public interface ExecTools
Various tools to deal with non-JVM, out-of-process executables.
| Type Params | Return Type | Name and description |
|---|---|---|
|
public AppRunnerSpec |
appRunnerSpec()Creates a AppRunnerSpec. |
|
public CommandEntryPoint |
commandEntryPoint()Returns an implementation that is optimised for the running version of Gradle. |
|
public Downloader |
downloader(String distributionName)Creates a new downloader for downloading packages / distributions. |
|
public ExecOutput |
exec(Action<? super ExecSpec> action)Executes the specified external process. |
|
public ExecSpec |
execSpec()Returns something that looks like an ExecSpec. |
|
public ExecOutput |
javaexec(Action<? super JavaExecSpec> action)Executes the specified external java process. |
|
public String |
parseVersionFromOutput(Iterable<String> argsForVersion, File executablePath, java.util.function.Function<String, String> versionParser)Simplifies running an executable to obtain a version. |
|
public String |
parseVersionFromOutput(Iterable<String> argsForVersion, File executablePath, java.util.function.Function<String, String> versionParser, Action<ExecSpec> configurator)Simplifies running an executable to obtain a version. |
Creates a AppRunnerSpec. This is primarily used internally by classes that implements execution specifications for non-JVM processes.
Returns an implementation that is optimised for the running version of Gradle.
nullCreates a new downloader for downloading packages / distributions.
distributionName - Name of distribution to be downloaded.Executes the specified external process.
action - Configures an ExecSpecReturns something that looks like an ExecSpec.
Executes the specified external java process.
action - Configures a JavaExecSpec Simplifies running an executable to obtain a version.
This is primarily used to implement a runExecutableAndReturnVersion method.
argsForVersion - Arguments required to obtain a versionexecutablePath - Location of the executableversionParser - A parser for the output of running the executable which could extract the version. Simplifies running an executable to obtain a version.
This is primarily used to implement a runExecutableAndReturnVersion method.
argsForVersion - Arguments required to obtain a versionexecutablePath - Location of the executableversionParser - A parser for the output of running the executable which could extract the version.configurator - Additional configurator to customise the execution specification.