1 16 17 package org.springframework.web.portlet.mvc; 18 19 import javax.portlet.ActionRequest; 20 import javax.portlet.ActionResponse; 21 import javax.portlet.PortletException; 22 import javax.portlet.RenderRequest; 23 import javax.portlet.RenderResponse; 24 25 import org.springframework.web.portlet.ModelAndView; 26 27 41 public class PortletModeNameViewController implements Controller { 42 43 public void handleActionRequest(ActionRequest request, ActionResponse response) throws Exception { 44 throw new PortletException("PortletModeNameViewController does not handle action requests"); 45 } 46 47 public ModelAndView handleRenderRequest(RenderRequest request, RenderResponse response) { 48 return new ModelAndView(request.getPortletMode().toString()); 49 } 50 51 } 52 | Popular Tags |