HexaPDF::Tokenizer
Inherits Reference < Object
Tokenizes the content of an IO object following the PDF rules.
See: PDF1.7 s7.2
Constructors
Instance methods
next_object(allow_end_array_token = false, allow_keyword = false)
Returns the PDF object at the current position. This is different from #next_token because references, arrays and dictionaries consist of multiple tokens.
If +allow_end_array_token+ is +true+, the ']' token is permitted to facilitate the use of this method during array parsing.
If +allow_keyword+ is +true+, the return value may also be a Token instance. See: PDF1.7 s7.3
next_token
Returns a single token read from the current position and advances the position.
Comments and a run of whitespace characters are ignored. A Token of type +:NO_MORE_TOKENS+ is returned if there are no more tokens available.