property

@Nullable
abstract fun property(propertyName: String): Any(source)

Returns the value of the given property of this task. This method locates a property as follows:

  1. If this task object has a property with the given name, return the value of the property.
  2. If this task has an extension with the given name, return the extension.
  3. If this task's convention object has a property with the given name, return the value of the property.
  4. If this task has an extra property with the given name, return the value of the property.
  5. If not found, throw MissingPropertyException

Return

The value of the property, possibly null.

Parameters

propertyName

The name of the property.

Throws

MissingPropertyException

When the given property is unknown.