Package org.apache.catalina.webresources
Class JarResourceRoot
- java.lang.Object
- 
- org.apache.catalina.webresources.AbstractResource
- 
- org.apache.catalina.webresources.JarResourceRoot
 
 
- 
- All Implemented Interfaces:
- WebResource
 
 public class JarResourceRoot extends AbstractResource 
- 
- 
Field Summary- 
Fields inherited from class org.apache.catalina.webresources.AbstractResourcesm
 
- 
 - 
Constructor SummaryConstructors Constructor Description JarResourceRoot(WebResourceRoot root, java.io.File base, java.lang.String baseUrl, java.lang.String webAppPath)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancanRead()booleandelete()protected java.io.InputStreamdoGetInputStream()booleanexists()java.lang.StringgetCanonicalPath()java.security.cert.Certificate[]getCertificates()java.net.URLgetCodeBase()byte[]getContent()longgetContentLength()longgetCreation()longgetLastModified()protected LoggetLog()java.util.jar.ManifestgetManifest()java.lang.StringgetName()java.net.URLgetURL()booleanisDirectory()booleanisFile()booleanisVirtual()Indicates if this resource is required for applications to correctly scan the file structure but that does not exist in either the main or any additionalWebResourceSet.- 
Methods inherited from class org.apache.catalina.webresources.AbstractResourcegetETag, getInputStream, getLastModifiedHttp, getMimeType, getWebappPath, getWebResourceRoot, setMimeType
 
- 
 
- 
- 
- 
Constructor Detail- 
JarResourceRootpublic JarResourceRoot(WebResourceRoot root, java.io.File base, java.lang.String baseUrl, java.lang.String webAppPath) 
 
- 
 - 
Method Detail- 
getLastModifiedpublic long getLastModified() - Returns:
- File.lastModified().
 
 - 
existspublic boolean exists() - Returns:
- File.exists().
 
 - 
isVirtualpublic boolean isVirtual() Description copied from interface:WebResourceIndicates if this resource is required for applications to correctly scan the file structure but that does not exist in either the main or any additionalWebResourceSet. For example, if an external directory is mapped to /WEB-INF/lib in an otherwise empty web application, /WEB-INF will be represented as a virtual resource.- Returns:
- truefor a virtual resource
 
 - 
isDirectorypublic boolean isDirectory() - Returns:
- File.isDirectory().
 
 - 
isFilepublic boolean isFile() - Returns:
- File.isFile().
 
 - 
deletepublic boolean delete() - Returns:
- File.delete().
 
 - 
getNamepublic java.lang.String getName() - Returns:
- File.getName().
 
 - 
getContentLengthpublic long getContentLength() - Returns:
- File.length().
 
 - 
getCanonicalPathpublic java.lang.String getCanonicalPath() - Returns:
- File.getCanonicalPath().
 
 - 
canReadpublic boolean canRead() - Returns:
- File.canRead().
 
 - 
doGetInputStreamprotected java.io.InputStream doGetInputStream() - Specified by:
- doGetInputStreamin class- AbstractResource
 
 - 
getContentpublic byte[] getContent() - Returns:
- the binary content of this resource or nullif it is not available in a byte[] because, for example, it is too big.
 
 - 
getCreationpublic long getCreation() - Returns:
- The time the file was created. If not available, the result of
 WebResource.getLastModified()will be returned.
 
 - 
getURLpublic java.net.URL getURL() - Returns:
- a URL to access the resource or nullif no such URL is available or if the resource does not exist.
 
 - 
getCodeBasepublic java.net.URL getCodeBase() - Returns:
- the code base for this resource that will be used when looking up the assigned permissions for the code base in the security policy file when running under a security manager.
 
 - 
getLogprotected Log getLog() - Specified by:
- getLogin class- AbstractResource
 
 - 
getCertificatespublic java.security.cert.Certificate[] getCertificates() - Returns:
- the certificates that were used to sign this resource to verify it or @null if none.
- See Also:
- JarEntry.getCertificates()
 
 - 
getManifestpublic java.util.jar.Manifest getManifest() - Returns:
- the manifest associated with this resource or @null if none.
- See Also:
- JarFile.getManifest()
 
 
- 
 
-