A Session
is a running instance of CET Designer. Only one Session
may be opened at a time - even if the Enable multiple drawings setting is turned on, there is still only one Session
containing multiple World
s.
Characteristics
- Provides interfaces for creating, selecting, and removing
World
s. - Provides interfaces to access the main app
Window
a,World
s,Space
s, andView
s. View
s are validated at inSession
'sflush
method (called from CET Designer's main message loop).- Handles background saves.
Flush and Flush Hooks
flush
is a method in Session
that is executed a few times every second.
In core, it's used to catch and log potential failure of crucial processes, detect processes that take too long, trigger background saves, etc.
We have hooks that added into a hook collection to trigger processes when flush
in cm/core/coreGlobals.cm :
/*************************************************************************** * Flush. ***************************************************************************/ /** * Before session flush hook. */ public (function()) {} beforeSessionFlushHooks() : keep; /** * After session flush hook. */ public (function()) {} afterSessionFlushHooks() : keep;
Processes registered in this will take place a few times every second. So please take caution to not put in heavy computational processes as it CAN and WILL slow down the whole CET Designer software.
Comments
0 comments
Please sign in to leave a comment.