Top Description Fields Constructors Methods
org.glassfish.hk2.classmodel.reflect.util

public Class DirectoryArchive

extends AbstractAdapter
Class Inheritance
Imports
org.glassfish.hk2.classmodel.reflect.Parser, java.io.*, java.nio.ByteBuffer, java.net.URI, java.util.jar.JarFile, .Manifest, java.util.logging.Level, .Logger

Directory base archive abstraction

Field Summary

Modifier and TypeField and Description
public final File
public final Parser

Constructor Summary

AccessConstructor and Description
public
DirectoryArchive(Parser parser, File directory)

Method Summary

Modifier and TypeMethod and Description
public void
close()

Implements java.io.Closeable.close.

Closes this stream and releases any system resources associated with it.

public Manifest
getManifest()

Implements org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.getManifest.

Returns the manifest instance for the archive.

public URI
getURI()

Implements org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.getURI.

Returns the URI of the archive

private String
public void
private void
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from org.glassfish.hk2.classmodel.reflect.util.AbstractAdapter:
onAllEntries

Field Detail

directoryback to summary
public final File directory
parserback to summary
public final Parser parser

Constructor Detail

DirectoryArchiveback to summary
public DirectoryArchive(Parser parser, File directory)

Method Detail

closeback to summary
public void close() throws IOException

Implements java.io.Closeable.close.

Doc from java.io.Closeable.close.

Closes this stream and releases any system resources associated with it. If the stream is already closed then invoking this method has no effect.

As noted in AutoCloseable#close(), cases where the close may fail require careful attention. It is strongly advised to relinquish the underlying resources and to internally mark the Closeable as closed, prior to throwing the IOException.

Annotations
@Override
Exceptions
IOException:
if an I/O error occurs
getManifestback to summary
public Manifest getManifest() throws IOException

Implements org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.getManifest.

Doc from org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.getManifest.

Returns the manifest instance for the archive.

Annotations
@Override
Exceptions
IOException:
if the manifest cannot be loaded.
getURIback to summary
public URI getURI()

Implements org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.getURI.

Doc from org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.getURI.

Returns the URI of the archive

Annotations
@Override
mangleback to summary
private String mangle(File f)
onSelectedEntriesback to summary
public void onSelectedEntries(ArchiveAdapter.Selector selector, ArchiveAdapter.EntryTask task, Logger logger) throws IOException

Implements org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.onSelectedEntries.

Doc from org.glassfish.hk2.classmodel.reflect.ArchiveAdapter.onSelectedEntries.

perform a task on selected archive entries

Annotations
@Override
Exceptions
IOException:
can be generated while reading the archive entries
parseback to summary
private void parse(File dir, ArchiveAdapter.Selector selector, ArchiveAdapter.EntryTask task, Logger logger) throws IOException
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Annotations
@Override