Class AnnotationProcessorImpl

  • All Implemented Interfaces:
    javax.annotation.processing.Processor

    @SupportedAnnotationTypes("*")
    @MetaInfServices(javax.annotation.processing.Processor.class)
    public class AnnotationProcessorImpl
    extends javax.annotation.processing.AbstractProcessor
    Creates indices of Indexed annotations.
    Author:
    Kohsuke Kawaguchi
    • Field Summary

      • Fields inherited from class javax.annotation.processing.AbstractProcessor

        processingEnv
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void execute​(java.util.Set<? extends javax.lang.model.element.TypeElement> annotations, javax.annotation.processing.RoundEnvironment roundEnv)  
      protected javax.lang.model.element.AnnotationMirror findAnnotationOn​(javax.lang.model.element.Element e, java.lang.String name)  
      protected javax.lang.model.util.Elements getElementUtils()  
      javax.lang.model.SourceVersion getSupportedSourceVersion()  
      protected boolean isIndexing​(javax.lang.model.element.TypeElement ann)
      Given a TypeElement that represents the annotation class, determines whether to index this annotation.
      boolean process​(java.util.Set<? extends javax.lang.model.element.TypeElement> annotations, javax.annotation.processing.RoundEnvironment roundEnv)  
      • Methods inherited from class javax.annotation.processing.AbstractProcessor

        getCompletions, getSupportedAnnotationTypes, getSupportedOptions, init, isInitialized
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AnnotationProcessorImpl

        public AnnotationProcessorImpl()
    • Method Detail

      • getElementUtils

        protected javax.lang.model.util.Elements getElementUtils()
      • process

        public boolean process​(java.util.Set<? extends javax.lang.model.element.TypeElement> annotations,
                               javax.annotation.processing.RoundEnvironment roundEnv)
        Specified by:
        process in interface javax.annotation.processing.Processor
        Specified by:
        process in class javax.annotation.processing.AbstractProcessor
      • getSupportedSourceVersion

        public javax.lang.model.SourceVersion getSupportedSourceVersion()
        Specified by:
        getSupportedSourceVersion in interface javax.annotation.processing.Processor
        Overrides:
        getSupportedSourceVersion in class javax.annotation.processing.AbstractProcessor
      • execute

        protected void execute​(java.util.Set<? extends javax.lang.model.element.TypeElement> annotations,
                               javax.annotation.processing.RoundEnvironment roundEnv)
      • findAnnotationOn

        protected javax.lang.model.element.AnnotationMirror findAnnotationOn​(javax.lang.model.element.Element e,
                                                                             java.lang.String name)
      • isIndexing

        protected boolean isIndexing​(javax.lang.model.element.TypeElement ann)
        Given a TypeElement that represents the annotation class, determines whether to index this annotation.