FileDocCategorySizeDatePackage
chargenURLConnection.javaAPI DocExample793Thu Apr 03 15:27:02 BST 1997sun.net.www.protocol.chargen

chargenURLConnection

public class chargenURLConnection extends URLConnection

Fields Summary
Socket
theConnection
public static final int
defaultPort
Constructors Summary
public chargenURLConnection(URL u)


     
    super(u);
  
Methods Summary
public synchronized voidconnect()

  
    int port;
  
    if (!connected) {
      port = url.getPort();
      if ( port < 0) {
        port = defaultPort;
      }
      theConnection = new Socket(url.getHost(), port);
      connected = true;
    } 
  
  
public java.lang.StringgetContentType()

    return "text/plain";
  
public synchronized java.io.InputStreamgetInputStream()

  
    if (!connected) {
      connect();
    }
    return theConnection.getInputStream();