@Mojo(name="war", defaultPhase=PACKAGE, threadSafe=true, requiresDependencyResolution=COMPILE_PLUS_RUNTIME) public class WarMojo extends AbstractWarMojo
escapeString, failOnMissingWebXml, outputTimestamp, propertiesEncoding
Constructor and Description |
---|
WarMojo() |
Modifier and Type | Method and Description |
---|---|
void |
execute()
Executes the WarMojo on the current project.
|
String |
getClassesClassifier() |
String |
getClassifier() |
String |
getOutputDirectory() |
String[] |
getPackagingExcludes() |
String[] |
getPackagingIncludes() |
org.apache.maven.project.MavenProjectHelper |
getProjectHelper() |
protected File |
getTargetClassesFile() |
protected static File |
getTargetFile(File basedir,
String finalName,
String classifier,
String type) |
protected File |
getTargetWarFile() |
org.codehaus.plexus.archiver.war.WarArchiver |
getWarArchiver() |
String |
getWarName() |
boolean |
isAttachClasses() |
boolean |
isFailOnMissingWebXml() |
boolean |
isPrimaryArtifact() |
boolean |
isSkip()
Skip the mojo run
|
void |
setAttachClasses(boolean attachClasses) |
void |
setClassesClassifier(String classesClassifier) |
void |
setClassifier(String classifier) |
void |
setFailOnMissingWebXml(boolean failOnMissingWebXml) |
void |
setOutputDirectory(String outputDirectory) |
void |
setPackagingExcludes(String packagingExcludes) |
void |
setPackagingIncludes(String packagingIncludes) |
void |
setPrimaryArtifact(boolean primaryArtifact) |
void |
setProjectHelper(org.apache.maven.project.MavenProjectHelper projectHelper) |
void |
setWarArchiver(org.codehaus.plexus.archiver.war.WarArchiver warArchiver) |
void |
setWarName(String warName) |
addOverlay, buildExplodedWebapp, buildWebapp, getArchive, getArtifactFactory, getClassesDirectory, getContainerConfigXML, getCurrentProjectOverlay, getDependentWarExcludes, getDependentWarIncludes, getExcludes, getFilters, getIncludes, getJarArchiver, getNonFilteredFileExtensions, getOutputFileNameMapping, getOverlays, getProject, getSession, getWarSourceDirectory, getWarSourceExcludes, getWarSourceIncludes, getWebappDirectory, getWebResources, getWebXml, getWorkDirectory, isArchiveClasses, isIncludeEmptyDirectories, isRecompressZippedFiles, setArchiveClasses, setArtifactFactory, setClassesDirectory, setContainerConfigXML, setFilters, setJarArchiver, setNonFilteredFileExtensions, setOutputFileNameMapping, setOverlays, setProject, setWarSourceDirectory, setWarSourceExcludes, setWarSourceIncludes, setWebappDirectory, setWebResources, setWebXml, setWorkDirectory
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionException
- if an error occurred while building the webapporg.apache.maven.plugin.MojoFailureException
- if an error.protected static File getTargetFile(File basedir, String finalName, String classifier, String type)
basedir
- The basedirfinalName
- The finalNameclassifier
- The classifier.type
- The type.File
public String getClassifier()
classifier
public void setClassifier(String classifier)
classifier
- classifier
public String[] getPackagingExcludes()
public void setPackagingExcludes(String packagingExcludes)
packagingExcludes
- packagingExcludes
public String[] getPackagingIncludes()
public void setPackagingIncludes(String packagingIncludes)
packagingIncludes
- packagingIncludes
public String getOutputDirectory()
outputDirectory
public void setOutputDirectory(String outputDirectory)
outputDirectory
- outputDirectory
public org.codehaus.plexus.archiver.war.WarArchiver getWarArchiver()
warArchiver
public void setWarArchiver(org.codehaus.plexus.archiver.war.WarArchiver warArchiver)
warArchiver
- warArchiver
public org.apache.maven.project.MavenProjectHelper getProjectHelper()
projectHelper
public void setProjectHelper(org.apache.maven.project.MavenProjectHelper projectHelper)
projectHelper
- projectHelper
public boolean isPrimaryArtifact()
primaryArtifact
public void setPrimaryArtifact(boolean primaryArtifact)
primaryArtifact
- primaryArtifact
public boolean isAttachClasses()
attachClasses
public void setAttachClasses(boolean attachClasses)
attachClasses
- attachClasses
public String getClassesClassifier()
classesClassifier
public void setClassesClassifier(String classesClassifier)
classesClassifier
- classesClassifier
public boolean isFailOnMissingWebXml()
AbstractWarMojo.failOnMissingWebXml
public void setFailOnMissingWebXml(boolean failOnMissingWebXml)
failOnMissingWebXml
- AbstractWarMojo.failOnMissingWebXml
public boolean isSkip()
skip
Copyright © 2002–2023 The Apache Software Foundation. All rights reserved.