From 31ff5ce755d00cf12ea2ffc96c33ed9acd36358f Mon Sep 17 00:00:00 2001 From: wang_zhiqiang Date: Wed, 21 Nov 2018 16:32:29 +0800 Subject: update doc add new sequence and update doxygen files. Change-Id: I6737939eb2628577d58b2d1d65086e46e7cb14a4 Signed-off-by: wang_zhiqiang --- doc/api-ref/html/dd/d1d/hs-helper_8c.html | 361 --------------------- doc/api-ref/html/dd/d1d/hs-helper_8c_source.html | 91 ------ doc/api-ref/html/dd/d30/hs-clientmanager_8cpp.html | 170 ++++++++++ .../html/dd/d30/hs-clientmanager_8cpp_source.html | 133 ++++++++ doc/api-ref/html/dd/d86/structevent-members.html | 78 ----- .../dd/dc9/class_h_s___client_manager-members.html | 118 +++++++ doc/api-ref/html/dd/ddc/structgeometry.html | 142 ++++++++ 7 files changed, 563 insertions(+), 530 deletions(-) delete mode 100644 doc/api-ref/html/dd/d1d/hs-helper_8c.html delete mode 100644 doc/api-ref/html/dd/d1d/hs-helper_8c_source.html create mode 100644 doc/api-ref/html/dd/d30/hs-clientmanager_8cpp.html create mode 100644 doc/api-ref/html/dd/d30/hs-clientmanager_8cpp_source.html delete mode 100644 doc/api-ref/html/dd/d86/structevent-members.html create mode 100644 doc/api-ref/html/dd/dc9/class_h_s___client_manager-members.html create mode 100644 doc/api-ref/html/dd/ddc/structgeometry.html (limited to 'doc/api-ref/html/dd') diff --git a/doc/api-ref/html/dd/d1d/hs-helper_8c.html b/doc/api-ref/html/dd/d1d/hs-helper_8c.html deleted file mode 100644 index ce8d1bd..0000000 --- a/doc/api-ref/html/dd/d1d/hs-helper_8c.html +++ /dev/null @@ -1,361 +0,0 @@ - - - - - - - -HomeScreenBinding: src/hs-helper.c File Reference - - - - - - - - - -
-
- - - - - - -
-
HomeScreenBinding -
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
- -
-
hs-helper.c File Reference
-
-
-
#include "hs-helper.h"
-#include <stdlib.h>
-#include <string.h>
-#include <limits.h>
-#include <json-c/json.h>
-#include <stdarg.h>
-
-

Go to the source code of this file.

- - - - - - - - - - - - - - - - -

-Functions

REQ_ERROR get_value_uint16 (const struct afb_req request, const char *source, uint16_t *out_id)
 
REQ_ERROR get_value_int16 (const struct afb_req request, const char *source, int16_t *out_id)
 
REQ_ERROR get_value_int32 (const struct afb_req request, const char *source, int32_t *out_id)
 
void hs_add_object_to_json_object (struct json_object *j_obj, int count,...)
 
void hs_add_object_to_json_object_str (struct json_object *j_obj, int count,...)
 
void hs_add_object_to_json_object_func (struct json_object *j_obj, const char *verb_name, int count,...)
 
int hs_search_event_name_index (const char *value)
 
-

Function Documentation

- -

◆ get_value_int16()

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
REQ_ERROR get_value_int16 (const struct afb_req request,
const char * source,
int16_t * out_id 
)
-
- -

Definition at line 48 of file hs-helper.c.

-
49 {
50  char* endptr;
51  const char* tmp = afb_req_value (request, source);
52  if(!tmp)
53  {
54  return REQ_FAIL;
55  }
56  long tmp_id = strtol(tmp,&endptr,10);
57 
58  /* error check of range */
59  if( (tmp_id > INT16_MAX) || (tmp_id < INT16_MIN) )
60  {
61  return OUT_RANGE;
62  }
63  if(*endptr != '\0')
64  {
65  return NOT_NUMBER;
66  }
67 
68  *out_id = (int16_t)tmp_id;
69  return REQ_OK;
70 }
- - - -
-
-
- -

◆ get_value_int32()

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
REQ_ERROR get_value_int32 (const struct afb_req request,
const char * source,
int32_t * out_id 
)
-
- -

Definition at line 72 of file hs-helper.c.

-
73 {
74  char* endptr;
75  const char* tmp = afb_req_value (request, source);
76  if(!tmp)
77  {
78  return REQ_FAIL;
79  }
80  long tmp_id = strtol(tmp,&endptr,10);
81 
82  /* error check of range */
83  if( (tmp_id > INT32_MAX) || (tmp_id < INT32_MIN) )
84  {
85  return OUT_RANGE;
86  }
87  if(*endptr != '\0')
88  {
89  return NOT_NUMBER;
90  }
91 
92  *out_id = (int32_t)tmp_id;
93  return REQ_OK;
94 }
- - - -
-
-
- -

◆ get_value_uint16()

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
REQ_ERROR get_value_uint16 (const struct afb_req request,
const char * source,
uint16_t * out_id 
)
-
- -

Definition at line 24 of file hs-helper.c.

-
25 {
26  char* endptr;
27  const char* tmp = afb_req_value (request, source);
28  if(!tmp)
29  {
30  return REQ_FAIL;
31  }
32  long tmp_id = strtol(tmp,&endptr,10);
33 
34  /* error check of range */
35  if( (tmp_id > UINT16_MAX) || (tmp_id < 0) )
36  {
37  return OUT_RANGE;
38  }
39  if(*endptr != '\0')
40  {
41  return NOT_NUMBER;
42  }
43 
44  *out_id = (uint16_t)tmp_id;
45  return REQ_OK;
46 }
- - - -
-
-
- -

◆ hs_add_object_to_json_object()

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
void hs_add_object_to_json_object (struct json_object * j_obj,
int count,
 ... 
)
-
- -

Definition at line 96 of file hs-helper.c.

-
97 {
98  va_list args;
99  va_start(args, count);
100  for(int i = 0; i < count; ++i )
101  {
102  char *key = va_arg(args, char*);
103  int value = va_arg(args, int);
104  json_object_object_add(j_obj, key, json_object_new_int((int32_t)value));
105  ++i;
106  }
107  va_end(args);
108 }
-
-
- -

◆ hs_add_object_to_json_object_func()

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
void hs_add_object_to_json_object_func (struct json_object * j_obj,
const char * verb_name,
int count,
 ... 
)
-
- -

Definition at line 125 of file hs-helper.c.

-
126 {
127  va_list args;
128  va_start(args, count);
129 
130  json_object_object_add(j_obj,"verb", json_object_new_string(verb_name));
131 
132  for(int i = 0; i < count; ++i )
133  {
134  char *key = va_arg(args, char*);
135  int value = va_arg(args, int);
136  json_object_object_add(j_obj, key, json_object_new_int((int32_t)value));
137  ++i;
138  }
139  va_end(args);
140 }
-
-
- -

◆ hs_add_object_to_json_object_str()

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
void hs_add_object_to_json_object_str (struct json_object * j_obj,
int count,
 ... 
)
-
- -

Definition at line 110 of file hs-helper.c.

-
111 {
112  va_list args;
113  va_start(args, count);
114  for(int i = 0; i < count; ++i )
115  {
116  char *key = va_arg(args, char*);
117  char *value = va_arg(args, char*);
118  json_object_object_add(j_obj, key, json_object_new_string(value));
119  ++i;
120  }
121  va_end(args);
122 }
-
-
- -

◆ hs_search_event_name_index()

- -
-
- - - - - - - - -
int hs_search_event_name_index (const char * value)
-
- -

Definition at line 142 of file hs-helper.c.

-
143 {
144  size_t buf_size = 50;
145  size_t size = sizeof evlist / sizeof *evlist;
146  int ret = -1;
147  for(size_t i = 0 ; i < size ; ++i)
148  {
149  if(!strncmp(value, evlist[i], buf_size))
150  {
151  ret = i;
152  break;
153  }
154  }
155  return ret;
156 }
static const char * evlist[]
Definition: hs-helper.h:34
-
-
-
-
- - - - diff --git a/doc/api-ref/html/dd/d1d/hs-helper_8c_source.html b/doc/api-ref/html/dd/d1d/hs-helper_8c_source.html deleted file mode 100644 index 792ec9d..0000000 --- a/doc/api-ref/html/dd/d1d/hs-helper_8c_source.html +++ /dev/null @@ -1,91 +0,0 @@ - - - - - - - -HomeScreenBinding: src/hs-helper.c Source File - - - - - - - - - -
-
- - - - - - -
-
HomeScreenBinding -
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
hs-helper.c
-
-
-Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017 TOYOTA MOTOR CORPORATION
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #include "hs-helper.h"
18 #include <stdlib.h>
19 #include <string.h>
20 #include <limits.h>
21 #include <json-c/json.h>
22 #include <stdarg.h>
23 
24 REQ_ERROR get_value_uint16(const struct afb_req request, const char *source, uint16_t *out_id)
25 {
26  char* endptr;
27  const char* tmp = afb_req_value (request, source);
28  if(!tmp)
29  {
30  return REQ_FAIL;
31  }
32  long tmp_id = strtol(tmp,&endptr,10);
33 
34  /* error check of range */
35  if( (tmp_id > UINT16_MAX) || (tmp_id < 0) )
36  {
37  return OUT_RANGE;
38  }
39  if(*endptr != '\0')
40  {
41  return NOT_NUMBER;
42  }
43 
44  *out_id = (uint16_t)tmp_id;
45  return REQ_OK;
46 }
47 
48 REQ_ERROR get_value_int16(const struct afb_req request, const char *source, int16_t *out_id)
49 {
50  char* endptr;
51  const char* tmp = afb_req_value (request, source);
52  if(!tmp)
53  {
54  return REQ_FAIL;
55  }
56  long tmp_id = strtol(tmp,&endptr,10);
57 
58  /* error check of range */
59  if( (tmp_id > INT16_MAX) || (tmp_id < INT16_MIN) )
60  {
61  return OUT_RANGE;
62  }
63  if(*endptr != '\0')
64  {
65  return NOT_NUMBER;
66  }
67 
68  *out_id = (int16_t)tmp_id;
69  return REQ_OK;
70 }
71 
72 REQ_ERROR get_value_int32(const struct afb_req request, const char *source, int32_t *out_id)
73 {
74  char* endptr;
75  const char* tmp = afb_req_value (request, source);
76  if(!tmp)
77  {
78  return REQ_FAIL;
79  }
80  long tmp_id = strtol(tmp,&endptr,10);
81 
82  /* error check of range */
83  if( (tmp_id > INT32_MAX) || (tmp_id < INT32_MIN) )
84  {
85  return OUT_RANGE;
86  }
87  if(*endptr != '\0')
88  {
89  return NOT_NUMBER;
90  }
91 
92  *out_id = (int32_t)tmp_id;
93  return REQ_OK;
94 }
95 
96 void hs_add_object_to_json_object(struct json_object* j_obj, int count,...)
97 {
98  va_list args;
99  va_start(args, count);
100  for(int i = 0; i < count; ++i )
101  {
102  char *key = va_arg(args, char*);
103  int value = va_arg(args, int);
104  json_object_object_add(j_obj, key, json_object_new_int((int32_t)value));
105  ++i;
106  }
107  va_end(args);
108 }
109 
110 void hs_add_object_to_json_object_str(struct json_object* j_obj, int count,...)
111 {
112  va_list args;
113  va_start(args, count);
114  for(int i = 0; i < count; ++i )
115  {
116  char *key = va_arg(args, char*);
117  char *value = va_arg(args, char*);
118  json_object_object_add(j_obj, key, json_object_new_string(value));
119  ++i;
120  }
121  va_end(args);
122 }
123 
124 
125 void hs_add_object_to_json_object_func(struct json_object* j_obj, const char* verb_name, int count, ...)
126 {
127  va_list args;
128  va_start(args, count);
129 
130  json_object_object_add(j_obj,"verb", json_object_new_string(verb_name));
131 
132  for(int i = 0; i < count; ++i )
133  {
134  char *key = va_arg(args, char*);
135  int value = va_arg(args, int);
136  json_object_object_add(j_obj, key, json_object_new_int((int32_t)value));
137  ++i;
138  }
139  va_end(args);
140 }
141 
142 int hs_search_event_name_index(const char* value)
143 {
144  size_t buf_size = 50;
145  size_t size = sizeof evlist / sizeof *evlist;
146  int ret = -1;
147  for(size_t i = 0 ; i < size ; ++i)
148  {
149  if(!strncmp(value, evlist[i], buf_size))
150  {
151  ret = i;
152  break;
153  }
154  }
155  return ret;
156 }
void hs_add_object_to_json_object_str(struct json_object *j_obj, int count,...)
Definition: hs-helper.c:110
- -
REQ_ERROR get_value_uint16(const struct afb_req request, const char *source, uint16_t *out_id)
Definition: hs-helper.c:24
-
static const char * evlist[]
Definition: hs-helper.h:34
- -
int hs_search_event_name_index(const char *value)
Definition: hs-helper.c:142
-
REQ_ERROR get_value_int16(const struct afb_req request, const char *source, int16_t *out_id)
Definition: hs-helper.c:48
- -
REQ_ERROR get_value_int32(const struct afb_req request, const char *source, int32_t *out_id)
Definition: hs-helper.c:72
- - -
REQ_ERROR
Definition: hs-helper.h:26
-
void hs_add_object_to_json_object(struct json_object *j_obj, int count,...)
Definition: hs-helper.c:96
-
void hs_add_object_to_json_object_func(struct json_object *j_obj, const char *verb_name, int count,...)
Definition: hs-helper.c:125
-
- - - - diff --git a/doc/api-ref/html/dd/d30/hs-clientmanager_8cpp.html b/doc/api-ref/html/dd/d30/hs-clientmanager_8cpp.html new file mode 100644 index 0000000..2207299 --- /dev/null +++ b/doc/api-ref/html/dd/d30/hs-clientmanager_8cpp.html @@ -0,0 +1,170 @@ + + + + + + +HomeScreenBinding: src/hs-clientmanager.cpp File Reference + + + + + + + + + + +
+
+ + + + + + +
+
HomeScreenBinding +
+
+
+ + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
hs-clientmanager.cpp File Reference
+
+
+
#include <algorithm>
+#include "hs-clientmanager.h"
+#include "hmi-debug.h"
+
+

Go to the source code of this file.

+ + + + +

+Functions

static void cbRemoveClientCtxt (void *data)
 
+ + + +

+Variables

static const char _homescreen [] = "homescreen"
 
+

Function Documentation

+ +
+
+ + + + + +
+ + + + + + + + +
static void cbRemoveClientCtxt (void * data)
+
+static
+
+ +

Definition at line 24 of file hs-clientmanager.cpp.

+
25 {
27 }
void removeClientCtxt(void *data)
+
static HS_ClientManager * instance(void)
+
+
+
+

Variable Documentation

+ +
+
+ + + + + +
+ + + + +
const char _homescreen[] = "homescreen"
+
+static
+
+ +

Definition at line 20 of file hs-clientmanager.cpp.

+ +
+
+
+ + + + diff --git a/doc/api-ref/html/dd/d30/hs-clientmanager_8cpp_source.html b/doc/api-ref/html/dd/d30/hs-clientmanager_8cpp_source.html new file mode 100644 index 0000000..9fd56e9 --- /dev/null +++ b/doc/api-ref/html/dd/d30/hs-clientmanager_8cpp_source.html @@ -0,0 +1,133 @@ + + + + + + +HomeScreenBinding: src/hs-clientmanager.cpp Source File + + + + + + + + + + +
+
+ + + + + + +
+
HomeScreenBinding +
+
+
+ + + + + + +
+
+ + +
+ +
+ + +
+
+
+
hs-clientmanager.cpp
+
+
+Go to the documentation of this file.
1 /*
2  * Copyright (c) 2018 TOYOTA MOTOR CORPORATION
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 #include <algorithm>
17 #include "hs-clientmanager.h"
18 #include "hmi-debug.h"
19 
20 static const char _homescreen[] = "homescreen";
21 
22 HS_ClientManager* HS_ClientManager::me = nullptr;
23 
24 static void cbRemoveClientCtxt(void *data)
25 {
27 }
28 
40 {
41 }
42 
54 {
55  if(me == nullptr)
56  me = new HS_ClientManager();
57 
58  return me;
59 }
60 
72 {
73  HMI_NOTICE("homescreen-service","called.");
74 }
75 
86 HS_ClientCtxt* HS_ClientManager::createClientCtxt(afb_req_t req, std::string appid)
87 {
88  HS_ClientCtxt *ctxt = (HS_ClientCtxt *)afb_req_context_get(req);
89  if (!ctxt)
90  {
91  HMI_NOTICE("homescreen-service", "create new session for %s", appid.c_str());
92  HS_ClientCtxt *ctxt = new HS_ClientCtxt(appid.c_str());
93  afb_req_session_set_LOA(req, 1);
94  afb_req_context_set(req, ctxt, cbRemoveClientCtxt);
95  }
96  return ctxt;
97 }
98 
109 HS_Client* HS_ClientManager::addClient(afb_req_t req, std::string appid)
110 {
111  return (client_list[appid] = new HS_Client(req, appid));
112 }
113 
124 void HS_ClientManager::removeClient(std::string appid)
125 {
126  delete client_list[appid];
127  client_list.erase(appid);
128 }
129 
141 {
142  HS_ClientCtxt *ctxt = (HS_ClientCtxt *)data;
143  if(ctxt == nullptr)
144  {
145  HMI_ERROR("homescreen-service", "data is nullptr");
146  return;
147  }
148 
149  HMI_NOTICE("homescreen-service", "remove app %s", ctxt->id.c_str());
150  std::lock_guard<std::mutex> lock(this->mtx);
151  removeClient(ctxt->id);
152  delete appid2ctxt[ctxt->id];
153  appid2ctxt.erase(ctxt->id);
154 }
155 
166 int HS_ClientManager::tap_shortcut(afb_req_t request)
167 {
168  int ret = 0;
169  const char* value = afb_req_value(request, _application_id);
170  if (value) {
171  HMI_NOTICE("homescreen-service","request params = %s.", value);
172  std::lock_guard<std::mutex> lock(this->mtx);
173  auto ip = client_list.find(std::string(value));
174  if(ip != client_list.end()) {
175  ip->second->tap_shortcut(value);
176  }
177  }
178  else {
179  HMI_NOTICE("homescreen-service","Please input application_id");
180  ret = AFB_EVENT_BAD_REQUEST;
181  }
182  return ret;
183 }
184 
196 {
197  int ret = 0;
198  const char* value = afb_req_value(request, _display_message);
199  if (value) {
200  HMI_NOTICE("homescreen-service","request params = %s.", value);
201  std::lock_guard<std::mutex> lock(this->mtx);
202  for(auto m : client_list) {
203  m.second->on_screen_message(request, value);
204  }
205  }
206  else {
207  HMI_NOTICE("homescreen-service","Please input display_message");
208  ret = AFB_EVENT_BAD_REQUEST;
209  }
210  return ret;
211 }
212 
223 int HS_ClientManager::on_screen_reply(afb_req_t request)
224 {
225  int ret = 0;
226  const char* value = afb_req_value(request, _reply_message);
227  if (value) {
228  HMI_NOTICE("homescreen-service","request params = %s.", value);
229  std::lock_guard<std::mutex> lock(this->mtx);
230  for(auto m : client_list) {
231  m.second->on_screen_reply(request, value);
232  }
233  }
234  else {
235  HMI_NOTICE("homescreen-service","Please input reply_message");
236  ret = AFB_EVENT_BAD_REQUEST;
237  }
238  return ret;
239 }
240 
251 int HS_ClientManager::subscribe(afb_req_t request)
252 {
253  int ret = 0;
254  const char *value = afb_req_value(request, "event");
255  HMI_NOTICE("homescreen-service","value is %s", value);
256  if(value) {
257  std::string appid(afb_req_get_application_id(request));
258  std::lock_guard<std::mutex> lock(this->mtx);
259 
260  HS_Client* client = nullptr;
261  auto ip = client_list.find(appid);
262  if(ip != client_list.end()) {
263  client = client_list[appid];
264  }
265  else {
266  appid2ctxt[appid] = createClientCtxt(request, appid);
267  client = addClient(request, appid);
268  }
269 
270  if(client->subscribe(request, value) != 0) {
271  HMI_NOTICE("homescreen-service","subscribe failed");
273  }
274  }
275  else {
276  HMI_NOTICE("homescreen-service","Please input event name");
277  ret = AFB_EVENT_BAD_REQUEST;
278  }
279  return ret;
280 }
281 
292 int HS_ClientManager::unsubscribe(afb_req_t request)
293 {
294  const char *value = afb_req_value(request, "event");
295  HMI_NOTICE("homescreen-service","value is %s", value);
296  int ret = 0;
297  if(value) {
298  std::string appid(afb_req_get_application_id(request));
299  std::lock_guard<std::mutex> lock(this->mtx);
300 
301  auto ip = client_list.find(appid);
302  if(ip != client_list.end()
303  && ip->second->unsubscribe(request, value) != 0) {
304  HMI_NOTICE("homescreen-service","unsubscribe failed");
306  }
307  }
308  else {
309  HMI_NOTICE("homescreen-service","Please input event name");
310  ret = AFB_EVENT_BAD_REQUEST;
311  }
312  return ret;
313 }
314 
326 int HS_ClientManager::showWindow(afb_req_t request)
327 {
328  int ret = 0;
329  const char* value = afb_req_value(request, _application_id);
330  if (value) {
331  HMI_NOTICE("homescreen-service","request params = %s.", value);
332  std::lock_guard<std::mutex> lock(this->mtx);
333  auto ip = client_list.find(std::string(value));
334  if(ip != client_list.end()) {
335  ret = ip->second->showWindow(request, value);
336  }
337  }
338  else {
339  HMI_NOTICE("homescreen-service","Please input application_id");
340  ret = AFB_EVENT_BAD_REQUEST;
341  }
342  return ret;
343 }
344 
356 int HS_ClientManager::hideWindow(afb_req_t request)
357 {
358  int ret = 0;
359  const char* value = afb_req_value(request, _application_id);
360  if (value) {
361  HMI_NOTICE("homescreen-service","request params = %s.", value);
362  std::lock_guard<std::mutex> lock(this->mtx);
363  auto ip = client_list.find(std::string(value));
364  if(ip != client_list.end()) {
365  ret = ip->second->hideWindow(request);
366  }
367  }
368  else {
369  HMI_NOTICE("homescreen-service","Please input application_id");
370  ret = AFB_EVENT_BAD_REQUEST;
371  }
372  return ret;
373 }
374 
386 int HS_ClientManager::replyShowWindow(afb_req_t request)
387 {
388  int ret = 0;
389  const char* value = afb_req_value(request, _application_id);
390  if (value) {
391  HMI_NOTICE("homescreen-service","request params = %s.", value);
392  std::lock_guard<std::mutex> lock(this->mtx);
393  auto ip = client_list.find(std::string(value));
394  if(ip != client_list.end()) {
395  ret = ip->second->replyShowWindow(request, value);
396  }
397  }
398  else {
399  HMI_NOTICE("homescreen-service","Please input application_id");
400  ret = AFB_EVENT_BAD_REQUEST;
401  }
402  return ret;
403 }
404 
417 {
418  int ret = 0;
419  std::lock_guard<std::mutex> lock(this->mtx);
420  auto ip = client_list.find(_homescreen);
421  if(ip != client_list.end()) {
422  ret = ip->second->showNotification(request);
423  }
424  else {
425  HMI_NOTICE("homescreen-service","not exist sessiion with homescreen");
427  }
428 
429  return ret;
430 }
431 
443 int HS_ClientManager::showInformation(afb_req_t request)
444 {
445  int ret = 0;
446  std::lock_guard<std::mutex> lock(this->mtx);
447  auto ip = client_list.find(_homescreen);
448  if(ip != client_list.end()) {
449  ret = ip->second->showInformation(request);
450  }
451  else {
452  HMI_NOTICE("homescreen-service","not exist sessiion with homescreen");
454  }
455 
456  return ret;
457 }
int subscribe(afb_req_t request, const char *event)
Definition: hs-client.cpp:139
+ +
int hideWindow(afb_req_t request)
+ +
int subscribe(afb_req_t request)
+
int tap_shortcut(afb_req_t request)
+
#define AFB_REQ_SHOWNOTIFICATION_ERROR
Definition: hs-helper.h:26
+ +
const char _reply_message[]
Definition: homescreen.cpp:30
+ +
int on_screen_reply(afb_req_t request)
+
#define HMI_NOTICE(prefix, args,...)
Definition: hmi-debug.h:40
+
int showWindow(afb_req_t request)
+
struct HS_ClientCtxt HS_ClientCtxt
+
int unsubscribe(afb_req_t request)
+ +
static const char _homescreen[]
+
int replyShowWindow(afb_req_t request)
+ +
const char _display_message[]
Definition: homescreen.cpp:29
+
void removeClientCtxt(void *data)
+
static HS_ClientManager * instance(void)
+
static void cbRemoveClientCtxt(void *data)
+
std::string id
+ +
#define AFB_REQ_UNSUBSCRIBE_ERROR
Definition: hs-helper.h:25
+
int showInformation(afb_req_t request)
+
#define HMI_ERROR(prefix, args,...)
Definition: hmi-debug.h:38
+
int on_screen_message(afb_req_t request)
+
const char _application_id[]
Definition: homescreen.cpp:28
+
#define AFB_EVENT_BAD_REQUEST
Definition: hs-helper.h:23
+
int showNotification(afb_req_t request)
+
#define AFB_REQ_SUBSCRIBE_ERROR
Definition: hs-helper.h:24
+
#define AFB_REQ_SHOWINFORMATION_ERROR
Definition: hs-helper.h:27
+
+ + + + diff --git a/doc/api-ref/html/dd/d86/structevent-members.html b/doc/api-ref/html/dd/d86/structevent-members.html deleted file mode 100644 index 8f15215..0000000 --- a/doc/api-ref/html/dd/d86/structevent-members.html +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - - -HomeScreenBinding: Member List - - - - - - - - - -
-
- - - - - - -
-
HomeScreenBinding -
-
-
- - - - - - - - -
-
- - -
- -
- -
-
-
-
event Member List
-
-
- -

This is the complete list of members for event, including all inherited members.

- - - -
eventevent
nameevent
- - - - diff --git a/doc/api-ref/html/dd/dc9/class_h_s___client_manager-members.html b/doc/api-ref/html/dd/dc9/class_h_s___client_manager-members.html new file mode 100644 index 0000000..fd18777 --- /dev/null +++ b/doc/api-ref/html/dd/dc9/class_h_s___client_manager-members.html @@ -0,0 +1,118 @@ + + + + + + +HomeScreenBinding: Member List + + + + + + + + + + +
+
+ + + + + + +
+
HomeScreenBinding +
+
+
+ + + + + + +
+
+ + +
+ +
+ +
+
+
+
HS_ClientManager Member List
+
+
+ +

This is the complete list of members for HS_ClientManager, including all inherited members.

+ + + + + + + + + + + + + + + + + + + + +
hideWindow(afb_req_t request)HS_ClientManager
HS_ClientManager()HS_ClientManager
HS_ClientManager(HS_ClientManager const &)=deleteHS_ClientManager
HS_ClientManager(HS_ClientManager &&)=deleteHS_ClientManager
init(void)HS_ClientManager
instance(void)HS_ClientManagerstatic
on_screen_message(afb_req_t request)HS_ClientManager
on_screen_reply(afb_req_t request)HS_ClientManager
operator=(HS_ClientManager const &)=deleteHS_ClientManager
operator=(HS_ClientManager &&)=deleteHS_ClientManager
removeClientCtxt(void *data)HS_ClientManager
replyShowWindow(afb_req_t request)HS_ClientManager
showInformation(afb_req_t request)HS_ClientManager
showNotification(afb_req_t request)HS_ClientManager
showWindow(afb_req_t request)HS_ClientManager
subscribe(afb_req_t request)HS_ClientManager
tap_shortcut(afb_req_t request)HS_ClientManager
unsubscribe(afb_req_t request)HS_ClientManager
~HS_ClientManager()=defaultHS_ClientManager
+ + + + diff --git a/doc/api-ref/html/dd/ddc/structgeometry.html b/doc/api-ref/html/dd/ddc/structgeometry.html new file mode 100644 index 0000000..ed8d0ff --- /dev/null +++ b/doc/api-ref/html/dd/ddc/structgeometry.html @@ -0,0 +1,142 @@ + + + + + + +HomeScreenBinding: geometry Struct Reference + + + + + + + + + + +
+
+ + + + + + +
+
HomeScreenBinding +
+
+
+ + + + + + +
+
+ + +
+ +
+ +
+
+ +
+
geometry Struct Reference
+
+
+ + + + + + +

+Public Attributes

int width
 
int height
 
+

Detailed Description

+
+

Definition at line 132 of file simple-egl.cpp.

+

Member Data Documentation

+ +
+
+ + + + +
int geometry::height
+
+ +

Definition at line 133 of file simple-egl.cpp.

+ +
+
+ +
+
+ + + + +
int geometry::width
+
+ +

Definition at line 133 of file simple-egl.cpp.

+ +
+
+
The documentation for this struct was generated from the following file: +
+ + + + -- cgit 1.2.3-korg