OLD | NEW |
1 /* | 1 /* |
2 ****************************************************************************** | 2 ****************************************************************************** |
3 * Copyright (C) 1997-2011, International Business Machines | 3 * Copyright (C) 1997-2014, International Business Machines |
4 * Corporation and others. All Rights Reserved. | 4 * Corporation and others. All Rights Reserved. |
5 ****************************************************************************** | 5 ****************************************************************************** |
6 * Date Name Description | 6 * Date Name Description |
7 * 03/28/00 aliu Creation. | 7 * 03/28/00 aliu Creation. |
8 ****************************************************************************** | 8 ****************************************************************************** |
9 */ | 9 */ |
10 | 10 |
11 #ifndef HASH_H | 11 #ifndef HASH_H |
12 #define HASH_H | 12 #define HASH_H |
13 | 13 |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 int32_t geti(const UnicodeString& key) const; | 78 int32_t geti(const UnicodeString& key) const; |
79 | 79 |
80 void* remove(const UnicodeString& key); | 80 void* remove(const UnicodeString& key); |
81 | 81 |
82 int32_t removei(const UnicodeString& key); | 82 int32_t removei(const UnicodeString& key); |
83 | 83 |
84 void removeAll(void); | 84 void removeAll(void); |
85 | 85 |
86 const UHashElement* find(const UnicodeString& key) const; | 86 const UHashElement* find(const UnicodeString& key) const; |
87 | 87 |
| 88 /** |
| 89 * @param pos - must be UHASH_FIRST on first call, and untouched afterwards. |
| 90 * @see uhash_nextElement |
| 91 */ |
88 const UHashElement* nextElement(int32_t& pos) const; | 92 const UHashElement* nextElement(int32_t& pos) const; |
89 | 93 |
90 UKeyComparator* setKeyComparator(UKeyComparator*keyComp); | 94 UKeyComparator* setKeyComparator(UKeyComparator*keyComp); |
91 | 95 |
92 UValueComparator* setValueComparator(UValueComparator* valueComp); | 96 UValueComparator* setValueComparator(UValueComparator* valueComp); |
93 | 97 |
94 UBool equals(const Hashtable& that) const; | 98 UBool equals(const Hashtable& that) const; |
95 private: | 99 private: |
96 Hashtable(const Hashtable &other); // forbid copying of this class | 100 Hashtable(const Hashtable &other); // forbid copying of this class |
97 Hashtable &operator=(const Hashtable &other); // forbid copying of this clas
s | 101 Hashtable &operator=(const Hashtable &other); // forbid copying of this clas
s |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
199 return uhash_setValueComparator(hash, valueComp); | 203 return uhash_setValueComparator(hash, valueComp); |
200 } | 204 } |
201 | 205 |
202 inline UBool Hashtable::equals(const Hashtable& that)const{ | 206 inline UBool Hashtable::equals(const Hashtable& that)const{ |
203 return uhash_equals(hash, that.hash); | 207 return uhash_equals(hash, that.hash); |
204 } | 208 } |
205 U_NAMESPACE_END | 209 U_NAMESPACE_END |
206 | 210 |
207 #endif | 211 #endif |
208 | 212 |
OLD | NEW |