InetAddress.getAllByName

InetAddress.getAllByName

Class Overview | Class Members | This Package | All Packages

Syntax
public static InetAddress[] getAllByName( String host ) throws UnknownHostException
Parameters
host
the name of the host.
Returns
an array of all the IP addresses for a given host name.
Description
Determines all the IP addresses of a host, given the host's name. The host name can either be a machine name, such as "java.sun.com", or a string representing its IP address, such as "206.26.48.100".

Exceptions
UnknownHostException if no IP address for the host could be found.