English | Site Directory

Android - An Open Handset Alliance Project

java.net
public abstract class

java.net.JarURLConnection

java.lang.Object
java.net.URLConnection
java.net.JarURLConnection

This class establishes a connection to a URL using the jar protocol. Jar URLs are specified as follows:

jar:!/{entry}
where "!/" is called a seperator.

Summary

Fields

protected      URLConnection  jarFileURLConnection   
Fields inherited from class java.net.URLConnection

Protected Constructors

          JarURLConnection(URL url)
Contructs an instance of JarURLConnection.

Public Methods

        Attributes  getAttributes()
Answers the attributes of the JarEntry referenced by this JarURLConnection.
        Certificate[]  getCertificates()
Answers the Certificates of the JarEntry referenced by this URLConnection.
        String  getEntryName()
Answers the JarEntry name of the entry referenced by this URLConnection.
        JarEntry  getJarEntry()
Answers the JarEntry of the entry referenced by this URLConnection.
abstract        JarFile  getJarFile()
Answers the the JarFile referenced by this URLConnection.
        URL  getJarFileURL()
Answers the URL of the JarFile referenced by this URLConnection.
        Attributes  getMainAttributes()
Answers the main Attributes of the JarFile referenced by this URLConnection.
        Manifest  getManifest()
Answers the Manifest associated with the Jar URL
Methods inherited from class java.net.URLConnection
Methods inherited from class java.lang.Object

Details

Fields

protected URLConnection jarFileURLConnection

Protected Constructors

protected JarURLConnection(URL url)

Contructs an instance of JarURLConnection.

Parameters

url java.net.URL the URL that contains the location to connect to

Public Methods

public Attributes getAttributes()

Answers the attributes of the JarEntry referenced by this JarURLConnection.

Returns

  • java.util.jar.Attributes the attributes of the the JarEntry

Throws

IOException thrown if an IO exception occurs while retrieving the JarEntry

public Certificate[] getCertificates()

Answers the Certificates of the JarEntry referenced by this URLConnection. This method will return null until the InputStream has been completely verified

Returns

  • Certificate[] the Certificates of the JarEntry.

Throws

IOException thrown if there is an IO exception occurs while getting the JarEntry.

public String getEntryName()

Answers the JarEntry name of the entry referenced by this URLConnection.

Returns

  • java.lang.String the JarEntry name

public JarEntry getJarEntry()

Answers the JarEntry of the entry referenced by this URLConnection.

Returns

  • java.util.jar.JarEntry the JarEntry referenced

Throws

IOException

public abstract JarFile getJarFile()

Answers the the JarFile referenced by this URLConnection.

Returns

  • java.util.jar.JarFile the JarFile

Throws

IOException thrown if an IO exception occurs while retrieving the Jar file

public URL getJarFileURL()

Answers the URL of the JarFile referenced by this URLConnection.

Returns

  • java.net.URL the URL of the JarFile.

public Attributes getMainAttributes()

Answers the main Attributes of the JarFile referenced by this URLConnection.

Returns

  • java.util.jar.Attributes the Attributes of the the JarFile

Throws

IOException thrown if an IO exception occurs while retrieving the JarFile

public Manifest getManifest()

Answers the Manifest associated with the Jar URL

Returns

  • java.util.jar.Manifest The JarFile's Manifest

Throws

IOException
Build m5-rc15i - 10 Jun 2008 13:54