Class PDF::Reader::Parser
In: lib/pdf/reader/parser.rb
Parent: Object

An internal PDF::Reader class that reads objects from the PDF file and converts them into useable ruby objects (hash‘s, arrays, true, false, etc)

Methods

array   dictionary   hex_string   new   object   parse_token   stream   string  

Public Class methods

Create a new parser around a PDF::Reader::Buffer object

buffer - a PDF::Reader::Buffer object that contains PDF data xref - a PDF::Reader::XRef object that represents the document‘s object offsets

Public Instance methods

reads a PDF array from the buffer and converts it to a Ruby Array.

reads a PDF dict from the buffer and converts it to a Ruby Hash.

Reads a PDF hex string from the buffer and converts it to a Ruby String

Reads an entire PDF object from the buffer and returns it as a Ruby String. If the object is a content stream, returns both the stream and the dictionary that describes it

id - the object ID to return gen - the object revision number to return

Reads the next token from the underlying buffer and convets it to an appropriate object

operators - a hash of supported operators to read from the underlying buffer.

Decodes the contents of a PDF Stream and returns it as a Ruby String.

Reads a PDF String from the buffer and converts it to a Ruby String

[Validate]