Name

UnknownHostException

Synopsis

Signals that the name of a specified host could not be resolved.

java.net.UnknownHostException

Figure 12-23. java.net.UnknownHostException

public class UnknownHostException extends java.io.IOException {
// Public Constructors
     public UnknownHostException( );  
     public UnknownHostException(String host);  
}

Thrown By

Inet6Address.getByAddress( ), InetAddress.{getAllByName( ), getByAddress( ), getByName( ), getLocalHost( )}, Socket.Socket( ), javax.net.SocketFactory.createSocket( ), javax.net.ssl.SSLSocket.SSLSocket( )

Get Java in a Nutshell, 5th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.