| |
|
| java.lang.Object org.xbill.DNS.Header
Header | public class Header (Code) | | A DNS message header
See Also: Message author: Brian Wellington |
Field Summary | |
final public static int | LENGTH The length of a DNS Header in wire format. |
Constructor Summary | |
public | Header(int id) Create a new empty header. | public | Header() | | Header(DNSInput in) Parses a Header from a stream containing DNS wire format. | public | Header(byte[] b) |
LENGTH | final public static int LENGTH(Code) | | The length of a DNS Header in wire format.
|
Header | public Header(int id)(Code) | | Create a new empty header.
Parameters: id - The message id |
Header | public Header()(Code) | | Create a new empty header with a random message id
|
Header | public Header(byte[] b) throws IOException(Code) | | Creates a new Header from its DNS wire format representation
Parameters: b - A byte array containing the DNS Header. |
decCount | void decCount(int field)(Code) | | |
getCount | public int getCount(int field)(Code) | | Retrieves the record count for the given section
See Also: Section |
getFlag | public boolean getFlag(int bit)(Code) | | Retrieves a flag
See Also: Flags |
getFlags | boolean[] getFlags()(Code) | | |
getID | public int getID()(Code) | | Retrieves the message ID
|
getOpcode | public int getOpcode()(Code) | | Retrieves the mesasge's opcode
See Also: Opcode |
getRcode | public int getRcode()(Code) | | Retrieves the mesasge's rcode
See Also: Rcode |
incCount | void incCount(int field)(Code) | | |
printFlags | public String printFlags()(Code) | | Converts the header's flags into a String
|
setCount | void setCount(int field, int value)(Code) | | |
setFlag | public void setFlag(int bit)(Code) | | Sets a flag to the supplied value
See Also: Flags |
setID | public void setID(int id)(Code) | | Sets the message ID
|
setOpcode | public void setOpcode(int value)(Code) | | Sets the message's opcode
See Also: Opcode |
setRcode | public void setRcode(int value)(Code) | | Sets the message's rcode
See Also: Rcode |
toString | public String toString()(Code) | | Converts the header into a String
|
toStringWithRcode | String toStringWithRcode(int newrcode)(Code) | | |
toWire | public byte[] toWire()(Code) | | |
unsetFlag | public void unsetFlag(int bit)(Code) | | Sets a flag to the supplied value
See Also: Flags |
|
|
|