|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.beanfabrics.meta.PathNode
public class PathNode
The PathNode
represents the meta data for a specific node inside a PM's tree-like structure, reachable by a
given Path
relative to a arbitratily defined root node.
With a PathNode
you can navigate from a specific node upwards until it's defined root node and downwards
until it's leaf nodes.
Note: There is no natural root node for any given PM, because there is no top-level PM class. PM classes can always be combined into greater structures. In this sense any node inside a PMs structure can be arbitrarily choosen to be a root node.
Method Summary | |
---|---|
PathNode |
asRoot()
Returns a new PathNode with this node defined as the new root node. |
boolean |
equals(java.lang.Object obj)
|
PathNode |
getChild(java.lang.String name)
Returns the path element info for the child with he given name. |
java.util.Collection<PathNode> |
getChildren()
Returns the path element infos for for all children. |
GenericType |
getGenericType()
Returns the generic type representing the Java class of this path element. |
java.lang.String |
getName()
Returns the element name of this path element. |
PathNode |
getNode(Path pathToNode)
Returns the path element info for the node at the end of the given path. |
PathNode |
getParent()
Returns the path element info of this element's parent. |
Path |
getPath()
Returns the relative path from the root element to this path element. |
PathNode |
getRoot()
Returns the root element. |
TypeInfo |
getTypeInfo()
Returns the type info of this element. |
boolean |
hasChildren()
Returns whether this element's type info has children. |
int |
hashCode()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public PathNode getParent()
public TypeInfo getTypeInfo()
public java.lang.String getName()
public boolean hasChildren()
public java.util.Collection<PathNode> getChildren()
public PathNode getChild(java.lang.String name)
name
- the property name of the child
public PathNode asRoot()
PathNode
with this node defined as the new root node.
PathNode
with this node defined as the new root nodepublic PathNode getNode(Path pathToNode)
pathToNode
-
public Path getPath()
public GenericType getGenericType()
public PathNode getRoot()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |