]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/i18n/csrsbcs.h
ICU-511.35.tar.gz
[apple/icu.git] / icuSources / i18n / csrsbcs.h
index 21cbabe5663b54c4612d2dd3d6fe4ede2d790580..cc26b057b48754796b5e309132fd779db5db0020 100644 (file)
@@ -1,6 +1,6 @@
 /*
  **********************************************************************
- *   Copyright (C) 2005-2009, International Business Machines
+ *   Copyright (C) 2005-2012, International Business Machines
  *   Corporation and others.  All Rights Reserved.
  **********************************************************************
  */
@@ -46,44 +46,37 @@ public:
 
 };
 
+
 class CharsetRecog_sbcs : public CharsetRecognizer
 {
-protected:
-    UBool haveC1Bytes;
-
 public:
     CharsetRecog_sbcs();
-
     virtual ~CharsetRecog_sbcs();
-
     virtual const char *getName() const = 0;
-
-    virtual int32_t match(InputText *det) = 0;
-
-    int32_t match_sbcs(InputText *det, const int32_t ngrams[], const uint8_t charMap[]);
+    virtual UBool match(InputText *det, CharsetMatch *results) const = 0;
+    virtual int32_t match_sbcs(InputText *det, const int32_t ngrams[], const uint8_t charMap[]) const;
 };
 
 class CharsetRecog_8859_1 : public CharsetRecog_sbcs
 {
 public:
     virtual ~CharsetRecog_8859_1();
-
     const char *getName() const;
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_2 : public CharsetRecog_sbcs
 {
 public:
     virtual ~CharsetRecog_8859_2();
-
     const char *getName() const;
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_5 : public CharsetRecog_sbcs
 {
 public:
     virtual ~CharsetRecog_8859_5();
-
     const char *getName() const;
 };
 
@@ -119,145 +112,7 @@ public:
     const char *getName() const;
 };
 
-class CharsetRecog_8859_1_en : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_en();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_da : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_da();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_de : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_de();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_es : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_es();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_fr : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_fr();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_it : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_it();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_nl : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_nl();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_no : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_no();
-
-    const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_pt : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_pt();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_1_sv : public CharsetRecog_8859_1
-{
-public:
-    virtual ~CharsetRecog_8859_1_sv();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_2_cs : public CharsetRecog_8859_2
-{
-public:
-    virtual ~CharsetRecog_8859_2_cs();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_2_hu : public CharsetRecog_8859_2
-{
-public:
-    virtual ~CharsetRecog_8859_2_hu();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_2_pl : public CharsetRecog_8859_2
-{
-public:
-    virtual ~CharsetRecog_8859_2_pl();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
-
-class CharsetRecog_8859_2_ro : public CharsetRecog_8859_2
-{
-public:
-    virtual ~CharsetRecog_8859_2_ro();
-
-    const char *getLanguage() const;
-
-    int32_t match(InputText *textIn);
-};
 
 class CharsetRecog_8859_5_ru : public CharsetRecog_8859_5
 {
@@ -266,7 +121,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_6_ar : public CharsetRecog_8859_6
@@ -276,7 +131,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_7_el : public CharsetRecog_8859_7
@@ -286,7 +141,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_8_I_he : public CharsetRecog_8859_8
@@ -298,7 +153,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_8_he : public CharsetRecog_8859_8
@@ -308,7 +163,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_8859_9_tr : public CharsetRecog_8859_9
@@ -318,7 +173,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_windows_1256 : public CharsetRecog_sbcs
@@ -330,7 +185,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_windows_1251 : public CharsetRecog_sbcs
@@ -342,7 +197,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 
@@ -355,7 +210,7 @@ public:
 
     const char *getLanguage() const;
 
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_IBM424_he : public CharsetRecog_sbcs
@@ -372,7 +227,7 @@ public:
     
     const char *getName() const;
     
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_IBM424_he_ltr : public CharsetRecog_IBM424_he {
@@ -380,7 +235,7 @@ class CharsetRecog_IBM424_he_ltr : public CharsetRecog_IBM424_he {
     
     const char *getName() const;
     
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_IBM420_ar : public CharsetRecog_sbcs
@@ -410,7 +265,7 @@ public:
     
     const char *getName() const;
     
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 class CharsetRecog_IBM420_ar_ltr : public CharsetRecog_IBM420_ar {
@@ -418,10 +273,10 @@ class CharsetRecog_IBM420_ar_ltr : public CharsetRecog_IBM420_ar {
     
     const char *getName() const;
     
-    int32_t match(InputText *textIn);
+    virtual UBool match(InputText *det, CharsetMatch *results) const;
 };
 
 U_NAMESPACE_END
 
-#endif
+#endif /* !UCONFIG_NO_CONVERSION */
 #endif /* __CSRSBCS_H */