From 4521c1e7ae5371ab9d639adc617d17fb4e8ded0c Mon Sep 17 00:00:00 2001 From: José Bollo Date: Mon, 9 Apr 2018 18:16:07 +0200 Subject: api-v3: First draft MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit introduces the bindings v3 API for bindings. The documentation has still to be improved and will come very soon. Change-Id: I8f9007370e29f671fdfd1da87fff7372a17db7af Signed-off-by: José Bollo --- bindings/tutorial/tuto-1.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'bindings/tutorial/tuto-1.c') diff --git a/bindings/tutorial/tuto-1.c b/bindings/tutorial/tuto-1.c index 433a4ebb..1f58be6c 100644 --- a/bindings/tutorial/tuto-1.c +++ b/bindings/tutorial/tuto-1.c @@ -1,18 +1,18 @@ -#define AFB_BINDING_VERSION 2 +#define AFB_BINDING_VERSION 3 #include -void hello(afb_req req) +void hello(afb_req_t req) { AFB_REQ_DEBUG(req, "hello world"); - afb_req_success(req, NULL, "hello world"); + afb_req_reply(req, NULL, NULL, "hello world"); } -const afb_verb_v2 verbs[] = { +const afb_verb_t verbs[] = { { .verb="hello", .callback=hello }, { .verb=NULL } }; -const afb_binding_v2 afbBindingV2 = { +const afb_binding_t afbBindingExport = { .api = "tuto-1", .verbs = verbs }; -- cgit 1.2.3-korg