TaskOutputFilePropertyBuilder (Gradle API 8.12)
Description: declaration: package: org.gradle.api.tasks, interface: TaskOutputFilePropertyBuilder

Package org.gradle.api.tasks

# Interface TaskOutputFilePropertyBuilder

All Superinterfaces:
  `TaskFilePropertyBuilder`, `TaskPropertyBuilder`

public interface TaskOutputFilePropertyBuilder extends TaskFilePropertyBuilder
Describes an output property of a task that contains zero or more files.

Since:
  3.0

- ## Method Summary

  Modifier and Type
  Method
  Description
  `TaskOutputFilePropertyBuilder`
  `optional()`
  Marks a task property as optional.
  `TaskOutputFilePropertyBuilder`
  `optional(boolean optional)`
  Sets whether the task property is optional.
  `TaskOutputFilePropertyBuilder`
  `withPropertyName(String propertyName)`
  Sets the name for this property.

- ## Method Details

  - ### withPropertyName

    TaskOutputFilePropertyBuilder withPropertyName(String propertyName)
    Sets the name for this property. The name must be a non-empty string.

    If the method is not called, or if it is called with `null`, a name will be assigned to the property automatically.

    Specified by:
      `withPropertyName` in interface `TaskFilePropertyBuilder`

  - ### optional

    TaskOutputFilePropertyBuilder optional()
    Marks a task property as optional. This means that a value does not have to be specified for the property, but any value specified must meet the validation constraints for the property.

  - ### optional

    TaskOutputFilePropertyBuilder optional(boolean optional)
    Sets whether the task property is optional. If the task property is optional, it means that a value does not have to be specified for the property, but any value specified must meet the validation constraints for the property.