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;
40 class SMTKCORE_EXPORT FillOutAttributes :
public Task
51 struct ResourceAttributes
54 std::set<smtk::common::UUID> m_valid;
56 std::set<smtk::common::UUID> m_invalid;
64 std::set<std::string> m_definitions;
73 bool m_autoconfigure =
false;
75 std::map<smtk::common::UUID, ResourceAttributes> m_resources;
84 const smtk::common::Managers::Ptr& managers =
nullptr);
88 const smtk::common::Managers::Ptr& managers =
nullptr);
105 bool initializeResources();
107 bool updateResourceEntry(
115 smtk::operation::Operation::Result result);
118 State computeInternalState()
const;
122 static bool testValidity(
130 bool hasRelevantInfomation(
132 bool& foundResources)
const;
133 smtk::common::Managers::Ptr m_managers;
134 smtk::operation::Observers::Key m_observer;
135 std::vector<AttributeSet> m_attributeSets;
140 #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: ConfigureOperation.h:71
Creating a Task that requires an operation to be executed NOTE - this is just a place holder - as you...
Definition: ConfigureOperation.h:35
nlohmann::json Configuration
Tasks are configured with arbitrary JSON objects, though this may change.
Definition: Task.h:84
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:82
A predicate used to collect resources that fit a given role.
Definition: ConfigureOperation.h:54
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
Operation is a base class for all SMTK operations.
Definition: Operation.h:51
#define smtkTypeMacro(...)
Add typedefs to a class for identifcation.
Definition: SharedFromThis.h:51
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:456
Store information about attribute definitions and instances.
Definition: Resource.h:77
#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
EventType
Enumerate events that an operation may encounter.
Definition: Observer.h:30
smtk::shared_ptr< smtk::resource::Manager > ManagerPtr
Definition: PublicPointerDefs.h:281
Per-resource sets of validated attributes.
Definition: ConfigureOperation.h:46
A container for caching and retrieving instances of types.
Definition: TypeContainer.h:37