Package org.xbill.DNS

Class MXRecord

All Implemented Interfaces:
Serializable, Cloneable, Comparable<Record>

public class MXRecord extends U16NameBase
Mail Exchange - specifies where mail to a domain is sent
See Also:
  • Constructor Details

    • MXRecord

      MXRecord()
    • MXRecord

      public MXRecord(Name name, int dclass, long ttl, int priority, Name target)
      Creates an MX Record from the given data
      Parameters:
      priority - The priority of this MX. Records with lower priority are preferred.
      target - The host that mail is sent to
  • Method Details

    • getTarget

      public Name getTarget()
      Returns the target of the MX record
    • getPriority

      public int getPriority()
      Returns the priority of this MX record
    • rrToWire

      protected void rrToWire(DNSOutput out, Compression c, boolean canonical)
      Description copied from class: Record
      Converts the type-specific RR to wire format - must be overridden.
      Overrides:
      rrToWire in class U16NameBase
    • getAdditionalName

      public Name getAdditionalName()
      Description copied from class: Record
      Returns the name for which additional data processing should be done for this record. This can be used both for building responses and parsing responses.
      Overrides:
      getAdditionalName in class Record
      Returns:
      The name to used for additional data processing, or null if this record type does not require additional data processing.