TaskOutputs

interface TaskOutputs(source)

A TaskOutputs represents the outputs of a task.

You can obtain a TaskOutputs instance using getOutputs.

Functions

Link copied to clipboard
abstract fun cacheIf(spec: Spec<in Task>)
abstract fun cacheIf(cachingEnabledReason: String, spec: Spec<in Task>)
Cache the results of the task only if the given spec is satisfied.
Link copied to clipboard
Registers an output directory for this task.
Link copied to clipboard
Registers some output directories for this task.
Link copied to clipboard
abstract fun doNotCacheIf(cachingDisabledReason: String, spec: Spec<in Task>)
Disable caching the results of the task if the given spec is satisfied.
Link copied to clipboard
Registers some output file for this task.
Link copied to clipboard
Registers some output files for this task.
Link copied to clipboard
abstract fun getFiles(): FileCollection
Returns the output files of this task.
Link copied to clipboard
abstract fun getHasOutput(): Boolean
Returns true if this task has declared any outputs.
Link copied to clipboard
abstract fun upToDateWhen(upToDateClosure: Closure)
abstract fun upToDateWhen(upToDateSpec: Spec<in Task>)
Adds a predicate to determine whether previous outputs of this task can be reused.