Package org.verapdf.pd.font.cmap
Class IdentityCMap
- java.lang.Object
-
- org.verapdf.pd.font.cmap.CMap
-
- org.verapdf.pd.font.cmap.IdentityCMap
-
public class IdentityCMap extends CMap
Class represents identity CMap.- Author:
- Sergey Shemyakov
-
-
Constructor Summary
Constructors Constructor Description IdentityCMap(String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontainsCode(int character)intgetCodeFromStream(InputStream stream)Reads character code from input stream and returnes it's CID.StringgetOrdering()StringgetRegistry()intgetSupplement()StringgetUnicode(int code)Returns Unicode sequence for given character code.inttoCID(int character)Gets CID for given character.-
Methods inherited from class org.verapdf.pd.font.cmap.CMap
getCidMappings, getName, getwMode, isUsesNonPredefinedCMap, setSupplement, setUsesNonPredefinedCMap, useCMap
-
-
-
-
Constructor Detail
-
IdentityCMap
public IdentityCMap(String name)
-
-
Method Detail
-
toCID
public int toCID(int character)
Description copied from class:CMapGets CID for given character.
-
containsCode
public boolean containsCode(int character)
- Overrides:
containsCodein classCMap- Returns:
- true if this CMap can convert given code to CID.
-
getCodeFromStream
public int getCodeFromStream(InputStream stream) throws IOException
Description copied from class:CMapReads character code from input stream and returnes it's CID. This uses codespace information from CMap. Details are described in PDF32000 in 9.7.6.2 "CMap Mapping".- Overrides:
getCodeFromStreamin classCMap- Parameters:
stream- is stream from which character codes will be read.- Returns:
- CID of read code.
- Throws:
IOException
-
getRegistry
public String getRegistry()
- Overrides:
getRegistryin classCMap- Returns:
- Registry value from CIDSystemInfo dictionary.
-
getOrdering
public String getOrdering()
- Overrides:
getOrderingin classCMap- Returns:
- Ordering value from CIDSystemInfo dictionary.
-
getSupplement
public int getSupplement()
- Overrides:
getSupplementin classCMap- Returns:
- supplement of CMap.
-
getUnicode
public String getUnicode(int code)
Description copied from class:CMapReturns Unicode sequence for given character code.- Overrides:
getUnicodein classCMap- Parameters:
code- is code of character.- Returns:
- Unicode sequence obtained from this CMap.
-
-