org.jboss.portal.theme.tag
Class ThemeTagHandler
java.lang.Object
SimpleTagSupport
org.jboss.portal.theme.tag.ThemeTagHandler
public class ThemeTagHandler
- extends SimpleTagSupport
Tag handler for the theme tag.
The theme tag injects theme resource links into the page. Themes are CSS files, and
their resources (images). The theme tag can inject only the resources of one theme at a time. The href and src
attributes of the link and script tags that are being injected are automatically adjusted to the war context they
reside in. A theme is defined in the /WEB-INF/portal-themes.xml
- Version:
- $LastChangedRevision: 7022 $, $LastChangedDate: 2007-04-23 00:48:41 +0200 (Mon, 23 Apr 2007) $
- Author:
PortalTheme
,
ThemeLink
,
ThemeScript
Method Summary |
void |
doTag()
Render the markup for theme injection into the HEAD tag. |
java.lang.String |
getThemeName()
|
void |
setThemeName(java.lang.String name)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ThemeTagHandler
public ThemeTagHandler()
doTag
public void doTag()
throws JspException,
java.io.IOException
- Render the markup for theme injection into the HEAD tag.
This tag expects that the theme name is provided via a
http request attribute, keyed by LayoutConstants.ATTR_PAGE
. The request attribute is expected to
contain a PageResult, which in turn exposes an accessor method for the active theme's name. The theme server
(registry of all available themes) also has to be available via a request attribute
(ThemeConstants.ATTR_THEMESERVER).
- Throws:
JspException
java.io.IOException
- See Also:
PortalTheme
getThemeName
public java.lang.String getThemeName()
setThemeName
public void setThemeName(java.lang.String name)