2000-11-15 00:56:35 +00:00
|
|
|
/*
|
|
|
|
*******************************************************************************
|
|
|
|
*
|
2003-10-25 00:29:13 +00:00
|
|
|
* Copyright (C) 2000-2003, International Business Machines
|
2000-11-15 00:56:35 +00:00
|
|
|
* Corporation and others. All Rights Reserved.
|
|
|
|
*
|
|
|
|
*******************************************************************************
|
|
|
|
* file name: makeconv.h
|
|
|
|
* encoding: US-ASCII
|
|
|
|
* tab size: 8 (not used)
|
|
|
|
* indentation:4
|
|
|
|
*
|
|
|
|
* created on: 2000nov01
|
|
|
|
* created by: Markus W. Scherer
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __MAKECONV_H__
|
|
|
|
#define __MAKECONV_H__
|
|
|
|
|
|
|
|
#include "unicode/utypes.h"
|
|
|
|
#include "ucnv_bld.h"
|
|
|
|
#include "unewdata.h"
|
2003-10-25 00:29:13 +00:00
|
|
|
#include "ucm.h"
|
2000-11-15 00:56:35 +00:00
|
|
|
|
|
|
|
/* exports from makeconv.c */
|
|
|
|
U_CFUNC UBool VERBOSE;
|
|
|
|
|
2003-10-25 00:29:13 +00:00
|
|
|
/* converter table type for writing */
|
|
|
|
enum {
|
|
|
|
TABLE_NONE,
|
|
|
|
TABLE_BASE,
|
|
|
|
TABLE_EXT,
|
|
|
|
TABLE_BASE_AND_EXT
|
|
|
|
};
|
|
|
|
|
2000-11-15 00:56:35 +00:00
|
|
|
/* abstract converter generator struct, C++ - style */
|
|
|
|
struct NewConverter;
|
|
|
|
typedef struct NewConverter NewConverter;
|
|
|
|
|
|
|
|
struct NewConverter {
|
|
|
|
void
|
|
|
|
(*close)(NewConverter *cnvData);
|
|
|
|
|
2001-01-03 00:29:09 +00:00
|
|
|
/** is this byte sequence valid? */
|
|
|
|
UBool
|
|
|
|
(*isValid)(NewConverter *cnvData,
|
2003-10-25 00:29:13 +00:00
|
|
|
const uint8_t *bytes, int32_t length);
|
2001-01-03 00:29:09 +00:00
|
|
|
|
2000-11-15 00:56:35 +00:00
|
|
|
UBool
|
2003-10-25 00:29:13 +00:00
|
|
|
(*addTable)(NewConverter *cnvData, UCMTable *table, UConverterStaticData *staticData);
|
2000-11-15 00:56:35 +00:00
|
|
|
|
|
|
|
uint32_t
|
2003-10-25 00:29:13 +00:00
|
|
|
(*write)(NewConverter *cnvData, const UConverterStaticData *staticData,
|
|
|
|
UNewDataMemory *pData, int32_t tableType);
|
2000-11-15 00:56:35 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|