MCPcopy Create free account
hub / github.com/LibPDF-js/core / parse

Method parse

src/parser/object-stream-parser.ts:91–101  ·  view source on GitHub ↗

* Decompress and parse the stream index. * Called automatically by getObject/getAllObjects if needed.

()

Source from the content-addressed store, hash-verified

89 * Called automatically by getObject/getAllObjects if needed.
90 */
91 parse(): void {
92 if (this.index !== null) {
93 return; // Already parsed
94 }
95
96 // Decompress stream data
97 this.decodedData = this.stream.getDecodedData();
98
99 // Parse the index (N pairs of integers before /First)
100 this.index = this.parseIndex();
101 }
102
103 /**
104 * Parse the index section of the object stream.

Callers 3

getObjectMethod · 0.95
getAllObjectsMethod · 0.95

Calls 2

parseIndexMethod · 0.95
getDecodedDataMethod · 0.80

Tested by

no test coverage detected