org.neverfear.whois
Class ResolveAfilias

java.lang.Object
  extended by org.neverfear.whois.ResolveCRSNIC
      extended by org.neverfear.whois.ResolveAfilias
All Implemented Interfaces:
ServerResolver

public class ResolveAfilias
extends ResolveCRSNIC

Resolve an Afilias domain name. See http://www.afilias.info/ for more information.

Author:
doug@neverfear.org

Field Summary
private static ResolveAfilias instance
           
private  int port
           
private  java.lang.String server
           
static java.lang.String WHOIS_HOST
          The whois server host name.
static int WHOIS_PORT
          The whois server host port.
 
Fields inherited from class org.neverfear.whois.ResolveCRSNIC
DOMAIN_STR, WHOIS_STR
 
Constructor Summary
private ResolveAfilias()
          Create an Afilias resolver.
 
Method Summary
static ResolveAfilias getInstance()
          Get an instance of a afilias resolver.
 int getPort()
          Get the whois server host port.
 java.lang.String getServer()
          Get the whois server host name.
 WhoisResponse query(java.lang.String name)
          Query the server for the given name.
 
Methods inherited from class org.neverfear.whois.ResolveCRSNIC
exactSearch, expandedSearch, partialSearch, search, search, summarySearch
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

WHOIS_HOST

public static final java.lang.String WHOIS_HOST
The whois server host name.

See Also:
Constant Field Values

WHOIS_PORT

public static final int WHOIS_PORT
The whois server host port.

See Also:
Constant Field Values

server

private java.lang.String server

port

private int port

instance

private static ResolveAfilias instance
Constructor Detail

ResolveAfilias

private ResolveAfilias()
Create an Afilias resolver. Cannot be instantiated outside of this object.

Method Detail

getInstance

public static ResolveAfilias getInstance()
Get an instance of a afilias resolver.

Returns:
The Afilias resolver

getServer

public java.lang.String getServer()
Get the whois server host name.

Overrides:
getServer in class ResolveCRSNIC
Returns:
A host name.

getPort

public int getPort()
Get the whois server host port.

Overrides:
getPort in class ResolveCRSNIC
Returns:
A host port.

query

public WhoisResponse query(java.lang.String name)
                    throws java.io.IOException,
                           java.net.UnknownHostException
Description copied from interface: ServerResolver
Query the server for the given name.

Specified by:
query in interface ServerResolver
Overrides:
query in class ResolveCRSNIC
Parameters:
name - A domain name.
Returns:
A WhoisResponse object.
Throws:
java.io.IOException
java.net.UnknownHostException