Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(12)

Side by Side Diff: source/common/unicode/udata.h

Issue 845603002: Update ICU to 54.1 step 1 (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@master
Patch Set: remove unusued directories Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « source/common/unicode/uconfig.h ('k') | source/common/unicode/uloc.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 ****************************************************************************** 2 ******************************************************************************
3 * 3 *
4 * Copyright (C) 1999-2012, International Business Machines 4 * Copyright (C) 1999-2014, International Business Machines
5 * Corporation and others. All Rights Reserved. 5 * Corporation and others. All Rights Reserved.
6 * 6 *
7 ****************************************************************************** 7 ******************************************************************************
8 * file name: udata.h 8 * file name: udata.h
9 * encoding: US-ASCII 9 * encoding: US-ASCII
10 * tab size: 8 (not used) 10 * tab size: 8 (not used)
11 * indentation:4 11 * indentation:4
12 * 12 *
13 * created on: 1999oct25 13 * created on: 1999oct25
14 * created by: Markus W. Scherer 14 * created by: Markus W. Scherer
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 70
71 #endif /* U_HIDE_INTERNAL_API */ 71 #endif /* U_HIDE_INTERNAL_API */
72 72
73 /** 73 /**
74 * UDataInfo contains the properties about the requested data. 74 * UDataInfo contains the properties about the requested data.
75 * This is meta data. 75 * This is meta data.
76 * 76 *
77 * <p>This structure may grow in the future, indicated by the 77 * <p>This structure may grow in the future, indicated by the
78 * <code>size</code> field.</p> 78 * <code>size</code> field.</p>
79 * 79 *
80 * <p>ICU data must be at least 8-aligned, and should be 16-aligned.
81 * The UDataInfo struct begins 4 bytes after the start of the data item,
82 * so it is 4-aligned.
83 *
80 * <p>The platform data property fields help determine if a data 84 * <p>The platform data property fields help determine if a data
81 * file can be efficiently used on a given machine. 85 * file can be efficiently used on a given machine.
82 * The particular fields are of importance only if the data 86 * The particular fields are of importance only if the data
83 * is affected by the properties - if there is integer data 87 * is affected by the properties - if there is integer data
84 * with word sizes > 1 byte, char* text, or UChar* text.</p> 88 * with word sizes > 1 byte, char* text, or UChar* text.</p>
85 * 89 *
86 * <p>The implementation for the <code>udata_open[Choice]()</code> 90 * <p>The implementation for the <code>udata_open[Choice]()</code>
87 * functions may reject data based on the value in <code>isBigEndian</code>. 91 * functions may reject data based on the value in <code>isBigEndian</code>.
88 * No other field is used by the <code>udata</code> API implementation.</p> 92 * No other field is used by the <code>udata</code> API implementation.</p>
89 * 93 *
90 * <p>The <code>dataFormat</code> may be used to identify 94 * <p>The <code>dataFormat</code> may be used to identify
91 * the kind of data, e.g. a converter table.</p> 95 * the kind of data, e.g. a converter table.</p>
92 * 96 *
93 * <p>The <code>formatVersion</code> field should be used to 97 * <p>The <code>formatVersion</code> field should be used to
94 * make sure that the format can be interpreted. 98 * make sure that the format can be interpreted.
95 * I may be a good idea to check only for the one or two highest 99 * It may be a good idea to check only for the one or two highest
96 * of the version elements to allow the data memory to 100 * of the version elements to allow the data memory to
97 * get more or somewhat rearranged contents, for as long 101 * get more or somewhat rearranged contents, for as long
98 * as the using code can still interpret the older contents.</p> 102 * as the using code can still interpret the older contents.</p>
99 * 103 *
100 * <p>The <code>dataVersion</code> field is intended to be a 104 * <p>The <code>dataVersion</code> field is intended to be a
101 * common place to store the source version of the data; 105 * common place to store the source version of the data;
102 * for data from the Unicode character database, this could 106 * for data from the Unicode character database, this could
103 * reflect the Unicode version.</p> 107 * reflect the Unicode version.</p>
108 *
104 * @stable ICU 2.0 109 * @stable ICU 2.0
105 */ 110 */
106 typedef struct { 111 typedef struct {
107 /** sizeof(UDataInfo) 112 /** sizeof(UDataInfo)
108 * @stable ICU 2.0 */ 113 * @stable ICU 2.0 */
109 uint16_t size; 114 uint16_t size;
110 115
111 /** unused, set to 0 116 /** unused, set to 0
112 * @stable ICU 2.0*/ 117 * @stable ICU 2.0*/
113 uint16_t reservedWord; 118 uint16_t reservedWord;
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
272 */ 277 */
273 U_DEFINE_LOCAL_OPEN_POINTER(LocalUDataMemoryPointer, UDataMemory, udata_close); 278 U_DEFINE_LOCAL_OPEN_POINTER(LocalUDataMemoryPointer, UDataMemory, udata_close);
274 279
275 U_NAMESPACE_END 280 U_NAMESPACE_END
276 281
277 #endif 282 #endif
278 283
279 /** 284 /**
280 * Get the pointer to the actual data inside the data memory. 285 * Get the pointer to the actual data inside the data memory.
281 * The data is read-only. 286 * The data is read-only.
287 *
288 * ICU data must be at least 8-aligned, and should be 16-aligned.
289 *
282 * @param pData The pointer to data memory object 290 * @param pData The pointer to data memory object
283 * @stable ICU 2.0 291 * @stable ICU 2.0
284 */ 292 */
285 U_STABLE const void * U_EXPORT2 293 U_STABLE const void * U_EXPORT2
286 udata_getMemory(UDataMemory *pData); 294 udata_getMemory(UDataMemory *pData);
287 295
288 /** 296 /**
289 * Get the information from the data memory header. 297 * Get the information from the data memory header.
290 * This allows to get access to the header containing 298 * This allows to get access to the header containing
291 * platform data properties etc. which is not part of 299 * platform data properties etc. which is not part of
(...skipping 12 matching lines...) Expand all
304 * @stable ICU 2.0 312 * @stable ICU 2.0
305 */ 313 */
306 U_STABLE void U_EXPORT2 314 U_STABLE void U_EXPORT2
307 udata_getInfo(UDataMemory *pData, UDataInfo *pInfo); 315 udata_getInfo(UDataMemory *pData, UDataInfo *pInfo);
308 316
309 /** 317 /**
310 * This function bypasses the normal ICU data loading process and 318 * This function bypasses the normal ICU data loading process and
311 * allows you to force ICU's system data to come out of a user-specified 319 * allows you to force ICU's system data to come out of a user-specified
312 * area in memory. 320 * area in memory.
313 * 321 *
322 * ICU data must be at least 8-aligned, and should be 16-aligned.
323 * See http://userguide.icu-project.org/icudata
324 *
314 * The format of this data is that of the icu common data file, as is 325 * The format of this data is that of the icu common data file, as is
315 * generated by the pkgdata tool with mode=common or mode=dll. 326 * generated by the pkgdata tool with mode=common or mode=dll.
316 * You can read in a whole common mode file and pass the address to the start of the 327 * You can read in a whole common mode file and pass the address to the start of the
317 * data, or (with the appropriate link options) pass in the pointer to 328 * data, or (with the appropriate link options) pass in the pointer to
318 * the data that has been loaded from a dll by the operating system, 329 * the data that has been loaded from a dll by the operating system,
319 * as shown in this code: 330 * as shown in this code:
320 * 331 *
321 * extern const char U_IMPORT U_ICUDATA_ENTRY_POINT []; 332 * extern const char U_IMPORT U_ICUDATA_ENTRY_POINT [];
322 * // U_ICUDATA_ENTRY_POINT is same as entry point specified to pkgdata t ool 333 * // U_ICUDATA_ENTRY_POINT is same as entry point specified to pkgdata t ool
323 * UErrorCode status = U_ZERO_ERROR; 334 * UErrorCode status = U_ZERO_ERROR;
(...skipping 24 matching lines...) Expand all
348 */ 359 */
349 U_STABLE void U_EXPORT2 360 U_STABLE void U_EXPORT2
350 udata_setCommonData(const void *data, UErrorCode *err); 361 udata_setCommonData(const void *data, UErrorCode *err);
351 362
352 363
353 /** 364 /**
354 * This function bypasses the normal ICU data loading process for application-sp ecific 365 * This function bypasses the normal ICU data loading process for application-sp ecific
355 * data and allows you to force the it to come out of a user-specified 366 * data and allows you to force the it to come out of a user-specified
356 * pointer. 367 * pointer.
357 * 368 *
369 * ICU data must be at least 8-aligned, and should be 16-aligned.
370 * See http://userguide.icu-project.org/icudata
371 *
358 * The format of this data is that of the icu common data file, like 'icudt26l.d at' 372 * The format of this data is that of the icu common data file, like 'icudt26l.d at'
359 * or the corresponding shared library (DLL) file. 373 * or the corresponding shared library (DLL) file.
360 * The application must read in or otherwise construct an image of the data and then 374 * The application must read in or otherwise construct an image of the data and then
361 * pass the address of it to this function. 375 * pass the address of it to this function.
362 * 376 *
363 * 377 *
364 * Warning: setAppData will set a U_USING_DEFAULT_WARNING code if 378 * Warning: setAppData will set a U_USING_DEFAULT_WARNING code if
365 * data with the specifed path that has already been opened, or 379 * data with the specifed path that has already been opened, or
366 * if setAppData with the same path has already been called. 380 * if setAppData with the same path has already been called.
367 * Any such calls to setAppData will have no effect. 381 * Any such calls to setAppData will have no effect.
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
407 * @param status Error code. 421 * @param status Error code.
408 * @see UDataFileAccess 422 * @see UDataFileAccess
409 * @stable ICU 3.4 423 * @stable ICU 3.4
410 */ 424 */
411 U_STABLE void U_EXPORT2 425 U_STABLE void U_EXPORT2
412 udata_setFileAccess(UDataFileAccess access, UErrorCode *status); 426 udata_setFileAccess(UDataFileAccess access, UErrorCode *status);
413 427
414 U_CDECL_END 428 U_CDECL_END
415 429
416 #endif 430 #endif
OLDNEW
« no previous file with comments | « source/common/unicode/uconfig.h ('k') | source/common/unicode/uloc.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698