Package org.jasig.portal.api.portlet

Examples of org.jasig.portal.api.portlet.PortletDelegationLocator


    public int doEndTag() throws JspException {
        //From portlet:defineObjects
        final RenderRequest renderRequest = (RenderRequest)this.pageContext.getAttribute("renderRequest");
        final RenderResponse renderResponse = (RenderResponse)this.pageContext.getAttribute("renderResponse");
       
        final PortletDelegationLocator portletDelegationLocator = (PortletDelegationLocator)renderRequest.getAttribute(PortletDelegationLocator.PORTLET_DELECATION_LOCATOR_ATTR);
       
        final String sessionKey = this.sessionKeyPrefix + this.fname;

        final PortletSession portletSession = renderRequest.getPortletSession();
        IPortletWindowId portletWindowId = (IPortletWindowId)portletSession.getAttribute(sessionKey);

        final PortletDelegationDispatcher portletDelegationDispatcher;
        final DelegateState delegateState;
        //No id in session, create a new dispatcher
        if (portletWindowId == null) {
            portletDelegationDispatcher = portletDelegationLocator.createRequestDispatcher(renderRequest, this.fname);
            portletWindowId = portletDelegationDispatcher.getPortletWindowId();
            portletSession.setAttribute(sessionKey, portletWindowId);

            final PortletMode portletMode = this.portletMode == null ? null : new PortletMode(this.portletMode);
            final WindowState windowState = this.windowState == null ? null : new WindowState(this.windowState);
           
            delegateState = new DelegateState(portletMode, windowState);
        }
        //id in session, get the old dispatcher
        else {
            portletDelegationDispatcher = portletDelegationLocator.getRequestDispatcher(renderRequest, portletWindowId);
            delegateState = null;
        }

        final DelegationRequest delegationRequest = new DelegationRequest();
        delegationRequest.setDelegateState(delegateState);
View Full Code Here


    public int doEndTag() throws JspException {
        //From portlet:defineObjects
        final RenderRequest renderRequest = (RenderRequest)this.pageContext.getAttribute("renderRequest");
        final RenderResponse renderResponse = (RenderResponse)this.pageContext.getAttribute("renderResponse");
       
        final PortletDelegationLocator portletDelegationLocator = (PortletDelegationLocator)renderRequest.getAttribute(PortletDelegationLocator.PORTLET_DELECATION_LOCATOR_ATTR);
       
        final String sessionKey = this.sessionKeyPrefix + this.fname;

        final PortletSession portletSession = renderRequest.getPortletSession();
        IPortletWindowId portletWindowId = (IPortletWindowId)portletSession.getAttribute(sessionKey);

        final PortletDelegationDispatcher portletDelegationDispatcher;
        final DelegateState delegateState;
        //No id in session, create a new dispatcher
        if (portletWindowId == null) {
            portletDelegationDispatcher = portletDelegationLocator.createRequestDispatcher(renderRequest, this.fname);
            portletWindowId = portletDelegationDispatcher.getPortletWindowId();
            portletSession.setAttribute(sessionKey, portletWindowId);

            final PortletMode portletMode = PortletUtils.getPortletMode(this.portletMode);
            final WindowState windowState = PortletUtils.getWindowState(this.windowState);
           
            delegateState = new DelegateState(portletMode, windowState);
        }
        //id in session, get the old dispatcher
        else {
            portletDelegationDispatcher = portletDelegationLocator.getRequestDispatcher(renderRequest, portletWindowId);
            delegateState = null;
        }

        final DelegationRequest delegationRequest = new DelegationRequest();
        delegationRequest.setDelegateState(delegateState);
View Full Code Here

TOP

Related Classes of org.jasig.portal.api.portlet.PortletDelegationLocator

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.