public final class UserSessionAccess extends Object
access
to the current UserSession
. By default the
implementation is based on spring but this small facade was created to support environments where no springframework
is available such as GWT (that does not even support ThreadLocal
). In GWT contexts a GWT compatible
implementation is provided automatically.Modifier and Type | Class and Description |
---|---|
static class |
UserSessionAccess.AbstractUserSessionProvider
The abstract base implementation of
UserSessionProvider . |
Modifier and Type | Field and Description |
---|---|
private static UserSessionProvider |
provider |
Modifier | Constructor and Description |
---|---|
private |
UserSessionAccess()
Construction forbidden.
|
Modifier and Type | Method and Description |
---|---|
private static UserSessionProvider |
getProvider() |
static UserSession |
getSession() |
static Locale |
getUserLocale() |
static String |
getUserLogin() |
private static void |
setProvider(UserSessionProvider sessionProvder) |
private static UserSessionProvider provider
private static UserSessionProvider getProvider()
UserSessionProvider
instance.private static void setProvider(UserSessionProvider sessionProvder)
sessionProvder
- is the UserSessionProvider
to set.public static UserSession getSession()
UserSession
.UserSessionProvider.getCurrentSession()
public static String getUserLogin()
null
if called outside the scope of a
current user session.public static Locale getUserLocale()
getSession()
.getLocale()
.Copyright © 2001–2016 mmm-Team. All rights reserved.