Component Manager Mixins
This module defines SKA Tango device mixin classes for using a component manager.
- class ska_tango_base.future._component_manager_mixins.ComponentManagerMixin[source]
Bases:
SignalBusMixin,Generic[ComponentManagerT]An abstract mixin class for using a component manager with a SKA Tango device.
Create the component manager when the shared bus is initialised.
The component manager is created here so that the
SharingObserverbus-propagation mechanism can automatically share the bus with the component manager (which itself should be a subclass ofSharingObserver). TheSharingObserver.shared_bussetter iteratesvars(self)after callingon_new_shared_bus, so assigning_component_managerhere ensures the component manager is found and receives the bus before any signals are emitted.
- property component_manager: ComponentManagerT
Get the component manager.
- create_component_manager() ComponentManagerT[source]
Create and return a component manager for this device.
- Raises:
NotImplementedError – if not overridden by a subclass.
- class ska_tango_base.future._component_manager_mixins.ComponentManagerLRCMixin[source]
Bases:
ComponentManagerMixin[TaskExecutorComponentManagerT],AbstractLRCMixinA mixin class for using a component manager and long running commands.
This mixin is intended to be used with a SKA Tango device which has a component manager that is a subclass of
TaskExecutorComponentManager, which in turn provides a task executor following theTaskExecutorProtocolthat can be used to execute long running tasks.- property task_executor: TaskExecutorProtocol
Get the task executor.
- Returns:
The initialised task executor.
- schedule_abort_task(task_callback: TaskCallbackType) tuple[TaskStatus, str][source]
Schedule an Abort task to begin executing immediately.
Subclasses should override this to change the behaviour of the
Abort()command.- Parameters:
task_callback – Notified of progress of the abort command.
- Returns:
A tuple containing TaskStatus.IN_PROGRESS and a message.