public class GopherURLConnection
extends java.net.URLConnection
Modifier and Type | Field and Description |
---|---|
protected GopherConnection |
connection
The connection managing the protocol exchange.
|
Constructor and Description |
---|
GopherURLConnection(java.net.URL url)
Constructs a Gopher connection to the specified URL.
|
Modifier and Type | Method and Description |
---|---|
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.
|
addRequestProperty, getAllowUserInteraction, getConnectTimeout, getContentEncoding, getContentLength, getContentLengthLong, getContentType, getDate, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getDoInput, getDoOutput, getExpiration, getFileNameMap, getHeaderField, getHeaderField, getHeaderFieldDate, getHeaderFieldInt, getHeaderFieldKey, getHeaderFieldLong, 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
protected GopherConnection connection
public GopherURLConnection(java.net.URL url)
url
- the URLpublic void connect() throws java.io.IOException
connect
in class java.net.URLConnection
java.io.IOException
public java.io.InputStream getInputStream() throws java.io.IOException
getInputStream
in class java.net.URLConnection
java.io.IOException
public java.io.OutputStream getOutputStream() throws java.io.IOException
getOutputStream
in class java.net.URLConnection
java.io.IOException
public java.lang.Object getContent() throws java.io.IOException
getContent
in class java.net.URLConnection
java.io.IOException
public java.lang.Object getContent(java.lang.Class[] classes) throws java.io.IOException
getContent
in class java.net.URLConnection
java.io.IOException