1999-08-16 21:50:52 +00:00
|
|
|
/*
|
1999-12-09 23:27:55 +00:00
|
|
|
**********************************************************************
|
|
|
|
* Copyright (C) 1995-1999, International Business Machines
|
|
|
|
* Corporation and others. All Rights Reserved.
|
|
|
|
**********************************************************************
|
1999-08-16 21:50:52 +00:00
|
|
|
* @version 1.0 23/10/96
|
|
|
|
* @author Helena Shih
|
|
|
|
* Based on Taligent international support for java
|
|
|
|
* Modification History :
|
|
|
|
*
|
|
|
|
* 05/07/97 helena Added isBogus()
|
2000-09-15 19:40:20 +00:00
|
|
|
* 07/15/98 erm Synched with Java 1.2 CompactShortArray.java.
|
|
|
|
* 07/30/98 erm Added 07/29/98 code review changes.
|
|
|
|
* 04/21/99 Damiba Port to C/New API faster ucmp16_get
|
1999-08-16 21:50:52 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef UCMP16_H
|
|
|
|
#define UCMP16_H
|
|
|
|
|
|
|
|
|
2000-11-06 23:58:15 +00:00
|
|
|
#include "umemstrm.h"
|
1999-12-28 23:39:02 +00:00
|
|
|
#include "unicode/utypes.h"
|
1999-08-16 21:50:52 +00:00
|
|
|
|
2000-04-19 23:05:27 +00:00
|
|
|
/* 32-bits.
|
|
|
|
Bump this whenever the internal structure changes.
|
|
|
|
*/
|
|
|
|
#define ICU_UCMP16_VERSION 0x01270000
|
1999-08-16 21:50:52 +00:00
|
|
|
|
2000-11-06 23:58:15 +00:00
|
|
|
/* internal constants*/
|
|
|
|
#define UCMP16_kMaxUnicode_int 65535
|
|
|
|
#define UCMP16_kUnicodeCount_int (UCMP16_kMaxUnicode_int + 1)
|
|
|
|
#define UCMP16_kBlockShift_int 7
|
|
|
|
#define UCMP16_kBlockCount_int (1 << UCMP16_kBlockShift_int)
|
|
|
|
#define UCMP16_kBlockBytes_int (UCMP16_kBlockCount_int * sizeof(int16_t))
|
|
|
|
#define UCMP16_kIndexShift_int (16 - UCMP16_kBlockShift_int)
|
|
|
|
#define UCMP16_kIndexCount_int (1 << UCMP16_kIndexShift_int)
|
|
|
|
#define UCMP16_kBlockMask_int (UCMP16_kBlockCount_int - 1)
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* class CompactATypeArray : use only on primitive data types
|
|
|
|
* Provides a compact way to store information that is indexed by Unicode
|
|
|
|
* values, such as character properties, types, keyboard values, etc.This
|
|
|
|
* is very useful when you have a block of Unicode data that contains
|
|
|
|
* significant values while the rest of the Unicode data is unused in the
|
|
|
|
* application or when you have a lot of redundance, such as where all 21,000
|
|
|
|
* Han ideographs have the same value. However, lookup is much faster than a
|
|
|
|
* hash table.
|
|
|
|
* <P>
|
|
|
|
* A compact array of any primitive data type serves two purposes:
|
|
|
|
* <UL type = round>
|
|
|
|
* <LI>Fast access of the indexed values.
|
|
|
|
* <LI>Smaller memory footprint.
|
|
|
|
* </UL>
|
|
|
|
* <P>
|
|
|
|
* The index array always points into particular parts of the data array
|
|
|
|
* it is initially set up to point at regular block boundaries
|
|
|
|
* The following example uses blocks of 4 for simplicity
|
|
|
|
* <PRE>
|
|
|
|
* Example: Expanded
|
|
|
|
* BLOCK 0 1 2 3 4
|
|
|
|
* INDEX 0 4 8 12 16 ...
|
|
|
|
* ARRAY abcdeababcdezyabcdea...
|
|
|
|
* | | | | | |...
|
|
|
|
* </PRE>
|
|
|
|
* <P>
|
|
|
|
* After compression, the index will point to various places in the data array
|
|
|
|
* wherever there is a runs of the same elements as in the original
|
|
|
|
* <PRE>
|
|
|
|
* Example: Compressed
|
|
|
|
* BLOCK 0 1 2 3 4
|
|
|
|
* INDEX 0 4 1 8 2 ...
|
|
|
|
* ARRAY abcdeabazyabc...
|
|
|
|
* </PRE>
|
|
|
|
* <P>
|
|
|
|
* If you look at the example, index number 2 in the expanded version points
|
|
|
|
* to data position number 8, which has elements "bcde". In the compressed
|
|
|
|
* version, index number 2 points to data position 1, which also has "bcde"
|
|
|
|
* @see CompactByteArray
|
|
|
|
* @see CompactIntArray
|
|
|
|
* @see CompactCharArray
|
|
|
|
* @see CompactStringArray
|
2000-12-13 19:48:01 +00:00
|
|
|
* @version $Revision: 1.16 $ 8/25/98
|
1999-08-16 21:50:52 +00:00
|
|
|
* @author Helena Shih
|
|
|
|
*/
|
|
|
|
|
1999-10-18 22:48:32 +00:00
|
|
|
typedef struct CompactShortArray {
|
1999-12-04 02:31:40 +00:00
|
|
|
int32_t fStructSize;
|
1999-08-16 21:50:52 +00:00
|
|
|
int16_t* fArray;
|
|
|
|
uint16_t* fIndex;
|
|
|
|
int32_t* fHashes;
|
|
|
|
int32_t fCount;
|
|
|
|
int16_t fDefaultValue;
|
2000-05-18 22:08:39 +00:00
|
|
|
UBool fCompact;
|
|
|
|
UBool fBogus;
|
|
|
|
UBool fAlias;
|
1999-08-16 21:50:52 +00:00
|
|
|
int32_t kBlockShift;
|
|
|
|
int32_t kBlockMask;
|
2000-05-18 22:08:39 +00:00
|
|
|
UBool fIAmOwned; /* don't free CSA on close */
|
1999-08-16 21:50:52 +00:00
|
|
|
} CompactShortArray;
|
|
|
|
|
|
|
|
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI int32_t U_EXPORT2 ucmp16_getkUnicodeCount(void);
|
|
|
|
U_CAPI int32_t U_EXPORT2 ucmp16_getkBlockCount(void);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
2000-12-13 19:48:01 +00:00
|
|
|
* Construct an empty CompactShortArray with uprv_malloc(). Do not call any of the
|
|
|
|
* ucmp16_init*() functions after using this function. They will cause a memory
|
|
|
|
* leak.
|
|
|
|
*
|
1999-08-16 21:50:52 +00:00
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
2000-12-13 19:48:01 +00:00
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initBogus
|
|
|
|
* @return The initialized array.
|
1999-08-16 21:50:52 +00:00
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_open(int16_t defaultValue);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Construct a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be adopted by the CompactShortArray. Memory is allocated with uprv_malloc.
|
|
|
|
* Note: for speed, the compact method will only re-use blocks in the values array
|
|
|
|
* that are on a block boundary. The pre-computed arrays passed in to this constructor
|
|
|
|
* may re-use blocks at any position in the values array. Do not call any of the
|
|
|
|
* ucmp16_init*() functions after using this function. They will cause a memory
|
|
|
|
* leak. The indexArray and newValues will be uprv_free'd when ucmp16_close() is called.
|
|
|
|
*
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initBogus
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_openAdopt(uint16_t *indexArray,
|
2000-09-15 19:40:20 +00:00
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Construct a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be adopted by the CompactShortArray. Memory is allocated with uprv_malloc.
|
|
|
|
* Note: for speed, the compact method will only re-use blocks in the values array
|
|
|
|
* that are on a block boundary. The pre-computed arrays passed in to this constructor
|
|
|
|
* may re-use blocks at any position in the values array. Do not call any of the
|
|
|
|
* ucmp16_init*() functions after using this function. They will cause a memory
|
|
|
|
* leak. The indexArray and newValues will be uprv_free'd when ucmp16_close() is called.
|
|
|
|
*
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initBogus
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_openAdoptWithBlockShift(uint16_t *indexArray,
|
2000-09-15 19:40:20 +00:00
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue,
|
|
|
|
int32_t blockShift);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Construct a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be aliased by the CompactShortArray. Memory is allocated with uprv_malloc.
|
|
|
|
* Note: for speed, the compact method will only re-use blocks in the values array
|
|
|
|
* that are on a block boundary. The pre-computed arrays passed in to this constructor
|
|
|
|
* may re-use blocks at any position in the values array. Do not call any of the
|
|
|
|
* ucmp16_init*() functions after using this function. They will cause a memory
|
|
|
|
* leak.
|
|
|
|
*
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initBogus
|
|
|
|
*/
|
1999-12-04 02:31:40 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_openAlias(uint16_t *indexArray,
|
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue );
|
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Initialize an empty CompactShortArray. Do not call this function if
|
|
|
|
* you created the array with any of the ucmp16_open*() funcitons because it
|
|
|
|
* will cause a memory leak.
|
|
|
|
*
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @param array An uninitialized CompactShortArray
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAdopt
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_initAdopt
|
|
|
|
* @see ucmp16_initAlias
|
|
|
|
*/
|
|
|
|
U_CAPI void U_EXPORT2 ucmp16_init(CompactShortArray* array, int16_t defaultValue);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Initialize an empty CompactShortArray to the bogus value. Do not call
|
|
|
|
* this function if you created the array with ucmp16_open() because it
|
|
|
|
* will cause a memory leak.
|
|
|
|
*
|
|
|
|
* @param array An uninitialized CompactShortArray
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAdopt
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_isBogus
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initAdopt
|
|
|
|
* @see ucmp16_initAlias
|
|
|
|
*/
|
|
|
|
U_CAPI void U_EXPORT2 ucmp16_initBogus(CompactShortArray* array);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Initialize a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be adopted by the CompactShortArray. No memory is allocated. Note: for speed,
|
|
|
|
* the compact method will only re-use blocks in the values array that are on a block
|
|
|
|
* boundary. The pre-computed arrays passed in to this constructor may re-use blocks
|
|
|
|
* at any position in the values array. The indexArray and newValues will be
|
|
|
|
* uprv_free'd when ucmp16_close() is called.
|
|
|
|
*
|
|
|
|
* @param this_obj the CompactShortArray to be initialized
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAdopt
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initAlias
|
|
|
|
*/
|
2000-09-15 19:40:20 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_initAdopt(CompactShortArray *this_obj,
|
|
|
|
uint16_t *indexArray,
|
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue );
|
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Initialize a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be adopted by the CompactShortArray. No memory is allocated. Note: for speed,
|
|
|
|
* the compact method will only re-use blocks in the values array that are on a block
|
|
|
|
* boundary. The pre-computed arrays passed in to this constructor may re-use blocks
|
|
|
|
* at any position in the values array. The indexArray and newValues will be
|
|
|
|
* uprv_free'd when ucmp16_close() is called.
|
|
|
|
*
|
|
|
|
* @param this_obj the CompactShortArray to be initialized
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @return The initialized array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAdopt
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initAlias
|
|
|
|
* @see ucmp16_initAdopt
|
|
|
|
*/
|
2000-09-15 19:40:20 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_initAdoptWithBlockShift(CompactShortArray *this_obj,
|
|
|
|
uint16_t *indexArray,
|
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue,
|
|
|
|
int32_t blockShift);
|
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Initialize a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be aliased by the CompactShortArray. No memory is allocated. Note: for speed,
|
|
|
|
* the compact method will only re-use blocks in the values array that are on a block
|
|
|
|
* boundary. The pre-computed arrays passed in to this constructor may re-use blocks
|
|
|
|
* at any position in the values array.
|
|
|
|
*
|
|
|
|
* @param this_obj the CompactShortArray to be initialized
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @return The initialized array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAdopt
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initAdopt
|
|
|
|
*/
|
2000-09-15 19:40:20 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_initAlias(CompactShortArray *this_obj,
|
|
|
|
uint16_t *indexArray,
|
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue );
|
|
|
|
|
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Initialize a CompactShortArray from a pre-computed index and values array. The values
|
|
|
|
* will be aliased by the CompactShortArray. No memory is allocated. Note: for speed,
|
|
|
|
* the compact method will only re-use blocks in the values array that are on a block
|
|
|
|
* boundary. The pre-computed arrays passed in to this constructor may re-use blocks
|
|
|
|
* at any position in the values array.
|
|
|
|
*
|
|
|
|
* @param this_obj the CompactShortArray to be initialized
|
|
|
|
* @param indexArray the index array to be adopted
|
|
|
|
* @param newValues the value array to be adopted
|
|
|
|
* @param count the number of entries in the value array
|
|
|
|
* @param defaultValue the default value for all characters not explicitly in the array
|
|
|
|
* @return The initialized array
|
|
|
|
* @see compact
|
|
|
|
* @see ucmp16_open
|
|
|
|
* @see ucmp16_openAdopt
|
|
|
|
* @see ucmp16_openAlias
|
|
|
|
* @see ucmp16_init
|
|
|
|
* @see ucmp16_initAdopt
|
|
|
|
*/
|
2000-09-19 16:33:22 +00:00
|
|
|
U_CAPI CompactShortArray* U_EXPORT2 ucmp16_initAliasWithBlockShift(CompactShortArray *this_obj,
|
|
|
|
uint16_t *indexArray,
|
|
|
|
int16_t *newValues,
|
|
|
|
int32_t count,
|
|
|
|
int16_t defaultValue,
|
|
|
|
int32_t blockShift);
|
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Free up any allocated memory associated with this compact array.
|
|
|
|
* The memory that is uprv_free'd depends on how the array was initialized
|
|
|
|
* or opened.
|
|
|
|
*
|
|
|
|
* @param array The array to close
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI void U_EXPORT2 ucmp16_close(CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Returns TRUE if the creation of the compact array fails.
|
|
|
|
*/
|
2000-05-18 22:08:39 +00:00
|
|
|
U_CAPI UBool U_EXPORT2 ucmp16_isBogus(const CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the mapped value of a Unicode character.
|
2000-12-13 19:48:01 +00:00
|
|
|
*
|
1999-08-16 21:50:52 +00:00
|
|
|
* @param index the character to get the mapped value with
|
|
|
|
* @return the mapped value of the given character
|
|
|
|
*/
|
|
|
|
#define ucmp16_get(array, index) (array->fArray[(array->fIndex[(index >> array->kBlockShift)] )+ \
|
|
|
|
(index & array->kBlockMask)])
|
|
|
|
|
|
|
|
#define ucmp16_getu(array, index) (uint16_t)ucmp16_get(array, index)
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
2000-12-13 19:48:01 +00:00
|
|
|
* Set a new value for a Unicode character.
|
|
|
|
* Set automatically expands the array if it is compacted.
|
|
|
|
*
|
|
|
|
* @param character the character to set the mapped value with
|
|
|
|
* @param value the new mapped value
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI void U_EXPORT2 ucmp16_set(CompactShortArray *array,
|
2000-09-15 19:40:20 +00:00
|
|
|
UChar character,
|
|
|
|
int16_t value);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
|
2000-12-13 19:48:01 +00:00
|
|
|
/**
|
|
|
|
* Set new values for a range of Unicode character.
|
|
|
|
*
|
|
|
|
* @param start the starting offset of the range
|
|
|
|
* @param end the ending offset of the range
|
|
|
|
* @param value the new mapped value
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI void U_EXPORT2 ucmp16_setRange(CompactShortArray* array,
|
2000-09-15 19:40:20 +00:00
|
|
|
UChar start,
|
|
|
|
UChar end,
|
|
|
|
int16_t value);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Compact the array. For efficency, this method will only re-use
|
|
|
|
* blocks in the values array that are on a block bounday. If you
|
|
|
|
* want better compaction, you can do your own compaction and use
|
|
|
|
* the constructor that lets you pass in the pre-computed arrays.
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI void U_EXPORT2 ucmp16_compact(CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the default value.
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI int16_t U_EXPORT2 ucmp16_getDefaultValue(const CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the number of elements in the value array.
|
|
|
|
* @return the number of elements in the value array.
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI uint32_t U_EXPORT2 ucmp16_getCount(const CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the address of the value array.
|
|
|
|
* @return the address of the value array
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI const int16_t* U_EXPORT2 ucmp16_getArray(const CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the address of the index array.
|
|
|
|
* @return the address of the index array
|
|
|
|
*/
|
1999-10-18 22:48:32 +00:00
|
|
|
U_CAPI const uint16_t* U_EXPORT2 ucmp16_getIndex(const CompactShortArray* array);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
|
1999-12-04 02:31:40 +00:00
|
|
|
/** INTERNAL USE ONLY **/
|
2000-11-07 16:32:42 +00:00
|
|
|
U_CAPI uint32_t U_EXPORT2 ucmp16_flattenMem(const CompactShortArray* array, UMemoryStream *MS);
|
2000-12-13 19:48:01 +00:00
|
|
|
/** INTERNAL USE ONLY **/
|
2000-04-19 23:05:27 +00:00
|
|
|
U_CAPI void U_EXPORT2 ucmp16_initFromData(CompactShortArray* array, const uint8_t **source, UErrorCode *status);
|
1999-08-16 21:50:52 +00:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|