public final class ByteBufferPacketPool extends PacketPool
PacketPool.PooledPacket
DEFAULT_PACKET_SIZE, DEFAULT_POOL_SIZE
Constructor and Description |
---|
ByteBufferPacketPool(int packetCount,
int packetSize)
Creates a pool of
bufferCount ByteBuffers that are
directly allocated being bufferSize big. |
Modifier and Type | Method and Description |
---|---|
protected Packet |
allocateNewPacket() |
dispose, getPacket, waitForPacketsToReturn
public ByteBufferPacketPool(int packetCount, int packetSize)
bufferCount
ByteBuffers that are
directly allocated being bufferSize
big.packetCount
- the number of buffers that will be in the pool.packetSize
- the size of the buffers that are in the pool.protected Packet allocateNewPacket()
allocateNewPacket
in class PacketPool
Copyright © 2005–2016 The Apache Software Foundation. All rights reserved.