setasign\FpdiPdfParser\PdfParser\CrossReference
CrossReference Class CrossReference
File: /FPDI PDF-Parser v2/PdfParser/CrossReference/CrossReference.php
This class also supports reading of compressed cross-references and object streams.
Class hierarchy
- setasign\Fpdi\PdfParser\CrossReference\CrossReference
Summary
Static Properties
$trailerSearchLength
-
The byte length in which the "startxref" keyword should be searched.
Properties
$fileHeaderOffset
-
$readers
-
Methods
__construct()
CrossReference constructor.
Parameters
- $parser : \setasign\FpdiPdfParser\PdfParser\PdfParser
- $fileHeaderOffset : int
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
Throws \setasign\Fpdi\PdfParser\Type\PdfTypeException
checkForEncryption()
Bypass check for encryption and handle this afterwards
Parameters
- $dictionary : \setasign\Fpdi\PdfParser\Type\PdfDictionary
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
findStartXref()
-
Find the start position for the first cross-reference.
Return Values
The byte-offset position of the first cross-reference.
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
getIndirectObject()
Get an indirect object by its object number.
Parameters
- $objectNumber : int
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
Throws \setasign\Fpdi\PdfParser\Filter\FilterException
Throws \setasign\Fpdi\PdfParser\PdfParserException
getOffsetFor()
Get the offset by an object number.
Parameters
- $objectNumber : int
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
Throws \setasign\Fpdi\PdfParser\PdfParserException
Throws \setasign\Fpdi\PdfParser\Type\PdfTypeException
getReaders()
-
Get the cross reference readser instances.
getSize()
-
Get the size of the cross reference.
getTrailer()
-
Get the trailer dictionary.
initReaderInstance()
Get a cross-reference reader instance.
Parameters
- $initValue : \setasign\Fpdi\PdfParser\Type\PdfToken|\setasign\Fpdi\PdfParser\Type\PdfIndirectObject
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
Throws \setasign\Fpdi\PdfParser\PdfParserException
Throws \setasign\Fpdi\PdfParser\Type\PdfTypeException
readXref()
-
Read the cross-reference table at a given offset.
Internally the method will try to evaluate the best reader for this cross-reference.
Parameters
- $offset : int
Exceptions
Throws \setasign\Fpdi\PdfParser\CrossReference\CrossReferenceException
Throws \setasign\Fpdi\PdfParser\Type\PdfTypeException