Class JarArchive
java.lang.Object
org.glassfish.hk2.classmodel.reflect.util.AbstractAdapter
org.glassfish.hk2.classmodel.reflect.util.JarArchive
- All Implemented Interfaces:
Closeable,AutoCloseable,ArchiveAdapter
Jar based archive abstraction
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.glassfish.hk2.classmodel.reflect.ArchiveAdapter
ArchiveAdapter.Entry, ArchiveAdapter.EntryTask, ArchiveAdapter.Selector -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final JarFileprivate final Parserprivate final AtomicIntegerWe need to maintain how many internal jars got opened so that we don't close our jar archive until all the sub scanning has been done successfully.private final URI -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Returns the manifest instance for the archive.getURI()Returns the URI of the archivevoidonSelectedEntries(ArchiveAdapter.Selector selector, ArchiveAdapter.EntryTask task, Logger logger) perform a task on selected archive entries(package private) voidMethods inherited from class org.glassfish.hk2.classmodel.reflect.util.AbstractAdapter
onAllEntries
-
Field Details
-
parser
-
jar
-
uri
-
releaseCount
We need to maintain how many internal jars got opened so that we don't close our jar archive until all the sub scanning has been done successfully.
-
-
Constructor Details
-
JarArchive
- Throws:
IOException
-
-
Method Details
-
getURI
Description copied from interface:ArchiveAdapterReturns the URI of the archive- Returns:
- URI of the archive
-
onSelectedEntries
public void onSelectedEntries(ArchiveAdapter.Selector selector, ArchiveAdapter.EntryTask task, Logger logger) throws IOException Description copied from interface:ArchiveAdapterperform a task on selected archive entries- Parameters:
selector- implementation to select the archive archive entries on which the task should be performed.task- the task to performlogger- for any logging activity- Throws:
IOException- can be generated while reading the archive entries
-
getManifest
Description copied from interface:ArchiveAdapterReturns the manifest instance for the archive.- Returns:
- the archive's manifest
- Throws:
IOException- if the manifest cannot be loaded.
-
close
- Throws:
IOException
-
releaseCount
- Throws:
IOException
-