Class ApiAnnotationProcessor
java.lang.Object
javax.annotation.processing.AbstractProcessor
org.opensearch.common.annotation.processor.ApiAnnotationProcessor
- All Implemented Interfaces:
Processor
@InternalApi
@SupportedAnnotationTypes("org.opensearch.common.annotation.*")
public class ApiAnnotationProcessor
extends AbstractProcessor
The annotation processor for API related annotations:
DeprecatedApi, ExperimentalApi,
InternalApi and PublicApi.
The checks are built on top of the following rules:
- introspect each type annotated with
PublicApi,DeprecatedApiorExperimentalApi, filtering out package-private declarations - make sure those leak only
PublicApi,DeprecatedApiorExperimentalApitypes as well (exceptions, method return values, method arguments, method generic type arguments, class generic type arguments, annotations) - recursively follow the type introspection chains to enforce the rules down the line
-
Field Summary
Fields inherited from class javax.annotation.processing.AbstractProcessor
processingEnv -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanprocess(Set<? extends TypeElement> annotations, RoundEnvironment round) Methods inherited from class javax.annotation.processing.AbstractProcessor
getCompletions, getSupportedAnnotationTypes, init, isInitialized
-
Constructor Details
-
ApiAnnotationProcessor
public ApiAnnotationProcessor()
-
-
Method Details
-
getSupportedSourceVersion
- Specified by:
getSupportedSourceVersionin interfaceProcessor- Overrides:
getSupportedSourceVersionin classAbstractProcessor
-
getSupportedOptions
- Specified by:
getSupportedOptionsin interfaceProcessor- Overrides:
getSupportedOptionsin classAbstractProcessor
-
process
- Specified by:
processin interfaceProcessor- Specified by:
processin classAbstractProcessor
-