Package dagger.android.processor
Class AndroidProcessor
java.lang.Object
javax.annotation.processing.AbstractProcessor
androidx.room.compiler.processing.javac.JavacBasicAnnotationProcessor
dagger.android.processor.AndroidProcessor
- All Implemented Interfaces:
androidx.room.compiler.processing.XBasicAnnotationProcessor,Processor
@IncrementalAnnotationProcessor(ISOLATING)
@AutoService(javax.annotation.processing.Processor.class)
public final class AndroidProcessor
extends androidx.room.compiler.processing.javac.JavacBasicAnnotationProcessor
An annotation processor to verify usage of
dagger.android code.
Additionally, if -Adagger.android.experimentalUseStringKeys is passed to the
compilation, a file will be generated to support obfuscated injected Android types used with
@AndroidInjectionKey. The fact that this is generated is deliberate: not all versions of
ProGuard/R8 support -identifiernamestring, so we can't include a ProGuard file in the
dagger-android artifact Instead, we generate the file in META-INF/proguard only when
users enable the flag. They should only be enabling it if their shrinker supports those files,
and any version that does so will also support -identifiernamestring. This was added to
R8 in May
2018.
-
Field Summary
Fields inherited from class javax.annotation.processing.AbstractProcessor
processingEnv -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal com.google.common.collect.ImmutableSet<String>voidinitialize(androidx.room.compiler.processing.XProcessingEnv env) Iterable<androidx.room.compiler.processing.XProcessingStep>Methods inherited from class androidx.room.compiler.processing.javac.JavacBasicAnnotationProcessor
getSupportedAnnotationTypes, getXProcessingEnv, init, processMethods inherited from class javax.annotation.processing.AbstractProcessor
getCompletions, isInitializedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface androidx.room.compiler.processing.XBasicAnnotationProcessor
postRound, preRound
-
Constructor Details
-
AndroidProcessor
public AndroidProcessor()
-
-
Method Details
-
initialize
public void initialize(androidx.room.compiler.processing.XProcessingEnv env) -
processingSteps
-
getSupportedOptions
- Specified by:
getSupportedOptionsin interfaceProcessor- Overrides:
getSupportedOptionsin classAbstractProcessor
-
getSupportedSourceVersion
- Specified by:
getSupportedSourceVersionin interfaceProcessor- Overrides:
getSupportedSourceVersionin classAbstractProcessor
-