public class MailServer extends Object implements Comparable<MailServer>
| Constructor and Description |
|---|
MailServer(int preference,
String domainName)
Constructs this MailServer from the supplied preference and domainName.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(MailServer mailServer)
Compares
MailServers by preference. |
String |
getDomainName()
Gets the domain name of this MailServer.
|
int |
getPreference()
Gets the preference of this MailServer.
|
String |
toString()
Creates a String representation of this MailServer.
|
public MailServer(int preference,
String domainName)
preference - The preference of this mail server.domainName - The doman name of this mail server.public int getPreference()
public String getDomainName()
public int compareTo(MailServer mailServer)
MailServers by preference.compareTo in interface Comparable<MailServer>mailServer - The MailServer to compare to this MailServer.Copyright © 2008–2017. All rights reserved.