Package org.fusesource.hawtjni.maven
Class BuildMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.fusesource.hawtjni.maven.BuildMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="build", defaultPhase=GENERATE_TEST_RESOURCES) public class BuildMojo extends org.apache.maven.plugin.AbstractMojoThis goal builds the JNI module which was previously generated with the generate goal. It adds the JNI module to the test resource path so that unit tests can load the freshly built JNI library.- Author:
- Hiram Chirino
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.maven.artifact.factory.ArtifactFactoryartifactFactoryArtifact factory, needed to download the package source fileprotected org.apache.maven.artifact.resolver.ArtifactResolverartifactResolverArtifact resolver, needed to download the package source fileprotected org.apache.maven.artifact.repository.ArtifactRepositorylocalRepositoryLocal maven repository.protected org.apache.maven.project.MavenProjectprojectThe maven project.protected ListremoteArtifactRepositoriesRemote repositories
-
Constructor Summary
Constructors Constructor Description BuildMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddownloadNativeSourcePackage(File buildDir)voidexecute()
-
-
-
Field Detail
-
project
@Parameter(defaultValue="${project}", readonly=true) protected org.apache.maven.project.MavenProject projectThe maven project.
-
remoteArtifactRepositories
@Parameter(defaultValue="${project.remoteArtifactRepositories}", readonly=true) protected List remoteArtifactRepositoriesRemote repositories
-
localRepository
@Parameter(defaultValue="${localRepository}", readonly=true) protected org.apache.maven.artifact.repository.ArtifactRepository localRepositoryLocal maven repository.
-
artifactFactory
@Component protected org.apache.maven.artifact.factory.ArtifactFactory artifactFactory
Artifact factory, needed to download the package source file
-
artifactResolver
@Component protected org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver
Artifact resolver, needed to download the package source file
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException- Throws:
org.apache.maven.plugin.MojoExecutionException
-
downloadNativeSourcePackage
public void downloadNativeSourcePackage(File buildDir) throws org.apache.maven.plugin.MojoExecutionException
- Throws:
org.apache.maven.plugin.MojoExecutionException
-
-