|
Groovy Documentation | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | METHOD | DETAIL: FIELD | METHOD |
interface Gradle
A Gradle represents an invocation of Gradle.
You can obtain a Gradle instance by calling Project#getGradle(). In your build file you can use gradle to access it.
Method Summary | |
---|---|
void
|
addBuildListener(BuildListener buildListener)
Adds a { |
void
|
addListener(java.lang.Object listener)
Adds the given listener to this build. |
ProjectEvaluationListener
|
addProjectEvaluationListener(ProjectEvaluationListener listener)
Adds a listener to this build, to receive notifications as projects are evaluated. |
void
|
afterProject(Closure closure)
Adds a closure to be called immediately after a project is evaluated. |
void
|
beforeProject(Closure closure)
Adds a closure to be called immediately before a project is evaluated. |
void
|
captureStandardOutput(LogLevel level)
Starts redirection of standard output during to the logging system during init script evaluation. |
void
|
disableStandardOutputCapture()
Disables redirection of standard output during init script evaluation. |
Gradle
|
getGradle()
Returns this { |
File
|
getGradleHomeDir()
Returns the Gradle home directory. |
File
|
getGradleUserHomeDir()
Returns the Gradle user home directory. |
java.lang.String
|
getGradleVersion()
Returns the current Gradle version. |
ScriptHandler
|
getInitscript()
Returns the init script handler for this build. |
InternalRepository
|
getInternalRepository()
Returns the repository used to pass artifacts between projects in this build. |
Logger
|
getLogger()
Returns the logger for this build. |
Project
|
getRootProject()
Returns the root project of this build. |
StartParameter
|
getStartParameter()
Returns the { |
TaskExecutionGraph
|
getTaskGraph()
Returns the { |
void
|
initscript(Closure configureClosure)
Configures the init script classpath for this build. |
void
|
removeListener(java.lang.Object listener)
Removes the given listener from this build. |
void
|
removeProjectEvaluationListener(ProjectEvaluationListener listener)
Removes the given listener from this build. |
Method Detail |
---|
public void addBuildListener(BuildListener buildListener)
Adds a BuildListener to this Build instance. The listener is notified of events which occur during the execution of the build.
public void addListener(java.lang.Object listener)
public ProjectEvaluationListener addProjectEvaluationListener(ProjectEvaluationListener listener)
public void afterProject(Closure closure)
public void beforeProject(Closure closure)
public void captureStandardOutput(LogLevel level)
public void disableStandardOutputCapture()
public Gradle getGradle()
public File getGradleHomeDir()
Returns the Gradle home directory. This directory is used to locate resources such as the default imports file.
public File getGradleUserHomeDir()
Returns the Gradle user home directory. This directory is used to cache downloaded resources.
public java.lang.String getGradleVersion()
Returns the current Gradle version.
public ScriptHandler getInitscript()
public InternalRepository getInternalRepository()
public Logger getLogger()
public Project getRootProject()
Returns the root project of this build.
public StartParameter getStartParameter()
public TaskExecutionGraph getTaskGraph()
Returns the TaskExecutionGraph for this build.
public void initscript(Closure configureClosure)
public void removeListener(java.lang.Object listener)
public void removeProjectEvaluationListener(ProjectEvaluationListener listener)
Groovy Documentation