Home / Function/ testToByteBuffer2() — netty Function Reference

testToByteBuffer2() — netty Function Reference

Architecture documentation for the testToByteBuffer2() function in AbstractByteBufTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  36216921_ddbe_e0b4_2d0b_4f1ec9e76a25["testToByteBuffer2()"]
  6540f2d1_cdad_6705_dd1d_9a24e2e53242["AbstractByteBufTest"]
  36216921_ddbe_e0b4_2d0b_4f1ec9e76a25 -->|defined in| 6540f2d1_cdad_6705_dd1d_9a24e2e53242
  5e8f57f5_06c7_0249_fefc_c6eeb8b82dee["assertRemainingEquals()"]
  36216921_ddbe_e0b4_2d0b_4f1ec9e76a25 -->|calls| 5e8f57f5_06c7_0249_fefc_c6eeb8b82dee
  style 36216921_ddbe_e0b4_2d0b_4f1ec9e76a25 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

buffer/src/test/java/io/netty/buffer/AbstractByteBufTest.java lines 2522–2534

    @Test
    public void testToByteBuffer2() {
        assumeTrue(buffer.nioBufferCount() == 1);

        byte[] value = new byte[buffer.capacity()];
        random.nextBytes(value);
        buffer.clear();
        buffer.writeBytes(value);

        for (int i = 0; i < buffer.capacity() - BLOCK_SIZE + 1; i += BLOCK_SIZE) {
            assertRemainingEquals(ByteBuffer.wrap(value, i, BLOCK_SIZE), buffer.nioBuffer(i, BLOCK_SIZE));
        }
    }

Domain

Subdomains

Frequently Asked Questions

What does testToByteBuffer2() do?
testToByteBuffer2() is a function in the netty codebase, defined in buffer/src/test/java/io/netty/buffer/AbstractByteBufTest.java.
Where is testToByteBuffer2() defined?
testToByteBuffer2() is defined in buffer/src/test/java/io/netty/buffer/AbstractByteBufTest.java at line 2522.
What does testToByteBuffer2() call?
testToByteBuffer2() calls 1 function(s): assertRemainingEquals.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free