Class ViewResolverRegistry
java.lang.Object
org.springframework.web.reactive.config.ViewResolverRegistry
Assist with the configuration of a chain of 
ViewResolver's supporting
 different template mechanisms.
 In addition, you can also configure defaultViews for rendering according to the requested content type, e.g.
 JSON, XML, etc.
- Since:
- 5.0
- Author:
- Rossen Stoyanchev, Sebastien Deleuze
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoiddefaultViews(View... defaultViews) Set default views associated with any view name and selected based on the best match for the requested content type.Register aFreeMarkerViewResolverwith a ".ftl" suffix.protected intgetOrder()protected List<ViewResolver>booleanWhether any view resolvers have been registered.voidorder(int order) Set the order for theViewResolutionResultHandler.Register a script template view resolver with an empty default view name prefix and suffix.voidviewResolver(ViewResolver viewResolver) Register aViewResolverbean instance.
- 
Constructor Details- 
ViewResolverRegistry
 
- 
- 
Method Details- 
freeMarkerRegister aFreeMarkerViewResolverwith a ".ftl" suffix.Note that you must also configure FreeMarker by adding a FreeMarkerConfigurerbean.
- 
scriptTemplateRegister a script template view resolver with an empty default view name prefix and suffix.Note that you must also configure script templating by adding a ScriptTemplateConfigurerbean.- Since:
- 5.0.4
 
- 
viewResolverRegister aViewResolverbean instance. This may be useful to configure a 3rd party resolver implementation or as an alternative to other registration methods in this class when they don't expose some more advanced property that needs to be set.
- 
defaultViewsSet default views associated with any view name and selected based on the best match for the requested content type.Use HttpMessageWriterViewto adapt and use any existingHttpMessageWriter(e.g. JSON, XML) as aView.
- 
hasRegistrationspublic boolean hasRegistrations()Whether any view resolvers have been registered.
- 
orderpublic void order(int order) Set the order for theViewResolutionResultHandler.By default this property is not set, which means the result handler is ordered at Ordered.LOWEST_PRECEDENCE.
- 
getOrderprotected int getOrder()
- 
getViewResolvers
- 
getDefaultViews
 
-