|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object magoffin.matt.ma2.support.BasicBizContext
public class BasicBizContext
Basic implementation of BizContext interface.
Note this implementation is not thread safe.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface magoffin.matt.ma2.biz.BizContext |
---|
BizContext.Feature |
Constructor Summary | |
---|---|
BasicBizContext()
Default constructor. |
|
BasicBizContext(magoffin.matt.xweb.util.AppContextSupport appContextSupport)
Constructor. |
Method Summary | |
---|---|
User |
getActingUser()
Get the acting user. |
magoffin.matt.xweb.util.AppContextSupport |
getAppContextSupport()
Get the application context. |
java.lang.Object |
getAttribute(java.lang.String key)
Get an attribute value. |
java.util.Locale |
getLocale()
Get the Locale to use for messages, etc. |
boolean |
isFeatureEnabled(BizContext.Feature feature)
Test if a feature is enabled. |
void |
setActingUser(User user)
Set the acting user. |
protected void |
setAppContextSupport(magoffin.matt.xweb.util.AppContextSupport appContextSupport)
Set the AppContextSupport. |
void |
setAttribute(java.lang.String key,
java.lang.Object value)
Set an attribute value. |
protected void |
setLocale(java.util.Locale locale)
Set the locale. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BasicBizContext(magoffin.matt.xweb.util.AppContextSupport appContextSupport)
appContextSupport
- the application contextpublic BasicBizContext()
Method Detail |
---|
public void setActingUser(User user)
user
- public User getActingUser()
BizContext
getActingUser
in interface BizContext
public magoffin.matt.xweb.util.AppContextSupport getAppContextSupport()
BizContext
getAppContextSupport
in interface BizContext
public java.util.Locale getLocale()
BizContext
getLocale
in interface BizContext
public boolean isFeatureEnabled(BizContext.Feature feature)
BizContext
isFeatureEnabled
in interface BizContext
feature
- the feature to test
protected void setLocale(java.util.Locale locale)
locale
- the locale to setprotected void setAppContextSupport(magoffin.matt.xweb.util.AppContextSupport appContextSupport)
appContextSupport
- public java.lang.Object getAttribute(java.lang.String key)
BizContext
getAttribute
in interface BizContext
key
- the attribute key
public void setAttribute(java.lang.String key, java.lang.Object value)
BizContext
setAttribute
in interface BizContext
key
- the attribute keyvalue
- the attribute value
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |