br.com.objectos.way.code.apt
Class AbstractAnnotationProcessor

java.lang.Object
  extended by javax.annotation.processing.AbstractProcessor
      extended by br.com.objectos.way.code.apt.AbstractAnnotationProcessor
All Implemented Interfaces:
Processor

public abstract class AbstractAnnotationProcessor
extends AbstractProcessor

Author:
marcio.endo@objectos.com.br (Marcio Endo)

Nested Class Summary
protected  class AbstractAnnotationProcessor.CodeCanvasArtifactAction
           
 
Field Summary
protected  Directory sourcePath
           
 
Fields inherited from class javax.annotation.processing.AbstractProcessor
processingEnv
 
Constructor Summary
AbstractAnnotationProcessor()
           
 
Method Summary
protected abstract  Class<? extends Annotation> annotationType()
           
protected  void beforeWrite(CodeCanvasArtifact artifact)
           
 Set<String> getSupportedAnnotationTypes()
           
 SourceVersion getSupportedSourceVersion()
           
protected  void info(String msg)
           
 void init(ProcessingEnvironment processingEnv)
           
protected  String name()
           
 boolean process(Set<? extends TypeElement> typeElements, RoundEnvironment roundEnv)
           
protected  boolean processReturnOnError(Set<? extends TypeElement> typeElements, RoundEnvironment roundEnv, Throwable e)
           
protected  boolean processReturnOnSuccess(Set<? extends TypeElement> typeElements, RoundEnvironment roundEnv)
           
protected abstract  boolean shouldProcessMethods()
           
protected abstract  boolean shouldProcessTypes()
           
protected  List<CodeCanvasArtifact> toArtifactList(TypeInfo typeInfo)
           
protected  List<CodeCanvasArtifact> toArtifactList(TypeInfo typeInfo, MethodInfo methodInfo)
           
 
Methods inherited from class javax.annotation.processing.AbstractProcessor
getCompletions, getSupportedOptions, isInitialized
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sourcePath

protected Directory sourcePath
Constructor Detail

AbstractAnnotationProcessor

public AbstractAnnotationProcessor()
Method Detail

getSupportedAnnotationTypes

public Set<String> getSupportedAnnotationTypes()
Specified by:
getSupportedAnnotationTypes in interface Processor
Overrides:
getSupportedAnnotationTypes in class AbstractProcessor

getSupportedSourceVersion

public SourceVersion getSupportedSourceVersion()
Specified by:
getSupportedSourceVersion in interface Processor
Overrides:
getSupportedSourceVersion in class AbstractProcessor

init

public void init(ProcessingEnvironment processingEnv)
Specified by:
init in interface Processor
Overrides:
init in class AbstractProcessor

process

public boolean process(Set<? extends TypeElement> typeElements,
                       RoundEnvironment roundEnv)
Specified by:
process in interface Processor
Specified by:
process in class AbstractProcessor

annotationType

protected abstract Class<? extends Annotation> annotationType()

shouldProcessMethods

protected abstract boolean shouldProcessMethods()

shouldProcessTypes

protected abstract boolean shouldProcessTypes()

toArtifactList

protected List<CodeCanvasArtifact> toArtifactList(TypeInfo typeInfo)

toArtifactList

protected List<CodeCanvasArtifact> toArtifactList(TypeInfo typeInfo,
                                                  MethodInfo methodInfo)

beforeWrite

protected void beforeWrite(CodeCanvasArtifact artifact)

info

protected void info(String msg)

name

protected String name()

processReturnOnError

protected boolean processReturnOnError(Set<? extends TypeElement> typeElements,
                                       RoundEnvironment roundEnv,
                                       Throwable e)

processReturnOnSuccess

protected boolean processReturnOnSuccess(Set<? extends TypeElement> typeElements,
                                         RoundEnvironment roundEnv)


Copyright © 2014. All rights reserved.