summaryrefslogtreecommitdiffstats
path: root/ahl-binding/ahl-binding.hpp
diff options
context:
space:
mode:
authorLoïc Collignon <loic.collignon@iot.bzh>2018-12-18 11:29:42 +0100
committerLoïc Collignon <loic.collignon@iot.bzh>2018-12-20 18:13:14 +0100
commitd0fc54659d0f6d5e6110e607f4ee49b52b0387d5 (patch)
treee83e0cd45fac07024bf9c2e46f528edf3fc3d20e /ahl-binding/ahl-binding.hpp
parent57faac0038cdfd2ed2c113e7ae5a752fe5aa99a4 (diff)
Clean up some code
Added comments, remove unused declarations and move around some declarations and implementations to be more logic and tidy. Change-Id: I4b392f9aa2471067b6d102532b620acc6afe3cb2 Signed-off-by: Loïc Collignon <loic.collignon@iot.bzh>
Diffstat (limited to 'ahl-binding/ahl-binding.hpp')
-rw-r--r--ahl-binding/ahl-binding.hpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/ahl-binding/ahl-binding.hpp b/ahl-binding/ahl-binding.hpp
index 9e670bb..881d906 100644
--- a/ahl-binding/ahl-binding.hpp
+++ b/ahl-binding/ahl-binding.hpp
@@ -46,31 +46,26 @@ private:
explicit ahl_binding_t();
void load_static_verbs();
-
-
void load_controller_configs();
int load_controller_config(const std::string& path);
int update_streams();
void update_stream(std::string hal, std::string stream, std::string deviceuri);
int create_api_verb(role_t* r);
- void policy_open(afb_req_t req, const role_t& role);
-
public:
static ahl_binding_t& instance();
+ afb_api_t handle() const;
+ const std::vector<role_t> roles() const;
+
int preinit(afb_api_t handle);
int init();
void event(std::string name, json_object* arg);
+ int emit_volume_changed(const std::string& role, int volume) const;
+ int parse_roles_config(json_object* o);
+
void get_roles(afb_req_t req) const;
void subscribe(afb_req_t req) const;
void unsubscribe(afb_req_t req) const;
- int emit_volume_changed(const std::string& role, int volume) const;
-
- const std::vector<role_t> roles() const;
- afb_api_t handle() const;
-
- void audiorole(afb_req_t req);
- int parse_roles_config(json_object* o);
};