use of org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter in project spring-data-document-examples by spring-projects.
the class HandlerAdapterConfiguration method annotationMethodHandlerAdapter.
@Bean
public AnnotationMethodHandlerAdapter annotationMethodHandlerAdapter() {
AnnotationMethodHandlerAdapter adapter = new AnnotationMethodHandlerAdapter();
ActionInterceptor[] interceptors = new ActionInterceptor[] { datastoreInterceptor };
//adapter.setActionInterceptors(interceptors);
ConfigurableWebBindingInitializer wbi = new ConfigurableWebBindingInitializer();
wbi.setValidator(getValidator());
wbi.setConversionService(conversionService());
adapter.setWebBindingInitializer(wbi);
adapter.setMessageConverters(getMessageConverters());
adapter.setOrder(-1);
return adapter;
}
Aggregations