The base class for various component types. More...
#include <cadex/PMI/SemanticComponent.hxx>
Public Member Functions | |
void | AddAttribute (const SemanticAttribute &theAttribute) |
Adds the attribute. | |
const std::vector< PMI::SemanticAttribute > & | Attributes () const |
Returns the attributes. | |
bool | HasAttributes () const |
Returns true if semantic attributes were added and false otherwise. | |
size_t | NumberOfAttributes () const |
Returns the number of added attributes. | |
void | Accept (SemanticAttributeVisitor &theVisitor) const |
Accepts an attribute visitor. | |
void | Accept (SemanticComponentVisitor &theVisitor) const |
Accepts the visitor. | |
![]() | |
size_t | Id () const |
Return unique identifier of public object. | |
internal::BaseObjectImpl * | Impl () const |
bool | IsNull () const |
operator bool () const | |
template<typename T > | |
bool | IsOfType () const |
template<typename T > | |
T * | Impl () const |
Reserved for internal use. | |
Static Public Member Functions | |
static bool | CompareType (const BaseObject &theObject) |
Returns true if theObject has the SemanticComponent type. | |
Protected Member Functions | |
SemanticComponent (const ImplType &theImpl) | |
![]() | |
BaseObject (const ImplType &theImpl) | |
Additional Inherited Members | |
![]() | |
typedef std::shared_ptr< internal::BaseObjectImpl > | ImplType |
The base class for various component types.
Contains a collection of PMI semantic attributes that are specific to each derived component.
void cadex::PMI::SemanticComponent::Accept | ( | SemanticAttributeVisitor & | theVisitor | ) | const |
Accepts an attribute visitor.
The order of visiting will match the order of adding attributes with AddAttribute().
const std::vector< PMI::SemanticAttribute > & cadex::PMI::SemanticComponent::Attributes | ( | ) | const |
Returns the attributes.
bool cadex::PMI::SemanticComponent::HasAttributes | ( | ) | const |
Returns true if semantic attributes were added and false otherwise.
Returns false if IsNull().
size_t cadex::PMI::SemanticComponent::NumberOfAttributes | ( | ) | const |
Returns the number of added attributes.
Returns 0 if IsNull().