java.lang.Object
org.apache.maven.plugin.AbstractMojo
gg.jte.maven.GeneratorMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="generate",
defaultPhase=GENERATE_SOURCES,
threadSafe=true)
public class GeneratorMojo
extends org.apache.maven.plugin.AbstractMojo
-
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanSetting, that UTF-8 encodes all static template parts at compile time.The content type of all templates.Optional - Extensions this template engine should load.booleanBy default, jte omits all HTML/CSS/JS comments, when compiling withContentType.Html.String[]Intercepts the given html tags during template compilation and calls the configured htmlInterceptor during template rendering.The package name, where template classes are generated to.org.apache.maven.project.MavenProjectThe directory where template files are located.Destination directory to store generated templates.Directory in which to generate non-java files (resources).booleanTrims control structures, resulting in prettier output.Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
project
@Parameter(defaultValue="${project}") public org.apache.maven.project.MavenProject project -
sourceDirectory
The directory where template files are located. -
targetDirectory
@Parameter(defaultValue="${project.build.directory}/generated-sources/jte") public String targetDirectoryDestination directory to store generated templates. Defaults to 'target/generated-sources/jte'. -
contentType
The content type of all templates. Either Plain or Html. -
trimControlStructures
@Parameter public boolean trimControlStructuresTrims control structures, resulting in prettier output. -
htmlTags
Intercepts the given html tags during template compilation and calls the configured htmlInterceptor during template rendering. -
htmlCommentsPreserved
@Parameter public boolean htmlCommentsPreservedBy default, jte omits all HTML/CSS/JS comments, when compiling withContentType.Html. If you don't want this behavior, you can disable it here. -
binaryStaticContent
@Parameter public boolean binaryStaticContentSetting, that UTF-8 encodes all static template parts at compile time. Only makes sense if you use a binary output, likeUtf8ByteOutput. -
packageName
The package name, where template classes are generated to. -
targetResourceDirectory
Directory in which to generate non-java files (resources). Typically, set by plugin rather than end user. Optional - if null, resources will not be generated -
extensions
Optional - Extensions this template engine should load. Currently, the following extensions exist:- gg.jte.models.generator.ModelExtension
- gg.jte.nativeimage.NativeResourcesExtension
-
-
Constructor Details
-
GeneratorMojo
public GeneratorMojo()
-
-
Method Details
-
execute
public void execute()
-