Package org.verapdf.parser
Class NotSeekableCOSParser
- java.lang.Object
-
- org.verapdf.parser.NotSeekableBaseParser
-
- org.verapdf.parser.NotSeekableCOSParser
-
- All Implemented Interfaces:
Closeable,AutoCloseable
- Direct Known Subclasses:
PDFStreamParser,PSParser
public class NotSeekableCOSParser extends NotSeekableBaseParser
Parser for COS objects that operates with a buffered stream. The seek() operation of stream is not required.- Author:
- Sergey Shemyakov
-
-
Field Summary
Fields Modifier and Type Field Description protected COSDocumentdocumentprotected booleanflagprotected Queue<Long>integersprotected COSKeykeyOfCurrentObjectprotected Queue<COSObject>objects-
Fields inherited from class org.verapdf.parser.NotSeekableBaseParser
isPSParser, source
-
-
Constructor Summary
Constructors Constructor Description NotSeekableCOSParser(ASInputStream stream)NotSeekableCOSParser(ASInputStream stream, boolean isPSParser)NotSeekableCOSParser(ASInputStream stream, COSDocument document)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected COSObjectgetArray()protected COSObjectgetCloseDictionary()protected COSObjectgetDictionary()protected COSObjectgetName()COSObjectnextObject()Gets next object from the source.-
Methods inherited from class org.verapdf.parser.NotSeekableBaseParser
close, extendArray, findKeyword, findKeyword, getLineBytes, getToken, initializeToken, isCR, isDigit, isDigit, isEndOfComment, isFF, isLF, nextToken, readLine, readNumber, readUntilDelimiter, skipSpaces, skipSpaces, skipStreamSpaces
-
-
-
-
Constructor Detail
-
NotSeekableCOSParser
public NotSeekableCOSParser(ASInputStream stream) throws IOException
- Throws:
IOException
-
NotSeekableCOSParser
public NotSeekableCOSParser(ASInputStream stream, boolean isPSParser) throws IOException
- Throws:
IOException
-
NotSeekableCOSParser
public NotSeekableCOSParser(ASInputStream stream, COSDocument document) throws IOException
- Throws:
IOException
-
-
Method Detail
-
nextObject
public COSObject nextObject() throws IOException
Gets next object from the source.- Returns:
- next COSObject.
- Throws:
IOException
-
getArray
protected COSObject getArray() throws IOException
- Throws:
IOException
-
getName
protected COSObject getName() throws IOException
- Throws:
IOException
-
getCloseDictionary
protected COSObject getCloseDictionary()
-
getDictionary
protected COSObject getDictionary() throws IOException
- Throws:
IOException
-
-