exopy.tasks.plugin module¶
Plugin centralizing the collection and managment of tasks and interfaces.
-
class
exopy.tasks.plugin.
TaskManagerPlugin
[source]¶ Bases:
exopy.utils.plugin_tools.HasPreferencesPlugin
Plugin responsible for collecting and providing tasks.
-
templates
¶ Known templates (store full path to .ini). This should not be manipulated by user code.
-
filters
¶ List of the filters.
-
auto_task_path
¶ Path to the file in which the names for the tasks are located.
-
auto_task_names
¶ List of names to use when creating a new task.
-
list_tasks
(filter='All')[source]¶ List the known tasks using the specified filter.
- Parameters
filter (
unicode
, optional) – Name of the filter to use- Returns
tasks – Task ids selected by the filter, or None if the filter does not exist.
- Return type
list(unicode)
orNone
-
get_task_infos
(task)[source]¶ Access a given task infos.
- Parameters
task (
unicode
) – Id of the task class for which to return the actual class.- Returns
infos – Object containing all the infos about the requested task. This object should never be manipulated directly by user code.
- Return type
TaskInfos
orNone
-
get_task
(task, view=False)[source]¶ Access a given task class.
- Parameters
task (
unicode
) – Id of the task class for which to return the actual class.view (
bool
, optional) – Whether or not to return the view assoicated with the task.
- Returns
-
get_interface_infos
(interface)[source]¶ Access a given interface infos.
- Parameters
interface (
unicode
) – Id of the task this interface is linked to followed by the ids of the intermediate interfaces if any and finally id of the interface itself. All ids should be separated by ‘:’ ex ‘exopy.LoopTask:exopy.IterableLoopInterface’views (
bool
, optional) – Whether or not to return the views assoicated with the interface.
- Returns
infos – Object containing all the infos about the requested interface. this object should never be manipulated directly by user code.
- Return type
InterfaceInfos
-
get_interface
(interface, views=False)[source]¶ Access a given interface class.
- Parameters
interface (
tuple[unicode|tuple|list]
) –Name of the task class for which to return the actual class.
Name of the task to which this interface is linked and names of the intermediate interfaces if any (going from the most general ones to the more specialised ones).
views (
bool
, optional) – Whether or not to return the views assoicated with the interface.
- Returns
-
get_interfaces
(interfaces)[source]¶ Access an ensemble of interface classes.
- Parameters
interfaces (
list[tuple[unicode|tuple|list]]
) – List of pairs (name of the interface class, corrisponding anchor) for which to return the actual classes.- Returns
-