- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 34 for getInstance (0.16 sec)
-
guava-tests/test/com/google/common/reflect/ImmutableTypeToInstanceMapTest.java
.put(int.class, 1) .build(); assertEquals(2, map.size()); assertEquals(0, (int) map.getInstance(Integer.class)); assertEquals(0, (int) map.getInstance(TypeToken.of(Integer.class))); assertEquals(1, (int) map.getInstance(int.class)); assertEquals(1, (int) map.getInstance(TypeToken.of(int.class))); } public void testParameterizedType() {
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Thu Feb 22 17:15:24 GMT 2024 - 6.8K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/hash/MacHashFunctionTest.java
} catch (IllegalStateException expected) { } finally { Providers.setProviderList(providers); } } public void testMultipleUpdates() throws Exception { Mac mac = Mac.getInstance("HmacSHA1"); mac.init(SHA1_KEY); mac.update("hello".getBytes(UTF_8)); mac.update("world".getBytes(UTF_8)); assertEquals( HashCode.fromBytes(mac.doFinal()),
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 13.8K bytes - Viewed (0) -
android/guava/src/com/google/common/reflect/TypeToInstanceMap.java
* that may have been bound to a subtype. * * <p>{@code getInstance(Foo.class)} is equivalent to {@code * getInstance(TypeToken.of(Foo.class))}. */ @CheckForNull <T extends @NonNull B> T getInstance(Class<T> type); /** * Returns the value the specified type is mapped to, or {@code null} if no entry for this type is
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Sat Apr 22 01:15:23 GMT 2023 - 3.8K bytes - Viewed (0) -
guava-tests/benchmark/com/google/common/hash/MessageDigestCreationBenchmark.java
private MessageDigest md; @BeforeExperiment void setUp() throws Exception { md = MessageDigest.getInstance(algorithm); } @Benchmark int getInstance(int reps) throws Exception { int retValue = 0; for (int i = 0; i < reps; i++) { retValue ^= MessageDigest.getInstance(algorithm).getDigestLength(); } return retValue; } @Benchmark int clone(int reps) throws Exception {
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Mon Dec 04 17:37:03 GMT 2017 - 1.6K bytes - Viewed (0) -
guava-tests/test/com/google/common/hash/MacHashFunctionTest.java
} catch (IllegalStateException expected) { } finally { Providers.setProviderList(providers); } } public void testMultipleUpdates() throws Exception { Mac mac = Mac.getInstance("HmacSHA1"); mac.init(SHA1_KEY); mac.update("hello".getBytes(UTF_8)); mac.update("world".getBytes(UTF_8)); assertEquals( HashCode.fromBytes(mac.doFinal()),
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 13.8K bytes - Viewed (0) -
guava-tests/test/com/google/common/reflect/MutableTypeToInstanceMapTest.java
assertNull(map.getInstance(Integer.class)); assertNull(map.putInstance(int.class, 0)); assertNull(map.putInstance(Integer.class, 1)); assertEquals(2, map.size()); assertEquals(0, (int) map.getInstance(int.class)); assertEquals(1, (int) map.getInstance(Integer.class)); assertEquals(0, (int) map.putInstance(int.class, null));
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Thu Feb 22 17:15:24 GMT 2024 - 7.9K bytes - Viewed (0) -
android/guava/src/com/google/common/reflect/ImmutableTypeToInstanceMap.java
this.delegate = delegate; } @Override @CheckForNull public <T extends B> T getInstance(TypeToken<T> type) { return trustedGet(type.rejectTypeVariables()); } @Override @CheckForNull public <T extends B> T getInstance(Class<T> type) { return trustedGet(TypeToken.of(type)); } /**
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Tue Feb 01 20:46:24 GMT 2022 - 5.6K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/reflect/ImmutableTypeToInstanceMapTest.java
.put(int.class, 1) .build(); assertEquals(2, map.size()); assertEquals(0, (int) map.getInstance(Integer.class)); assertEquals(0, (int) map.getInstance(TypeToken.of(Integer.class))); assertEquals(1, (int) map.getInstance(int.class)); assertEquals(1, (int) map.getInstance(TypeToken.of(int.class))); } public void testParameterizedType() {
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Thu Feb 22 17:15:24 GMT 2024 - 6.8K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ClassToInstanceMap.java
* A map, each entry of which maps a Java <a href="http://tinyurl.com/2cmwkz">raw type</a> to an * instance of that type. In addition to implementing {@code Map}, the additional type-safe * operations {@link #putInstance} and {@link #getInstance} are available. * * <p>Like any other {@code Map<Class, Object>}, this map may contain entries for primitive types, * and a primitive type and its corresponding wrapper type may map to different values. *
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Sat Jun 17 14:40:53 GMT 2023 - 3K bytes - Viewed (0) -
guava-tests/benchmark/com/google/common/hash/MessageDigestAlgorithmBenchmark.java
this.algorithmName = algorithmName; this.hashFn = hashFn; } public MessageDigest getMessageDigest() { try { return MessageDigest.getInstance(algorithmName); } catch (NoSuchAlgorithmException e) { throw new AssertionError(e); } } public HashFunction getHashFunction() { return hashFn; } }
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Mon Dec 04 17:37:03 GMT 2017 - 3.5K bytes - Viewed (0)