Class PageTreeNode
java.lang.Object
de.erichseifert.vectorgraphics2d.pdf.PageTreeNode
- All Implemented Interfaces:
PDFObject
Represents an intermediate node in the page tree of a PDF document.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPageTreeNode(PageTreeNode parent) Initializes aPageTreeNodewith the specified parent node. -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds the specifiedPageto the node's children.intgetCount()Returns the total number ofPageobjects in this subtree.getKids()Returns allPageobjects that are immediate children of this node.Returns the parent of this node.getType()Returns the type of this object.
-
Field Details
-
parent
-
children
-
-
Constructor Details
-
PageTreeNode
Initializes aPageTreeNodewith the specified parent node.- Parameters:
parent- Parent node ornullto create a root node.
-
-
Method Details
-
getType
Returns the type of this object. The return value is always Pages.- Returns:
- The String Pages.
-
getParent
Returns the parent of this node. If this node is a root node, the method returnsnull.- Returns:
- Parent node or
null, if this is a root node.
-
add
Adds the specifiedPageto the node's children.- Parameters:
page-Pageto be added.
-
getKids
Returns allPageobjects that are immediate children of this node.- Returns:
- List of child pages.
-
getCount
public int getCount()Returns the total number ofPageobjects in this subtree.- Returns:
- Number of pages that are direct or indirect children.
-