gradle
8.3

# DependencyConstraint

interface DependencyConstraint : ModuleVersionSelector, HasConfigurableAttributes<SELF>

Represents a constraints over all, including transitive, dependencies.

## Functions

attributes
Link copied to clipboard
abstract fun attributes(configureAction: Action<out Any>): DependencyConstraint
Mutates the attributes of this constraint.
because
Link copied to clipboard
abstract fun because(@Nullable reason: String)
Sets the reason why this dependency constraint should be used.
getAttributes
Link copied to clipboard
abstract fun getAttributes(): AttributeContainer
Returns the attributes for this constraint.
getGroup
Link copied to clipboard
abstract fun getGroup(): String
getModule
Link copied to clipboard
abstract fun getModule(): ModuleIdentifier
getName
Link copied to clipboard
abstract fun getName(): String
getReason
Link copied to clipboard
@Nullable
abstract fun getReason(): String
Returns a reason why this dependency constraint should be used, in particular with regards to its version.
getVersion
Link copied to clipboard
abstract fun getVersion(): String
getVersionConstraint
Link copied to clipboard
abstract fun getVersionConstraint(): VersionConstraint
Returns the version constraint to be used during selection.
matchesStrictly
Link copied to clipboard
abstract fun matchesStrictly(identifier: ModuleVersionIdentifier): Boolean
version
Link copied to clipboard
abstract fun version(configureAction: Action<out Any>)
Configures the version constraint for this dependency constraint.