|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.net.URLConnection
java.net.JarURLConnection
no.sesat.search.http.protocol.jar.JarURLConnection
public class JarURLConnection
| Field Summary |
|---|
| Fields inherited from class java.net.URLConnection |
|---|
allowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCaches |
| Constructor Summary | |
|---|---|
JarURLConnection(URL url,
sun.net.www.protocol.jar.Handler handler)
|
|
| Method Summary | |
|---|---|
void |
addRequestProperty(String key,
String value)
Adds a general request property specified by a key-value pair. |
void |
connect()
|
boolean |
getAllowUserInteraction()
Returns the value of the allowUserInteraction field for
this object. |
Object |
getContent()
|
int |
getContentLength()
|
String |
getContentType()
|
boolean |
getDefaultUseCaches()
Returns the default value of a URLConnection's
useCaches flag. |
String |
getHeaderField(String name)
|
InputStream |
getInputStream()
|
JarEntry |
getJarEntry()
|
JarFile |
getJarFile()
|
Permission |
getPermission()
|
Map<String,List<String>> |
getRequestProperties()
Returns an unmodifiable Map of general request properties for this connection. |
String |
getRequestProperty(String key)
Returns the value of the named general request property for this connection. |
boolean |
getUseCaches()
Returns the value of this URLConnection's
useCaches field. |
void |
setAllowUserInteraction(boolean allowuserinteraction)
Set the value of the allowUserInteraction field of
this URLConnection. |
void |
setDefaultUseCaches(boolean defaultusecaches)
Sets the default value of the useCaches field to the
specified value. |
void |
setIfModifiedSince(long ifmodifiedsince)
Sets the value of the ifModifiedSince field of
this URLConnection to the specified value. |
void |
setRequestProperty(String key,
String value)
Sets the general request property. |
void |
setUseCaches(boolean usecaches)
Sets the value of the useCaches field of this
URLConnection to the specified value. |
| Methods inherited from class java.net.JarURLConnection |
|---|
getAttributes, getCertificates, getEntryName, getJarFileURL, getMainAttributes, getManifest |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public JarURLConnection(URL url,
sun.net.www.protocol.jar.Handler handler)
throws MalformedURLException,
IOException
MalformedURLException
IOException| Method Detail |
|---|
public JarFile getJarFile()
throws IOException
getJarFile in class JarURLConnectionIOException
public JarEntry getJarEntry()
throws IOException
getJarEntry in class JarURLConnectionIOException
public Permission getPermission()
throws IOException
getPermission in class URLConnectionIOException
public void connect()
throws IOException
connect in class URLConnectionIOException
public InputStream getInputStream()
throws IOException
getInputStream in class URLConnectionIOExceptionpublic int getContentLength()
getContentLength in class URLConnection
public Object getContent()
throws IOException
getContent in class URLConnectionIOExceptionpublic String getContentType()
getContentType in class URLConnectionpublic String getHeaderField(String name)
getHeaderField in class URLConnection
public void setRequestProperty(String key,
String value)
setRequestProperty in class URLConnectionkey - the keyword by which the request is known
(e.g., "accept").value - the value associated with it.public String getRequestProperty(String key)
getRequestProperty in class URLConnection
public void addRequestProperty(String key,
String value)
addRequestProperty in class URLConnectionkey - the keyword by which the request is known
(e.g., "accept").value - the value associated with it.public Map<String,List<String>> getRequestProperties()
getRequestProperties in class URLConnectionpublic void setAllowUserInteraction(boolean allowuserinteraction)
allowUserInteraction field of
this URLConnection.
setAllowUserInteraction in class URLConnectionallowuserinteraction - the new value.URLConnection.allowUserInteractionpublic boolean getAllowUserInteraction()
allowUserInteraction field for
this object.
getAllowUserInteraction in class URLConnectionallowUserInteraction field for
this object.URLConnection.allowUserInteractionpublic void setUseCaches(boolean usecaches)
useCaches field of this
URLConnection to the specified value.
Some protocols do caching of documents. Occasionally, it is important to be able to "tunnel through" and ignore the caches (e.g., the "reload" button in a browser). If the UseCaches flag on a connection is true, the connection is allowed to use whatever caches it can. If false, caches are to be ignored. The default value comes from DefaultUseCaches, which defaults to true.
setUseCaches in class URLConnectionURLConnection.useCachespublic boolean getUseCaches()
URLConnection's
useCaches field.
getUseCaches in class URLConnectionURLConnection's
useCaches field.URLConnection.useCachespublic void setIfModifiedSince(long ifmodifiedsince)
ifModifiedSince field of
this URLConnection to the specified value.
setIfModifiedSince in class URLConnectionvalue - the new value.URLConnection.ifModifiedSincepublic void setDefaultUseCaches(boolean defaultusecaches)
useCaches field to the
specified value.
setDefaultUseCaches in class URLConnectiondefaultusecaches - the new value.URLConnection.useCachespublic boolean getDefaultUseCaches()
URLConnection's
useCaches flag.
Ths default is "sticky", being a part of the static state of all URLConnections. This flag applies to the next, and all following URLConnections that are created.
getDefaultUseCaches in class URLConnectionURLConnection's
useCaches flag.URLConnection.useCaches
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||