<bean id="portletModeHandlerMapping" class="org.springframework.web.portlet.handler.PortletModeHandlerMapping"> <property name="portletModeMap"> <map> <entry key="view" value-ref="oneController" /> </map> </property> <property name="interceptors"> <list> <ref bean="pruebaCustomInterceptor" /> </list> </property> </bean> <bean id="pruebaCustomInterceptor" class="es.pruebas.portlet.cve.controller.CustomInterceptor"/>
The bean "oneController" is just a MVC Portlet controller, a class annotated with @Controller.
public class CustomInterceptor extends org.springframework.web.portlet.handler.HandlerInterceptorAdapter { @Override protected boolean preHandle(final PortletRequest request, final PortletResponse response, final Object handler) throws Exception { return super.preHandle(request, response, handler); } }
No hay comentarios:
Publicar un comentario