diff options
Diffstat (limited to 'src/device/device.hpp')
-rw-r--r-- | src/device/device.hpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/device/device.hpp b/src/device/device.hpp index c21456daf..d14b8848c 100644 --- a/src/device/device.hpp +++ b/src/device/device.hpp @@ -202,6 +202,17 @@ namespace hw { ~reset_mode() { hwref.set_mode(hw::device::NONE);} }; - device& get_device(const std::string device_descriptor) ; + class device_registry { + private: + std::map<std::string, std::unique_ptr<device>> registry; + + public: + device_registry(); + bool register_device(const std::string & device_name, device * hw_device); + device& get_device(const std::string & device_descriptor); + }; + + device& get_device(const std::string & device_descriptor); + bool register_device(const std::string & device_name, device * hw_device); } |