Interface Treeable<PK extends java.io.Serializable,​T,​TR extends Treeable>

  • Type Parameters:
    PK - the generic type of the technical primary key
    T - the generic type of the value from this tree entity
    TR - 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 interface Treeable provides the data for keep information with in a tree structure.
    • 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