Class AbstractMessageHandler<T>
java.lang.Object
org.miaixz.bus.socket.metric.handler.AbstractMessageHandler<T>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal voidfinal void监控触发本次读回调Session的已读数据字节数final voidafterWrite(Session session, int writeSize) 监控触发本次写回调session的已写数据字节数final voidbeforeRead(Session session) 即将开始读取数据final voidbeforeWrite(Session session) 即将开始写数据final void处理接收到的消息abstract void处理接收到的消息shouldAccept(AsynchronousSocketChannel channel) 监控已接收到的连接final voidstateEvent(Session session, Status status, Throwable throwable) 状态机事件,当枚举事件发生时由框架触发该方法abstract voidstateEvent0(Session session, Status status, Throwable throwable)
-
Constructor Details
-
AbstractMessageHandler
public AbstractMessageHandler()
-
-
Method Details
-
afterRead
-
afterWrite
Description copied from interface:Monitor监控触发本次写回调session的已写数据字节数- Specified by:
afterWritein interfaceMonitor- Parameters:
session- 本次执行write回调的Session对象writeSize- 本次输出的数据长度
-
beforeRead
Description copied from interface:Monitor即将开始读取数据- Specified by:
beforeReadin interfaceMonitor- Parameters:
session- 当前会话对象
-
beforeWrite
Description copied from interface:Monitor即将开始写数据- Specified by:
beforeWritein interfaceMonitor- Parameters:
session- 当前会话对象
-
shouldAccept
Description copied from interface:Monitor监控已接收到的连接- Specified by:
shouldAcceptin interfaceMonitor- Parameters:
channel- 当前已经建立连接的通道对象- Returns:
- 非null:接受该连接,null:拒绝该连接
-
process
-
process0
-
stateEvent
-
stateEvent0
-
addPlugin
-