|
Rakesh API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rakeshv.tex.ISOToTeX
public final class ISOToTeX
Implements a HashMap that maps accentuated
ISO character entities to their
LATEX
equivalents.
See ISO Character Entities for a full description of the character entities.
Copyright © 2002 Rakesh Vidyadharan
| Field Summary | |
|---|---|
static boolean |
DO_NULL_CHECK
Specify that you wish to get back the input character as a String equivalent, if no match is found in the
HashMap. |
private static java.util.Map |
map
The HashMap that holds the character mappings. |
| Constructor Summary | |
|---|---|
ISOToTeX()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
convertString(java.lang.String inString)
Convert all ISO 8859-1 encoded non-ASCII characters to appropriate LATEX tags, and return the modified String object. |
static java.lang.String |
convertString(java.lang.String inString,
java.lang.String encoding)
Converts the input String in the specified
character encoding to ISO 8859-1
encoding, and then invokes convertString( String ). |
static java.lang.String |
getTeXEquivalent(char input)
Returns the LATEX equivalent for the specified char. |
static java.lang.String |
getTeXEquivalent(char input,
boolean checkFlag)
Returns the LATEX equivalent for the specified char. |
private void |
ISOToTeX()
Private constructor. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static java.util.Map map
HashMap that holds the character mappings.
public static final boolean DO_NULL_CHECK
String equivalent, if no match is found in the
HashMap.
| Constructor Detail |
|---|
public ISOToTeX()
| Method Detail |
|---|
private void ISOToTeX()
public static java.lang.String getTeXEquivalent(char input)
Returns the
LATEX
equivalent for the specified char.
If the input character equivalent is not found, this
method returns null. You will have to check
the return value, and take appropriate action.
input - - The character that is to be transformed.
public static java.lang.String getTeXEquivalent(char input,
boolean checkFlag)
Returns the
LATEX
equivalent for the specified char.
If the input character equivalent is not found, and
checkFlag is specified as DO_NULL_CHECK,
then, a String representation of the input
character is returned.
input - - The character that is to be transformed.checkFlag - - Specify that checking for existence
of ASCII equivalent should be done in the method or not. To
enable checking, specify DO_NULL_CHECK.
public static java.lang.String convertString(java.lang.String inString)
Convert all ISO 8859-1 encoded non-ASCII characters to
appropriate LATEX tags, and return the
modified String object.
inString - - The String object that is to be modified.
public static java.lang.String convertString(java.lang.String inString,
java.lang.String encoding)
Converts the input String in the specified
character encoding to ISO 8859-1
encoding, and then invokes convertString( String ).
inString - - The String object in Windows Cp1252 format
that is to be converted.encoding - - The character encoding of input string.
|
Rakesh API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||