+/** An object that can be configured. */
+class SR_API Configurable
+{
+public:
+ /** Read configuration for the given key.
+ * @param key ConfigKey to read. */
+ Glib::VariantBase config_get(const ConfigKey *key);
+ /** Set configuration for the given key to a specified value.
+ * @param key ConfigKey to set.
+ * @param value Value to set. */
+ void config_set(const ConfigKey *key, Glib::VariantBase value);
+ /** Enumerate available values for the given configuration key.
+ * @param key ConfigKey to enumerate values for. */
+ Glib::VariantContainerBase config_list(const ConfigKey *key);
+ /** Enumerate available keys, according to a given index key. */
+ vector<const ConfigKey *> config_keys(const ConfigKey *key);
+ /** Check for a key in the list from a given index key. */
+ bool config_check(const ConfigKey *key, const ConfigKey *index_key);
+protected:
+ Configurable(
+ struct sr_dev_driver *driver,
+ struct sr_dev_inst *sdi,
+ struct sr_channel_group *channel_group);
+ virtual ~Configurable();
+ struct sr_dev_driver *config_driver;
+ struct sr_dev_inst *config_sdi;
+ struct sr_channel_group *config_channel_group;
+};
+