X-Git-Url: https://sigrok.org/gitweb/?p=pulseview.git;a=blobdiff_plain;f=pv%2Fdevicemanager.hpp;h=9b8ef3d120a3a4c68f97a9e359156270516ed4eb;hp=43d93a7a88f5778d0bed24bcead6ec1f2e9dc85e;hb=72486b789078f024e4f3404f81118c03b03e2b70;hpb=6f925ba9d6faf1077b73c5a5808259576081716a diff --git a/pv/devicemanager.hpp b/pv/devicemanager.hpp index 43d93a7a..9b8ef3d1 100644 --- a/pv/devicemanager.hpp +++ b/pv/devicemanager.hpp @@ -23,12 +23,16 @@ #include #include #include +#include #include +#include using std::list; using std::map; +using std::set; using std::shared_ptr; using std::string; +using std::vector; namespace Glib { class VariantBase; @@ -40,6 +44,8 @@ class Context; class Driver; } +using sigrok::ConfigKey; + namespace pv { namespace devices { @@ -52,7 +58,8 @@ class Session; class DeviceManager { public: - DeviceManager(shared_ptr context); + DeviceManager(shared_ptr context, + std::string driver, bool do_scan); ~DeviceManager() = default; @@ -61,6 +68,9 @@ public: shared_ptr context(); const list< shared_ptr >& devices() const; + shared_ptr user_spec_device() const; + + bool driver_supported(shared_ptr driver) const; list< shared_ptr > driver_scan( shared_ptr driver, @@ -76,9 +86,14 @@ private: bool compare_devices(shared_ptr a, shared_ptr b); + static map + drive_scan_options(vector user_spec, + set driver_opts); + protected: shared_ptr context_; list< shared_ptr > devices_; + shared_ptr user_spec_device_; }; } // namespace pv