Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 69 for Writer (0.25 sec)

  1. guava-tests/test/com/google/common/io/CharSinkTest.java

      public void setUp() {
        sink = new TestCharSink();
      }
    
      public void testOpenBufferedStream() throws IOException {
        Writer writer = sink.openBufferedStream();
        assertTrue(sink.wasStreamOpened());
        assertFalse(sink.wasStreamClosed());
    
        writer.write(STRING);
        writer.close();
    
        assertTrue(sink.wasStreamClosed());
        assertEquals(STRING, sink.getString());
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.4K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/io/SourceSinkFactories.java

        public CharSink createSink() throws IOException {
          File file = createFile();
          if (initialString != null) {
            Writer writer = new OutputStreamWriter(new FileOutputStream(file), Charsets.UTF_8);
            try {
              writer.write(initialString);
            } finally {
              writer.close();
            }
            return Files.asCharSink(file, Charsets.UTF_8, FileWriteMode.APPEND);
          }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Apr 06 12:56:11 GMT 2023
    - 12.7K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/io/Files.java

       * java.nio.file.Files#write(java.nio.file.Path, byte[], java.nio.file.OpenOption...)}.
       *
       * @param from the bytes to write
       * @param to the destination file
       * @throws IOException if an I/O error occurs
       */
      public static void write(byte[] from, File to) throws IOException {
        asByteSink(to).write(from);
      }
    
      /**
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 33.1K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/util/concurrent/AbstractServiceTest.java

        final NoOpService service = new NoOpService();
        Thread waiter =
            new Thread() {
              @Override
              public void run() {
                service.awaitTerminated();
              }
            };
        waiter.start();
        service.startAsync().awaitRunning();
        assertEquals(State.RUNNING, service.state());
        service.stopAsync();
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 29.3K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/AbstractAbstractFutureTest.java

        // Check that we wait long enough anyway (presumably as long as MAX_VALUE nanos):
        TimedWaiterThread waiter = new TimedWaiterThread(future, Long.MAX_VALUE, SECONDS);
        waiter.start();
        waiter.awaitWaiting();
    
        future.set(1);
        waiter.join();
      }
    
      @J2ktIncompatible // TODO(b/324550390): Enable
      public void testSetNull() throws Exception {
        future.set(null);
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 13 14:28:25 GMT 2024
    - 15.5K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/MonitorTestCase.java

      // TODO: Test interrupts with both interruptible and uninterruptible monitor.
      // TODO: Test multiple waiters: If guard is still satisfied, signal next waiter.
      // TODO: Test multiple waiters: If guard is no longer satisfied, do not signal next waiter.
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Apr 26 20:07:17 GMT 2023
    - 7.9K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/ImmutableMapValues.java

      @Override
      @J2ktIncompatible // serialization
      @GwtIncompatible // serialization
      Object writeReplace() {
        return super.writeReplace();
      }
    
      // No longer used for new writes, but kept so that old data can still be read.
      @GwtIncompatible // serialization
      @J2ktIncompatible
      @SuppressWarnings("unused")
      private static class SerializedForm<V> implements Serializable {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Nov 30 21:54:06 GMT 2023
    - 3.6K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/CollectionFuture.java

       * on the fields of TimeoutFuture. This field is slightly different from the fields discussed
       * there: cancel() never reads this field, only writes to it. That makes the race here completely
       * harmless, rather than just 99.99% harmless.
       */
      @CheckForNull @LazyInit private List<@Nullable Present<V>> values;
    
      CollectionFuture(
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 3.8K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/collect/AbstractTableTest.java

    import java.util.Map;
    import org.checkerframework.checker.nullness.qual.NonNull;
    import org.checkerframework.checker.nullness.qual.Nullable;
    
    /**
     * Test cases for a {@link Table} implementation supporting reads and writes.
     *
     * @author Jared Levy
     * @author Louis Wasserman
     */
    @GwtCompatible
    @ElementTypesAreNonnullByDefault
    public abstract class AbstractTableTest<C extends @Nullable Character>
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Mar 04 16:54:11 GMT 2024
    - 6K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/util/concurrent/Monitor.java

       * non-satisfied before reacquiring the lock, and that other thread takes over the responsibility
       * of signaling the next waiter.
       *
       * Unlike the underlying Condition, if we are not careful, an interrupt *can* cause a signal to be
       * lost, because the signal may be sent to a condition whose sole waiter has just been
       * interrupted.
       *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 18:22:01 GMT 2023
    - 38.6K bytes
    - Viewed (0)
Back to top