Package org.apache.pluto.container

Examples of org.apache.pluto.container.PortletRequestContext


        PortletRequestContextService rcService = getContainerServices().getPortletRequestContextService();
        PortletEnvironmentService envService = getContainerServices().getPortletEnvironmentService();
        PortletInvokerService invoker = getContainerServices().getPortletInvokerService();

        PortletRequestContext requestContext = rcService.getPortletEventRequestContext(this, request, response, portletWindow);
        PortletEventResponseContext responseContext = rcService.getPortletEventResponseContext(this, request, response, portletWindow);
        EventRequest portletRequest = envService.createEventRequest(requestContext, responseContext, event);
        EventResponse portletResponse = envService.createEventResponse(responseContext);

        FilterManager filterManager = filterInitialisation(portletWindow,PortletRequest.EVENT_PHASE);
View Full Code Here


                needsFlushAfterForward = true;
                ((MimeResponse)response).resetBuffer();
            }
        }
       
        PortletRequestContext requestContext = (PortletRequestContext)request.getAttribute(PortletInvokerService.REQUEST_CONTEXT);
        HttpSession session = null;
       
        // PLT.10.4.3. Proxied session is created and passed if javax.portlet.servletDefaultSessionScope == PORTLET_SCOPE
        if (isPortletScopeSessionConfigured(requestContext))
        {
            String portletWindowId = requestContext.getPortletWindow().getId().getStringId();
            session = ServletPortletSessionProxy.createProxy(requestContext.getServletRequest(), portletWindowId);
        }
       
        HttpServletPortletRequestWrapper req = new HttpServletPortletRequestWrapper(requestContext.getServletRequest(),
                                                                                    requestContext.getServletContext(),
                                                                                    session,
                                                                                    request,
                                                                                    included,
                                                                                    namedDispatch);
        HttpServletPortletResponseWrapper res = new HttpServletPortletResponseWrapper(requestContext.getServletResponse(),
                                                                                      request,
                                                                                      response,
                                                                                      included);
        try
        {
            request.setAttribute(PortletInvokerService.PORTLET_CONFIG, requestContext.getPortletConfig());
            request.setAttribute(PortletInvokerService.PORTLET_REQUEST, request);
            request.setAttribute(PortletInvokerService.PORTLET_RESPONSE, response);
           
            if (!included && req.isForwardingPossible())
            {
View Full Code Here

        final PortletRequest portletRequest = (PortletRequest)request.getAttribute(PortletInvokerService.PORTLET_REQUEST);

        final PortletResponse portletResponse = (PortletResponse)request.getAttribute(PortletInvokerService.PORTLET_RESPONSE);

        final PortletRequestContext requestContext = (PortletRequestContext)portletRequest.getAttribute(PortletInvokerService.REQUEST_CONTEXT);
        final PortletResponseContext responseContext = (PortletResponseContext)portletRequest.getAttribute(PortletInvokerService.RESPONSE_CONTEXT);

        final FilterManager filterManager = (FilterManager)request.getAttribute(PortletInvokerService.FILTER_MANAGER);

        request.removeAttribute(PortletInvokerService.METHOD_ID);
        request.removeAttribute(PortletInvokerService.PORTLET_REQUEST);
        request.removeAttribute(PortletInvokerService.PORTLET_RESPONSE);
        request.removeAttribute(PortletInvokerService.FILTER_MANAGER);

        requestContext.init(portletConfig, getServletContext(), request, response);
        responseContext.init(request, response);

        PortletWindow window = requestContext.getPortletWindow();

        PortletInvocationEvent event = new PortletInvocationEvent(portletRequest, window, methodId.intValue());

        notify(event, true, null);
View Full Code Here

        }

        @Override
        public PortletPreferences getPreferences() {
            if (this.portletPreferences == null) {
                final PortletRequestContext requestContext = this.getRequestContext();
                this.portletPreferences = portletPreferencesFactory.createPortletPreferences(requestContext, false);
            }
            return this.portletPreferences;
        }
View Full Code Here

        }

        @Override
        public PortletPreferences getPreferences() {
            if (this.portletPreferences == null) {
                final PortletRequestContext requestContext = this.getRequestContext();
                this.portletPreferences = portletPreferencesFactory.createPortletPreferences(requestContext, false);
            }
            return this.portletPreferences;
        }
View Full Code Here

        }

        @Override
        public PortletPreferences getPreferences() {
            if (this.portletPreferences == null) {
                final PortletRequestContext requestContext = this.getRequestContext();
                this.portletPreferences = portletPreferencesFactory.createPortletPreferences(requestContext, true);
            }
            return this.portletPreferences;
        }
View Full Code Here

        }

        @Override
        public PortletPreferences getPreferences() {
            if (this.portletPreferences == null) {
                final PortletRequestContext requestContext = this.getRequestContext();
                this.portletPreferences = portletPreferencesFactory.createPortletPreferences(requestContext, false);
            }
            return this.portletPreferences;
        }
View Full Code Here

    {       
        PortletWindow window = Jetspeed.getCurrentRequestContext().getCurrentPortletWindow();
        HttpServletRequest req = (HttpServletRequest)window.getAttribute(SERVLET_REQUEST);
        if (req == null)
        {
            PortletRequestContext rc = window.getPortletRequestContext();
            req = requestDispatcherService.getRequestWrapper(rc.getServletContext(),
                                                             rc.getServletRequest(),
                                                             request,
                                                             null,
                                                             true,
                                                             false);
            req.setAttribute(ContainerConstants.PORTLET_CONFIG, rc.getPortletConfig());
            req.setAttribute(ContainerConstants.PORTLET_REQUEST, window.getPortletRequest());
            req.setAttribute(ContainerConstants.PORTLET_RESPONSE, window.getPortletResponse());
            window.setAttribute(SERVLET_REQUEST, req);
        }
        return req;
View Full Code Here

        PortletWindow window = Jetspeed.getCurrentRequestContext().getCurrentPortletWindow();
        HttpServletResponse res = (HttpServletResponse)window.getAttribute(SERVLET_RESPONSE);
        if (res == null)
        {
            boolean included = window.getAttribute(PortalReservedParameters.PORTLET_CONTAINER_INVOKER_USE_FORWARD) == null;
            PortletRequestContext rc = window.getPortletRequestContext();
            res = requestDispatcherService.getResponseWraper(rc.getServletContext(),
                                                             rc.getServletResponse(),
                                                             window.getPortletRequest(),
                                                             response,
                                                             included);
            if (PortletWindow.Action.RENDER == window.getAction() && !included)
            {
View Full Code Here

TOP

Related Classes of org.apache.pluto.container.PortletRequestContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.