BeeeOn Gateway  v2020.3.1-2-g6f737dc
Platform to interconnect the IoT world
Data Structures | Public Member Functions | Protected Member Functions
BeeeOn::SpecificZWaveMapperRegistry Class Reference

SpecificZWaveMapperRegistry implements the method resolve() generically. The subclass of SpecificZWaveMapperRegistry should register a special instantiator creating the appropriate Mapper implementation based on the vendor and product IDs of Z-Wave nodes. More...

#include <SpecificZWaveMapperRegistry.h>

Inheritance diagram for BeeeOn::SpecificZWaveMapperRegistry:
BeeeOn::ZWaveMapperRegistry BeeeOn::Loggable BeeeOn::AeotecZWaveMapperRegistry BeeeOn::ClimaxZWaveMapperRegistry BeeeOn::FibaroZWaveMapperRegistry BeeeOn::ST02L1ZWaveMapperRegistry

Data Structures

class  MapperInstantiator
 Instantiator of specific Mapper implementations. More...
 
class  SimpleMapperInstantiator
 Template implementation of MapperInstantiator creating MapperType instances having constructor specified as: MapperType(const ZWaveNode::Identity &, const std::string &). More...
 
struct  Spec
 Specification of a Z-Wave node to match. More...
 

Public Member Functions

Mapper::Ptr resolve (const ZWaveNode &node) override
 Try to resolve a Mapper implementation suitable for the given Z-Wave node.
 
void setSpecMap (const std::map< std::string, std::string > &specMap)
 Set the spec mapping where the map key is a string in form: VENDOR:PRODUCT and the value is the name of MapperInstantiator to be used.
 

Protected Member Functions

void registerInstantiator (const std::string &name, MapperInstantiator::Ptr instantiator)
 The subclass would call this method for each instantiator type it offers. The name of instantiator is referred from the specMap property. More...
 
- Protected Member Functions inherited from BeeeOn::Loggable
void setupLogger (Poco::Logger *logger=0) const
 
Poco::Logger & logger () const
 
 Loggable (const ClassInfo &info)
 
 Loggable (const std::type_info &info)
 

Additional Inherited Members

- Public Types inherited from BeeeOn::ZWaveMapperRegistry
typedef Poco::SharedPtr
< ZWaveMapperRegistry
Ptr
 
- Static Protected Member Functions inherited from BeeeOn::Loggable
static Poco::Logger & forMethod (const char *name)
 
static Poco::Logger & forClass (const ClassInfo &info)
 
static Poco::Logger & forClass (const std::type_info &info)
 
template<typename T >
static Poco::Logger & forInstance (const T *i)
 
static void configureSimple (Poco::Logger &logger, const std::string &level)
 
static void logException (Poco::Logger &logger, const Poco::Message::Priority priority, const Poco::Exception &e, const char *file, size_t line)
 

Detailed Description

SpecificZWaveMapperRegistry implements the method resolve() generically. The subclass of SpecificZWaveMapperRegistry should register a special instantiator creating the appropriate Mapper implementation based on the vendor and product IDs of Z-Wave nodes.

Member Function Documentation

void SpecificZWaveMapperRegistry::registerInstantiator ( const std::string &  name,
MapperInstantiator::Ptr  instantiator 
)
protected

The subclass would call this method for each instantiator type it offers. The name of instantiator is referred from the specMap property.

See Also
setSpecMap()

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