org.apache.activeio.packet
Class ByteBufferPacketPool
java.lang.Object
org.apache.activeio.packet.PacketPool
org.apache.activeio.packet.ByteBufferPacketPool
public final class ByteBufferPacketPool
- extends PacketPool
Provides a simple pool of ByteBuffer objects.
- Version:
- $Revision: 1.1 $
Constructor Summary |
ByteBufferPacketPool(int packetCount,
int packetSize)
Creates a pool of bufferCount ByteBuffers that are
directly allocated being bufferSize big. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ByteBufferPacketPool
public ByteBufferPacketPool(int packetCount,
int packetSize)
- Creates a pool of
bufferCount
ByteBuffers that are
directly allocated being bufferSize
big.
- Parameters:
packetCount
- the number of buffers that will be in the pool.packetSize
- the size of the buffers that are in the pool.
allocateNewPacket
protected Packet allocateNewPacket()
- Specified by:
allocateNewPacket
in class PacketPool
- Returns:
Copyright © 2005-2009 Apache Software Foundation. All Rights Reserved.