public class DatagramDnsQuery extends DefaultDnsQuery implements io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>
DnsQuery implementation for UDP/IP.| Constructor and Description |
|---|
DatagramDnsQuery(InetSocketAddress sender,
InetSocketAddress recipient,
int id)
Creates a new instance with the
DnsOpCode.QUERY opCode. |
DatagramDnsQuery(InetSocketAddress sender,
InetSocketAddress recipient,
int id,
DnsOpCode opCode)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
DatagramDnsQuery |
addRecord(DnsSection section,
DnsRecord record)
Adds the specified
record at the end of the specified section of this DNS message. |
DatagramDnsQuery |
addRecord(DnsSection section,
int index,
DnsRecord record)
Adds the specified
record at the specified index of the specified section
of this DNS message. |
DatagramDnsQuery |
clear()
Removes all the records in this DNS message.
|
DatagramDnsQuery |
clear(DnsSection section)
Removes all the records in the specified
section of this DNS message. |
DatagramDnsQuery |
content() |
boolean |
equals(Object obj) |
int |
hashCode() |
InetSocketAddress |
recipient() |
DatagramDnsQuery |
retain() |
DatagramDnsQuery |
retain(int increment) |
InetSocketAddress |
sender() |
DatagramDnsQuery |
setId(int id)
Sets the
ID of this DNS message. |
DatagramDnsQuery |
setOpCode(DnsOpCode opCode)
Sets the
opCode of this DNS message. |
DatagramDnsQuery |
setRecord(DnsSection section,
DnsRecord record)
Sets the specified
section of this DNS message to the specified record,
making it a single-record section. |
DatagramDnsQuery |
setRecursionDesired(boolean recursionDesired)
Sets the
RD (recursion desired} field of this DNS message. |
DatagramDnsQuery |
setZ(int z)
Sets the
Z (reserved for future use) field of this DNS message. |
DatagramDnsQuery |
touch() |
DatagramDnsQuery |
touch(Object hint) |
toStringcount, count, deallocate, id, isRecursionDesired, opCode, recordAt, recordAt, removeRecord, setRecord, zrefCnt, release, release, setRefCntclone, finalize, getClass, notify, notifyAll, wait, wait, waitcount, count, id, isRecursionDesired, opCode, recordAt, recordAt, removeRecord, setRecord, zpublic DatagramDnsQuery(InetSocketAddress sender, InetSocketAddress recipient, int id)
DnsOpCode.QUERY opCode.sender - the address of the senderrecipient - the address of the recipientid - the ID of the DNS querypublic DatagramDnsQuery(InetSocketAddress sender, InetSocketAddress recipient, int id, DnsOpCode opCode)
sender - the address of the senderrecipient - the address of the recipientid - the ID of the DNS queryopCode - the opCode of the DNS querypublic DatagramDnsQuery content()
content in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>public InetSocketAddress sender()
sender in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>public InetSocketAddress recipient()
recipient in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>public DatagramDnsQuery setId(int id)
DnsMessageID of this DNS message.setId in interface DnsMessagesetId in interface DnsQuerysetId in class DefaultDnsQuerypublic DatagramDnsQuery setOpCode(DnsOpCode opCode)
DnsMessageopCode of this DNS message.setOpCode in interface DnsMessagesetOpCode in interface DnsQuerysetOpCode in class DefaultDnsQuerypublic DatagramDnsQuery setRecursionDesired(boolean recursionDesired)
DnsMessageRD (recursion desired} field of this DNS message.setRecursionDesired in interface DnsMessagesetRecursionDesired in interface DnsQuerysetRecursionDesired in class DefaultDnsQuerypublic DatagramDnsQuery setZ(int z)
DnsMessageZ (reserved for future use) field of this DNS message.setZ in interface DnsMessagesetZ in interface DnsQuerysetZ in class DefaultDnsQuerypublic DatagramDnsQuery setRecord(DnsSection section, DnsRecord record)
DnsMessagesection of this DNS message to the specified record,
making it a single-record section. When the specified section is DnsSection.QUESTION,
the specified record must be a DnsQuestion.setRecord in interface DnsMessagesetRecord in interface DnsQuerysetRecord in class DefaultDnsQuerypublic DatagramDnsQuery addRecord(DnsSection section, DnsRecord record)
DnsMessagerecord at the end of the specified section of this DNS message.
When the specified section is DnsSection.QUESTION, the specified record
must be a DnsQuestion.addRecord in interface DnsMessageaddRecord in interface DnsQueryaddRecord in class DefaultDnsQuerypublic DatagramDnsQuery addRecord(DnsSection section, int index, DnsRecord record)
DnsMessagerecord at the specified index of the specified section
of this DNS message. When the specified section is DnsSection.QUESTION, the specified
record must be a DnsQuestion.addRecord in interface DnsMessageaddRecord in interface DnsQueryaddRecord in class DefaultDnsQuerypublic DatagramDnsQuery clear(DnsSection section)
DnsMessagesection of this DNS message.clear in interface DnsMessageclear in interface DnsQueryclear in class DefaultDnsQuerypublic DatagramDnsQuery clear()
DnsMessageclear in interface DnsMessageclear in interface DnsQueryclear in class DefaultDnsQuerypublic DatagramDnsQuery touch()
touch in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>touch in interface DnsMessagetouch in interface DnsQuerytouch in interface io.netty.util.ReferenceCountedtouch in class DefaultDnsQuerypublic DatagramDnsQuery touch(Object hint)
touch in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>touch in interface DnsMessagetouch in interface DnsQuerytouch in interface io.netty.util.ReferenceCountedtouch in class DefaultDnsQuerypublic DatagramDnsQuery retain()
retain in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>retain in interface DnsMessageretain in interface DnsQueryretain in interface io.netty.util.ReferenceCountedretain in class DefaultDnsQuerypublic DatagramDnsQuery retain(int increment)
retain in interface io.netty.channel.AddressedEnvelope<DatagramDnsQuery,InetSocketAddress>retain in interface DnsMessageretain in interface DnsQueryretain in interface io.netty.util.ReferenceCountedretain in class DefaultDnsQuerypublic boolean equals(Object obj)
equals in class AbstractDnsMessagepublic int hashCode()
hashCode in class AbstractDnsMessageCopyright © 2008–2025 The Netty Project. All rights reserved.