@Override public PortletRequestDispatcher getRequestDispatcher(String path) { return wrapped.getRequestDispatcher(path); }
/** * Default resource serving. * <p> * The default implementation of this method does nothing. * <p> * However, if the reserved portlet initialization parameter * {@link #AUTOMATIC_RESOURCE_DISPATCH} * (= "javax.portlet.automaticResourceDispatching") * is set to <code>true</code>, the default * implementation will perform a * <code>PortletRequestDispatcher.forward</code> to the location designated by * the ResourceID of the ResourceRequest. * If no ResourceID is set on the resource URL the default implementation * does nothing. * * @since 2.0 */ public void serveResource(ResourceRequest request, ResourceResponse response) throws PortletException, IOException { String autofwd = getInitParameter(AUTOMATIC_RESOURCE_DISPATCH); if (autofwd != null && autofwd.equalsIgnoreCase("true")) { if (request.getResourceID() != null) { PortletRequestDispatcher rd = getPortletConfig().getPortletContext().getRequestDispatcher( request.getResourceID()); if (rd != null) rd.forward(request, response); } } }
protected PortletRequestDispatcher getPortletRequestDispatcher( ResourceRequest resourceRequest, String path) { PortletConfig portletConfig = getPortletConfig(resourceRequest); PortletContext portletContext = portletConfig.getPortletContext(); return portletContext.getRequestDispatcher(path); }
protected void include( ResourceRequest resourceRequest, ResourceResponse resourceResponse, String jspPath) throws IOException, PortletException { PortletConfig portletConfig = getPortletConfig(resourceRequest); PortletContext portletContext = portletConfig.getPortletContext(); PortletRequestDispatcher portletRequestDispatcher = portletContext.getRequestDispatcher(jspPath); portletRequestDispatcher.include(resourceRequest, resourceResponse); }
protected void include( String path, PortletRequest portletRequest, PortletResponse portletResponse, String lifecycle) throws IOException, PortletException { HttpServletRequest httpServletRequest = PortalUtil.getHttpServletRequest(portletRequest); PortletContext portletContext = (PortletContext)httpServletRequest.getAttribute( MVCRenderConstants. PORTLET_CONTEXT_OVERRIDE_REQUEST_ATTIBUTE_NAME_PREFIX + path); if (portletContext == null) { portletContext = getPortletContext(); } PortletRequestDispatcher portletRequestDispatcher = portletContext.getRequestDispatcher(path); if (portletRequestDispatcher == null) { _log.error(path + " is not a valid include"); } else { checkPath(path); portletRequestDispatcher.include(portletRequest, portletResponse); } if (clearRequestParameters) { if (lifecycle.equals(PortletRequest.RENDER_PHASE)) { portletResponse.setProperty( "clear-request-parameters", Boolean.TRUE.toString()); } } }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); PortletContext pc = portletConfig.getPortletContext(); normalView = pc.getRequestDispatcher("/WEB-INF/view/jmsmanager/server/connector/normal.jsp"); maximizedView = pc.getRequestDispatcher("/WEB-INF/view/jmsmanager/server/connector/maximized.jsp"); helpView = pc.getRequestDispatcher("/WEB-INF/view/jmsmanager/server/connector/help.jsp"); editView = pc.getRequestDispatcher("/WEB-INF/view/jmsmanager/server/connector/editGeneric.jsp"); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); kernel = KernelRegistry.getSingleKernel(); PortletContext context = portletConfig.getPortletContext(); normalView = context.getRequestDispatcher(NORMAL_VIEW); detailView = context.getRequestDispatcher(DETAIL_VIEW); helpView = context.getRequestDispatcher(HELP_VIEW); addView = context.getRequestDispatcher(ADD_VIEW); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); kernel = KernelRegistry.getSingleKernel(); ctx = portletConfig.getPortletContext(); normalView = ctx.getRequestDispatcher("/WEB-INF/view/repository/normal.jsp"); helpView = ctx.getRequestDispatcher("/WEB-INF/view/repository/help.jsp"); usageView = ctx.getRequestDispatcher("/WEB-INF/view/repository/usage.jsp"); }
/** * Portlet is being placed into service */ public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); PortletContext pc = portletConfig.getPortletContext(); viewLDAPServerView = pc.getRequestDispatcher(VIEWLDAPSERVER_JSP); helpView = pc.getRequestDispatcher(HELP_JSP); }
/** * Portlet is being placed into service */ public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); PortletContext pc = portletConfig.getPortletContext(); viewJMXServerView = pc.getRequestDispatcher(VIEWJMXSERVER_JSP); helpView = pc.getRequestDispatcher(HELP_JSP); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); normalView = portletConfig.getPortletContext().getRequestDispatcher( NORMALVIEW_JSP); maximizedView = portletConfig.getPortletContext().getRequestDispatcher( MAXIMIZEDVIEW_JSP); helpView = portletConfig.getPortletContext().getRequestDispatcher( HELPVIEW_JSP); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); normalView = portletConfig.getPortletContext().getRequestDispatcher( NORMALVIEW_JSP); maximizedView = portletConfig.getPortletContext().getRequestDispatcher( MAXIMIZEDVIEW_JSP); helpView = portletConfig.getPortletContext().getRequestDispatcher( HELPVIEW_JSP); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); helpView = portletConfig.getPortletContext().getRequestDispatcher("/WEB-INF/view/obrmanager/OBRManager.jsp"); obrManagerView = portletConfig.getPortletContext().getRequestDispatcher("/WEB-INF/view/obrmanager/OBRManager.jsp"); resolveView = portletConfig.getPortletContext().getRequestDispatcher("/WEB-INF/view/obrmanager/resolve.jsp"); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); normalView = portletConfig.getPortletContext().getRequestDispatcher( VIEW_JSP); helpView = portletConfig.getPortletContext().getRequestDispatcher( HELPVIEW_JSP); }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); normalView = portletConfig.getPortletContext().getRequestDispatcher( "/WEB-INF/view/servermanager/normal.jsp"); shutdownView = portletConfig.getPortletContext().getRequestDispatcher( "/WEB-INF/view/servermanager/shutdown.jsp"); helpView = portletConfig.getPortletContext().getRequestDispatcher( "/WEB-INF/view/servermanager/help.jsp"); kernel = KernelRegistry.getSingleKernel(); }
protected void processMimeResponseRequest(PortletRequest request, MimeResponse response, String hstDispUrl, HstPortletResponseState portletResponseState) throws PortletException, IOException { PortletRequestDispatcher dispatcher = this.portletContext.getRequestDispatcher(hstDispUrl); if (dispatcher != null) { dispatch(dispatcher, request, response, true); portletResponseState.flush(); } }
public void init(PortletConfig portletConfig) throws PortletException { super.init(portletConfig); kernel = KernelRegistry.getSingleKernel(); normalView = portletConfig.getPortletContext().getRequestDispatcher("/WEB-INF/view/configmanager/normal.jsp"); maximizedView = portletConfig.getPortletContext().getRequestDispatcher("/WEB-INF/view/configmanager/maximized.jsp"); helpView = portletConfig.getPortletContext().getRequestDispatcher("/WEB-INF/view/configmanager/help.jsp"); moduleType = getInitParameter(CONFIG_INIT_PARAM); //Only show the displayNames for the web applications showDisplayName = ConfigurationModuleType.WAR.getName().equalsIgnoreCase(moduleType); }
@Override protected void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { final PortletSession session = request.getPortletSession(); final boolean inServantMode = ServantUtil.isInServantMode(request); request.setAttribute("inServantMode", inServantMode); request.setAttribute(VALUE_ATTR, session.getAttribute(VALUE_ATTR)); final PortletContext context = this.getPortletContext(); final PortletRequestDispatcher prd = context.getRequestDispatcher(DEFAULT_VIEW); prd.include(request, response); }
@Override public void serveResource(ResourceRequest request, ResourceResponse response) throws PortletException, IOException { if (request.getResourceID() != null && resolveEmbeddedDispatchURL(request,response) != null) { // only handle serveResource by ResourceID parameter HstResponseState portletResponseState = new HstPortletResponseState(request, response); PortletRequestDispatcher dispatcher = getPortletContext().getRequestDispatcher(request.getResourceID()); if (dispatcher != null) { dispatcher.include(request, response); portletResponseState.flush(); } } }
protected void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { PortletSession porletSession=request.getPortletSession(); request.setAttribute(ERROR_MESSAGE_ATTRIBUTE_NAME,porletSession.getAttribute(ERROR_MESSAGE_ATTRIBUTE_NAME)); request.setAttribute(INFO_MESSAGE_ATTRIBUTE_NAME,porletSession.getAttribute(INFO_MESSAGE_ATTRIBUTE_NAME)); PortletContext context = getPortletContext(); PortletRequestDispatcher prd = context.getRequestDispatcher(DEFAULT_VIEW); response.setContentType("text/html"); prd.include(request,response); }