Package io.quarkus.deployment.builditem
Class HotDeploymentWatchedFileBuildItem
java.lang.Object
io.quarkus.builder.item.BuildItem
io.quarkus.builder.item.MultiBuildItem
io.quarkus.deployment.builditem.HotDeploymentWatchedFileBuildItem
Identifies a file from a
reloadable module
that, if modified, may result in a hot redeployment when in the dev mode.
A file may be identified with an location or a matching predicate. See HotDeploymentWatchedFileBuildItem.Builder.setLocation(String)
and
HotDeploymentWatchedFileBuildItem.Builder.setLocationPredicate(Predicate)
.
The location may be:
- a relative OS-agnostic file path where
/
is used as a separator; e.g.foo/bar.txt
- an absolute OS-specific file path; e.g.
/home/foo/bar.txt
- a glob pattern as defined in
FileSystem.getPathMatcher(String)
; e.g.*.sample
If multiple build items match the same file then the final value of restartNeeded
is computed as a logical OR of all
the isRestartNeeded()
values.
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionHotDeploymentWatchedFileBuildItem
(String location) HotDeploymentWatchedFileBuildItem
(String location, boolean restartNeeded) -
Method Summary
-
Constructor Details
-
Method Details
-
builder
-
getLocation
- Returns:
- a location a file from a reloadable module
-
hasLocation
public boolean hasLocation() -
getLocationPredicate
- Returns:
- a predicate used to match a file from a reloadable module
-
hasLocationPredicate
public boolean hasLocationPredicate() -
isRestartNeeded
public boolean isRestartNeeded()- Returns:
true
if a file change should result in an application restart,false
otherwise
-