org.apache.jetspeed.container.state.impl
Class JetspeedNavigationalStateComponent

java.lang.Object
  extended by org.apache.jetspeed.container.state.impl.JetspeedNavigationalStateComponent
All Implemented Interfaces:
NavigationalStateComponent, org.springframework.beans.factory.BeanFactoryAware

public class JetspeedNavigationalStateComponent
extends java.lang.Object
implements NavigationalStateComponent, org.springframework.beans.factory.BeanFactoryAware

JetspeedNavigationalStateComponent

Version:
$Id: JetspeedNavigationalStateComponent.java 517124 2007-03-12 08:10:25Z ate $
Author:
David Sean Taylor

Constructor Summary
JetspeedNavigationalStateComponent(java.lang.String navBeanName, java.lang.String urlBeanName, PortalContext portalContext, java.lang.String desktopUrlBeanName)
           
 
Method Summary
 NavigationalState create()
           create
 PortalURL createDesktopURL(javax.servlet.http.HttpServletRequest request, java.lang.String characterEncoding)
          Creates a Desktop Portal URL representing the URL of the request.
 PortalURL createURL(javax.servlet.http.HttpServletRequest request, java.lang.String characterEncoding)
           createURL
 javax.portlet.PortletMode lookupPortletMode(java.lang.String name)
          Given a portlet mode name, look up its object.
 javax.portlet.WindowState lookupWindowState(java.lang.String name)
          Given a window state name, look up its object.
 void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JetspeedNavigationalStateComponent

public JetspeedNavigationalStateComponent(java.lang.String navBeanName,
                                          java.lang.String urlBeanName,
                                          PortalContext portalContext,
                                          java.lang.String desktopUrlBeanName)
                                   throws java.lang.ClassNotFoundException
Parameters:
navBeanName - name of the bean implementing Navigational State instances
urlBeanName - name of the bean implementing Portal URL instances
navCodecBeanName - name of the bean implementing Navigational State Codec instance
Throws:
java.lang.ClassNotFoundException - if navClassName or urlClassName do not exist.
Method Detail

create

public NavigationalState create()
                         throws FailedToCreateNavStateException

create

Specified by:
create in interface NavigationalStateComponent
Returns:
@throws FailedToCreateNavStateException if the nav state could not be created. Under normal circumstances, this should not happen.
Throws:
FailedToCreateNavStateException - if the nav state could not be created. Under normal circumstances, this should not happen.
See Also:
org.apache.jetspeed.container.state.NavigationalStateComponent#create(org.apache.jetspeed.request.RequestContext)

createURL

public PortalURL createURL(javax.servlet.http.HttpServletRequest request,
                           java.lang.String characterEncoding)

createURL

Specified by:
createURL in interface NavigationalStateComponent
Parameters:
context -
Returns:
See Also:
org.apache.jetspeed.container.state.NavigationalStateComponent#createURL(org.apache.jetspeed.request.RequestContext)

lookupWindowState

public javax.portlet.WindowState lookupWindowState(java.lang.String name)
Description copied from interface: NavigationalStateComponent
Given a window state name, look up its object. Ensures that we always use the same objects for WindowStates allowing for comparison by value.

Specified by:
lookupWindowState in interface NavigationalStateComponent
Parameters:
name - The string representation of the window state.
Returns:
The corresponding WindowState object

lookupPortletMode

public javax.portlet.PortletMode lookupPortletMode(java.lang.String name)
Description copied from interface: NavigationalStateComponent
Given a portlet mode name, look up its object. Ensures that we always use the same objects for Portlet Modes allowing for comparison by value.

Specified by:
lookupPortletMode in interface NavigationalStateComponent
Parameters:
name - The string representation of the portlet mode.
Returns:
The corresponding PortletMode object

setBeanFactory

public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
                    throws org.springframework.beans.BeansException
Specified by:
setBeanFactory in interface org.springframework.beans.factory.BeanFactoryAware
Throws:
org.springframework.beans.BeansException

createDesktopURL

public PortalURL createDesktopURL(javax.servlet.http.HttpServletRequest request,
                                  java.lang.String characterEncoding)
Description copied from interface: NavigationalStateComponent
Creates a Desktop Portal URL representing the URL of the request.

Specified by:
createDesktopURL in interface NavigationalStateComponent
Parameters:
request - The ubiqitious request.
characterEncoding - String containing the name of the chararacter encoding
Returns:
A new Portal URL. This method will never return null;


Copyright © 1999-2009 Apache Software Foundation. All Rights Reserved.