api / org.gradle.api.plugins / ExtensionContainer / configure

configure

@Incubating abstract fun <T : Any> configure(type: Class<T>, action: Action<in T>): Unit

Looks for the extension of the specified type and configures it with the supplied action.

Parameters

type - extension type

action - the configure action

Exceptions

UnknownDomainObjectException - if no extension is found.

@Incubating abstract fun <T : Any> configure(type: TypeOf<T>, action: Action<in T>): Unit

Looks for the extension of the specified type and configures it with the supplied action.

Parameters

type - extension type

action - the configure action

Exceptions

UnknownDomainObjectException - if no extension is found.

Since
3.5

@Incubating abstract fun <T : Any> configure(name: String, action: Action<in T>): Unit

Looks for the extension with the specified name and configures it with the supplied action.

Parameters

name - extension name

action - the configure action

Exceptions

UnknownDomainObjectException - if no extension is found.

Since
4.0