gnu.inet.gopher
Class GopherURLConnection

java.lang.Object
  extended by java.net.URLConnection
      extended by gnu.inet.gopher.GopherURLConnection

public class GopherURLConnection
extends java.net.URLConnection

A Gopher URL connection.

Author:
Chris Burdess

Field Summary
protected  GopherConnection connection
          The connection managing the protocol exchange.
 
Fields inherited from class java.net.URLConnection
allowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCaches
 
Constructor Summary
GopherURLConnection(java.net.URL url)
          Constructs a Gopher connection to the specified URL.
 
Method Summary
 void connect()
          Establishes the connection.
 java.lang.Object getContent()
           
 java.lang.Object getContent(java.lang.Class[] classes)
           
 java.io.InputStream getInputStream()
          Returns an input stream that reads from this open connection.
 java.io.OutputStream getOutputStream()
          Returns an output stream that writes to this connection.
 
Methods inherited from class java.net.URLConnection
addRequestProperty, getAllowUserInteraction, getConnectTimeout, getContentEncoding, getContentLength, getContentType, getDate, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getDoInput, getDoOutput, getExpiration, getFileNameMap, getHeaderField, getHeaderField, getHeaderFieldDate, getHeaderFieldInt, getHeaderFieldKey, getHeaderFields, getIfModifiedSince, getLastModified, getPermission, getReadTimeout, getRequestProperties, getRequestProperty, getURL, getUseCaches, guessContentTypeFromName, guessContentTypeFromStream, setAllowUserInteraction, setConnectTimeout, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setDefaultUseCaches, setDoInput, setDoOutput, setFileNameMap, setIfModifiedSince, setReadTimeout, setRequestProperty, setUseCaches, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

connection

protected GopherConnection connection
The connection managing the protocol exchange.

Constructor Detail

GopherURLConnection

public GopherURLConnection(java.net.URL url)
Constructs a Gopher connection to the specified URL.

Parameters:
url - the URL
Method Detail

connect

public void connect()
             throws java.io.IOException
Establishes the connection.

Specified by:
connect in class java.net.URLConnection
Throws:
java.io.IOException

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.IOException
Returns an input stream that reads from this open connection.

Overrides:
getInputStream in class java.net.URLConnection
Throws:
java.io.IOException

getOutputStream

public java.io.OutputStream getOutputStream()
                                     throws java.io.IOException
Returns an output stream that writes to this connection.

Overrides:
getOutputStream in class java.net.URLConnection
Throws:
java.io.IOException

getContent

public java.lang.Object getContent()
                            throws java.io.IOException
Overrides:
getContent in class java.net.URLConnection
Throws:
java.io.IOException

getContent

public java.lang.Object getContent(java.lang.Class[] classes)
                            throws java.io.IOException
Overrides:
getContent in class java.net.URLConnection
Throws:
java.io.IOException


© Copyright 2003 The Free Software Foundation, all rights reserved