Class CheckDistributionMojo

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

    @Mojo(name="check-distribution",
          requiresProject=true,
          defaultPhase=PACKAGE)
    public final class CheckDistributionMojo
    extends org.apache.maven.plugin.AbstractMojo
    Check a set of spec artifact in a staging directory.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.io.File dir
      The directory containing the spec artifacts to process.
      private java.lang.String excludes
      Exclude pattern.
      private java.lang.String includes
      Include pattern.
      private java.util.List<Spec> specs
      The specification configurations.
      • Fields inherited from interface org.apache.maven.plugin.Mojo

        ROLE
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void execute()  
      private Spec getSpec​(java.io.File file)
      Find or create the specification configuration for the given artifact.
      • 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

      • includes

        @Parameter(property="includes",
                   defaultValue="javax*.jar")
        private java.lang.String includes
        Include pattern.
      • excludes

        @Parameter(property="excludes")
        private java.lang.String excludes
        Exclude pattern.
      • dir

        @Parameter(property="dir",
                   required=true)
        private java.io.File dir
        The directory containing the spec artifacts to process.
      • specs

        @Parameter(property="specs",
                   required=true)
        private java.util.List<Spec> specs
        The specification configurations.
    • Constructor Detail

      • CheckDistributionMojo

        public CheckDistributionMojo()
    • Method Detail

      • getSpec

        private Spec getSpec​(java.io.File file)
                      throws java.io.IOException
        Find or create the specification configuration for the given artifact.
        Parameters:
        file - the artifact file to match
        Returns:
        the spec configuration
        Throws:
        java.io.IOException - if an error occurs while reading the JAR file entries
      • execute

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