summaryrefslogtreecommitdiff
path: root/i18npool
diff options
context:
space:
mode:
authorRĂ¼diger Timm <rt@openoffice.org>2004-01-20 12:18:27 +0000
committerRĂ¼diger Timm <rt@openoffice.org>2004-01-20 12:18:27 +0000
commitb91b4de06ff88e69843691e6f1c55c0e0a03b336 (patch)
tree97c93ae193a0f382f54c35d405641de17db33e9b /i18npool
parent2859f89baf8c1bcdddd9e152010863e0c6d9eb12 (diff)
INTEGRATION: CWS i18n10 (1.3.54); FILE MERGED
2003/12/17 20:08:41 khong 1.3.54.1: #i22138# #112506# migrate to ICU collator and remove link to tool library
Diffstat (limited to 'i18npool')
-rw-r--r--i18npool/inc/collator_unicode.hxx39
1 files changed, 30 insertions, 9 deletions
diff --git a/i18npool/inc/collator_unicode.hxx b/i18npool/inc/collator_unicode.hxx
index ba65c49bafca..75baa2f68f55 100644
--- a/i18npool/inc/collator_unicode.hxx
+++ b/i18npool/inc/collator_unicode.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: collator_unicode.hxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: rt $ $Date: 2003-04-08 15:43:32 $
+ * last change: $Author: rt $ $Date: 2004-01-20 13:18:27 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -63,8 +63,8 @@
#include <com/sun/star/uno/Reference.h>
#include <com/sun/star/i18n/XCollator.hpp>
-#include <com/sun/star/i18n/TransliterationModules.hpp>
#include <cppuhelper/implbase1.hxx>
+#include <unicode/tblcoll.h>
// ----------------------------------------------------
// class Collator_Unicode
@@ -80,13 +80,13 @@ public:
// Destructor
~Collator_Unicode();
- virtual sal_Int32 SAL_CALL compareSubstring( const rtl::OUString& s1, sal_Int32 off1, sal_Int32 len1,
+ sal_Int32 SAL_CALL compareSubstring( const rtl::OUString& s1, sal_Int32 off1, sal_Int32 len1,
const rtl::OUString& s2, sal_Int32 off2, sal_Int32 len2) throw(com::sun::star::uno::RuntimeException);
- virtual sal_Int32 SAL_CALL compareString( const rtl::OUString& s1, const rtl::OUString& s2)
+ sal_Int32 SAL_CALL compareString( const rtl::OUString& s1, const rtl::OUString& s2)
throw(com::sun::star::uno::RuntimeException);
- virtual sal_Int32 SAL_CALL loadCollatorAlgorithm( const rtl::OUString& impl, const lang::Locale& rLocale,
+ sal_Int32 SAL_CALL loadCollatorAlgorithm( const rtl::OUString& impl, const lang::Locale& rLocale,
sal_Int32 collatorOptions) throw(com::sun::star::uno::RuntimeException);
@@ -106,11 +106,32 @@ public:
virtual com::sun::star::uno::Sequence< rtl::OUString > SAL_CALL getSupportedServiceNames() throw( com::sun::star::uno::RuntimeException );
protected:
- sal_Char *implementationName;
- com::sun::star::lang::Locale aLocale;
- TransliterationModules tranModules;
+ const sal_Char *implementationName;
+ const sal_uInt8 *rulesImage;
+private:
+ RuleBasedCollator *collator;
};
+#define COLLATOR( algorithm ) \
+class Collator_##algorithm : public Collator_Unicode {\
+public:\
+ Collator_##algorithm(); \
+};
+
+COLLATOR( zh_pinyin )
+COLLATOR( zh_radical )
+COLLATOR( zh_stroke )
+COLLATOR( zh_charset )
+COLLATOR( zh_zhuyin )
+COLLATOR( zh_TW_radical )
+COLLATOR( zh_TW_stroke )
+COLLATOR( zh_TW_charset )
+COLLATOR( ko_dict )
+COLLATOR( ko_charset )
+COLLATOR( ja_charset )
+COLLATOR( ja_phonetic_alphanumeric_first )
+COLLATOR( ja_phonetic_alphanumeric_last )
+#undef COLLATOR
} } } }
#endif