@SupportedOptions(value={"org.robolectric.annotation.processing.shadowPackage","org.robolectric.annotation.processing.shouldInstrumentPackage"}) @SupportedAnnotationTypes(value="org.robolectric.annotation.*") public class RobolectricProcessor extends AbstractProcessor
Annotation processor entry point for Robolectric annotations.
processingEnv
Constructor and Description |
---|
RobolectricProcessor()
Default constructor.
|
RobolectricProcessor(Map<String,String> options)
Constructor to use for testing passing options in.
|
Modifier and Type | Method and Description |
---|---|
SourceVersion |
getSupportedSourceVersion() |
void |
init(ProcessingEnvironment environment) |
boolean |
process(Set<? extends TypeElement> annotations,
RoundEnvironment roundEnv) |
getCompletions, getSupportedAnnotationTypes, getSupportedOptions, isInitialized
public RobolectricProcessor()
Default constructor.
public RobolectricProcessor(Map<String,String> options)
Constructor to use for testing passing options in. Only necessary until compile-testing supports passing options in.
options
- simulated options that would ordinarily be passed in the ProcessingEnvironment
.public void init(ProcessingEnvironment environment)
init
in interface Processor
init
in class AbstractProcessor
public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv)
process
in interface Processor
process
in class AbstractProcessor
public SourceVersion getSupportedSourceVersion()
getSupportedSourceVersion
in interface Processor
getSupportedSourceVersion
in class AbstractProcessor