Package com.webguys.maven.plugin.st
Class Template
java.lang.Object
com.webguys.maven.plugin.st.Template
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ControllerThe class to invoke to provide data for the template.private FileThe path to the template file's parent directory.private StringThe name of the template file to render.The static properties to be provided to the template.private FileThe path to the output file. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()voidinstallProperties(org.stringtemplate.v4.ST st) voidinvokeController(org.stringtemplate.v4.ST st, org.twdata.maven.mojoexecutor.MojoExecutor.ExecutionEnvironment executionEnvironment, org.apache.maven.ProjectDependenciesResolver dependenciesResolver, org.apache.maven.plugin.logging.Log log) private voidprepareCompilerSourceRoot(File file, org.apache.maven.project.MavenProject project, org.apache.maven.plugin.logging.Log log) private FileprepareOutputFile(File baseDirectory) voidrender(org.stringtemplate.v4.ST st, org.apache.maven.project.MavenProject project, org.apache.maven.plugin.logging.Log log)
-
Field Details
-
directory
The path to the template file's parent directory. -
name
The name of the template file to render. -
target
The path to the output file. -
controller
The class to invoke to provide data for the template. -
properties
The static properties to be provided to the template.
-
-
Constructor Details
-
Template
public Template()
-
-
Method Details
-
getDirectory
-
getName
-
invokeController
public void invokeController(org.stringtemplate.v4.ST st, org.twdata.maven.mojoexecutor.MojoExecutor.ExecutionEnvironment executionEnvironment, org.apache.maven.ProjectDependenciesResolver dependenciesResolver, org.apache.maven.plugin.logging.Log log) throws org.apache.maven.plugin.MojoExecutionException - Throws:
org.apache.maven.plugin.MojoExecutionException
-
installProperties
public void installProperties(org.stringtemplate.v4.ST st) -
render
public void render(org.stringtemplate.v4.ST st, org.apache.maven.project.MavenProject project, org.apache.maven.plugin.logging.Log log) throws org.apache.maven.plugin.MojoExecutionException - Throws:
org.apache.maven.plugin.MojoExecutionException
-
prepareOutputFile
private File prepareOutputFile(File baseDirectory) throws org.apache.maven.plugin.MojoExecutionException, IOException - Throws:
org.apache.maven.plugin.MojoExecutionExceptionIOException
-
prepareCompilerSourceRoot
private void prepareCompilerSourceRoot(File file, org.apache.maven.project.MavenProject project, org.apache.maven.plugin.logging.Log log)
-