- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 11 for HashBiMap (0.04 sec)
-
android/guava/src/com/google/common/collect/HashBiMap.java
* @since 2.0 */ @GwtCompatible public final class HashBiMap<K extends @Nullable Object, V extends @Nullable Object> extends AbstractMap<K, V> implements BiMap<K, V>, Serializable { /** Returns a new, empty {@code HashBiMap} with the default initial capacity (16). */ public static <K extends @Nullable Object, V extends @Nullable Object> HashBiMap<K, V> create() { return create(16); } /**
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Dec 16 14:46:34 UTC 2025 - 37.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/HashBiMapTest.java
"chile", "peso", "switzerland", "franc"); HashBiMap<String, String> bimap = HashBiMap.create(map); assertEquals("dollar", bimap.get("canada")); assertEquals("canada", bimap.inverse().get("dollar")); } private static final int N = 1000; public void testBashIt() throws Exception { BiMap<Integer, Integer> bimap = HashBiMap.create(N); BiMap<Integer, Integer> inverse = bimap.inverse();
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Oct 28 16:03:47 UTC 2025 - 8.4K bytes - Viewed (0) -
android/guava-testlib/test/com/google/common/testing/FreshValueGeneratorTest.java
import com.google.common.base.Ticker; import com.google.common.collect.ArrayListMultimap; import com.google.common.collect.BiMap; import com.google.common.collect.HashBasedTable; import com.google.common.collect.HashBiMap; import com.google.common.collect.HashMultimap; import com.google.common.collect.HashMultiset; import com.google.common.collect.ImmutableBiMap; import com.google.common.collect.ImmutableCollection;
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Oct 28 16:03:47 UTC 2025 - 17.4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/MapsTest.java
assertThat(converter.convert(null)).isNull(); assertThat(converter.reverse().convert(null)).isNull(); } public void testAsConverter_isAView() throws Exception { BiMap<String, Integer> biMap = HashBiMap.create(); biMap.put("one", 1); biMap.put("two", 2); Converter<String, Integer> converter = Maps.asConverter(biMap); assertEquals((Integer) 1, converter.convert("one"));
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Dec 11 22:56:33 UTC 2025 - 62.7K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/BiMap.java
* bimap containing the same entries as this bimap but with reversed keys and values. * * <h3>Implementations</h3> * * <ul> * <li>{@link ImmutableBiMap} * <li>{@link HashBiMap} * <li>{@link EnumBiMap} * <li>{@link EnumHashBiMap} * </ul> * * <p>See the Guava User Guide article on <a href= * "https://github.com/google/guava/wiki/NewCollectionTypesExplained#bimap">{@code BiMap}</a>.
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Wed Aug 06 17:32:30 UTC 2025 - 4.2K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/EnumHashBiMapTest.java
} public void testCreate() { EnumHashBiMap<Currency, String> bimap = EnumHashBiMap.create(Currency.class); assertTrue(bimap.isEmpty()); assertEquals("{}", bimap.toString()); assertEquals(HashBiMap.create(), bimap); bimap.put(Currency.DOLLAR, "dollar"); assertEquals("dollar", bimap.get(Currency.DOLLAR)); assertEquals(Currency.DOLLAR, bimap.inverse().get("dollar")); }
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Oct 28 16:03:47 UTC 2025 - 8.4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/BenchmarkHelpers.java
} }; } enum BiMapImpl implements MapsImplEnum { HashBiMapImpl { @Override public <K extends Comparable<K>, V> BiMap<K, V> create(Map<K, V> map) { return HashBiMap.create(map); } }, ImmutableBiMapImpl { @Override public <K extends Comparable<K>, V> BiMap<K, V> create(Map<K, V> map) { return ImmutableBiMap.copyOf(map); } };Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Sun Aug 10 19:54:19 UTC 2025 - 12.5K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/EnumBiMapTest.java
public void testCreate() { EnumBiMap<Currency, Country> bimap = EnumBiMap.create(Currency.class, Country.class); assertTrue(bimap.isEmpty()); assertEquals("{}", bimap.toString()); assertEquals(HashBiMap.create(), bimap); bimap.put(Currency.DOLLAR, Country.CANADA); assertEquals(Country.CANADA, bimap.get(Currency.DOLLAR)); assertEquals(Currency.DOLLAR, bimap.inverse().get(Country.CANADA)); }
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Oct 28 16:03:47 UTC 2025 - 11.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/MapsTest.java
assertThat(converter.convert(null)).isNull(); assertThat(converter.reverse().convert(null)).isNull(); } public void testAsConverter_isAView() throws Exception { BiMap<String, Integer> biMap = HashBiMap.create(); biMap.put("one", 1); biMap.put("two", 2); Converter<String, Integer> converter = Maps.asConverter(biMap); assertEquals((Integer) 1, converter.convert("one"));
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Dec 11 22:56:33 UTC 2025 - 65K bytes - Viewed (0) -
guava/src/com/google/common/collect/Maps.java
* * <p>It is imperative that the user manually synchronize on the returned map when accessing any * of its collection views: * * {@snippet : * BiMap<Long, String> map = Maps.synchronizedBiMap(HashBiMap.create()); * ... * Set<Long> set = map.keySet(); // Needn't be in synchronized block * ... * synchronized (map) { // Synchronizing on map, not set!Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Mon Nov 17 22:50:48 UTC 2025 - 163.5K bytes - Viewed (0)