com.atlassian.confluence.plugins.macros.dashboard
Class DashboardMacroSupport

java.lang.Object
  extended by com.atlassian.confluence.plugins.macros.dashboard.DashboardMacroSupport

public class DashboardMacroSupport
extends Object

This support class provides common functionality used by the macros that are used on the dashboard.


Constructor Summary
DashboardMacroSupport()
           
 
Method Summary
 List<Space> getAllViewableSpaces()
           
 DateFormatter getDateFormatter()
           
 List<Space> getFavouriteSpaces()
           
 List<Space> getGroupSpaces()
           
 List<Space> getNewSpaces()
           
 Set<Space> getPermittedSpaces()
           
 javax.servlet.http.HttpServletRequest getRequest()
          There are three possible cases here - You are within an HTTP request thread, in which case the request will be retrieved from a ThreadLocal You are an AJAX call in which case the request will be retrieved from a WebContextFactory.
 String getRequestParameter(String key)
           
protected  String getSelectedGroupKey()
           
protected  String getSelectedTeamLabelName()
           
 List<SpaceGroup> getSpaceGroups()
           
 String getSpacesSelectedTab()
           
 List<Space> getTeamSpaces()
           
protected  UserInterfaceState getUserInterfaceState()
           
 List<String> getViewableTeamLabels()
           
protected  boolean isSuperUser()
           
protected  String sanitise(String spacesSelectedTab)
          four cases to sanitise on "new" tab when there are no new spaces "my" tab when there are no favourite spaces "team" tab when there are no teams "groups" tab when there are no groups
 void setLabelManager(LabelManager labelManager)
           
 void setLocaleManager(LocaleManager localeManager)
           
 void setSettingsManager(SettingsManager settingsManager)
           
 void setSpaceGroupManager(SpaceGroupManager spaceGroupManager)
           
 void setSpaceManager(SpaceManager spaceManager)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DashboardMacroSupport

public DashboardMacroSupport()
Method Detail

getFavouriteSpaces

public List<Space> getFavouriteSpaces()

getDateFormatter

public DateFormatter getDateFormatter()

getNewSpaces

public List<Space> getNewSpaces()

getTeamSpaces

public List<Space> getTeamSpaces()

getPermittedSpaces

public Set<Space> getPermittedSpaces()

getGroupSpaces

public List<Space> getGroupSpaces()

getSelectedTeamLabelName

protected String getSelectedTeamLabelName()

getSelectedGroupKey

protected String getSelectedGroupKey()

getViewableTeamLabels

public List<String> getViewableTeamLabels()

isSuperUser

protected boolean isSuperUser()

getUserInterfaceState

protected UserInterfaceState getUserInterfaceState()

getSpacesSelectedTab

public String getSpacesSelectedTab()

sanitise

protected String sanitise(String spacesSelectedTab)
four cases to sanitise on

getRequestParameter

public String getRequestParameter(String key)

getRequest

public javax.servlet.http.HttpServletRequest getRequest()
There are three possible cases here -
  1. You are within an HTTP request thread, in which case the request will be retrieved from a ThreadLocal
  2. You are an AJAX call in which case the request will be retrieved from a WebContextFactory.
  3. You are not a 'web related' thread (e.g. a Long running task) in which case null will be returned.

Returns:
The HttpServletRequest associated with the current thread.

getSpaceGroups

public List<SpaceGroup> getSpaceGroups()

getAllViewableSpaces

public List<Space> getAllViewableSpaces()

setLabelManager

public void setLabelManager(LabelManager labelManager)

setSpaceManager

public void setSpaceManager(SpaceManager spaceManager)

setSpaceGroupManager

public void setSpaceGroupManager(SpaceGroupManager spaceGroupManager)

setSettingsManager

public void setSettingsManager(SettingsManager settingsManager)

setLocaleManager

public void setLocaleManager(LocaleManager localeManager)


Copyright © 2003-2010 Atlassian. All Rights Reserved.