Class JavaAnnotationsMojoDescriptorExtractor

java.lang.Object
org.codehaus.plexus.logging.AbstractLogEnabled
org.apache.maven.tools.plugin.extractor.annotations.JavaAnnotationsMojoDescriptorExtractor
All Implemented Interfaces:
org.apache.maven.tools.plugin.extractor.MojoDescriptorExtractor, org.codehaus.plexus.logging.LogEnabled

@Component(role=org.apache.maven.tools.plugin.extractor.MojoDescriptorExtractor.class, hint="java-annotations") public class JavaAnnotationsMojoDescriptorExtractor extends org.codehaus.plexus.logging.AbstractLogEnabled implements org.apache.maven.tools.plugin.extractor.MojoDescriptorExtractor
JavaMojoDescriptorExtractor, a MojoDescriptor extractor to read descriptors from java classes with annotations. Notice that source files are also parsed to get description, since and deprecation information.
Since:
3.0
Author:
Olivier Lamy
  • Constructor Details

    • JavaAnnotationsMojoDescriptorExtractor

      public JavaAnnotationsMojoDescriptorExtractor()
  • Method Details

    • execute

      public List<org.apache.maven.plugin.descriptor.MojoDescriptor> execute(org.apache.maven.tools.plugin.PluginToolsRequest request) throws org.apache.maven.tools.plugin.extractor.ExtractionException, org.apache.maven.plugin.descriptor.InvalidPluginDescriptorException
      Specified by:
      execute in interface org.apache.maven.tools.plugin.extractor.MojoDescriptorExtractor
      Throws:
      org.apache.maven.tools.plugin.extractor.ExtractionException
      org.apache.maven.plugin.descriptor.InvalidPluginDescriptorException
    • discoverClassesFromSourcesJar

      protected Map<String,com.thoughtworks.qdox.model.JavaClass> discoverClassesFromSourcesJar(org.apache.maven.artifact.Artifact artifact, org.apache.maven.tools.plugin.PluginToolsRequest request, String classifier) throws org.apache.maven.tools.plugin.extractor.ExtractionException
      Throws:
      org.apache.maven.tools.plugin.extractor.ExtractionException
    • populateDataFromJavadoc

      protected void populateDataFromJavadoc(Map<String,MojoAnnotatedClass> mojoAnnotatedClasses, Map<String,com.thoughtworks.qdox.model.JavaClass> javaClassesMap)
      from sources scan to get @since and @deprecated and description of classes and fields.
      Parameters:
      mojoAnnotatedClasses -
      javaClassesMap -
    • discoverClasses

      protected Map<String,com.thoughtworks.qdox.model.JavaClass> discoverClasses(org.apache.maven.tools.plugin.PluginToolsRequest request)
    • discoverClasses

      protected Map<String,com.thoughtworks.qdox.model.JavaClass> discoverClasses(String encoding, org.apache.maven.project.MavenProject project)
    • discoverClasses

      protected Map<String,com.thoughtworks.qdox.model.JavaClass> discoverClasses(String encoding, List<File> sourceDirectories, Set<org.apache.maven.artifact.Artifact> artifacts)
    • findExecuteInParentHierarchy

      protected ExecuteAnnotationContent findExecuteInParentHierarchy(MojoAnnotatedClass mojoAnnotatedClass, Map<String,MojoAnnotatedClass> mojoAnnotatedClasses)
    • getParametersParentHierarchy

      protected Map<String,ParameterAnnotationContent> getParametersParentHierarchy(MojoAnnotatedClass mojoAnnotatedClass, Map<String,ParameterAnnotationContent> parameters, Map<String,MojoAnnotatedClass> mojoAnnotatedClasses)
    • getParametersParent

      protected List<ParameterAnnotationContent> getParametersParent(MojoAnnotatedClass mojoAnnotatedClass, List<ParameterAnnotationContent> parameterAnnotationContents, Map<String,MojoAnnotatedClass> mojoAnnotatedClasses)
    • getComponentsParentHierarchy

      protected Map<String,ComponentAnnotationContent> getComponentsParentHierarchy(MojoAnnotatedClass mojoAnnotatedClass, Map<String,ComponentAnnotationContent> components, Map<String,MojoAnnotatedClass> mojoAnnotatedClasses)
    • getComponentParent

      protected List<ComponentAnnotationContent> getComponentParent(MojoAnnotatedClass mojoAnnotatedClass, List<ComponentAnnotationContent> componentAnnotationContents, Map<String,MojoAnnotatedClass> mojoAnnotatedClasses)
    • getFromProjectReferences

      protected org.apache.maven.project.MavenProject getFromProjectReferences(org.apache.maven.artifact.Artifact artifact, org.apache.maven.project.MavenProject project)