|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface BbSession
BbSession. See blackboard.apps.bb5.session for implementation classes.
Nested Class Summary | |
---|---|
static class |
BbSession.Scope
Deprecated. All attributes are stored in Global scope, since the alternate scopes were never properly implemented |
Method Summary | |
---|---|
java.lang.String |
encodeNavigationItemURL(javax.servlet.http.HttpServletRequest request,
java.lang.String url)
Performs url parse/replace operation for navigation item specific entities. |
java.lang.String |
encodeSessionContext(java.lang.String url)
Encodes this session's id on the given url as a request parameter formatted as "? |
java.lang.String |
encodeTemplateUrl(javax.servlet.http.HttpServletRequest request,
java.lang.String url)
Encodes context information on the given url as required by the template based format. |
java.lang.Object |
getAttribute(java.lang.String name,
BbSession.Scope scope)
Deprecated. Use HttpSession for private attributes (visible only to the calling webapp). Use getGlobalKey() for global attributes (visible across all webapps). |
int |
getBbSessionId()
Returns the Blackboard assigned unique id for this user's session. |
java.lang.String |
getBbSessionIdMd5()
Returns the Blackboard assigned unique id for this user's session as an MD5 hashed string. |
long |
getCreateTimeMillis()
Deprecated. The session creation time is not stored in the database. Local "in memory" time is meaningless since sessions can be opened on multiple machines in a load balanced scenario. |
java.lang.String |
getGlobalKey(java.lang.String name)
Retrieves a key that was stored for global use. |
long |
getLastAccessTimeMillis()
Returns the system time in milliseconds as specified by System.getTimeMillis() of when this session instance was last accessed. |
Id |
getUserId()
Returns the Id of the user associated with this session. |
java.lang.String |
getUserName()
Returns the system login name of the user associated with this session. |
boolean |
isAuthenticated()
Returns true if the associated user has been authenticated. |
CourseContext |
lookupCourseContext(javax.servlet.http.HttpServletRequest request)
Deprecated. The return object is not part of the public API and has been removed from use. |
GroupContext |
lookupGroupContext(javax.servlet.http.HttpServletRequest request)
Deprecated. The return object is not part of the public API and has been removed from use. |
RequestContext |
lookupRequestContext(javax.servlet.http.HttpServletRequest request)
Deprecated. The return object is not part of the public API and has been removed from use. |
UserContext |
lookupUserContext(javax.servlet.http.HttpServletRequest request)
Deprecated. The return object is not part of the public API and has been removed from use. |
java.lang.Object |
removeAttribute(java.lang.String name,
BbSession.Scope scope)
Deprecated. This method has no meaning since the corresponding set/get are not implemented. |
void |
setAttribute(java.lang.String name,
java.lang.Object value,
BbSession.Scope scope)
Deprecated. Use HttpSession for private attributes (visible only to the calling webapp). Use setGlobalKey() for global attributes (visible across all webapps). |
void |
setGlobalKey(java.lang.String name,
java.lang.String value)
Sets a key for global use. |
Method Detail |
---|
int getBbSessionId()
java.lang.String getBbSessionIdMd5()
java.lang.String encodeSessionContext(java.lang.String url)
java.lang.String encodeTemplateUrl(javax.servlet.http.HttpServletRequest request, java.lang.String url) throws PersistenceException, InitializationException
PersistenceException
InitializationException
java.lang.String encodeNavigationItemURL(javax.servlet.http.HttpServletRequest request, java.lang.String url)
Id getUserId()
Id
of the user associated with this session.
java.lang.String getUserName()
boolean isAuthenticated()
UserContext lookupUserContext(javax.servlet.http.HttpServletRequest request)
UserContext
or null if none exists. This method can be used
to retrieve a context encoded via UserContext.encodeUserContext( String ).
RequestContext lookupRequestContext(javax.servlet.http.HttpServletRequest request)
RequestContext
or null if none exists. This method can be used
to retrieve a context encoded via RequestContext.encodeRequestContext( String ).
CourseContext lookupCourseContext(javax.servlet.http.HttpServletRequest request)
CourseContext
or null if none exists. This method can be used
to retrieve a context encoded via CourseContext.encodeCourseContext( String ).
GroupContext lookupGroupContext(javax.servlet.http.HttpServletRequest request)
GroupContext
or null if none exists. This method can be used
to retrieve a context encoded via GroupContext.encodeGroupContext( String ).
java.lang.String getGlobalKey(java.lang.String name) throws PersistenceException
name
- Name of the key to retrieve
PersistenceException
- thrown if the keys could not be loaded from the databasevoid setGlobalKey(java.lang.String name, java.lang.String value) throws PersistenceException
name
- Name of the key to setvalue
- Value of the key to set
PersistenceException
- thrown if the key could not be writtenvoid setAttribute(java.lang.String name, java.lang.Object value, BbSession.Scope scope)
java.lang.Object getAttribute(java.lang.String name, BbSession.Scope scope)
java.lang.Object removeAttribute(java.lang.String name, BbSession.Scope scope)
long getCreateTimeMillis()
long getLastAccessTimeMillis()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |