]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/common/ucnv_cnv.h
ICU-66108.tar.gz
[apple/icu.git] / icuSources / common / ucnv_cnv.h
index a51faaf26adad9b1c44333201d8cd0ed15fd7fb1..2eed2c60df60c3ace76533c9bcc3146ea83619a3 100644 (file)
@@ -1,6 +1,8 @@
+// © 2016 and later: Unicode, Inc. and others.
+// License & terms of use: http://www.unicode.org/copyright.html
 /*
 **********************************************************************
-*   Copyright (C) 1999-2007, International Business Machines
+*   Copyright (C) 1999-2011, International Business Machines
 *   Corporation and others.  All Rights Reserved.
 **********************************************************************
 *
@@ -49,17 +51,22 @@ typedef struct UConverterSharedData UConverterSharedData;
 typedef struct {
     int32_t size;               /* sizeof(UConverterLoadArgs) */
     int32_t nestedLoads;        /* count nested ucnv_load() calls */
-    int32_t reserved;           /* reserved - for good alignment of the pointers */
+    UBool onlyTestIsLoadable;   /* input: don't actually load */
+    UBool reserved0;            /* reserved - for good alignment of the pointers */
+    int16_t reserved;           /* reserved - for good alignment of the pointers */
     uint32_t options;
-    const char *pkg, *name;
+    const char *pkg, *name, *locale;
 } UConverterLoadArgs;
 
+#define UCNV_LOAD_ARGS_INITIALIZER \
+    { (int32_t)sizeof(UConverterLoadArgs), 0, FALSE, FALSE, 0, 0, NULL, NULL, NULL }
+
 typedef void (*UConverterLoad) (UConverterSharedData *sharedData,
                                 UConverterLoadArgs *pArgs,
                                 const uint8_t *raw, UErrorCode *pErrorCode);
 typedef void (*UConverterUnload) (UConverterSharedData *sharedData);
 
-typedef void (*UConverterOpen) (UConverter *cnv, const char *name, const char *locale,uint32_t options, UErrorCode *pErrorCode);
+typedef void (*UConverterOpen) (UConverter *cnv, UConverterLoadArgs *pArgs, UErrorCode *pErrorCode);
 typedef void (*UConverterClose) (UConverter *cnv);
 
 typedef enum UConverterResetChoice {
@@ -255,7 +262,7 @@ extern const UConverterSharedData
     _LMBCSData1,_LMBCSData2, _LMBCSData3, _LMBCSData4, _LMBCSData5, _LMBCSData6,
     _LMBCSData8,_LMBCSData11,_LMBCSData16,_LMBCSData17,_LMBCSData18,_LMBCSData19,
     _HZData,_ISCIIData, _SCSUData, _ASCIIData,
-    _UTF7Data, _Bocu1Data, _UTF16Data, _UTF32Data, _CESU8Data, _IMAPData;
+    _UTF7Data, _Bocu1Data, _UTF16Data, _UTF32Data, _CESU8Data, _IMAPData, _CompoundTextData;
 
 U_CDECL_END