Package io.micronaut.context.visitor
Class ContextConfigurerVisitor
java.lang.Object
io.micronaut.context.visitor.ContextConfigurerVisitor
- All Implemented Interfaces:
Ordered,Toggleable,TypeElementVisitor<ContextConfigurer,Object>
@Internal
public class ContextConfigurerVisitor
extends Object
implements TypeElementVisitor<ContextConfigurer,Object>
This visitor is responsible for generating service files for classes
annotated with
ContextConfigurer.- Since:
- 3.2
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.micronaut.inject.visitor.TypeElementVisitor
TypeElementVisitor.VisitorKind -
Field Summary
Fields inherited from interface io.micronaut.core.order.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidChecks that a class annotated withContextConfigurerdoesn't have any constructor with parameters, which is unsupported.voidvisitClass(ClassElement element, VisitorContext context) Executed when a class is encountered that matches the <C> generic.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.micronaut.core.util.Toggleable
isEnabledMethods inherited from interface io.micronaut.inject.visitor.TypeElementVisitor
finish, getClassType, getSupportedAnnotationNames, getSupportedOptions, query, start, visitConstructor, visitEnumConstant, visitField, visitMethod
-
Constructor Details
-
ContextConfigurerVisitor
public ContextConfigurerVisitor()
-
-
Method Details
-
getVisitorKind
- Specified by:
getVisitorKindin interfaceTypeElementVisitor<ContextConfigurer,Object> - Returns:
- The visitor kind.
-
getElementType
- Specified by:
getElementTypein interfaceTypeElementVisitor<ContextConfigurer,Object>
-
visitClass
Description copied from interface:TypeElementVisitorExecuted when a class is encountered that matches the <C> generic.- Specified by:
visitClassin interfaceTypeElementVisitor<ContextConfigurer,Object> - Parameters:
element- The elementcontext- The visitor context
-
assertNoConstructorForContextAnnotation
Checks that a class annotated withContextConfigurerdoesn't have any constructor with parameters, which is unsupported.- Parameters:
element- the class to check
-