interface Action<T : Any>
Performs some action against objects of type T. |
|
interface ActionConfiguration
Allows specification of configuration for some action. The configuration is represented using zero or more initialization parameters to use when constructing an instance of the implementation class. The following types are supported:
|
|
abstract class AntBuilder : AntBuilder
An |
|
interface Buildable
A |
|
interface BuildableComponentSpec : Buildable, ComponentSpec
A ComponentSpec that is directly Buildable via a specified task. |
|
interface CheckableComponentSpec : ComponentSpec
A ComponentSpec that is directly checkable via a specified task. |
|
open class DefaultTask : AbstractTask
|
|
interface Describable
Types can implement this interface when they provide a human-readable display name. It is strongly encouraged to compute this display name lazily: computing a display name, even if it's only a string concatenation, can take a significant amount of time during configuration for something that would only be used, typically, in error messages. |
|
interface DomainObjectCollection<T : Any> : MutableCollection<T>
A The filtered collections returned by the filtering methods, such as You can also add actions which are executed as elements are added to the collection. Actions added to filtered collections will be fired if an addition/removal occurs for the source collection that matches the filter. |
|
interface DomainObjectSet<T : Any> : DomainObjectCollection<T>, MutableSet<T>
A |
|
interface ExtensiblePolymorphicDomainObjectContainer<T : Any> : PolymorphicDomainObjectContainer<T>, NamedDomainObjectFactoryRegistry
A org.gradle.api.PolymorphicDomainObjectContainer that can be extended at runtime to create elements of new types. |
|
class JavaVersion
An enumeration of Java versions. Before 9: http://www.oracle.com/technetwork/java/javase/versioning-naming-139433.html 9+: http://openjdk.java.net/jeps/223 |
|
interface Named
Types can implement this interface and use the embedded Namer implementation, to satisfy API that calls for a namer. |
|
interface NamedDomainObjectCollection<T : Any> : DomainObjectCollection<T>
A Objects to be added to a named domain object collection must implement All implementations must guarantee that all elements in the collection are uniquely named. That is, an attempt to add an object with a name equal to the name of any existing object in the collection will fail. Implementations may choose to simply return false from Objects in the collection are accessible as read-only properties, using the name of the object as the property name. For example (assuming the 'name' property provides the object name):
A dynamic method is added for each object which takes a configuration closure. This is equivalent to calling
You can also use the
Rule objects can be attached to the collection in order to respond to requests for objects by name where no object with name exists in the collection. This mechanism can be used to create objects on demand. For example:
|
|
interface NamedDomainObjectContainer<T : Any> : NamedDomainObjectSet<T>, Configurable
A named domain object container is a specialisation of NamedDomainObjectSet that adds the ability to create instances of the element type. Implementations may use different strategies for creating new object instances. Note that a container is an implementation of java.util.SortedSet, which means that the container is guaranteed to only contain elements with unique names within this container. Furthermore, items are ordered by their name. |
|
interface NamedDomainObjectFactory<T : Any>
A factory for named objects of type |
|
interface NamedDomainObjectList<T : Any> : NamedDomainObjectCollection<T>, MutableList<T>
A specialisation of org.gradle.api.NamedDomainObjectCollection that also implements java.util.List. All object equality is determined in terms of object names. That is, calling |
|
interface NamedDomainObjectSet<T : Any> : NamedDomainObjectCollection<T>, MutableSet<T>
A specialisation of NamedDomainObjectCollection that also implements Set and orders objects by their inherent name. All object equality is determined in terms of object names. That is, calling |
|
interface Namer<T : Any>
A namer is capable of providing a name based on some inherent characteristic of an object. |
|
class PathValidation
An enumeration for describing validation policies for file paths. |
|
interface Plugin<T : Any>
A |
|
interface PolymorphicDomainObjectContainer<T : Any> : NamedDomainObjectContainer<T>
A NamedDomainObjectContainer that allows to create domain objects with different types. |
|
interface Project : Comparable<Project>, ExtensionAware, PluginAware
This interface is the main API you use to interact with Gradle from your build file. From a There is a one-to-one relationship between a
A project is essentially a collection of Task objects. Each task performs some basic piece of work, such as compiling classes, or running unit tests, or zipping up a WAR file. You add tasks to a project using one of the A project generally has a number of dependencies it needs in order to do its work. Also, a project generally produces a number of artifacts, which other projects can use. Those dependencies are grouped in configurations, and can be retrieved and uploaded from repositories. You use the org.gradle.api.artifacts.ConfigurationContainer returned by Projects are arranged into a hierarchy of projects. A project has a name, and a fully qualified path which uniquely identifies it in the hierarchy. Plugins Plugins can be used to modularise and reuse project configuration. Plugins can be applied using the Gradle executes the project's build file against the For example:
You can also access the A project has 5 property 'scopes', which it searches for properties. You can access these properties by name in your build file, or by calling the project's
When reading a property, the project searches the above scopes in order, and returns the value from the first scope it finds the property in. If not found, an exception is thrown. See When writing a property, the project searches the above scopes in order, and sets the property in the first scope it finds the property in. If not found, an exception is thrown. See Reading extra properties is done through the "ext" or through the owning object. Dynamic Methods
A project has 5 method 'scopes', which it searches for methods:
|
|
interface ProjectEvaluationListener
An |
|
interface ProjectState
|
|
interface Rule
A |
|
interface Script
This interface is implemented by all Gradle scripts to add in some Gradle-specific methods. As your compiled script class will implement this interface, you can use the methods and properties declared by this interface directly in your script. Generally, a |
|
interface Task : Comparable<Task>, ExtensionAware
A Each task belongs to a Project. You can use the various methods on to create and lookup task instances. For example,
Each task has a name, which can be used to refer to the task within its owning project, and a fully qualified path, which is unique across all tasks in all projects. The path is the concatenation of the owning project's path and the task's name. Path elements are separated using the {@value org.gradle.api.Project#PATH_SEPARATOR} character. Task ActionsA Groovy closures can also be used to provide a task action. When the action is executed, the closure is called with the task as parameter. You can add action closures to a task by calling There are 2 special exceptions which a task action can throw to abort execution and continue without failing the build. A task action can abort execution of the action and continue to the next action of the task by throwing a org.gradle.api.tasks.StopActionException. A task action can abort execution of the task and continue to the next task by throwing a org.gradle.api.tasks.StopExecutionException. Using these exceptions allows you to have precondition actions which skip execution of the task, or part of the task, if not true. Task Dependencies and Task OrderingA task may have dependencies on other tasks or might be scheduled to always run after another task. Gradle ensures that all task dependencies and ordering rules are honored when executing tasks, so that the task is executed after all of its dependencies and any "must run after" tasks have been executed. Dependencies to a task are controlled using
A
A Plugin may add methods to a By default, tasks are not executed in parallel unless a task is waiting on asynchronous work and another task (which is not dependent) is ready to execute. Parallel execution can be enabled by the |
|
interface Transformer<OUT : Any, IN : Any>
A Implementations are free to return new objects or mutate the incoming value. |
|
interface XmlProvider
Provides various ways to access the content of an XML document. |
class HasImplicitReceiver
Marks a SAM interface as a target for lambda expressions / closures where the single parameter is passed as the implicit receiver of the invocation (
|
|
class Incubating
Indicates that a feature is incubating. This means that the feature is currently a work-in-progress and may change at any time. |
|
class NonExtensible
Indicates that the type, when DSL enhanced, does not support extensibility. This means that it will not be enhanced with org.gradle.api.plugins.ExtensionAware. |
|
class NonNullApi
Marks a type or a whole package as providing a non-null API by default. All parameter and return types are assumed to be Nonnull unless specifically marked as Nullable. |
|
class Nullable
Indicates that the value of an element can be null. |
open class BuildCancelledException : GradleException
A |
|
open class CircularReferenceException : GradleException
A |
|
open class GradleException : RuntimeException
|
|
open class GradleScriptException : GradleException
A |
|
open class IllegalDependencyNotation : GradleException
This exceptions is thrown, if a dependency is declared with a illegal notation. |
|
open class InvalidActionClosureException : GradleException
Thrown when a Closure is given as an Action implementation, but has the wrong signature. |
|
open class InvalidUserCodeException : GradleException
A |
|
open class InvalidUserDataException : GradleException
A |
|
open class ProjectConfigurationException : GradleException
Indicates a problem that occurs during project configuration (evaluation) phase. |
|
open class UncheckedIOException : RuntimeException
|
|
open class UnknownDomainObjectException : GradleException
A |
|
open class UnknownProjectException : UnknownDomainObjectException
An |
|
open class UnknownTaskException : UnknownDomainObjectException
An |