SMTK
@SMTK_VERSION@
Simulation Modeling Tool Kit
|
10 #ifndef smtk_task_Group_h
11 #define smtk_task_Group_h
13 #include "smtk/operation/Manager.h"
14 #include "smtk/operation/Observer.h"
15 #include "smtk/operation/Operation.h"
16 #include "smtk/resource/Resource.h"
17 #include "smtk/task/Task.h"
51 Group(
const Configuration& config,
const smtk::common::Managers::Ptr& managers =
nullptr);
55 const smtk::common::Managers::Ptr& managers =
nullptr);
57 ~
Group()
override =
default;
61 std::vector<Task::Ptr> children()
const;
62 bool hasChildren()
const override {
return !m_children.empty(); }
65 const std::vector<std::weak_ptr<smtk::task::Adaptor>>& adaptors()
const {
return m_adaptors; }
74 smtk::common::Managers::Ptr
managers()
const {
return m_managers; }
78 State computeInternalState()
const;
82 smtk::common::Managers::Ptr m_managers;
83 std::map<Task::Ptr, Task::Observers::Key> m_children;
84 std::vector<std::weak_ptr<smtk::task::Adaptor>> m_adaptors;
90 #endif // smtk_task_Group_h
The main namespace for the Simulation Modeling Tool Kit (SMTK).
Definition: doc.h:33
nlohmann::json Configuration
Tasks are configured with arbitrary JSON objects, though this may change.
Definition: Task.h:84
std::set< Ptr > PassedDependencies
A task's dependencies are other tasks passed as shared pointers.
Definition: Task.h:82
bool hasChildren() const override
Return whether or not the task has children.
Definition: Group.h:62
State
The set of states that a task may take on.
Definition: State.h:29
#define smtkCreateMacro(...)
Add static create() methods to a class.
Definition: SharedFromThis.h:113
Visit
Return values common to most visitor methods.
Definition: Visit.h:23
#define smtkTypeMacro(...)
Add typedefs to a class for identifcation.
Definition: SharedFromThis.h:51
Group is a task that owns children and draws its state from them.
Definition: Group.h:43
#define smtkSuperclassMacro(...)
Add a typedef to the superclass of this class.
Definition: SharedFromThis.h:87
Task is a base class for all SMTK tasks.
Definition: Task.h:69
smtk::common::Managers::Ptr managers() const
Return the managers used to configure this Group.
Definition: Group.h:74