站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBOSS Portal 2.6 API 英文版文档

StrategyContext - JBOSS Portal 2.6 API 英文版文档


org.jboss.portal.theme.strategy
Class StrategyContext

java.lang.Object
  extended byorg.jboss.portal.theme.strategy.StrategyContext

public final class StrategyContext
extends java.lang.Object

An implementation of the strategy context.

The strategy context is used by the layout strategy interceptor to pass the available state information from the portal to the strategy. The context contains information about the current page, the windowIds on it, the state of those windowIds, etc.

Version:
$Revision: 5448 $
Author:
Martin Holzner.
See Also:
StrategyContext

Field Summary
private  javax.servlet.http.HttpServletRequest httpRequest
           
private  java.util.List localWindowContexts
           
private static org.apache.log4j.Logger log
          .
private  AttributeResolver navigationalStateContext
           
private  java.lang.String[] regionNames
           
private  HTTPStreamInfo streamInfo
           
private  java.util.Set supportedPortletModes
           
private  java.util.Set supportedWindowStates
           
 
Constructor Summary
StrategyContext(AttributeResolver navCtx, PageNavigationalState pageNavState, javax.servlet.http.HttpServletRequest httpRequest, HTTPStreamInfo streamInfo, java.util.Set windowStates, java.util.Set portletModes, java.util.List regionNames)
           
 
Method Summary
 StrategyResponse createResponse()
           
 java.lang.String getCharSet()
           
 javax.servlet.http.HttpServletRequest getHttpServletRequest()
           
 java.lang.String[] getLayoutRegions()
           
 MediaType getMediaType()
           
 Mode getPortletMode(WindowContext portlet)
           
 java.util.Collection getPortletWindowContexts()
           
 java.util.List getWindows(WindowState windowState)
          Return a list of windows matching the specified window state.
 WindowState getWindowState(WindowLocation portlet)
           
 boolean isSupportedPortletMode(Mode mode)
           
 boolean isSupportedWindowState(WindowState state)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static org.apache.log4j.Logger log
.


regionNames

private final java.lang.String[] regionNames

httpRequest

private final javax.servlet.http.HttpServletRequest httpRequest

supportedWindowStates

private final java.util.Set supportedWindowStates

supportedPortletModes

private final java.util.Set supportedPortletModes

streamInfo

private final HTTPStreamInfo streamInfo

localWindowContexts

private final java.util.List localWindowContexts

navigationalStateContext

private final AttributeResolver navigationalStateContext
Constructor Detail

StrategyContext

public StrategyContext(AttributeResolver navCtx,
                       PageNavigationalState pageNavState,
                       javax.servlet.http.HttpServletRequest httpRequest,
                       HTTPStreamInfo streamInfo,
                       java.util.Set windowStates,
                       java.util.Set portletModes,
                       java.util.List regionNames)
Method Detail

getLayoutRegions

public java.lang.String[] getLayoutRegions()
See Also:
getLayoutRegions()

createResponse

public StrategyResponse createResponse()
See Also:
createResponse()

getHttpServletRequest

public javax.servlet.http.HttpServletRequest getHttpServletRequest()
See Also:
getHttpServletRequest()

getMediaType

public MediaType getMediaType()
See Also:
getMediaType()

getCharSet

public java.lang.String getCharSet()
See Also:
getCharSet()

isSupportedWindowState

public boolean isSupportedWindowState(WindowState state)
See Also:
isSupportedWindowState(WindowState)

isSupportedPortletMode

public boolean isSupportedPortletMode(Mode mode)
See Also:
isSupportedPortletMode(Mode)

getPortletWindowContexts

public java.util.Collection getPortletWindowContexts()

getWindowState

public WindowState getWindowState(WindowLocation portlet)

getPortletMode

public Mode getPortletMode(WindowContext portlet)

getWindows

public java.util.List getWindows(WindowState windowState)
                          throws java.lang.IllegalArgumentException
Return a list of windows matching the specified window state.

Parameters:
windowState - the window state to match
Returns:
a list of windows
Throws:
java.lang.IllegalArgumentException - if the window state is null