java.lang.Object
org.sejda.sambox.cos.COSBase
- All Implemented Interfaces:
COSObjectable
- Direct Known Subclasses:
COSArray,COSBoolean,COSDictionary,COSDocument,COSName,COSNull,COSNumber,COSString,DirectCOSObject,ExistingIndirectCOSObject,IndirectCOSObject,IndirectCOSObjectReference
The base object that all objects in the PDF document will extend.
- Author:
- Ben Litchfield
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract voidaccept(COSVisitor visitor) Visitor pattern for the COS model objectsConvert this standard java object to a COS object.booleanhasId()id()voidAssign an id to thisCOSBaseif it doesn't have one already.
-
Constructor Details
-
COSBase
public COSBase()
-
-
Method Details
-
getCOSObject
Convert this standard java object to a COS object.- Specified by:
getCOSObjectin interfaceCOSObjectable- Returns:
- The cos object that matches this Java object.
-
accept
Visitor pattern for the COS model objects- Parameters:
visitor-- Throws:
IOException
-
id
- Returns:
- an identifier that can be used to identify this
COSBase.
-
idIfAbsent
Assign an id to thisCOSBaseif it doesn't have one already.- Parameters:
id-
-
hasId
public boolean hasId()- Returns:
- true if the
COSBasehas an id assigned to it
-