Moodle PHP Documentation 5.1
Moodle 5.1dev (Build: 20250530) (c39b7370636)
PdfArray Class Reference
Inheritance diagram for PdfArray:
PdfType

Static Public Member Functions

static create (array $values=[])
 Helper method to create an instance.
 
static ensure ($array, $size=null)
 Ensures that the passed array is a PdfArray instance with a (optional) specific size.
 
static flatten (PdfType $value, PdfParser $parser)
 Flatten indirect object references to direct objects.
 
static parse (Tokenizer $tokenizer, PdfParser $parser)
 Parses an array of the passed tokenizer and parser.
 
static resolve (PdfType $value, PdfParser $parser, $stopAtIndirectObject=false)
 Resolves a PdfType value to its value.
 

Public Attributes

mixed $value
 The value of the PDF type.
 

Static Protected Member Functions

static ensureType ($type, $value, $errorMessage)
 Ensure that a value is an instance of a specific PDF type.
 

Member Function Documentation

◆ create()

static PdfArray::create ( array $values = [])
static

Helper method to create an instance.

Parameters
PdfType[]$values
Return values
self

◆ ensure()

static PdfArray::ensure ( $array,
$size = null )
static

Ensures that the passed array is a PdfArray instance with a (optional) specific size.

Parameters
mixed$array
null | int$size
Return values
self
Exceptions
PdfTypeException

◆ ensureType()

static PdfType::ensureType ( $type,
$value,
$errorMessage )
staticprotectedinherited

Ensure that a value is an instance of a specific PDF type.

Parameters
string$type
PdfType$value
string$errorMessage
Return values
mixed
Exceptions
PdfTypeException

◆ flatten()

static PdfType::flatten ( PdfType $value,
PdfParser $parser )
staticinherited

Flatten indirect object references to direct objects.

Parameters
PdfType$value
PdfParser$parser
Return values
PdfType
Exceptions
CrossReferenceException
PdfParserException

◆ parse()

static PdfArray::parse ( Tokenizer $tokenizer,
PdfParser $parser )
static

Parses an array of the passed tokenizer and parser.

Parameters
Tokenizer$tokenizer
PdfParser$parser
Return values
false|self
Exceptions
PdfTypeException

◆ resolve()

static PdfType::resolve ( PdfType $value,
PdfParser $parser,
$stopAtIndirectObject = false )
staticinherited

Resolves a PdfType value to its value.

This method is used to evaluate indirect and direct object references until a final value is reached.

Parameters
PdfType$value
PdfParser$parser
bool$stopAtIndirectObject
Return values
PdfType
Exceptions
CrossReferenceException
PdfParserException

The documentation for this class was generated from the following file: