Task Container
Functions
Link copied to clipboard
Adds any of the given objects to the collection that do not have the same name as any existing element.
Link copied to clipboard
Link copied to clipboard
Executes the given closure against all objects in this collection, and any objects subsequently added to this collection.
Executes the given action against all objects in this collection, and any objects subsequently added to this collection.
Link copied to clipboard
Configures each element in this collection using the given action, as each element is required.
Link copied to clipboard
Creates a regular container that wraps the polymorphic container presenting all elements of a specified type.
Link copied to clipboard
Link copied to clipboard
Creates a Task with the given name and adds it to this container.
Creates a Task and adds it to this container.
Creates a Task with the given name adds it to this container.
Creates a Task with the given name and type, and adds it to this container.
Creates a Task with the given name and of type org.gradle.api.DefaultTask, configures it with the given action, and adds it to this container.
Creates a Task adds it to this container.
Creates a Task with the given name and type, passing the given arguments to the
@Inject-annotated constructor, and adds it to this container.Creates a Task with the given name and type, configures it with the given action, and adds it to this container.
Link copied to clipboard
Disallows further structural modifications to this collection.
Link copied to clipboard
Locates an object by name, returning null if there is no such object.
Link copied to clipboard
Locates a task by path.
Link copied to clipboard
Provides access to the schema of all created or registered named domain objects in this collection.
Link copied to clipboard
Returns a collection which contains the objects in this collection which meet the given closure specification.
Returns a collection which contains the objects in this collection which meet the given specification.
Link copied to clipboard
Looks for an item with the given name, creating and adding it to this container if it does not exist.
Looks for an item with the given name and type, creating and adding it to this container if it does not exist.
Link copied to clipboard
Locates a object by name, failing if there is no such object.
Returns a collection containing the objects with names matching the provided filter.
abstract fun <S : T?> named(name: String, type: Class<S>, configurationAction: Action<in S>): NamedDomainObjectProvider<S>
abstract fun <S : T?> named(name: String, type: Class<S>, configurationAction: Action<in S>): TaskProvider<S>
Locates a object by name and type, failing if there is no such object.
Locates a task by name, without triggering its creation or configuration, failing if there is no such object.
Link copied to clipboard
Link copied to clipboard
Defines a new task, which will be created when it is required.
abstract fun <T : Task?> register(name: String, type: Class<T>, configurationAction: Action<in T>): TaskProvider<T>
Defines a new task, which will be created and configured when it is required.
abstract fun <T : Task?> register(name: String, type: Class<T>, constructorArgs: Array<Any>): TaskProvider<T>
Defines a new task, which will be created when it is required passing the given arguments to the
@Inject-annotated constructor.Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Adds a closure to be called when an object is added to this collection.
Adds an
Action to be executed when an object is added to this collection.Link copied to clipboard
Adds a closure to be called when an object is removed from this collection.
Adds an
Action to be executed when an object is removed from this collection.Link copied to clipboard
Adds a closure to be called when a task is added to this collection.
Adds an
Action to be executed when a task is added to this collection.Link copied to clipboard
abstract fun <S : T?> withType(type: Class<S>, @DelegatesTo(genericTypeIndex = 0 ) configureClosure: Closure): DomainObjectCollection<S>
abstract fun <S : T?> withType(type: Class<S>, configureAction: Action<in S>): DomainObjectCollection<S>
Returns a collection containing the objects in this collection of the given type.