Uses of Class
org.miaixz.bus.socket.Session
Packages that use Session
Package
Description
定义用户进行通信开发所需实现的接口
KCP相关实现
消息处理实现
字符协议等实现
插件等实现
-
Uses of Session in org.miaixz.bus.socket
Methods in org.miaixz.bus.socket with parameters of type SessionModifier and TypeMethodDescriptionvoid监控触发本次读回调Session的已读数据字节数voidMonitor.afterWrite(Session session, int writeSize) 监控触发本次写回调session的已写数据字节数voidMonitor.beforeRead(Session session) 即将开始读取数据voidMonitor.beforeWrite(Session session) 即将开始写数据Message.decode(ByteBuffer readBuffer, Session session) 对于从Socket流中获取到的数据采用当前Protocol的实现类协议进行解析。void处理接收到的消息boolean对请求消息进行预处理,并决策是否进行后续的Handler处理 若返回false,则当前消息将被忽略。default voidHandler.stateEvent(Session session, Status status, Throwable throwable) 状态机事件,当枚举事件发生时由框架触发该方法voidPlugin.stateEvent(Status status, Session session, Throwable throwable) 监听状态机事件 -
Uses of Session in org.miaixz.bus.socket.accord
Subclasses of Session in org.miaixz.bus.socket.accordMethods in org.miaixz.bus.socket.accord that return SessionModifier and TypeMethodDescriptionUdpChannel.connect(SocketAddress remote) 建立与远程服务的连接会话,通过Session可进行数据传输AioClient.start()启动客户端。AioClient.start(AsynchronousChannelGroup asynchronousChannelGroup) 启动客户端。Method parameters in org.miaixz.bus.socket.accord with type arguments of type SessionModifier and TypeMethodDescription<A> voidAioClient.start(A attachment, CompletionHandler<Session, ? super A> handler) 采用异步的方式启动客户端<A> voidAioClient.start(AsynchronousChannelGroup asynchronousChannelGroup, A attachment, CompletionHandler<Session, ? super A> handler) 采用异步的方式启动客户端 -
Uses of Session in org.miaixz.bus.socket.accord.kcp
Methods in org.miaixz.bus.socket.accord.kcp with parameters of type Session -
Uses of Session in org.miaixz.bus.socket.metric.handler
Methods in org.miaixz.bus.socket.metric.handler with parameters of type SessionModifier and TypeMethodDescriptionfinal voidfinal voidAbstractMessageHandler.afterWrite(Session session, int writeSize) final voidAbstractMessageHandler.beforeRead(Session session) final voidAbstractMessageHandler.beforeWrite(Session session) final voidabstract void处理接收到的消息final voidAbstractMessageHandler.stateEvent(Session session, Status status, Throwable throwable) abstract voidAbstractMessageHandler.stateEvent0(Session session, Status status, Throwable throwable) -
Uses of Session in org.miaixz.bus.socket.metric.message
Methods in org.miaixz.bus.socket.metric.message with parameters of type SessionModifier and TypeMethodDescriptionprotected byte[]protected abstract Tfinal TFixedLengthBytesMessage.decode(ByteBuffer readBuffer, Session session) StringMessage.decode(ByteBuffer readBuffer, Session session) -
Uses of Session in org.miaixz.bus.socket.plugin
Methods in org.miaixz.bus.socket.plugin with parameters of type SessionModifier and TypeMethodDescriptionvoidvoidvoidAbstractPlugin.afterWrite(Session session, int writeSize) voidMonitorPlugin.afterWrite(Session session, int writeSize) voidAbstractPlugin.beforeRead(Session session) voidMonitorPlugin.beforeRead(Session session) voidAbstractPlugin.beforeWrite(Session session) voidMonitorPlugin.beforeWrite(Session session) voidabstract booleanHeartPlugin.isHeartMessage(Session session, T msg) 判断当前收到的消息是否为心跳消息。booleanfinal booleanbooleanabstract voidHeartPlugin.sendHeartRequest(Session session) 自定义心跳消息并发送voidAbstractPlugin.stateEvent(Status status, Session session, Throwable throwable) final voidHeartPlugin.stateEvent(Status status, Session session, Throwable throwable) voidMonitorPlugin.stateEvent(Status status, Session session, Throwable throwable)