diff options
Diffstat (limited to 'doc/api-documentation/html/utf8transliterator_8h-source.html')
-rw-r--r-- | doc/api-documentation/html/utf8transliterator_8h-source.html | 171 |
1 files changed, 98 insertions, 73 deletions
diff --git a/doc/api-documentation/html/utf8transliterator_8h-source.html b/doc/api-documentation/html/utf8transliterator_8h-source.html index 4b377f1..d859019 100644 --- a/doc/api-documentation/html/utf8transliterator_8h-source.html +++ b/doc/api-documentation/html/utf8transliterator_8h-source.html @@ -3,83 +3,108 @@ <title>utf8transliterator.h Source File</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head><body> -<!-- Generated by Doxygen 1.2.15 --> +<!-- Generated by Doxygen 1.2.17 --> <center> -<a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="namespaces.html">Namespace List</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Compound Members</a> </center> -<hr><h1>utf8transliterator.h</h1><div class="fragment"><pre>00001 <font class="comment">/*</font> -00002 <font class="comment"> *</font> -00003 <font class="comment"> * Copyright 2001 CrossWire Bible Society (http://www.crosswire.org)</font> -00004 <font class="comment"> * CrossWire Bible Society</font> -00005 <font class="comment"> * P. O. Box 2528</font> -00006 <font class="comment"> * Tempe, AZ 85280-2528</font> -00007 <font class="comment"> *</font> -00008 <font class="comment"> * This program is free software; you can redistribute it and/or modify it</font> -00009 <font class="comment"> * under the terms of the GNU General Public License as published by the</font> -00010 <font class="comment"> * Free Software Foundation version 2.</font> -00011 <font class="comment"> *</font> -00012 <font class="comment"> * This program is distributed in the hope that it will be useful, but</font> -00013 <font class="comment"> * WITHOUT ANY WARRANTY; without even the implied warranty of</font> -00014 <font class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</font> -00015 <font class="comment"> * General Public License for more details.</font> -00016 <font class="comment"> *</font> -00017 <font class="comment"> */</font> -00018 <font class="preprocessor">#ifdef _ICU_</font> -00019 <font class="preprocessor"></font> -00020 <font class="preprocessor">#ifndef UTF8TRANSLITERATOR_H</font> -00021 <font class="preprocessor"></font><font class="preprocessor">#define UTF8TRANSLITERATOR_H</font> -00022 <font class="preprocessor"></font> -00023 <font class="keyword">enum</font> scriptEnum {SE_OFF, SE_LATIN, <font class="comment">/*one-way (to) transliterators*/</font> SE_BASICLATIN, SE_BETA, SE_BGREEK, <font class="comment">/*two-way transliterators*/</font> 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, <font class="comment">/*one-way (from) transliterators*/</font> SE_HAN, SE_KANJI}; -00024 <font class="preprocessor">#define NUMSCRIPTS 32</font> -00025 <font class="preprocessor"></font><font class="preprocessor">#define NUMTARGETSCRIPTS 5</font> -00026 <font class="preprocessor"></font> -00027 <font class="preprocessor">#include <swfilter.h></font> -00028 <font class="preprocessor">#include <swmodule.h></font> -00029 -00030 <font class="preprocessor">#include <unicode/utypes.h></font> -00031 <font class="preprocessor">#include <unicode/ucnv.h></font> -00032 <font class="preprocessor">#include <unicode/ustring.h></font> -00033 <font class="preprocessor">#include <unicode/uchar.h></font> -00034 -00035 <font class="preprocessor">#include <unicode/unistr.h></font> -00036 <font class="preprocessor">#include <unicode/translit.h></font> -00037 -00038 <font class="preprocessor">#include <defs.h></font> +<a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="namespaces.html">Namespace List</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="namespacemembers.html">Namespace Members</a> <a class="qindex" href="functions.html">Compound Members</a> </center> +<hr><h1>utf8transliterator.h</h1><div class="fragment"><pre>00001 <span class="comment">/*</span> +00002 <span class="comment"> *</span> +00003 <span class="comment"> * Copyright 2001 CrossWire Bible Society (http://www.crosswire.org)</span> +00004 <span class="comment"> * CrossWire Bible Society</span> +00005 <span class="comment"> * P. O. Box 2528</span> +00006 <span class="comment"> * Tempe, AZ 85280-2528</span> +00007 <span class="comment"> *</span> +00008 <span class="comment"> * This program is free software; you can redistribute it and/or modify it</span> +00009 <span class="comment"> * under the terms of the GNU General Public License as published by the</span> +00010 <span class="comment"> * Free Software Foundation version 2.</span> +00011 <span class="comment"> *</span> +00012 <span class="comment"> * This program is distributed in the hope that it will be useful, but</span> +00013 <span class="comment"> * WITHOUT ANY WARRANTY; without even the implied warranty of</span> +00014 <span class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</span> +00015 <span class="comment"> * General Public License for more details.</span> +00016 <span class="comment"> *</span> +00017 <span class="comment"> */</span> +00018 +00019 <span class="preprocessor">#ifndef UTF8TRANSLITERATOR_H</span> +00020 <span class="preprocessor"></span><span class="preprocessor">#define UTF8TRANSLITERATOR_H</span> +00021 <span class="preprocessor"></span> +00022 <span class="keyword">enum</span> scriptEnum {SE_OFF, SE_LATIN, <span class="comment">/*one-way (to) transliterators*/</span> SE_BASICLATIN, SE_BETA, SE_BGREEK, <span class="comment">/*two-way transliterators*/</span> 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, <span class="comment">/*one-way (from) transliterators*/</span> SE_HAN, SE_KANJI}; +00023 <span class="preprocessor">#define NUMSCRIPTS 32</span> +00024 <span class="preprocessor"></span><span class="preprocessor">#define NUMTARGETSCRIPTS 5</span> +00025 <span class="preprocessor"></span> +00026 <span class="preprocessor">#include <swfilter.h></span> +00027 <span class="preprocessor">#include <swmodule.h></span> +00028 +00029 <span class="comment">//#include <unicode/utypes.h></span> +00030 <span class="comment">//#include <unicode/ucnv.h></span> +00031 <span class="comment">//#include <unicode/ustring.h></span> +00032 <span class="comment">//#include <unicode/uchar.h></span> +00033 +00034 <span class="preprocessor">#include <unicode/unistr.h></span> +00035 <span class="preprocessor">#include <unicode/translit.h></span> +00036 +00037 <span class="preprocessor">#include <defs.h></span> +00038 <span class="preprocessor">#include <map></span> 00039 -00042 <font class="keyword">class </font>SWDLLEXPORT UTF8Transliterator : <font class="keyword">public</font> SWFilter -00043 { -00044 <font class="keywordtype">char</font> option; -00045 -00046 <font class="keyword">static</font> <font class="keyword">const</font> <font class="keywordtype">char</font> optionstring[NUMTARGETSCRIPTS][16]; -00047 -00048 <font class="keyword">static</font> <font class="keyword">const</font> <font class="keywordtype">char</font> optName[]; -00049 <font class="keyword">static</font> <font class="keyword">const</font> <font class="keywordtype">char</font> optTip[]; -00050 OptionsList options; +00040 +00041 <span class="comment">//class UnicodeString;</span> +00042 +00043 SWORD_NAMESPACE_START +00044 +00045 <span class="keyword">struct </span>SWTransData { +00046 UnicodeString resource; +00047 UTransDirection dir; +00048 }; +00049 <span class="keyword">typedef</span> std::map <const UnicodeString, SWTransData> SWTransMap; +00050 <span class="keyword">typedef</span> std::pair<UnicodeString, SWTransData> SWTransPair; 00051 -00052 <font class="keyword">public</font>: -00053 UTF8Transliterator (); -00054 <font class="keyword">virtual</font> <font class="keywordtype">char</font> ProcessText (<font class="keywordtype">char</font> *text, <font class="keywordtype">int</font> maxlen, <font class="keyword">const</font> <a class="code" href="class_s_w_key.html">SWKey</a> * key, <font class="keyword">const</font> <a class="code" href="class_s_w_module.html">SWModule</a> * = 0); -00055 <font class="keyword">virtual</font> <font class="keyword">const</font> <font class="keywordtype">char</font> *getOptionName () -00056 { -00057 <font class="keywordflow">return</font> optName; -00058 } -00059 <font class="keyword">virtual</font> <font class="keyword">const</font> <font class="keywordtype">char</font> *getOptionTip () -00060 { -00061 <font class="keywordflow">return</font> optTip; -00062 } -00063 <font class="keyword">virtual</font> <font class="keywordtype">void</font> setOptionValue (<font class="keyword">const</font> <font class="keywordtype">char</font> *ival); -00064 <font class="keyword">virtual</font> <font class="keyword">const</font> <font class="keywordtype">char</font> *getOptionValue (); -00065 <font class="keyword">virtual</font> OptionsList getOptionValues () -00066 { -00067 <font class="keywordflow">return</font> options; -00068 } -00069 }; -00070 -00071 <font class="preprocessor">#endif</font> -00072 <font class="preprocessor"></font> -00073 <font class="preprocessor">#endif</font> -</pre></div><hr><address align="right"><small>Generated on Thu Jun 20 22:13:01 2002 for The Sword Project by +<a name="l00054"></a><a class="code" href="classsword_1_1_u_t_f8_transliterator.html">00054</a> <span class="keyword">class </span>SWDLLEXPORT <a class="code" href="classsword_1_1_u_t_f8_transliterator.html">UTF8Transliterator</a> : <span class="keyword">public</span> SWFilter +00055 { +00056 <span class="keyword">private</span>: +00057 +00058 <span class="keywordtype">char</span> option; +00059 +00060 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">char</span> optionstring[NUMTARGETSCRIPTS][16]; +00061 +00062 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">char</span> optName[]; +00063 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">char</span> optTip[]; +00064 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">char</span> SW_RB_RULE_BASED_IDS[]; +00065 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">char</span> SW_RB_RULE[]; +00066 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">char</span> SW_RESDATA[]; +00067 <a class="code" href="namespacesword.html#a82">OptionsList</a> options; +00068 <span class="keyword">static</span> SWTransMap transMap; +00069 UErrorCode utf8status; +00070 +00071 <span class="keywordtype">void</span> Load(UErrorCode &status); +00072 <span class="keywordtype">void</span> registerTrans(<span class="keyword">const</span> UnicodeString& ID, <span class="keyword">const</span> UnicodeString& resource, +00073 UTransDirection dir, UErrorCode &status ); +00074 <span class="keywordtype">bool</span> checkTrans(<span class="keyword">const</span> UnicodeString& ID, UErrorCode &status ); +00075 Transliterator * createTrans(<span class="keyword">const</span> UnicodeString& preID, <span class="keyword">const</span> UnicodeString& ID, +00076 <span class="keyword">const</span> UnicodeString& postID, UTransDirection dir, UErrorCode &status ); +00077 +00078 <span class="keyword">public</span>: +00079 <a class="code" href="classsword_1_1_u_t_f8_transliterator.html">UTF8Transliterator</a> (); +00080 <span class="keyword">virtual</span> <span class="keywordtype">char</span> ProcessText (<span class="keywordtype">char</span> *text, <span class="keywordtype">int</span> maxlen, <span class="keyword">const</span> <a class="code" href="classsword_1_1_s_w_key.html">SWKey</a> * key, <span class="keyword">const</span> <a class="code" href="classsword_1_1_s_w_module.html">SWModule</a> * = 0); +00081 <span class="keyword">virtual</span> <span class="keyword">const</span> <span class="keywordtype">char</span> *getOptionName () +00082 { +00083 <span class="keywordflow">return</span> optName; +00084 } +00085 <span class="keyword">virtual</span> <span class="keyword">const</span> <span class="keywordtype">char</span> *getOptionTip () +00086 { +00087 <span class="keywordflow">return</span> optTip; +00088 } +00089 <span class="keyword">virtual</span> <span class="keywordtype">void</span> setOptionValue (<span class="keyword">const</span> <span class="keywordtype">char</span> *ival); +00090 <span class="keyword">virtual</span> <span class="keyword">const</span> <span class="keywordtype">char</span> *getOptionValue (); +00091 <span class="keyword">virtual</span> <a class="code" href="namespacesword.html#a82">OptionsList</a> getOptionValues () +00092 { +00093 <span class="keywordflow">return</span> options; +00094 } +00095 }; +00096 +00097 SWORD_NAMESPACE_END +00098 <span class="preprocessor">#endif</span> +</pre></div><hr><address style="align: right;"><small>Generated on Thu Oct 31 12:11:28 2002 for The Sword Project by <a href="http://www.doxygen.org/index.html"> <img src="doxygen.png" alt="doxygen" align="middle" border=0 -width=110 height=53></a>1.2.15 </small></address> +width=110 height=53></a>1.2.17 </small></address> </body> </html> |