Implementation Note
This class needs to maintain JDK 8 source compatibility. It is used internally in the JDK to implement jimage/jrtfs access, but also compiled and delivered as part of the jrtfs.jar to support access to the jimage file provided by the shipped JDK by tools running on JDK 8.
| Modifier and Type | Class and Description |
|---|---|
| private class |
| Modifier and Type | Field and Description |
|---|---|
| private static final String | |
| private final Path | |
| private final BasicFileAttributes | |
| private final Map | |
| private static final String | |
| private final String |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public synchronized void | close()
Implements abstract jdk. Implements java. Closes this resource, relinquishing any underlying resources. |
| private ImageReader. | Returns: the newly created and cached node, ornull if the given
path references a file which must be hidden in the node hierarchy.a resource or directory node name, of the form "/modules/...". name, Path the path of a file for a resource or directory. path)Lazily creates and caches a |
| public synchronized ImageReader. | |
| private String | |
| public byte[] | |
| private void | |
| private static boolean | |
| private String | |
| private String | |
| private Path | underlyingModulesPath(String name)
Returns the expected file path for name in the "/modules/..." namespace,
or |
| MODULES | back to summary |
|---|---|
| private static final String MODULES | |
| modulesDir | back to summary |
|---|---|
| private final Path modulesDir | |
| modulesDirAttrs | back to summary |
|---|---|
| private final BasicFileAttributes modulesDirAttrs | |
| nodes | back to summary |
|---|---|
| private final Map<String, ExplodedImage. | |
| PACKAGES | back to summary |
|---|---|
| private static final String PACKAGES | |
| separator | back to summary |
|---|---|
| private final String separator | |
| ExplodedImage | back to summary |
|---|---|
| pack-priv ExplodedImage(Path modulesDir) throws IOException | |
| close | back to summary |
|---|---|
| public synchronized void close() throws IOException Implements abstract jdk. Implements java. Doc from java. Closes this resource, relinquishing any underlying resources.
This method is invoked automatically on objects managed by the
| |
| createModulesNode | back to summary |
|---|---|
| private ImageReader. Lazily creates and caches a
| |
| findNode | back to summary |
|---|---|
| public synchronized ImageReader. Implements abstract jdk.
| |
| frontSlashToNativeSlash | back to summary |
|---|---|
| private String frontSlashToNativeSlash(String str) | |
| getResource | back to summary |
|---|---|
| public byte[] getResource(ImageReader. Implements abstract jdk.
| |
| initNodes | back to summary |
|---|---|
| private void initNodes() throws IOException | |
| isNonEmptyModulesPath | back to summary |
|---|---|
| private static boolean isNonEmptyModulesPath(String name) | |
| nativeSlashToFrontSlash | back to summary |
|---|---|
| private String nativeSlashToFrontSlash(String str) | |
| slashesToDots | back to summary |
|---|---|
| private String slashesToDots(String str) | |
| underlyingModulesPath | back to summary |
|---|---|
| private Path underlyingModulesPath(String name) Returns the expected file path for name in the "/modules/..." namespace,
or | |
| Modifier and Type | Field and Description |
|---|---|
| private List | |
| private ExplodedImage. | |
| private Path |
| Access | Constructor and Description |
|---|---|
| private | |
| private | |
| private |
| Modifier and Type | Method and Description |
|---|---|
| public Stream | getChildNames()
Overrides jdk. Returns the fully qualified names of any child nodes for a directory. |
| private byte[] | |
| public boolean | isDirectory()
Overrides jdk. Returns whether this node is a directory. |
| public boolean | isLink()
Overrides jdk. Returns whether this node is a symbolic link. |
| public boolean | isResource()
Overrides jdk. Returns whether this node is a resource. |
| public ExplodedImage. | resolveLink(boolean recursive)
Overrides jdk. Resolves a symbolic link to its target node. |
| public long | size()
Overrides jdk. Returns the uncompressed size of this node's content. |
| children | back to summary |
|---|---|
| private List<ImageReader. | |
| link | back to summary |
|---|---|
| private ExplodedImage. | |
| path | back to summary |
|---|---|
| private Path path | |
| PathNode | back to summary |
|---|---|
| private PathNode(String name, Path path, BasicFileAttributes attrs) | |
| PathNode | back to summary |
|---|---|
| private PathNode(String name, ImageReader. | |
| PathNode | back to summary |
|---|---|
| private PathNode(String name, List<ImageReader. | |
| getChildNames | back to summary |
|---|---|
| public Stream Overrides jdk. Doc from jdk. Returns the fully qualified names of any child nodes for a directory. By default, this method throws
| |
| getContent | back to summary |
|---|---|
| private byte[] getContent() throws IOException | |
| isDirectory | back to summary |
|---|---|
| public boolean isDirectory() Overrides jdk. Doc from jdk. Returns whether this node is a directory. Directory nodes can have
| |
| isLink | back to summary |
|---|---|
| public boolean isLink() Overrides jdk. Doc from jdk. Returns whether this node is a symbolic link.
| |
| isResource | back to summary |
|---|---|
| public boolean isResource() Overrides jdk. Doc from jdk. Returns whether this node is a resource. Resource nodes can have
their contents obtained via
| |
| resolveLink | back to summary |
|---|---|
| public ExplodedImage. Overrides jdk. Doc from jdk. Resolves a symbolic link to its target node. If this code is not a symbolic link, then it resolves to itself.
| |
| size | back to summary |
|---|---|
| public long size() Overrides jdk. Doc from jdk. Returns the uncompressed size of this node's content. If this node is not a resource, this method returns zero.
| |