|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.maven.plugin.AbstractMojo
org.ops4j.pax.construct.archetype.AbstractPaxArchetypeMojo
public abstract class AbstractPaxArchetypeMojo
Based on MavenArchetypeMojo, this abstract mojo adds support for additional archetype properties, needed to provide multi-module archetypes.
| Field Summary | |
|---|---|
static java.lang.String |
PAX_CONSTRUCT_GROUP_ID
Our local archetype group |
| Fields inherited from interface org.apache.maven.plugin.Mojo |
|---|
ROLE |
| Constructor Summary | |
|---|---|
AbstractPaxArchetypeMojo()
|
|
| Method Summary | |
|---|---|
protected void |
addTempFiles(java.lang.String pathExpression)
|
protected void |
cacheOriginalFiles(java.io.File baseDir)
Gives sub-classes the chance to cache the original files before custom archetypes run |
protected boolean |
createMoreArtifacts()
|
void |
execute()
|
protected java.lang.String |
getArchetypeProperty(java.lang.String name)
|
protected java.lang.String |
getCompoundId(java.lang.String groupId,
java.lang.String artifactId)
Combine the groupId and artifactId, eliminating duplicate elements if compactNames is true |
protected org.apache.maven.artifact.factory.ArtifactFactory |
getFactory()
|
protected java.util.Set |
getFinalFilenames()
|
protected java.lang.String |
getInternalGroupId(java.lang.String bundleGroupId)
|
protected org.apache.maven.artifact.repository.ArtifactRepository |
getLocalRepo()
|
protected abstract java.lang.String |
getParentId()
|
protected java.lang.String |
getPluginVersion()
|
protected java.util.List |
getRemoteRepos()
|
protected org.apache.maven.artifact.resolver.ArtifactResolver |
getResolver()
|
protected org.apache.maven.artifact.metadata.ArtifactMetadataSource |
getSource()
|
protected boolean |
hasCustomContent()
|
protected void |
postProcess(PomUtils.Pom pom,
BndUtils.Bnd bnd)
Sub-class specific post-processing, which runs *after* custom archetypes are added |
protected void |
saveBndInstructions(BndUtils.Bnd bnd)
|
protected void |
saveProjectModel(PomUtils.Pom pom)
|
protected void |
scheduleArchetype(java.lang.String groupId,
java.lang.String artifactId,
java.lang.String version)
Add a custom archetype to the list of archetypes to merge in once the main archetype has been applied |
protected void |
setArchetypeProperty(java.lang.String name,
java.lang.String value)
|
protected void |
setMainArchetype(java.lang.String archetypeArtifactId)
Fill in archetype details for the selected Pax-Construct archetype |
protected abstract void |
updateExtensionFields()
Set the remaining fields in the archetype mojo |
| 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 |
| Field Detail |
|---|
public static final java.lang.String PAX_CONSTRUCT_GROUP_ID
| Constructor Detail |
|---|
public AbstractPaxArchetypeMojo()
| Method Detail |
|---|
protected final org.apache.maven.artifact.factory.ArtifactFactory getFactory()
protected final org.apache.maven.artifact.resolver.ArtifactResolver getResolver()
protected final org.apache.maven.artifact.metadata.ArtifactMetadataSource getSource()
protected final org.apache.maven.artifact.repository.ArtifactRepository getLocalRepo()
protected final java.util.List getRemoteRepos()
protected final boolean hasCustomContent()
protected final java.lang.String getInternalGroupId(java.lang.String bundleGroupId)
bundleGroupId - customized bundle groupId (may be null)
protected final java.lang.String getPluginVersion()
protected final void addTempFiles(java.lang.String pathExpression)
pathExpression - Ant-style path expression, can include wildcards
public final void execute()
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
protected abstract void updateExtensionFields()
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionprotected abstract java.lang.String getParentId()
protected void cacheOriginalFiles(java.io.File baseDir)
baseDir - project base directory
protected void postProcess(PomUtils.Pom pom,
BndUtils.Bnd bnd)
throws org.apache.maven.plugin.MojoExecutionException
pom - working copy of Maven POMbnd - working copy of Bnd instructions
org.apache.maven.plugin.MojoExecutionExceptionprotected boolean createMoreArtifacts()
protected final void setMainArchetype(java.lang.String archetypeArtifactId)
archetypeArtifactId - selected OSGi archetype
protected final void saveProjectModel(PomUtils.Pom pom)
throws java.io.IOException
pom - Maven project to merge with the latest file copy
java.io.IOException
protected final void saveBndInstructions(BndUtils.Bnd bnd)
throws java.io.IOException
bnd - Bnd instructions to merge with the latest file copy
java.io.IOException
protected final java.lang.String getCompoundId(java.lang.String groupId,
java.lang.String artifactId)
groupId - project group idartifactId - project artifact id
protected final void scheduleArchetype(java.lang.String groupId,
java.lang.String artifactId,
java.lang.String version)
groupId - archetype group idartifactId - archetype atifact idversion - archetype versionprotected final java.util.Set getFinalFilenames()
protected final void setArchetypeProperty(java.lang.String name,
java.lang.String value)
name - property namevalue - property valueprotected final java.lang.String getArchetypeProperty(java.lang.String name)
name - property name
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||