public class SocksPortUnificationServerHandler extends ByteToMessageDecoder
Socks4ServerDecoder或Socks5InitialRequestDecoder初始化管道。
ByteToMessageDecoder.CumulatorChannelHandler.SharableCOMPOSITE_CUMULATOR, MERGE_CUMULATOR| Constructor and Description |
|---|
SocksPortUnificationServerHandler()
使用默认配置创建一个新实例。
|
SocksPortUnificationServerHandler(Socks5ServerEncoder socks5encoder)
用指定的 Socks5ServerEncoder创建一个新实例。
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
decode(ChannelHandlerContext ctx, ByteBuf in, java.util.List<java.lang.Object> out)
解码从一个 ByteBuf到另一个。
|
actualReadableBytes, callDecode, channelInactive, channelRead, channelReadComplete, decodeLast, discardSomeReadBytes, handlerRemoved, handlerRemoved0, internalBuffer, isSingleDecode, setCumulator, setDiscardAfterReads, setSingleDecode, userEventTriggeredchannelActive, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaughtensureNotSharable, handlerAdded, isSharableclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waithandlerAddedpublic SocksPortUnificationServerHandler()
public SocksPortUnificationServerHandler(Socks5ServerEncoder socks5encoder)
Socks5ServerEncoder创建一个新实例。
当用户想要使用替代Socks5AddressEncoder时,此构造函数很有用。
protected void decode(ChannelHandlerContext ctx, ByteBuf in, java.util.List<java.lang.Object> out) throws java.lang.Exception
ByteToMessageDecoder
decode
ByteToMessageDecoder
ctx - ByteToMessageDecoder所属的ChannelHandlerContext
in - 从中读取数据的ByteBuf
out - 应该添加解码消息的
List
java.lang.Exception - 发生错误时抛出
Copyright © 2008–2018 The Netty Project. All rights reserved.