Annotation Type EnableWebMvcExtension
-
@Retention(RUNTIME) @Target(TYPE) @Documented @Import({WebMvcExtensionBeanDefinitionRegistrar.class,WebMvcExtensionConfiguration.class}) @EnableWebExtension public @interface EnableWebMvcExtensionEnable annotation to extend the features of Spring WebMVC- Since:
- 1.0.0
- Author:
- Mercy
- See Also:
EnableWebMvc,EnableWebExtension,WebMvcExtensionBeanDefinitionRegistrar,WebMvcExtensionConfiguration
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.Class<? extends org.springframework.web.servlet.HandlerInterceptor>[]handlerInterceptorsSpecifyHandlerInterceptortypes or its inherited types as Spring beans and then register intoInterceptorRegistry.booleaninterceptHandlerMethodsIndicate whether Spring WebHandlerMethodshould be intercepted.booleanpublishEventsIndicate whether it publishes the Spring Web extension events:HandlerMethodArgumentsResolvedEvent(if enabled)WebEndpointMappingsReadyEvent(if enabled)booleanregisterHandlerInterceptorsIndicate whether theInterceptorRegistryregisters the beans ofHandlerInterceptor.booleanregisterWebEndpointMappingsIndicate whether The Spring Web registers the instances ofWebEndpointMappingthat source from Spring WebMVC, Spring WebFlux or Classical Servlet.RequestContextStrategyrequestContextStrategyIndicate where theRequestAttributesstores.booleanreversedProxyHandlerMappingIndicate whether theReversedProxyHandlerMappingis enabled or not.booleanstoreRequestBodyArgumentIndicate thatRequestAttributesstores theargumentofHandlerMethodthat annotatedRequestBodybooleanstoreResponseBodyReturnValueIndicate thatRequestAttributesstores the return value ofHandlerMethodbefore write as theResponseBody
-
-
-
Element Detail
-
registerWebEndpointMappings
@AliasFor(annotation=io.microsphere.spring.web.annotation.EnableWebExtension.class) boolean registerWebEndpointMappings
Indicate whether The Spring Web registers the instances ofWebEndpointMappingthat source from Spring WebMVC, Spring WebFlux or Classical Servlet.- Returns:
trueas default- See Also:
WebEndpointMapping,WebEndpointMappingResolver,WebEndpointMappingRegistry,WebEndpointMappingFactory,WebEndpointMappingFilter
- Default:
- true
-
-
-
interceptHandlerMethods
@AliasFor(annotation=io.microsphere.spring.web.annotation.EnableWebExtension.class) boolean interceptHandlerMethods
Indicate whether Spring WebHandlerMethodshould be intercepted. Iftrue,HandlerMethodArgumentInterceptorandHandlerMethodInterceptorbeans will be initialized and then be invoked aroundHandlerMethodbeing executed.- Returns:
trueas default- See Also:
HandlerMethodArgumentInterceptor,HandlerMethodInterceptor
- Default:
- true
-
-
-
publishEvents
@AliasFor(annotation=io.microsphere.spring.web.annotation.EnableWebExtension.class) boolean publishEvents
Indicate whether it publishes the Spring Web extension events:- Returns:
trueas default- See Also:
WebEventPublisher,WebEndpointMappingsReadyEvent,HandlerMethodArgumentsResolvedEvent
- Default:
- true
-
-
-
requestContextStrategy
@AliasFor(annotation=io.microsphere.spring.web.annotation.EnableWebExtension.class) RequestContextStrategy requestContextStrategy
Indicate where theRequestAttributesstores.- Returns:
RequestContextStrategy.DEFAULTas default- See Also:
RequestAttributes,RequestContextHolder,RequestContextFilter,RequestContextListener,FrameworkServlet.initContextHolders(HttpServletRequest, LocaleContext, RequestAttributes),RequestContextStrategy
- Default:
- io.microsphere.spring.web.util.RequestContextStrategy.DEFAULT
-
-
-
registerHandlerInterceptors
boolean registerHandlerInterceptors
Indicate whether theInterceptorRegistryregisters the beans ofHandlerInterceptor. If it specifiestrue,handlerInterceptors()method will not work anymore.- Returns:
falseas default- See Also:
WebMvcConfigurer.addInterceptors(InterceptorRegistry),InterceptorRegistry
- Default:
- false
-
-
-
handlerInterceptors
java.lang.Class<? extends org.springframework.web.servlet.HandlerInterceptor>[] handlerInterceptors
SpecifyHandlerInterceptortypes or its inherited types as Spring beans and then register intoInterceptorRegistry.If
registerHandlerInterceptors()istrue, specified types will be ignored.- Returns:
nullas default- See Also:
WebMvcConfigurer.addInterceptors(InterceptorRegistry),InterceptorRegistry
- Default:
- {}
-
-
-
storeRequestBodyArgument
boolean storeRequestBodyArgument
Indicate thatRequestAttributesstores theargumentofHandlerMethodthat annotatedRequestBody- Returns:
falseas default- See Also:
RequestBody,StoringRequestBodyArgumentAdvice,HandlerMethod,WebMvcUtils.getHandlerMethodRequestBodyArgument(HttpServletRequest, Method),RequestAttributesUtils.getHandlerMethodRequestBodyArgument(RequestAttributes, HandlerMethod)
- Default:
- false
-
-
-
storeResponseBodyReturnValue
boolean storeResponseBodyReturnValue
Indicate thatRequestAttributesstores the return value ofHandlerMethodbefore write as theResponseBody- Returns:
falseas default- See Also:
ResponseBody,WebMvcUtils.getHandlerMethodReturnValue(HttpServletRequest, Method),RequestAttributesUtils.getHandlerMethodReturnValue(RequestAttributes, HandlerMethod)
- Default:
- false
-
-
-
reversedProxyHandlerMapping
boolean reversedProxyHandlerMapping
Indicate whether theReversedProxyHandlerMappingis enabled or not.- Returns:
falseas default- See Also:
ReversedProxyHandlerMapping
- Default:
- false
-
-