Package io.netty.handler.codec.dns
Class DnsResponseDecoder<A extends java.net.SocketAddress>
- java.lang.Object
-
- io.netty.handler.codec.dns.DnsResponseDecoder<A>
-
abstract class DnsResponseDecoder<A extends java.net.SocketAddress> extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description private DnsRecordDecoder
recordDecoder
-
Constructor Summary
Constructors Constructor Description DnsResponseDecoder(DnsRecordDecoder recordDecoder)
Creates a new decoder with the specifiedrecordDecoder
.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description (package private) DnsResponse
decode(A sender, A recipient, ByteBuf buffer)
private void
decodeQuestions(DnsResponse response, ByteBuf buf, int questionCount)
private boolean
decodeRecords(DnsResponse response, DnsSection section, ByteBuf buf, int count)
protected abstract DnsResponse
newResponse(A sender, A recipient, int id, DnsOpCode opCode, DnsResponseCode responseCode)
-
-
-
Field Detail
-
recordDecoder
private final DnsRecordDecoder recordDecoder
-
-
Constructor Detail
-
DnsResponseDecoder
DnsResponseDecoder(DnsRecordDecoder recordDecoder)
Creates a new decoder with the specifiedrecordDecoder
.
-
-
Method Detail
-
decode
final DnsResponse decode(A sender, A recipient, ByteBuf buffer) throws java.lang.Exception
- Throws:
java.lang.Exception
-
newResponse
protected abstract DnsResponse newResponse(A sender, A recipient, int id, DnsOpCode opCode, DnsResponseCode responseCode) throws java.lang.Exception
- Throws:
java.lang.Exception
-
decodeQuestions
private void decodeQuestions(DnsResponse response, ByteBuf buf, int questionCount) throws java.lang.Exception
- Throws:
java.lang.Exception
-
decodeRecords
private boolean decodeRecords(DnsResponse response, DnsSection section, ByteBuf buf, int count) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-