org.apache.maven.plugin.assembly
Class AbstractUnpackingMojo

java.lang.Object
  extended by org.apache.maven.plugin.AbstractMojo
      extended by org.apache.maven.plugin.assembly.AbstractUnpackingMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
Direct Known Subclasses:
AbstractAssemblyMojo, UnpackMojo

public abstract class AbstractUnpackingMojo
extends org.apache.maven.plugin.AbstractMojo

Base routines for assembly and unpack goals.

Version:
$Id: AbstractUnpackingMojo.java 387485 2006-03-21 10:50:21Z epunzalan $

Field Summary
protected  org.codehaus.plexus.archiver.manager.ArchiverManager archiverManager
          To look up Archiver/UnArchiver implementations
protected  org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver
           
protected  java.lang.String classifier
          Deprecated. Please use the Assembly's id for classifier instead
protected static java.lang.String[] EMPTY_STRING_ARRAY
           
protected  java.lang.String finalName
          The filename of the assembled distribution file.
protected  org.apache.maven.artifact.repository.ArtifactRepository localRepository
           
protected  java.io.File outputDirectory
          The output directory of the assembled distribution file.
protected  org.apache.maven.project.MavenProject project
          The Maven Project.
protected  boolean projectModulesOnly
           
protected  java.util.List reactorProjects
          Contains the full list of projects in the reactor.
protected  java.io.File workDirectory
          Directory to unpack JARs into if needed
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
AbstractUnpackingMojo()
           
 
Method Summary
 java.lang.String getClassifier()
           
protected  java.util.Set getDependencies()
          Retrieves all artifact dependencies within the reactor
protected abstract  org.apache.maven.project.MavenProject getExecutedProject()
           
protected  java.util.Set getModules()
           
protected  void unpack(java.io.File file, java.io.File location)
          Unpacks the archive file.
 
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
 
Methods inherited from interface org.apache.maven.plugin.Mojo
execute
 

Field Detail

EMPTY_STRING_ARRAY

protected static final java.lang.String[] EMPTY_STRING_ARRAY

outputDirectory

protected java.io.File outputDirectory
The output directory of the assembled distribution file.


finalName

protected java.lang.String finalName
The filename of the assembled distribution file.


projectModulesOnly

protected boolean projectModulesOnly

workDirectory

protected java.io.File workDirectory
Directory to unpack JARs into if needed


archiverManager

protected org.codehaus.plexus.archiver.manager.ArchiverManager archiverManager
To look up Archiver/UnArchiver implementations


artifactResolver

protected org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver

localRepository

protected org.apache.maven.artifact.repository.ArtifactRepository localRepository

reactorProjects

protected java.util.List reactorProjects
Contains the full list of projects in the reactor.


classifier

protected java.lang.String classifier
Deprecated. Please use the Assembly's id for classifier instead

project

protected org.apache.maven.project.MavenProject project
The Maven Project.

Constructor Detail

AbstractUnpackingMojo

public AbstractUnpackingMojo()
Method Detail

getDependencies

protected java.util.Set getDependencies()
                                 throws org.apache.maven.plugin.MojoExecutionException
Retrieves all artifact dependencies within the reactor

Returns:
A HashSet of artifacts
Throws:
org.apache.maven.plugin.MojoExecutionException

getModules

protected java.util.Set getModules()
                            throws org.apache.maven.plugin.MojoExecutionException,
                                   org.apache.maven.plugin.MojoFailureException
Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException

getExecutedProject

protected abstract org.apache.maven.project.MavenProject getExecutedProject()

unpack

protected void unpack(java.io.File file,
                      java.io.File location)
               throws org.apache.maven.plugin.MojoExecutionException,
                      org.codehaus.plexus.archiver.manager.NoSuchArchiverException
Unpacks the archive file.

Parameters:
file - File to be unpacked.
location - Location where to put the unpacked files.
Throws:
org.apache.maven.plugin.MojoExecutionException
org.codehaus.plexus.archiver.manager.NoSuchArchiverException

getClassifier

public java.lang.String getClassifier()


Copyright © 2002-2007 Apache Software Foundation. All Rights Reserved.