\Smalot\PdfParserHeader

Class Header

Summary

Methods
Properties
Constants
__construct()
getElements()
getElementTypes()
getDetails()
has()
get()
parse()
No public properties found
No constants found
resolveXRef()
$document
$elements
N/A
No private methods found
No private properties found
N/A

Properties

$elements

$elements : \Smalot\PdfParser\Element[]

Type

\Smalot\PdfParser\Element[]

Methods

__construct()

__construct(\Smalot\PdfParser\Element[] $elements, \Smalot\PdfParser\Document $document)

Parameters

\Smalot\PdfParser\Element[] $elements

List of elements.

\Smalot\PdfParser\Document $document

Document.

getElements()

getElements() : mixed

Returns all elements.

Returns

mixed

getElementTypes()

getElementTypes() : array

Used only for debug.

Returns

array

getDetails()

getDetails(bool $deep) : array

Parameters

bool $deep

Returns

array

has()

has(string $name) : bool

Indicate if an element name is available in header.

Parameters

string $name

The name of the element

Returns

bool

get()

get(string $name) : \Smalot\PdfParser\Element|Object

Parameters

string $name

Returns

\Smalot\PdfParser\Element|Object

parse()

parse(string $content, \Smalot\PdfParser\Document $document, int $position) : \Smalot\PdfParser\Header

Parameters

string $content

The content to parse

\Smalot\PdfParser\Document $document

The document

int $position

The new position of the cursor after parsing

Returns

\Smalot\PdfParser\Header

resolveXRef()

resolveXRef(string $name) : \Smalot\PdfParser\Element|Object

Resolve XRef to object.

Parameters

string $name

Throws

\Exception

Returns

\Smalot\PdfParser\Element|Object