# registering

fun <T : Any, C : ERROR CLASS: Symbol not found for NamedDomainObjectContainer<T>> C.registering(action: T.() -> Unit): RegisteringDomainObjectDelegateProviderWithAction<out C, T>(source)

### 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")
       }
    }

Content copied to clipboard

#### Parameters

action

the configuration action

#### Type Parameters

T

the domain object type

C

the concrete container type

fun <T : Any, C : ERROR CLASS: Symbol not found for PolymorphicDomainObjectContainer<T>, U : T> C.registering(type: KClass<U>): RegisteringDomainObjectDelegateProviderWithType<out C, U>(source)

### 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

fun <T : Any, C : ERROR CLASS: Symbol not found for PolymorphicDomainObjectContainer<T>, U : T> C.registering(type: KClass<U>, action: U.() -> Unit): RegisteringDomainObjectDelegateProviderWithTypeAndAction<out C, U>(source)

### 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

val <T : Any, C : ERROR CLASS: Symbol not found for NamedDomainObjectContainer<T>> C.registering: RegisteringDomainObjectDelegateProvider<out C>(source)

### 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