Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

utf8transliterator.h

00001 /*
00002  *
00003  * Copyright 2001 CrossWire Bible Society (http://www.crosswire.org)
00004  *      CrossWire Bible Society
00005  *      P. O. Box 2528
00006  *      Tempe, AZ  85280-2528
00007  *
00008  * This program is free software; you can redistribute it and/or modify it
00009  * under the terms of the GNU General Public License as published by the
00010  * Free Software Foundation version 2.
00011  *
00012  * This program is distributed in the hope that it will be useful, but
00013  * WITHOUT ANY WARRANTY; without even the implied warranty of
00014  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00015  * General Public License for more details.
00016  *
00017  */
00018 #ifdef _ICU_
00019 
00020 #ifndef UTF8TRANSLITERATOR_H
00021 #define UTF8TRANSLITERATOR_H
00022 
00023 enum scriptEnum {SE_OFF, SE_LATIN, /*one-way (to) transliterators*/ SE_BASICLATIN, SE_BETA, SE_BGREEK, /*two-way transliterators*/ SE_GREEK, SE_HEBREW, SE_CYRILLIC, SE_ARABIC, SE_SYRIAC, SE_KATAKANA, SE_HIRAGANA, SE_JAMO, SE_HANGUL, SE_DEVANAGARI, SE_TAMIL, SE_BENGALI, SE_GURMUKHI, SE_GUJARATI, SE_ORIYA, SE_TELUGU, SE_KANNADA, SE_MALAYALAM, SE_THAI, SE_GEORGIAN, SE_ARMENIAN, SE_ETHIOPIC, SE_GOTHIC, SE_UGARITIC, SE_COPTIC, /*one-way (from) transliterators*/ SE_HAN, SE_KANJI};
00024 #define NUMSCRIPTS 32
00025 #define NUMTARGETSCRIPTS 5
00026 
00027 #include <swfilter.h>
00028 #include <swmodule.h>
00029 
00030 #include <unicode/utypes.h>
00031 #include <unicode/ucnv.h>
00032 #include <unicode/ustring.h>
00033 #include <unicode/uchar.h>
00034 
00035 #include <unicode/unistr.h>
00036 #include <unicode/translit.h>
00037 
00038 #include <defs.h>
00039 
00042 class SWDLLEXPORT UTF8Transliterator : public SWFilter
00043 {
00044   char option;
00045 
00046   static const char optionstring[NUMTARGETSCRIPTS][16];
00047 
00048   static const char optName[];
00049   static const char optTip[];
00050   OptionsList options;
00051 
00052  public:
00053   UTF8Transliterator ();
00054   virtual char ProcessText (char *text, int maxlen, const SWKey * key, const SWModule * = 0);
00055   virtual const char *getOptionName ()
00056     {
00057       return optName;
00058     }
00059   virtual const char *getOptionTip ()
00060     {
00061       return optTip;
00062     }
00063   virtual void setOptionValue (const char *ival);
00064   virtual const char *getOptionValue ();
00065   virtual OptionsList getOptionValues ()
00066     {
00067       return options;
00068     }
00069 };
00070 
00071 #endif
00072 
00073 #endif

Generated at Tue Jan 22 14:52:49 2002 for The Sword Project by doxygen1.2.9.1 written by Dimitri van Heesch, © 1997-2001