Class WebConfig
java.lang.Object
io.jstach.opt.spring.webflux.example.WebConfig
- All Implemented Interfaces:
org.springframework.web.reactive.config.WebFluxConfigurer
@Configuration
public class WebConfig
extends Object
implements org.springframework.web.reactive.config.WebFluxConfigurer
Configures MVC using
JStachioHttpMessageConverter
to allow returning models
which will be rendered using JStachio runtime.- Author:
- agentgt
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
configureHttpMessageCodecs
(org.springframework.http.codec.ServerCodecConfigurer configurer) viewSetupHandlerInterceptor
(org.springframework.context.ApplicationContext context) Factory to create a bean post processor to registerJStachioModelViewConfigurer
s.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.web.reactive.config.WebFluxConfigurer
addCorsMappings, addFormatters, addResourceHandlers, configureArgumentResolvers, configureContentTypeResolver, configurePathMatching, configureViewResolvers, getMessageCodesResolver, getValidator, getWebSocketService
-
Constructor Details
-
WebConfig
Configures based on the jstachio found by spring- Parameters:
jstachio
- the found jstachio
-
-
Method Details
-
configureHttpMessageCodecs
public void configureHttpMessageCodecs(org.springframework.http.codec.ServerCodecConfigurer configurer) - Specified by:
configureHttpMessageCodecs
in interfaceorg.springframework.web.reactive.config.WebFluxConfigurer
-
viewSetupHandlerInterceptor
@Bean public ViewSetupBeanPostProcessor viewSetupHandlerInterceptor(org.springframework.context.ApplicationContext context) Factory to create a bean post processor to registerJStachioModelViewConfigurer
s.- Parameters:
context
- supplied by spring- Returns:
- a post processor that will configure JStachio Model Views before being rendered.
-