public class AmpMojo
extends org.apache.maven.plugin.AbstractMojo
| Modifier and Type | Field and Description |
|---|---|
protected File |
ampBuildDirectory
Target folder used to aggregate content then packaged into the AMP
|
protected File |
ampFinalDir
Directory of the final generated AMP
|
protected String |
ampFinalName
Name of the generated AMP and JAR artifacts
|
protected org.apache.maven.archiver.MavenArchiveConfiguration |
archive
The archive configuration to use.
|
protected boolean |
attachClasses
Whether the JAR produced should be attached as a separate 'classes' artifact.
|
protected boolean |
attachConfig
Whether a config artifact should be produced should be attached as a separate 'config' artifact.
|
protected File |
classesDirectory
(Read Only) Directory containing the classes and resource files that should be packaged into the JAR.
|
protected String |
classifier
Classifier to add to the artifact generated.
|
protected boolean |
includeDependencies
Whether (runtime scoped) JAR dependencies (including transitive) should be added or not to the generated AMP /lib folder.
|
protected boolean |
includeWebResources
Whether the AMP /web folder should be added or not to the generated AMP file.
|
protected org.apache.maven.project.MavenProject |
project
(Read Only) The Maven project.
|
protected org.apache.maven.project.MavenProjectHelper |
projectHelper |
protected org.apache.maven.execution.MavenSession |
session
(Read Only) The Maven session
|
| Constructor and Description |
|---|
AmpMojo() |
| Modifier and Type | Method and Description |
|---|---|
protected File |
createArchive()
Creates and returns the AMP archive, invoking the AmpArchiver
|
protected File |
createConfigArchive()
Creates and returns the config archive, invoking the MavenArchiver
|
protected File |
createJarArchive()
Creates and returns the JAR archive, invoking the MavenArchiver
|
void |
execute() |
protected void |
gatherDependencies()
Copies all runtime dependencies to AMP lib.
|
protected static File |
getFile(File basedir,
String finalName,
String classifier,
String extension)
Builds a File object pointing to the target AMP package; the pointer to the File is created taking into
account the (optional) artifact classifier defined
|
protected String ampFinalName
protected File ampBuildDirectory
protected String classifier
protected boolean includeDependencies
protected boolean includeWebResources
protected boolean attachClasses
protected boolean attachConfig
protected File ampFinalDir
protected File classesDirectory
protected org.apache.maven.project.MavenProject project
protected org.apache.maven.execution.MavenSession session
protected org.apache.maven.archiver.MavenArchiveConfiguration archive
protected org.apache.maven.project.MavenProjectHelper projectHelper
public void execute()
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionprotected File createJarArchive() throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionprotected File createArchive() throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionprotected File createConfigArchive() throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionprotected static File getFile(File basedir, String finalName, String classifier, String extension)
basedir - the Base Directory of the currently built projectfinalName - the Final Name of the artifact being builtclassifier - the optional classifier of the artifact being builtprotected void gatherDependencies()
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionCopyright © 2014. All rights reserved.