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

  1. /*
  2. *****************************************************************************************
  3. *                                                                                       *
  4. * COPYRIGHT:                                                                            *
  5. *   (C) Copyright Taligent, Inc.,  1996                                                 *
  6. *   (C) Copyright International Business Machines Corporation,  1999                    *
  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. * File CG7COLL.H
  15. *
  16. * Modification History:
  17. *        Name                     Description            
  18. *     Madhu Katragadda            Converted to C
  19. *********************************************************************************
  20. /**
  21.  * G7CollationTest is a third level test class.  This test performs the examples 
  22.  * mentioned on the Taligent international demos web site.  
  23.  * Sample Rules: & Z < p , P 
  24.  * Effect :  Making P sort after Z.
  25.  *
  26.  * Sample Rules: & c < ch , cH, Ch, CH 
  27.  * Effect : As well as adding sequences of characters that act as a single character (this is
  28.  * known as contraction), you can also add characters that act like a sequence of
  29.  * characters (this is known as expansion).  
  30.  * 
  31.  * Sample Rules: & Question'-'mark ; '?' & Hash'-'mark ; '#' & Ampersand ; '&' 
  32.  * Effect : Expansion and contraction can actually be combined.  
  33.  * 
  34.  * Sample Rules: & aa ; a'-' & ee ; e'-' & ii ; i'-' & oo ; o'-' & uu ; u'-'
  35.  * Effect : sorted sequence as the following,
  36.  * aardvark  
  37.  * a-rdvark  
  38.  * abbot  
  39.  * coop  
  40.  * co-p  
  41.  * cop 
  42.  */
  43.  
  44. #ifndef _CG7COLLTST
  45. #define _CG7COLLTST
  46.  
  47. #include "cintltst.h"
  48.  
  49. #define MAX_TOKEN_LEN 128
  50. #define  TESTLOCALES  12 
  51. #define  FIXEDTESTSET 15 
  52. #define  TOTALTESTSET  30 
  53.  
  54.         
  55.     /* main test routine, tests comparisons for a set of strings against sets of expected results */
  56.    static  void doTest(UCollator *myCollation, const UChar* source, const UChar* target, UCollationResult result);
  57.     
  58.     /* perform test for G7 locales */
  59.     void TestG7Locales(void);
  60.  
  61.     /* perform test with added rules " & Z < p, P" */
  62.     void TestDemo1(void);
  63.  
  64.     /* perorm test with added rules "& C < ch , cH, Ch, CH" */
  65.     void TestDemo2(void);
  66.  
  67.     /* perform test with added rules  */
  68.     /* "& Question'-'mark ; '?' & Hash'-'mark ; '#' & Ampersand ; '&'" */
  69.     void TestDemo3(void);
  70.  
  71.     /* perform test with added rules  */
  72.     /* " & aa ; a'-' & ee ; e'-' & ii ; i'-' & oo ; o'-' & uu ; u'-' " */
  73.     void TestDemo4(void);
  74.  
  75. #endif
  76.