aboutsummaryrefslogtreecommitdiffstats
path: root/libnavi/include/RequestManage.h
diff options
context:
space:
mode:
authorMatt Ranostay <matt.ranostay@konsulko.com>2019-10-19 13:45:11 -0700
committerMatt Ranostay <matt.ranostay@konsulko.com>2019-10-31 01:59:13 -0700
commit3e94024998c1615bd30306aab7537db22161a9ce (patch)
tree6bea3ac4de640d98c8c27ffd0c02f9eb86ca0773 /libnavi/include/RequestManage.h
parent9539611e896e61e27154bbb5917188753a983871 (diff)
binding: navigation: rewrite of navigation binding
To remove dependency on DBus the binding needed to be rewritten to output pure JSON output to subscribed consumers. Bug-AGL: SPEC-2880 Change-Id: Ie85dfccd42ca36119116a0fbfb16bf4e96efc184 Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
Diffstat (limited to 'libnavi/include/RequestManage.h')
-rw-r--r--libnavi/include/RequestManage.h64
1 files changed, 0 insertions, 64 deletions
diff --git a/libnavi/include/RequestManage.h b/libnavi/include/RequestManage.h
deleted file mode 100644
index 05ffcdf..0000000
--- a/libnavi/include/RequestManage.h
+++ /dev/null
@@ -1,64 +0,0 @@
-// Copyright 2017 AISIN AW CO.,LTD
-
-#pragma once
-
-#include <stdint.h>
-#include <string>
-#include <pthread.h>
-
-extern "C" {
- #include <afb/afb-wsj1.h>
- #include <afb/afb-ws-client.h>
-}
-
-#include "RequestManageListener.h"
-
-/**
-* @brief Class for request
-*/
-class RequestManage
-{
-public:
- pthread_cond_t cond;
- pthread_mutex_t mutex;
-
- struct afb_wsj1* wsj1;
- std::string* requestURL;
- struct afb_wsj1_itf wsj1_itf;
-
-private:
- RequestManageListener* listener;
- int request_cnt;
- uint32_t sessionHandle;
- uint32_t routeHandle;
-
- // Function called from thread
- static void* BinderThread(void* param);
-
- // Callback function
- void OnReply(struct afb_wsj1_msg *msg);
- void OnHangup(struct afb_wsj1 *wsj1);
- void OnCallStatic(const char *api, const char *verb, struct afb_wsj1_msg *msg);
- void OnEventStatic(const char *event, struct afb_wsj1_msg *msg);
-
- static void OnReplyStatic(void *closure, struct afb_wsj1_msg *msg);
- static void OnHangupStatic(void *closure, struct afb_wsj1 *wsj1);
- static void OnCallStatic(void *closure, const char *api, const char *verb, struct afb_wsj1_msg *msg);
- static void OnEventStatic(void *closure, const char *event, struct afb_wsj1_msg *msg);
-
-// ==================================================================================================
-// public
-// ==================================================================================================
-public:
- RequestManage();
- ~RequestManage();
-
- bool Connect(const char* api_url, RequestManageListener* listener);
- bool IsConnect();
- bool CallBinderAPI(const char *api, const char *verb, const char *object);
- void SetSessionHandle(uint32_t session);
- uint32_t GetSessionHandle();
- void SetRouteHandle(uint32_t route);
- uint32_t GetRouteHandle();
-};
-