Package org.apache.felix.bundleplugin
Class ManifestPlugin
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.apache.felix.bundleplugin.BundlePlugin
-
- org.apache.felix.bundleplugin.ManifestPlugin
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
BundleAllPlugin
@Mojo(name="manifest", requiresDependencyResolution=TEST, threadSafe=true, defaultPhase=PROCESS_CLASSES) public class ManifestPlugin extends BundlePluginGenerate an OSGi manifest for this project
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanrebuildBundleWhen true, generate the manifest by rebuilding the full bundle in memory-
Fields inherited from class org.apache.felix.bundleplugin.BundlePlugin
artifactFactory, artifactResolver, classifier, createDependencyReducedPom, dependencyGraphBuilder, dependencyReducedPomLocation, dumpClasspath, dumpInstructions, excludeDependencies, exportScr, localRepository, m_dependencyGraphBuilder, manifestLocation, mavenProjectBuilder, niceManifest, packaging, project, remoteArtifactRepositories, scrLocation, session, supportedProjectTypes, unpackBundle
-
-
Constructor Summary
Constructors Constructor Description ManifestPlugin()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static StringcalculateExportsFromContents(aQute.bnd.osgi.Jar bundle)protected voidexecute(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, Map<String,String> instructions, Properties properties, aQute.bnd.osgi.Jar[] classpath)protected aQute.bnd.osgi.AnalyzergetAnalyzer(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, aQute.bnd.osgi.Jar[] classpath)protected aQute.bnd.osgi.AnalyzergetAnalyzer(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, Map<String,String> instructions, Properties properties, aQute.bnd.osgi.Jar[] classpath)ManifestgetManifest(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, aQute.bnd.osgi.Jar[] classpath)ManifestgetManifest(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, Map<String,String> instructions, Properties properties, aQute.bnd.osgi.Jar[] classpath, org.sonatype.plexus.build.incremental.BuildContext buildContext)static voidwriteManifest(aQute.bnd.osgi.Analyzer analyzer, File outputFile, boolean niceManifest, boolean exportScr, File scrLocation, org.sonatype.plexus.build.incremental.BuildContext buildContext, org.apache.maven.plugin.logging.Log log)static voidwriteManifest(Manifest manifest, File outputFile, boolean niceManifest, org.sonatype.plexus.build.incremental.BuildContext buildContext, org.apache.maven.plugin.logging.Log log)-
Methods inherited from class org.apache.felix.bundleplugin.BundlePlugin
addMavenInstructions, addMavenSourcePath, buildDependencyGraph, buildOSGiBundle, convertVersionToOsgi, dumpClasspath, dumpInstructions, dumpManifest, execute, execute, getBase, getBuildDirectory, getBundleName, getClasspath, getDefaultProperties, getEmbeddableArtifacts, getFile, getMaven2OsgiConverter, getMavenResourcePaths, getOptionalPackages, getOSGiBuilder, getOutputDirectory, getProject, includeJava9Fixups, includeMavenResources, isTransitivelyOptional, mergeManifest, mergeMavenManifest, removeTagFromInstruction, reportErrors, sanitize, sanitize, setBuildDirectory, setOutputDirectory, transformDirectives, updateExcludesInDeps
-
-
-
-
Method Detail
-
execute
protected void execute(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, Map<String,String> instructions, Properties properties, aQute.bnd.osgi.Jar[] classpath) throws org.apache.maven.plugin.MojoExecutionException- Overrides:
executein classBundlePlugin- Throws:
org.apache.maven.plugin.MojoExecutionException
-
getManifest
public Manifest getManifest(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, aQute.bnd.osgi.Jar[] classpath) throws IOException, org.apache.maven.plugin.MojoFailureException, org.apache.maven.plugin.MojoExecutionException, Exception
- Throws:
IOExceptionorg.apache.maven.plugin.MojoFailureExceptionorg.apache.maven.plugin.MojoExecutionExceptionException
-
getManifest
public Manifest getManifest(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, Map<String,String> instructions, Properties properties, aQute.bnd.osgi.Jar[] classpath, org.sonatype.plexus.build.incremental.BuildContext buildContext) throws IOException, org.apache.maven.plugin.MojoFailureException, org.apache.maven.plugin.MojoExecutionException, Exception
- Throws:
IOExceptionorg.apache.maven.plugin.MojoFailureExceptionorg.apache.maven.plugin.MojoExecutionExceptionException
-
getAnalyzer
protected aQute.bnd.osgi.Analyzer getAnalyzer(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, aQute.bnd.osgi.Jar[] classpath) throws IOException, org.apache.maven.plugin.MojoExecutionException, Exception- Throws:
IOExceptionorg.apache.maven.plugin.MojoExecutionExceptionException
-
getAnalyzer
protected aQute.bnd.osgi.Analyzer getAnalyzer(org.apache.maven.project.MavenProject project, org.apache.maven.shared.dependency.graph.DependencyNode dependencyGraph, Map<String,String> instructions, Properties properties, aQute.bnd.osgi.Jar[] classpath) throws IOException, org.apache.maven.plugin.MojoExecutionException, Exception- Throws:
IOExceptionorg.apache.maven.plugin.MojoExecutionExceptionException
-
writeManifest
public static void writeManifest(aQute.bnd.osgi.Analyzer analyzer, File outputFile, boolean niceManifest, boolean exportScr, File scrLocation, org.sonatype.plexus.build.incremental.BuildContext buildContext, org.apache.maven.plugin.logging.Log log) throws Exception- Throws:
Exception
-
writeManifest
public static void writeManifest(Manifest manifest, File outputFile, boolean niceManifest, org.sonatype.plexus.build.incremental.BuildContext buildContext, org.apache.maven.plugin.logging.Log log) throws IOException
- Throws:
IOException
-
calculateExportsFromContents
public static String calculateExportsFromContents(aQute.bnd.osgi.Jar bundle)
-
-