Package org.jenkinsci.remoting.util
Interface ByteBufferPool
-
- All Known Implementing Classes:
DirectByteBufferPool
,IOHub
,ProtocolStack
public interface ByteBufferPool
API for a pool ofByteBuffer
s.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ByteBuffer
acquire(int size)
Borrow a buffer from the pool.void
release(ByteBuffer buffer)
Returns a buffer to the pool.
-
-
-
Method Detail
-
acquire
ByteBuffer acquire(int size)
Borrow a buffer from the pool.- Parameters:
size
- The minimum size and initial limit of the buffer.- Returns:
- the buffer.
-
release
void release(ByteBuffer buffer)
Returns a buffer to the pool.- Parameters:
buffer
- the buffer.
-
-