api / org.gradle.api.tasks / Destroys

Destroys

@Target([AnnotationTarget.FUNCTION, AnnotationTarget.PROPERTY_GETTER, AnnotationTarget.PROPERTY_SETTER, AnnotationTarget.FIELD]) class Destroys

Marks a property as specifying a file or directory that a task destroys.

This annotation should be attached to the getter method or the field for the property.

This will cause the task to have exclusive access to this file or directory while running. This means that other tasks that either create or consume this file (by specifying the file or directory as an input or output) cannot execute concurrently with a task that destroys this file.

Since
4.0

Constructors

<init>

Destroys()

Marks a property as specifying a file or directory that a task destroys.

This annotation should be attached to the getter method or the field for the property.

This will cause the task to have exclusive access to this file or directory while running. This means that other tasks that either create or consume this file (by specifying the file or directory as an input or output) cannot execute concurrently with a task that destroys this file.