public abstract class SessionManager extends Object
Modifier and Type | Field and Description |
---|---|
protected Set<SessionListener> |
listeners |
protected LoginSession |
session |
Modifier | Constructor and Description |
---|---|
protected |
SessionManager(org.eclipse.core.databinding.observable.Realm realm) |
Modifier and Type | Method and Description |
---|---|
void |
addListener(SessionListener listener)
Add a new listener
|
protected void |
checkRealm() |
protected void |
dispose() |
static SessionManager |
getDefault() |
org.eclipse.core.databinding.observable.Realm |
getRealm() |
LoginSession |
getSession() |
boolean |
hasRole(String role) |
void |
removeListener(SessionListener listener)
Remove a new listener
|
protected void |
setSession(LoginSession session) |
protected final Set<SessionListener> listeners
protected LoginSession session
protected SessionManager(org.eclipse.core.databinding.observable.Realm realm)
public void addListener(SessionListener listener)
Must be called from the realm of the manager. This is normally the display thread.
listener
- to addprotected void checkRealm()
public void removeListener(SessionListener listener)
Must be called from the realm of the manager. This is normally the display thread.
listener
- to removeprotected void setSession(LoginSession session)
protected void dispose()
public org.eclipse.core.databinding.observable.Realm getRealm()
public static SessionManager getDefault()
public LoginSession getSession()
public boolean hasRole(String role)