Package org.apache.felix.bundleplugin.baseline

# Class BaselineReport

java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.felix.bundleplugin.baseline.BaselineReport

All Implemented Interfaces:
  `org.apache.maven.plugin.ContextEnabled`, `org.apache.maven.plugin.Mojo`, `org.apache.maven.reporting.MavenReport`

@Mojo(name="baseline-report", threadSafe=true, defaultPhase=SITE) public final class BaselineReport extends org.apache.maven.plugin.AbstractMojo implements org.apache.maven.reporting.MavenReport
BND Baseline report.

Since:
  2.4.1

## Field Summary

Fields
Modifier and Type
Field
Description
`protected org.sonatype.plexus.build.incremental.BuildContext`
`buildContext`
`protected String`
`comparisonArtifactId`
Artifact to compare the current code against.
`protected String`
`comparisonClassifier`
Classifier for the artifact to compare the current code against.
`protected String`
`comparisonGroupId`
Group id to compare the current code against.
`protected String`
`comparisonPackaging`
Artifact to compare the current code against.
`protected String`
`comparisonVersion`
Version to compare the current code against.
`protected org.apache.maven.artifact.factory.ArtifactFactory`
`factory`
`protected boolean`
`failOnError`
Whether to fail on errors.
`protected boolean`
`failOnWarning`
Whether to fail on warnings.
`protected org.apache.maven.project.MavenProject`
`project`
`protected org.apache.maven.artifact.resolver.ArtifactResolver`
`resolver`
`protected org.apache.maven.execution.MavenSession`
`session`
`protected boolean`
`skip`
Flag to easily skip execution.
`protected List<String>`
`supportedProjectTypes`
Project types which this plugin supports.

### Fields inherited from interface org.apache.maven.reporting.MavenReport

`CATEGORY_PROJECT_INFORMATION, CATEGORY_PROJECT_REPORTS, ROLE`

### Fields inherited from interface org.apache.maven.plugin.Mojo

`ROLE`

## Constructor Summary

Constructors
Constructor
Description
`BaselineReport()`

## Method Summary

Modifier and Type
Method
Description
`boolean`
`canGenerateReport()`
`protected void`
`close(Object context)`
`protected void`
`endBaseline(Object context)`
`protected void`
`endDiff(Object context, int depth)`
`protected void`
`endPackage(Object context)`
`final void`
`execute()`
`protected void`
`execute(Object context)`
`void`
`generate(org.apache.maven.doxia.sink.Sink sink, Locale locale)`
`String`
`getCategoryName()`
`String`
`getDescription(Locale locale)`
`String`
`getName(Locale locale)`
`String`
`getOutputName()`
`File`
`getReportOutputDirectory()`
`protected Object`
`init(Object context)`
`boolean`
`isExternalReport()`
`void`
`setReportOutputDirectory(File outputDirectory)`
`protected void`
`startBaseline(Object context, String generationDate, String bundleName, String currentVersion, String previousVersion)`
`protected void`
`startDiff(Object context, int depth, String type, String name, String delta, String shortDelta)`
`protected void`
`startPackage(Object context, boolean mismatch, String packageName, String shortDelta, String delta, aQute.bnd.version.Version newerVersion, aQute.bnd.version.Version olderVersion, aQute.bnd.version.Version suggestedVersion, org.apache.felix.bundleplugin.baseline.DiffMessage diffMessage, Map<String,String> attributes)`

### 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.reporting.MavenReport

`getOutputPath`

## Field Details

### skip

@Parameter(property="baseline.skip", defaultValue="false") protected boolean skip
Flag to easily skip execution.

### failOnError

@Parameter(property="baseline.failOnError", defaultValue="true") protected boolean failOnError
Whether to fail on errors.

### failOnWarning

@Parameter(property="baseline.failOnWarning", defaultValue="false") protected boolean failOnWarning
Whether to fail on warnings.

### project

@Parameter(defaultValue="${project}", readonly=true, required=true) protected org.apache.maven.project.MavenProject project

### session

@Parameter(defaultValue="${session}", readonly=true, required=true) protected org.apache.maven.execution.MavenSession session

### resolver

@Component protected org.apache.maven.artifact.resolver.ArtifactResolver resolver

### factory

@Component protected org.apache.maven.artifact.factory.ArtifactFactory factory

### comparisonGroupId

@Parameter(defaultValue="${project.groupId}", property="comparisonGroupId") protected String comparisonGroupId
Group id to compare the current code against.

### comparisonArtifactId

@Parameter(defaultValue="${project.artifactId}", property="comparisonArtifactId") protected String comparisonArtifactId
Artifact to compare the current code against.

### comparisonVersion

@Parameter(defaultValue="(,${project.version})", property="comparisonVersion") protected String comparisonVersion
Version to compare the current code against.

### comparisonPackaging

@Parameter(defaultValue="${project.packaging}", property="comparisonPackaging") protected String comparisonPackaging
Artifact to compare the current code against.

### comparisonClassifier

@Parameter(property="comparisonClassifier") protected String comparisonClassifier
Classifier for the artifact to compare the current code against.

### supportedProjectTypes

@Parameter protected List<String> supportedProjectTypes
Project types which this plugin supports.

### buildContext

@Component protected org.sonatype.plexus.build.incremental.BuildContext buildContext

## Constructor Details

### BaselineReport

public BaselineReport()

## Method Details

### init

protected Object init(Object context)

### close

protected void close(Object context)

### startBaseline

protected void startBaseline(Object context, String generationDate, String bundleName, String currentVersion, String previousVersion)

### startPackage

protected void startPackage(Object context, boolean mismatch, String packageName, String shortDelta, String delta, aQute.bnd.version.Version newerVersion, aQute.bnd.version.Version olderVersion, aQute.bnd.version.Version suggestedVersion, org.apache.felix.bundleplugin.baseline.DiffMessage diffMessage, Map<String,String> attributes)

### startDiff

protected void startDiff(Object context, int depth, String type, String name, String delta, String shortDelta)

### endDiff

protected void endDiff(Object context, int depth)

### endPackage

protected void endPackage(Object context)

### endBaseline

protected void endBaseline(Object context)

### canGenerateReport

public boolean canGenerateReport()

Specified by:
  `canGenerateReport` in interface `org.apache.maven.reporting.MavenReport`

### getCategoryName

public String getCategoryName()

Specified by:
  `getCategoryName` in interface `org.apache.maven.reporting.MavenReport`

### getDescription

public String getDescription(Locale locale)

Specified by:
  `getDescription` in interface `org.apache.maven.reporting.MavenReport`

### getName

public String getName(Locale locale)

Specified by:
  `getName` in interface `org.apache.maven.reporting.MavenReport`

### generate

public void generate(org.apache.maven.doxia.sink.Sink sink, Locale locale) throws org.apache.maven.reporting.MavenReportException

Specified by:
  `generate` in interface `org.apache.maven.reporting.MavenReport`
Throws:
  `org.apache.maven.reporting.MavenReportException`

### getOutputName

public String getOutputName()

Specified by:
  `getOutputName` in interface `org.apache.maven.reporting.MavenReport`

### getReportOutputDirectory

public File getReportOutputDirectory()

Specified by:
  `getReportOutputDirectory` in interface `org.apache.maven.reporting.MavenReport`

### isExternalReport

public boolean isExternalReport()

Specified by:
  `isExternalReport` in interface `org.apache.maven.reporting.MavenReport`

### setReportOutputDirectory

public void setReportOutputDirectory(File outputDirectory)

Specified by:
  `setReportOutputDirectory` in interface `org.apache.maven.reporting.MavenReport`

### execute

public final void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException

Throws:
  `org.apache.maven.plugin.MojoExecutionException`
  `org.apache.maven.plugin.MojoFailureException`

### execute

protected void execute(Object context) throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException

Throws:
  `org.apache.maven.plugin.MojoExecutionException`
  `org.apache.maven.plugin.MojoFailureException`