public class PDFStreamParser extends BaseParser
A, ASCII_CR, ASCII_LF, ASCII_SPACE, B, D, DEF, document, E, ENDOBJ_STRING, ENDSTREAM_STRING, J, M, N, O, pdfSource, PROP_PUSHBACK_SIZE, R, S, STREAM_STRING, T, validationParsing| Constructor and Description |
|---|
PDFStreamParser(COSStream stream)
Constructor.
|
PDFStreamParser(COSStream stream,
boolean validationParsing)
Constructor.
|
PDFStreamParser(PDStream stream)
Constructor.
|
PDFStreamParser(RandomAccessRead input)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Iterator<Object> |
getTokenIterator()
This will get an iterator which can be used to parse the stream
one token after the other.
|
List<Object> |
getTokens()
This will get the tokens that were parsed from the stream.
|
void |
parse()
This will parse the tokens in the stream.
|
Object |
parseNextToken()
This will parse the next token in the stream.
|
protected String |
readOperator()
This will read an operator from the stream.
|
isClosing, isClosing, isDigit, isDigit, isEndOfName, isEOL, isEOL, isSpace, isSpace, isWhitespace, isWhitespace, parseBoolean, parseCOSArray, parseCOSDictionary, parseCOSName, parseCOSString, parseDirObject, readExpectedChar, readExpectedString, readExpectedString, readGenerationNumber, readInt, readLine, readLineWithoutWhitespacesSkip, readLong, readObjectNumber, readString, readString, readStringNumber, skipSpaces, skipWhiteSpacespublic PDFStreamParser(PDStream stream) throws IOException
stream - The stream to parse.IOException - If there is an error initializing the stream.public PDFStreamParser(COSStream stream) throws IOException
stream - The stream to parse.IOException - If there is an error initializing the stream.public PDFStreamParser(COSStream stream, boolean validationParsing) throws IOException
stream - The stream to parse.validationParsing - flag to parse according to pdfa validationIOException - If there is an error initializing the stream.public PDFStreamParser(RandomAccessRead input) throws IOException
input - The random access read to parse.IOException - If there is an error initializing the stream.public void parse()
throws IOException
IOException - If there is an error while parsing the stream.public List<Object> getTokens()
public Iterator<Object> getTokenIterator()
public Object parseNextToken() throws IOException
IOException - If an io error occurs while parsing the stream.protected String readOperator() throws IOException
IOException - If there is an error reading from the stream.Copyright © 2015–2021 The veraPDF Consortium. All rights reserved.