org.hsqldb
Class SessionManager
- java.lang.Object
-
- org.hsqldb.SessionManager
-
public class SessionManager extends java.lang.ObjectContainer that maintains a map of session id's to Session objects. Responsible for managing opening and closing of sessions.- Since:
- 1.7.2
-
-
Constructor Summary
Constructors Constructor and Description SessionManager(Database db)Constructs an new SessionManager handling the specified Database.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidcloseAllSessions()Closes all Sessions registered with this SessionManager.Session[]getAllSessions()SessiongetSysLobSession()SessiongetSysSession()Retrieves the common SYS Session.SessiongetSysSessionForScript(Database db)Retrieves a new SYS Session.Session[]getVisibleSessions(Session session)Retrieves a list of the Sessions in this container that are visible to the specified Session, given the access rights of the Session User.booleanisUserActive(java.lang.String userName)SessionnewSession(Database db, User user, boolean readonly, boolean autoCommit, java.lang.String zoneString, int timeZoneSeconds)Binds the specified Session object into this SessionManager's active Session registry.SessionnewSessionForLog(Database db)SessionnewSysSession()Retrieves a transient transaction session.SessionnewSysSession(HsqlNameManager.HsqlName schema, User user)voidremoveSchemaReference(Schema schema)voidresetLoggedSchemas()
-
-
-
Constructor Detail
-
SessionManager
public SessionManager(Database db)
Constructs an new SessionManager handling the specified Database. Creates a SYS User.
-
-
Method Detail
-
newSession
public Session newSession(Database db, User user, boolean readonly, boolean autoCommit, java.lang.String zoneString, int timeZoneSeconds)
Binds the specified Session object into this SessionManager's active Session registry. This method is typically called internally as the final step, when a successful connection has been made.- Parameters:
db- the database to which the new Session is initially connecteduser- the Session Userreadonly- the ReadOnly attribute for the new SessionforLog- true when session is for reading a logtimeZoneSeconds- the session time zone second interval- Returns:
- Session
-
getSysSessionForScript
public Session getSysSessionForScript(Database db)
Retrieves a new SYS Session.
-
getSysLobSession
public Session getSysLobSession()
-
getSysSession
public Session getSysSession()
Retrieves the common SYS Session.
-
newSysSession
public Session newSysSession()
Retrieves a transient transaction session.
-
newSysSession
public Session newSysSession(HsqlNameManager.HsqlName schema, User user)
-
closeAllSessions
public void closeAllSessions()
Closes all Sessions registered with this SessionManager.
-
getVisibleSessions
public Session[] getVisibleSessions(Session session)
Retrieves a list of the Sessions in this container that are visible to the specified Session, given the access rights of the Session User.
-
getAllSessions
public Session[] getAllSessions()
-
isUserActive
public boolean isUserActive(java.lang.String userName)
-
removeSchemaReference
public void removeSchemaReference(Schema schema)
-
resetLoggedSchemas
public void resetLoggedSchemas()
-
-
DataMelt 3.0 © DataMelt by jWork.ORG