Package org.glassfish.admingui.theme
Class AdminguiThemeContext
- java.lang.Object
-
- com.sun.webui.theme.ThemeContext
-
- com.sun.webui.theme.ServletThemeContext
-
- org.glassfish.admingui.theme.AdminguiThemeContext
-
public class AdminguiThemeContext extends com.sun.webui.theme.ServletThemeContextThis class allows us to use a
Mapto pass in parameters which alter the Woodstock theme instead of using context-params from the web.xml. This allows us greater runtime control over the theme and helps allow the Woodstock theme properties to be overridden by plugins.- Author:
- ana, Ken
-
-
Field Summary
Fields Modifier and Type Field Description static StringTHEME_NAME_KEYThese keys are used when getting the property values provided in the custom theme plugin properties file.static StringTHEME_VERSION_KEY
-
Constructor Summary
Constructors Modifier Constructor Description protectedAdminguiThemeContext(String themeName, String themeVersion)This constructor takes in the theme name and version to use by default.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ClassLoadergetDefaultClassLoader()This method delegates toJSFThemeContext.static com.sun.webui.theme.ThemeContextgetInstance(jakarta.faces.context.FacesContext context, String themeName, String themeVersion)static com.sun.webui.theme.ThemeContextgetInstance(jakarta.faces.context.FacesContext context, Properties propMap)StringgetRequestContextPath()This method delegates toJSFThemeContext.StringgetResourcePath(String path)This method delegates toJSFThemeContext.voidsetDefaultClassLoader(ClassLoader classLoader)This method delegates toJSFThemeContext.voidsetRequestContextPath(String path)This method delegates toJSFThemeContext.-
Methods inherited from class com.sun.webui.theme.ThemeContext
getDefaultLocale, getDefaultTheme, getDefaultThemeMajorVersion, getDefaultThemeMinorVersion, getDefaultThemeVersion, getMessages, getSupportedLocales, getThemeFactory, getThemeFactoryClassName, getThemeResources, getThemeServletContext, setDefaultLocale, setDefaultTheme, setDefaultThemeVersion, setMessages, setSupportedLocales, setThemeFactoryClassName, setThemeResources, setThemeServletContext
-
-
-
-
Field Detail
-
THEME_NAME_KEY
public static final String THEME_NAME_KEY
These keys are used when getting the property values provided in the custom theme plugin properties file.- See Also:
- Constant Field Values
-
THEME_VERSION_KEY
public static final String THEME_VERSION_KEY
- See Also:
- Constant Field Values
-
-
Method Detail
-
getInstance
public static com.sun.webui.theme.ThemeContext getInstance(jakarta.faces.context.FacesContext context, String themeName, String themeVersion)- Returns:
- an instance of
ThemeContextcreating one if necessary and persisting it in theApplicationMap.
-
getInstance
public static com.sun.webui.theme.ThemeContext getInstance(jakarta.faces.context.FacesContext context, Properties propMap)- Returns:
- an instance of
ThemeContextusing properties provided viaIntegration point.
-
getDefaultClassLoader
public ClassLoader getDefaultClassLoader()
This method delegates toJSFThemeContext.- Overrides:
getDefaultClassLoaderin classcom.sun.webui.theme.ThemeContext
-
setDefaultClassLoader
public void setDefaultClassLoader(ClassLoader classLoader)
This method delegates toJSFThemeContext.- Overrides:
setDefaultClassLoaderin classcom.sun.webui.theme.ThemeContext
-
getRequestContextPath
public String getRequestContextPath()
This method delegates toJSFThemeContext.- Overrides:
getRequestContextPathin classcom.sun.webui.theme.ThemeContext
-
setRequestContextPath
public void setRequestContextPath(String path)
This method delegates toJSFThemeContext.- Overrides:
setRequestContextPathin classcom.sun.webui.theme.ThemeContext
-
-