Class PDStructureTreeRoot
- java.lang.Object
-
- org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDStructureNode
-
- org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDStructureTreeRoot
-
- All Implemented Interfaces:
COSObjectable
public class PDStructureTreeRoot extends PDStructureNode
A root of a structure tree.
-
-
Constructor Summary
Constructors Constructor Description PDStructureTreeRoot()
Default Constructor.PDStructureTreeRoot(COSDictionary dic)
Constructor for an existing structure element.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description PDNameTreeNode<PDStructureElement>
getIDTree()
Returns the ID tree.COSBase
getK()
Returns the K entry.COSArray
getKArray()
Deprecated.usegetK()
only.PDNumberTreeNode
getParentTree()
Returns the parent tree.int
getParentTreeNextKey()
Returns the next key in the parent tree.java.util.Map<java.lang.String,java.lang.Object>
getRoleMap()
Returns the role map.void
setIDTree(PDNameTreeNode<PDStructureElement> idTree)
Sets the ID tree.void
setK(COSBase k)
Sets the K entry.void
setParentTree(PDNumberTreeNode parentTree)
Sets the parent tree.void
setParentTreeNextKey(int parentTreeNextkey)
Sets the next key in the parent tree.void
setRoleMap(java.util.Map<java.lang.String,java.lang.String> roleMap)
Sets the role map.-
Methods inherited from class org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDStructureNode
appendKid, appendKid, appendObjectableKid, create, createObject, getCOSObject, getKids, getType, insertBefore, insertBefore, insertObjectableBefore, removeKid, removeKid, removeObjectableKid, setKids
-
-
-
-
Field Detail
-
LOG
private static final org.apache.commons.logging.Log LOG
Log instance.
-
TYPE
private static final java.lang.String TYPE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
PDStructureTreeRoot
public PDStructureTreeRoot()
Default Constructor.
-
PDStructureTreeRoot
public PDStructureTreeRoot(COSDictionary dic)
Constructor for an existing structure element.- Parameters:
dic
- The existing dictionary.
-
-
Method Detail
-
getKArray
@Deprecated public COSArray getKArray()
Deprecated.usegetK()
only. /K can be a dictionary or an array, and the next level can also be a dictionary. See file 054080.pdf in PDFBOX-4417 and read "Entries in the structure tree root" in the PDF specification.Returns the K array entry.- Returns:
- the K array entry
-
getK
public COSBase getK()
Returns the K entry. This can be a dictionary representing a structure element, or an array of them.- Returns:
- the K entry.
-
setK
public void setK(COSBase k)
Sets the K entry.- Parameters:
k
- the K value
-
getIDTree
public PDNameTreeNode<PDStructureElement> getIDTree()
Returns the ID tree.- Returns:
- the ID tree
-
setIDTree
public void setIDTree(PDNameTreeNode<PDStructureElement> idTree)
Sets the ID tree.- Parameters:
idTree
- the ID tree
-
getParentTree
public PDNumberTreeNode getParentTree()
Returns the parent tree.- Returns:
- the parent tree
-
setParentTree
public void setParentTree(PDNumberTreeNode parentTree)
Sets the parent tree.- Parameters:
parentTree
- the parent tree
-
getParentTreeNextKey
public int getParentTreeNextKey()
Returns the next key in the parent tree.- Returns:
- the next key in the parent tree
-
setParentTreeNextKey
public void setParentTreeNextKey(int parentTreeNextkey)
Sets the next key in the parent tree.- Parameters:
parentTreeNextkey
- the next key in the parent tree.
-
getRoleMap
public java.util.Map<java.lang.String,java.lang.Object> getRoleMap()
Returns the role map.- Returns:
- the role map
-
setRoleMap
public void setRoleMap(java.util.Map<java.lang.String,java.lang.String> roleMap)
Sets the role map.- Parameters:
roleMap
- the role map
-
-