Class LibYearMojo

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

    @Mojo(name="analyze",
          defaultPhase=VERIFY)
    public class LibYearMojo
    extends org.apache.maven.plugin.AbstractMojo
    Analyze dependencies and calculate how old they are.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected Set<String> ignoredVersions  
      protected boolean processDependencies
      Whether to consider the dependencies pom section.
      • Fields inherited from interface org.apache.maven.plugin.Mojo

        ROLE
    • Constructor Summary

      Constructors 
      Constructor Description
      LibYearMojo​(org.apache.maven.repository.RepositorySystem repositorySystem, org.eclipse.aether.RepositorySystem aetherRepositorySystem)  
    • Field Detail

      • ignoredVersions

        @Parameter(property="maven.version.ignore",
                   readonly=true)
        protected Set<String> ignoredVersions
      • processDependencies

        @Parameter(property="processDependencies",
                   defaultValue="true")
        protected boolean processDependencies
        Whether to consider the dependencies pom section. If this is set to false the plugin won't analyze dependencies, but it might analyze e.g. plugins depending on configuration.
        Since:
        1.0.
    • Constructor Detail

      • LibYearMojo

        @Inject
        public LibYearMojo​(org.apache.maven.repository.RepositorySystem repositorySystem,
                           org.eclipse.aether.RepositorySystem aetherRepositorySystem)
    • Method Detail

      • setProject

        protected void setProject​(org.apache.maven.project.MavenProject project)
        Setter for property 'project'.
        Parameters:
        project - Value to set for property 'project'.
      • setSession

        protected void setSession​(org.apache.maven.execution.MavenSession session)
        Setter for property 'session'.
        Parameters:
        session - Value to set for property 'session'.
      • setSearchUri

        protected void setSearchUri​(String uri)
        Set the search URI
      • setHttpTimeout

        protected void setHttpTimeout​(int seconds)
        Setter for the HTTP timeout for API calls
      • setFetchRetryCount

        protected void setFetchRetryCount​(int count)
        Setter for the HTTP API fetch retry count
        Parameters:
        count - the number of retries before giving up
      • execute

        public void execute()
                     throws org.apache.maven.plugin.MojoExecutionException
        Main entry point for the plugin.
        Throws:
        org.apache.maven.plugin.MojoExecutionException - On failure, such as upstream HTTP issues