org.apache.pluto.portalImpl.core
Class PortalURL

java.lang.Object
  extended by org.apache.pluto.portalImpl.core.PortalURL

public class PortalURL
extends java.lang.Object


Field Summary
private  boolean analyzed
           
private  java.util.HashMap encodedStartControlParameter
           
private  PortalEnvironment environment
           
private static java.lang.String insecureServlet
           
private static java.lang.String secureServlet
           
private  java.util.List startGlobalNavigation
           
private  java.util.List startLocalNavigation
           
private  java.util.HashMap startStateLessControlParameter
           
 
Constructor Summary
PortalURL(HttpServletRequest request)
          Creates and URL pointing to the home of the portal
PortalURL(HttpServletRequest request, Fragment pointTo)
          Creates and URL pointing to the given fragment of the portal
PortalURL(PortalEnvironment env)
          Creates and URL pointing to the home of the portal
 
Method Summary
 void addGlobalNavigation(java.lang.String nav)
          Adds a navigational information pointing to a portal part, e.g.
 void addLocalNavigation(java.lang.String nav)
          Adds a navigational information pointing to a local portal part inside of a global portal part, for example, a portlet on a page.
(package private)  void analyzeControlInformation(PortalControlParameter control)
           
(package private)  void analyzeRequestInformation()
           
 void clearRenderParameters(PortletWindow portletWindow)
           
 java.lang.String getBasePortalURL(HttpServletRequest request)
          Creates and URL pointing to the home of the portal
(package private)  java.util.Map getClonedEncodedStateFullControlParameter()
           
(package private)  java.util.Map getClonedStateLessControlParameter()
           
 java.lang.String getControlParameterAsString(PortalControlParameter controlParam)
           
 java.lang.String getGlobalNavigationAsString()
           
 java.lang.String getLocalNavigationAsString()
           
 java.lang.String getRequestParameterAsString(PortalControlParameter controlParam)
           
 boolean isPartOfGlobalNavigation(java.lang.String nav)
          Returns true if the given string is part of the global navigation of this URL
 boolean isPartOfLocalNavigation(java.lang.String nav)
          Returns true if the given string is part of the local navigation of this URL
 void setLocalNavigation()
          Sets the local navigation.
 void setRenderParameter(PortletWindow portletWindow, java.lang.String name, java.lang.String[] values)
           
 java.lang.String toString()
           
 java.lang.String toString(PortalControlParameter controlParam, java.lang.Boolean p_secure)
           
private  java.lang.String urlEncode(java.lang.String value)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

insecureServlet

private static final java.lang.String insecureServlet

secureServlet

private static final java.lang.String secureServlet

startGlobalNavigation

private java.util.List startGlobalNavigation

startLocalNavigation

private java.util.List startLocalNavigation

encodedStartControlParameter

private java.util.HashMap encodedStartControlParameter

startStateLessControlParameter

private java.util.HashMap startStateLessControlParameter

analyzed

private boolean analyzed

environment

private PortalEnvironment environment
Constructor Detail

PortalURL

public PortalURL(PortalEnvironment env)
Creates and URL pointing to the home of the portal

Parameters:
env - the portal environment

PortalURL

public PortalURL(HttpServletRequest request)
Creates and URL pointing to the home of the portal

Parameters:
request - the servlet request

PortalURL

public PortalURL(HttpServletRequest request,
                 Fragment pointTo)
Creates and URL pointing to the given fragment of the portal

Parameters:
request - the servlet request
pointTo - the fragment to point to
Method Detail

getBasePortalURL

public java.lang.String getBasePortalURL(HttpServletRequest request)
Creates and URL pointing to the home of the portal

Parameters:
request - the servlet request
Returns:
the portal URL

addGlobalNavigation

public void addGlobalNavigation(java.lang.String nav)
Adds a navigational information pointing to a portal part, e.g. PageGroups or Pages

Parameters:
nav - the string pointing to a portal part

setLocalNavigation

public void setLocalNavigation()
Sets the local navigation. Because the local navigation is always handled by the Browser, therefore the local navigation cleared.


addLocalNavigation

public void addLocalNavigation(java.lang.String nav)
Adds a navigational information pointing to a local portal part inside of a global portal part, for example, a portlet on a page.

Parameters:
nav - the string pointing to a local portal part

isPartOfGlobalNavigation

public boolean isPartOfGlobalNavigation(java.lang.String nav)
Returns true if the given string is part of the global navigation of this URL

Parameters:
nav - the string to check
Returns:
true, if the string is part of the navigation

isPartOfLocalNavigation

public boolean isPartOfLocalNavigation(java.lang.String nav)
Returns true if the given string is part of the local navigation of this URL

Parameters:
nav - the string to check
Returns:
true, if the string is part of the navigation

urlEncode

private java.lang.String urlEncode(java.lang.String value)

getGlobalNavigationAsString

public java.lang.String getGlobalNavigationAsString()

getLocalNavigationAsString

public java.lang.String getLocalNavigationAsString()

getControlParameterAsString

public java.lang.String getControlParameterAsString(PortalControlParameter controlParam)

getRequestParameterAsString

public java.lang.String getRequestParameterAsString(PortalControlParameter controlParam)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

toString

public java.lang.String toString(PortalControlParameter controlParam,
                                 java.lang.Boolean p_secure)

getClonedEncodedStateFullControlParameter

java.util.Map getClonedEncodedStateFullControlParameter()

getClonedStateLessControlParameter

java.util.Map getClonedStateLessControlParameter()

analyzeControlInformation

void analyzeControlInformation(PortalControlParameter control)

analyzeRequestInformation

void analyzeRequestInformation()

setRenderParameter

public void setRenderParameter(PortletWindow portletWindow,
                               java.lang.String name,
                               java.lang.String[] values)

clearRenderParameters

public void clearRenderParameters(PortletWindow portletWindow)