org.apache.fontbox.cff.encoding
Class CFFEncoding

java.lang.Object
  extended by org.apache.fontbox.cff.encoding.CFFEncoding
Direct Known Subclasses:
CFFExpertEncoding, CFFStandardEncoding

public abstract class CFFEncoding
extends java.lang.Object

This is the superclass for all CFFFont encodings.

Version:
$Revision$
Author:
Villu Russmann

Constructor Summary
CFFEncoding()
           
 
Method Summary
 int getCode(int sid)
          Returns the code corresponding to the given SID.
 java.util.Iterator<java.lang.Integer> getCodes()
          Returns an iterator for all codes of this encoding.
 int getSID(int code)
          Returns the SID corresponding to the given code.
 boolean isFontSpecific()
          Determines if the encoding is font specific or not.
 void register(int code, int sid)
          Adds a new code/SID combination to the encoding.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CFFEncoding

public CFFEncoding()
Method Detail

isFontSpecific

public boolean isFontSpecific()
Determines if the encoding is font specific or not.

Returns:
if the encoding is font specific

getCode

public int getCode(int sid)
Returns the code corresponding to the given SID.

Parameters:
sid - the given SID
Returns:
the corresponding code

getSID

public int getSID(int code)
Returns the SID corresponding to the given code.

Parameters:
code - the given code
Returns:
the corresponding SID

register

public void register(int code,
                     int sid)
Adds a new code/SID combination to the encoding.

Parameters:
code - the given code
sid - the given SID

getCodes

public java.util.Iterator<java.lang.Integer> getCodes()
Returns an iterator for all codes of this encoding.

Returns:
the iterator for all codes of this encoding


Copyright © 2008-2011 Apache Software Foundation. All Rights Reserved.