Class HK2GenerateMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
com.sun.enterprise.module.maven.HK2GenerateMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
@Mojo(name="hk2-generate",
defaultPhase=PREPARE_PACKAGE,
requiresProject=true,
requiresDependencyResolution=COMPILE)
public class HK2GenerateMojo
extends org.apache.maven.plugin.AbstractMojo
Generates a consolidated OSGI bundle with a consolidated HK2 header
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final intprivate static final Stringprivate static final Stringprivate static final Stringprotected FileDirectory where the manifest will be writtenprivate static final Stringprotected org.apache.maven.project.MavenProjectThe maven project.Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidcatJarEntry(JarFile jf, JarEntry e, OutputStream catStream) voidexecute()private OutputStreamMethods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
META_INF
- See Also:
-
HK2_LOCATOR
- See Also:
-
DEFAULT
- See Also:
-
JAR_ENTRY
- See Also:
-
BUFFER_SIZE
private static final int BUFFER_SIZE- See Also:
-
manifestLocation
@Parameter(property="manifestLocation", defaultValue="${project.build.outputDirectory}") protected File manifestLocationDirectory where the manifest will be written -
project
@Parameter(property="project", required=true, readonly=true) protected org.apache.maven.project.MavenProject projectThe maven project.
-
-
Constructor Details
-
HK2GenerateMojo
public HK2GenerateMojo()
-
-
Method Details
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException- Throws:
org.apache.maven.plugin.MojoExecutionException
-
catJarEntry
- Throws:
IOException
-
getCatOutputStream
private OutputStream getCatOutputStream() throws org.apache.maven.plugin.MojoExecutionException, IOException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionIOException
-