Class PDAttributeObject
- java.lang.Object
-
- com.tom_roush.pdfbox.pdmodel.common.PDDictionaryWrapper
-
- com.tom_roush.pdfbox.pdmodel.documentinterchange.logicalstructure.PDAttributeObject
-
- All Implemented Interfaces:
COSObjectable
- Direct Known Subclasses:
PDDefaultAttributeObject,PDStandardAttributeObject,PDUserAttributeObject
public abstract class PDAttributeObject extends PDDictionaryWrapper
An attribute object.
-
-
Constructor Summary
Constructors Constructor Description PDAttributeObject()Default constructor.PDAttributeObject(COSDictionary dictionary)Creates a new attribute object with a given dictionary.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static StringarrayToString(float[] array)Creates a String representation of a float array.protected static StringarrayToString(Object[] array)Creates a String representation of an Object array.static PDAttributeObjectcreate(COSDictionary dictionary)Creates an attribute object.StringgetOwner()Returns the owner of the attributes.booleanisEmpty()Detects whether there are no properties in the attribute object.protected voidnotifyChanged()Notifies the attribute object change listeners about a change in this attribute object.protected voidpotentiallyNotifyChanged(COSBase oldBase, COSBase newBase)Notifies the attribute object change listeners if the attribute is changed.protected voidsetOwner(String owner)Sets the owner of the attributes.protected voidsetStructureElement(PDStructureElement structureElement)Sets the structure element.StringtoString()-
Methods inherited from class com.tom_roush.pdfbox.pdmodel.common.PDDictionaryWrapper
equals, getCOSObject, hashCode
-
-
-
-
Constructor Detail
-
PDAttributeObject
public PDAttributeObject()
Default constructor.
-
PDAttributeObject
public PDAttributeObject(COSDictionary dictionary)
Creates a new attribute object with a given dictionary.- Parameters:
dictionary- the dictionary
-
-
Method Detail
-
create
public static PDAttributeObject create(COSDictionary dictionary)
Creates an attribute object.- Parameters:
dictionary- the dictionary- Returns:
- the attribute object
-
setStructureElement
protected void setStructureElement(PDStructureElement structureElement)
Sets the structure element.- Parameters:
structureElement- the structure element
-
getOwner
public String getOwner()
Returns the owner of the attributes.- Returns:
- the owner of the attributes
-
setOwner
protected void setOwner(String owner)
Sets the owner of the attributes.- Parameters:
owner- the owner of the attributes
-
isEmpty
public boolean isEmpty()
Detects whether there are no properties in the attribute object.- Returns:
trueif the attribute object is empty,falseotherwise
-
potentiallyNotifyChanged
protected void potentiallyNotifyChanged(COSBase oldBase, COSBase newBase)
Notifies the attribute object change listeners if the attribute is changed.- Parameters:
oldBase- old valuenewBase- new value
-
notifyChanged
protected void notifyChanged()
Notifies the attribute object change listeners about a change in this attribute object.
-
arrayToString
protected static String arrayToString(Object[] array)
Creates a String representation of an Object array.- Parameters:
array- the Object array- Returns:
- the String representation
-
arrayToString
protected static String arrayToString(float[] array)
Creates a String representation of a float array.- Parameters:
array- the float array- Returns:
- the String representation
-
-