Package cz.vutbr.fit.layout.model
Interface GenericTreeNode<T extends GenericTreeNode<T>>
-
- All Known Subinterfaces:
Area,Box,LogicalArea
- All Known Implementing Classes:
BoxImpl,BoxImpl,BoxNode,DefaultArea,DefaultBox,DefaultLogicalArea,DefaultTreeContentRect,DefaultTreeNode,RDFArea,RDFBox,RDFLogicalArea
public interface GenericTreeNode<T extends GenericTreeNode<T>>A generic tree node interface.- Author:
- burgetr
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidappendChild(T child)voidappendChildren(List<T> children)intgetDepth()TgetChildAt(int index)intgetChildCount()List<T>getChildren()intgetIndex(T child)intgetLeafCount()TgetNextSibling()TgetParent()TgetPreviousSibling()TgetRoot()voidchildrenChanged()Signals that some children have been added or removed or their state changed.voidinsertChild(T child, int index)booleanisLeaf()booleanisRoot()voidremoveAllChildren()voidremoveChild(int index)voidremoveChild(T child)voidsetParent(T parent)voidsetRoot(T root)
-
-
-
Method Detail
-
getParent
T getParent()
-
setParent
void setParent(T parent)
-
getRoot
T getRoot()
-
setRoot
void setRoot(T root)
-
isRoot
boolean isRoot()
-
getChildCount
int getChildCount()
-
isLeaf
boolean isLeaf()
-
appendChild
void appendChild(T child)
-
insertChild
void insertChild(T child, int index) throws IndexOutOfBoundsException
- Throws:
IndexOutOfBoundsException
-
removeAllChildren
void removeAllChildren()
-
removeChild
void removeChild(int index) throws IndexOutOfBoundsException- Throws:
IndexOutOfBoundsException
-
removeChild
void removeChild(T child) throws IllegalArgumentException
- Throws:
IllegalArgumentException
-
getChildAt
T getChildAt(int index) throws IndexOutOfBoundsException
- Throws:
IndexOutOfBoundsException
-
getIndex
int getIndex(T child)
-
getPreviousSibling
T getPreviousSibling()
-
getNextSibling
T getNextSibling()
-
getDepth
int getDepth()
-
getLeafCount
int getLeafCount()
-
childrenChanged
void childrenChanged()
Signals that some children have been added or removed or their state changed.
-
-