Full name:
org.codehaus.modello:modello-maven-plugin:2.5.1:velocity
Description:
Creates files from the model using Velocity templates.
This mojo can be given a list of templates and a list of parameters. Each template from the templates
property will be run with the following context:
version
: the version of the model to generatemodel
: the modello modelHelper
: a org.codehaus.modello.plugin.velocity.Helper
object instanceparams
property#MODELLO-VELOCITY#SAVE-OUTPUT-TO
VTL directive. This allows a single template to generate multiple files. For example, the following directive will redirect further output from the template to a file named org/apache/maven/api/model/Plugin.java
if the variable package
is set to org.apache.maven.api.model
and the variable className
is set to Plugin
.
#MODELLO-VELOCITY#SAVE-OUTPUT-TO ${package.replace('.','/')
/${className}.java}
Attributes:
generate-sources
.<basedir>
String
-
Base directory of the project, from where the Modello models are loaded.
${basedir}
<models>
String[]
-
List of relative paths to mdo files containing the models. <packageWithVersion>
boolean
-
True if the generated package names should include the version.
false
packageWithVersion
<version>
String
-
The version of the model we will be working on.
version
Optional Parameters Name Type Since Description <licenseFile>
File
2.3.1
The file that contains license header text. If both configured, the licenseText
prevails. <licenseText>
String
2.3.1
The contents of license header text, verbatim. <outputDirectory>
File
-
The output directory of the generated files.
${project.build.directory}/generated-sources/modello
<packagedVersions>
List<String>
-
Additional historical versions to generate, each being packaged with the version regardless of the packageWithVersion
setting. <params>
List<String>
-
A list of parameters, using the syntax key=value
. Those parameters will be made accessible to the templates. <pluralExceptions>
Map<String,String>
2.5.0
Additional exceptions to the singularization rules, changing plural noun to singular.
As a key we provide plural noun and as value we provide singular noun, example:
<kisses>kiss</kisses>
<templates>
List<String>
-
A list of template paths to be run against the loaded Modello model. Those are .vm
files as described in the Velocity Users Guide relative to velocityBasedir
. <velocityBasedir>
File
-
The directory where Velocity templates are looked for.
${project.basedir}
Parameter Details <basedir>
Base directory of the project, from where the Modello models are loaded.
java.lang.String
Yes
${basedir}
The file that contains license header text. If both configured, the
licenseText
prevails.
java.io.File
2.3.1
No
The contents of license header text, verbatim.
java.lang.String
2.3.1
No
List of relative paths to mdo files containing the models.
java.lang.String[]
Yes
The output directory of the generated files.
java.io.File
No
${project.build.directory}/generated-sources/modello
True if the generated package names should include the version.
boolean
Yes
packageWithVersion
false
Additional historical versions to generate, each being packaged with the version regardless of the packageWithVersion
setting.
java.util.List<java.lang.String>
No
A list of parameters, using the syntax key=value
. Those parameters will be made accessible to the templates.
java.util.List<java.lang.String>
No
Additional exceptions to the singularization rules, changing plural noun to singular.
As a key we provide plural noun and as value we provide singular noun, example:
<kisses>kiss</kisses>
java.util.Map<java.lang.String, java.lang.String>
2.5.0
No
A list of template paths to be run against the loaded Modello model. Those are
.vm
files as described in the
Velocity Users Guiderelative to
velocityBasedir
.
java.util.List<java.lang.String>
No
The directory where Velocity templates are looked for.
java.io.File
No
${project.basedir}
The version of the model we will be working on.
java.lang.String
Yes
version
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4