SMTK
@SMTK_VERSION@
Simulation Modeling Tool Kit
|
10 #ifndef smtk_attribute_ComponentItem_h
11 #define smtk_attribute_ComponentItem_h
13 #include "smtk/attribute/ReferenceItem.h"
15 #include "smtk/resource/Component.h"
27 class ComponentItemDefinition;
58 ComponentPtr
value(std::size_t ii = 0)
const
72 bool appendValue(ComponentPtr value,
bool allowDuplicates =
true)
79 std::string valueAsString(std::size_t ii)
const override;
The main namespace for the Simulation Modeling Tool Kit (SMTK).
Definition: doc.h:33
PersistentObjectPtr value(std::size_t i=0) const
Return the i-th object stored in this item.
Definition: ReferenceItem.cxx:486
Type
Definition: Item.h:56
Stores the definition of an attribute.
Definition: Definition.h:45
std::string valueAsString() const override
Serialize the i-th value to a string.
Definition: ComponentItem.h:78
bool setValue(ComponentPtr value)
Set the i-th value as a component.
Definition: ComponentItem.h:64
bool appendValue(const PersistentObjectPtr &val, bool allowDuplicates=true)
Add val if it is allowed and val is not already present in the item unless allowDuplicates is true.
Definition: ReferenceItem.cxx:634
The base class for items that hold information inside an attribute.
Definition: Item.h:47
bool appendValue(ComponentPtr value, bool allowDuplicates=true)
Append a value to the item if possible.
Definition: ComponentItem.h:72
#define smtkTypeMacro(...)
Add typedefs to a class for identifcation.
Definition: SharedFromThis.h:128
Hold associations that link resources or components as an attribute value.
Definition: ReferenceItem.h:51
Hold resource components as an attribute value.
Definition: ComponentItem.h:43
#define smtkSuperclassMacro(...)
Add a typedef to the superclass of this class.
Definition: SharedFromThis.h:147
Represent a (possibly composite) value according to a definition.
Definition: Attribute.h:50
A definition for attribute items that store component UUIDs as values.
Definition: ComponentItemDefinition.h:26
Component is the base class for records stored in an smtk::resource::Resource.
Definition: Component.h:43
ComponentPtr value(std::size_t ii=0) const
Return the i-th value as a component.
Definition: ComponentItem.h:58
smtk::shared_ptr< smtk::resource::Component > ComponentPtr
Definition: PublicPointerDefs.h:304