Package io.quarkus.deployment
Interface ApplicationArchive
-
- All Known Implementing Classes:
ApplicationArchiveImpl
public interface ApplicationArchive
Represents an archive that is part of application code.An application archive is an archive that provides components to the application. As a result it will be indexed via jandex, and any deployment descriptors will be made available to the application.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description Path
getArchiveLocation()
Deprecated.in favor ofgetPaths()
Path
getArchiveRoot()
Deprecated.in favor ofgetRootDirs()
io.quarkus.bootstrap.model.AppArtifactKey
getArtifactKey()
default Path
getChildPath(String path)
Convenience method, returns the child path if it exists, otherwise null.org.jboss.jandex.IndexView
getIndex()
io.quarkus.bootstrap.model.PathsCollection
getPaths()
io.quarkus.bootstrap.model.PathsCollection
getRootDirs()
Returns paths representing the archive root directories.boolean
isJarArchive()
Deprecated.does not appear to be used anywhere and now it shouldn't bedefault void
processEntry(String path, BiConsumer<Path,Path> consumer)
Searches for the specified entry among the archive paths.
-
-
-
Method Detail
-
getIndex
org.jboss.jandex.IndexView getIndex()
- Returns:
- The index of this application Archive
-
getArchiveRoot
@Deprecated Path getArchiveRoot()
Deprecated.in favor ofgetRootDirs()
Returns a path representing the archive root. Note that if this is a jar archive this is not the path to the jar, but rather a path to the root of the mountedcom.sun.nio.zipfs.ZipFileSystem
- Returns:
- The archive root.
-
isJarArchive
@Deprecated boolean isJarArchive()
Deprecated.does not appear to be used anywhere and now it shouldn't be- Returns:
true
if this archive is a jar
-
getArchiveLocation
@Deprecated Path getArchiveLocation()
Deprecated.in favor ofgetPaths()
If this archive is a jar file it will return the path to the jar file on the file system, otherwise it will return the directory that this corresponds to.
-
getRootDirs
io.quarkus.bootstrap.model.PathsCollection getRootDirs()
Returns paths representing the archive root directories. Note that every path in this collection is guaranteed to be a directory. If the actual application archive appears to be a JAR, this collection will include a path to the root of the mountedFileSystem
created from the JAR.- Returns:
- The archive root directories.
-
getPaths
io.quarkus.bootstrap.model.PathsCollection getPaths()
- Returns:
- The paths representing the application root paths.
-
getArtifactKey
io.quarkus.bootstrap.model.AppArtifactKey getArtifactKey()
- Returns:
- the artifact key or null if not available
-
getChildPath
default Path getChildPath(String path)
Convenience method, returns the child path if it exists, otherwise null.- Parameters:
path
- The child path- Returns:
- The child path, or null if it does not exist.
-
processEntry
default void processEntry(String path, BiConsumer<Path,Path> consumer)
Searches for the specified entry among the archive paths. If a root path appears to be a JAR, the entry will be searched among its entries. The first matched entry will be passed to the consumer along with its root path.- Parameters:
path
- relative entry pathconsumer
- entry consumer
-
-