ibis.util
Class IPUtils

java.lang.Object
  extended byibis.util.IPUtils

public class IPUtils
extends java.lang.Object

Some utilities that deal with IP addresses.


Method Summary
static java.net.InetAddress getAlternateLocalHostAddress()
          Returns the InetAddress associated with the local host.
static java.net.InetAddress getLocalHostAddress()
          Returns the InetAddress associated with the local host.
static boolean isExternalAddress(java.net.InetAddress address)
          Returns true if the specified address is an external address.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isExternalAddress

public static boolean isExternalAddress(java.net.InetAddress address)
Returns true if the specified address is an external address. External means not a site local, link local, or loopback address.

Parameters:
address - the specified address.
Returns:
true if addr is an external address.

getLocalHostAddress

public static java.net.InetAddress getLocalHostAddress()
Returns the InetAddress associated with the local host. If the ibis.util.ip.address property is specified and set to a specific IP address, that address is used.


getAlternateLocalHostAddress

public static java.net.InetAddress getAlternateLocalHostAddress()
Returns the InetAddress associated with the local host. If the ibis.util.ip.alt_address property is specified and set to a specific IP address, that address is used.



The Ibis project