protected UrlState determineUrlState(
            final IPortletWindow portletWindow, final WindowState requestedWindowState) {
        // Determine the UrlState based on the WindowState of the targeted portlet
        final WindowState currentWindowState = portletWindow.getWindowState();
        final WindowState urlWindowState =
                requestedWindowState != null ? requestedWindowState : currentWindowState;
        if (WindowState.MAXIMIZED.equals(urlWindowState)) {
            return UrlState.MAX;
        }

        if (IPortletRenderer.DETACHED.equals(urlWindowState)) {
            return UrlState.DETACHED;
        }

        if (IPortletRenderer.EXCLUSIVE.equals(urlWindowState)) {
            return UrlState.EXCLUSIVE;
        }

        if (!WindowState.NORMAL.equals(urlWindowState)
                && !WindowState.MINIMIZED.equals(urlWindowState)) {
            this.logger.warn(
                    "Unknown WindowState '"
                            + urlWindowState
                            + "' specified for portlet window "
                            + portletWindow
                            + ", defaulting to UrlState.NORMAL");
        }

        return UrlState.NORMAL;
    }
protected UrlState determineUrlState ( final IPortletWindow portletWindow , final WindowState requestedWindowState ) { final WindowState currentWindowState = portletWindow . getWindowState ( ) ; final WindowState urlWindowState = requestedWindowState != null ? requestedWindowState : currentWindowState ; if ( WindowState . MAXIMIZED . equals ( urlWindowState ) ) { return UrlState . MAX ; } if ( IPortletRenderer . DETACHED . equals ( urlWindowState ) ) { return UrlState . DETACHED ; } if ( IPortletRenderer . EXCLUSIVE . equals ( urlWindowState ) ) { return UrlState . EXCLUSIVE ; } if ( ! WindowState . NORMAL . equals ( urlWindowState ) && ! WindowState . MINIMIZED . equals ( urlWindowState ) ) { this . logger . warn ( "Unknown WindowState '" + urlWindowState + "' specified for portlet window " + portletWindow + ", defaulting to UrlState.NORMAL" ) ; } return UrlState . NORMAL ; }
Determine the {@link UrlState} to use for the targeted portlet window