scuffed-code/icu4c/source/test/cintltst/nccbtst.h

67 lines
2.8 KiB
C
Raw Normal View History

/********************************************************************
* COPYRIGHT:
* Copyright (c) 1997-2001, International Business Machines Corporation and
* others. All Rights Reserved.
********************************************************************/
/********************************************************************************
1999-08-16 21:50:52 +00:00
*
* File NCCBTST.H
*
* Modification History:
* Name Description
* Madhu Katragadda creation
*********************************************************************************
*/
2000-06-26 21:33:25 +00:00
#ifndef _NCCBTST
#define _NCCBTST
1999-08-16 21:50:52 +00:00
/* C API TEST FOR CALL BACK ROUTINES OF CODESET CONVERSION COMPONENT */
#include "cintltst.h"
#include "unicode/utypes.h"
1999-08-16 21:50:52 +00:00
static void TestSkipCallBack(void);
static void TestStopCallBack(void);
1999-08-16 21:50:52 +00:00
static void TestSubCallBack(void);
static void TestSubWithValueCallBack(void);
static void TestLegalAndOtherCallBack(void);
static void TestSingleByteCallBack(void);
1999-08-16 21:50:52 +00:00
static void TestSkip(int32_t inputsize, int32_t outputsize);
static void TestStop(int32_t inputsize, int32_t outputsize);
1999-08-16 21:50:52 +00:00
static void TestSub(int32_t inputsize, int32_t outputsize);
static void TestSubWithValue(int32_t inputsize, int32_t outputsize);
static void TestLegalAndOthers(int32_t inputsize, int32_t outputsize);
static void TestSingleByte(int32_t inputsize, int32_t outputsize);
static void TestEBCDIC_STATEFUL_Sub(int32_t inputsize, int32_t outputsize);
1999-08-16 21:50:52 +00:00
UBool testConvertFromUnicode(const UChar *source, int sourceLen, const uint8_t *expect, int expectLen,
const char *codepage, UConverterFromUCallback callback, const int32_t *expectOffsets,
const char *mySubChar, int8_t len);
1999-08-16 21:50:52 +00:00
UBool testConvertToUnicode( const uint8_t *source, int sourcelen, const UChar *expect, int expectlen,
const char *codepage, UConverterToUCallback callback, const int32_t *expectOffsets,
const char *mySubChar, int8_t len);
1999-08-16 21:50:52 +00:00
UBool testConvertFromUnicodeWithContext(const UChar *source, int sourceLen, const uint8_t *expect, int expectLen,
const char *codepage, UConverterFromUCallback callback , const int32_t *expectOffsets,
const char *mySubChar, int8_t len, void* context, UErrorCode expectedError);
UBool testConvertToUnicodeWithContext( const uint8_t *source, int sourcelen, const UChar *expect, int expectlen,
const char *codepage, UConverterToUCallback callback, const int32_t *expectOffsets,
const char *mySubChar, int8_t len, void* context, UErrorCode expectedError);
1999-08-16 21:50:52 +00:00
static void printSeq(const uint8_t* a, int len);
1999-08-16 21:50:52 +00:00
static void printUSeq(const UChar* a, int len);
static void printSeqErr(const uint8_t* a, int len);
1999-08-16 21:50:52 +00:00
static void printUSeqErr(const UChar* a, int len);
static void setNuConvTestName(const char *codepage, const char *direction);
#endif