java.lang.Object
org.sejda.sambox.cos.COSBase
org.sejda.sambox.cos.COSNumber
org.sejda.sambox.cos.COSInteger
- All Implemented Interfaces:
COSObjectable
This class represents an integer number in a PDF document.
- Author:
- Ben Litchfield
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final COSIntegerstatic final COSIntegerstatic final COSIntegerstatic final COSInteger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(COSVisitor visitor) Visitor pattern for the COS model objectsdoublebooleanfloatstatic COSIntegerget(long val) Factory method for a COSInteger instance with the given value.inthashCode()intintValue()longtoString()Methods inherited from class org.sejda.sambox.cos.COSNumber
get, idIfAbsentMethods inherited from class org.sejda.sambox.cos.COSBase
getCOSObject, hasId, id
-
Field Details
-
ZERO
-
ONE
-
TWO
-
THREE
-
-
Constructor Details
-
COSInteger
public COSInteger(long value) creates a COSInteger that is not cached
-
-
Method Details
-
get
Factory method for a COSInteger instance with the given value.- Parameters:
val- integer value- Returns:
- COSInteger instance
-
equals
-
hashCode
public int hashCode() -
toString
-
floatValue
public float floatValue()- Specified by:
floatValuein classCOSNumber- Returns:
- The float value of this object.
-
doubleValue
public double doubleValue()- Specified by:
doubleValuein classCOSNumber- Returns:
- The double value of this number.
-
intValue
public int intValue() -
longValue
public long longValue() -
accept
Description copied from class:COSBaseVisitor pattern for the COS model objects- Specified by:
acceptin classCOSBase- Throws:
IOException
-