Package org.apache.commons.vfs2.provider
Class DefaultURLConnection
java.lang.Object
java.net.URLConnection
org.apache.commons.vfs2.provider.DefaultURLConnection
A default URL connection that will work for most file systems.
-
Field Summary
FieldsFields inherited from class java.net.URLConnection
allowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCaches -
Constructor Summary
ConstructorsConstructorDescriptionDefaultURLConnection(URL url, FileContent fileContent) Constructs a new instance. -
Method Summary
Methods inherited from class java.net.URLConnection
addRequestProperty, getAllowUserInteraction, getConnectTimeout, getContent, getContent, getContentLengthLong, getDate, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getDoInput, getDoOutput, getExpiration, getFileNameMap, getHeaderField, getHeaderField, getHeaderFieldDate, getHeaderFieldInt, getHeaderFieldKey, getHeaderFieldLong, getHeaderFields, getIfModifiedSince, getPermission, getReadTimeout, getRequestProperties, getRequestProperty, getURL, getUseCaches, guessContentTypeFromName, guessContentTypeFromStream, setAllowUserInteraction, setConnectTimeout, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setDefaultUseCaches, setDoInput, setDoOutput, setFileNameMap, setIfModifiedSince, setReadTimeout, setRequestProperty, setUseCaches, toString
-
Field Details
-
fileContent
-
-
Constructor Details
-
DefaultURLConnection
Constructs a new instance.- Parameters:
url- The URL to connect.fileContent- The URL fileContent.
-
-
Method Details
-
connect
public void connect()- Specified by:
connectin classURLConnection
-
getContentEncoding
- Overrides:
getContentEncodingin classURLConnection
-
getContentLength
public int getContentLength()- Overrides:
getContentLengthin classURLConnection
-
getContentType
- Overrides:
getContentTypein classURLConnection
-
getInputStream
- Overrides:
getInputStreamin classURLConnection- Throws:
IOException
-
getLastModified
public long getLastModified()- Overrides:
getLastModifiedin classURLConnection
-
getOutputStream
- Overrides:
getOutputStreamin classURLConnection- Throws:
IOException
-