registering

Deprecated

Use 'val element = register(name) { }' instead. See the Gradle 9.6 upgrading guide.

Property delegate for registering new elements in the container.

tasks {
val rebuild by registering {
dependsOn("clean", "build")
}
}

Parameters

action

the configuration action

Type Parameters

T

the domain object type

C

the concrete container type


Deprecated

Use 'val element = register<Type>(name)' instead. See the Gradle 9.6 upgrading guide.

Property delegate for registering new elements in the container.

tasks { val jar by registering(Jar::class) }

Parameters

type

the domain object type

Type Parameters

T

the domain object type

C

the concrete container type


Deprecated

Use 'val element = register<Type>(name) { }' instead. See the Gradle 9.6 upgrading guide.

Property delegate for registering new elements in the container.

tasks { val jar by registering(Jar::class) { } }

Parameters

type

the domain object type

action

the configuration action

Type Parameters

T

the container element type

C

the container type

U

the desired domain object type


Deprecated

Use 'val element = register(name)' instead. See the Gradle 9.6 upgrading guide.

Property delegate for registering new elements in the container.

tasks { val rebuild by registering }

Type Parameters

T

the domain object type

C

the concrete container type