KickJava   Java API By Example, From Geeks To Geeks.

Java > Java SE, EE, ME > java > rmi > UnknownHostException

java.rmi
Class UnknownHostException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.io.IOException
              extended by java.rmi.RemoteException
                  extended by java.rmi.UnknownHostException
All Implemented Interfaces:
Serializable
See Also:
Top Examples, Source Code

public UnknownHostException(String s)
Geek's Notes:
Description  Add your codes or notes  Search More Java Examples  


public UnknownHostException(String s,
                            Exception ex)
Geek's Notes:
Description  Add your codes or notes  Search More Java Examples  


[1547]Unknown Host
By Anonymous on 2005/09/26 14:18:46  Rate
  try {  
     c1 = new Socket ( "machine name", REMOTE_PORT ) ; 
     is = new BufferedReader  ( new InputStreamReader  ( c1.getInputStream (  )  )  ) ; 
      os = new DataOutputStream  ( c1.getOutputStream (  )  ) ; 
        }  
     catch  ( UnknownHostException e )  {  
       System.out.println ( "Unknown Host" + e ) ; 
        }  
      catch  ( IOException ex )   {  
      System.out.println ( "error io "+ ex ) ; 
       }  
 

Popular Tags