Search Options

Results per page
Sort
Preferred Languages
Advance

Results 71 - 80 of 199 for ImmutableMap (0.09 sec)

  1. android/guava-tests/test/com/google/common/collect/AbstractTableTest.java

          assertEquals(ImmutableMap.of(1, 'a', 3, 'c'), row);
          table.remove("foo", 3);
          assertEquals(ImmutableMap.of(1, 'a'), row);
          table.remove("foo", 1);
          assertEquals(ImmutableMap.of(), row);
          table.put("foo", 2, cellValue('b'));
          assertEquals(ImmutableMap.of(2, 'b'), row);
          row.clear();
          assertEquals(ImmutableMap.of(), row);
          table.put("foo", 5, cellValue('x'));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 15 17:36:06 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/CollectCollectors.java

            ImmutableMap.Builder::combine,
            ImmutableMap.Builder::buildOrThrow);
      }
    
      static <T extends @Nullable Object, K, V> Collector<T, ?, ImmutableMap<K, V>> toImmutableMap(
          Function<? super T, ? extends K> keyFunction,
          Function<? super T, ? extends V> valueFunction,
          BinaryOperator<V> mergeFunction) {
        checkNotNull(keyFunction);
        checkNotNull(valueFunction);
        checkNotNull(mergeFunction);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 17.1K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/collect/ImmutableBiMapTest.java

        ImmutableBiMap.Builder<String, Integer> builder =
            new ImmutableBiMap.Builder<String, Integer>(2).put("four", 4).put("one", 1);
        ImmutableMap<String, Integer> keyOrdered = builder.build();
        ImmutableMap<String, Integer> valueOrdered =
            builder.orderEntriesByValue(Ordering.natural()).build();
        assertMapEquals(keyOrdered, "four", 4, "one", 1);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 22.3K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/collect/ImmutableRangeMapTest.java

                  ImmutableRangeMap.<Integer, Integer>builder().put(range1, 1).put(range2, 2).build();
    
              ImmutableMap<Range<Integer>, Integer> expectedAsMap =
                  ImmutableMap.of(range1, 1, range2, 2);
              ImmutableMap<Range<Integer>, Integer> asMap = rangeMap.asMapOfRanges();
              ImmutableMap<Range<Integer>, Integer> descendingMap = rangeMap.asDescendingMapOfRanges();
              assertEquals(expectedAsMap, asMap);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 9.4K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/collect/RegularImmutableMapWithUnhashableValuesMapInterfaceTest.java

    import java.util.Map;
    
    @GwtIncompatible // GWT's ImmutableMap emulation is backed by java.util.HashMap.
    public class RegularImmutableMapWithUnhashableValuesMapInterfaceTest
        extends AbstractImmutableMapMapInterfaceTest<Integer, UnhashableObject> {
      @Override
      protected Map<Integer, UnhashableObject> makeEmptyMap() {
        return ImmutableMap.of();
      }
    
      @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Mar 09 02:18:08 UTC 2022
    - 1.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/ImmutableTable.java

            (ImmutableMap<C, V>) rowMap().get(rowKey), ImmutableMap.<C, V>of());
      }
    
      @Override
      public ImmutableSet<R> rowKeySet() {
        return rowMap().keySet();
      }
    
      /**
       * {@inheritDoc}
       *
       * <p>The value {@code Map<C, V>} instances in the returned map are {@link ImmutableMap} instances
       * as well.
       */
      @Override
      public abstract ImmutableMap<R, Map<C, V>> rowMap();
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  7. guava/src/com/google/common/graph/ImmutableGraph.java

        return ElementOrder.stable();
      }
    
      private static <N> ImmutableMap<N, GraphConnections<N, Presence>> getNodeConnections(
          Graph<N> graph) {
        // ImmutableMap.Builder maintains the order of the elements as inserted, so the map will have
        // whatever ordering the graph's nodes do, so ImmutableSortedMap is unnecessary even if the
        // input nodes are sorted.
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Feb 01 16:30:37 UTC 2022
    - 7.1K bytes
    - Viewed (0)
  8. guava/src/com/google/common/graph/ImmutableValueGraph.java

      }
    
      private static <N, V> ImmutableMap<N, GraphConnections<N, V>> getNodeConnections(
          ValueGraph<N, V> graph) {
        // ImmutableMap.Builder maintains the order of the elements as inserted, so the map will have
        // whatever ordering the graph's nodes do, so ImmutableSortedMap is unnecessary even if the
        // input nodes are sorted.
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Feb 01 16:30:37 UTC 2022
    - 7.7K bytes
    - Viewed (0)
  9. guava/src/com/google/common/cache/AbstractLoadingCache.java

        }
      }
    
      @Override
      public ImmutableMap<K, V> getAll(Iterable<? extends K> keys) throws ExecutionException {
        Map<K, V> result = Maps.newLinkedHashMap();
        for (K key : keys) {
          if (!result.containsKey(key)) {
            result.put(key, get(key));
          }
        }
        return ImmutableMap.copyOf(result);
      }
    
      @Override
      public final V apply(K key) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Aug 06 17:12:03 UTC 2022
    - 2.7K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/hash/MessageDigestHashFunctionTest.java

      //  - For example, the "SHA-1" algorithm might be referred to as "SHA1".
      //  - The algorithm name is not case-sensitive.
      private static final ImmutableMap<String, HashFunction> ALGORITHMS =
          new ImmutableMap.Builder<String, HashFunction>()
              .put("MD5", Hashing.md5())
              .put("SHA", Hashing.sha1()) // Not the official name, but still works
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Jul 23 14:22:54 UTC 2024
    - 4.1K bytes
    - Viewed (0)
Back to top