Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 10 of 137 for multisets (0.06 seconds)

  1. guava/src/com/google/common/collect/Multisets.java

       *
       * <p>Results are undefined if {@code multiset1} and {@code multiset2} are based on different
       * equivalence relations (as {@code HashMultiset} and {@code TreeMultiset} are).
       *
       * @since 14.0
       */
      public static <E extends @Nullable Object> Multiset<E> union(
          Multiset<? extends E> multiset1, Multiset<? extends E> multiset2) {
        checkNotNull(multiset1);
        checkNotNull(multiset2);
    
        return new ViewMultiset<E>() {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Sep 22 18:35:44 GMT 2025
    - 41.2K bytes
    - Click Count (0)
  2. android/guava/src/com/google/common/collect/Multisets.java

       *
       * <p>Results are undefined if {@code multiset1} and {@code multiset2} are based on different
       * equivalence relations (as {@code HashMultiset} and {@code TreeMultiset} are).
       *
       * @since 14.0
       */
      public static <E extends @Nullable Object> Multiset<E> union(
          Multiset<? extends E> multiset1, Multiset<? extends E> multiset2) {
        checkNotNull(multiset1);
        checkNotNull(multiset2);
    
        return new ViewMultiset<E>() {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Sep 22 18:35:44 GMT 2025
    - 41.3K bytes
    - Click Count (0)
  3. guava-testlib/src/com/google/common/collect/testing/google/MultisetForEachEntryTester.java

        assertEquals(expected, actual);
      }
    
      public void testForEachEntryDuplicates() {
        initThreeCopies();
        List<Entry<E>> expected = singletonList(Multisets.immutableEntry(e0(), 3));
        List<Entry<E>> actual = new ArrayList<>();
        getMultiset()
            .forEachEntry((element, count) -> actual.add(Multisets.immutableEntry(element, count)));
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Aug 07 16:05:33 GMT 2025
    - 3.2K bytes
    - Click Count (0)
  4. android/guava-testlib/src/com/google/common/collect/testing/google/MultisetCountTester.java

      }
    
      public void testCount_wrongType() {
        assertEquals(
            "multiset.count(wrongType) didn't return 0", 0, getMultiset().count(WrongType.VALUE));
      }
    
      /**
       * Returns {@link Method} instances for the read tests that assume multisets support duplicates so
       * that the test of {@code Multisets.forSet()} can suppress them.
       */
      @J2ktIncompatible
      @GwtIncompatible // reflection
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Aug 07 16:05:33 GMT 2025
    - 3.6K bytes
    - Click Count (0)
  5. guava-testlib/src/com/google/common/collect/testing/google/MultisetCountTester.java

      }
    
      public void testCount_wrongType() {
        assertEquals(
            "multiset.count(wrongType) didn't return 0", 0, getMultiset().count(WrongType.VALUE));
      }
    
      /**
       * Returns {@link Method} instances for the read tests that assume multisets support duplicates so
       * that the test of {@code Multisets.forSet()} can suppress them.
       */
      @J2ktIncompatible
      @GwtIncompatible // reflection
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Aug 07 16:05:33 GMT 2025
    - 3.6K bytes
    - Click Count (0)
  6. guava/src/com/google/common/collect/AbstractMultiset.java

       * and if, for each element, the two multisets have the same count.
       */
      @Override
      public final boolean equals(@Nullable Object object) {
        return Multisets.equalsImpl(this, object);
      }
    
      /**
       * {@inheritDoc}
       *
       * <p>This implementation returns the hash code of {@link Multiset#entrySet()}.
       */
      @Override
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sat Aug 09 01:14:59 GMT 2025
    - 5.9K bytes
    - Click Count (0)
  7. guava/src/com/google/common/collect/ImmutableSortedMultiset.java

            () -> TreeMultiset.create(comparator),
            (multiset, t) ->
                multiset.add(checkNotNull(elementFunction.apply(t)), countFunction.applyAsInt(t)),
            (multiset1, multiset2) -> {
              multiset1.addAll(multiset2);
              return multiset1;
            },
            (Multiset<E> multiset) -> copyOfSortedEntries(comparator, multiset.entrySet()));
      }
    
      /**
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Sep 22 21:07:18 GMT 2025
    - 29.5K bytes
    - Click Count (0)
  8. android/guava/src/com/google/common/collect/UnmodifiableSortedMultiset.java

    import com.google.common.annotations.J2ktIncompatible;
    import com.google.common.collect.Multisets.UnmodifiableMultiset;
    import com.google.errorprone.annotations.concurrent.LazyInit;
    import java.util.Comparator;
    import java.util.NavigableSet;
    import org.jspecify.annotations.Nullable;
    
    /**
     * Implementation of {@link Multisets#unmodifiableSortedMultiset(SortedMultiset)}, split out into
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Aug 07 16:05:33 GMT 2025
    - 4K bytes
    - Click Count (0)
  9. android/guava/src/com/google/common/collect/ImmutableMultiset.java

      @J2ktIncompatible
      private static final class EntrySetSerializedForm<E> implements Serializable {
        final ImmutableMultiset<E> multiset;
    
        EntrySetSerializedForm(ImmutableMultiset<E> multiset) {
          this.multiset = multiset;
        }
    
            Object readResolve() {
          return multiset.entrySet();
        }
      }
    
      @GwtIncompatible
      @J2ktIncompatible
      @Override
        abstract Object writeReplace();
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Sep 22 21:07:18 GMT 2025
    - 22.3K bytes
    - Click Count (0)
  10. android/guava/src/com/google/common/collect/ImmutableSortedMultiset.java

        return Collector.of(
            () -> TreeMultiset.create(comparator),
            (multiset, t) -> mapAndAdd(t, multiset, elementFunction, countFunction),
            (multiset1, multiset2) -> {
              multiset1.addAll(multiset2);
              return multiset1;
            },
            (Multiset<E> multiset) -> copyOfSortedEntries(comparator, multiset.entrySet()));
      }
    
      @IgnoreJRERequirement // helper for toImmutableSortedMultiset
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue May 13 17:27:14 GMT 2025
    - 35.2K bytes
    - Click Count (0)
Back to Top