SMTK
@SMTK_VERSION@
Simulation Modeling Tool Kit
|
10 #ifndef smtk_task_FillOutAttributes_h
11 #define smtk_task_FillOutAttributes_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"
28 class ResourceAndRole;
73 bool m_autoconfigure =
false;
85 const smtk::common::Managers::Ptr& managers =
nullptr);
90 const smtk::common::Managers::Ptr& managers =
nullptr);
107 bool initializeResources();
109 bool updateResourceEntry(
117 smtk::operation::Operation::Result result);
120 State computeInternalState()
const;
124 static bool testValidity(
132 bool hasRelevantInfomation(
134 bool& foundResources)
const;
135 smtk::common::Managers::Ptr m_managers;
136 smtk::operation::Observers::Key m_observer;
137 std::vector<AttributeSet> m_attributeSets;
142 #endif // smtk_task_FillOutAttributes_h
The main namespace for the Simulation Modeling Tool Kit (SMTK).
Definition: doc.h:33
std::function< smtk::common::Visit(AttributeSet &)> AttributeSetVisitor
Signatures of functors that visit resources-by-role predicates.
Definition: FillOutAttributes.h:78
FillOutAttributes is a task that is incomplete until specified attributes are valid.
Definition: FillOutAttributes.h:40
std::set< smtk::common::UUID > m_valid
Attributes matching a definition that are validated.
Definition: FillOutAttributes.h:54
nlohmann::json Configuration
Tasks are configured with arbitrary JSON objects, though this may change.
Definition: Task.h:89
std::map< smtk::common::UUID, ResourceAttributes > m_resources
The set of resources being managed that are selected by the validator.
Definition: FillOutAttributes.h:75
std::set< std::string > m_instances
The explicit attribute instances in matching resources that need to be valid.
Definition: FillOutAttributes.h:66
std::set< Ptr > PassedDependencies
A task's dependencies are other tasks passed as shared pointers.
Definition: Task.h:87
std::string m_role
The required role. If empty, any role is allowed.
Definition: FillOutAttributes.h:62
A predicate used to collect resources that fit a given role.
Definition: FillOutAttributes.h:59
A task manager is responsible for creating new tasks.
Definition: Manager.h:68
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:173
Visit
Return values common to most visitor methods.
Definition: Visit.h:23
Operation is a base class for all SMTK operations.
Definition: Operation.h:61
#define smtkTypeMacro(...)
Add typedefs to a class for identifcation.
Definition: SharedFromThis.h:128
Configure a task with a resource and role given a dependent producer.
Definition: ResourceAndRole.h:24
smtk::shared_ptr< smtk::attribute::Attribute > AttributePtr
Definition: PublicPointerDefs.h:463
std::set< smtk::common::UUID > m_invalid
Attributes matching a definition that need attention.
Definition: FillOutAttributes.h:56
Store information about attribute definitions and instances.
Definition: Resource.h:76
#define smtkSuperclassMacro(...)
Add a typedef to the superclass of this class.
Definition: SharedFromThis.h:147
std::set< std::string > m_definitions
The definitions in matching resources whose attributes should be valid.
Definition: FillOutAttributes.h:64
Task is a base class for all SMTK tasks.
Definition: Task.h:73
EventType
Enumerate events that an operation may encounter.
Definition: Observer.h:30
smtk::shared_ptr< smtk::resource::Manager > ManagerPtr
Definition: PublicPointerDefs.h:288
Per-resource sets of validated attributes.
Definition: FillOutAttributes.h:51
A container for caching and retrieving instances of types.
Definition: TypeContainer.h:42