Class CosToken
- java.lang.Object
 - 
- com.adobe.internal.pdftoolkit.core.cos.CosToken
 
 
- 
public final class CosToken extends java.lang.ObjectThe PDF parser. 
- 
- 
Field Summary
Fields Modifier and Type Field Description static java.math.BigDecimalMAX_REALstatic java.math.BigDecimalMIN_FLOAT_APPROACHING_TO_ZERO 
- 
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidskipObject(CosDocument doc, InputByteStream buf, byte b)This method tokenizes the document stream to reach the position where object definition is completed.static byteskipWhitespace(InputByteStream buf)Skips over whitespace in the input stream.static bytetoHexDigit(byte b)Converts the specified hexidecimal character to a byte value. 
 - 
 
- 
- 
Method Detail
- 
toHexDigit
public static byte toHexDigit(byte b) throws PDFCosParseExceptionConverts the specified hexidecimal character to a byte value. For example, the hex character 'A' is converted to the value 10.- Parameters:
 b- Hex character to convert- Returns:
 - Byte value corresponding to the specified hex character.
 - Throws:
 PDFCosParseException
 
- 
skipWhitespace
public static byte skipWhitespace(InputByteStream buf) throws java.io.IOException, PDFCosParseException
Skips over whitespace in the input stream. Whitespace is defined in section 3.1.1 of the PDF Reference Manual version 1.4. For the purposes of this method, comments are also considered whitespace.- Parameters:
 buf- Buffer to parse- Returns:
 - The first non-whitespace byte encountered.
 - Throws:
 java.io.IOExceptionPDFCosParseException
 
- 
skipObject
public static void skipObject(CosDocument doc, InputByteStream buf, byte b) throws PDFCosParseException, java.io.IOException, PDFSecurityException, PDFIOException
This method tokenizes the document stream to reach the position where object definition is completed.- Parameters:
 doc- Document containing the COS objectbuf- Buffer to skipb- Starting byte- Throws:
 PDFCosParseExceptionjava.io.IOExceptionPDFSecurityExceptionPDFIOExceptionPDFIOException
 
 - 
 
 -