Package org.apache.jetspeed.container.state

Examples of org.apache.jetspeed.container.state.NavigationalState


     */
    public WindowState getWindowState() throws Exception
    {
        try
        {
            NavigationalState nav = getRequestContext().getPortalURL().getNavigationalState();
            return nav.getState(windowAccess.getPortletWindow(getCurrentFragment()));
        }
        catch (Exception e)
        {
            handleError(e, e.toString(), getCurrentFragment());
            return null;
View Full Code Here


     * @throws Exception
     */
    public PortletMode getPortletMode() throws Exception
    {

        NavigationalState nav = getRequestContext().getPortalURL().getNavigationalState();
        try
        {
            return nav.getMode(windowAccess.getPortletWindow(getCurrentFragment()));
        }
        catch (FailedToRetrievePortletWindow e)
        {
            handleError(e, e.toString(), getCurrentFragment());
            return null;
View Full Code Here

        }

        ///////////////////////////////////////////////////////////////////////////////////////////////
        ContentDispatcher dispatcher = renderer.getDispatcher(context, (strategy == STRATEGY_PARALLEL));
        // handle maximized state
        NavigationalState nav = context.getPortalURL().getNavigationalState();
        PortletWindow window = nav.getMaximizedWindow();
        if (null != window)
        {
            renderMaximizedWindow(context, page, root, window);
        }
        else
View Full Code Here

            engine.service(context);
           
            PortalURL url = context.getPortalURL();
            if (url != null)
            {
                NavigationalState state = url.getNavigationalState();               
                PortletWindow actionWindow = state.getPortletWindowOfAction();
                if (actionWindow == null)
                {
                    Iterator windows = state.getWindowIdIterator();
                    while (windows.hasNext())
                    {
                        String windowId = (String)windows.next();
                        PortletMode mode = state.getMode(windowId);
                        WindowState wstate = state.getState(windowId);
                        if (wstate != null || mode != null)
                        {
                            String windowState = "";
                            if (wstate != null)
                                windowState = wstate.toString();
                           
                            String portletMode = "";
                            if (mode != null)
                                portletMode = mode.toString();
                           
                            Portlets portlets = ((JetspeedRunData)data).getProfile().getDocument().getPortlets();
                            traverse(portlets, windowId, windowState, portletMode, (JetspeedRunData)data);                           
                        }
                    }
                   
                }
                if (actionWindow != null)
                {
                    String windowId = actionWindow.getId().toString();
                    //String windowId = nav.getWindowIdFromKey(state[0]);
                    //System.out.println("got token = " + state[0]+ ", window id = " + windowId + ", action = " + state[1]);
                    Portlets portlets = ((JetspeedRunData)data).getProfile().getDocument().getPortlets();
                    //traverse(portlets, windowId, state[1], (JetspeedRunData)data);
                    String windowState = state.getState(actionWindow).toString();
                    if (windowState == null)
                    {
                        windowState = "";
                    }
                    PortletMode mode = state.getMode(actionWindow);
                    String portletMode = "";
                    if (mode != null)
                        portletMode = mode.toString();
                   
                    traverse(portlets, windowId, windowState, portletMode, (JetspeedRunData)data);
View Full Code Here

        {
            return super.buildActionList(rundata, portlet);
        }
        PortletMode mode2 = PortletMode.VIEW;
        WindowState state2 = WindowState.NORMAL;
        NavigationalState nav = fusion.getNavigationalState(jdata);
        if (nav == null)
        {
            mode2 = PortletMode.VIEW;
            state2 = WindowState.NORMAL;
        }
        else
        {
            mode2 = nav.getMode(window);
            state2 = nav.getState(window);
        }

        int m = jdata.getMode();
        System.out.println("j1 mode = " + m);
       
View Full Code Here

    }

   
    public MutableNavigationalState getNavigationalState(JetspeedRunData data)
    {
        NavigationalState ns = null;
        RequestContext context = (RequestContext) data.getRequest().getAttribute(FUSION_NAV_STATE);
        if (context != null)
        {
            PortalURL url = context.getPortalURL();
            if (url != null)
View Full Code Here

        if (root == null)
        {
            throw new JetspeedException("No root ContentFragment found in ContentPage");
        }
        // handle maximized state
        NavigationalState nav = context.getPortalURL().getNavigationalState();
        PortletWindow window = nav.getMaximizedWindow();
        if (null != window)
        {
            renderMaximizedWindow(context, page, root, window);
        }
        else
View Full Code Here

        if (root == null)
        {
            throw new JetspeedException("No root ContentFragment found in ContentPage");
        }
        // handle maximized state
        NavigationalState nav = context.getPortalURL().getNavigationalState();
        PortletWindow window = nav.getMaximizedWindow();
        if (null != window)
        {
            renderMaximizedWindow(context, page, root, window);
        }
        else
View Full Code Here

     */
    public WindowState getWindowState() throws Exception
    {
        try
        {
            NavigationalState nav = getRequestContext().getPortalURL().getNavigationalState();
            return nav.getState(windowAccess.getPortletWindow(getCurrentFragment()));
        }
        catch (Exception e)
        {
            handleError(e, e.toString(), getCurrentFragment());
            return null;
View Full Code Here

     */
    public WindowState getMappedWindowState() throws Exception
    {
        try
        {
            NavigationalState nav = getRequestContext().getPortalURL().getNavigationalState();
            return nav.getMappedState(windowAccess.getPortletWindow(getCurrentFragment()));
        }
        catch (Exception e)
        {
            handleError(e, e.toString(), getCurrentFragment());
            return null;
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.container.state.NavigationalState

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.