home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 6 / AACD06.ISO / AACD / Programming / ICU / src / icu / source / test / intltest / jacoll.h < prev    next >
Encoding:
C/C++ Source or Header  |  1999-08-16  |  1.9 KB  |  58 lines

  1. /*
  2. *****************************************************************************************
  3. *                                                                                       *
  4. * COPYRIGHT:                                                                            *
  5. *   (C) Copyright Taligent, Inc.,  1997                                                 *
  6. *   (C) Copyright International Business Machines Corporation,  1997-1998               *
  7. *   Licensed Material - Program-Property of IBM - All Rights Reserved.                  *
  8. *   US Government Users Restricted Rights - Use, duplication, or disclosure             *
  9. *   restricted by GSA ADP Schedule Contract with IBM Corp.                              *
  10. *                                                                                       *
  11. *****************************************************************************************
  12. */
  13.  
  14. /**
  15.  * CollationKanaTest is a third level test class.  This tests the locale
  16.  * specific tertiary rules.  For example, the term 'A-' (/u3041/u30fc) is 
  17.  * equivalent to 'AA' (/u3041/u3041).
  18.  */
  19.  
  20. #ifndef _JACOLL
  21. #define _JACOLL
  22.  
  23. #ifndef _UTYPES
  24. #include "utypes.h"
  25. #endif
  26.  
  27. #ifndef _COLL
  28. #include "coll.h"
  29. #endif
  30.  
  31. #ifndef _INTLTEST
  32. #include "intltest.h"
  33. #endif
  34.  
  35. class CollationKanaTest: public IntlTest {
  36. public:
  37.     // static constants
  38.     enum EToken_Len { MAX_TOKEN_LEN = 128 };
  39.  
  40.     CollationKanaTest();
  41.     ~CollationKanaTest();
  42.     void runIndexedTest( int32_t index, bool_t exec, char* &name, char* par = NULL );
  43.  
  44.     // main test routine, tests rules specific to "Kana" locale
  45.     void doTest( UnicodeString source, UnicodeString target, Collator::EComparisonResult result);
  46.  
  47.     // performs test with strength TERIARY
  48.     void TestTertiary( char* par );
  49.  
  50. private:
  51.     static const UChar testSourceCases[][MAX_TOKEN_LEN];
  52.     static const UChar testTargetCases[][MAX_TOKEN_LEN];
  53.     static const Collator::EComparisonResult results[];
  54.  
  55.     Collator *myCollation;
  56. };
  57. #endif
  58.