public class EditingProperty extends java.lang.Object implements InheritableProperty
AutoValue, DEFAULT_DOUBLE, IllegalValue, VoidValue
Constructor and Description |
---|
EditingProperty(PropTreeCell cell,
HostList hostList,
boolean isLive) |
Modifier and Type | Method and Description |
---|---|
static java.util.LinkedList<Property> |
createProperties(PropTreeCell tree,
HostList hostList,
boolean isLive) |
static EditingProperty |
createProperty(java.lang.String[] propPaths,
HasProperties ancestor,
boolean isLive)
Create an EditingProperty that edits a single property across a set of
hosts, each specified by a property path with respect to a common
ancestor host.
|
static EditingProperty |
createProperty(java.lang.String propPath,
HasProperties[] hosts,
boolean isLive)
Create an EditingProperty that edits a property specified by propPath
with respect to a set of property hosts.
|
java.lang.Object |
get()
Returns the value associated with this property.
|
PropTreeCell |
getCell() |
HasProperties |
getHost()
Assuming this is not needed ...
|
HostList |
getHostList() |
PropertyInfo |
getInfo()
Gets static information about the property.
|
PropertyMode |
getMode()
Returns the current mode for this property.
|
java.lang.String |
getName()
Returns the name associated with this Property.
|
Range |
getRange()
Returns a range that indicates what values are legal for
for this property, or
null if the
property does not have any range limits (i.e., if
any value of appropriate type specified to Property.get()
is valid. |
boolean |
isLive() |
void |
set(java.lang.Object value)
Sets the value associated with this property.
|
void |
setHostList(HostList hostList,
boolean isLive)
Resets the host list within this EditingProperty.
|
void |
setMode(PropertyMode mode)
Sets the mode for this property.
|
void |
updateValue() |
public EditingProperty(PropTreeCell cell, HostList hostList, boolean isLive)
public static EditingProperty createProperty(java.lang.String[] propPaths, HasProperties ancestor, boolean isLive)
propPaths
- paths of the property with respect to the ancestor hostancestor
- ancestor property hostisLive
- if true
, this widget should support live updating
of the property value within the hostsnull
if the specified
property is not the same across all hosts.public static EditingProperty createProperty(java.lang.String propPath, HasProperties[] hosts, boolean isLive)
propPath
- path of the property with respect to each hosthosts
- property host objectisLive
- if true
, this widget should support live updating
of the property value in the hostsnull
if the specified
property is not common to all hosts.public void setHostList(HostList hostList, boolean isLive)
hostList
- new host listpublic void updateValue()
public java.lang.Object get()
Property
get
in interface Property
Property.getInfo()
public void set(java.lang.Object value)
Property
PropertyInfo
method
isReadOnly
returns
true.set
in interface Property
value
- object containing the value to be set.Property.getInfo()
public Range getRange()
Property
null
if the
property does not have any range limits (i.e., if
any value of appropriate type specified to Property.get()
is valid.public PropertyMode getMode()
InheritableProperty
getMode
in interface InheritableProperty
InheritableProperty.setMode(maspack.properties.PropertyMode)
public void setMode(PropertyMode mode)
InheritableProperty
PropertyMode.Explicit
,
PropertyMode.Inherited
,
or PropertyMode.Inactive
.setMode
in interface InheritableProperty
mode
- new mode for this property.InheritableProperty.getMode()
public java.lang.String getName()
Property
getInfo().getName();
public HasProperties getHost()
public PropertyInfo getInfo()
Property
public HostList getHostList()
public boolean isLive()
public PropTreeCell getCell()
public static java.util.LinkedList<Property> createProperties(PropTreeCell tree, HostList hostList, boolean isLive)