public class ToMapUnicodeToAscii extends Transformation implements java.lang.Cloneable
Users may define their own mapping in $LVG/data/Unicode/unicodeMap.data.
History:
NO_MUTATE_INFO, UPDATE| Constructor and Description |
|---|
ToMapUnicodeToAscii() |
| Modifier and Type | Method and Description |
|---|---|
static java.util.Hashtable<java.lang.Character,java.lang.String> |
GetUnicodeMapFromFile(Configuration config)
Read in unicode to ASCII mapping list from configuration file
|
static void |
main(java.lang.String[] args)
A unit test driver for this flow component.
|
static java.lang.String |
MapUnicodeToAscii(char inChar,
java.util.Hashtable<java.lang.Character,java.lang.String> unicodeMap)
Get unicode synonym
|
static java.util.Vector<LexItem> |
Mutate(LexItem in,
java.util.Hashtable<java.lang.Character,java.lang.String> unicodeMap,
boolean detailsFlag,
boolean mutateFlag)
Performs the mutation of this flow component.
|
GetTestStr, PrintResult, PrintResults, UpdateLexItem, UpdateLexItem, UpdateLexItempublic static java.util.Vector<LexItem> Mutate(LexItem in, java.util.Hashtable<java.lang.Character,java.lang.String> unicodeMap, boolean detailsFlag, boolean mutateFlag)
in - a LexItem as the input for this flow componentunicodeMap - a hash table contains the unicode mappingdetailsFlag - a boolean flag for processing details informationmutateFlag - a boolean flag for processing mutate informationpublic static java.util.Hashtable<java.lang.Character,java.lang.String> GetUnicodeMapFromFile(Configuration config)
config - Configuratin objectpublic static java.lang.String MapUnicodeToAscii(char inChar,
java.util.Hashtable<java.lang.Character,java.lang.String> unicodeMap)
inChar - an input characterunicodeMap - a hash table contains the unicodepublic static void main(java.lang.String[] args)
Submit a bug or feature
Copyright © 2013 National Library of Medicine