Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Differences Between: [Versions 310 and 400] [Versions 39 and 400] [Versions 400 and 403]

This file is part of FPDI

Copyright: Copyright (c) 2020 Setasign GmbH & Co. KG (https://www.setasign.com)
License: http://opensource.org/licenses/mit-license The MIT License
File Size: 199 lines (6 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

FixedReader:: (5 methods):
  __construct()
  getSubSections()
  getOffsetFor()
  read()
  fixFaultySubSectionShift()


Class: FixedReader  - X-Ref

Class FixedReader

This reader allows a very less overhead parsing of single entries of the cross-reference, because the main entries
are only read when needed and not in a single run.
__construct(PdfParser $parser)   X-Ref
FixedReader constructor.

param: PdfParser $parser

getSubSections()   X-Ref
Get all subsection data.

return: array

getOffsetFor($objectNumber)   X-Ref


read()   X-Ref
Read the cross-reference.

This reader will only read the subsections in this method. The offsets were resolved individually by this
information.


fixFaultySubSectionShift()   X-Ref
Fixes an invalid object number shift.

This method can be used to repair documents with an invalid subsection header:

<code>
xref
1 7
0000000000 65535 f
0000000009 00000 n
0000412075 00000 n
0000412172 00000 n
0000412359 00000 n
0000412417 00000 n
0000412468 00000 n
</code>

It shall only be called on the first table.

return: bool