public class WebModule extends AbstractEarModule
EarModule implementation for a Web application module.| Modifier and Type | Field and Description |
|---|---|
private static java.lang.String |
CONTEXT_ROOT_FIELD |
private java.lang.String |
contextRoot |
private static java.lang.String |
WEB_MODULE |
private static java.lang.String |
WEB_URI_FIELD |
ALT_DD, altDeploymentDescriptor, bundleDir, bundleFileName, earExecutionContext, excluded, JAVA_MODULE, MODULE_ELEMENT, unpack| Constructor and Description |
|---|
WebModule()
Create an instance.
|
WebModule(org.apache.maven.artifact.Artifact a) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendModule(org.codehaus.plexus.util.xml.XMLWriter writer,
java.lang.String version,
java.lang.Boolean generateId)
Appends the XML representation of this module.
|
java.lang.String |
getContextRoot()
Returns the context root to use for the web module.
|
private static java.lang.String |
getDefaultContextRoot(org.apache.maven.artifact.Artifact a)
Generates a default context root for the given artifact, based on the artifactId.
|
java.lang.String |
getLibDir() |
java.lang.String |
getType()
Returns the type associated to the module.
|
void |
resolveArtifact(java.util.Set<org.apache.maven.artifact.Artifact> artifacts)
Resolves the
Artifact represented by the module. |
areNullOrEqual, changeManifestClasspath, cleanBundleDir, getAltDeploymentDescriptor, getArtifact, getArtifactId, getBundleDir, getBundleFileName, getClassifier, getGroupId, getModuleId, getOriginalBundleFileName, getUri, isExcluded, setEarExecutionContext, setUri, shouldUnpack, startModuleElement, toString, writeAltDeploymentDescriptorprivate static final java.lang.String WEB_MODULE
private static final java.lang.String WEB_URI_FIELD
private static final java.lang.String CONTEXT_ROOT_FIELD
private java.lang.String contextRoot
public WebModule()
public WebModule(org.apache.maven.artifact.Artifact a)
a - Artifactpublic void appendModule(org.codehaus.plexus.util.xml.XMLWriter writer,
java.lang.String version,
java.lang.Boolean generateId)
writer - the writer to useversion - the version of the application.xml filegenerateId - whether an id should be generatedpublic void resolveArtifact(java.util.Set<org.apache.maven.artifact.Artifact> artifacts)
throws EarPluginException,
org.apache.maven.plugin.MojoFailureException
Artifact represented by the module. Note that the EarExecutionContext might be used
to customize further the resolution.resolveArtifact in interface EarModuleresolveArtifact in class AbstractEarModuleartifacts - the project's artifactsEarPluginException - if the artifact could not be resolvedorg.apache.maven.plugin.MojoFailureException - if an unexpected error occurredpublic java.lang.String getContextRoot()
public java.lang.String getType()
private static java.lang.String getDefaultContextRoot(org.apache.maven.artifact.Artifact a)
a - the artifactpublic java.lang.String getLibDir()
getLibDir in interface EarModulegetLibDir in class AbstractEarModulenull