|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
A TLV Tuple tree node modeled in the likeness of a TreeNode.
| Method Summary | |
void |
accept(TupleNodeVisitor visitor)
Element/node accept method for visitor pattern. |
void |
encode(java.nio.ByteBuffer buf)
Recursively encodes the tree rooted at this node. |
boolean |
equals(java.lang.Object obj)
Checks to see if two trees are equal. |
int |
getChildCount()
Gets the number of child nodes contained. |
java.util.Iterator |
getChildren()
Gets an iterator over this node's children. |
TupleNode |
getChildTupleNodeAt(int index)
Gets a tuple node at an index. |
int |
getIndex(TupleNode node)
Gets the index of a child if the child node if it exists. |
TupleNode |
getParentTupleNode()
Gets the parent tuple node to this node or null if a parent does not exist. |
Tuple |
getTuple()
Gets the Tuple this node represents. |
java.util.List |
getValueChunks()
Gets the chunked value buffer fragments collected within this node. |
int |
size()
Gets the number of child nodes contained. |
| Method Detail |
public TupleNode getParentTupleNode()
TreeNode interface
would be getParent().
public java.util.Iterator getChildren()
TreeNode interface would be children which
returns an Enumeration instead of an Iterator.
public TupleNode getChildTupleNodeAt(int index)
TreeNode
would be the getChildAt method.
index - the index of the child to get
public java.util.List getValueChunks()
public int getIndex(TupleNode node)
TreeNode takes a TreeNode instead of a
TupleNode.
- Parameters:
node - the child node to get the index for
- Returns:
- the index of the child node or -1 if the node does not exist
public int getChildCount()
TreeNode.getChildCount() as well.
public int size()
TreeNode.size() as well.
public Tuple getTuple()
TreeNode.getUserObject().
public void encode(java.nio.ByteBuffer buf)
buf - the buffer populated with the BER encoded tlv tree contentspublic boolean equals(java.lang.Object obj)
equals().
obj - the object to compare this node to
public void accept(TupleNodeVisitor visitor)
visitor - the tuple node tree structure visitorTupleNodeVisitor
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||