Top Fields Constructors Methods
io.netty.handler.codec.dns

public final Class TcpDnsQueryDecoder

extends LengthFieldBasedFrameDecoder
Class Inheritance
Annotations
@UnstableApi
Imports
io.netty.buffer.ByteBuf, io.netty.channel.ChannelHandlerContext, io.netty.handler.codec.LengthFieldBasedFrameDecoder, io.netty.util.internal.ObjectUtil, .UnstableApi

Field Summary

Modifier and TypeField and Description
private final DnsRecordDecoder

Constructor Summary

AccessConstructor and Description
public
TcpDnsQueryDecoder()

Creates a new decoder with the default record decoder.

public
TcpDnsQueryDecoder(DnsRecordDecoder decoder, int maxFrameLength)

Creates a new decoder with the specified decoder.

Method Summary

Modifier and TypeMethod and Description
protected Object
decode(ChannelHandlerContext ctx, ByteBuf
the ByteBuf from which to read data
in
)

Overrides io.netty.handler.codec.LengthFieldBasedFrameDecoder.decode.

Create a frame out of the ByteBuf and return it.
Inherited from io.netty.handler.codec.LengthFieldBasedFrameDecoder:
decodeextractFramegetUnadjustedFrameLength

Field Detail

decoderback to summary
private final DnsRecordDecoder decoder

Constructor Detail

TcpDnsQueryDecoderback to summary
public TcpDnsQueryDecoder()

Creates a new decoder with the default record decoder.

TcpDnsQueryDecoderback to summary
public TcpDnsQueryDecoder(DnsRecordDecoder decoder, int maxFrameLength)

Creates a new decoder with the specified decoder.

Method Detail

decodeback to summary
protected Object decode(ChannelHandlerContext ctx, ByteBuf in) throws Exception

Overrides io.netty.handler.codec.LengthFieldBasedFrameDecoder.decode.

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

Create a frame out of the ByteBuf and return it.

Parameters
ctx:ChannelHandlerContext

the ChannelHandlerContext which this ByteToMessageDecoder belongs to

in:ByteBuf

the ByteBuf from which to read data

Returns:Object

frame the ByteBuf which represent the frame or null if no frame could be created.

Annotations
@Override