Radium Engine  1.5.20
Loading...
Searching...
No Matches
Ra::Core::Utils::ObjectWithSemantic Class Reference

Object associated with one or multiple semantic names. More...

#include <Core/Utils/ObjectWithSemantic.hpp>

+ Inheritance diagram for Ra::Core::Utils::ObjectWithSemantic:
+ Collaboration diagram for Ra::Core::Utils::ObjectWithSemantic:

Public Types

using SemanticName = std::string
 
using SemanticNameCollection = std::set<SemanticName>
 Store in set to allow for logarithmic search.
 

Public Member Functions

 ObjectWithSemantic (const ObjectWithSemantic &other)
 
bool hasSemantic (const SemanticName &name) const
 
const SemanticNameCollectionsemantics () const
 
ObjectWithSemanticoperator= (const ObjectWithSemantic &other)
 
ObjectWithSemanticoperator= (ObjectWithSemantic &&other)
 
bool shareSemantic (const ObjectWithSemantic &other) const
 
bool sameSemantics (const ObjectWithSemantic &other) const
 

Protected Member Functions

template<class... SemanticNames>
 ObjectWithSemantic (SemanticNames... names)
 
 ObjectWithSemantic (const SemanticNameCollection &otherNames)
 

Detailed Description

Object associated with one or multiple semantic names.

Holds a static collection of names (SemanticNameCollection) that are defined by the inheriting class when calling the protected constructor. Provides hasSemantic to test if one object has a given semantic name, as well as shareSemantic and sameSemantics to compare different objects.

Definition at line 17 of file ObjectWithSemantic.hpp.

Member Typedef Documentation

◆ SemanticName

◆ SemanticNameCollection

Store in set to allow for logarithmic search.

Definition at line 23 of file ObjectWithSemantic.hpp.

Constructor & Destructor Documentation

◆ ObjectWithSemantic() [1/3]

Ra::Core::Utils::ObjectWithSemantic::ObjectWithSemantic ( const ObjectWithSemantic & other)
inlineexplicit

Definition at line 25 of file ObjectWithSemantic.hpp.

◆ ObjectWithSemantic() [2/3]

template<class... SemanticNames>
Ra::Core::Utils::ObjectWithSemantic::ObjectWithSemantic ( SemanticNames... names)
inlineexplicitprotected

Definition at line 59 of file ObjectWithSemantic.hpp.

◆ ObjectWithSemantic() [3/3]

Ra::Core::Utils::ObjectWithSemantic::ObjectWithSemantic ( const SemanticNameCollection & otherNames)
inlineexplicitprotected

Definition at line 61 of file ObjectWithSemantic.hpp.

Member Function Documentation

◆ hasSemantic()

bool Ra::Core::Utils::ObjectWithSemantic::hasSemantic ( const SemanticName & name) const
inline

Definition at line 30 of file ObjectWithSemantic.hpp.

◆ operator=() [1/2]

ObjectWithSemantic & Ra::Core::Utils::ObjectWithSemantic::operator= ( const ObjectWithSemantic & other)
inline

Definition at line 36 of file ObjectWithSemantic.hpp.

◆ operator=() [2/2]

ObjectWithSemantic & Ra::Core::Utils::ObjectWithSemantic::operator= ( ObjectWithSemantic && other)
inline

Definition at line 41 of file ObjectWithSemantic.hpp.

◆ sameSemantics()

bool Ra::Core::Utils::ObjectWithSemantic::sameSemantics ( const ObjectWithSemantic & other) const
inline

Definition at line 53 of file ObjectWithSemantic.hpp.

◆ semantics()

const SemanticNameCollection & Ra::Core::Utils::ObjectWithSemantic::semantics ( ) const
inline

Definition at line 34 of file ObjectWithSemantic.hpp.

◆ shareSemantic()

bool Ra::Core::Utils::ObjectWithSemantic::shareSemantic ( const ObjectWithSemantic & other) const
inline

Definition at line 47 of file ObjectWithSemantic.hpp.


The documentation for this class was generated from the following file: