@Internal public interface BufferBlocker
Modifier and Type | Method and Description |
---|---|
void |
add(BufferOrEvent boe)
Adds a buffer or event to the blocker.
|
void |
close()
Cleans up all the resources in the current sequence.
|
long |
getBytesBlocked()
Gets the number of bytes blocked in the current sequence.
|
BufferOrEventSequence |
rollOverReusingResources()
Starts a new sequence of buffers and event reusing the same resources and
returns the current sequence of buffers for reading.
|
BufferOrEventSequence |
rollOverWithoutReusingResources()
Starts a new sequence of buffers and event without reusing the same resources and
returns the current sequence of buffers for reading.
|
void add(BufferOrEvent boe) throws IOException
boe
- The buffer or event to be added into the blocker.IOException
BufferOrEventSequence rollOverWithoutReusingResources() throws IOException
IOException
BufferOrEventSequence rollOverReusingResources() throws IOException
IOException
void close() throws IOException
IOException
long getBytesBlocked()
Copyright © 2014–2019 The Apache Software Foundation. All rights reserved.