org.glassfish.hk2.classmodel.reflect.util
Class JarArchive

java.lang.Object
  extended by org.glassfish.hk2.classmodel.reflect.util.AbstractAdapter
      extended by org.glassfish.hk2.classmodel.reflect.util.JarArchive
All Implemented Interfaces:
Closeable, ArchiveAdapter

public class JarArchive
extends AbstractAdapter

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
 
Constructor Summary
JarArchive(Parser parser, URI uri)
           
 
Method Summary
 void close()
           
 Manifest getManifest()
          Returns the manifest instance for the archive.
 URI getURI()
          Returns the URI of the archive
 void onSelectedEntries(ArchiveAdapter.Selector selector, ArchiveAdapter.EntryTask task, Logger logger)
          perform a task on selected archive entries
 
Methods inherited from class org.glassfish.hk2.classmodel.reflect.util.AbstractAdapter
onAllEntries
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JarArchive

public JarArchive(Parser parser,
                  URI uri)
           throws IOException
Throws:
IOException
Method Detail

getURI

public URI getURI()
Description copied from interface: ArchiveAdapter
Returns 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: ArchiveAdapter
perform 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 perform
logger - for any logging activity
Throws:
IOException - can be generated while reading the archive entries

getManifest

public Manifest getManifest()
                     throws IOException
Description copied from interface: ArchiveAdapter
Returns the manifest instance for the archive.

Returns:
the archive's manifest
Throws:
IOException - if the manifest cannot be loaded.

close

public void close()
           throws IOException
Throws:
IOException


Copyright © 2013 Oracle Corporation. All Rights Reserved.