1 \hypertarget{class_h_s___client_manager}{}\section{H\+S\+\_\+\+Client\+Manager Class Reference}
2 \label{class_h_s___client_manager}\index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
5 {\ttfamily \#include $<$hs-\/clientmanager.\+h$>$}
7 \subsection*{Public Member Functions}
8 \begin{DoxyCompactItemize}
10 \hyperlink{class_h_s___client_manager_adac35e476e559cc89bc39363525268bf}{H\+S\+\_\+\+Client\+Manager} ()
12 \hyperlink{class_h_s___client_manager_a50733274a93293fef892fdd453d74cae}{$\sim$\+H\+S\+\_\+\+Client\+Manager} ()=default
14 \hyperlink{class_h_s___client_manager_a0033db6b552f9de818789e76735c1ebc}{H\+S\+\_\+\+Client\+Manager} (\hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} const \&)=delete
16 \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} \& \hyperlink{class_h_s___client_manager_ac8e02cffc79d4530b06e1143abb18891}{operator=} (\hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} const \&)=delete
18 \hyperlink{class_h_s___client_manager_a715811c549cccd93cb1f903d179c8b41}{H\+S\+\_\+\+Client\+Manager} (\hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} \&\&)=delete
20 \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} \& \hyperlink{class_h_s___client_manager_a49e225bb8421c812ac016309d54a00fa}{operator=} (\hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} \&\&)=delete
22 int \hyperlink{class_h_s___client_manager_ae0b9b18adeffca7822b060ad4ea8a7a1}{init} (void)
24 void \hyperlink{class_h_s___client_manager_adc23f8b3f5cc06eeab39fb24098af3e2}{remove\+Client\+Ctxt} (void $\ast$data)
26 int \hyperlink{class_h_s___client_manager_a9910fc27c412530b5b9854b00bd16c07}{tap\+\_\+shortcut} (afb\+\_\+req\+\_\+t request)
28 int \hyperlink{class_h_s___client_manager_afed8158f276d1d22c32b0d89e970d442}{show\+Window} (afb\+\_\+req\+\_\+t request)
30 int \hyperlink{class_h_s___client_manager_a6195694d281a3b97b0345b96c0add1fd}{hide\+Window} (afb\+\_\+req\+\_\+t request)
32 int \hyperlink{class_h_s___client_manager_a59b1c1e115b5a257a585c41f854f5fdd}{reply\+Show\+Window} (afb\+\_\+req\+\_\+t request)
34 int \hyperlink{class_h_s___client_manager_a58ce4a013d3694265dd69f481bf88510}{on\+\_\+screen\+\_\+message} (afb\+\_\+req\+\_\+t request)
36 int \hyperlink{class_h_s___client_manager_aa78f992287e3b8fe93422b331dc9edc5}{on\+\_\+screen\+\_\+reply} (afb\+\_\+req\+\_\+t request)
38 int \hyperlink{class_h_s___client_manager_a1b8a4e42342c4bcdc4e7dc4934e02469}{subscribe} (afb\+\_\+req\+\_\+t request)
40 int \hyperlink{class_h_s___client_manager_ac86314afbb90116e2f02ce071166226e}{unsubscribe} (afb\+\_\+req\+\_\+t request)
42 int \hyperlink{class_h_s___client_manager_a857934af280081ca6ac61d9f2cac37c5}{show\+Notification} (afb\+\_\+req\+\_\+t request)
44 int \hyperlink{class_h_s___client_manager_a0645294f89c67fd3c9b0cce62a900f69}{show\+Information} (afb\+\_\+req\+\_\+t request)
45 \end{DoxyCompactItemize}
46 \subsection*{Static Public Member Functions}
47 \begin{DoxyCompactItemize}
49 static \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} $\ast$ \hyperlink{class_h_s___client_manager_ad86c1fea7d107d52cbf0466fb7a2658b}{instance} (void)
50 \end{DoxyCompactItemize}
53 \subsection{Detailed Description}
56 Definition at line 37 of file hs-\/clientmanager.\+h.
60 \subsection{Constructor \& Destructor Documentation}
61 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
62 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
63 \subsubsection[{\texorpdfstring{H\+S\+\_\+\+Client\+Manager()}{HS_ClientManager()}}]{\setlength{\rightskip}{0pt plus 5cm}H\+S\+\_\+\+Client\+Manager\+::\+H\+S\+\_\+\+Client\+Manager (
64 \begin{DoxyParamCaption}
66 \end{DoxyParamCaption}
67 )}\hypertarget{class_h_s___client_manager_adac35e476e559cc89bc39363525268bf}{}\label{class_h_s___client_manager_adac35e476e559cc89bc39363525268bf}
68 \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} construction function
70 \subparagraph*{Parameters}
77 \subparagraph*{Return}
81 Definition at line 39 of file hs-\/clientmanager.\+cpp.
88 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!````~H\+S\+\_\+\+Client\+Manager@{$\sim$\+H\+S\+\_\+\+Client\+Manager}}
89 \index{````~H\+S\+\_\+\+Client\+Manager@{$\sim$\+H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
90 \subsubsection[{\texorpdfstring{$\sim$\+H\+S\+\_\+\+Client\+Manager()=default}{~HS_ClientManager()=default}}]{\setlength{\rightskip}{0pt plus 5cm}H\+S\+\_\+\+Client\+Manager\+::$\sim$\+H\+S\+\_\+\+Client\+Manager (
91 \begin{DoxyParamCaption}
93 \end{DoxyParamCaption}
94 )\hspace{0.3cm}{\ttfamily [default]}}\hypertarget{class_h_s___client_manager_a50733274a93293fef892fdd453d74cae}{}\label{class_h_s___client_manager_a50733274a93293fef892fdd453d74cae}
95 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
96 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
97 \subsubsection[{\texorpdfstring{H\+S\+\_\+\+Client\+Manager(\+H\+S\+\_\+\+Client\+Manager const \&)=delete}{HS_ClientManager(HS_ClientManager const &)=delete}}]{\setlength{\rightskip}{0pt plus 5cm}H\+S\+\_\+\+Client\+Manager\+::\+H\+S\+\_\+\+Client\+Manager (
98 \begin{DoxyParamCaption}
99 \item[{{\bf H\+S\+\_\+\+Client\+Manager} const \&}]{}
100 \end{DoxyParamCaption}
101 )\hspace{0.3cm}{\ttfamily [delete]}}\hypertarget{class_h_s___client_manager_a0033db6b552f9de818789e76735c1ebc}{}\label{class_h_s___client_manager_a0033db6b552f9de818789e76735c1ebc}
102 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
103 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
104 \subsubsection[{\texorpdfstring{H\+S\+\_\+\+Client\+Manager(\+H\+S\+\_\+\+Client\+Manager \&\&)=delete}{HS_ClientManager(HS_ClientManager &&)=delete}}]{\setlength{\rightskip}{0pt plus 5cm}H\+S\+\_\+\+Client\+Manager\+::\+H\+S\+\_\+\+Client\+Manager (
105 \begin{DoxyParamCaption}
106 \item[{{\bf H\+S\+\_\+\+Client\+Manager} \&\&}]{}
107 \end{DoxyParamCaption}
108 )\hspace{0.3cm}{\ttfamily [delete]}}\hypertarget{class_h_s___client_manager_a715811c549cccd93cb1f903d179c8b41}{}\label{class_h_s___client_manager_a715811c549cccd93cb1f903d179c8b41}
111 \subsection{Member Function Documentation}
112 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!hide\+Window@{hide\+Window}}
113 \index{hide\+Window@{hide\+Window}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
114 \subsubsection[{\texorpdfstring{hide\+Window(afb\+\_\+req\+\_\+t request)}{hideWindow(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::hide\+Window (
115 \begin{DoxyParamCaption}
116 \item[{afb\+\_\+req\+\_\+t}]{request}
117 \end{DoxyParamCaption}
118 )}\hypertarget{class_h_s___client_manager_a6195694d281a3b97b0345b96c0add1fd}{}\label{class_h_s___client_manager_a6195694d281a3b97b0345b96c0add1fd}
121 \subparagraph*{Parameters}
125 \item request \+: the request
128 \subparagraph*{Return}
130 0 \+: success others \+: fail
132 Definition at line 356 of file hs-\/clientmanager.\+cpp.
137 358 \textcolor{keywordtype}{int} ret = 0;
138 359 \textcolor{keyword}{const} \textcolor{keywordtype}{char}* value = afb\_req\_value(request, \hyperlink{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}{\_application\_id});
139 360 \textcolor{keywordflow}{if} (value) \{
140 361 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"request params = %s."}, value);
141 362 std::lock\_guard<std::mutex> lock(this->mtx);
142 363 \textcolor{keyword}{auto} ip = client\_list.find(std::string(value));
143 364 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
144 365 ret = ip->second->hideWindow(request);
147 368 \textcolor{keywordflow}{else} \{
148 369 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input application\_id"});
149 370 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
151 372 \textcolor{keywordflow}{return} ret;
154 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!init@{init}}
155 \index{init@{init}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
156 \subsubsection[{\texorpdfstring{init(void)}{init(void)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::init (
157 \begin{DoxyParamCaption}
159 \end{DoxyParamCaption}
160 )}\hypertarget{class_h_s___client_manager_ae0b9b18adeffca7822b060ad4ea8a7a1}{}\label{class_h_s___client_manager_ae0b9b18adeffca7822b060ad4ea8a7a1}
161 \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} init function
163 \subparagraph*{Parameters}
170 \subparagraph*{Return}
174 Definition at line 71 of file hs-\/clientmanager.\+cpp.
179 73 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
182 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!instance@{instance}}
183 \index{instance@{instance}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
184 \subsubsection[{\texorpdfstring{instance(void)}{instance(void)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf H\+S\+\_\+\+Client\+Manager} $\ast$ H\+S\+\_\+\+Client\+Manager\+::instance (
185 \begin{DoxyParamCaption}
187 \end{DoxyParamCaption}
188 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{class_h_s___client_manager_ad86c1fea7d107d52cbf0466fb7a2658b}{}\label{class_h_s___client_manager_ad86c1fea7d107d52cbf0466fb7a2658b}
191 \subparagraph*{Parameters}
198 \subparagraph*{Return}
200 \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} instance pointer
202 Definition at line 53 of file hs-\/clientmanager.\+cpp.
207 55 \textcolor{keywordflow}{if}(me == \textcolor{keyword}{nullptr})
208 56 me = \textcolor{keyword}{new} \hyperlink{class_h_s___client_manager_adac35e476e559cc89bc39363525268bf}{HS\_ClientManager}();
210 58 \textcolor{keywordflow}{return} me;
213 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!on\+\_\+screen\+\_\+message@{on\+\_\+screen\+\_\+message}}
214 \index{on\+\_\+screen\+\_\+message@{on\+\_\+screen\+\_\+message}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
215 \subsubsection[{\texorpdfstring{on\+\_\+screen\+\_\+message(afb\+\_\+req\+\_\+t request)}{on_screen_message(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::on\+\_\+screen\+\_\+message (
216 \begin{DoxyParamCaption}
217 \item[{afb\+\_\+req\+\_\+t}]{request}
218 \end{DoxyParamCaption}
219 )}\hypertarget{class_h_s___client_manager_a58ce4a013d3694265dd69f481bf88510}{}\label{class_h_s___client_manager_a58ce4a013d3694265dd69f481bf88510}
220 on\+\_\+screen\+\_\+message
222 \subparagraph*{Parameters}
226 \item request\+: the request to bindings
229 \subparagraph*{Return}
233 Definition at line 195 of file hs-\/clientmanager.\+cpp.
238 197 \textcolor{keywordtype}{int} ret = 0;
239 198 \textcolor{keyword}{const} \textcolor{keywordtype}{char}* value = afb\_req\_value(request, \hyperlink{homescreen_8cpp_abfd6c1d6f316fa952b11553f8f275e92}{\_display\_message});
240 199 \textcolor{keywordflow}{if} (value) \{
241 200 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"request params = %s."}, value);
242 201 std::lock\_guard<std::mutex> lock(this->mtx);
243 202 \textcolor{keywordflow}{for}(\textcolor{keyword}{auto} m : client\_list) \{
244 203 m.second->on\_screen\_message(request, value);
247 206 \textcolor{keywordflow}{else} \{
248 207 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input display\_message"});
249 208 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
251 210 \textcolor{keywordflow}{return} ret;
254 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!on\+\_\+screen\+\_\+reply@{on\+\_\+screen\+\_\+reply}}
255 \index{on\+\_\+screen\+\_\+reply@{on\+\_\+screen\+\_\+reply}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
256 \subsubsection[{\texorpdfstring{on\+\_\+screen\+\_\+reply(afb\+\_\+req\+\_\+t request)}{on_screen_reply(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::on\+\_\+screen\+\_\+reply (
257 \begin{DoxyParamCaption}
258 \item[{afb\+\_\+req\+\_\+t}]{request}
259 \end{DoxyParamCaption}
260 )}\hypertarget{class_h_s___client_manager_aa78f992287e3b8fe93422b331dc9edc5}{}\label{class_h_s___client_manager_aa78f992287e3b8fe93422b331dc9edc5}
261 on\+\_\+screen\+\_\+reply
263 \subparagraph*{Parameters}
267 \item request\+: the request to bindings
270 \subparagraph*{Return}
274 Definition at line 223 of file hs-\/clientmanager.\+cpp.
279 225 \textcolor{keywordtype}{int} ret = 0;
280 226 \textcolor{keyword}{const} \textcolor{keywordtype}{char}* value = afb\_req\_value(request, \hyperlink{homescreen_8cpp_a79b0f0b481161527ccb80e83da143219}{\_reply\_message});
281 227 \textcolor{keywordflow}{if} (value) \{
282 228 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"request params = %s."}, value);
283 229 std::lock\_guard<std::mutex> lock(this->mtx);
284 230 \textcolor{keywordflow}{for}(\textcolor{keyword}{auto} m : client\_list) \{
285 231 m.second->on\_screen\_reply(request, value);
288 234 \textcolor{keywordflow}{else} \{
289 235 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input reply\_message"});
290 236 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
292 238 \textcolor{keywordflow}{return} ret;
295 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!operator=@{operator=}}
296 \index{operator=@{operator=}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
297 \subsubsection[{\texorpdfstring{operator=(\+H\+S\+\_\+\+Client\+Manager const \&)=delete}{operator=(HS_ClientManager const &)=delete}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf H\+S\+\_\+\+Client\+Manager}\& H\+S\+\_\+\+Client\+Manager\+::operator= (
298 \begin{DoxyParamCaption}
299 \item[{{\bf H\+S\+\_\+\+Client\+Manager} const \&}]{}
300 \end{DoxyParamCaption}
301 )\hspace{0.3cm}{\ttfamily [delete]}}\hypertarget{class_h_s___client_manager_ac8e02cffc79d4530b06e1143abb18891}{}\label{class_h_s___client_manager_ac8e02cffc79d4530b06e1143abb18891}
302 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!operator=@{operator=}}
303 \index{operator=@{operator=}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
304 \subsubsection[{\texorpdfstring{operator=(\+H\+S\+\_\+\+Client\+Manager \&\&)=delete}{operator=(HS_ClientManager &&)=delete}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf H\+S\+\_\+\+Client\+Manager}\& H\+S\+\_\+\+Client\+Manager\+::operator= (
305 \begin{DoxyParamCaption}
306 \item[{{\bf H\+S\+\_\+\+Client\+Manager} \&\&}]{}
307 \end{DoxyParamCaption}
308 )\hspace{0.3cm}{\ttfamily [delete]}}\hypertarget{class_h_s___client_manager_a49e225bb8421c812ac016309d54a00fa}{}\label{class_h_s___client_manager_a49e225bb8421c812ac016309d54a00fa}
309 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!remove\+Client\+Ctxt@{remove\+Client\+Ctxt}}
310 \index{remove\+Client\+Ctxt@{remove\+Client\+Ctxt}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
311 \subsubsection[{\texorpdfstring{remove\+Client\+Ctxt(void $\ast$data)}{removeClientCtxt(void *data)}}]{\setlength{\rightskip}{0pt plus 5cm}void H\+S\+\_\+\+Client\+Manager\+::remove\+Client\+Ctxt (
312 \begin{DoxyParamCaption}
313 \item[{void $\ast$}]{data}
314 \end{DoxyParamCaption}
315 )}\hypertarget{class_h_s___client_manager_adc23f8b3f5cc06eeab39fb24098af3e2}{}\label{class_h_s___client_manager_adc23f8b3f5cc06eeab39fb24098af3e2}
316 remove Client from list
318 \subparagraph*{Parameters}
322 \item data\+: \hyperlink{struct_h_s___client_ctxt}{H\+S\+\_\+\+Client\+Ctxt} pointer
325 \subparagraph*{Return}
329 Definition at line 140 of file hs-\/clientmanager.\+cpp.
334 142 \hyperlink{struct_h_s___client_ctxt}{HS\_ClientCtxt} *ctxt = (\hyperlink{struct_h_s___client_ctxt}{HS\_ClientCtxt} *)data;
335 143 \textcolor{keywordflow}{if}(ctxt == \textcolor{keyword}{nullptr})
337 145 \hyperlink{include_2hmi-debug_8h_a65bb6c7cfe38f8a724beab5059d36fb2}{HMI\_ERROR}(\textcolor{stringliteral}{"homescreen-service"}, \textcolor{stringliteral}{"data is nullptr"});
338 146 \textcolor{keywordflow}{return};
341 149 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"}, \textcolor{stringliteral}{"remove app %s"}, ctxt->\hyperlink{struct_h_s___client_ctxt_a04929d7d5f583a821d3d594815f77d1c}{id}.c\_str());
342 150 std::lock\_guard<std::mutex> lock(this->mtx);
343 151 removeClient(ctxt->\hyperlink{struct_h_s___client_ctxt_a04929d7d5f583a821d3d594815f77d1c}{id});
344 152 \textcolor{keyword}{delete} appid2ctxt[ctxt->\hyperlink{struct_h_s___client_ctxt_a04929d7d5f583a821d3d594815f77d1c}{id}];
345 153 appid2ctxt.erase(ctxt->\hyperlink{struct_h_s___client_ctxt_a04929d7d5f583a821d3d594815f77d1c}{id});
348 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!reply\+Show\+Window@{reply\+Show\+Window}}
349 \index{reply\+Show\+Window@{reply\+Show\+Window}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
350 \subsubsection[{\texorpdfstring{reply\+Show\+Window(afb\+\_\+req\+\_\+t request)}{replyShowWindow(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::reply\+Show\+Window (
351 \begin{DoxyParamCaption}
352 \item[{afb\+\_\+req\+\_\+t}]{request}
353 \end{DoxyParamCaption}
354 )}\hypertarget{class_h_s___client_manager_a59b1c1e115b5a257a585c41f854f5fdd}{}\label{class_h_s___client_manager_a59b1c1e115b5a257a585c41f854f5fdd}
355 reply\+Show\+Window event
357 \subparagraph*{Parameters}
361 \item request \+: the request
364 \subparagraph*{Return}
366 0 \+: success others \+: fail
368 Definition at line 386 of file hs-\/clientmanager.\+cpp.
373 388 \textcolor{keywordtype}{int} ret = 0;
374 389 \textcolor{keyword}{const} \textcolor{keywordtype}{char}* value = afb\_req\_value(request, \hyperlink{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}{\_application\_id});
375 390 \textcolor{keywordflow}{if} (value) \{
376 391 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"request params = %s."}, value);
377 392 std::lock\_guard<std::mutex> lock(this->mtx);
378 393 \textcolor{keyword}{auto} ip = client\_list.find(std::string(value));
379 394 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
380 395 ret = ip->second->replyShowWindow(request, value);
383 398 \textcolor{keywordflow}{else} \{
384 399 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input application\_id"});
385 400 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
387 402 \textcolor{keywordflow}{return} ret;
390 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!show\+Information@{show\+Information}}
391 \index{show\+Information@{show\+Information}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
392 \subsubsection[{\texorpdfstring{show\+Information(afb\+\_\+req\+\_\+t request)}{showInformation(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::show\+Information (
393 \begin{DoxyParamCaption}
394 \item[{afb\+\_\+req\+\_\+t}]{request}
395 \end{DoxyParamCaption}
396 )}\hypertarget{class_h_s___client_manager_a0645294f89c67fd3c9b0cce62a900f69}{}\label{class_h_s___client_manager_a0645294f89c67fd3c9b0cce62a900f69}
397 show\+Information event
399 \subparagraph*{Parameters}
403 \item request \+: the request
406 \subparagraph*{Return}
408 0 \+: success others \+: fail
410 Definition at line 443 of file hs-\/clientmanager.\+cpp.
415 445 \textcolor{keywordtype}{int} ret = 0;
416 446 std::lock\_guard<std::mutex> lock(this->mtx);
417 447 \textcolor{keyword}{auto} ip = client\_list.find(\hyperlink{hs-clientmanager_8cpp_a8bbab9002543614eacdc7a319d13a476}{\_homescreen});
418 448 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
419 449 ret = ip->second->showInformation(request);
421 451 \textcolor{keywordflow}{else} \{
422 452 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"not exist sessiion with homescreen"});
423 453 ret = \hyperlink{hs-helper_8h_aefe0d7ff8202f954693c235c1fb8e310}{AFB\_REQ\_SHOWINFORMATION\_ERROR};
426 456 \textcolor{keywordflow}{return} ret;
429 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!show\+Notification@{show\+Notification}}
430 \index{show\+Notification@{show\+Notification}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
431 \subsubsection[{\texorpdfstring{show\+Notification(afb\+\_\+req\+\_\+t request)}{showNotification(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::show\+Notification (
432 \begin{DoxyParamCaption}
433 \item[{afb\+\_\+req\+\_\+t}]{request}
434 \end{DoxyParamCaption}
435 )}\hypertarget{class_h_s___client_manager_a857934af280081ca6ac61d9f2cac37c5}{}\label{class_h_s___client_manager_a857934af280081ca6ac61d9f2cac37c5}
436 show\+Notification event
438 \subparagraph*{Parameters}
442 \item request \+: the request
445 \subparagraph*{Return}
447 0 \+: success others \+: fail
449 Definition at line 416 of file hs-\/clientmanager.\+cpp.
454 418 \textcolor{keywordtype}{int} ret = 0;
455 419 std::lock\_guard<std::mutex> lock(this->mtx);
456 420 \textcolor{keyword}{auto} ip = client\_list.find(\hyperlink{hs-clientmanager_8cpp_a8bbab9002543614eacdc7a319d13a476}{\_homescreen});
457 421 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
458 422 ret = ip->second->showNotification(request);
460 424 \textcolor{keywordflow}{else} \{
461 425 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"not exist sessiion with homescreen"});
462 426 ret = \hyperlink{hs-helper_8h_a057fc88b8445828c261305cf9107d99d}{AFB\_REQ\_SHOWNOTIFICATION\_ERROR};
465 429 \textcolor{keywordflow}{return} ret;
468 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!show\+Window@{show\+Window}}
469 \index{show\+Window@{show\+Window}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
470 \subsubsection[{\texorpdfstring{show\+Window(afb\+\_\+req\+\_\+t request)}{showWindow(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::show\+Window (
471 \begin{DoxyParamCaption}
472 \item[{afb\+\_\+req\+\_\+t}]{request}
473 \end{DoxyParamCaption}
474 )}\hypertarget{class_h_s___client_manager_afed8158f276d1d22c32b0d89e970d442}{}\label{class_h_s___client_manager_afed8158f276d1d22c32b0d89e970d442}
477 \subparagraph*{Parameters}
481 \item request \+: the request
484 \subparagraph*{Return}
486 0 \+: success others \+: fail
488 Definition at line 326 of file hs-\/clientmanager.\+cpp.
493 328 \textcolor{keywordtype}{int} ret = 0;
494 329 \textcolor{keyword}{const} \textcolor{keywordtype}{char}* value = afb\_req\_value(request, \hyperlink{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}{\_application\_id});
495 330 \textcolor{keywordflow}{if} (value) \{
496 331 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"request params = %s."}, value);
497 332 std::lock\_guard<std::mutex> lock(this->mtx);
498 333 \textcolor{keyword}{auto} ip = client\_list.find(std::string(value));
499 334 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
500 335 ret = ip->second->showWindow(request, value);
503 338 \textcolor{keywordflow}{else} \{
504 339 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input application\_id"});
505 340 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
507 342 \textcolor{keywordflow}{return} ret;
510 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!subscribe@{subscribe}}
511 \index{subscribe@{subscribe}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
512 \subsubsection[{\texorpdfstring{subscribe(afb\+\_\+req\+\_\+t request)}{subscribe(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::subscribe (
513 \begin{DoxyParamCaption}
514 \item[{afb\+\_\+req\+\_\+t}]{request}
515 \end{DoxyParamCaption}
516 )}\hypertarget{class_h_s___client_manager_a1b8a4e42342c4bcdc4e7dc4934e02469}{}\label{class_h_s___client_manager_a1b8a4e42342c4bcdc4e7dc4934e02469}
519 \subparagraph*{Parameters}
523 \item request\+: the request to bindings
526 \subparagraph*{Return}
530 Definition at line 251 of file hs-\/clientmanager.\+cpp.
535 253 \textcolor{keywordtype}{int} ret = 0;
536 254 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *value = afb\_req\_value(request, \textcolor{stringliteral}{"event"});
537 255 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"value is %s"}, value);
538 256 \textcolor{keywordflow}{if}(value) \{
539 257 std::string appid(afb\_req\_get\_application\_id(request));
540 258 std::lock\_guard<std::mutex> lock(this->mtx);
542 260 \hyperlink{class_h_s___client}{HS\_Client}* client = \textcolor{keyword}{nullptr};
543 261 \textcolor{keyword}{auto} ip = client\_list.find(appid);
544 262 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
545 263 client = client\_list[appid];
547 265 \textcolor{keywordflow}{else} \{
548 266 appid2ctxt[appid] = createClientCtxt(request, appid);
549 267 client = addClient(request, appid);
552 270 \textcolor{keywordflow}{if}(client->\hyperlink{class_h_s___client_a3d000ca70bd4a8af7c4895d95bc7d0d0}{subscribe}(request, value) != 0) \{
553 271 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"subscribe failed"});
554 272 ret = \hyperlink{hs-helper_8h_a995612de89db4df1483c16e4b9b70571}{AFB\_REQ\_SUBSCRIBE\_ERROR};
557 275 \textcolor{keywordflow}{else} \{
558 276 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input event name"});
559 277 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
561 279 \textcolor{keywordflow}{return} ret;
564 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!tap\+\_\+shortcut@{tap\+\_\+shortcut}}
565 \index{tap\+\_\+shortcut@{tap\+\_\+shortcut}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
566 \subsubsection[{\texorpdfstring{tap\+\_\+shortcut(afb\+\_\+req\+\_\+t request)}{tap_shortcut(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::tap\+\_\+shortcut (
567 \begin{DoxyParamCaption}
568 \item[{afb\+\_\+req\+\_\+t}]{request}
569 \end{DoxyParamCaption}
570 )}\hypertarget{class_h_s___client_manager_a9910fc27c412530b5b9854b00bd16c07}{}\label{class_h_s___client_manager_a9910fc27c412530b5b9854b00bd16c07}
573 \subparagraph*{Parameters}
577 \item request\+: the request to bindings
580 \subparagraph*{Return}
584 Definition at line 166 of file hs-\/clientmanager.\+cpp.
589 168 \textcolor{keywordtype}{int} ret = 0;
590 169 \textcolor{keyword}{const} \textcolor{keywordtype}{char}* value = afb\_req\_value(request, \hyperlink{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}{\_application\_id});
591 170 \textcolor{keywordflow}{if} (value) \{
592 171 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"request params = %s."}, value);
593 172 std::lock\_guard<std::mutex> lock(this->mtx);
594 173 \textcolor{keyword}{auto} ip = client\_list.find(std::string(value));
595 174 \textcolor{keywordflow}{if}(ip != client\_list.end()) \{
596 175 ip->second->tap\_shortcut(value);
599 178 \textcolor{keywordflow}{else} \{
600 179 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input application\_id"});
601 180 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
603 182 \textcolor{keywordflow}{return} ret;
606 \index{H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}!unsubscribe@{unsubscribe}}
607 \index{unsubscribe@{unsubscribe}!H\+S\+\_\+\+Client\+Manager@{H\+S\+\_\+\+Client\+Manager}}
608 \subsubsection[{\texorpdfstring{unsubscribe(afb\+\_\+req\+\_\+t request)}{unsubscribe(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}int H\+S\+\_\+\+Client\+Manager\+::unsubscribe (
609 \begin{DoxyParamCaption}
610 \item[{afb\+\_\+req\+\_\+t}]{request}
611 \end{DoxyParamCaption}
612 )}\hypertarget{class_h_s___client_manager_ac86314afbb90116e2f02ce071166226e}{}\label{class_h_s___client_manager_ac86314afbb90116e2f02ce071166226e}
615 \subparagraph*{Parameters}
619 \item request\+: the request to bindings
622 \subparagraph*{Return}
626 Definition at line 292 of file hs-\/clientmanager.\+cpp.
631 294 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *value = afb\_req\_value(request, \textcolor{stringliteral}{"event"});
632 295 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"value is %s"}, value);
633 296 \textcolor{keywordtype}{int} ret = 0;
634 297 \textcolor{keywordflow}{if}(value) \{
635 298 std::string appid(afb\_req\_get\_application\_id(request));
636 299 std::lock\_guard<std::mutex> lock(this->mtx);
638 301 \textcolor{keyword}{auto} ip = client\_list.find(appid);
639 302 \textcolor{keywordflow}{if}(ip != client\_list.end()
640 303 && ip->second->unsubscribe(request, value) != 0) \{
641 304 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"unsubscribe failed"});
642 305 ret = \hyperlink{hs-helper_8h_a78e930a97920b821706a80ca8f430034}{AFB\_REQ\_UNSUBSCRIBE\_ERROR};
645 308 \textcolor{keywordflow}{else} \{
646 309 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Please input event name"});
647 310 ret = \hyperlink{hs-helper_8h_aa611e2ec24ef295bd87825889fe2ce5e}{AFB\_EVENT\_BAD\_REQUEST};
649 312 \textcolor{keywordflow}{return} ret;
654 The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
656 src/\hyperlink{hs-clientmanager_8h}{hs-\/clientmanager.\+h}\item
657 src/\hyperlink{hs-clientmanager_8cpp}{hs-\/clientmanager.\+cpp}\end{DoxyCompactItemize}