Class PDObjectReference
java.lang.Object
org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDObjectReference
- All Implemented Interfaces:
COSObjectable
An object reference.
This is described as "Entries in an object reference dictionary" in the PDF specification.
- Author:
- Johannes Koch
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefault Constructor.PDObjectReference(COSDictionary theDictionary) Constructor for an existing object reference. -
Method Summary
Modifier and TypeMethodDescriptionReturns the underlying dictionary.getPage()Get the page on which the object shall be rendered.Gets a higher-level object for the referenced object.voidSets the page on which the object shall be rendered.voidsetReferencedObject(PDXObject xobject) Sets the referenced XObject.voidsetReferencedObject(PDAnnotation annotation) Sets the referenced annotation.
-
Field Details
-
TYPE
TYPE of this object.- See Also:
-
-
Constructor Details
-
PDObjectReference
public PDObjectReference()Default Constructor. -
PDObjectReference
Constructor for an existing object reference.- Parameters:
theDictionary- The existing dictionary.
-
-
Method Details
-
getCOSObject
Returns the underlying dictionary.- Specified by:
getCOSObjectin interfaceCOSObjectable- Returns:
- the dictionary
-
getReferencedObject
Gets a higher-level object for the referenced object. Currently this method may return aPDAnnotation, aPDXObjectornull.- Returns:
- a higher-level object for the referenced object
-
setReferencedObject
Sets the referenced annotation.- Parameters:
annotation- the referenced annotation
-
setReferencedObject
Sets the referenced XObject.- Parameters:
xobject- the referenced XObject
-
getPage
Get the page on which the object shall be rendered.- Returns:
- the referenced page or null.
-
setPage
Sets the page on which the object shall be rendered. This is optional and overrides the /PG entry in the structure element containing the object reference; shall be used if the structure element contained no such entry.- Parameters:
page-
-