public class JkRun
extends java.lang.Object
Modifier | Constructor and Description |
---|---|
protected |
JkRun()
Constructs a
JkRun . |
Modifier and Type | Method and Description |
---|---|
void |
clean()
Cleans the output directory.
|
java.nio.file.Path |
getBaseDir()
Returns the base directory for this project.
|
JkPathTree |
getBaseTree()
Returns the base directory tree for this project.
|
JkImportedRuns |
getImportedRuns()
Returns imported runs with plugins applied on.
|
java.nio.file.Path |
getOutputDir()
Returns the output directory where all the final and intermediate artifacts are generated.
|
<T extends JkPlugin> |
getPlugin(java.lang.Class<T> pluginClass)
Shorthand to
getPlugins().get( . |
JkRunPlugins |
getPlugins()
Returns the container of loaded plugins for this instance.
|
JkDependencySet |
getRunDependencies()
Dependencies necessary to compile the this run class.
|
JkDependencyResolver |
getRunDependencyResolver()
Returns the dependency resolver used to compile/run scripts of this project.
|
void |
help()
Displays all available methods defined in this run.
|
static <T extends JkRun> |
of(java.lang.Class<T> runClass)
Creates a instance of the specified run class (extending JkRun), including option injection, plugin loading
and plugin activation.
|
protected void |
setup()
This method is invoked right after options has been injected into this instance.
|
protected void |
setupAfterPluginActivations()
This method is called once all plugin has been activated.
|
java.lang.String |
toString() |
public static <T extends JkRun> T of(java.lang.Class<T> runClass)
protected void setup()
protected void setupAfterPluginActivations()
public final JkPathTree getBaseTree()
JkPathTree.of(baseDir)
.public final java.nio.file.Path getBaseDir()
public java.nio.file.Path getOutputDir()
public JkRunPlugins getPlugins()
public <T extends JkPlugin> T getPlugin(java.lang.Class<T> pluginClass)
getPlugins().get()
.
Returns the plugin instance of the specified class loaded in the holding JkRun instance. If it does not hold
a plugin of the specified class at call time, the plugin is loaded then returned.public final JkDependencyResolver getRunDependencyResolver()
public final JkDependencySet getRunDependencies()
public final JkImportedRuns getImportedRuns()
public void clean()
public void help()
public java.lang.String toString()
toString
in class java.lang.Object