Home / Function/ testIsWritable() — netty Function Reference

testIsWritable() — netty Function Reference

Architecture documentation for the testIsWritable() function in ReadOnlyDirectByteBufferBufTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  d781657c_6848_dcb3_b49a_356306795c71["testIsWritable()"]
  2436e747_1306_235e_86df_d12765b22d51["ReadOnlyDirectByteBufferBufTest"]
  d781657c_6848_dcb3_b49a_356306795c71 -->|defined in| 2436e747_1306_235e_86df_d12765b22d51
  style d781657c_6848_dcb3_b49a_356306795c71 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

buffer/src/test/java/io/netty/buffer/ReadOnlyDirectByteBufferBufTest.java lines 468–491

    @ParameterizedTest
    @EnumSource(DerivedParam.class)
    void testIsWritable(DerivedParam param) {
        ByteBuffer buffer = allocate(24);
        ByteBuf buf = buffer(buffer.asReadOnlyBuffer());
        buf.writerIndex(8);

        switch (param) {
            case None:
                break;
            case Duplicate:
                buf = buf.duplicate();
                break;
            case Slice:
                buf = buf.slice(0, buf.capacity()).writerIndex(8);
                break;
        }
        try {
            assertFalse(buf.isWritable());
            assertFalse(buf.isWritable(1));
        } finally {
            buf.release();
        }
    }

Domain

Subdomains

Frequently Asked Questions

What does testIsWritable() do?
testIsWritable() is a function in the netty codebase, defined in buffer/src/test/java/io/netty/buffer/ReadOnlyDirectByteBufferBufTest.java.
Where is testIsWritable() defined?
testIsWritable() is defined in buffer/src/test/java/io/netty/buffer/ReadOnlyDirectByteBufferBufTest.java at line 468.

Analyze Your Own Codebase

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

Try Supermodel Free