public class MungeMojo
extends org.apache.maven.plugin.AbstractMojo
http://blog.publicobject.com/2009/02/preprocessing-java-with-munge.html
,
http://weblogs.java.net/blog/2006/09/05/munge-swings-secret-preprocessor
Modifier and Type | Field and Description |
---|---|
private org.apache.maven.model.Build |
build |
private java.lang.String |
excludes
List of patterns (separated by commas) specifying files that should not be copied; by default exclude nothing.
|
private org.apache.maven.project.MavenProject |
executedProject |
private java.lang.String |
includes
List of patterns (separated by commas) specifying files that should be munged; by default munge everything.
|
private java.lang.String |
mungedDirectory
Where to put the munged source files.
|
private java.lang.String |
symbols
List of symbols (separated by commas) identifying which sections of munged code to keep.
|
Constructor and Description |
---|
MungeMojo() |
Modifier and Type | Method and Description |
---|---|
void |
execute() |
static void |
munge(java.lang.String from,
java.lang.String to,
java.lang.String includes,
java.lang.String excludes)
Munges source files found in
from and places them in to , honoring any includes or excludes. |
private java.lang.String mungedDirectory
private java.lang.String symbols
private java.lang.String includes
private java.lang.String excludes
private org.apache.maven.model.Build build
private org.apache.maven.project.MavenProject executedProject
public void execute() throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
public static void munge(java.lang.String from, java.lang.String to, java.lang.String includes, java.lang.String excludes) throws org.apache.maven.plugin.MojoExecutionException
from
and places them in to
, honoring any includes or excludes.from
- The original source directoryto
- The munged source directoryincludes
- Comma-separated list of files to includeexcludes
- Comma-separated list of files to excludeorg.apache.maven.plugin.MojoExecutionException