Class FilterURLConnection
java.lang.Object
java.net.URLConnection
ro.sync.ecss.extensions.api.webapp.plugin.FilterURLConnection
- All Implemented Interfaces:
FileBrowsingConnection
@API(src=PUBLIC,
type=EXTENDABLE)
public class FilterURLConnection
extends URLConnection
implements FileBrowsingConnection
URLConnection that delegates all methods to the connection given as a
parameter.
- Since:
- 17
-
Field Summary
FieldsFields inherited from class java.net.URLConnection
allowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCaches
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addRequestProperty
(String key, String value) void
connect()
boolean
boolean
int
getContent
(Class[] classes) int
long
getDate()
boolean
boolean
boolean
long
getHeaderField
(int n) getHeaderField
(String name) long
getHeaderFieldDate
(String name, long Default) int
getHeaderFieldInt
(String name, int Default) getHeaderFieldKey
(int n) long
long
int
getRequestProperty
(String key) getURL()
boolean
int
hashCode()
Retrieves all children of the directory identified by the URL on which this connection is made.void
setAllowUserInteraction
(boolean allowuserinteraction) void
setConnectTimeout
(int timeout) void
setDefaultUseCaches
(boolean defaultusecaches) void
setDoInput
(boolean doinput) void
setDoOutput
(boolean dooutput) void
setIfModifiedSince
(long ifmodifiedsince) void
setReadTimeout
(int timeout) void
setRequestProperty
(String key, String value) void
setUseCaches
(boolean usecaches) toString()
Methods inherited from class java.net.URLConnection
getContentLengthLong, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getFileNameMap, getHeaderFieldLong, guessContentTypeFromName, guessContentTypeFromStream, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setDefaultUseCaches, setFileNameMap
-
Field Details
-
delegateConnection
The underlying connection.
-
-
Constructor Details
-
FilterURLConnection
Constructor.- Parameters:
delegateConnection
- The underlying connection.
-
-
Method Details
-
getInputStream
- Overrides:
getInputStream
in classURLConnection
- Throws:
IOException
- See Also:
-
getOutputStream
- Overrides:
getOutputStream
in classURLConnection
- Throws:
IOException
- See Also:
-
connect
- Specified by:
connect
in classURLConnection
- Throws:
IOException
- See Also:
-
addRequestProperty
- Overrides:
addRequestProperty
in classURLConnection
- See Also:
-
equals
-
getAllowUserInteraction
public boolean getAllowUserInteraction()- Overrides:
getAllowUserInteraction
in classURLConnection
- See Also:
-
getConnectTimeout
public int getConnectTimeout()- Overrides:
getConnectTimeout
in classURLConnection
- See Also:
-
getContent
- Overrides:
getContent
in classURLConnection
- Throws:
IOException
- See Also:
-
getContent
- Overrides:
getContent
in classURLConnection
- Throws:
IOException
- See Also:
-
getContentEncoding
- Overrides:
getContentEncoding
in classURLConnection
- See Also:
-
getContentLength
public int getContentLength()- Overrides:
getContentLength
in classURLConnection
- See Also:
-
getContentType
- Overrides:
getContentType
in classURLConnection
- See Also:
-
getDate
public long getDate()- Overrides:
getDate
in classURLConnection
- See Also:
-
getDefaultUseCaches
public boolean getDefaultUseCaches()- Overrides:
getDefaultUseCaches
in classURLConnection
- See Also:
-
getDoInput
public boolean getDoInput()- Overrides:
getDoInput
in classURLConnection
- See Also:
-
getDoOutput
public boolean getDoOutput()- Overrides:
getDoOutput
in classURLConnection
- See Also:
-
getExpiration
public long getExpiration()- Overrides:
getExpiration
in classURLConnection
- See Also:
-
getHeaderField
- Overrides:
getHeaderField
in classURLConnection
- See Also:
-
getHeaderField
- Overrides:
getHeaderField
in classURLConnection
- See Also:
-
getHeaderFieldDate
- Overrides:
getHeaderFieldDate
in classURLConnection
- See Also:
-
getHeaderFieldInt
- Overrides:
getHeaderFieldInt
in classURLConnection
- See Also:
-
getHeaderFieldKey
- Overrides:
getHeaderFieldKey
in classURLConnection
- See Also:
-
getHeaderFields
- Overrides:
getHeaderFields
in classURLConnection
- See Also:
-
getIfModifiedSince
public long getIfModifiedSince()- Overrides:
getIfModifiedSince
in classURLConnection
- See Also:
-
getLastModified
public long getLastModified()- Overrides:
getLastModified
in classURLConnection
- See Also:
-
getPermission
- Overrides:
getPermission
in classURLConnection
- Throws:
IOException
- See Also:
-
getReadTimeout
public int getReadTimeout()- Overrides:
getReadTimeout
in classURLConnection
- See Also:
-
getRequestProperties
- Overrides:
getRequestProperties
in classURLConnection
- See Also:
-
getRequestProperty
- Overrides:
getRequestProperty
in classURLConnection
- See Also:
-
getURL
- Overrides:
getURL
in classURLConnection
- See Also:
-
getUseCaches
public boolean getUseCaches()- Overrides:
getUseCaches
in classURLConnection
- See Also:
-
hashCode
public int hashCode() -
setAllowUserInteraction
public void setAllowUserInteraction(boolean allowuserinteraction) - Overrides:
setAllowUserInteraction
in classURLConnection
- See Also:
-
setConnectTimeout
public void setConnectTimeout(int timeout) - Overrides:
setConnectTimeout
in classURLConnection
- See Also:
-
setDefaultUseCaches
public void setDefaultUseCaches(boolean defaultusecaches) - Overrides:
setDefaultUseCaches
in classURLConnection
- See Also:
-
setDoInput
public void setDoInput(boolean doinput) - Overrides:
setDoInput
in classURLConnection
- See Also:
-
setDoOutput
public void setDoOutput(boolean dooutput) - Overrides:
setDoOutput
in classURLConnection
- See Also:
-
setIfModifiedSince
public void setIfModifiedSince(long ifmodifiedsince) - Overrides:
setIfModifiedSince
in classURLConnection
- See Also:
-
setReadTimeout
public void setReadTimeout(int timeout) - Overrides:
setReadTimeout
in classURLConnection
- See Also:
-
setRequestProperty
- Overrides:
setRequestProperty
in classURLConnection
- See Also:
-
setUseCaches
public void setUseCaches(boolean usecaches) - Overrides:
setUseCaches
in classURLConnection
- See Also:
-
toString
- Overrides:
toString
in classURLConnection
- See Also:
-
listFolder
Description copied from interface:FileBrowsingConnection
Retrieves all children of the directory identified by the URL on which this connection is made.- Specified by:
listFolder
in interfaceFileBrowsingConnection
- Returns:
- For list of descriptors for each folder entry.
- Throws:
IOException
- If the remote server could not return a list of children.UserActionRequiredException
- Whether the browsing requires user interaction, like login.- See Also:
-