scistag.remotestag.session.Session¶
- class Session(config)[source]¶
Bases:
objectRepresents a single user data session
Initializer
- Parameters
config (
dict) – The configuration dictionary. Has to at least contain the sessionId
Methods
Returns the last guest data
Is called right after the constructor and before the build call
Called when the session shall deallocate memory intensive resources
Should be called when the session was requested
Requests if the user data shall be handled manually.
Backups the last data for a guest viewer
Stores user data provided from the browser
Returns the current configuration :rtype:
dict:return: The configurationAttributes
PERMISSIONSREMOTE_SESSIONSESSION_ID__dict____doc____module____weakref__list of weak references to the object (if defined)
Multithread access lock
Set to true when the app is going to be destroyed and should not be used anymore
The unique session identifier
Access id for guest access
Contains the previous image cached for a guest viewer
The configuration dictionary
Last interaction to manage garbage collection in seconds
The session timeout in seconds.
registered user data elements
Local database connection
- get_guest_data()[source]¶
Returns the last guest data
- Return type
bytes | None
- Returns
The last guest data
- handle_user_data(user_data_name, data)[source]¶
Requests if the user data shall be handled manually.
Otherwise it ‘s stored in {rootPath}.userData
- set_guest_data(data)[source]¶
Backups the last data for a guest viewer
- Parameters
data (
bytes) – The last image
- _config¶
The configuration dictionary
- data_connection¶
Local database connection
- guest_id¶
Access id for guest access
- last_interaction¶
Last interaction to manage garbage collection in seconds
- lock¶
Multithread access lock
- session_id¶
The unique session identifier
- session_timeout¶
The session timeout in seconds. 0.0 = no timeout
- unloaded¶
Set to true when the app is going to be destroyed and should not be used anymore
- user_data_config¶
registered user data elements