public interface Archive extends Iterable<Archive.Entry>, AutoCloseable
Launcher.JarFileArchive| Modifier and Type | Interface and Description |
|---|---|
static interface |
Archive.Entry
Represents a single entry in the archive.
|
static interface |
Archive.EntryFilter
Strategy interface to filter
Entries. |
| Modifier and Type | Method and Description |
|---|---|
default void |
close()
Closes the
Archive, releasing any open resources. |
Manifest |
getManifest()
Returns the manifest of the archive.
|
default List<Archive> |
getNestedArchives(Archive.EntryFilter filter)
Deprecated.
since 2.3.0 in favor of
getNestedArchives(EntryFilter, EntryFilter) |
default Iterator<Archive> |
getNestedArchives(Archive.EntryFilter searchFilter,
Archive.EntryFilter includeFilter)
Returns nested
Archives for entries that match the specified filters. |
URL |
getUrl()
Returns a URL that can be used to load the archive.
|
default boolean |
isExploded()
Return if the archive is exploded (already unpacked).
|
Iterator<Archive.Entry> |
iterator()
Deprecated.
since 2.3.0 in favor of using
JarFile to access entries and
getNestedArchives(EntryFilter, EntryFilter) for accessing nested archives. |
forEach, spliteratorURL getUrl() throws MalformedURLException
MalformedURLException - if the URL is malformedManifest getManifest() throws IOException
IOException - if the manifest cannot be readdefault Iterator<Archive> getNestedArchives(Archive.EntryFilter searchFilter, Archive.EntryFilter includeFilter) throws IOException
Archives for entries that match the specified filters.searchFilter - filter used to limit when additional sub-entry searching is
required or null if all entries should be considered.includeFilter - filter used to determine which entries should be included in
the result or null if all entries should be includedIOException - on IO error@Deprecated default List<Archive> getNestedArchives(Archive.EntryFilter filter) throws IOException
getNestedArchives(EntryFilter, EntryFilter)Archives for entries that match the specified filter.filter - the filter used to limit entriesIOException - if nested archives cannot be read@Deprecated Iterator<Archive.Entry> iterator()
JarFile to access entries and
getNestedArchives(EntryFilter, EntryFilter) for accessing nested archives.iterator in interface Iterable<Archive.Entry>Iterable.iterator()default boolean isExploded()
default void close()
throws Exception
Archive, releasing any open resources.close in interface AutoCloseableException - if an error occurs during close processing