|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.softslate.commerce.businessobjects.core.BaseBusinessObject com.softslate.commerce.businessobjects.core.BaseBusinessProcessor com.softslate.commerce.businessobjects.core.SettingsBean
public class SettingsBean
Represents various settings used by the application. Settings for the
application are stored in the sscSetting
database table. The
various settings represent everything from the default colors and fonts used
by the display templates, to the names of the Java classes that implement
various business object interfaces for the application.
An instance of SettingsBean
is created in the Struts layer. It
is initialized there through initialize()
, which populates the
map
property with the results of a query on the
sscSetting
table. For each setting, an entry in the
map
is created with the setting code used as the key and its
value as the key's value.
The SettingsBean
instance created in the Struts layer is
passed throughout the application to look up needed settings. The
application's BusinessObjectFactory
initializes each business
object with the SettingsBean
immediately after it creates it.
Field Summary | |
---|---|
(package private) static org.apache.commons.logging.Log |
log
|
private java.util.Map |
map
|
private static long |
serialVersionUID
|
Constructor Summary | |
---|---|
SettingsBean()
|
Method Summary | |
---|---|
java.util.Map |
getMap()
Retrieves the map of settings values for this Settings
instance. |
java.lang.Object |
getValue(java.lang.String key)
Gets the value of a given key in this Settings '
map . |
void |
initialize()
Initializes this Settings instance. |
void |
setMap(java.util.Map map)
Sets the map of settings values for this Settings
instance. |
void |
setValue(java.lang.String key,
java.lang.Object value)
Sets the value of a given key in this Settings '
map . |
Methods inherited from class com.softslate.commerce.businessobjects.core.BaseBusinessProcessor |
---|
formatDateTime, formatPrice, getAppComponents, getAppSettings, getAttributeIDs, getBusinessObjectFactory, getDaoFactory, getProductIDs, getSettings, getUser, initialize, loadMatchingSkus, parseDateTime, parseResponseData, prepareRequestData, sendHTTPPost, setAppComponents, setAppSettings, setBusinessObjectFactory, setDaoFactory, setSettings, setUser, utils |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final long serialVersionUID
static org.apache.commons.logging.Log log
private java.util.Map map
getMap()
Constructor Detail |
---|
public SettingsBean()
Method Detail |
---|
public java.util.Map getMap()
Settings
Settings
instance. The keys of this Map
correspond to the
code
field of the sscSetting
database
table. The values correspond to value field (integerValue
,
smallValue
, mediumValue
, or
textValue
) that corresponds with the value of the
valueType
field.
getMap
in interface Settings
Map
of settings keys and values for this
Settings
instance.public void setMap(java.util.Map map)
Settings
Settings
instance.
setMap
in interface Settings
public void setValue(java.lang.String key, java.lang.Object value)
Settings
Settings
'
map
.
setValue
in interface Settings
key
- The key whose value is being setvalue
- The value.public java.lang.Object getValue(java.lang.String key)
Settings
Settings
'
map
.
getValue
in interface Settings
key
- The key whose value is to be retrieved.
public void initialize() throws java.lang.Exception
Settings
Settings
instance. Populates the
map
property with the results of a query on the
sscSetting
database table.
initialize
in interface Settings
java.lang.Exception
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |