APIdia Launch Partner
Top Description Inners Methods
jdk.tools.jlink.internal

public Interface Archive

extends Closeable
Known Direct Implementers
jdk.tools.jlink.internal.DirArchive, jdk.tools.jlink.internal.JarArchive, jdk.tools.jlink.internal.JmodArchive, jdk.tools.jlink.internal.JRTArchive
Imports
java.io.Closeable, .IOException, .InputStream, java.nio.file.Path, java.util.Objects, java.util.stream.Stream

An Archive of all content, classes, resources, configuration files, and other, for a module.

Nested and Inner Type Summary

Modifier and TypeClass and Description
public abstract static class
Archive.Entry

Entry is contained in an Archive

Method Summary

Modifier and TypeMethod and Description
public void
close()

Redeclares java.io.Closeable.close.

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

public Stream<Archive.Entry>
public Path
public String
public void
open()

Method Detail

closeback to summary
public void close() throws IOException

Redeclares 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
entriesback to summary
public Stream<Archive.Entry> entries()
getPathback to summary
public Path getPath()
moduleNameback to summary
public String moduleName()
openback to summary
public void open() throws IOException
jdk.tools.jlink.internal back to summary

public abstract Class Archive.Entry

extends Object
Class Inheritance
Known Direct Subclasses
jdk.tools.jlink.internal.DirArchive.FileEntry, jdk.tools.jlink.internal.JarArchive.JarEntry, jdk.tools.jlink.internal.JmodArchive.JmodEntry

Entry is contained in an Archive

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static enum

Field Summary

Modifier and TypeField and Description
private final Archive
private final String
private final String
private final Archive.Entry.EntryType

Constructor Summary

AccessConstructor and Description
public
Entry(Archive
the archive in which this entry exists.
archive
,
String
the complete path of the entry, including the module.
path
,
String
an entry name relative to its containing module.
name
,
Archive.Entry.EntryType
the entry type.
type
)

Constructs an entry of the given archive.

Method Summary

Modifier and TypeMethod and Description
public final String
getResourcePoolEntryName()

Returns the name representing a ResourcePoolEntry in the form of: /$MODULE/$ENTRY_NAME

public final String
name()

Returns the name of this entry.

public abstract long
size()

public abstract InputStream
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

public final Archive.Entry.EntryType
type()

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

archiveback to summary
private final Archive archive
nameback to summary
private final String name
pathback to summary
private final String path
typeback to summary
private final Archive.Entry.EntryType type

Constructor Detail

Entryback to summary
public Entry(Archive archive, String path, String name, Archive.Entry.EntryType type)

Constructs an entry of the given archive.

Parameters
archive:Archive

the archive in which this entry exists.

path:String

the complete path of the entry, including the module.

name:String

an entry name relative to its containing module.

type:Archive.Entry.EntryType

the entry type.

Method Detail

getResourcePoolEntryNameback to summary
public final String getResourcePoolEntryName()

Returns the name representing a ResourcePoolEntry in the form of: /$MODULE/$ENTRY_NAME

nameback to summary
public final String name()

Returns the name of this entry.

sizeback to summary
public abstract long size()
streamback to summary
public abstract InputStream stream() 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
typeback to summary
public final Archive.Entry.EntryType type()
jdk.tools.jlink.internal back to summary

public final Enum Archive.Entry.EntryType

extends Enum<Archive.Entry.EntryType>
Class Inheritance

Field Summary

Modifier and TypeField and Description
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType
public static final Archive.Entry.EntryType

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static Archive.Entry.EntryType
public static Archive.Entry.EntryType[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

CLASS_OR_RESOURCEback to summary
public static final Archive.Entry.EntryType CLASS_OR_RESOURCE
CONFIGback to summary
public static final Archive.Entry.EntryType CONFIG
HEADER_FILEback to summary
public static final Archive.Entry.EntryType HEADER_FILE
LEGAL_NOTICEback to summary
public static final Archive.Entry.EntryType LEGAL_NOTICE
MAN_PAGEback to summary
public static final Archive.Entry.EntryType MAN_PAGE
MODULE_NAMEback to summary
public static final Archive.Entry.EntryType MODULE_NAME
NATIVE_CMDback to summary
public static final Archive.Entry.EntryType NATIVE_CMD
NATIVE_LIBback to summary
public static final Archive.Entry.EntryType NATIVE_LIB
SERVICEback to summary
public static final Archive.Entry.EntryType SERVICE

Constructor Detail

EntryTypeback to summary
private EntryType()

Method Detail

valueOfback to summary
public static Archive.Entry.EntryType valueOf(String name)
valuesback to summary
public static Archive.Entry.EntryType[] values()