org.elasticsearch.util.io
Class HostResolver

java.lang.Object
  extended by org.elasticsearch.util.io.HostResolver

public abstract class HostResolver
extends java.lang.Object


Field Summary
static java.lang.String GLOBAL_NETWORK_BINDHOST_SETTING
           
static java.lang.String GLOBAL_NETWORK_PUBLISHHOST_SETTING
           
static java.lang.String LOCAL_CANONICALHOST
           
static java.lang.String LOCAL_HOST
           
static java.lang.String LOCAL_IP
           
 
Method Summary
static boolean isIPv4()
           
static java.lang.String resolveHost(java.lang.String host, java.lang.String defaultValue1, java.lang.String defaultValue2)
           
static java.net.InetAddress resolveInetAddress(java.lang.String host, java.lang.String defaultValue1, java.lang.String defaultValue2)
           
static java.net.InetAddress resultBindHostAddress(java.lang.String bindHost, Settings settings)
           
static java.net.InetAddress resultBindHostAddress(java.lang.String bindHost, Settings settings, java.lang.String defaultValue2)
           
static java.net.InetAddress resultPublishHostAddress(java.lang.String publishHost, Settings settings)
           
static java.net.InetAddress resultPublishHostAddress(java.lang.String publishHost, Settings settings, java.lang.String defaultValue2)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GLOBAL_NETWORK_BINDHOST_SETTING

public static final java.lang.String GLOBAL_NETWORK_BINDHOST_SETTING
See Also:
Constant Field Values

GLOBAL_NETWORK_PUBLISHHOST_SETTING

public static final java.lang.String GLOBAL_NETWORK_PUBLISHHOST_SETTING
See Also:
Constant Field Values

LOCAL_IP

public static final java.lang.String LOCAL_IP
See Also:
Constant Field Values

LOCAL_HOST

public static final java.lang.String LOCAL_HOST
See Also:
Constant Field Values

LOCAL_CANONICALHOST

public static final java.lang.String LOCAL_CANONICALHOST
See Also:
Constant Field Values
Method Detail

isIPv4

public static boolean isIPv4()

resultBindHostAddress

public static java.net.InetAddress resultBindHostAddress(java.lang.String bindHost,
                                                         Settings settings)
                                                  throws java.io.IOException
Throws:
java.io.IOException

resultBindHostAddress

public static java.net.InetAddress resultBindHostAddress(java.lang.String bindHost,
                                                         Settings settings,
                                                         java.lang.String defaultValue2)
                                                  throws java.io.IOException
Throws:
java.io.IOException

resultPublishHostAddress

public static java.net.InetAddress resultPublishHostAddress(java.lang.String publishHost,
                                                            Settings settings)
                                                     throws java.io.IOException
Throws:
java.io.IOException

resultPublishHostAddress

public static java.net.InetAddress resultPublishHostAddress(java.lang.String publishHost,
                                                            Settings settings,
                                                            java.lang.String defaultValue2)
                                                     throws java.io.IOException
Throws:
java.io.IOException

resolveInetAddress

public static java.net.InetAddress resolveInetAddress(java.lang.String host,
                                                      java.lang.String defaultValue1,
                                                      java.lang.String defaultValue2)
                                               throws java.net.UnknownHostException,
                                                      java.io.IOException
Throws:
java.net.UnknownHostException
java.io.IOException

resolveHost

public static java.lang.String resolveHost(java.lang.String host,
                                           java.lang.String defaultValue1,
                                           java.lang.String defaultValue2)
                                    throws java.net.UnknownHostException,
                                           java.io.IOException
Throws:
java.net.UnknownHostException
java.io.IOException