Save This Page
Home » spring-framework-2.5.4 » org.springframework » web » portlet » handler » [javadoc | source]
org.springframework.web.portlet.handler
public class: PortletModeHandlerMapping [javadoc | source]
java.lang.Object
   org.springframework.context.support.ApplicationObjectSupport
      org.springframework.web.portlet.handler.AbstractHandlerMapping
         org.springframework.web.portlet.handler.AbstractMapBasedHandlerMapping
            org.springframework.web.portlet.handler.PortletModeHandlerMapping

All Implemented Interfaces:
    HandlerMapping, Ordered, ApplicationContextAware

Implementation of the org.springframework.web.portlet.HandlerMapping interface to map from the current PortletMode to request handler beans.

The bean configuration for this mapping will look something like this:

<bean id="portletModeHandlerMapping" class="org.springframework.web.portlet.handler.PortletModeHandlerMapping">
<property name="portletModeMap">
<map>
<entry key="view"><ref bean="viewHandler"/></entry>
<entry key="edit"><ref bean="editHandler"/></entry>
<entry key="help"><ref bean="helpHandler"/></entry>
</map>
</property>
</bean>
Fields inherited from org.springframework.context.support.ApplicationObjectSupport:
logger
Method from org.springframework.web.portlet.handler.PortletModeHandlerMapping Summary:
getLookupKey,   initApplicationContext,   registerHandlers,   setMappings,   setPortletModeMap
Methods from org.springframework.web.portlet.handler.AbstractMapBasedHandlerMapping:
getHandlerInternal,   getLookupKey,   registerHandler,   registerHandler,   registerHandlers,   setLazyInitHandlers
Methods from org.springframework.web.portlet.handler.AbstractHandlerMapping:
adaptInterceptor,   extendInterceptors,   getAdaptedInterceptors,   getDefaultHandler,   getHandler,   getHandlerExecutionChain,   getHandlerInternal,   getOrder,   initApplicationContext,   initInterceptors,   setApplyWebRequestInterceptorsToRenderPhaseOnly,   setDefaultHandler,   setInterceptors,   setOrder
Methods from org.springframework.context.support.ApplicationObjectSupport:
getApplicationContext,   getMessageSourceAccessor,   initApplicationContext,   initApplicationContext,   isContextRequired,   requiredContextClass,   setApplicationContext
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.springframework.web.portlet.handler.PortletModeHandlerMapping Detail:
 protected Object getLookupKey(PortletRequest request) throws Exception 
    Uses the current PortletMode as lookup key.
 public  void initApplicationContext() throws BeansException 
    Calls the registerHandlers method in addition to the superclass's initialization.
 protected  void registerHandlers(Map portletModeMap) throws BeansException 
    Register all handlers specified in the Portlet mode map for the corresponding modes.
 public  void setMappings(Properties mappings) 
    Set PortletMode to handler bean name mappings from a Properties object.
 public  void setPortletModeMap(Map portletModeMap) 
    Set a Map with PortletModes as keys and handler beans as values. Convenient for population with bean references.