Search Options

Results per page
Sort
Preferred Languages
Advance

Results 61 - 70 of 111 for minValue (0.17 sec)

  1. guava/src/com/google/common/primitives/Chars.java

       *     {@link Character#MAX_VALUE} if it is too large, or {@link Character#MIN_VALUE} if it is too
       *     small
       */
      public static char saturatedCast(long value) {
        if (value > Character.MAX_VALUE) {
          return Character.MAX_VALUE;
        }
        if (value < Character.MIN_VALUE) {
          return Character.MIN_VALUE;
        }
        return (char) value;
      }
    
      /**
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 24.2K bytes
    - Viewed (0)
  2. src/test/java/jcifs/smb1/dcerpc/ndr/NdrHyperTest.java

        }
    
        /**
         * Parameterised test for a selection of edge and typical values.
         */
        @ParameterizedTest(name = "Encode and decode {0}")
        @ValueSource(longs = { 0L, 1L, -1L, Long.MAX_VALUE, Long.MIN_VALUE })
        public void testEncodeWithVariousValues(long val) throws NdrException {
            NdrHyper hyper = new NdrHyper(val);
            // Create buffer with extra space for alignment
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 4.3K bytes
    - Viewed (0)
  3. src/test/java/jcifs/smb1/smb1/TransWaitNamedPipeResponseTest.java

         */
        @Nested
        @DisplayName("Wire format method behaviour")
        class WireFormatMethods {
            @ParameterizedTest
            @ValueSource(ints = { 0, 1, -1, Integer.MAX_VALUE, Integer.MIN_VALUE })
            @DisplayName("writeSetupWireFormat returns 0 for all indices")
            void writeSetupWireFormatReturnsZero(int index) {
                TransWaitNamedPipeResponse resp = new TransWaitNamedPipeResponse();
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 5.4K bytes
    - Viewed (0)
  4. src/test/java/jcifs/internal/SmbBasicFileInfoTest.java

                    Arguments.of(1, 1L, 1L, 1L, 1L), // ones
                    Arguments.of(123, 456L, 789L, 101112L, 131415L), // arbitrary positives
                    Arguments.of(Integer.MAX_VALUE, Long.MAX_VALUE, Long.MIN_VALUE, 999_999_999_999L, -1L), // extremes
                    Arguments.of(-1, -2L, -3L, -4L, -5L) // negative values
            );
        }
    
        // --- Mockito interaction: verify each getter is invoked and returns stubbed values ---
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 5.8K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/primitives/Ints.java

       *     {@link Integer#MAX_VALUE} if it is too large, or {@link Integer#MIN_VALUE} if it is too
       *     small
       */
      public static int saturatedCast(long value) {
        if (value > Integer.MAX_VALUE) {
          return Integer.MAX_VALUE;
        }
        if (value < Integer.MIN_VALUE) {
          return Integer.MIN_VALUE;
        }
        return (int) value;
      }
    
      /**
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 31.4K bytes
    - Viewed (0)
  6. src/main/java/jcifs/util/ServerResponseValidator.java

         */
        public int safeAdd(int a, int b) throws SmbException {
            totalValidations.incrementAndGet();
    
            long result = (long) a + (long) b;
            if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
                failedValidations.incrementAndGet();
                integerOverflowsPrevented.incrementAndGet();
                log.warn("Integer overflow in addition: {} + {} = {}", a, b, result);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 16.6K bytes
    - Viewed (0)
  7. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/FastFallbackExchangeFinder.kt

      override val routePlanner: RoutePlanner,
      private val taskRunner: TaskRunner,
    ) : ExchangeFinder {
      private val connectDelayNanos = TimeUnit.MILLISECONDS.toNanos(250L)
      private var nextTcpConnectAtNanos = Long.MIN_VALUE
    
      /**
       * Plans currently being connected, and that will later be added to [connectResults]. This is
       * mutated by the call thread only. If is accessed by background connect threads.
       */
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Dec 27 13:39:56 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/primitives/ImmutableLongArrayTest.java

      public static final class ImmutableLongArrayHeadSubListAsListGenerator
          extends TestLongListGenerator {
        @Override
        protected List<Long> create(Long[] elements) {
          Long[] suffix = {Long.MIN_VALUE, Long.MAX_VALUE};
          Long[] all = concat(elements, suffix);
          return makeArray(all).subArray(0, elements.length).asList();
        }
      }
    
      @J2ktIncompatible
      @GwtIncompatible // used only from suite
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 20.5K bytes
    - Viewed (0)
  9. src/test/java/jcifs/util/InputValidatorTest.java

            assertThrows(ArithmeticException.class, () -> InputValidator.safeAdd(Integer.MAX_VALUE, 1));
            assertThrows(ArithmeticException.class, () -> InputValidator.safeAdd(Integer.MIN_VALUE, -1));
        }
    
        @Test
        @DisplayName("Test safe integer multiplication")
        void testSafeMultiplication() {
            assertEquals(100, InputValidator.safeMultiply(10, 10));
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 11.9K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/primitives/ImmutableDoubleArrayTest.java

      public static final class ImmutableDoubleArrayHeadSubListAsListGenerator
          extends TestDoubleListGenerator {
        @Override
        protected List<Double> create(Double[] elements) {
          Double[] suffix = {Double.MIN_VALUE, Double.MAX_VALUE};
          Double[] all = concat(elements, suffix);
          return makeArray(all).subArray(0, elements.length).asList();
        }
      }
    
      @J2ktIncompatible
      @GwtIncompatible // used only from suite
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 21.5K bytes
    - Viewed (0)
Back to top