exopy.measurement.workspace.workspace module¶
Workspace used for editing and executing measures.
-
class
exopy.measurement.workspace.workspace.
MeasurementSpace
(parent=None, **kwargs)[source]¶ Bases:
enaml.workbench.ui.workspace.Workspace
Workspace dedicated tot measurement edition and execution.
-
plugin
¶ Reference to the plugin to which the workspace is linked.
-
log_model
¶ Reference to the log panel model received from the log plugin.
-
last_selected_measurement
¶ Reference to the last edited measurement used for saving.
-
window_title
¶ A value of type unicode.
By default, plain strings will be promoted to unicode strings. Pass strict=True to the constructor to enable strict unicode checking.
-
start
()[source]¶ Start the workspace, create a blanck measurement if necessary and get engine contribution.
-
new_measurement
(dock_item=None)[source]¶ Create a new edited measurement using the default tools.
- Parameters
dock_item – Dock item used for editing the measurement, if None a new item will be created and inserted in the dock area.
-
save_measurement
(measurement, auto=True)[source]¶ Save a measurement in a file.
- Parameters
measurement (Measurement) – Measurement to save.
auto (bool, optional) – When true if a path is associated to the measurement save it there, otherwise ask the user where to save it.
-
load_measurement
(mode, dock_item=None)[source]¶ Load a measurement.
- Parameters
mode ({'file', 'template'}) – In file mode, ask the user to specify a file from which to load a measurement. In template mode, ask the user to choose a template and use the defaults settings of the plugin for the tools..
-
enqueue_measurement
(measurement)[source]¶ Put a measurement in the queue if it pass the tests.
- Parameters
measurement (Measurement) – Instance of Measurement representing the measurement.
- Returns
True if the measurement was successfully enqueued, False otherwise.
- Return type
-
reenqueue_measurement
(measurement)[source]¶ Mark a measurement already in queue as fitted to be executed.
This method can be used to re-enqueue a measurement that previously failed, for example because a profile was missing, the measurement can then be edited again and will be executed in its turn.
WARNING : the test are run again !!!
- Parameters
measurement (Measurement) – The measurement to re-enqueue
-
remove_processed_measurements
()[source]¶ Remove all the measures which have been processed from the queue.
This method rely on the status of the measurement. Only measures whose status is ‘READY’ will be left in the queue.
-
start_processing_measurements
()[source]¶ Starts to perform the measurement in the queue.
Measurement are processed in their order of appearance in the queue.
-
process_single_measurement
(measurement)[source]¶ Performs a single measurement and then stops.
- Parameters
measurement (Measurement) – Measurement to perform.
-
stop_current_measurement
(no_post_exec=False, force=False)[source]¶ Stop the execution of the currently executed measurement.
-
stop_processing_measurements
(no_post_exec=False, force=False)[source]¶ Stop processing enqueued measurement.
-
property
dock_area
¶ Getter for the dock_area of the content.
-