Home / Function/ onSend() — netty Function Reference

onSend() — netty Function Reference

Architecture documentation for the onSend() function in StompChatHandler.java from the netty codebase.

Function java Buffer Search calls 1 called by 1

Entity Profile

Dependency Diagram

graph TD
  e7e2a1ff_4014_45fc_319b_33586aa4f65b["onSend()"]
  f937e446_8aba_2036_93fc_8020adb1953f["StompChatHandler"]
  e7e2a1ff_4014_45fc_319b_33586aa4f65b -->|defined in| f937e446_8aba_2036_93fc_8020adb1953f
  5ef12430_b789_c7f8_301d_8283d302e997["channelRead0()"]
  5ef12430_b789_c7f8_301d_8283d302e997 -->|calls| e7e2a1ff_4014_45fc_319b_33586aa4f65b
  f5104c6e_035e_0b9d_444a_4cc359d713bf["sendErrorFrame()"]
  e7e2a1ff_4014_45fc_319b_33586aa4f65b -->|calls| f5104c6e_035e_0b9d_444a_4cc359d713bf
  style e7e2a1ff_4014_45fc_319b_33586aa4f65b fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

example/src/main/java/io/netty/example/stomp/websocket/StompChatHandler.java lines 113–124

    private void onSend(ChannelHandlerContext ctx, StompFrame inboundFrame) {
        String destination = inboundFrame.headers().getAsString(DESTINATION);
        if (destination == null) {
            sendErrorFrame("missed header", "required 'destination' header missed", ctx);
            return;
        }

        Set<StompSubscription> subscriptions = chatDestinations.get(destination);
        for (StompSubscription subscription : subscriptions) {
            subscription.channel().writeAndFlush(transformToMessage(inboundFrame, subscription));
        }
    }

Domain

Subdomains

Called By

Frequently Asked Questions

What does onSend() do?
onSend() is a function in the netty codebase, defined in example/src/main/java/io/netty/example/stomp/websocket/StompChatHandler.java.
Where is onSend() defined?
onSend() is defined in example/src/main/java/io/netty/example/stomp/websocket/StompChatHandler.java at line 113.
What does onSend() call?
onSend() calls 1 function(s): sendErrorFrame.
What calls onSend()?
onSend() is called by 1 function(s): channelRead0.

Analyze Your Own Codebase

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

Try Supermodel Free