Workspaces allow for restoring a session or automate the execution of a series of data loading and algorithms in a similar fashion as scripting.
More...
Workspaces allow for restoring a session or automate the execution of a series of data loading and algorithms in a similar fashion as scripting.
This class serves as encapsulation of the individual aspects of workspaces. The workspace state can either be retrieved from an ApplicationController and/or loaded from a workspace file (a XML-serialized form of a workspace). An existing workspace can then be run/executed in an ApplicationController and/or saved to a workspace file.
Workspaces can store the following information:
- A set of algorithms, each described by:
- The Algorithm factory name
- The algorithm Configuration and optionally the corresponding AlgorithmController configuration (if any)
- A list of input Data (if any), each described by a UID
- A list of output Data (if any), each described by a UID
- An
executed flag describing whether the algorithm shall be executed or only opened
- A set of metadata blocks for of datasets, each described by:
- A unique ID (uid) used for cross-referencing within a workspace
- An optional name/title that shall be shown in the DataModel
- An optional transformation matrix
- Optional Properties (only for images)
- A set of DataLink instances that link datasets.
- A set of annotations, each described by:
- An optional parent dataset (described by a UID) under which the annotation is stored in the AnnotationModel
- An optional reference dataset storing annotation data in case of meshes, point clouds, etc.
- Properties storing the configuration
- Optional Display settings
- See also
- Workspaces API, WorkspaceConversionFunction, Placeholders in Workspace Files
|
| void | recordAlgorithm (const Algorithm &algorithm, const AlgorithmController *controller, bool executed, const DataList &inputData, const DataList &outputData, bool keepControllerOpen=false, bool canUseReplayWorkspace=true) |
| | Add an algorithm to be recorded by this workspace.
|
| |
|
void | markAlgorithmAsRemoved (const Algorithm *alg) |
| | Marks an algorithm as removed.
|
| |
|
bool | updateAlgorithmDescription (const Algorithm *alg) |
| | Update the description of a recorded algorithm.
|
| |
|
void | recordSelectionChange (MainWindowBase &mwb, SharedImageSet &sis) |
| | Convenience method to record a SelectionChangeAlgorithm for the given image if needed.
|
| |
| void | retrieveState (ApplicationController &appCtrl) |
| | Retrieve workspace state from the current state of the given ApplicationController.
|
| |
| bool | execute (ApplicationController &appCtrl) |
| | Execute the workspace in the given ApplicationController.
|
| |
|
bool | loadFromFile (const std::string &filename) |
| | Load a workspace state from a file.
|
| |
|
bool | saveToFile (const std::string &filename, Mode mode) |
| | Save the workspace state to an .iws file.
|
| |
|
bool | saveToFile (const std::string &filename) |
| | Save the workspace state to an .iws file. Uses p_saveMode to determine the mode.
|
| |
|
bool | exportAsPython (const std::string &filename) |
| | Export the workspace algorithms as python script.
|
| |
|
void | clear () |
| | Clear the current workspace state.
|
| |
|
bool | isComposed () const |
| | Returns whether the algorithm 'Run Workspace' is in the current workspace.
|
| |
|
void | registerData (Data &data, const std::string &uid) |
| | Register a data under a given uid.
|
| |
|
void | setFallbackDataModel (const DataModel *dm) |
| |
|
void | setSelectedDataComponents (const std::set< std::string > &selectedComps) |
| | Sets the list of DataComponent IDs that will be written to the workspace file on export.
|
| |
|
const std::set< std::string > & | selectedDataComponents () const |
| | Retrieves the list of DataComponent IDs that will be written to the workspace file on export.
|
| |
|
bool | canUseReplayWorkspace () const |
| | Returns whether all algorithms in the history can be replayed (determined by the flag passed in recordAlgorithm)
|
| |
|
| SignalReceiver ()=default |
| | Default constructor.
|
| |
|
| SignalReceiver (const SignalReceiver &other) |
| | Copy constructor, does not copy any existing signal connections from other.
|
| |
|
SignalReceiver & | operator= (SignalReceiver rhs) |
| | Assignment operator, disconnects all existing connections, does not copy any existing signal connections from rhs.
|
| |
|
virtual | ~SignalReceiver () |
| | Virtual destructor disconnects from all connected signals.
|
| |
| virtual void | configure (const Properties *p) |
| | Configure this object instance by de-serializing the given Properties.
|
| |
| virtual void | configuration (Properties *p) const |
| | Serialize the current object configuration into the given Properties object.
|
| |
| virtual void | configureDefaults () |
| | Retrieve the properties of this object, replaces values with their defaults and sets it again.
|
| |
|
void | registerParameter (ParameterBase *param) |
| | Register the given Parameter or SubProperty, so that it will be configured during configure()/configuration().
|
| |
|
void | unregisterParameter (const ParameterBase *param) |
| | Remove the given Parameter or SubProperty from the list of registered parameters.
|
| |
|
| Configurable (const Configurable &rhs) |
| |
|
| Configurable (Configurable &&rhs) noexcept |
| |
|
Configurable & | operator= (const Configurable &) |
| |
|
Configurable & | operator= (Configurable &&) noexcept |
| |
|
|
Parameter< Mode > | p_saveMode {"saveMode", Mode::Replay, this} |
| |
|
Parameter< bool > | p_removeDefaultProperties {"removeDefaultProperties", true, this} |
| |
|
Parameter< bool > | p_removeEmptyProperties {"removeEmptyProperties", true, this} |
| |
|
Parameter< bool > | p_saveAbsolutePaths {"saveAbsolutePaths", false, this} |
| |
|
Parameter< bool > | p_saveDisplayState {"saveDisplayState", true, this} |
| |
|
Parameter< bool > | p_composeWorkspacesInSaving {"composeWorkspacesInSaving", true, this} |
| |
|
Signal | signalParametersChanged |
| | Emitted whenever one of the registered Parameters' or SubPropertys' signalValueChanged signal was emitted.
|
| |