Home
last modified time | relevance | path

Searched refs:Entry (Results 1 – 25 of 203) sorted by relevance

123456789

/libcore/ojluni/src/main/java/java/lang/
DClassValue.java102 Entry<?>[] cache; in get()
103 Entry<T> e = probeHomeLocation(cache = getCacheCarefully(type), this); in get()
188 private static Entry<?>[] getCacheCarefully(Class<?> type) { in getCacheCarefully()
194 Entry<?>[] cache = map.getCache(); in getCacheCarefully()
200 private static final Entry<?>[] EMPTY_CACHE = { null };
208 private T getFromBackup(Entry<?>[] cache, Class<?> type) { in getFromBackup()
209 Entry<T> e = probeBackupLocations(cache, this); in getFromBackup()
217 Entry<T> castEntry(Entry<?> e) { return (Entry<T>) e; } in castEntry()
225 Entry<T> e = map.startEntry(this); in getFromHashMap()
243 boolean match(Entry<?> e) { in match()
[all …]
DThreadLocal.java165 ThreadLocalMap.Entry e = map.getEntry(this); in get()
329 static class Entry extends WeakReference<ThreadLocal<?>> { class in ThreadLocal.ThreadLocalMap
333 Entry(ThreadLocal<?> k, Object v) { in Entry() method in ThreadLocal.ThreadLocalMap.Entry
348 private Entry[] table;
387 table = new Entry[INITIAL_CAPACITY]; in ThreadLocalMap()
389 table[i] = new Entry(firstKey, firstValue); in ThreadLocalMap()
401 Entry[] parentTable = parentMap.table; in ThreadLocalMap()
404 table = new Entry[len]; in ThreadLocalMap()
406 for (Entry e : parentTable) { in ThreadLocalMap()
412 Entry c = new Entry(key, value); in ThreadLocalMap()
[all …]
DProcessEnvironment.java276 public Set<Map.Entry<String,String>> entrySet() { in entrySet()
297 for (Map.Entry<Variable,Value> entry : m.entrySet()) { in toEnvironmentBlock()
305 for (Map.Entry<Variable,Value> entry : m.entrySet()) { in toEnvironmentBlock()
328 implements Map.Entry<String,String>
330 private final Map.Entry<Variable,Value> e;
331 public StringEntry(Map.Entry<Variable,Value> e) {this.e = e;} in StringEntry()
346 extends AbstractSet<Map.Entry<String,String>>
348 private final Set<Map.Entry<Variable,Value>> s;
349 public StringEntrySet(Set<Map.Entry<Variable,Value>> s) {this.s = s;} in StringEntrySet()
353 public Iterator<Map.Entry<String,String>> iterator() { in iterator()
[all …]
/libcore/ojluni/src/test/java/util/concurrent/tck/
DEntryTest.java58 Map.Entry e = new AbstractMap.SimpleEntry(k1, v1); in testConstructor1()
67 Map.Entry s = new AbstractMap.SimpleImmutableEntry(k1, v1); in testConstructor2()
76 Map.Entry e2 = new AbstractMap.SimpleEntry(k1, v1); in testConstructor3()
77 Map.Entry e = new AbstractMap.SimpleEntry(e2); in testConstructor3()
86 Map.Entry s2 = new AbstractMap.SimpleImmutableEntry(k1, v1); in testConstructor4()
87 Map.Entry s = new AbstractMap.SimpleImmutableEntry(s2); in testConstructor4()
97 Map.Entry e2 = new AbstractMap.SimpleEntry(k1, v1); in testEquals()
98 Map.Entry e = new AbstractMap.SimpleEntry(e2); in testEquals()
99 Map.Entry s2 = new AbstractMap.SimpleImmutableEntry(k1, v1); in testEquals()
100 Map.Entry s = new AbstractMap.SimpleImmutableEntry(s2); in testEquals()
[all …]
DTreeSubMapTest.java232 Map.Entry e = (Map.Entry) it.next();
272 Map.Entry e1 = map.lowerEntry(three);
275 Map.Entry e2 = map.lowerEntry(six);
278 Map.Entry e3 = map.lowerEntry(one);
281 Map.Entry e4 = map.lowerEntry(zero);
290 Map.Entry e1 = map.higherEntry(three);
293 Map.Entry e2 = map.higherEntry(zero);
296 Map.Entry e3 = map.higherEntry(five);
299 Map.Entry e4 = map.higherEntry(six);
308 Map.Entry e1 = map.floorEntry(three);
[all …]
/libcore/jsr166-tests/src/test/java/jsr166/
DEntryTest.java35 Map.Entry e = new AbstractMap.SimpleEntry(k1, v1); in testConstructor1()
44 Map.Entry s = new AbstractMap.SimpleImmutableEntry(k1, v1); in testConstructor2()
53 Map.Entry e2 = new AbstractMap.SimpleEntry(k1, v1); in testConstructor3()
54 Map.Entry e = new AbstractMap.SimpleEntry(e2); in testConstructor3()
63 Map.Entry s2 = new AbstractMap.SimpleImmutableEntry(k1, v1); in testConstructor4()
64 Map.Entry s = new AbstractMap.SimpleImmutableEntry(s2); in testConstructor4()
74 Map.Entry e2 = new AbstractMap.SimpleEntry(k1, v1); in testEquals()
75 Map.Entry e = new AbstractMap.SimpleEntry(e2); in testEquals()
76 Map.Entry s2 = new AbstractMap.SimpleImmutableEntry(k1, v1); in testEquals()
77 Map.Entry s = new AbstractMap.SimpleImmutableEntry(s2); in testEquals()
[all …]
DTreeSubMapTest.java209 Map.Entry e = (Map.Entry) it.next();
249 Map.Entry e1 = map.lowerEntry(three);
252 Map.Entry e2 = map.lowerEntry(six);
255 Map.Entry e3 = map.lowerEntry(one);
258 Map.Entry e4 = map.lowerEntry(zero);
267 Map.Entry e1 = map.higherEntry(three);
270 Map.Entry e2 = map.higherEntry(zero);
273 Map.Entry e3 = map.higherEntry(five);
276 Map.Entry e4 = map.higherEntry(six);
285 Map.Entry e1 = map.floorEntry(three);
[all …]
DConcurrentSkipListSubMapTest.java252 Map.Entry e = (Map.Entry) it.next();
362 Map.Entry e1 = map.lowerEntry(three);
365 Map.Entry e2 = map.lowerEntry(six);
368 Map.Entry e3 = map.lowerEntry(one);
371 Map.Entry e4 = map.lowerEntry(zero);
380 Map.Entry e1 = map.higherEntry(three);
383 Map.Entry e2 = map.higherEntry(zero);
386 Map.Entry e3 = map.higherEntry(five);
389 Map.Entry e4 = map.higherEntry(six);
398 Map.Entry e1 = map.floorEntry(three);
[all …]
/libcore/ojluni/src/main/java/java/util/
DWeakHashMap.java159 Entry<K,V>[] table;
193 private Entry<K,V>[] newTable(int n) { in newTable()
194 return (Entry<K,V>[]) new Entry<?,?>[n]; in newTable()
285 private boolean matchesKey(Entry<K,V> e, Object key) { in matchesKey()
326 Entry<K,V> e = (Entry<K,V>) x; in expungeStaleEntries()
329 Entry<K,V> prev = table[i]; in expungeStaleEntries()
330 Entry<K,V> p = prev; in expungeStaleEntries()
332 Entry<K,V> next = p.next; in expungeStaleEntries()
354 private Entry<K,V>[] getTable() { in getTable()
403 Entry<K,V>[] tab = getTable(); in get()
[all …]
DLinkedHashMap.java223 static class Entry<K,V> extends HashMap.Node<K,V> { class in LinkedHashMap
224 Entry<K,V> before, after;
225 Entry(int hash, K key, V value, Node<K,V> next) { in Entry() method in LinkedHashMap.Entry
236 transient LinkedHashMap.Entry<K,V> head;
241 transient LinkedHashMap.Entry<K,V> tail;
254 private void linkNodeAtEnd(LinkedHashMap.Entry<K,V> p) { in linkNodeAtEnd()
256 LinkedHashMap.Entry<K,V> first = head; in linkNodeAtEnd()
265 LinkedHashMap.Entry<K,V> last = tail; in linkNodeAtEnd()
277 private void transferLinks(LinkedHashMap.Entry<K,V> src, in transferLinks()
278 LinkedHashMap.Entry<K,V> dst) { in transferLinks()
[all …]
DAbstractMap.java27 import java.util.Map.Entry;
116 Iterator<Entry<K,V>> i = entrySet().iterator(); in containsValue()
119 Entry<K,V> e = i.next(); in containsValue()
125 Entry<K,V> e = i.next(); in containsValue()
148 Iterator<Map.Entry<K,V>> i = entrySet().iterator(); in containsKey()
151 Entry<K,V> e = i.next(); in containsKey()
157 Entry<K,V> e = i.next(); in containsKey()
180 Iterator<Entry<K,V>> i = entrySet().iterator(); in get()
183 Entry<K,V> e = i.next(); in get()
189 Entry<K,V> e = i.next(); in get()
[all …]
DNavigableMap.java117 Map.Entry<K,V> lowerEntry(K key); in lowerEntry()
146 Map.Entry<K,V> floorEntry(K key); in floorEntry()
175 Map.Entry<K,V> ceilingEntry(K key); in ceilingEntry()
204 Map.Entry<K,V> higherEntry(K key); in higherEntry()
227 Map.Entry<K,V> firstEntry(); in firstEntry()
236 Map.Entry<K,V> lastEntry(); in lastEntry()
245 Map.Entry<K,V> pollFirstEntry(); in pollFirstEntry()
254 Map.Entry<K,V> pollLastEntry(); in pollLastEntry()
DSequencedMap.java151 default Map.Entry<K,V> firstEntry() { in firstEntry()
168 default Map.Entry<K,V> lastEntry() { in lastEntry()
187 default Map.Entry<K,V> pollFirstEntry() { in pollFirstEntry()
212 default Map.Entry<K,V> pollLastEntry() { in pollLastEntry()
334 default SequencedSet<Map.Entry<K, V>> sequencedEntrySet() { in sequencedEntrySet()
335 class SeqEntrySet extends AbstractMap.ViewCollection<Map.Entry<K, V>> in sequencedEntrySet()
336 implements SequencedSet<Map.Entry<K, V>> { in sequencedEntrySet()
337 Collection<Map.Entry<K, V>> view() { in sequencedEntrySet()
340 public SequencedSet<Map.Entry<K, V>> reversed() { in sequencedEntrySet()
DReverseOrderSortedMapView.java120 public Set<Entry<K, V>> entrySet() {
123 public Iterator<Entry<K, V>> iterator() { return descendingEntryIterator(base); }
145 public Map.Entry<K, V> firstEntry() {
149 public Map.Entry<K, V> lastEntry() {
153 public Map.Entry<K,V> pollFirstEntry() {
157 public Map.Entry<K,V> pollLastEntry() {
240 static <K, V> Iterator<Map.Entry<K, V>> descendingEntryIterator(SortedMap<K, V> map) {
248 public Map.Entry<K, V> next() {
259 static class ViewEntry<K, V> implements Map.Entry<K, V> {
275 return o instanceof Map.Entry<?, ?> e
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DSimpleEntryTest.java25 import java.util.Map.Entry;
34 static class NullEntry implements Entry {
52 Entry entryToPut = (Entry) map.entrySet().iterator().next(); in test_SimpleEntry_Constructor_LEntry()
53 Entry testEntry = new AbstractMap.SimpleEntry(entryToPut); in test_SimpleEntry_Constructor_LEntry()
71 Entry entry = new AbstractMap.SimpleEntry<Integer, String>(1, "test"); in test_SimpleEntry_getKey()
78 Entry entry = new AbstractMap.SimpleEntry<Integer, String>(1, "test"); in test_SimpleEntry_getValue()
85 Entry entry = new AbstractMap.SimpleEntry<Integer, String>(1, "test"); in test_SimpleEntry_setValue()
94 Entry entry = new AbstractMap.SimpleEntry<Integer, String>(1, "test"); in test_SimpleEntry_equals()
97 Entry entryToPut = (Entry) map.entrySet().iterator().next(); in test_SimpleEntry_equals()
98 Entry testEntry = new AbstractMap.SimpleEntry(entryToPut); in test_SimpleEntry_equals()
[all …]
DSimpleImmutableEntryTest.java26 import java.util.Map.Entry;
35 static class NullEntry implements Entry {
53 Entry entryToPut = (Entry) map.entrySet().iterator().next(); in test_SimpleImmutableEntry_Constructor_LEntry()
54 Entry testEntry = new AbstractMap.SimpleImmutableEntry(entryToPut); in test_SimpleImmutableEntry_Constructor_LEntry()
72 Entry entry = new AbstractMap.SimpleImmutableEntry<Integer, String>(1, "test"); in test_SimpleImmutableEntry_getKey()
79 Entry entry = new AbstractMap.SimpleImmutableEntry<Integer, String>(1, "test"); in test_SimpleImmutableEntry_getValue()
86 Entry entry = new AbstractMap.SimpleImmutableEntry<Integer, String>(1, "test"); in test_SimpleImmutableEntry_setValue()
104 Entry entry = new AbstractMap.SimpleImmutableEntry<Integer, String>(1, "test"); in test_SimpleImmutableEntry_equals()
107 Entry entryToPut = (Entry) map.entrySet().iterator().next(); in test_SimpleImmutableEntry_equals()
108 Entry testEntry = new AbstractMap.SimpleImmutableEntry(entryToPut); in test_SimpleImmutableEntry_equals()
[all …]
/libcore/ojluni/src/main/java/java/io/
DExpiringCache.java38 private Map<String,Entry> map;
44 static class Entry { class in ExpiringCache
48 Entry(long timestamp, String val) { in Entry() method in ExpiringCache.Entry
67 map = new LinkedHashMap<String,Entry>() { in ExpiringCache()
73 protected boolean removeEldestEntry(Map.Entry<String,ExpiringCache.Entry> eldest) { in ExpiringCache()
83 Entry entry = entryFor(key); in get()
94 Entry entry = entryFor(key); in put()
99 map.put(key, new Entry(System.currentTimeMillis(), val)); in put()
107 private Entry entryFor(String key) { in entryFor()
108 Entry entry = map.get(key); in entryFor()
/libcore/ojluni/src/test/java/util/Map/
DEntryComparators.java46 Comparator<Map.Entry<K, V>> ck, in assertPairComparison()
47 Comparator<Map.Entry<K, V>> cv) { in assertPairComparison()
48 final Map.Entry<K, V> p11 = new AbstractMap.SimpleImmutableEntry<>(k1, v1); in assertPairComparison()
49 final Map.Entry<K, V> p12 = new AbstractMap.SimpleImmutableEntry<>(k1, v2); in assertPairComparison()
50 final Map.Entry<K, V> p21 = new AbstractMap.SimpleImmutableEntry<>(k2, v1); in assertPairComparison()
51 final Map.Entry<K, V> p22 = new AbstractMap.SimpleImmutableEntry<>(k2, v2); in assertPairComparison()
69 Comparator<Map.Entry<K, V>> cmp = ck.thenComparing(cv); in assertPairComparison()
91 Map.Entry.<Integer, String>comparingByKey(),
92 Map.Entry.<Integer, String>comparingByValue());
126 Map.Entry.<People, People>comparingByKey(cmp),
[all …]
DEntrySetIterator.java41 Set<Map.Entry<String, String>> entrySet = map.entrySet(); in testEntrySetIterator()
42 Iterator<Map.Entry<String, String>> iterator = entrySet.iterator(); in testEntrySetIterator()
47 Set<Map.Entry<String, String>> copy1 = new HashSet<>(entrySet); in testEntrySetIterator()
48 Set<Map.Entry<String, String>> copy2 = new HashSet<>(entrySet); in testEntrySetIterator()
/libcore/luni/src/test/java/libcore/java/util/
DLinkedHashMapTest.java51 Map.Entry<String, String> newest = null; in test_getOrDefault()
52 for (Map.Entry<String, String> e : m.entrySet()) { in test_getOrDefault()
72 Map.Entry<String, String> newest = null; in test_putIfAbsent()
73 for (Map.Entry<String, String> e : m.entrySet()) { in test_putIfAbsent()
81 for (Map.Entry<String, String> e : m.entrySet()) { in test_putIfAbsent()
104 Map.Entry<String, String> newest = null; in test_replace$K$V$V()
105 for (Map.Entry<String, String> e : m.entrySet()) { in test_replace$K$V$V()
114 for (Map.Entry<String, String> e : m.entrySet()) { in test_replace$K$V$V()
131 Map.Entry<String, String> newest = null; in test_replace$K$V()
132 for (Map.Entry<String, String> e : m.entrySet()) { in test_replace$K$V()
[all …]
DOldMapEntryTest.java28 Map.Entry me = null;
75 me = (Map.Entry)i.next(); in testSetValue()
89 Map.Entry me1 = (Map.Entry)i.next(); in testEquals()
97 Map.Entry me1 = (Map.Entry)i.next(); in testHashCode()
108 me = (Map.Entry)i.next(); in setUp()
DMapOfTest.java84 Map.Entry[] entries = { entry("duplicateKey", 23), entry("duplicateKey", 42) }; in duplicates_sameKey()
89 Map.Entry[] entries = { entry("duplicateKey", 42), entry("duplicateKey", 42) }; in duplicates_sameEntry()
94 Map.Entry[] entries = { in duplicates_manyElements()
107 assertThrowsNpe(() -> Map.ofEntries((Map.Entry[]) null)); in nullEntries()
108 assertThrowsNpe(() -> Map.ofEntries((Map.Entry) null)); in nullEntries()
109 List<Map.Entry<String, Integer>> sampleEntries = new ArrayList<>(); in nullEntries()
115 Map.Entry[] entries = sampleEntries.subList(0, size).toArray( in nullEntries()
116 (Map.Entry<String, Integer>[]) new Map.Entry[0]); in nullEntries()
134 List<Map.Entry<String, Integer>> sampleEntries = new ArrayList<>(); in manyEntries()
139 Map.Entry[] entries = sampleEntries.subList(0, size).toArray( in manyEntries()
[all …]
/libcore/ojluni/annotations/flagged_api/java/util/
DNavigableMap.annotated.java42 public java.util.Map.Entry<K,V> lowerEntry(K key); in lowerEntry()
46 public java.util.Map.Entry<K,V> floorEntry(K key); in floorEntry()
50 public java.util.Map.Entry<K,V> ceilingEntry(K key); in ceilingEntry()
54 public java.util.Map.Entry<K,V> higherEntry(K key); in higherEntry()
58 public java.util.Map.Entry<K,V> firstEntry(); in firstEntry()
60 public java.util.Map.Entry<K,V> lastEntry(); in lastEntry()
62 public java.util.Map.Entry<K,V> pollFirstEntry(); in pollFirstEntry()
64 public java.util.Map.Entry<K,V> pollLastEntry(); in pollLastEntry()
/libcore/ojluni/src/main/java/java/time/format/
DDateTimeTextProvider.java90 import java.util.Map.Entry;
108 …private static final ConcurrentMap<Entry<TemporalField, Locale>, Object> CACHE = new ConcurrentHas…
110 …private static final Comparator<Entry<String, Long>> COMPARATOR = new Comparator<Entry<String, Lon…
112 public int compare(Entry<String, Long> obj1, Entry<String, Long> obj2) {
223 …public Iterator<Entry<String, Long>> getTextIterator(TemporalField field, TextStyle style, Locale … in getTextIterator()
248 public Iterator<Entry<String, Long>> getTextIterator(Chronology chrono, TemporalField field, in getTextIterator()
279 List<Entry<String, Long>> list = new ArrayList<>(map.size()); in getTextIterator()
282 for (Map.Entry<String, Integer> entry : map.entrySet()) { in getTextIterator()
295 for (Map.Entry<String, Integer> entry : map.entrySet()) { in getTextIterator()
300 for (Map.Entry<String, Integer> entry : map.entrySet()) { in getTextIterator()
[all …]
/libcore/ojluni/src/test/java/util/EnumMap/
DToArray.java50 Map.Entry[] x1 = new Map.Entry[3]; in testToArray()
52 Map.Entry[] x2 = m.entrySet().toArray(x1); in testToArray()
58 Map.Entry[] y1 = new Map.Entry[1]; in testToArray()
59 Map.Entry[] y2 = m.entrySet().toArray(y1); in testToArray()

123456789