Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 15 for compose (0.17 sec)

  1. android/guava/src/com/google/common/collect/Comparators.java

       * @param b second value to compare.
       * @throws ClassCastException if the parameters are not <i>mutually comparable</i> using the given
       *     comparator.
       * @since 30.0
       */
      @ParametricNullness
      public static <T extends @Nullable Object> T max(
          @ParametricNullness T a, @ParametricNullness T b, Comparator<? super T> comparator) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/ImmutableSortedSet.java

        // Pretend the comparator can compare anything. If it turns out it can't
        // compare a and b, we should get a CCE or NPE on the subsequent line. Only methods
        // that are spec'd to throw CCE and NPE should call this.
        @SuppressWarnings({"unchecked", "nullness"})
        Comparator<@Nullable Object> unsafeComparator = (Comparator<@Nullable Object>) comparator;
        return unsafeComparator.compare(a, b);
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 36.9K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/collect/ImmutableSortedMap.java

     * Comparator} or {@link Comparable} type whose comparison behavior is <i>inconsistent with
     * equals</i>. That is, {@code a.compareTo(b)} or {@code comparator.compare(a, b)} should equal zero
     * <i>if and only if</i> {@code a.equals(b)}. If this advice is not followed, the resulting map will
     * not correctly obey its specification.
     *
     * <p>See the Guava User Guide article on <a href=
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 53.2K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/Multisets.java

      }
    
      private static final class DecreasingCount implements Comparator<Entry<?>> {
        static final Comparator<Entry<?>> INSTANCE = new DecreasingCount();
    
        @Override
        public int compare(Entry<?> entry1, Entry<?> entry2) {
          return entry2.getCount() - entry1.getCount(); // subtracting two nonnegative integers
        }
      }
    
      /**
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 41.7K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/collect/Maps.java

          Predicate<? super K> keyPredicate) {
        return compose(keyPredicate, Maps.<K>keyFunction());
      }
    
      static <V extends @Nullable Object> Predicate<Entry<?, V>> valuePredicateOnEntries(
          Predicate<? super V> valuePredicate) {
        return compose(valuePredicate, Maps.<V>valueFunction());
      }
    
      /**
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 159.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/ImmutableMap.java

        }
    
        /**
         * Configures this {@code Builder} to order entries by value according to the specified
         * comparator.
         *
         * <p>The sort order is stable, that is, if two entries have values that compare as equivalent,
         * the entry that was inserted first will be first in the built map's iteration order.
         *
         * @throws IllegalStateException if this method was already called
         * @since 19.0
         */
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 41.7K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/ImmutableBiMap.java

        }
    
        /**
         * Configures this {@code Builder} to order entries by value according to the specified
         * comparator.
         *
         * <p>The sort order is stable, that is, if two entries have values that compare as equivalent,
         * the entry that was inserted first will be first in the built map's iteration order.
         *
         * @throws IllegalStateException if this method was already called
         * @since 19.0
         */
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 22.4K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/collect/Ordering.java

       * instead (but note that it does not guarantee which tied minimum element is returned).
       *
       * @param a value to compare, returned if less than or equal to the rest.
       * @param b value to compare
       * @param c value to compare
       * @param rest values to compare
       * @throws ClassCastException if the parameters are not <i>mutually comparable</i> under this
       *     ordering.
       */
      @ParametricNullness
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Apr 24 19:38:27 GMT 2024
    - 39.4K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/Sets.java

        if (set.comparator() != null
            && set.comparator() != Ordering.natural()
            && range.hasLowerBound()
            && range.hasUpperBound()) {
          checkArgument(
              set.comparator().compare(range.lowerEndpoint(), range.upperEndpoint()) <= 0,
              "set is using a custom comparator which is inconsistent with the natural ordering.");
        }
        if (range.hasLowerBound() && range.hasUpperBound()) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 77.4K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/collect/ImmutableMapTest.java

        private final int value;
    
        ClassWithTerribleHashCode(int value) {
          this.value = value;
        }
    
        @Override
        public int compareTo(ClassWithTerribleHashCode that) {
          return Integer.compare(this.value, that.value);
        }
    
        @Override
        public boolean equals(@Nullable Object x) {
          return x instanceof ClassWithTerribleHashCode
              && ((ClassWithTerribleHashCode) x).value == value;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Apr 30 14:39:16 GMT 2024
    - 37.3K bytes
    - Viewed (0)
Back to top