For AI agents: the documentation index is at https://docs.gradle.org/llms.txt. Request any page with the header Accept: text/markdown to get Markdown. User manual pages are also available as Markdown by replacing .html with .md in the URL.

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 the all method, or it can be specific to a capability by calling one of the withCapability, withCapability or withCapability methods.

Since

5.6

Functions

Link copied to clipboard
abstract fun all(action: Action<in CapabilityResolutionDetails>)
Configures the resolution strategy of capability conflicts for all capabilities.
Link copied to clipboard
abstract fun withCapability(notation: Any, action: Action<in CapabilityResolutionDetails>)
abstract fun withCapability(capability: Capability, action: Action<in CapabilityResolutionDetails>)
abstract fun withCapability(group: String, name: String, action: Action<in CapabilityResolutionDetails>)
Configures the resolution strategy of a specific capability.