public interface Archive
Modifier and Type | Method and Description |
---|---|
void |
close()
closes this archive and releases all resources
|
Enumeration<String> |
entries()
Returns an enumeration of the module file entries.
|
Enumeration<String> |
entries(String prefix)
Returns an enumeration of the module file entries with the
specified prefix.
|
long |
getArchiveSize()
Returns the size of the archive.
|
Collection<String> |
getDirectories()
Returns the enumeration of first level directories in this
archive
|
Manifest |
getManifest()
Returns the manifest information for this archive
|
String |
getName()
Returns the name of the archive.
|
URI |
getURI()
Returns the path used to create or open the underlying archive
|
boolean |
isDirectory(String name)
Returns true if the entry is a directory or a plain file
|
void close() throws IOException
IOException
Enumeration<String> entries()
Enumeration<String> entries(String prefix)
prefix
- the prefix of entries to be includedCollection<String> getDirectories() throws IOException
IOException
boolean isDirectory(String name)
name
- name is one of the entries returned by entries()
Manifest getManifest() throws IOException
IOException
URI getURI()
TODO: abstraction breakage:
Several callers, most notably DeploymentContext.getSourceDir()
implementation, assumes that this URI is an URL, and in fact file URL.
If this needs to be URL, use of URI
is misleading. And furthermore,
if its needs to be a file URL, this should be File
.
long getArchiveSize() throws SecurityException
SecurityException
String getName()
Implementations should not return null.
Copyright © 2018. All rights reserved.