public class PdfOCProperties extends PdfObjectWrapper<PdfDictionary>
PdfObjectWrapper the PdfObject
must be indirect.| Constructor and Description |
|---|
PdfOCProperties(PdfDictionary ocPropertiesDict)
Creates a new PdfOCProperties instance by the dictionary it represents,
the dictionary must be an indirect object.
|
PdfOCProperties(PdfDocument document)
Creates a new PdfOCProperties instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addOCGRadioGroup(List<PdfLayer> group)
Use this method to set a collection of optional content groups
whose states are intended to follow a "radio button" paradigm.
|
PdfObject |
fillDictionary()
Fills the underlying PdfDictionary object with the current layers and their settings.
|
void |
flush() |
protected PdfDocument |
getDocument() |
List<PdfLayer> |
getLayers()
Gets the list of all the layers currently registered in the OCProperties.
|
protected boolean |
isWrappedObjectMustBeIndirect()
Defines if the object behind this wrapper must be an indirect object in the
resultant document.
|
protected void |
registerLayer(PdfLayer layer)
This method registers a new layer in the OCProperties.
|
ensureObjectIsAddedToDocument, ensureUnderlyingObjectHasIndirectReference, getPdfObject, isFlushed, makeIndirect, makeIndirect, markObjectAsIndirect, setForbidRelease, setModified, setPdfObject, unsetForbidReleasepublic PdfOCProperties(PdfDocument document)
document - the document the optional content belongs topublic PdfOCProperties(PdfDictionary ocPropertiesDict)
ocPropertiesDict - the dictionary of optional content properties, must have an indirect reference.public void addOCGRadioGroup(List<PdfLayer> group)
group - the radio grouppublic PdfObject fillDictionary()
public void flush()
flush in class PdfObjectWrapper<PdfDictionary>public List<PdfLayer> getLayers()
protected boolean isWrappedObjectMustBeIndirect()
PdfObjectWrapperisWrappedObjectMustBeIndirect in class PdfObjectWrapper<PdfDictionary>protected void registerLayer(PdfLayer layer)
layer - the new layerprotected PdfDocument getDocument()
Copyright © 1998–2017 iText Group NV. All rights reserved.