|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--test.ojb.broker.Tree
Tree is recursive type: a Tree element contains some data and a Vector of child Tree elements. This sample demonstrates what is needed to map such a data structure on a DB table
Constructor Summary | |
Tree()
Tree constructor comment. |
|
Tree(int id,
java.lang.String data,
int parentid)
Tree constructor comment. |
Method Summary | |
void |
addChild(Tree newChild)
|
Tree |
getChild(int index)
|
java.util.Vector |
getChilds()
Insert the method's description here. |
java.lang.String |
getData()
Insert the method's description here. |
int |
getId()
Insert the method's description here. |
int |
getParentId()
Insert the method's description here. |
void |
setChilds(java.util.Vector newChilds)
Insert the method's description here. |
void |
setData(java.lang.String newData)
Insert the method's description here. |
void |
setId(int newId)
Insert the method's description here. |
void |
setParentId(int newParentId)
Insert the method's description here. |
int |
size()
Insert the method's description here. |
java.lang.String |
toString()
Insert the method's description here. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Tree()
public Tree(int id, java.lang.String data, int parentid)
Method Detail |
public void addChild(Tree newChild)
public Tree getChild(int index)
public java.util.Vector getChilds()
public java.lang.String getData()
public int getId()
public int getParentId()
public void setChilds(java.util.Vector newChilds)
newChilds
- java.util.Vectorpublic void setData(java.lang.String newData)
newData
- java.lang.Stringpublic void setId(int newId)
newId
- intpublic void setParentId(int newParentId)
newParentId
- intpublic int size()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |