Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for NullWriter (0.03 sec)

  1. guava/src/com/google/common/io/CharStreams.java

       * <p><b>Java 11+ users:</b> use {@link Writer#nullWriter()} instead. Note that the {@link
       * CharStreams} method returns a singleton writer whose {@code close} method has no effect, while
       * the {@link Writer#nullWriter()} method returns a new instance whose methods throw after the
       * instance is {@link Writer#close() closed}.
       *
       * @since 15.0
       */
      public static Writer nullWriter() {
        return NullWriter.INSTANCE;
      }
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Wed Jul 30 17:25:01 UTC 2025
    - 10.9K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/io/CharStreamsTest.java

        // create a null writer
        Writer nullWriter = CharStreams.nullWriter();
        // write to the writer
        nullWriter.write('n');
        String test = "Test string for NullWriter";
        nullWriter.write(test);
        nullWriter.write(test, 2, 10);
        nullWriter.append(null);
        nullWriter.append(null, 0, 4);
    
        assertThrows(IndexOutOfBoundsException.class, () -> nullWriter.append(null, -1, 4));
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Tue May 13 18:46:00 UTC 2025
    - 11.3K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/io/CharStreamsTest.java

        // create a null writer
        Writer nullWriter = CharStreams.nullWriter();
        // write to the writer
        nullWriter.write('n');
        String test = "Test string for NullWriter";
        nullWriter.write(test);
        nullWriter.write(test, 2, 10);
        nullWriter.append(null);
        nullWriter.append(null, 0, 4);
    
        assertThrows(IndexOutOfBoundsException.class, () -> nullWriter.append(null, -1, 4));
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Tue May 13 18:46:00 UTC 2025
    - 11.3K bytes
    - Viewed (0)
Back to top