public class LayerNode
extends java.lang.Object
LayerNode
is encapsulation of PDF layers.
It can be constructed by the following way:
Example:
LayerNode node = PDFDocument#enumLayers();
PDFDocument
Modifier and Type | Method and Description |
---|---|
void |
clear()
Clear current PDF layer node.
|
int |
countChildren()
Get the count of children.
|
LayerNode |
getChildren(int index)
Get the children of the layer or layer group with the specified index.
|
long |
getHandle()
Get the
LayerNode handle. |
Layer |
getLayer()
Get the current layer of layer group.
|
java.lang.String |
getName()
Get the current layer name or layer group name.
|
public long getHandle()
LayerNode
handle.LayerNode
handle.public java.lang.String getName() throws PDFException
PDFException
- For more exception information please see definitions
PDFException.ERRCODE_XXX
.PDFException
public Layer getLayer() throws PDFException
If not null
means a layer; otherwise it's a layer group.
Layer
object.PDFException
- For more exception information please see definitions
PDFException.ERRCODE_XXX
.PDFException
,
Layer
public int countChildren() throws PDFException
PDFException
- For more exception information please see definitions
PDFException.ERRCODE_XXX
.PDFException
public LayerNode getChildren(int index) throws PDFException
If the layer or layer group could have children.
index
- An integer
value for index children of layer of layer group.
Range: 0 to (childrencount - 1). childrencount
is returned by function
countChildren()
.LayerNode
object.If there aren't children, it will return null.PDFException
- For more exception information please see definitions
PDFException.ERRCODE_XXX
.PDFException
public void clear() throws PDFException
PDFException
- For more exception information please see definitions
PDFException.ERRCODE_XXX
.PDFException