Package com.itextpdf.io.font.cmap
Class CMapByteCid
java.lang.Object
com.itextpdf.io.font.cmap.AbstractCMap
com.itextpdf.io.font.cmap.CMapByteCid
Maps variable-length character codes to CID values.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classTracks the unread portion of a byte sequence during CID decoding. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondecodeSequence(byte[] cidBytes, int offset, int length) Decode byte sequence.protected intdecodeSingle(byte[] cidBytes, CMapByteCid.Cursor cursor) Decodes one CID and advances the supplied cursor.Methods inherited from class com.itextpdf.io.font.cmap.AbstractCMap
decodeStringToByte, getName, getOrdering, getRegistry, getSupplement, toUnicodeString
-
Constructor Details
-
CMapByteCid
public CMapByteCid()Creates an empty byte code to CID map.
-
-
Method Details
-
decodeSequence
Decode byte sequence.- Parameters:
-
cidBytes- byteCodeBytes -
offset- number of bytes to skip before starting to return chars from the sequence -
length- number of bytes to process - Returns:
- string that contains decoded representation of the given sequence
-
decodeSingle
Decodes one CID and advances the supplied cursor.- Parameters:
-
cidBytes- the source byte array -
cursor- the mutable segment cursor to advance - Returns:
-
the decoded CID, or
-1when the segment ends before a complete CID
-