-
-struct afb_context
-{
- void *context;
- void (*free_context)(void*);
-};
-
-extern void *afb_context_get(struct afb_context *actx);
-extern void afb_context_set(struct afb_context *actx, void *context, void (*free_context)(void*));
-
-struct afb_event_listener_itf
-{
- void (*send)(void *closure, const char *event, struct json_object *object);
-};
-
-struct afb_event_listener
-{
- const struct afb_event_listener_itf *itf;
- void *closure;
-};
-
-struct afb_event_listener_list;
-
-struct AFB_clientCtx
-{
- int created;
- unsigned refcount;
- time_t expiration; // expiration time of the token
- struct afb_context *contexts;
- char uuid[37]; // long term authentication of remote client
- char token[37]; // short term authentication of remote client
- struct afb_event_listener_list *listeners;
-};