public class CMapParser extends Object
Modifier and Type | Class and Description |
---|---|
private class |
CMapParser.LiteralName
Internal class.
|
private class |
CMapParser.Operator
Internal class.
|
Modifier and Type | Field and Description |
---|---|
private static String |
BEGIN_BASE_FONT_CHAR |
private static String |
BEGIN_BASE_FONT_RANGE |
private static String |
BEGIN_CODESPACE_RANGE |
private static String |
MARK_END_OF_ARRAY |
private static String |
MARK_END_OF_DICTIONARY |
private byte[] |
tokenParserByteBuffer |
Constructor and Description |
---|
CMapParser()
Creates a new instance of CMapParser.
|
Modifier and Type | Method and Description |
---|---|
private int |
compare(byte[] first,
byte[] second) |
private String |
createStringFromBytes(byte[] bytes) |
private void |
increment(byte[] data) |
private void |
increment(byte[] data,
int position) |
private boolean |
isWhitespaceOrEOF(int aByte) |
CMap |
parse(InputStream input)
This will parse the stream and create a cmap object.
|
private Object |
parseNextToken(PushbackInputStream is) |
private void |
readUntilEndOfLine(InputStream is,
StringBuffer buf) |
private static final String BEGIN_CODESPACE_RANGE
private static final String BEGIN_BASE_FONT_CHAR
private static final String BEGIN_BASE_FONT_RANGE
private static final String MARK_END_OF_DICTIONARY
private static final String MARK_END_OF_ARRAY
private byte[] tokenParserByteBuffer
public CMapParser()
public CMap parse(InputStream input) throws IOException
input
- The CMAP stream to parse.IOException
- If there is an error parsing the stream.private Object parseNextToken(PushbackInputStream is) throws IOException
IOException
private void readUntilEndOfLine(InputStream is, StringBuffer buf) throws IOException
IOException
private boolean isWhitespaceOrEOF(int aByte)
private void increment(byte[] data)
private void increment(byte[] data, int position)
private String createStringFromBytes(byte[] bytes) throws IOException
IOException
private int compare(byte[] first, byte[] second)
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses