Interface Treeable<PK extends java.io.Serializable,T,TR extends Treeable>
-
- Type Parameters:
PK- the generic type of the technical primary keyT- the generic type of the value from this tree entityTR- the generic type of the concrete entity that will implement this interface
- All Known Subinterfaces:
IdentifiableTreeable<PK,T,TR>,IdentifiableTreeableVersionable<PK,T,TR>
public interface Treeable<PK extends java.io.Serializable,T,TR extends Treeable>The interfaceTreeableprovides the data for keep information with in a tree structure.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringCOLUMN_NAME_DEPTHThe Constant for the column name 'depth'.static java.lang.StringCOLUMN_NAME_NODEThe Constant for the column name 'node'.static java.lang.StringCOLUMN_NAME_PARENTThe Constant for the column name 'parent'.static java.lang.StringCOLUMN_NAME_VALUEThe Constant for the column name 'value'.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetDepth()Gets the depth of the nodeTRgetParent()Gets the parentTgetValue()Gets the value.booleanisNode()Checks if this is a nodevoidsetDepth(int depth)Sets the new depth of the nodevoidsetNode(boolean node)Sets the node flagvoidsetParent(TR parent)Sets the parentvoidsetValue(T value)Sets the value
-
-
-
Field Detail
-
COLUMN_NAME_DEPTH
static final java.lang.String COLUMN_NAME_DEPTH
The Constant for the column name 'depth'.- See Also:
- Constant Field Values
-
COLUMN_NAME_NODE
static final java.lang.String COLUMN_NAME_NODE
The Constant for the column name 'node'.- See Also:
- Constant Field Values
-
COLUMN_NAME_PARENT
static final java.lang.String COLUMN_NAME_PARENT
The Constant for the column name 'parent'.- See Also:
- Constant Field Values
-
COLUMN_NAME_VALUE
static final java.lang.String COLUMN_NAME_VALUE
The Constant for the column name 'value'.- See Also:
- Constant Field Values
-
-
Method Detail
-
getDepth
int getDepth()
Gets the depth of the node- Returns:
- the depth of the node
-
getParent
TR getParent()
Gets the parent- Returns:
- the parent
-
getValue
T getValue()
Gets the value.- Returns:
- the value
-
isNode
boolean isNode()
Checks if this is a node- Returns:
- true, if it is a node
-
setDepth
void setDepth(int depth)
Sets the new depth of the node- Parameters:
depth- the new depth
-
setNode
void setNode(boolean node)
Sets the node flag- Parameters:
node- the new node flag
-
setParent
void setParent(TR parent)
Sets the parent- Parameters:
parent- the new parent
-
setValue
void setValue(T value)
Sets the value- Parameters:
value- the new value
-
-