| <HTML><HEAD><TITLE>Xalan-C++ API Documentation</TITLE></HEAD>
|
| <BODY>
|
| <h2 align="center">Xalan-C++ API Documentation</h2>
|
| <h3 align="center">The Xalan C++ XSLT Processor Version 1.10</h3>
|
| </BODY> |
| <!-- Generated by Doxygen 1.2.8.1 --> |
| <center> |
| <a class="qindex" href="index.html">Main Page</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> <a class="qindex" href="globals.html">File Members</a> </center> |
| <hr><h1>ICUBridgeCollationCompareFunctorImpl.hpp</h1><a href="ICUBridgeCollationCompareFunctorImpl_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <font class="comment">/*</font> |
| 00002 <font class="comment"> * Copyright 1999-2004 The Apache Software Foundation.</font> |
| 00003 <font class="comment"> *</font> |
| 00004 <font class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</font> |
| 00005 <font class="comment"> * you may not use this file except in compliance with the License.</font> |
| 00006 <font class="comment"> * You may obtain a copy of the License at</font> |
| 00007 <font class="comment"> *</font> |
| 00008 <font class="comment"> * http://www.apache.org/licenses/LICENSE-2.0</font> |
| 00009 <font class="comment"> *</font> |
| 00010 <font class="comment"> * Unless required by applicable law or agreed to in writing, software</font> |
| 00011 <font class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</font> |
| 00012 <font class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</font> |
| 00013 <font class="comment"> * See the License for the specific language governing permissions and</font> |
| 00014 <font class="comment"> * limitations under the License.</font> |
| 00015 <font class="comment"> */</font> |
| 00016 |
| 00017 <font class="preprocessor">#if !defined(ICUBRIDGE_COLLATIONCOMPAREFUNCTORIMPL_GUARD_1357924680)</font> |
| <a name="l00018"></a><a class="code" href="ICUBridgeCollationCompareFunctorImpl_8hpp.html#a0">00018</a> <font class="preprocessor"></font><font class="preprocessor">#define ICUBRIDGE_COLLATIONCOMPAREFUNCTORIMPL_GUARD_1357924680</font> |
| 00019 <font class="preprocessor"></font> |
| 00020 |
| 00021 |
| 00022 <font class="preprocessor">#include <<a class="code" href="ICUBridgeDefinitions_8hpp.html">xalanc/ICUBridge/ICUBridgeDefinitions.hpp</a>></font> |
| 00023 |
| 00024 |
| 00025 |
| 00026 <font class="preprocessor">#include <<a class="code" href="XalanList_8hpp.html">xalanc/Include/XalanList.hpp</a>></font> |
| 00027 |
| 00028 |
| 00029 |
| 00030 <font class="preprocessor">#include <<a class="code" href="StylesheetExecutionContextDefault_8hpp.html">xalanc/XSLT/StylesheetExecutionContextDefault.hpp</a>></font> |
| 00031 |
| 00032 |
| 00033 |
| 00034 <font class="preprocessor">#include <unicode/coll.h></font> |
| 00035 |
| 00036 |
| 00037 |
| 00038 |
| 00039 XALAN_CPP_NAMESPACE_BEGIN |
| 00040 |
| 00041 |
| 00042 <font class="preprocessor">#if defined(XALAN_HAS_CPP_NAMESPACE)</font> |
| 00043 <font class="preprocessor"></font><font class="keyword">typedef</font> U_ICU_NAMESPACE::Collator CollatorType; |
| 00044 <font class="preprocessor">#else</font> |
| <a name="l00045"></a><a class="code" href="ICUBridgeCollationCompareFunctorImpl_8hpp.html#a1">00045</a> <font class="preprocessor"></font><font class="keyword">typedef</font> Collator CollatorType; |
| 00046 <font class="preprocessor">#endif</font> |
| 00047 <font class="preprocessor"></font> |
| <a name="l00048"></a><a class="code" href="structCollationCacheStruct.html">00048</a> <font class="keyword">struct </font><a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a> |
| 00049 { |
| <a name="l00050"></a><a class="code" href="structCollationCacheStruct.html#a0">00050</a> <a class="code" href="structCollationCacheStruct.html#a0">CollationCacheStruct</a>( |
| 00051 MemoryManagerType& theManager, |
| 00052 <font class="keyword">const</font> <a class="code" href="classXalanDOMString.html">XalanDOMString</a>& theLocale, |
| 00053 CollatorType* theCollator) : |
| 00054 m_locale(theLocale, theManager), |
| 00055 m_collator(theCollator) |
| 00056 { |
| 00057 } |
| 00058 |
| <a name="l00059"></a><a class="code" href="structCollationCacheStruct.html#a1">00059</a> <a class="code" href="structCollationCacheStruct.html#a0">CollationCacheStruct</a>(MemoryManagerType& theManager) : |
| 00060 m_locale(theManager), |
| 00061 m_collator(0) |
| 00062 { |
| 00063 } |
| 00064 |
| <a name="l00065"></a><a class="code" href="structCollationCacheStruct.html#a2">00065</a> <a class="code" href="structCollationCacheStruct.html#a0">CollationCacheStruct</a>( <font class="keyword">const</font> <a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>& other, |
| 00066 MemoryManagerType& theManager) : |
| 00067 m_locale(other.m_locale,theManager), |
| 00068 m_collator(other.m_collator) |
| 00069 { |
| 00070 } |
| 00071 <font class="keywordtype">void</font> |
| <a name="l00072"></a><a class="code" href="structCollationCacheStruct.html#a3">00072</a> <a class="code" href="structCollationCacheStruct.html#a3">swap</a>(<a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>& theOther)<font class="keyword"></font> |
| 00073 <font class="keyword"> </font>{ |
| 00074 m_locale.<a class="code" href="classXalanDOMString.html#a35">swap</a>(theOther.m_locale); |
| 00075 |
| 00076 CollatorType* <font class="keyword">const</font> theTemp = m_collator; |
| 00077 |
| 00078 m_collator = theOther.m_collator; |
| 00079 |
| 00080 theOther.m_collator = theTemp; |
| 00081 } |
| 00082 |
| 00083 <font class="preprocessor">#if defined(XALAN_NO_SELECTIVE_TEMPLATE_INSTANTIATION)</font> |
| 00084 <font class="preprocessor"></font> <font class="keywordtype">bool</font> |
| 00085 <a class="code" href="ElemAttributeSet_8hpp.html#a2">operator<</a>(<font class="keyword">const</font> <a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>& theRHS)<font class="keyword"> const</font> |
| 00086 <font class="keyword"> </font>{ |
| 00087 <font class="keywordflow">return</font> <font class="keyword">this</font> < &theRHS; |
| 00088 } |
| 00089 |
| 00090 <font class="keywordtype">bool</font> |
| 00091 <a class="code" href="ElemAttributeSet_8hpp.html#a1">operator==</a>(<font class="keyword">const</font> <a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>& theRHS)<font class="keyword"> const</font> |
| 00092 <font class="keyword"> </font>{ |
| 00093 <font class="keywordflow">return</font> <font class="keyword">this</font> == &theRHS; |
| 00094 } |
| 00095 <font class="preprocessor">#endif</font> |
| 00096 <font class="preprocessor"></font> |
| <a name="l00097"></a><a class="code" href="structCollationCacheStruct.html#m0">00097</a> <a class="code" href="classXalanDOMString.html">XalanDOMString</a> m_locale; |
| 00098 |
| <a name="l00099"></a><a class="code" href="structCollationCacheStruct.html#m1">00099</a> CollatorType* m_collator; |
| 00100 |
| <a name="l00101"></a><a class="code" href="structCollationCacheStruct_1_1CollatorDeleteFunctor.html">00101</a> <font class="keyword">struct </font>CollatorDeleteFunctor |
| 00102 { |
| <a name="l00103"></a><a class="code" href="structCollationCacheStruct_1_1CollatorDeleteFunctor.html#a0">00103</a> <a class="code" href="structCollationCacheStruct_1_1CollatorDeleteFunctor.html#a0">CollatorDeleteFunctor</a>(MemoryManagerType& theManager): |
| 00104 m_memoryManager(theManager) |
| 00105 { |
| 00106 } |
| 00107 |
| 00108 <font class="keywordtype">void</font> |
| <a name="l00109"></a><a class="code" href="structCollationCacheStruct_1_1CollatorDeleteFunctor.html#a1">00109</a> <a class="code" href="structCollationCacheStruct_1_1CollatorDeleteFunctor.html#a1">operator()</a>(<a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>& theStruct)<font class="keyword"> const</font> |
| 00110 <font class="keyword"> </font>{ |
| 00111 <font class="keyword">delete</font> theStruct.m_collator; |
| 00112 } |
| 00113 <font class="keyword">private</font>: |
| 00114 MemoryManagerType& m_memoryManager; |
| 00115 }; |
| 00116 |
| <a name="l00117"></a><a class="code" href="structCollationCacheStruct_1_1CollatorFindFunctor.html">00117</a> <font class="keyword">struct </font>CollatorFindFunctor |
| 00118 { |
| <a name="l00119"></a><a class="code" href="structCollationCacheStruct_1_1CollatorFindFunctor.html#a0">00119</a> <a class="code" href="structCollationCacheStruct_1_1CollatorFindFunctor.html#a0">CollatorFindFunctor</a>(<font class="keyword">const</font> XalanDOMChar* theLocale) : |
| 00120 m_locale(theLocale) |
| 00121 { |
| 00122 } |
| 00123 |
| 00124 <font class="keywordtype">bool</font> |
| <a name="l00125"></a><a class="code" href="structCollationCacheStruct_1_1CollatorFindFunctor.html#a1">00125</a> <a class="code" href="structCollationCacheStruct_1_1CollatorFindFunctor.html#a1">operator()</a>(<a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>& theStruct)<font class="keyword"> const</font> |
| 00126 <font class="keyword"> </font>{ |
| 00127 <font class="keywordflow">return</font> <a class="code" href="classXalanDOMString.html#d0">XalanDOMString::equals</a>(theStruct.m_locale ,m_locale); |
| 00128 } |
| 00129 |
| <a name="l00130"></a><a class="code" href="structCollationCacheStruct_1_1CollatorFindFunctor.html#m0">00130</a> <font class="keyword">const</font> XalanDOMChar* <font class="keyword">const</font> m_locale; |
| 00131 }; |
| 00132 }; |
| 00133 |
| <a name="l00134"></a><a class="code" href="ICUBridgeCollationCompareFunctorImpl_8hpp.html#a2">00134</a> <a class="code" href="XalanMemoryManagement_8hpp.html#a4">XALAN_USES_MEMORY_MANAGER</a>(<a class="code" href="structCollationCacheStruct.html">CollationCacheStruct</a>) |
| 00135 |
| 00136 <font class="keyword">class </font>XALAN_ICUBRIDGE_EXPORT ICUBridgeCollationCompareFunctorImpl : <font class="keyword">public</font> <a class="code" href="classXalanCollationServices.html">XalanCollationServices</a>::CollationCompareFunctor |
| 00137 { |
| 00138 <font class="keyword">public</font>: |
| 00139 |
| 00145 <a class="code" href="ICUBridgeCollationCompareFunctor_8hpp.html#a1">ICUBridgeCollationCompareFunctorImpl</a>( MemoryManagerType& theManager , |
| 00146 <font class="keywordtype">bool</font> fCacheCollators = <font class="keyword">false</font>); |
| 00147 |
| 00148 <font class="keyword">static</font> ICUBridgeCollationCompareFunctorImpl* |
| 00149 create( MemoryManagerType& theManager, |
| 00150 <font class="keywordtype">bool</font> fCacheCollators = <font class="keyword">false</font>); |
| 00151 |
| 00152 |
| 00153 ~ICUBridgeCollationCompareFunctorImpl(); |
| 00154 |
| 00155 MemoryManagerType& |
| 00156 getMemoryManager()<font class="keyword">const</font> |
| 00157 { |
| 00158 <font class="keywordflow">return</font> m_collatorCache.getMemoryManager(); |
| 00159 } |
| 00160 |
| 00161 <font class="keywordtype">int</font> |
| 00162 operator()( |
| 00163 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00164 <font class="keyword">const</font> XalanDOMChar* theRHS, |
| 00165 XalanCollationServices::eCaseOrder theCaseOrder = XalanCollationServices::eDefault) <font class="keyword">const</font>; |
| 00166 |
| 00167 <font class="keywordtype">int</font> |
| 00168 operator()( |
| 00169 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00170 <font class="keyword">const</font> XalanDOMChar* theRHS, |
| 00171 <font class="keyword">const</font> XalanDOMChar* theLocale, |
| 00172 XalanCollationServices::eCaseOrder theCaseOrder = XalanCollationServices::eDefault) <font class="keyword">const</font>; |
| 00173 |
| 00174 <font class="keywordtype">bool</font> |
| 00175 isValid()<font class="keyword"> const</font> |
| 00176 <font class="keyword"> </font>{ |
| 00177 <font class="keywordflow">return</font> m_isValid; |
| 00178 } |
| 00179 |
| 00180 |
| 00181 <font class="keyword">typedef</font> <a class="code" href="classXalanList.html">XalanList<CollationCacheStruct></a> CollatorCacheListType; |
| 00182 |
| 00183 <font class="keyword">enum</font> { eCacheMax = 10 }; |
| 00184 |
| 00185 <font class="keyword">private</font>: |
| 00186 |
| 00187 <font class="keywordtype">int</font> |
| 00188 doDefaultCompare( |
| 00189 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00190 <font class="keyword">const</font> XalanDOMChar* theRHS) <font class="keyword">const</font>; |
| 00191 |
| 00192 <font class="keywordtype">int</font> |
| 00193 doCompare( |
| 00194 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00195 <font class="keyword">const</font> XalanDOMChar* theRHS, |
| 00196 <font class="keyword">const</font> XalanDOMChar* theLocale, |
| 00197 XalanCollationServices::eCaseOrder theCaseOrder) <font class="keyword">const</font>; |
| 00198 |
| 00199 <font class="keywordtype">int</font> |
| 00200 doCompareCached( |
| 00201 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00202 <font class="keyword">const</font> XalanDOMChar* theRHS, |
| 00203 <font class="keyword">const</font> XalanDOMChar* theLocale, |
| 00204 XalanCollationServices::eCaseOrder theCaseOrder) <font class="keyword">const</font>; |
| 00205 |
| 00206 <font class="keywordtype">int</font> |
| 00207 doCompare( |
| 00208 <font class="keyword">const</font> CollatorType& theCollator, |
| 00209 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00210 <font class="keyword">const</font> XalanDOMChar* theRHS) <font class="keyword">const</font>; |
| 00211 |
| 00212 <font class="keywordtype">int</font> |
| 00213 doCompare( |
| 00214 CollatorType& theCollator, |
| 00215 <font class="keyword">const</font> XalanDOMChar* theLHS, |
| 00216 <font class="keyword">const</font> XalanDOMChar* theRHS, |
| 00217 XalanCollationServices::eCaseOrder theCaseOrder) <font class="keyword">const</font>; |
| 00218 |
| 00219 CollatorType* |
| 00220 getCachedCollator(<font class="keyword">const</font> XalanDOMChar* theLocale) <font class="keyword">const</font>; |
| 00221 |
| 00222 <font class="keywordtype">void</font> |
| 00223 cacheCollator( |
| 00224 CollatorType* theCollator, |
| 00225 <font class="keyword">const</font> XalanDOMChar* theLocale) <font class="keyword">const</font>; |
| 00226 |
| 00227 |
| 00228 <font class="comment">// Data members...</font> |
| 00229 <font class="keywordtype">bool</font> m_isValid; |
| 00230 |
| 00231 CollatorType* m_defaultCollator; |
| 00232 |
| 00233 <a class="code" href="classXalanDOMString.html">XalanDOMString</a> m_defaultCollatorLocaleName; |
| 00234 |
| 00235 <font class="keywordtype">bool</font> m_cacheCollators; |
| 00236 |
| 00237 <font class="keyword">mutable</font> CollatorCacheListType m_collatorCache; |
| 00238 |
| 00239 <font class="keyword">static</font> <font class="keyword">const</font> StylesheetExecutionContextDefault::DefaultCollationCompareFunctor s_defaultFunctor; |
| 00240 }; |
| 00241 |
| 00242 |
| 00243 |
| 00244 XALAN_CPP_NAMESPACE_END |
| 00245 |
| 00246 |
| 00247 |
| 00248 <font class="preprocessor">#endif // ICUBRIDGE_COLLATIONCOMPAREFUNCTORIMPL_GUARD_1357924680</font> |
| </font></pre></div><p align="center"><a href="diagramnotes.html">Interpreting class diagrams</a></p>
|
| <p><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
|
| <i><A href="http://www.stack.nl/~dimitri/doxygen/">Doxygen</A> and
|
| <A href="http://www.research.att.com/sw/tools/graphviz/">GraphViz</A> are used to generate this API documentation from the Xalan-C header files.</I></FONT></p>
|
|
|
| <TABLE border="0" cellpadding="0" cellspacing="0" width="820"><TR><TD bgcolor="#0086b2"><IMG height="1" src="../resources/dot.gif" width="1" alt="dot"></TD></TR></TABLE>
|
| <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTH="80%">
|
| <TR>
|
| <TD WIDTH="80%" VALIGN="TOP">
|
| <P ALIGN="CENTER"><B>Xalan-C++ XSLT Processor Version 1.10</B><BR>
|
| Copyright © 1999-2004 The Apache Software Foundation. All Rights Reserved.</i></p>
|
| </TD>
|
| </TR>
|
| <TR>
|
| <TD WIDTH="100%">
|
| <P ALIGN="CENTER"><IMG SRC="ApacheLogo.jpg" WIDTH="387" HEIGHT="100" ALIGN="BOTTOM" BORDER="0" ALT="Apache Logo">
|
| </TD>
|
| </TR>
|
| </TABLE>
|