|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.palo.api.ElementNode
public class ElementNode
ElementNode
ElementNodes are used to construct a tree of consolidations for
a given dimension. Since elements can be consolidated multiple times, it is
not practicable to use them as is for representing tree-nodes in the
consolidation-hierarchy instead ElementNodes are used. Each element-node
wraps an element where a single element can be wrapped in multiple
ElementNodes. The wrapped element can be retrieved by invoking
getElement().
| Constructor Summary | |
|---|---|
ElementNode(Element element)
Constructs a new ElementNode |
|
ElementNode(Element element,
Consolidation consolidation)
Constructs a new ElementNode |
|
ElementNode(Element element,
Consolidation consolidation,
int index)
Constructs a new ElementNode |
|
| Method Summary | |
|---|---|
void |
addChild(ElementNode child)
Adds a child to this ElementNode. |
boolean |
equals(java.lang.Object obj)
|
ElementNode[] |
getChildren()
Returns the children of this ElementNode. |
Consolidation |
getConsolidation()
Returns the Consolidation of this instance. |
int |
getDepth()
Returns the depth of this ElementNode
in the consolidation hierarchy. |
Element |
getElement()
Returns the wrapped Element. |
int |
getIndex()
Returns the optional index of this instance or -1 if no index was set. |
ElementNode |
getParent()
Returns the parent ElementNode or
null. |
boolean |
hasChildren()
Returns whether this ElementNode has any children. |
int |
hashCode()
|
void |
removeChild(ElementNode child)
Removes a child from this ElementNode. |
void |
removeChildren()
Removes all children from this ElementNode. |
void |
setParent(ElementNode parent)
|
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ElementNode(Element element)
ElementNode
element - the Element to wrap.
public ElementNode(Element element,
Consolidation consolidation)
ElementNode
element - the Element to wrap.consolidation - the Consolidation of this node.
public ElementNode(Element element,
Consolidation consolidation,
int index)
ElementNode
element - the Element to wrap.consolidation - the Consolidation of this node.index - index in parent (optional)| Method Detail |
|---|
public final int getIndex()
the - index of this instance or -1 if none was setpublic final Element getElement()
Element.
Element.public final Consolidation getConsolidation()
Consolidation of this instance.
Consolidation of this instance.public final void setParent(ElementNode parent)
public final ElementNode getParent()
ElementNode or
null.
ElementNode or
null.public final int getDepth()
ElementNode
in the consolidation hierarchy.
ElementNodepublic final void addChild(ElementNode child)
ElementNode.
Note: This is an internal method and it is not
required to invoke it under most circumstances.
child - the child to add.public final void removeChild(ElementNode child)
ElementNode.
Note: This is an internal method and it is not
required to invoke it under most circumstances.
child - the child to remove.public final void removeChildren()
ElementNode.
Note: This is an internal method and it is not
required to invoke it under most circumstances.
public ElementNode[] getChildren()
ElementNode.
ElementNode.public boolean hasChildren()
ElementNode has any children.
ElementNode has any children.public final java.lang.String toString()
toString in class java.lang.Objectpublic final boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic final int hashCode()
hashCode in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||