public final class ByteBufferPacketPool extends PacketPool
PacketPool.PooledPacket
DEFAULT_PACKET_SIZE, DEFAULT_POOL_SIZE
Constructor | Description |
---|---|
ByteBufferPacketPool(int packetCount,
int packetSize) |
Creates a pool of
bufferCount ByteBuffers that are
directly allocated being bufferSize big. |
Modifier and Type | Method | Description |
---|---|---|
protected Packet |
allocateNewPacket() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
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–2018. All rights reserved.