Package org.gradle.api.artifacts
Interface CapabilitiesResolution
-
public interface CapabilitiesResolution
Allows configuring the capabilities resolution strategy. When there's a capability conflict, this object will let you select what to do in that situation. The configuration can either be global, for any capability by calling theall(Action)
method, or it can be specific to a capability by calling one of thewithCapability(Object, Action)
,withCapability(Capability, Action)
orwithCapability(String, String, Action)
methods.- Since:
- 5.6
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
all(Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of capability conflicts for all capabilities.void
withCapability(java.lang.Object notation, Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of a specific capability.void
withCapability(java.lang.String group, java.lang.String name, Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of a specific capability.void
withCapability(Capability capability, Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of a specific capability.
-
-
-
Method Detail
-
all
void all(Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of capability conflicts for all capabilities.- Parameters:
action
- the configuration action
-
withCapability
void withCapability(Capability capability, Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of a specific capability. The capability version is irrelevant.- Parameters:
capability
- a capability to configureaction
- the configuration action
-
withCapability
void withCapability(java.lang.String group, java.lang.String name, Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of a specific capability.- Parameters:
group
- the group of the capability to configurename
- the name of the capability to configureaction
- the configuration action
-
withCapability
void withCapability(java.lang.Object notation, Action<? super CapabilityResolutionDetails> action)
Configures the resolution strategy of a specific capability.
-
-