public class MX extends Data
| Modifier and Type | Field and Description |
|---|---|
int | priorityThe priority of this service. |
DnsName | targetThe name of the target server. |
| Constructor and Description |
|---|
MX(int priority,
DnsName name)MX. |
MX(int priority,
String name)MX. |
| Modifier and Type | Method and Description |
|---|---|
Record.TYPE | getType()getType. |
static MX | parse(DataInputStream dis,
byte[] data)Parse an MX record from a stream. |
void | serialize(DataOutputStream dos)serialize. |
String | toString()toString. |
equals, hashCode, length, toByteArray, toOutputStream, toOutputStreampublic final int priority
public final DnsName target
public MX(int priority,
DnsName name)public MX(int priority,
String name)public Record.TYPE getType()
public static MX parse(DataInputStream dis, byte[] data) throws IOException
dis - the input streamdata - the raw DNS message dataIOException - on parse errorpublic void serialize(DataOutputStream dos) throws IOException
serialize in class Datados - the output stream to serialize to.IOException - if an I/O error occurs.