LineReader
extends AbstractReader
in package
implements
ReaderInterface
Class LineReader
This reader class read all cross-reference entries in a single run. It supports reading cross-references with e.g. invalid data (e.g. entries with a length < or > 20 bytes).
Table of Contents
Interfaces
- ReaderInterface
- ReaderInterface for cross-reference readers.
Properties
- $offsets : array<string|int, mixed>
- The object offsets.
- $parser : PdfParser
- $trailer : PdfDictionary
Methods
- __construct() : mixed
- LineReader constructor.
- getOffsetFor() : int|false
- Get an offset by an object number.
- getOffsets() : array<string|int, mixed>
- Get all found offsets.
- getTrailer() : PdfDictionary
- Get the trailer dictionary.
- extract() : string
- Extracts the cross reference data from the stream reader.
- read() : mixed
- Read the cross-reference entries.
- readTrailer() : mixed
- Read the trailer dictionary.
Properties
$offsets
The object offsets.
protected
array<string|int, mixed>
$offsets
$parser
protected
PdfParser
$parser
$trailer
protected
PdfDictionary
$trailer
Methods
__construct()
LineReader constructor.
public
__construct(PdfParser $parser) : mixed
Parameters
- $parser : PdfParser
Tags
getOffsetFor()
Get an offset by an object number.
public
getOffsetFor(mixed $objectNumber) : int|false
Parameters
- $objectNumber : mixed
Tags
Return values
int|falsegetOffsets()
Get all found offsets.
public
getOffsets() : array<string|int, mixed>
Return values
array<string|int, mixed>getTrailer()
Get the trailer dictionary.
public
getTrailer() : PdfDictionary
Return values
PdfDictionaryextract()
Extracts the cross reference data from the stream reader.
protected
extract(StreamReader $reader) : string
Parameters
- $reader : StreamReader
Tags
Return values
stringread()
Read the cross-reference entries.
protected
read(string $xrefContent) : mixed
Parameters
- $xrefContent : string
Tags
readTrailer()
Read the trailer dictionary.
protected
readTrailer() : mixed