java.lang.Object
org.apache.maven.plugin.AbstractMojo
gg.jte.maven.CompilerMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="precompile",
defaultPhase=PROCESS_CLASSES,
requiresDependencyResolution=COMPILE,
threadSafe=true)
public class CompilerMojo
extends org.apache.maven.plugin.AbstractMojo
-
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanSetting, that UTF-8 encodes all static template parts at compile time.String[]Sets additional compiler arguments for jte templates.The compile-classpath to use.The content type of all templates.booleanBy default, jte omits all HTML/CSS/JS comments, when compiling withContentType.Html.Policy class that checks the parsed HTML at compile time.String[]Intercepts the given html tags during template compilation and calls the configured htmlInterceptor during template rendering.booleanBy default, this plugin deletes all generated jte source files after compilation.The package name, where template classes are generated to.The directory where template files are locatedThe directory where compiled classes should be written tobooleanTrims 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
-
sourceDirectory
The directory where template files are located -
targetDirectory
The directory where compiled classes should be written to -
compilePath
@Parameter(defaultValue="${project.compileClasspathElements}", required=true) public List<String> compilePathThe compile-classpath to use. Defaults to project.compileClasspathElements -
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. -
htmlPolicyClass
Policy class that checks the parsed HTML at compile time. Must be an instance ofHtmlPolicy -
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. -
compileArgs
Sets additional compiler arguments for jte templates. -
packageName
The package name, where template classes are generated to. -
keepGeneratedSourceFiles
@Parameter public boolean keepGeneratedSourceFilesBy default, this plugin deletes all generated jte source files after compilation. If you want to keep them, set this property to true.
-
-
Constructor Details
-
CompilerMojo
public CompilerMojo()
-
-
Method Details
-
execute
public void execute()
-