public class UdpAioSession extends AioSession
SESSION_STATUS_CLOSED, SESSION_STATUS_CLOSING, SESSION_STATUS_ENABLED, status| Modifier and Type | Method and Description |
|---|---|
void |
awaitRead() |
void |
close(boolean immediate)
是否立即关闭会话
|
InetSocketAddress |
getLocalAddress()
获取当前会话的本地连接地址
|
InetSocketAddress |
getRemoteAddress()
获取当前会话的远程连接地址
|
ByteBuffer |
readBuffer()
获取读缓冲区对象
|
void |
signalRead()
继续触发读行为,该方法仅可在异步处理模式下可使用,否则会触发不可预知的异常
|
org.aoju.bus.core.io.WriteBuffer |
writeBuffer()
获取WriteBuffer用以数据输出
|
close, getAttachment, getInputStream, getInputStream, getSessionID, isInvalid, setAttachmentpublic org.aoju.bus.core.io.WriteBuffer writeBuffer()
AioSessionwriteBuffer in class AioSessionpublic ByteBuffer readBuffer()
AioSessionreadBuffer in class AioSessionpublic void awaitRead()
awaitRead in class AioSessionpublic void signalRead()
AioSessionsignalRead in class AioSessionpublic void close(boolean immediate)
AioSessionclose in class AioSessionimmediate - true:立即关闭,false:响应消息发送完后关闭public InetSocketAddress getLocalAddress() throws IOException
AioSessiongetLocalAddress in class AioSessionIOException - IO异常AsynchronousSocketChannel.getLocalAddress()public InetSocketAddress getRemoteAddress()
AioSessiongetRemoteAddress in class AioSessionAsynchronousSocketChannel.getRemoteAddress()Copyright © 2021. All rights reserved.