Base capability class.
More...
|
| static bool | isCapabilityTypeRegistered (const std::type_info &oCapabilityType) noexcept |
| | Tells whether a capability type was registered. More...
|
| |
| static const std::type_info & | getCapabilityClassIdType (const std::string &sCapabilityClassId, bool &bRegistered) noexcept |
| | Gets the type of the registered capability subclass associated with class id. More...
|
| |
| static std::string | getCapabilityTypeClassId (const std::type_info &oType) noexcept |
| | Gets the class id of the given type. More...
|
| |
◆ ~Capability()
| virtual stmi::Capability::~Capability |
( |
| ) |
|
|
virtualdefaultnoexcept |
◆ Capability()
| stmi::Capability::Capability |
( |
const Class & |
oClass | ) |
|
|
explicitprotectednoexcept |
Constructor to be called from subclasses.
The registered type has to be the actual class of the instance being constructed or a superclass of it.
- Parameters
-
| oClass | The registered class of the capability. Cannot be empty. |
◆ getCapabilityClass()
| const Class& stmi::Capability::getCapabilityClass |
( |
| ) |
const |
|
inlinenoexcept |
Get the registered class of the capability instance.
- Returns
- The registered class. Cannot be empty.
◆ getCapabilityClassIdClass()
| static Class stmi::Capability::getCapabilityClassIdClass |
( |
const std::string & |
sCapabilityClassId | ) |
|
|
staticnoexcept |
Gets the class with given class id.
- Parameters
-
| sCapabilityClassId | The registered class id. |
- Returns
- The class. Might be empty if sCapabilityClassId is not registered.
◆ getCapabilityClassIdType()
| static const std::type_info& stmi::Capability::getCapabilityClassIdType |
( |
const std::string & |
sCapabilityClassId, |
|
|
bool & |
bRegistered |
|
) |
| |
|
staticprotectednoexcept |
Gets the type of the registered capability subclass associated with class id.
- Parameters
-
| sCapabilityClassId | The type string. |
| bRegistered | Whether the return value is valid. |
- Returns
- The registered type. If bRegistered is
false the result is undefined.
◆ getCapabilityTypeClassId()
| static std::string stmi::Capability::getCapabilityTypeClassId |
( |
const std::type_info & |
oType | ) |
|
|
staticprotectednoexcept |
Gets the class id of the given type.
- Parameters
-
| oType | The type to be tested. |
- Returns
- The class id or an empty string if the type is not registered.
◆ getDevice()
| virtual shared_ptr<Device> stmi::Capability::getDevice |
( |
| ) |
const |
|
pure virtualnoexcept |
◆ getId()
| int32_t stmi::Capability::getId |
( |
| ) |
const |
|
inlinenoexcept |
The capability id.
- Returns
- The unique id of the capability.
◆ isCapabilityClassIdRegistered()
| static bool stmi::Capability::isCapabilityClassIdRegistered |
( |
const std::string & |
sCapabilityClassId | ) |
|
|
staticnoexcept |
Tells whether the given capability class id is registered.
- Parameters
-
| sCapabilityClassId | The class id. |
- Returns
- Whether registered.
◆ isCapabilityTypeRegistered()
| static bool stmi::Capability::isCapabilityTypeRegistered |
( |
const std::type_info & |
oCapabilityType | ) |
|
|
staticprotectednoexcept |
Tells whether a capability type was registered.
- Parameters
-
| oCapabilityType | The c++ typeid of a class. |
- Returns
- Whether the class was registered.