aboutsummaryrefslogtreecommitdiffstats
path: root/src/afb-stub-ws.h
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2017-08-11 16:57:53 +0200
committerJosé Bollo <jose.bollo@iot.bzh>2017-08-11 19:14:54 +0200
commit8406a51db98b563a4562f26de8338efc0478aff2 (patch)
treeac128c56dff7deb508250e7841d05ac4b12fe3e4 /src/afb-stub-ws.h
parent53c7b44e96e6015a4da4f88f22e98b13cfa2e056 (diff)
afb-stub-ws: improvements
The client stub isn't connecting anymore automatically to the apiset. The function 'afb_stub_ws_client_add' provides the feature. The client now returns a afb_api structure. name and on_hangup features added. Change-Id: I204cc39adeb782f5d40360c22c79d14f54dd5c63 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
Diffstat (limited to 'src/afb-stub-ws.h')
-rw-r--r--src/afb-stub-ws.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/afb-stub-ws.h b/src/afb-stub-ws.h
index 33ab5b2f..4e07f982 100644
--- a/src/afb-stub-ws.h
+++ b/src/afb-stub-ws.h
@@ -20,6 +20,7 @@
struct afb_stub_ws;
struct afb_apiset;
+struct afb_api;
extern struct afb_stub_ws *afb_stub_ws_create_client(int fd, const char *apiname, struct afb_apiset *apiset);
@@ -29,3 +30,11 @@ extern void afb_stub_ws_unref(struct afb_stub_ws *stubws);
extern void afb_stub_ws_addref(struct afb_stub_ws *stubws);
+extern void afb_stub_ws_on_hangup(struct afb_stub_ws *stubws, void (*on_hangup)(struct afb_stub_ws*));
+
+extern const char *afb_stub_ws_name(struct afb_stub_ws *stubws);
+
+extern struct afb_api afb_stub_ws_client_api(struct afb_stub_ws *stubws);
+
+extern int afb_stub_ws_client_add(struct afb_stub_ws *stubws, struct afb_apiset *apiset);
+