org.apache.felix.bundleplugin.baseline

## Class BaselinePlugin

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

- All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

      @Mojo(name="baseline",
            threadSafe=true,
            requiresDependencyResolution=TEST,
            defaultPhase=VERIFY)
      public final class BaselinePlugin
      extends org.apache.maven.plugin.AbstractMojo

  BND Baseline check between two bundles.
  Since:
    2.4.1

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected String` | `comparisonClassifier` Classifier for the 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.plugin.Mojo

      `ROLE`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `BaselinePlugin()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `close(Object writer)`
    `protected void` | `endBaseline(Object context)`
    `protected void` | `endDiff(Object context, int depth)`
    `protected void` | `endPackage(Object context)`
    `void` | `execute()`
    `protected void` | `execute(Object context)`
    `protected Object` | `init(Object noContext)`
    `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 name, 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`

- - ### Field Detail

    - #### 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

    - #### comparisonVersion

          @Parameter(defaultValue="(,${project.version})",
                     property="comparisonVersion")
          protected String comparisonVersion

      Version 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.

  - ### Constructor Detail

    - #### BaselinePlugin

          public BaselinePlugin()

  - ### Method Detail

    - #### init

          protected Object init(Object noContext)

    - #### close

          protected void close(Object writer)

    - #### startBaseline

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

    - #### startPackage

          protected void startPackage(Object context,
                          boolean mismatch,
                          String name,
                          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)

    - #### 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`

Copyright © 2015. All rights reserved.