Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 55 for Scharf (0.14 sec)

  1. android/guava-tests/test/com/google/common/escape/UnicodeEscaperTest.java

            new UnicodeEscaper() {
              // Canonical escaper method that only escapes lower case ASCII letters.
              @Override
              protected char @Nullable [] escape(int cp) {
                return ('a' <= cp && cp <= 'z') ? new char[] {Character.toUpperCase((char) cp)} : null;
              }
              // Inefficient implementation that defines all letters as escapable.
              @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Apr 19 19:24:36 GMT 2023
    - 6.2K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/escape/ArrayBasedEscaperMapTest.java

        // Exhaustively check all mappings (an int index avoids wrapping).
        for (int n = 0; n < replacementArray.length; ++n) {
          char c = (char) n;
          if (replacementArray[n] != null) {
            assertEquals(map.get(c), new String(replacementArray[n]));
          } else {
            assertFalse(map.containsKey(c));
          }
        }
      }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 2.5K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/io/CharSourceTester.java

        this.source = factory.createSource(data);
      }
    
      public void testOpenStream() throws IOException {
        Reader reader = source.openStream();
    
        StringWriter writer = new StringWriter();
        char[] buf = new char[64];
        int read;
        while ((read = reader.read(buf)) != -1) {
          writer.write(buf, 0, read);
        }
        reader.close();
        writer.close();
    
        assertExpectedString(writer.toString());
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 7.3K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/collect/TreeTraverserTest.java

    @ElementTypesAreNonnullByDefault
    public class TreeTraverserTest extends TestCase {
      private static class Node {
        final char value;
    
        Node(char value) {
          this.value = value;
        }
      }
    
      private static final class Tree extends Node {
        final List<Tree> children;
    
        public Tree(char value, Tree... children) {
          super(value);
          this.children = Arrays.asList(children);
        }
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Feb 19 20:34:55 GMT 2024
    - 3.3K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/io/LittleEndianDataInputStream.java

      }
    
      /**
       * Reads a char as specified by {@link DataInputStream#readChar()}, except using little-endian
       * byte order.
       *
       * @return the next two bytes of the input stream, interpreted as a {@code char} in little-endian
       *     byte order
       * @throws IOException if an I/O error occurs
       */
      @CanIgnoreReturnValue // to skip some bytes
      @Override
      public char readChar() throws IOException {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed May 17 14:35:11 GMT 2023
    - 7.3K bytes
    - Viewed (0)
  6. guava-tests/benchmark/com/google/common/io/ByteSourceAsCharSourceReadBenchmark.java

              // TODO(lukes): in a real implementation we would need to handle overflow conditions
              int maxChars = (int) (size.get().intValue() * cs.newDecoder().maxCharsPerByte());
              char[] buffer = new char[maxChars];
              int bufIndex = 0;
              int remaining = buffer.length;
              try (InputStreamReader reader = new InputStreamReader(byteSource.openStream(), cs)) {
                int nRead = 0;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 5.2K bytes
    - Viewed (0)
  7. android/guava-tests/benchmark/com/google/common/io/ByteSourceAsCharSourceReadBenchmark.java

              // TODO(lukes): in a real implementation we would need to handle overflow conditions
              int maxChars = (int) (size.get().intValue() * cs.newDecoder().maxCharsPerByte());
              char[] buffer = new char[maxChars];
              int bufIndex = 0;
              int remaining = buffer.length;
              try (InputStreamReader reader = new InputStreamReader(byteSource.openStream(), cs)) {
                int nRead = 0;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 5.2K bytes
    - Viewed (0)
  8. guava/src/com/google/common/base/Defaults.java

       * false} for {@code boolean} and {@code '\0'} for {@code char}. For non-primitive types and
       * {@code void}, {@code null} is returned.
       */
      @SuppressWarnings("unchecked")
      @CheckForNull
      public static <T> T defaultValue(Class<T> type) {
        checkNotNull(type);
        if (type.isPrimitive()) {
          if (type == boolean.class) {
            return (T) Boolean.FALSE;
          } else if (type == char.class) {
            return (T) Character.valueOf('\0');
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 23 15:09:35 GMT 2023
    - 2.2K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/io/CharStreamsCopyBenchmark.java

        sb.ensureCapacity(size);
        for (int k = 0; k < size; k++) {
          // [9-127) includes all ascii non-control characters
          sb.append((char) (random.nextInt(127 - 9) + 9));
        }
        data = sb.toString();
      }
    
      @Benchmark
      public long timeCopy(int reps) throws IOException {
        long r = 0;
        final String localData = data;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Feb 23 18:59:54 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  10. android/guava-tests/benchmark/com/google/common/io/CharStreamsCopyBenchmark.java

        sb.ensureCapacity(size);
        for (int k = 0; k < size; k++) {
          // [9-127) includes all ascii non-control characters
          sb.append((char) (random.nextInt(127 - 9) + 9));
        }
        data = sb.toString();
      }
    
      @Benchmark
      public long timeCopy(int reps) throws IOException {
        long r = 0;
        final String localData = data;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 23 18:59:54 GMT 2023
    - 3.2K bytes
    - Viewed (0)
Back to top