org.jqurantree.arabic.encoding
Class EncodingTableBase

java.lang.Object
  extended by org.jqurantree.arabic.encoding.EncodingTableBase

public abstract class EncodingTableBase
extends java.lang.Object

EncodingTableBase provides a common implementation for tables used by table-driven encoders and decoders of ArabicText.

Author:
Kais Dukes

Constructor Summary
protected EncodingTableBase()
          Creates a new encoding table instance.
 
Method Summary
protected  void addItem(UnicodeType unicodeType, char ch, CharacterType characterType)
          Adds an Arabic character to the table.
protected  void addItem(UnicodeType unicodeType, char ch, CharacterType characterType, DiacriticType diacriticType)
          Adds an Arabic character with an attached diacritic to the table.
protected  void addItem(UnicodeType unicodeType, char ch, DiacriticType diacriticType)
          Adds a diacritic to the table.
 char getCharacter(CharacterType characterType)
          Gets an output character in the table by Arabic character type.
 char getCharacter(UnicodeType unicodeType)
          Gets an output character in the table by Unicode character type.
 org.jqurantree.arabic.encoding.EncodingTableItem getItem(char unicode)
          Gets an item in the table by Unicode character.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EncodingTableBase

protected EncodingTableBase()
Creates a new encoding table instance.

Method Detail

getItem

public org.jqurantree.arabic.encoding.EncodingTableItem getItem(char unicode)
Gets an item in the table by Unicode character.

Parameters:
unicode - the Unicode character
Returns:
the encoding table item

getCharacter

public char getCharacter(CharacterType characterType)
Gets an output character in the table by Arabic character type.

Parameters:
characterType - the type of Arabic character
Returns:
the output character in the table

getCharacter

public char getCharacter(UnicodeType unicodeType)
Gets an output character in the table by Unicode character type.

Parameters:
unicodeType - the type of Unicode character
Returns:
the output character in the table

addItem

protected void addItem(UnicodeType unicodeType,
                       char ch,
                       CharacterType characterType)
Adds an Arabic character to the table.

Parameters:
unicodeType - the type of Unicode character
ch - the output character
characterType - the type of Arabic character

addItem

protected void addItem(UnicodeType unicodeType,
                       char ch,
                       DiacriticType diacriticType)
Adds a diacritic to the table.

Parameters:
unicodeType - the type of Unicode character
ch - the output character
diacriticType - the type of diacritic

addItem

protected void addItem(UnicodeType unicodeType,
                       char ch,
                       CharacterType characterType,
                       DiacriticType diacriticType)
Adds an Arabic character with an attached diacritic to the table.

Parameters:
unicodeType - the type of Unicode character
ch - the output character
characterType - the type of Arabic character
diacriticType - the type of diacritic


Copyright© Kais Dukes, 2009. All Rights Reserved.