|
MeVisLab Web Toolkit Reference
|
The MLAB.Core.ModuleContext has different states, each state expects certain remote messages and handles them accordingly. More...
Classes | |
| class | MLAB.Core.MCState |
| This is the base class for module context states. More... | |
| class | MLAB.Core.MCStateCreatingModule |
| This module context state is active when the module is being created. More... | |
| class | MLAB.Core.MCStateFailedToCreateModule |
| This module context state is active when the module could not be created due to an error. More... | |
| class | MLAB.Core.MCStateMDLReady |
| This module context state is active when all widget controls and DOM elements are created from the MDL script. More... | |
| class | MLAB.Core.MCStateModuleReady |
| This module context state is active when the module was created and authentication was successful. More... | |
| class | MLAB.Core.MCStateRenderingSlavesActivated |
| This module context state is active when the remote rendering slaves are activated. More... | |
| class | MLAB.Core.MCStateUninitialized |
| This module context state is initially active. More... | |
The MLAB.Core.ModuleContext has different states, each state expects certain remote messages and handles them accordingly.
The initial state is MLAB.Core.MCStateUninitialized. Later MLAB.GUI.Application will call MLAB.Core.ModuleContext.connect() which creates the web socket connection using the MLAB.Core.RemoteManager of the module context.
If the connection was successfully created, then the module context sends a MLAB.Core.ModuleCreateMessage to MeVisLab and changes its state to MLAB.Core.MCStateCreatingModule. After MeVisLab sends a MLAB.Core.ModuleInfoMessage after it has finished the creating the module. MLAB.Core.MCStateCreatingModule then handles this message. Depending on the message status, the next state will be either MLAB.Core.MCStateModuleReady (everything is ok and the module is ready), or MLAB.Core.MCStateFailedToCreateModule.
In case of MLAB.Core.MCStateFailedToCreateModule nothing will be done further.
If MLAB.Core.MCStateModuleReady gets the current state, then it creates the fields (see Fields), notifies the module context that the module is ready, and sends a generic request to the module in MeVisLab to retrieve the MDL tree for the window creation. If the reply to this request is received, then the widget controls are created and the current state is changed to MLAB.Core.MCStateMDLReady. If the html body is already visible or when it gets visible, then the remote rendering slaves are activated and the current and final state is MLAB.Core.MCStateRenderingSlavesActivated.