PdfNumeric
extends PdfType
in package
Class representing a numeric PDF object
Table of Contents
Properties
- $value : mixed
- The value of the PDF type.
Methods
- create() : PdfNumeric
- Helper method to create an instance.
- ensure() : self
- Ensures that the passed value is a PdfNumeric instance.
- flatten() : PdfType
- Flatten indirect object references to direct objects.
- resolve() : PdfType
- Resolves a PdfType value to its value.
- ensureType() : mixed
- Ensure that a value is an instance of a specific PDF type.
Properties
$value
The value of the PDF type.
public
mixed
$value
Methods
create()
Helper method to create an instance.
public
static create(int|float $value) : PdfNumeric
Parameters
- $value : int|float
Return values
PdfNumericensure()
Ensures that the passed value is a PdfNumeric instance.
public
static ensure(mixed $value) : self
Parameters
- $value : mixed
Tags
Return values
selfflatten()
Flatten indirect object references to direct objects.
public
static flatten(PdfType $value, PdfParser $parser) : PdfType
Parameters
Tags
Return values
PdfTyperesolve()
Resolves a PdfType value to its value.
public
static resolve(PdfType $value, PdfParser $parser[, bool $stopAtIndirectObject = false ][, array<string|int, mixed> &$ensuredObjectsList = [] ]) : PdfType
This method is used to evaluate indirect and direct object references until a final value is reached.
Parameters
- $value : PdfType
- $parser : PdfParser
- $stopAtIndirectObject : bool = false
- $ensuredObjectsList : array<string|int, mixed> = []
-
A list of all ensured indirect objects to prevent recursion
Tags
Return values
PdfTypeensureType()
Ensure that a value is an instance of a specific PDF type.
protected
static ensureType(string $type, PdfType $value, string $errorMessage) : mixed
Parameters
- $type : string
- $value : PdfType
- $errorMessage : string