net.sf.xsltmp
Class ManyToManyBase
java.lang.Object
org.apache.maven.plugin.AbstractMojo
net.sf.xsltmp.XsltGeneratorBase
net.sf.xsltmp.FromManyBase
net.sf.xsltmp.ManyToManyBase
- All Implemented Interfaces:
- XsltGeneratorConstants, org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
- ManyToDynamicMojo, ManyToManyMojo
public abstract class ManyToManyBase
- extends FromManyBase
A base class for mojos with multiple destination files.
| Fields inherited from interface org.apache.maven.plugin.Mojo |
ROLE |
| Methods inherited from class net.sf.xsltmp.FromManyBase |
ensureDestFileDirExists, getResolver, getSourceFile, getSourceFiles, getSrcDir, getSrcExcludes, getSrcIncludes, logExecution, setSrcDir, setSrcExcludes, setSrcIncludes, verifySrcDirExist |
| Methods inherited from class net.sf.xsltmp.XsltGeneratorBase |
getArchiverManager, getFilter, getFilterParameters, getForce, getHelper, getLogPrefix, getMojoName, getParameters, getProject, getSourceEncoding, getTimestamp, getTransformer, getXslFile, getXslTemplate, hasChanged, setArchiverManager, setFilter, setFilterParameters, setForce, setParameters, setProject, setSourceEncoding, setXslTemplate, verifyXsltFileExist |
| Methods inherited from class org.apache.maven.plugin.AbstractMojo |
getLog, getPluginContext, setLog, setPluginContext |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ManyToManyBase
public ManyToManyBase()
getDestDir
public File getDestDir()
setDestDir
public void setDestDir(File destDir)
getAddDestDirTo
public String getAddDestDirTo()
setAddDestDirTo
public void setAddDestDirTo(String addDestDirTo)
execute
public void execute()
throws org.apache.maven.plugin.MojoExecutionException,
org.apache.maven.plugin.MojoFailureException
- The main MOJO execution method.
Perform a generic XSL transformation algorithm. The mojo-specific parts
are implemented in called abstract methods in the class descendants.
- Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException
getDestFile
protected abstract File getDestFile(String sourceFileName)
- Return the destination file for a given source file name.
- Parameters:
sourceFileName -
- Returns:
- File
shouldSkip
protected abstract boolean shouldSkip(File srcFile,
File destFile)
- Return true iff the transformation from the given source file to the
given destination file should be skipped.
- Parameters:
srcFile - destFile -
- Returns:
- boolean
cleanAfterFileTransformation
protected void cleanAfterFileTransformation(File destFile)
- Perform any clean-up after a source file has been transformed into the
given destination file.
- Parameters:
destFile -
ensureDestDirExists
protected void ensureDestDirExists()
throws org.apache.maven.plugin.MojoFailureException
- Throws:
org.apache.maven.plugin.MojoFailureException
addDestDir
protected void addDestDir()
- Add the destination directory to the project.
Copyright © 2008-2010 SEAF. All Rights Reserved.