Class ArtifactMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- com.googlecode.download.maven.plugin.internal.ArtifactMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="artifact", defaultPhase=PROCESS_RESOURCES, requiresProject=false) public class ArtifactMojo extends org.apache.maven.plugin.AbstractMojoThis mojo is designed to download a maven artifact from the repository and download them in the specified path. The maven artifact downloaded can also download it's dependency or not, based on a parameter.- Author:
- Marc-Andre Houle
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.maven.project.ProjectBuilderprojectBuilderThe (injected)ProjectBuilderinstance.protected org.eclipse.aether.RepositorySystemrepositorySystemThe (injected)RepositorySysteminstance.protected org.apache.maven.execution.MavenSessionsessionThe Maven Session.
-
Constructor Summary
Constructors Constructor Description ArtifactMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute()Will download the specified artifact in the specified directory.
-
-
-
Field Detail
-
session
@Parameter(defaultValue="${session}", required=true, readonly=true) protected org.apache.maven.execution.MavenSession sessionThe Maven Session.
-
repositorySystem
@Inject protected org.eclipse.aether.RepositorySystem repositorySystem
The (injected)RepositorySysteminstance.
-
projectBuilder
@Inject protected org.apache.maven.project.ProjectBuilder projectBuilder
The (injected)ProjectBuilderinstance.
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionExceptionWill download the specified artifact in the specified directory.- Throws:
org.apache.maven.plugin.MojoExecutionException- thrown if there is a problem while processing the request- See Also:
Mojo.execute()
-
-