|
Enterprise Information Portal APIs |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.net.URLConnection | +--com.ibm.gcs.netutil.GCSFileConnection
The GCSFileConnection is a customization of the URLConnection object and defines a connection object corresponding to the GCS "file" protocol. A GCSFileConnection object is returned by the openConnection method of the GCSFileStreamHandler class for the "file" protocol. NOTE: Right now, GCS will NOT connect to a file on a machine other than the localhost. So file://another_machine/d:/foo/bar will throw an IOException.
URLConnection
,
GCSFileStreamHandler
Constructor Summary | |
GCSFileConnection(java.net.URL u)
(constructor) |
Method Summary | |
void |
connect()
Opens a connection to the URL if already not connected. |
int |
getContentLength()
Get the length of the content (length of the content header field). |
java.lang.String |
getContentType()
Returns the value of the content-type header field. |
java.io.InputStream |
getInputStream()
get an input stream that reads from this open connection overrides the super class's getInputStream method. |
Methods inherited from class java.net.URLConnection |
getAllowUserInteraction, getContent, getContent, getContentEncoding, getDate, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getDoInput, getDoOutput, getExpiration, getFileNameMap, getHeaderField, getHeaderField, getHeaderFieldDate, getHeaderFieldInt, getHeaderFieldKey, getIfModifiedSince, getLastModified, getOutputStream, getPermission, getRequestProperty, getURL, getUseCaches, guessContentTypeFromStream, setAllowUserInteraction, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setDefaultUseCaches, setDoInput, setDoOutput, setFileNameMap, setIfModifiedSince, setRequestProperty, setUseCaches, toString |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public GCSFileConnection(java.net.URL u)
u
- URL object for which a connection object is createdMethod Detail |
public java.io.InputStream getInputStream() throws java.io.IOException
getInputStream
in class java.net.URLConnection
java.io.IOException
- when a File IO exception happensURLConnection.getInputStream()
public java.lang.String getContentType()
getContentType
in class java.net.URLConnection
URLConnection.getContentType()
,
URLConnection.getContent()
,
GCSContentHandlerFactory
,
GCSFileContentHandler
public int getContentLength()
getContentLength
in class java.net.URLConnection
URLConnection.getContentLength()
public void connect() throws java.io.IOException
connected
field to true.connect
in class java.net.URLConnection
URLConnection.connect()
,
java.net.URLConnection#connected
|
EIP Web Crawler APIs | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |