public class PropertyNode extends Object implements IGosuObject
PropertySet
. Any compound names, such
as a.b.c and a.b.d, in the keys of the property set are split into a tree representation. In the
a.b.c/a.b.d example there would be a property node for a, with a child node b with two further
leaf children c and d.Modifier and Type | Method and Description |
---|---|
static PropertyNode |
buildTree(PropertySet propertySet) |
List<PropertyNode> |
getChildren()
The direct children of this property node
|
String |
getChildValue(String name)
Return the value for the named child property; this is just like doing lookup on the underlying
PropertySet except that the name is prefixed with the full name of this property. |
String |
getFullName()
The full property name, for example a.b
|
IType |
getIntrinsicType()
Return the intrinsic type based on this property node
|
PropertyNode |
getParent() |
String |
getPath() |
String |
getRelativeName()
The last part of the property name, for example b if the full name is a.b
|
String |
getTypeName()
Return the name that should be used for the type based on this property node
|
String |
getValue()
Return the value for this property as given by the underlying
PropertySet |
boolean |
hasValue()
Does this property node have a value in the underlying
PropertySet |
boolean |
isLeaf()
Is this a leaf node - that is, does it have no children?
|
boolean |
isRoot()
Is this the root of a property node tree?
|
String |
toString()
If this node has a property value, returns the value of that property.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
equals, hashCode
public static PropertyNode buildTree(PropertySet propertySet)
public String getFullName()
public String getRelativeName()
public String getTypeName()
public IType getIntrinsicType()
getIntrinsicType
in interface IGosuObject
public boolean hasValue()
PropertySet
public String getValue()
PropertySet
public boolean isLeaf()
public boolean isRoot()
public List<PropertyNode> getChildren()
public String getChildValue(String name)
PropertySet
except that the name is prefixed with the full name of this property. For
example if this property is a then getting the child value b.c will return the value of a.b.c
in the original property setname
- non null name of child propertypublic String toString()
toString
in interface IGosuObject
toString
in class Object
public String getPath()
public PropertyNode getParent()
Copyright © 2016. All rights reserved.