Package com.itextpdf.kernel.pdf.tagging
Class PdfStructureAttributes
- java.lang.Object
-
- com.itextpdf.kernel.pdf.PdfObjectWrapper<PdfDictionary>
-
- com.itextpdf.kernel.pdf.tagging.PdfStructureAttributes
-
- Direct Known Subclasses:
PdfUserPropertiesAttributes
public class PdfStructureAttributes extends PdfObjectWrapper<PdfDictionary>
-
-
Constructor Summary
Constructors Constructor Description PdfStructureAttributes(PdfDictionary attributesDict)PdfStructureAttributes(PdfNamespace namespace)PdfStructureAttributes(java.lang.String owner)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PdfStructureAttributesaddEnumAttribute(java.lang.String attributeName, java.lang.String attributeValue)PdfStructureAttributesaddFloatAttribute(java.lang.String attributeName, float attributeValue)PdfStructureAttributesaddIntAttribute(java.lang.String attributeName, int attributeValue)PdfStructureAttributesaddTextAttribute(java.lang.String attributeName, java.lang.String attributeValue)java.lang.StringgetAttributeAsEnum(java.lang.String attributeName)java.lang.FloatgetAttributeAsFloat(java.lang.String attributeName)java.lang.IntegergetAttributeAsInt(java.lang.String attributeName)java.lang.StringgetAttributeAsText(java.lang.String attributeName)java.lang.StringgetPdfOwner()Method to get owner of current pdf object.protected booleanisWrappedObjectMustBeIndirect()Defines if the object behind this wrapper must be an indirect object in the resultant document.PdfStructureAttributesremoveAttribute(java.lang.String attributeName)-
Methods inherited from class com.itextpdf.kernel.pdf.PdfObjectWrapper
ensureObjectIsAddedToDocument, ensureUnderlyingObjectHasIndirectReference, flush, getPdfObject, isFlushed, makeIndirect, makeIndirect, markObjectAsIndirect, setForbidRelease, setModified, setPdfObject, unsetForbidRelease
-
-
-
-
Constructor Detail
-
PdfStructureAttributes
public PdfStructureAttributes(PdfDictionary attributesDict)
-
PdfStructureAttributes
public PdfStructureAttributes(java.lang.String owner)
-
PdfStructureAttributes
public PdfStructureAttributes(PdfNamespace namespace)
-
-
Method Detail
-
getPdfOwner
public java.lang.String getPdfOwner()
Method to get owner of current pdf object.- Returns:
- Pdf owner
-
addEnumAttribute
public PdfStructureAttributes addEnumAttribute(java.lang.String attributeName, java.lang.String attributeValue)
-
addTextAttribute
public PdfStructureAttributes addTextAttribute(java.lang.String attributeName, java.lang.String attributeValue)
-
addIntAttribute
public PdfStructureAttributes addIntAttribute(java.lang.String attributeName, int attributeValue)
-
addFloatAttribute
public PdfStructureAttributes addFloatAttribute(java.lang.String attributeName, float attributeValue)
-
getAttributeAsEnum
public java.lang.String getAttributeAsEnum(java.lang.String attributeName)
-
getAttributeAsText
public java.lang.String getAttributeAsText(java.lang.String attributeName)
-
getAttributeAsInt
public java.lang.Integer getAttributeAsInt(java.lang.String attributeName)
-
getAttributeAsFloat
public java.lang.Float getAttributeAsFloat(java.lang.String attributeName)
-
removeAttribute
public PdfStructureAttributes removeAttribute(java.lang.String attributeName)
-
isWrappedObjectMustBeIndirect
protected boolean isWrappedObjectMustBeIndirect()
Description copied from class:PdfObjectWrapperDefines if the object behind this wrapper must be an indirect object in the resultant document.
If this method returns true it doesn't necessarily mean that object must be in the indirect state at any moment, but rather defines that when the object will be written to the document it will be transformed into indirect object if it's not indirect yet.
Return value of this method shouldn't depend on any logic, it should return always true or false.- Specified by:
isWrappedObjectMustBeIndirectin classPdfObjectWrapper<PdfDictionary>- Returns:
- true if in the resultant document the object behind the wrapper must be indirect, otherwise false.
-
-