gradle
8.5

# ClientModule

interface ClientModule : ExternalModuleDependency(source)

### Deprecated

To model a module in your dependency declarations. Usually you can either declare a single dependency artifact or you declare a module dependency that depends on a module descriptor in a repository. With a client module you can declare a module dependency without the need of a module descriptor in a remote repository.

Client modules dependencies are deprecated and will be removed in Gradle 9.0. Use component metadata rules instead.

#### See also

DependencyHandler

## Properties

ARCHIVES_CONFIGURATION
Link copied to clipboard
val ARCHIVES_CONFIGURATION: String = "archives"
CLASSIFIER
Link copied to clipboard
val CLASSIFIER: String = "m:classifier"
DEFAULT_CONFIGURATION
Link copied to clipboard
val DEFAULT_CONFIGURATION: String = "default"

## Functions

addArtifact
Link copied to clipboard
abstract fun addArtifact(artifact: DependencyArtifact): ModuleDependency
addDependency
Link copied to clipboard
abstract fun addDependency(dependency: ModuleDependency)
Add a dependency to the client module.
artifact
Link copied to clipboard
abstract fun artifact(configureClosure: Closure): DependencyArtifact
attributes
Link copied to clipboard
abstract fun attributes(configureAction: Action<out Any>): ModuleDependency
abstract fun attributes(action: Action<out Any>): SELF
because
Link copied to clipboard
abstract fun because(reason: String)
capabilities
Link copied to clipboard
abstract fun capabilities(configureAction: Action<out Any>): ModuleDependency
contentEquals
Link copied to clipboard
abstract fun contentEquals(dependency: Dependency): Boolean
copy
Link copied to clipboard
abstract fun copy(): ClientModule
abstract fun copy(): Dependency
abstract fun copy(): ExternalDependency
abstract fun copy(): ModuleDependency
doNotEndorseStrictVersions
Link copied to clipboard
abstract fun doNotEndorseStrictVersions()
endorseStrictVersions
Link copied to clipboard
abstract fun endorseStrictVersions()
exclude
Link copied to clipboard
abstract fun exclude(excludeProperties: Map<String, String>): ModuleDependency
getArtifacts
Link copied to clipboard
abstract fun getArtifacts(): Set<DependencyArtifact>
getAttributes
Link copied to clipboard
abstract fun getAttributes(): AttributeContainer
getDependencies
Link copied to clipboard
abstract fun getDependencies(): Set<ModuleDependency>
Returns all the dependencies added to the client module.
getExcludeRules
Link copied to clipboard
abstract fun getExcludeRules(): Set<ExcludeRule>
getGroup
Link copied to clipboard
abstract fun getGroup(): String
getId
Link copied to clipboard
abstract fun getId(): String
Returns the id of the client module.
getModule
Link copied to clipboard
abstract fun getModule(): ModuleIdentifier
getName
Link copied to clipboard
abstract fun getName(): String
getReason
Link copied to clipboard
abstract fun getReason(): String
getRequestedCapabilities
Link copied to clipboard
abstract fun getRequestedCapabilities(): List<Capability>
getTargetConfiguration
Link copied to clipboard
abstract fun getTargetConfiguration(): String
getVersion
Link copied to clipboard
abstract fun getVersion(): String
getVersionConstraint
Link copied to clipboard
abstract fun getVersionConstraint(): VersionConstraint
isChanging
Link copied to clipboard
abstract fun isChanging(): Boolean
isEndorsingStrictVersions
Link copied to clipboard
abstract fun isEndorsingStrictVersions(): Boolean
isForce
Link copied to clipboard
abstract fun isForce(): Boolean
isTransitive
Link copied to clipboard
abstract fun isTransitive(): Boolean
matchesStrictly
Link copied to clipboard
abstract fun matchesStrictly(identifier: ModuleVersionIdentifier): Boolean
setChanging
Link copied to clipboard
abstract fun setChanging(changing: Boolean): ExternalModuleDependency
setTargetConfiguration
Link copied to clipboard
abstract fun setTargetConfiguration(name: String)
setTransitive
Link copied to clipboard
abstract fun setTransitive(transitive: Boolean): ModuleDependency
version
Link copied to clipboard
abstract fun version(configureAction: Action<out Any>)