V - the kind of values this UIValue handlesU - the kind of UIValue that the UIProperties will handle.
This class is either abstract, or a subclass of U.public abstract class AbstractUIValue<V,U extends UIValue<V>> extends Object implements UIValue<V>
UIValue. This class contains more than
just one resource:
UIPropertiesUIProperties.| Constructor and Description |
|---|
AbstractUIValue(String id)
Creates a new
UIValue. |
AbstractUIValue(String id,
Path kind)
Creates a new
UIValue. |
AbstractUIValue(String id,
Path kind,
V backup)
Creates a new
UIValue. |
AbstractUIValue(String id,
V backup)
Creates a new
UIValue. |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
changed(V oldValue,
V newValue)
Called when the resource of this
AbstractDockColor has changed |
V |
getBackup()
Gets the backup value.
|
String |
getId()
Gets the identifier of this value.
|
Path |
getKind()
Gets the kind of this value.
|
V |
getValue()
Gets the override value.
|
protected abstract U |
me()
Returns
this. |
void |
set(V value)
Called when the underlying resource of this
UIValue changes. |
void |
setBackup(V backup)
Sets the backup value.
|
void |
setId(String id)
Changes the identifier of this value.
|
void |
setKind(Path kind)
Changes the kind of this value.
|
void |
setManager(UIProperties<V,U,?> manager)
Sets the manager which owns this
UIValue, this will
automatically be added or removed from the current manager. |
void |
setValue(V value)
Sets the override value.
|
void |
setValue(V value,
boolean forceNull)
Sets the override value.
|
void |
update(UIProperties<V,U,?> manager)
|
V |
value()
Gets the first non-
null value of the list
override, value, backup. |
public AbstractUIValue(String id)
UIValue.id - the id of the resource for which this should listen forpublic AbstractUIValue(String id, Path kind)
UIValue.id - the id of the resource for which this should listen forkind - the kind of UIValue this ispublic AbstractUIValue(String id, V backup)
UIValue.id - the id of the resource for which this should listen forbackup - a backup resource, can be nullprotected abstract U me()
this. This method can only be implemented when
the generic boundaries are met, so this methods ensures that this
is really an U, or abstract.thispublic void setId(String id)
id - the new id, must not be nullpublic String getId()
nullpublic void setKind(Path kind)
UIProperties
to find out, which UIBridge should be used to interact with
this UIValue.kind - the new kind, not null. The kind should be
a class or interfaces that is implemented by this UIValue.public Path getKind()
setKind(Path).nullpublic void setManager(UIProperties<V,U,?> manager)
UIValue, this will
automatically be added or removed from the current manager.manager - the new manager, can be nullpublic void set(V value)
UIValueUIValue changes.public void update(UIProperties<V,U,?> manager)
manager - the manager from which to read the valuepublic V value()
null value of the list
override, value, backup.nullprotected abstract void changed(V oldValue, V newValue)
AbstractDockColor has changedoldValue - the old value, can be nullnewValue - the new value, can be nullpublic void setValue(V value)
value - the new override or nullpublic void setValue(V value, boolean forceNull)
value() returns
null, use forceNull with care.value - the new value, can be nullforceNull - if true and value is null, then
the result of value() is null toopublic V getValue()
nullpublic void setBackup(V backup)
backup - the backup or nullpublic V getBackup()
nullCopyright © 2017 Docking Frames. All rights reserved.