public class TreeProperty
extends java.lang.Object
TreeComposite
properties or
parameters. Properties for a TreeComposite
are the Entry
instances stored in the tree's DataComponent
s or "data nodes".
This class also provides some helper methods for determining if a property is
read only or if it is the "adaptive type" for an
AdaptiveTreeComposite
.
Modifier and Type | Field and Description |
---|---|
int |
id
The ID of the property.
|
Constructor and Description |
---|
TreeProperty(int id,
TreeComposite tree,
DataComponent dataNode,
Entry entry)
The default constructor.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<java.lang.String> |
getAdaptiveTypes()
The supported types for the parent
AdaptiveTreeComposite . |
DataComponent |
getDataNode()
|
Entry |
getEntry()
Gets the actual "property" or "parameter".
|
TreeComposite |
getTree()
Gets the parent tree for this property.
|
boolean |
isAdaptiveType()
|
boolean |
isReadOnly()
Whether or not the entry is read only.
|
public final int id
Map
s.public TreeProperty(int id, TreeComposite tree, DataComponent dataNode, Entry entry)
id
- The ID of the property. This is usually the index of the
property among all its sibling properties.tree
- The parent tree for this property.dataNode
- The data node in the tree that contains the entry.entry
- The actual "property" or "parameter".public TreeComposite getTree()
TreeComposite
.public DataComponent getDataNode()
DataComponent
.public Entry getEntry()
Entry
corresponding to the tree property or
parameter.public boolean isReadOnly()
public boolean isAdaptiveType()
Entry
's value is the type of
AdaptiveTreeComposite
for the parent tree, false
otherwise.public java.util.List<java.lang.String> getAdaptiveTypes()
AdaptiveTreeComposite
.List
of Strings
representing the
parent tree's adaptive types, or an empty List
if
the property does not correspond to the parent tree's adaptive
type Entry
.