api / org.gradle.api.artifacts / ResolvedConfiguration

ResolvedConfiguration

interface ResolvedConfiguration

A ResolvedConfiguration represents the result of resolving a Configuration, and provides access to both the artifacts and the meta-data of the result.

Functions

getFiles

abstract fun getFiles(): MutableSet<File>

Returns the files for the configuration dependencies.

abstract fun getFiles(dependencySpec: Spec<in Dependency>): MutableSet<File>

Returns the files for the specified subset of configuration dependencies.

getFirstLevelModuleDependencies

abstract fun getFirstLevelModuleDependencies(): MutableSet<ResolvedDependency>

Returns the ResolvedDependency instances for each direct dependency of the configuration. Via those you have access to all ResolvedDependency instances, including the transitive dependencies of the configuration.

abstract fun getFirstLevelModuleDependencies(dependencySpec: Spec<in Dependency>): MutableSet<ResolvedDependency>

Returns the ResolvedDependency instances for each direct dependency of the configuration that matches the given spec. Via those you have access to all ResolvedDependency instances, including the transitive dependencies of the configuration.

getLenientConfiguration

abstract fun getLenientConfiguration(): LenientConfiguration

Provides configuration that does not fail eagerly when some dependencies are not resolved.

getResolvedArtifacts

abstract fun getResolvedArtifacts(): MutableSet<ResolvedArtifact>

Returns the set of artifact meta-data for this configuration.

hasError

abstract fun hasError(): Boolean

Returns whether all dependencies were successfully retrieved or not.

rethrowFailure

abstract fun rethrowFailure(): Unit

A resolve of a configuration that is not successful does not automatically throws an exception. Such a exception is only thrown if the result of a resolve is accessed. You can force the throwing of such an exception by calling this method.

This method does nothing when resolution was successful.