Interface WritableBufferedByteChannel

  • All Superinterfaces:
    java.lang.AutoCloseable, java.nio.channels.Channel, java.io.Closeable, java.nio.channels.WritableByteChannel

    public interface WritableBufferedByteChannel
    extends java.nio.channels.WritableByteChannel
    Extends WritableByteChannel with buffered (i.e. non-flushable) write operations, see writeBuffered(ByteBuffer). The messages are buffered and the channel is flushed after the buffer has overflew.
    The method WritableByteChannel.write(ByteBuffer) flushes every written message. You can flush the channel by writing the zero length of ByteBuffer.
    • Method Detail

      • writeBuffered

        void writeBuffered​(java.nio.ByteBuffer src)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • countBufferOverflows

        long countBufferOverflows()