/external/guava/guava-tests/test/com/google/common/cache/ |
D | CacheManualTest.java | 46 assertNull(cache.asMap().get(one)); in testGetIfPresent() 47 assertFalse(cache.asMap().containsKey(one)); in testGetIfPresent() 48 assertFalse(cache.asMap().containsValue(two)); in testGetIfPresent() 56 assertNull(cache.asMap().get(two)); in testGetIfPresent() 57 assertFalse(cache.asMap().containsKey(two)); in testGetIfPresent() 58 assertFalse(cache.asMap().containsValue(one)); in testGetIfPresent() 68 assertSame(two, cache.asMap().get(one)); in testGetIfPresent() 69 assertTrue(cache.asMap().containsKey(one)); in testGetIfPresent() 70 assertTrue(cache.asMap().containsValue(two)); in testGetIfPresent() 78 assertNull(cache.asMap().get(two)); in testGetIfPresent() [all …]
|
D | PopulatedCachesTest.java | 62 assertMapSize(cache.asMap(), WARMUP_SIZE); in testSize_populated() 73 assertTrue(cache.asMap().containsKey(entry.getKey())); in testContainsKey_found() 74 assertTrue(cache.asMap().containsValue(entry.getValue())); in testContainsKey_found() 90 assertSame(entry.getValue(), cache.asMap().put(entry.getKey(), newValue)); in testPut_populated() 94 assertNull(cache.asMap().put(newKey, entry.getValue())); in testPut_populated() 113 assertSame(entry.getValue(), cache.asMap().putIfAbsent(entry.getKey(), newValue)); in testPutIfAbsent_populated() 115 assertNull(cache.asMap().putIfAbsent(newKey, entry.getValue())); in testPutIfAbsent_populated() 133 cache.asMap().putAll(ImmutableMap.of(newKey, newValue)); in testPutAll_populated() 148 assertSame(entry.getValue(), cache.asMap().replace(entry.getKey(), newValue)); in testReplace_populated() 149 assertTrue(cache.asMap().replace(entry.getKey(), newValue, entry.getValue())); in testReplace_populated() [all …]
|
D | CacheReferencesTest.java | 69 assertTrue(cache.asMap().containsKey(key)); 70 assertTrue(cache.asMap().containsValue(value)); 80 assertFalse(cache.asMap().isEmpty()); 83 assertTrue(cache.asMap().isEmpty()); 84 assertFalse(cache.asMap().containsKey(key)); 85 assertFalse(cache.asMap().containsValue(value)); 97 assertEquals(ImmutableSet.of(key1, key2), cache.asMap().keySet()); 98 ASSERT.that(cache.asMap().values()).hasContentsAnyOrder(value1, value2); 100 cache.asMap().entrySet()); 113 assertFalse(cache.asMap().containsKey(key1)); [all …]
|
D | EmptyCachesTest.java | 116 Set<Object> keys = cache.asMap().keySet(); in testKeySet_nullToArray() 130 cache.asMap().keySet().add(1); in testKeySet_addNotSupported() 137 cache.asMap().keySet().addAll(asList(1, 2)); in testKeySet_addNotSupported() 149 Set<Object> keys = cache.asMap().keySet(); in testKeySet_clear() 158 Set<Object> keys = cache.asMap().keySet(); in testKeySet_empty_remove() 174 Set<Object> keys = cache.asMap().keySet(); in testKeySet_remove() 193 Collection<Object> values = cache.asMap().values(); in testValues_nullToArray() 207 cache.asMap().values().add(1); in testValues_addNotSupported() 214 cache.asMap().values().addAll(asList(1, 2)); in testValues_addNotSupported() 226 Collection<Object> values = cache.asMap().values(); in testValues_clear() [all …]
|
D | CacheExpirationTest.java | 142 assertEquals(1, Iterators.size(cache.asMap().entrySet().iterator())); in runExpirationTest() 143 assertEquals(1, Iterators.size(cache.asMap().keySet().iterator())); in runExpirationTest() 144 assertEquals(1, Iterators.size(cache.asMap().values().iterator())); in runExpirationTest() 149 assertFalse(cache.asMap().containsKey(KEY_PREFIX + i)); in runExpirationTest() 154 assertFalse(cache.asMap().containsKey(KEY_PREFIX + i)); in runExpirationTest() 262 Set<Integer> keySet = cache.asMap().keySet(); in testExpirationOrder_access() 314 Set<Integer> keySet = cache.asMap().keySet(); in testExpirationOrder_write() 334 cache.asMap().put(3, -3); in testExpirationOrder_write() 339 cache.asMap().replace(4, -4); in testExpirationOrder_write() 367 Set<Integer> keySet = cache.asMap().keySet(); in testExpirationOrder_writeAccess() [all …]
|
/external/guava/guava-tests/test/com/google/common/collect/ |
D | MapConstraintsTest.java | 235 ASSERT.that(constrained.asMap().get("foo")).hasContentsInOrder(1); in testConstrainedMultimapLegal() 236 assertNull(constrained.asMap().get("missing")); in testConstrainedMultimapLegal() 237 assertEquals(multimap.asMap(), constrained.asMap()); in testConstrainedMultimapLegal() 256 assertFalse(constrained.asMap().values() instanceof Serializable); in testConstrainedMultimapLegal() 258 constrained.asMap().values().iterator(); in testConstrainedMultimapLegal() 271 = multimap.asMap().entrySet().iterator().next(); in testConstrainedTypePreservingList() 284 = multimap.asMap().entrySet().iterator().next(); in testConstrainedTypePreservingRandomAccessList() 297 = multimap.asMap().entrySet().iterator().next(); in testConstrainedTypePreservingSet() 310 = multimap.asMap().entrySet().iterator().next(); in testConstrainedTypePreservingSortedSet() 398 constrained.asMap().get("foo").add(TEST_VALUE); in testConstrainedMultimapIllegal() [all …]
|
D | ImmutableMultimapAsMapImplementsMapTest.java | 40 return ImmutableMultimap.<String, Integer>of().asMap(); in makeEmptyMap() 46 return ImmutableMultimap.copyOf(delegate).asMap(); in makePopulatedMap()
|
D | ImmutableSetMultimapAsMapImplementsMapTest.java | 40 return ImmutableSetMultimap.<String, Integer>of().asMap(); in makeEmptyMap() 46 return ImmutableSetMultimap.copyOf(delegate).asMap(); in makePopulatedMap()
|
D | UnmodifiableMultimapAsMapImplementsMapTest.java | 41 LinkedHashMultimap.<String, Integer>create()).asMap(); in makeEmptyMap() 47 return Multimaps.unmodifiableMultimap(delegate).asMap(); in makePopulatedMap()
|
D | ConstrainedMultimapAsMapImplementsMapTest.java | 43 .asMap(); in makeEmptyMap() 51 .asMap(); in makePopulatedMap()
|
D | MultimapsTransformValuesAsMapTest.java | 41 Functions.<Integer> identity()).asMap(); in makeEmptyMap() 48 .transformValues(delegate, Functions.<Integer> identity()).asMap(); in makePopulatedMap()
|
D | TreeMultimapNaturalTest.java | 99 multimap.asMap().entrySet().iterator(); in testOrderedAsMapEntries() 451 return multimap.asMap().entrySet().iterator(); in testAsSetIteration() 456 assertEquals(newHashSet(elements), multimap.asMap().entrySet()); in testAsSetIteration() 518 SortedMap<String, Collection<Integer>> asMap = multimap.asMap(); in testTreeMultimapAsMapSorted() local 519 assertEquals(Ordering.natural(), asMap.comparator()); in testTreeMultimapAsMapSorted() 520 assertEquals("foo", asMap.firstKey()); in testTreeMultimapAsMapSorted() 521 assertEquals("tree", asMap.lastKey()); in testTreeMultimapAsMapSorted() 526 asMap.tailMap("g")); in testTreeMultimapAsMapSorted() 528 asMap.headMap("h")); in testTreeMultimapAsMapSorted() 530 asMap.subMap("g", "h")); in testTreeMultimapAsMapSorted()
|
D | ForMapMultimapAsMapImplementsMapTest.java | 41 return Multimaps.forMap(map).asMap(); in makeEmptyMap() 49 return Multimaps.forMap(map).asMap(); in makePopulatedMap()
|
D | MultimapsFilterEntriesAsMapTest.java | 55 return multimap.asMap(); in makeEmptyMap() 61 return multimap.asMap(); in makePopulatedMap()
|
D | MultimapsTest.java | 293 unmodifiable.asMap().entrySet(), multimap.asMap().entrySet()); in checkUnmodifiableMultimap() 299 ASSERT.that(unmodifiable.asMap().get("bar")).hasContentsAnyOrder(5, -1); in checkUnmodifiableMultimap() 300 assertNull(unmodifiable.asMap().get("missing")); in checkUnmodifiableMultimap() 303 assertFalse(unmodifiable.asMap().values() instanceof Serializable); in checkUnmodifiableMultimap() 435 ASSERT.that(multimapView.asMap().entrySet()).hasContentsAnyOrder( in testForMap() 478 Map<String, Collection<Integer>> asMap = Multimaps.forMap(map).asMap(); in testForMapAsMap() local 479 assertEquals(Collections.singleton(1), asMap.get("foo")); in testForMapAsMap() 480 assertNull(asMap.get("cow")); in testForMapAsMap() 481 assertTrue(asMap.containsKey("foo")); in testForMapAsMap() 482 assertFalse(asMap.containsKey("cow")); in testForMapAsMap() [all …]
|
D | SubMapMultimapAsMapImplementsMapTest.java | 50 return createMultimap().asMap().subMap("e", "p"); in makeEmptyMap() 59 return multimap.asMap().subMap("e", "p"); in makePopulatedMap()
|
/external/guava/guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ |
D | Multimaps.java | 419 @Override public Map<K, Collection<V>> asMap() { in asMap() method in Multimaps.UnmodifiableMultimap 423 = Collections.unmodifiableMap(delegate.asMap()); in asMap() 941 transient Map<K, Collection<V>> asMap; 1069 public Map<K, Collection<V>> asMap() { 1070 Map<K, Collection<V>> result = asMap; 1072 asMap = result = new AsMap(); 1083 return this.size() == that.size() && asMap().equals(that.asMap()); 1331 private transient Map<K, Collection<V2>> asMap; 1333 @Override public Map<K, Collection<V2>> asMap() { 1334 if (asMap == null) { [all …]
|
/external/guava/guava/src/com/google/common/collect/ |
D | Multimaps.java | 508 @Override public Map<K, Collection<V>> asMap() { in asMap() method in Multimaps.UnmodifiableMultimap 512 = Collections.unmodifiableMap(delegate.asMap()); in asMap() 1030 transient Map<K, Collection<V>> asMap; 1158 public Map<K, Collection<V>> asMap() { 1159 Map<K, Collection<V>> result = asMap; 1161 asMap = result = new AsMap(); 1172 return this.size() == that.size() && asMap().equals(that.asMap()); 1420 private transient Map<K, Collection<V2>> asMap; 1422 @Override public Map<K, Collection<V2>> asMap() { 1423 if (asMap == null) { [all …]
|
D | AbstractSortedSetMultimap.java | 109 @Override public Map<K, Collection<V>> asMap() { in asMap() method in AbstractSortedSetMultimap 110 return super.asMap(); in asMap()
|
D | AbstractListMultimap.java | 104 @Override public Map<K, Collection<V>> asMap() { in asMap() method in AbstractListMultimap 105 return super.asMap(); in asMap()
|
D | AbstractSetMultimap.java | 104 @Override public Map<K, Collection<V>> asMap() { in asMap() method in AbstractSetMultimap 105 return super.asMap(); in asMap()
|
/external/guava/guava-testlib/src/com/google/common/collect/testing/google/ |
D | UnmodifiableCollectionTests.java | 289 multimap.asMap().entrySet(), in assertMultimapIsUnmodifiable() 297 multimap.asMap().entrySet().iterator().next().getValue(); in assertMultimapIsUnmodifiable() 381 multimap.asMap().remove(sampleKey); in assertMultimapIsUnmodifiable() 390 multimap.asMap().get(presentKey).remove(sampleValue); in assertMultimapIsUnmodifiable() 397 multimap.asMap().values().iterator().next().remove(sampleValue); in assertMultimapIsUnmodifiable() 404 ((Collection<?>) multimap.asMap().values().toArray()[0]).clear(); in assertMultimapIsUnmodifiable()
|
/external/guava/guava/src/com/google/common/util/concurrent/ |
D | AtomicLongMap.java | 265 private transient Map<K, Long> asMap; field in AtomicLongMap 270 public Map<K, Long> asMap() { in asMap() method in AtomicLongMap 271 Map<K, Long> result = asMap; in asMap() 272 return (result == null) ? asMap = createAsMap() : result; in asMap()
|
/external/protobuf/java/src/test/java/com/google/protobuf/ |
D | UnknownFieldSetTest.java | 76 unknownFields.asMap().entrySet()) { in getBizarroData() 137 assertEquals(1, group.asMap().size()); in testGroup() 199 assertTrue(fields.asMap().isEmpty()); in testClear() 221 assertEquals(1, destination.getUnknownFields().asMap().size()); in testParseKnownAndUnknown() 249 assertEquals(unknownFields.asMap().size(), in testUnknownExtensions() 250 message.getUnknownFields().asMap().size()); in testUnknownExtensions()
|
/external/chromium_org/third_party/protobuf/java/src/test/java/com/google/protobuf/ |
D | UnknownFieldSetTest.java | 76 unknownFields.asMap().entrySet()) { in getBizarroData() 137 assertEquals(1, group.asMap().size()); in testGroup() 199 assertTrue(fields.asMap().isEmpty()); in testClear() 221 assertEquals(1, destination.getUnknownFields().asMap().size()); in testParseKnownAndUnknown() 249 assertEquals(unknownFields.asMap().size(), in testUnknownExtensions() 250 message.getUnknownFields().asMap().size()); in testUnknownExtensions()
|