BEA Systems, Inc.

com.beasys.commerce.portal.jspbeans
Class PortalAppearanceBean

java.lang.Object
  |
  +--com.beasys.commerce.portal.jspbeans.PortalAppearanceBean

public class PortalAppearanceBean
extends java.lang.Object

The PortalAppearanceBean is used to hold property choices for portal appearance. Among these choices are portlet titlebar color, portlet title font color, portlet content background color, portal background color, portlet border appearance, and portlet banner color.


Inner Class Summary
 class PortalAppearanceBean.ColorScheme
          Color scheme holds a color scheme name, a titlebar color, a banner color, and a portlet content background color.
 
Field Summary
static java.lang.String BANNER_BG_COLOR
          Property name for portlet banner background color.
static java.lang.String BLACK
          Black color representation.
static java.lang.String BODY_BG_COLOR
          Property name for portal background color.
static java.lang.String BODY_BG_COLOR_TEXT
          Property name for custom-entered portal background color.
static java.lang.String COLOR_WARNING
          A color warning which informs the user that a color outside the standard set of 216 internet colors was chosen for a particular preference.
static java.lang.String CONTENT_BG_COLOR
          Property name for portlet content background color.
static java.lang.String CUSTOM
          Generally-used 'custom' property name.
static java.lang.String GREY
          Grey color representation.
static java.lang.String SCHEME
          Property name for portlet color scheme.
static java.lang.String SHOW_BORDERS
          Property name for show borders property.
static java.lang.String TITLEBAR_BG_COLOR
          Property name for portlet titlebar background color.
static java.lang.String TITLEBAR_FONT_COLOR
          Property name for portlet titlebar font color.
static java.lang.String TITLEBAR_FONT_COLOR_TEXT
          Property name for custom-entered portlet titlebar font color.
static java.lang.String WARNING
          Standard warning text
static java.lang.String WHITE
          White color representation.
 
Constructor Summary
PortalAppearanceBean()
          Default constructor
 
Method Summary
 java.lang.String getBannerBGColor()
          Retrieves the current portlet banner color, as dictated by the JSP page using this bean.
 java.lang.String getBodyBGColor()
          Retrieves the current portal background color, as dictated by the JSP page using this bean.
 java.lang.String getBodyBGColorText()
          Retrieves the value of the custom-entered portal background color, dictated by the JSP page using this bean.
 PortalAppearanceBean.ColorScheme getColorScheme(java.lang.String schemeName)
          Retrieves the appropriate ColorScheme object based on the provided scheme name.
 PortalAppearanceBean.ColorScheme[] getColorSchemes()
          Retrieves all color schemes from which a non-custom portlet scheme can be selected.
 java.lang.String getDefaultBannerColor()
          Retrieves the default portlet banner color.
 java.lang.String getDefaultPortalBGColor()
          Retrieves the default portal background color.
 java.lang.String getDefaultPortletBGColor()
          Retrieves the default portlet background color.
 java.lang.String getDefaultShowBorders()
          Retrieves the default portal setting regarding whether portlet borders are displayed at portal run-time.
 java.lang.String getDefaultTitleBarColor()
          Retrieves the default titlebar color.
 java.lang.String getDefaultTitleFontColor()
          Retrieves the default title font color.
 java.lang.String getPortletBGColor()
          Retrieves the current portlet background color, as dictated by the JSP page using this bean.
 java.lang.String getSchemaProperty(PropertyBean aPropertyBean, java.lang.String aPropertyName)
           
 java.lang.String getScheme()
          Retrieves the current portlet color scheme name, as dictated by the JSP page using this bean.
 java.lang.String getTitlebarColor()
          Retrieves the current titlebar color, as dictated by the JSP page using this bean.
 java.lang.String getTitleFontColor()
          Retrieves the current title font color, as dictated by the JSP page using this bean.
 java.lang.String getTitleFontColorText()
          Retrieves the value of the custom-entered title font color, dictated by the JSP page using this bean.
protected  void loadColorSchemes()
          Loads available portlet color schemes.
 void setBannerBGColor(java.lang.String bannerBGColor)
          Sets the portlet banner color.
 void setBodyBGColor(java.lang.String bodyBGColor)
          Sets the portal background color.
 void setBodyBGColorText(java.lang.String bodyBGColorText)
          Sets the custom-entered title portal background color.
 void setPortletBGColor(java.lang.String portletBGColor)
          Sets the portlet background color.
 java.lang.String setSchemaProperty(PropertyBean aPropertyBean, java.lang.String aPropertyName, java.lang.String theValue)
           
 void setScheme(java.lang.String scheme)
          Sets the portlet color scheme name.
 void setTitlebarColor(java.lang.String titlebarColor)
          Sets the titlebar color.
 void setTitleFontColor(java.lang.String titleFontColor)
          Sets the title font color.
 void setTitleFontColorText(java.lang.String titleFontColorText)
          Sets the custom-entered title font color value.
 java.lang.String validateBodyColor()
          Checks the entered portlet background color for errors.
 java.lang.String validateColorScheme()
          Checks the entered portlet color scheme for errors.
 java.lang.String validateTitleFontColor()
          Checks the entered title font color for errors.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GREY

public static final java.lang.String GREY
Grey color representation.

BLACK

public static final java.lang.String BLACK
Black color representation.

WHITE

public static final java.lang.String WHITE
White color representation.

SCHEME

public static final java.lang.String SCHEME
Property name for portlet color scheme.

TITLEBAR_BG_COLOR

public static final java.lang.String TITLEBAR_BG_COLOR
Property name for portlet titlebar background color.

BANNER_BG_COLOR

public static final java.lang.String BANNER_BG_COLOR
Property name for portlet banner background color.

CONTENT_BG_COLOR

public static final java.lang.String CONTENT_BG_COLOR
Property name for portlet content background color.

BODY_BG_COLOR

public static final java.lang.String BODY_BG_COLOR
Property name for portal background color.

BODY_BG_COLOR_TEXT

public static final java.lang.String BODY_BG_COLOR_TEXT
Property name for custom-entered portal background color.

TITLEBAR_FONT_COLOR

public static final java.lang.String TITLEBAR_FONT_COLOR
Property name for portlet titlebar font color.

TITLEBAR_FONT_COLOR_TEXT

public static final java.lang.String TITLEBAR_FONT_COLOR_TEXT
Property name for custom-entered portlet titlebar font color.

SHOW_BORDERS

public static final java.lang.String SHOW_BORDERS
Property name for show borders property.

CUSTOM

public static final java.lang.String CUSTOM
Generally-used 'custom' property name.

WARNING

public static final java.lang.String WARNING
Standard warning text

COLOR_WARNING

public static final java.lang.String COLOR_WARNING
A color warning which informs the user that a color outside the standard set of 216 internet colors was chosen for a particular preference.
Constructor Detail

PortalAppearanceBean

public PortalAppearanceBean()
Default constructor
Method Detail

getDefaultShowBorders

public java.lang.String getDefaultShowBorders()
Retrieves the default portal setting regarding whether portlet borders are displayed at portal run-time. This is the default setting at the portal level.
Returns:
String "true" or "false"

getDefaultPortletBGColor

public java.lang.String getDefaultPortletBGColor()
Retrieves the default portlet background color. This is the default setting at the portal level.
Returns:
String the default portlet background color.

getDefaultPortalBGColor

public java.lang.String getDefaultPortalBGColor()
Retrieves the default portal background color. This is the default setting at the portal level.
Returns:
String the default portal background color.

getDefaultTitleFontColor

public java.lang.String getDefaultTitleFontColor()
Retrieves the default title font color. This is the default setting at the portal level.
Returns:
String the default title font color.

getDefaultTitleBarColor

public java.lang.String getDefaultTitleBarColor()
Retrieves the default titlebar color. This is the default setting at the portal level.
Returns:
String the default titlebar color.

getDefaultBannerColor

public java.lang.String getDefaultBannerColor()
Retrieves the default portlet banner color. This is the default setting at the portal level.
Returns:
String the default portlet banner color.

getTitleFontColor

public java.lang.String getTitleFontColor()
Retrieves the current title font color, as dictated by the JSP page using this bean.
Returns:
String the current title font color

setTitleFontColor

public void setTitleFontColor(java.lang.String titleFontColor)
Sets the title font color. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
titleFontColor - the new title font color

getTitleFontColorText

public java.lang.String getTitleFontColorText()
Retrieves the value of the custom-entered title font color, dictated by the JSP page using this bean.
Returns:
Stringthe custom-entered title font color

setTitleFontColorText

public void setTitleFontColorText(java.lang.String titleFontColorText)
Sets the custom-entered title font color value. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
titleFontColorText - the new custom-entered title font color

getTitlebarColor

public java.lang.String getTitlebarColor()
Retrieves the current titlebar color, as dictated by the JSP page using this bean.
Returns:
String the current titlebar color

setTitlebarColor

public void setTitlebarColor(java.lang.String titlebarColor)
Sets the titlebar color. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
titlebarColor - the new titlebar color

getScheme

public java.lang.String getScheme()
Retrieves the current portlet color scheme name, as dictated by the JSP page using this bean.
Returns:
String the current portlet color scheme name

setScheme

public void setScheme(java.lang.String scheme)
Sets the portlet color scheme name. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
scheme - the new portlet color scheme name

getBannerBGColor

public java.lang.String getBannerBGColor()
Retrieves the current portlet banner color, as dictated by the JSP page using this bean.
Returns:
String the current portlet banner color

setBannerBGColor

public void setBannerBGColor(java.lang.String bannerBGColor)
Sets the portlet banner color. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
bannerBGColor - the new portlet banner color

getPortletBGColor

public java.lang.String getPortletBGColor()
Retrieves the current portlet background color, as dictated by the JSP page using this bean.
Returns:
String the current portlet background color

setPortletBGColor

public void setPortletBGColor(java.lang.String portletBGColor)
Sets the portlet background color. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
portletBGColor - the new portlet background color

getBodyBGColor

public java.lang.String getBodyBGColor()
Retrieves the current portal background color, as dictated by the JSP page using this bean.
Returns:
String the current portal backgroun color

setBodyBGColor

public void setBodyBGColor(java.lang.String bodyBGColor)
Sets the portal background color. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
bodyBGColor - the new portal background color

getBodyBGColorText

public java.lang.String getBodyBGColorText()
Retrieves the value of the custom-entered portal background color, dictated by the JSP page using this bean.
Returns:
Stringthe custom-entered title font color

setBodyBGColorText

public void setBodyBGColorText(java.lang.String bodyBGColorText)
Sets the custom-entered title portal background color. Typically used by the JSP page via the <jsp:setProperty> tag.
Parameters:
bodyBGColorText - the new custom-entered portal background color

validateTitleFontColor

public java.lang.String validateTitleFontColor()
Checks the entered title font color for errors.
Returns:
String error message ; null if no error.

validateColorScheme

public java.lang.String validateColorScheme()
Checks the entered portlet color scheme for errors.
Returns:
String error message ; null if no error.

validateBodyColor

public java.lang.String validateBodyColor()
Checks the entered portlet background color for errors.
Returns:
String error message ; null if no error.

getColorScheme

public PortalAppearanceBean.ColorScheme getColorScheme(java.lang.String schemeName)
Retrieves the appropriate ColorScheme object based on the provided scheme name.
Returns:
ColorScheme the scheme associated with the provided name.

getColorSchemes

public PortalAppearanceBean.ColorScheme[] getColorSchemes()
Retrieves all color schemes from which a non-custom portlet scheme can be selected.
Returns:
ColorScheme[] all standardly available portlet color schemes.

loadColorSchemes

protected void loadColorSchemes()
Loads available portlet color schemes. Will eventually use an XML file. The loaded schemes are available to any client JSP page.

getSchemaProperty

public java.lang.String getSchemaProperty(PropertyBean aPropertyBean,
                                          java.lang.String aPropertyName)

setSchemaProperty

public java.lang.String setSchemaProperty(PropertyBean aPropertyBean,
                                          java.lang.String aPropertyName,
                                          java.lang.String theValue)

BEA Systems, Inc.

Copyright © 2000 BEA Systems, Inc. All Rights Reserved