Package io.quarkus.deployment
Class Capabilities
java.lang.Object
io.quarkus.builder.item.BuildItem
io.quarkus.builder.item.SimpleBuildItem
io.quarkus.deployment.Capabilities
This build items holds the set of registered capabilities.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisCapabilityWithPrefixMissing(String capabilityPrefix) Checks whether a capability with a given prefix is missing during the build.booleanisCapabilityWithPrefixPresent(String capabilityPrefix) Checks whether a capability with a given prefix is present during the build.booleanChecks whether a given capability is missing during the build.booleanChecks whether a given capability is present during the build.
-
Constructor Details
-
Capabilities
-
-
Method Details
-
getCapabilities
-
isPresent
Checks whether a given capability is present during the build.- Parameters:
capability- capability name- Returns:
- true, in case the capability is present, otherwise - false
-
isMissing
Checks whether a given capability is missing during the build.- Parameters:
capability- capability name- Returns:
- true, in case the capability is missing, otherwise - false
-
isCapabilityWithPrefixPresent
Checks whether a capability with a given prefix is present during the build.A capability name is a dot-separated string. A prefix is also a string that is composed of either the first capability name element or a dot separated sequence of the capability name elements starting from the first one.
E.g. for capability
io.quarkus.resteasy.json.jacksonthe following prefixes will be registered:ioio.quarkusio.quarkus.resteasyio.quarkus.resteasy.json
io.quarkus.resteasy.jsonis present during the build.Given that only a single provider of a given capability is allowed in an application, capability prefixes allow expressing a certain common aspect among different but somewhat related capabilities.
E.g. there could be extensions providing the following capabilities:
io.quarkus.resteasy.json.jacksonio.quarkus.resteasy.json.jackson.clientio.quarkus.resteasy.json.jsonbio.quarkus.resteasy.json.jsonb.client
io.quarkus.resteasy.jsonis present.- Parameters:
capabilityPrefix- capability prefix- Returns:
- true, in case the capability with the given prefix is present, otherwise - false
-
isCapabilityWithPrefixMissing
Checks whether a capability with a given prefix is missing during the build. This method simple callsisCapabilityWithPrefixPresent(String)and returns its result inverted.- Parameters:
capabilityPrefix- capability prefix- Returns:
- true, in case the capability with the given prefix is missing, otherwise - false
-