Package io.netty.buffer
Class PoolArena.DirectArena
- java.lang.Object
-
- io.netty.buffer.PoolArena<java.nio.ByteBuffer>
-
- io.netty.buffer.PoolArena.DirectArena
-
- All Implemented Interfaces:
PoolArenaMetric
static final class PoolArena.DirectArena extends PoolArena<java.nio.ByteBuffer>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class io.netty.buffer.PoolArena
PoolArena.DirectArena, PoolArena.HeapArena, PoolArena.SizeClass
-
-
Field Summary
-
Fields inherited from class io.netty.buffer.PoolArena
chunkSize, directMemoryCacheAlignment, directMemoryCacheAlignmentMask, HAS_UNSAFE, numSmallSubpagePools, numThreadCaches, numTinySubpagePools, pageShifts, pageSize, parent, subpageOverflowMask
-
-
Constructor Summary
Constructors Constructor Description DirectArena(PooledByteBufAllocator parent, int pageSize, int maxOrder, int pageShifts, int chunkSize, int directMemoryCacheAlignment)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private static java.nio.ByteBufferallocateDirect(int capacity)protected voiddestroyChunk(PoolChunk<java.nio.ByteBuffer> chunk)(package private) booleanisDirect()protected voidmemoryCopy(java.nio.ByteBuffer src, int srcOffset, PooledByteBuf<java.nio.ByteBuffer> dstBuf, int length)protected PooledByteBuf<java.nio.ByteBuffer>newByteBuf(int maxCapacity)protected PoolChunk<java.nio.ByteBuffer>newChunk(int pageSize, int maxOrder, int pageShifts, int chunkSize)protected PoolChunk<java.nio.ByteBuffer>newUnpooledChunk(int capacity)(package private) intoffsetCacheLine(java.nio.ByteBuffer memory)-
Methods inherited from class io.netty.buffer.PoolArena
alignCapacity, allocate, chunkLists, finalize, findSubpagePoolHead, free, freeChunk, isTiny, isTinyOrSmall, normalizeCapacity, numActiveAllocations, numActiveBytes, numActiveHugeAllocations, numActiveNormalAllocations, numActiveSmallAllocations, numActiveTinyAllocations, numAllocations, numChunkLists, numDeallocations, numHugeAllocations, numHugeDeallocations, numNormalAllocations, numNormalDeallocations, numSmallAllocations, numSmallDeallocations, numSmallSubpages, numThreadCaches, numTinyAllocations, numTinyDeallocations, numTinySubpages, reallocate, smallIdx, smallSubpages, tinyIdx, tinySubpages, toString
-
-
-
-
Constructor Detail
-
DirectArena
DirectArena(PooledByteBufAllocator parent, int pageSize, int maxOrder, int pageShifts, int chunkSize, int directMemoryCacheAlignment)
-
-
Method Detail
-
offsetCacheLine
int offsetCacheLine(java.nio.ByteBuffer memory)
-
newChunk
protected PoolChunk<java.nio.ByteBuffer> newChunk(int pageSize, int maxOrder, int pageShifts, int chunkSize)
-
newUnpooledChunk
protected PoolChunk<java.nio.ByteBuffer> newUnpooledChunk(int capacity)
- Specified by:
newUnpooledChunkin classPoolArena<java.nio.ByteBuffer>
-
allocateDirect
private static java.nio.ByteBuffer allocateDirect(int capacity)
-
destroyChunk
protected void destroyChunk(PoolChunk<java.nio.ByteBuffer> chunk)
- Specified by:
destroyChunkin classPoolArena<java.nio.ByteBuffer>
-
newByteBuf
protected PooledByteBuf<java.nio.ByteBuffer> newByteBuf(int maxCapacity)
- Specified by:
newByteBufin classPoolArena<java.nio.ByteBuffer>
-
memoryCopy
protected void memoryCopy(java.nio.ByteBuffer src, int srcOffset, PooledByteBuf<java.nio.ByteBuffer> dstBuf, int length)- Specified by:
memoryCopyin classPoolArena<java.nio.ByteBuffer>
-
-