|
Jive Forums API (5.5.20.2-oracle) Developer Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jivesoftware.base.theme.AbstractThemeManager
public abstract class AbstractThemeManager
Nested Class Summary | |
---|---|
static class |
AbstractThemeManager.ThemePutTask
|
static class |
AbstractThemeManager.ThemeRemoveTask
|
Field Summary | |
---|---|
protected static Theme |
globalTheme
|
protected static java.lang.String |
THEME_CONFIG_FILENAME
|
protected static java.util.Map |
themeMaps
|
protected static java.util.Map |
themes
|
protected static java.io.File |
themesDir
|
Constructor Summary | |
---|---|
AbstractThemeManager()
|
Method Summary | |
---|---|
void |
addThemeMap(java.lang.String theme,
ThemeMap themeMap)
Adds a theme mapping to the system. |
void |
deleteThemeMap(ThemeMap themeMap)
Removes a theme mapping from the system. |
abstract Theme |
determineTheme(com.opensymphony.xwork.ActionContext context,
javax.servlet.http.HttpServletRequest request)
Returns the Theme corresponding to the given parameters, or null if no theme meets the criteria. |
Theme |
getGlobalTheme()
Returns the Theme object that is currently installed as the 'Global' theme, or null if a global theme is not installed. |
protected Theme |
getTheme(java.util.Locale locale)
Used to determine a theme given a locale. |
protected Theme |
getTheme(java.lang.String url)
Used to determine a theme given a url |
Theme |
getTheme(ThemeMap themeMap)
Returns the Theme object corresponding to the provided themeMap, or null if no association is found. |
protected Theme |
getThemeByName(java.lang.String themeName)
Used to get a theme by the theme name. |
java.lang.String |
getThemeHome()
Returns the absolute path to the theme home directory. |
java.util.Map |
getThemeMaps()
Returns a Map of theme name -> ThemeMap objects. |
java.util.Collection |
getThemes()
Returns a Collection of Theme objects for all the themes in the system. |
protected abstract boolean |
isNumValue(ThemeMap themeMap)
Returns true if the themeMap is using a number value, false if it's using a string value. |
void |
reloadThemeMaps()
Used to force a reload (and resort) of theme maps. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final java.lang.String THEME_CONFIG_FILENAME
protected static java.io.File themesDir
protected static java.util.Map themes
protected static java.util.Map themeMaps
protected static Theme globalTheme
Constructor Detail |
---|
public AbstractThemeManager()
Method Detail |
---|
public java.lang.String getThemeHome()
ThemeManager
getThemeHome
in interface ThemeManager
public java.util.Collection getThemes()
ThemeManager
getThemes
in interface ThemeManager
public java.util.Map getThemeMaps()
ThemeManager
getThemeMaps
in interface ThemeManager
ThemeMap
public Theme getGlobalTheme()
ThemeManager
getGlobalTheme
in interface ThemeManager
public Theme getTheme(ThemeMap themeMap)
ThemeManager
getTheme
in interface ThemeManager
themeMap
- the theme map to use to retrieve the theme
public abstract Theme determineTheme(com.opensymphony.xwork.ActionContext context, javax.servlet.http.HttpServletRequest request)
ThemeManager
determineTheme
in interface ThemeManager
context
- the action contextrequest
- the servlet request
Theme
public void addThemeMap(java.lang.String theme, ThemeMap themeMap)
ThemeManager
addThemeMap
in interface ThemeManager
theme
- the name of the themethemeMap
- the ThemeMap containing the criteria used to determine when to use the themepublic void deleteThemeMap(ThemeMap themeMap)
ThemeManager
deleteThemeMap
in interface ThemeManager
themeMap
- the ThemeMap to remove.public void reloadThemeMaps()
reloadThemeMaps
in interface ThemeManager
protected abstract boolean isNumValue(ThemeMap themeMap)
themeMap
- the ThemeMap to check the value for
protected Theme getTheme(java.lang.String url)
url
- the url to use to determine the theme
protected Theme getTheme(java.util.Locale locale)
locale
- the locale to use to determine the theme
protected Theme getThemeByName(java.lang.String themeName)
themeName
- the name of the theme.
|
Jive Forums Project Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |