| OLD | NEW |
| 1 /* | 1 /* |
| 2 ****************************************************************************** | 2 ****************************************************************************** |
| 3 * Copyright (C) 1996-2009, International Business Machines * | 3 * Copyright (C) 1996-2009, International Business Machines * |
| 4 * Corporation and others. All Rights Reserved. * | 4 * Corporation and others. All Rights Reserved. * |
| 5 ****************************************************************************** | 5 ****************************************************************************** |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #include "unicode/utypes.h" | 8 #include "unicode/utypes.h" |
| 9 | 9 |
| 10 #if !UCONFIG_NO_COLLATION | 10 #if !UCONFIG_NO_COLLATION |
| (...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 460 void flush(); | 460 void flush(); |
| 461 | 461 |
| 462 private: | 462 private: |
| 463 static char *getKey(UCollator *collator, char *keyBuffer, int32_t *charBuffe
rLength); | 463 static char *getKey(UCollator *collator, char *keyBuffer, int32_t *charBuffe
rLength); |
| 464 static void deleteKey(char *key); | 464 static void deleteKey(char *key); |
| 465 | 465 |
| 466 UMTX lock; | 466 UMTX lock; |
| 467 UHashtable *cache; | 467 UHashtable *cache; |
| 468 }; | 468 }; |
| 469 | 469 |
| 470 U_CFUNC void deleteChars(void */*obj*/) | 470 U_CFUNC void deleteChars(void * /*obj*/) |
| 471 { | 471 { |
| 472 // char *chars = (char *) obj; | 472 // char *chars = (char *) obj; |
| 473 // All the key strings are owned by the | 473 // All the key strings are owned by the |
| 474 // CollData objects and don't need to | 474 // CollData objects and don't need to |
| 475 // be freed here. | 475 // be freed here. |
| 476 //DELETE_ARRAY(chars); | 476 //DELETE_ARRAY(chars); |
| 477 } | 477 } |
| 478 | 478 |
| 479 U_CFUNC void deleteCollDataCacheEntry(void *obj) | 479 U_CFUNC void deleteCollDataCacheEntry(void *obj) |
| 480 { | 480 { |
| (...skipping 612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1093 // **** this will fail if the another **** | 1093 // **** this will fail if the another **** |
| 1094 // **** thread deletes the cache here **** | 1094 // **** thread deletes the cache here **** |
| 1095 if (cache != NULL) { | 1095 if (cache != NULL) { |
| 1096 cache->flush(); | 1096 cache->flush(); |
| 1097 } | 1097 } |
| 1098 } | 1098 } |
| 1099 | 1099 |
| 1100 U_NAMESPACE_END | 1100 U_NAMESPACE_END |
| 1101 | 1101 |
| 1102 #endif // #if !UCONFIG_NO_COLLATION | 1102 #endif // #if !UCONFIG_NO_COLLATION |
| OLD | NEW |