Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for falseFirst (0.11 sec)

  1. android/guava/src/com/google/common/primitives/Booleans.java

       *
       * <p>This is particularly useful in Java 8+ in combination with {@code Comparator.comparing},
       * e.g. {@code Comparator.comparing(Foo::hasBar, falseFirst())}.
       *
       * @since 21.0
       */
      public static Comparator<Boolean> falseFirst() {
        return BooleanComparator.FALSE_FIRST;
      }
    
      /**
       * Returns a hash code for {@code value}; equal to the result of invoking {@code ((Boolean)
       * value).hashCode()}.
       *
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  2. guava/src/com/google/common/primitives/Booleans.java

       *
       * <p>This is particularly useful in Java 8+ in combination with {@code Comparator.comparing},
       * e.g. {@code Comparator.comparing(Foo::hasBar, falseFirst())}.
       *
       * @since 21.0
       */
      public static Comparator<Boolean> falseFirst() {
        return BooleanComparator.FALSE_FIRST;
      }
    
      /**
       * Returns a hash code for {@code value}; equal to the result of invoking {@code ((Boolean)
       * value).hashCode()}.
       *
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/collect/ComparisonChainTest.java

        Bar(boolean isBaz) {
          this.isBaz = isBaz;
        }
    
        boolean isBaz() {
          return isBaz;
        }
      }
    
      /**
       * Validates that {@link Booleans#trueFirst()} and {@link Booleans#falseFirst()} can be used with
       * {@link Comparator} when replacing {@link ComparisonChain#compareTrueFirst} and {@link
       * ComparisonChain#compareFalseFirst}, as we document.
       */
      public void testTrueFirstFalseFirst() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Feb 27 13:27:08 UTC 2024
    - 7.5K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/primitives/BooleansTest.java

      }
    
      public void testFalseFirst() {
        assertThat(Booleans.falseFirst().compare(true, true)).isEqualTo(0);
        assertThat(Booleans.falseFirst().compare(false, false)).isEqualTo(0);
        assertThat(Booleans.falseFirst().compare(false, true)).isLessThan(0);
        assertThat(Booleans.falseFirst().compare(true, false)).isGreaterThan(0);
      }
    
      public void testCompare() {
        for (boolean x : VALUES) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 24.8K bytes
    - Viewed (0)
Back to top