Home / Function/ testRemoveItselfWithReplayError() — netty Function Reference

testRemoveItselfWithReplayError() — netty Function Reference

Architecture documentation for the testRemoveItselfWithReplayError() function in ReplayingDecoderTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  fa08f416_b7b8_071c_83f8_83cb90cdd60d["testRemoveItselfWithReplayError()"]
  342ea63b_1bca_5900_7b37_0cc8ddc3402d["ReplayingDecoderTest"]
  fa08f416_b7b8_071c_83f8_83cb90cdd60d -->|defined in| 342ea63b_1bca_5900_7b37_0cc8ddc3402d
  0bda4795_4d98_a4e1_d850_763cc1379646["decode()"]
  fa08f416_b7b8_071c_83f8_83cb90cdd60d -->|calls| 0bda4795_4d98_a4e1_d850_763cc1379646
  style fa08f416_b7b8_071c_83f8_83cb90cdd60d fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-base/src/test/java/io/netty/handler/codec/ReplayingDecoderTest.java lines 163–186

    @Test
    public void testRemoveItselfWithReplayError() {
        EmbeddedChannel channel = new EmbeddedChannel(new ReplayingDecoder() {
            private boolean removed;

            @Override
            protected void decode(ChannelHandlerContext ctx, ByteBuf in, List<Object> out) throws Exception {
                assertFalse(removed);
                ctx.pipeline().remove(this);

                in.readBytes(1000);

                removed = true;
            }
        });

        ByteBuf buf = Unpooled.wrappedBuffer(new byte[] {'a', 'b', 'c'});
        channel.writeInbound(buf.copy());
        ByteBuf b = channel.readInbound();

        assertEquals(b, buf, "Expect to have still all bytes in the buffer");
        b.release();
        buf.release();
    }

Domain

Subdomains

Calls

Frequently Asked Questions

What does testRemoveItselfWithReplayError() do?
testRemoveItselfWithReplayError() is a function in the netty codebase, defined in codec-base/src/test/java/io/netty/handler/codec/ReplayingDecoderTest.java.
Where is testRemoveItselfWithReplayError() defined?
testRemoveItselfWithReplayError() is defined in codec-base/src/test/java/io/netty/handler/codec/ReplayingDecoderTest.java at line 163.
What does testRemoveItselfWithReplayError() call?
testRemoveItselfWithReplayError() calls 1 function(s): decode.

Analyze Your Own Codebase

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

Try Supermodel Free