testNormalizeAlignedCapacity() — netty Function Reference
Architecture documentation for the testNormalizeAlignedCapacity() function in PoolArenaTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 6b688ebe_ae19_0d98_ef5f_190695bd7661["testNormalizeAlignedCapacity()"] a309ea5f_39fd_34ca_b674_7a5f76e6b7eb["PoolArenaTest"] 6b688ebe_ae19_0d98_ef5f_190695bd7661 -->|defined in| a309ea5f_39fd_34ca_b674_7a5f76e6b7eb style 6b688ebe_ae19_0d98_ef5f_190695bd7661 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
buffer/src/test/java/io/netty/buffer/PoolArenaTest.java lines 46–56
@Test
public void testNormalizeAlignedCapacity() {
SizeClasses sc = new SizeClasses(PAGE_SIZE, PAGE_SHIFTS, CHUNK_SIZE, 64);
PoolArena<ByteBuffer> arena = new PoolArena.DirectArena(null, sc);
int[] reqCapacities = {0, 15, 510, 1024, 1023, 1025};
int[] expectedResult = {64, 64, 512, 1024, 1024, 1280};
for (int i = 0; i < reqCapacities.length; i ++) {
assertEquals(expectedResult[i],
arena.sizeClass.sizeIdx2size(arena.sizeClass.size2SizeIdx(reqCapacities[i])));
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does testNormalizeAlignedCapacity() do?
testNormalizeAlignedCapacity() is a function in the netty codebase, defined in buffer/src/test/java/io/netty/buffer/PoolArenaTest.java.
Where is testNormalizeAlignedCapacity() defined?
testNormalizeAlignedCapacity() is defined in buffer/src/test/java/io/netty/buffer/PoolArenaTest.java at line 46.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free