Top Description Inners Fields Constructors Methods
io.netty.handler.codec.socks

public Class SocksCmdResponseDecoder

extends ReplayingDecoder<SocksCmdResponseDecoder.State>
Class Inheritance
Imports
io.netty.buffer.ByteBuf, .ByteBufUtil, io.netty.channel.ChannelHandlerContext, io.netty.handler.codec.ReplayingDecoder, io.netty.handler.codec.socks.SocksCmdResponseDecoder.State, io.netty.util.NetUtil, io.netty.util.internal.UnstableApi, java.util.List

Decodes ByteBufs into SocksCmdResponse. Before returning SocksResponse decoder removes itself from pipeline.

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static enum

Field Summary

Modifier and TypeField and Description
private SocksAddressType
private SocksCmdStatus

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected void
decode(ChannelHandlerContext ctx, ByteBuf
the ByteBuf from which to read data
byteBuf
,
List<Object>
the List to which decoded messages should be added
out
)

Implements abstract io.netty.handler.codec.ByteToMessageDecoder.decode.

Decode the from one ByteBuf to an other.
Inherited from io.netty.handler.codec.ReplayingDecoder:
callDecodecheckpointcheckpointstatestate

Field Detail

addressTypeback to summary
private SocksAddressType addressType
cmdStatusback to summary
private SocksCmdStatus cmdStatus

Constructor Detail

SocksCmdResponseDecoderback to summary
public SocksCmdResponseDecoder()

Method Detail

decodeback to summary
protected void decode(ChannelHandlerContext ctx, ByteBuf byteBuf, List<Object> out) throws Exception

Implements abstract io.netty.handler.codec.ByteToMessageDecoder.decode.

Doc from io.netty.handler.codec.ByteToMessageDecoder.decode.

Decode the from one ByteBuf to an other. This method will be called till either the input ByteBuf has nothing to read when return from this method or till nothing was read from the input ByteBuf.

Parameters
ctx:ChannelHandlerContext

the ChannelHandlerContext which this ByteToMessageDecoder belongs to

byteBuf:ByteBuf

the ByteBuf from which to read data

out:List<Object>

the List to which decoded messages should be added

Annotations
@Override
Exceptions
Exception:
is thrown if an error occurs
io.netty.handler.codec.socks back to summary

public final Enum SocksCmdResponseDecoder.State

extends Enum<SocksCmdResponseDecoder.State>
Class Inheritance
Annotations
@UnstableApi

Field Summary

Modifier and TypeField and Description
public static final SocksCmdResponseDecoder.State
public static final SocksCmdResponseDecoder.State
public static final SocksCmdResponseDecoder.State

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static SocksCmdResponseDecoder.State
public static SocksCmdResponseDecoder.State[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

CHECK_PROTOCOL_VERSIONback to summary
public static final SocksCmdResponseDecoder.State CHECK_PROTOCOL_VERSION
READ_CMD_ADDRESSback to summary
public static final SocksCmdResponseDecoder.State READ_CMD_ADDRESS
READ_CMD_HEADERback to summary
public static final SocksCmdResponseDecoder.State READ_CMD_HEADER

Constructor Detail

Stateback to summary
private State()

Method Detail

valueOfback to summary
public static SocksCmdResponseDecoder.State valueOf(String name)
valuesback to summary
public static SocksCmdResponseDecoder.State[] values()