Home / Class/ EventOutboundHandler Class — netty Architecture

EventOutboundHandler Class — netty Architecture

Architecture documentation for the EventOutboundHandler class in EmbeddedChannelTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  356d79f4_595f_2fb5_fb0a_e211560e9654["EventOutboundHandler"]
  e148d706_0313_c998_93c5_83ac65559c84["EmbeddedChannelTest.java"]
  356d79f4_595f_2fb5_fb0a_e211560e9654 -->|defined in| e148d706_0313_c998_93c5_83ac65559c84
  14682a54_a3c2_37f7_b68d_c1ff77b7e22b["disconnect()"]
  356d79f4_595f_2fb5_fb0a_e211560e9654 -->|method| 14682a54_a3c2_37f7_b68d_c1ff77b7e22b
  4fc8a753_5665_2ca5_69db_dc1006272b05["close()"]
  356d79f4_595f_2fb5_fb0a_e211560e9654 -->|method| 4fc8a753_5665_2ca5_69db_dc1006272b05
  63b4df60_afde_a6cb_c3af_dbdb438b5ceb["Integer()"]
  356d79f4_595f_2fb5_fb0a_e211560e9654 -->|method| 63b4df60_afde_a6cb_c3af_dbdb438b5ceb

Relationship Graph

Source Code

transport/src/test/java/io/netty/channel/embedded/EmbeddedChannelTest.java lines 830–851

    private static final class EventOutboundHandler extends ChannelOutboundHandlerAdapter {
        static final Integer DISCONNECT = 0;
        static final Integer CLOSE = 1;

        private final Queue<Integer> queue = new ArrayDeque<Integer>();

        @Override
        public void disconnect(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception {
            queue.add(DISCONNECT);
            promise.setSuccess();
        }

        @Override
        public void close(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception {
            queue.add(CLOSE);
            promise.setSuccess();
        }

        Integer pollEvent() {
            return queue.poll();
        }
    }

Frequently Asked Questions

What is the EventOutboundHandler class?
EventOutboundHandler is a class in the netty codebase, defined in transport/src/test/java/io/netty/channel/embedded/EmbeddedChannelTest.java.
Where is EventOutboundHandler defined?
EventOutboundHandler is defined in transport/src/test/java/io/netty/channel/embedded/EmbeddedChannelTest.java at line 830.

Analyze Your Own Codebase

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

Try Supermodel Free