Interface AppImageLayout
- All Known Subinterfaces:
ApplicationLayout
,RuntimeLayout
- All Known Implementing Classes:
AppImageLayout.Stub
public interface AppImageLayout
Generic app image directory layout.
App image layout is a collection of files and directories with specific roles
(executables, configuration files, etc.) sharing the same root directory.
The layout is "unresolved" if the root directory is an empty string and
"resolved" otherwise.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final record
Default implementation ofAppImageLayout
interface. -
Method Summary
Modifier and TypeMethodDescriptionCreates a copy of this app image resolved at the given root directory.Root directory of this app image.A path to Java runtime directory.static PathGroup
toPathGroup
(AppImageLayout appImageLayout) CreatesPathGroup
object from the givenAppImageLayout
instance.
-
Method Details
-
runtimeDirectory
Path runtimeDirectory()A path to Java runtime directory. The directory should have standard JDK subdirectories like "bin", "lib", etc.- Returns:
- Java runtime sub-directory within this app image
-
rootDirectory
Path rootDirectory()Root directory of this app image. It should normally be equal toPath.of("")
for unresolved layout.- Returns:
- the root directory of this app image
-
resolveAt
Creates a copy of this app image resolved at the given root directory.- Parameters:
root
- path to a directory at which to resolve the layout- Returns:
- a copy of this app image resolved at the given root directory
-
toPathGroup
CreatesPathGroup
object from the givenAppImageLayout
instance. It will call every non-static accessible method without parameters and withPath
return type of the givenAppImageLayout
instance exceptrootDirectory()
method.For every call, it will save the return value in the output
PathGroup
object under the key equals the name of a function used in the call.- Parameters:
appImageLayout
- source layout object- Returns:
PathGroup
object constructed from the given source layout object
-