PdfArray
extends PdfType
in package
Class representing a PDF array object
Table of Contents
Properties
- $value : array<string|int, mixed>
- The value of the PDF type.
Methods
- create() : self
- Helper method to create an instance.
- ensure() : self
- Ensures that the passed array is a PdfArray instance with a (optional) specific size.
- flatten() : PdfType
- Flatten indirect object references to direct objects.
- parse() : false|self
- Parses an array of the passed tokenizer and parser.
- 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
array<string|int, mixed>
$value
The value of the PDF type.
Methods
create()
Helper method to create an instance.
public
static create([array<string|int, PdfType> $values = [] ]) : self
Parameters
- $values : array<string|int, PdfType> = []
Return values
selfensure()
Ensures that the passed array is a PdfArray instance with a (optional) specific size.
public
static ensure(mixed $array[, null|int $size = null ]) : self
Parameters
- $array : mixed
- $size : null|int = null
Tags
Return values
selfflatten()
Flatten indirect object references to direct objects.
public
static flatten(PdfType $value, PdfParser $parser) : PdfType
Parameters
Tags
Return values
PdfTypeparse()
Parses an array of the passed tokenizer and parser.
public
static parse(Tokenizer $tokenizer, PdfParser $parser) : false|self
Parameters
Tags
Return values
false|selfresolve()
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