Package com.webguys.maven.plugin.st
Class Template
java.lang.Object
com.webguys.maven.plugin.st.Template
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Controller
The class to invoke to provide data for the template.private File
The path to the template file's parent directory.private String
The name of the template file to render.The static properties to be provided to the template.private File
The path to the output file. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()
void
installProperties
(org.stringtemplate.v4.ST st) 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) private void
prepareCompilerSourceRoot
(File file, org.apache.maven.project.MavenProject project, org.apache.maven.plugin.logging.Log log) private File
prepareOutputFile
(File baseDirectory) void
render
(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.MojoExecutionException
IOException
-
prepareCompilerSourceRoot
private void prepareCompilerSourceRoot(File file, org.apache.maven.project.MavenProject project, org.apache.maven.plugin.logging.Log log)
-