Package org.docx4j.model.styles
Class Node<T>
java.lang.Object
org.docx4j.model.styles.Node<T>
Represents a node of the Tree class. The Node is also a container, and
can be thought of as instrumentation to determine the location of the type T
in the Tree.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
styleId
-
tree
-
data
-
children
-
-
Constructor Details
-
Node
Convenience ctor to create a Nodewith an instance of T. - Parameters:
data- an instance of T.
-
-
Method Details
-
getParent
-
setParent
-
getChildren
Return the children of Node. The Tree is represented by a single root Node whose children are represented by a List<Node >. Each of these Node elements in the List can have children. The getChildren() method will return the children of a Node . - Returns:
- the children of Node
-
addChild
Adds a child to the list of children for this Node. The addition of the first child will create a new List<Node >. - Parameters:
child- a Nodeobject to set.
-
getData
-
setData
-
toString
-