Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 33 for radix (0.09 sec)

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

        }
        if (radix < Character.MIN_RADIX || radix > Character.MAX_RADIX) {
          throw new NumberFormatException("illegal radix: " + radix);
        }
    
        int maxSafePos = ParseOverflowDetection.maxSafeDigits[radix] - 1;
        long value = 0;
        for (int pos = 0; pos < string.length(); pos++) {
          int digit = Character.digit(string.charAt(pos), radix);
          if (digit == -1) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Aug 12 21:04:48 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/primitives/UnsignedBytesTest.java

        for (int radix = Character.MIN_RADIX; radix <= Character.MAX_RADIX; radix++) {
          for (int i = 0; i <= 0xff; i++) {
            assertThat(UnsignedBytes.parseUnsignedByte(Integer.toString(i, radix), radix))
                .isEqualTo((byte) i);
          }
          assertParseFails(Integer.toString(1000, radix), radix);
          assertParseFails(Integer.toString(-1, radix), radix);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/primitives/UnsignedIntsTest.java

        for (long a : UNSIGNED_INTS) {
          for (int radix = Character.MIN_RADIX; radix <= Character.MAX_RADIX; radix++) {
            assertThat(UnsignedInts.parseUnsignedInt(Long.toString(a, radix), radix))
                .isEqualTo((int) a);
          }
        }
      }
    
      public void testParseIntWithRadixLimits() {
        // loops through all legal radix values.
        for (int r = Character.MIN_RADIX; r <= Character.MAX_RADIX; r++) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 12.5K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/primitives/UnsignedLongTest.java

        }
      }
    
      @GwtIncompatible // too slow
      public void testToStringRadix() {
        for (int radix = Character.MIN_RADIX; radix <= Character.MAX_RADIX; radix++) {
          for (long l : TEST_LONGS) {
            UnsignedLong value = UnsignedLong.fromLongBits(l);
            assertThat(value.toString(radix)).isEqualTo(value.bigIntegerValue().toString(radix));
          }
        }
      }
    
      public void testToStringRadixQuick() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/primitives/UnsignedLongTest.java

        }
      }
    
      @GwtIncompatible // too slow
      public void testToStringRadix() {
        for (int radix = Character.MIN_RADIX; radix <= Character.MAX_RADIX; radix++) {
          for (long l : TEST_LONGS) {
            UnsignedLong value = UnsignedLong.fromLongBits(l);
            assertThat(value.toString(radix)).isEqualTo(value.bigIntegerValue().toString(radix));
          }
        }
      }
    
      public void testToStringRadixQuick() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/primitives/IntsTest.java

        for (int radix = Character.MIN_RADIX; radix <= Character.MAX_RADIX; radix++) {
          radixEncodeParseAndAssertEquals(0, radix);
          radixEncodeParseAndAssertEquals(8000, radix);
          radixEncodeParseAndAssertEquals(-8000, radix);
          radixEncodeParseAndAssertEquals(GREATEST, radix);
          radixEncodeParseAndAssertEquals(LEAST, radix);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 29.1K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/primitives/UnsignedInts.java

       * unsigned.
       *
       * <p><b>Java 8+ users:</b> use {@link Integer#toUnsignedString(int, int)} instead.
       *
       * @param x the value to convert to a string.
       * @param radix the radix to use while working with {@code x}
       * @throws IllegalArgumentException if {@code radix} is not between {@link Character#MIN_RADIX}
       *     and {@link Character#MAX_RADIX}.
       */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 21:17:54 UTC 2024
    - 13.7K bytes
    - Viewed (0)
  8. guava/src/com/google/common/primitives/UnsignedInts.java

       * unsigned.
       *
       * <p><b>Java 8+ users:</b> use {@link Integer#toUnsignedString(int, int)} instead.
       *
       * @param x the value to convert to a string.
       * @param radix the radix to use while working with {@code x}
       * @throws IllegalArgumentException if {@code radix} is not between {@link Character#MIN_RADIX}
       *     and {@link Character#MAX_RADIX}.
       */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 21:17:54 UTC 2024
    - 13.7K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/primitives/LongsTest.java

      public void testTryParse_radix() {
        for (int radix = Character.MIN_RADIX; radix <= Character.MAX_RADIX; radix++) {
          radixEncodeParseAndAssertEquals((long) 0, radix);
          radixEncodeParseAndAssertEquals((long) 8000, radix);
          radixEncodeParseAndAssertEquals((long) -8000, radix);
          radixEncodeParseAndAssertEquals(MAX_VALUE, radix);
          radixEncodeParseAndAssertEquals(MIN_VALUE, radix);
          assertWithMessage("Radix: " + radix)
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 29.8K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/primitives/Ints.java

       * @param string the string representation of an integer value
       * @param radix the radix to use when parsing
       * @return the integer value represented by {@code string} using {@code radix}, or {@code null} if
       *     {@code string} has a length of zero or cannot be parsed as an integer value
       * @throws IllegalArgumentException if {@code radix < Character.MIN_RADIX} or {@code radix >
       *     Character.MAX_RADIX}
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 25 18:05:56 UTC 2024
    - 31K bytes
    - Viewed (0)
Back to top