# TaskProvider

interface TaskProvider<T : Task?> : NamedDomainObjectProvider<T> (source)

Providers a task of the given type.

#### Since

4.8

#### Parameters

<T>

Task type

## Functions

configure
Link copied to clipboard
abstract fun configure(action: Action<in T>)
Configures the task with the given action.
filter
Link copied to clipboard
abstract fun filter(spec: Spec<in T>): Provider<T>
flatMap
Link copied to clipboard
abstract fun <S> flatMap(transformer: Transformer<out @Nullable Provider<out S>, in T>): Provider<S>
get
Link copied to clipboard
abstract fun get(): T
getName
Link copied to clipboard
abstract fun getName(): String
The task name referenced by this provider.
getOrElse
Link copied to clipboard
abstract fun getOrElse(defaultValue: T): T
getOrNull
Link copied to clipboard
abstract fun getOrNull(): @Nullable T
getValue
Link copied to clipboard
inline operator fun <T : Any, U : T> NamedDomainObjectProvider<out T>.getValue(thisRef: Any?, property: KProperty<*>): U

Allows a NamedDomainObjectProvider to be used as a property delegate.

invoke
Link copied to clipboard
operator fun <T : Any> NamedDomainObjectProvider<T>.invoke(action: T.() -> Unit)

Allows a NamedDomainObjectProvider to be configured via invocation syntax.

isPresent
Link copied to clipboard
abstract fun isPresent(): Boolean
map
Link copied to clipboard
abstract fun <S> map(transformer: Transformer<out @Nullable S, in T>): Provider<S>
orElse
Link copied to clipboard
abstract fun orElse(value: T): Provider<T>
zip
Link copied to clipboard
abstract fun <U, R> zip(right: Provider<U>, combiner: BiFunction<in T, in U, out @Nullable R>): Provider<R>