Class PDAttributeObject
java.lang.Object
org.apache.pdfbox.pdmodel.common.PDDictionaryWrapper
org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDAttributeObject
- All Implemented Interfaces:
COSObjectable
- Direct Known Subclasses:
PDDefaultAttributeObject
,PDStandardAttributeObject
,PDUserAttributeObject
An attribute object.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.PDAttributeObject
(COSDictionary dictionary) Creates a new attribute object with a given dictionary. -
Method Summary
Modifier and TypeMethodDescriptionprotected static String
arrayToString
(float[] array) Creates a String representation of a float array.protected static String
arrayToString
(Object[] array) Creates a String representation of an Object array.static PDAttributeObject
create
(COSDictionary dictionary) Creates an attribute object.getOwner()
Returns the owner of the attributes.private PDStructureElement
Gets the structure element.boolean
isEmpty()
Detects whether there are no properties in the attribute object.private boolean
isValueChanged
(COSBase oldValue, COSBase newValue) Is the value changed?protected void
Notifies the attribute object change listeners about a change in this attribute object.protected void
potentiallyNotifyChanged
(COSBase oldBase, COSBase newBase) Notifies the attribute object change listeners if the attribute is changed.protected void
Sets the owner of the attributes.protected void
setStructureElement
(PDStructureElement structureElement) Sets the structure element.toString()
Methods inherited from class org.apache.pdfbox.pdmodel.common.PDDictionaryWrapper
equals, getCOSObject, hashCode
-
Field Details
-
structureElement
-
-
Constructor Details
-
PDAttributeObject
public PDAttributeObject()Default constructor. -
PDAttributeObject
Creates a new attribute object with a given dictionary.- Parameters:
dictionary
- the dictionary
-
-
Method Details
-
create
Creates an attribute object.- Parameters:
dictionary
- the dictionary- Returns:
- the attribute object
-
getStructureElement
Gets the structure element.- Returns:
- the structure element
-
setStructureElement
Sets the structure element.- Parameters:
structureElement
- the structure element
-
getOwner
Returns the owner of the attributes.- Returns:
- the owner of the attributes
-
setOwner
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:
true
if the attribute object is empty,false
otherwise
-
potentiallyNotifyChanged
Notifies the attribute object change listeners if the attribute is changed.- Parameters:
oldBase
- old valuenewBase
- new value
-
isValueChanged
Is the value changed?- Parameters:
oldValue
- old valuenewValue
- new value- Returns:
true
if the value is changed,false
otherwise
-
notifyChanged
protected void notifyChanged()Notifies the attribute object change listeners about a change in this attribute object. -
toString
-
arrayToString
Creates a String representation of an Object array.- Parameters:
array
- the Object array- Returns:
- the String representation
-
arrayToString
Creates a String representation of a float array.- Parameters:
array
- the float array- Returns:
- the String representation
-