rad  3.0.0
ZpbHellomalifImpl.hpp
Go to the documentation of this file.
1 // GENERATED, DO NOT MANUALLY MODIFY
2 // generator core v1.10
3 // specific generator: C++ ZPB .hpp Generator v0.94
4 // source: /home/eltdev/workspace/ICS/RAD/ifw-rad-daily/test/templates/genMalSm/hello/hellomalif/src/hellomalif.xml
5 
6 #pragma once
7 
8 #include <opentracing/ext/tags.h>
9 #include <google/protobuf/io/zero_copy_stream_impl_lite.h>
10 
11 #include <memory>
12 #include <vector>
13 #include <string>
14 #include <algorithm>
15 #include <utility>
16 
17 #include <boost/functional/hash.hpp>
18 
19 #include <mal/Mal.hpp>
20 #include <mal/util/MalTracingUtil.hpp>
21 #include <mal/utility/future.hpp>
22 #include <mal/rr/ClientAsync.hpp>
23 #include <mal/rr/AmiZpb.hpp>
24 #include <mal/ps/ZpbDataEntity.hpp>
25 #include <mal/utility/Uri.hpp>
26 #include <mal/util/ZpbList.hpp>
27 #include <mal/types/ZpbMalTypes.hpp>
28 #include <mal/rr/ServerContextZpb.hpp>
29 #include <mal/rr/ServerContextZpbAmi.hpp>
30 #include <mal/rr/ServerContextProvider.hpp>
31 
32 
33 
34 
35 namespace hellomalif {
36 namespace zpb {
37 
38 // generated
40  public:
41  typedef ::generated::zpb::hellomalif::ExceptionErr ZpbType;
42 
43  ExceptionErrImpl(): m_zpbObj(new ::generated::zpb::hellomalif::ExceptionErr())
44  {}
45 
47  m_zpbObj(inner, ::elt::mal::util::list::NoopDeleter<ZpbType*>())
48  {}
49 
50 
51  explicit ExceptionErrImpl(const ::generated::zpb::hellomalif::ExceptionErr& inner):
53  *m_zpbObj = inner;
54  }
55 
56  explicit ExceptionErrImpl(const ::hellomalif::ExceptionErr& malVal):
58  copy(malVal);
59  }
60 
61  ExceptionErrImpl( const std::string& desc ): ExceptionErrImpl() {
62  setDesc(desc);
63  }
64 
65 
66  ExceptionErrImpl(const ExceptionErrImpl &rhs): m_zpbObj(rhs.m_zpbObj)
67  {}
68 
69  ExceptionErrImpl(ExceptionErrImpl &&rhs): m_zpbObj(std::move(rhs.m_zpbObj))
70  {}
71 
73  copy(that);
74  return *this;
75  }
76 
77  std::string getDesc() const override {
78  return m_zpbObj->desc();
79  }
80 
81  void copy(const ::hellomalif::ExceptionErr &from) {
82  setDesc(from.getDesc());
83  };
84 
85  operator ZpbType*() const {
86  return &*m_zpbObj;
87  }
88 
89  private:
90  void setDesc(const std::string& desc) {
91  m_zpbObj->set_desc(desc);
92  }
93 
94  std::shared_ptr<ZpbType> m_zpbObj;
95 
96  };
97 
98 } // namespace zpb
99 } // namespace hellomalif
100 
101 
102 
103 
104 
105 
106 
107 
108 namespace hellomalif {
109 namespace zpb {
110 
111 // generated
112 class LogInfoImpl : public virtual ::hellomalif::LogInfo,
113  public virtual ::elt::mal::ps::ZpbDataEntity<::hellomalif::LogInfo> {
114  public:
115  typedef ::generated::zpb::hellomalif::LogInfo ZpbType;
116 
117  LogInfoImpl(): m_zpbObj(new ::generated::zpb::hellomalif::LogInfo())
118  {}
119 
121  m_zpbObj(inner, ::elt::mal::util::list::NoopDeleter<ZpbType*>())
122  {}
123 
124 
125  explicit LogInfoImpl(const ::generated::zpb::hellomalif::LogInfo& inner):
126  LogInfoImpl() {
127  *m_zpbObj = inner;
128  }
129 
130  LogInfoImpl( const std::string& level, const std::string& logger ): LogInfoImpl() {
131  setLevel(level);
132  setLogger(logger);
133  }
134 
135 
136  LogInfoImpl(const LogInfoImpl &rhs): m_zpbObj(rhs.m_zpbObj) {}
137 
138  LogInfoImpl(LogInfoImpl &&rhs): m_zpbObj(std::move(rhs.m_zpbObj)) {}
139 
141  copy(that);
142  return *this;
143  }
144 
145  std::string getLevel() const override {
146  return m_zpbObj->level();
147  }
148 
149  void setLevel(const std::string& level) override {
150  m_zpbObj->set_level(level);
151  }
152  std::string getLogger() const override {
153  return m_zpbObj->logger();
154  }
155 
156  void setLogger(const std::string& logger) override {
157  m_zpbObj->set_logger(logger);
158  }
159 
160  std::unique_ptr<::hellomalif::LogInfo> clone() const override {
161  auto cloned = std::unique_ptr<::hellomalif::LogInfo>(new LogInfoImpl(getLevel(),getLogger()));
162 
163  auto const* traceableDataEntity = dynamic_cast<const ::elt::mal::ps::Traceable*>(this);
164  if (traceableDataEntity) {
165  auto *clonedTraceable = dynamic_cast<::elt::mal::ps::Traceable*>(cloned.get());
166  if (clonedTraceable) {
167  clonedTraceable->setTrace(traceableDataEntity->getTrace());
168  }
169  }
170  return cloned;
171  }
172 
173  bool keyEquals(const ::hellomalif::LogInfo& other) const override {
174  return false;
175  }
176 
177  std::size_t keyHash() const {
178  std::size_t seed = 0;
179  return seed;
180  }
181 
182  std::unique_ptr<::hellomalif::LogInfo> cloneKey() const override {
183  std::unique_ptr<::hellomalif::LogInfo> entity(new LogInfoImpl());
184  return entity;
185  };
186 
187  bool hasKey() const override {
188  return false;
189  }
190 
191  bool toByteArray(zmq::message_t& msg) const override {
192  msg.rebuild(m_zpbObj->ByteSizeLong());
193  return m_zpbObj->SerializeToArray(msg.data(), msg.size());
194  }
195 
196  bool toByteArray(std::string &output) const override {
197  return m_zpbObj->SerializeToString(&output);
198  }
199 
200  bool fromByteArray(const std::string &data) override {
201  return m_zpbObj->ParseFromString(data);
202  }
203 
204  bool fromByteArray(const void * data, std::size_t size) override {
205  google::protobuf::io::ArrayInputStream ais(data, size);
206  return m_zpbObj->ParseFromZeroCopyStream(&ais);
207  }
208 
209  void copy(const ::hellomalif::LogInfo &from) override {
210  setLevel(from.getLevel());
211  setLogger(from.getLogger());
212 
213  auto const* traceableFrom = dynamic_cast<const ::elt::mal::ps::Traceable*>(&from);
214  if (traceableFrom) {
215  auto* traceableTo = dynamic_cast<::elt::mal::ps::Traceable*>(this);
216  if (traceableTo) {
217  traceableTo->setTrace(traceableFrom->getTrace());
218  }
219  }
220  }
221 
222  operator ZpbType*() const {
223  return &*m_zpbObj;
224  }
225 
226  static int32_t typeHash() {
227  return -1574765012;
228  }
229 
230 
231  private:
232 
233  std::shared_ptr<ZpbType> m_zpbObj;
234 
235  };
236 
237 } // namespace zpb
238 } // namespace hellomalif
239 
240 
241 
242 
243 
244 
245 
246 
247 
248 namespace hellomalif {
249 namespace zpb {
250 
251 
252 template<typename Intf>
254 
255 
256 template<>
258  : public virtual ::elt::mal::rr::ClientAsyncImpl<::hellomalif::StdCmdsAsync,
259  ::generated::zpb::hellomalif::StdCmds_Request,
260  ::generated::zpb::hellomalif::StdCmds_Reply>,
261  public virtual ::hellomalif::StdCmdsAsync {
262  public:
264  const ::elt::mal::Uri &uri,
265  const std::vector<std::shared_ptr<::elt::mal::rr::qos::QoS>> &standardQoS,
266  const ::elt::mal::Mal::Properties &malSpecificProperties,
267  const std::shared_ptr<::elt::mal::ZpbMal> &zpbMal):
268  ::elt::mal::rr::ClientAsyncImpl<::hellomalif::StdCmdsAsync,
269  ::generated::zpb::hellomalif::StdCmds_Request, ::generated::zpb::hellomalif::StdCmds_Reply>(
270  uri, standardQoS, malSpecificProperties, zpbMal) {}
271 
272  ::elt::mal::future<std::string> Init() override {
275  new ::generated::zpb::hellomalif::StdCmds_Init_In();
276 
277 
278 
279  request.mutable_data()->set_allocated_init(params_);
280 
281  auto span = ::elt::mal::util::tracing::createSpan(
282  "Init", {::opentracing::SetTag {
283  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
284 
285  return sendRequest(request, std::move(span)).then([](
286  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
287  auto reply = replyFut.get();
288  auto code = reply.header().code();
289 
290  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
291  std::ostringstream errMsg;
292 
293  errMsg << "Code:" << code << " Message:";
294  reply.header().has_exceptionmessage() ?
295  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
296 
297  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
298  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
299  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
300  }
301  auto data = reply.data();
302  if (data.init().has_exexceptionerr()) {
303  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.init().exexceptionerr()));
304  }
305  return (std::string)data.init().retval();
306  });
307  }
308 
309  ::elt::mal::future<std::string> Reset() override {
312  new ::generated::zpb::hellomalif::StdCmds_Reset_In();
313 
314 
315 
316  request.mutable_data()->set_allocated_reset(params_);
317 
318  auto span = ::elt::mal::util::tracing::createSpan(
319  "Reset", {::opentracing::SetTag {
320  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
321 
322  return sendRequest(request, std::move(span)).then([](
323  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
324  auto reply = replyFut.get();
325  auto code = reply.header().code();
326 
327  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
328  std::ostringstream errMsg;
329 
330  errMsg << "Code:" << code << " Message:";
331  reply.header().has_exceptionmessage() ?
332  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
333 
334  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
335  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
336  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
337  }
338  auto data = reply.data();
339  if (data.reset().has_exexceptionerr()) {
340  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.reset().exexceptionerr()));
341  }
342  return (std::string)data.reset().retval();
343  });
344  }
345 
346  ::elt::mal::future<std::string> Enable() override {
349  new ::generated::zpb::hellomalif::StdCmds_Enable_In();
350 
351 
352 
353  request.mutable_data()->set_allocated_enable(params_);
354 
355  auto span = ::elt::mal::util::tracing::createSpan(
356  "Enable", {::opentracing::SetTag {
357  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
358 
359  return sendRequest(request, std::move(span)).then([](
360  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
361  auto reply = replyFut.get();
362  auto code = reply.header().code();
363 
364  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
365  std::ostringstream errMsg;
366 
367  errMsg << "Code:" << code << " Message:";
368  reply.header().has_exceptionmessage() ?
369  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
370 
371  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
372  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
373  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
374  }
375  auto data = reply.data();
376  if (data.enable().has_exexceptionerr()) {
377  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.enable().exexceptionerr()));
378  }
379  return (std::string)data.enable().retval();
380  });
381  }
382 
383  ::elt::mal::future<std::string> Disable() override {
386  new ::generated::zpb::hellomalif::StdCmds_Disable_In();
387 
388 
389 
390  request.mutable_data()->set_allocated_disable(params_);
391 
392  auto span = ::elt::mal::util::tracing::createSpan(
393  "Disable", {::opentracing::SetTag {
394  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
395 
396  return sendRequest(request, std::move(span)).then([](
397  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
398  auto reply = replyFut.get();
399  auto code = reply.header().code();
400 
401  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
402  std::ostringstream errMsg;
403 
404  errMsg << "Code:" << code << " Message:";
405  reply.header().has_exceptionmessage() ?
406  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
407 
408  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
409  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
410  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
411  }
412  auto data = reply.data();
413  if (data.disable().has_exexceptionerr()) {
414  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.disable().exexceptionerr()));
415  }
416  return (std::string)data.disable().retval();
417  });
418  }
419 
420  ::elt::mal::future<std::string> GetState() override {
423  new ::generated::zpb::hellomalif::StdCmds_GetState_In();
424 
425 
426 
427  request.mutable_data()->set_allocated_getstate(params_);
428 
429  auto span = ::elt::mal::util::tracing::createSpan(
430  "GetState", {::opentracing::SetTag {
431  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
432 
433  return sendRequest(request, std::move(span)).then([](
434  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
435  auto reply = replyFut.get();
436  auto code = reply.header().code();
437 
438  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
439  std::ostringstream errMsg;
440 
441  errMsg << "Code:" << code << " Message:";
442  reply.header().has_exceptionmessage() ?
443  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
444 
445  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
446  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
447  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
448  }
449  auto data = reply.data();
450  if (data.getstate().has_exexceptionerr()) {
451  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.getstate().exexceptionerr()));
452  }
453  return (std::string)data.getstate().retval();
454  });
455  }
456 
457  ::elt::mal::future<std::string> GetStatus() override {
460  new ::generated::zpb::hellomalif::StdCmds_GetStatus_In();
461 
462 
463 
464  request.mutable_data()->set_allocated_getstatus(params_);
465 
466  auto span = ::elt::mal::util::tracing::createSpan(
467  "GetStatus", {::opentracing::SetTag {
468  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
469 
470  return sendRequest(request, std::move(span)).then([](
471  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
472  auto reply = replyFut.get();
473  auto code = reply.header().code();
474 
475  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
476  std::ostringstream errMsg;
477 
478  errMsg << "Code:" << code << " Message:";
479  reply.header().has_exceptionmessage() ?
480  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
481 
482  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
483  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
484  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
485  }
486  auto data = reply.data();
487  if (data.getstatus().has_exexceptionerr()) {
488  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.getstatus().exexceptionerr()));
489  }
490  return (std::string)data.getstatus().retval();
491  });
492  }
493 
494  ::elt::mal::future<std::string> GetVersion() override {
497  new ::generated::zpb::hellomalif::StdCmds_GetVersion_In();
498 
499 
500 
501  request.mutable_data()->set_allocated_getversion(params_);
502 
503  auto span = ::elt::mal::util::tracing::createSpan(
504  "GetVersion", {::opentracing::SetTag {
505  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
506 
507  return sendRequest(request, std::move(span)).then([](
508  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
509  auto reply = replyFut.get();
510  auto code = reply.header().code();
511 
512  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
513  std::ostringstream errMsg;
514 
515  errMsg << "Code:" << code << " Message:";
516  reply.header().has_exceptionmessage() ?
517  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
518 
519  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
520  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
521  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
522  }
523  auto data = reply.data();
524  if (data.getversion().has_exexceptionerr()) {
525  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.getversion().exexceptionerr()));
526  }
527  return (std::string)data.getversion().retval();
528  });
529  }
530 
531  ::elt::mal::future<std::string> Stop() override {
534  new ::generated::zpb::hellomalif::StdCmds_Stop_In();
535 
536 
537 
538  request.mutable_data()->set_allocated_stop(params_);
539 
540  auto span = ::elt::mal::util::tracing::createSpan(
541  "Stop", {::opentracing::SetTag {
542  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
543 
544  return sendRequest(request, std::move(span)).then([](
545  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
546  auto reply = replyFut.get();
547  auto code = reply.header().code();
548 
549  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
550  std::ostringstream errMsg;
551 
552  errMsg << "Code:" << code << " Message:";
553  reply.header().has_exceptionmessage() ?
554  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
555 
556  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
557  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
558  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
559  }
560  auto data = reply.data();
561  if (data.stop().has_exexceptionerr()) {
562  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.stop().exexceptionerr()));
563  }
564  return (std::string)data.stop().retval();
565  });
566  }
567 
568  ::elt::mal::future<std::string> Exit() override {
571  new ::generated::zpb::hellomalif::StdCmds_Exit_In();
572 
573 
574 
575  request.mutable_data()->set_allocated_exit(params_);
576 
577  auto span = ::elt::mal::util::tracing::createSpan(
578  "Exit", {::opentracing::SetTag {
579  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
580 
581  return sendRequest(request, std::move(span)).then([](
582  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
583  auto reply = replyFut.get();
584  auto code = reply.header().code();
585 
586  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
587  std::ostringstream errMsg;
588 
589  errMsg << "Code:" << code << " Message:";
590  reply.header().has_exceptionmessage() ?
591  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
592 
593  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
594  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
595  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
596  }
597  auto data = reply.data();
598  if (data.exit().has_exexceptionerr()) {
599  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.exit().exexceptionerr()));
600  }
601  return (std::string)data.exit().retval();
602  });
603  }
604 
605  ::elt::mal::future<std::string> SetLogLevel( const std::shared_ptr<::hellomalif::LogInfo>& info) override {
608  new ::generated::zpb::hellomalif::StdCmds_SetLogLevel_In();
609 
610 
611  {
612  auto _infoImpl = dynamic_cast< ::hellomalif::zpb::LogInfoImpl*>(info.get());
613  if (_infoImpl) {
614  *params_->mutable_info() = **_infoImpl;
615  } else {
617  _tmp.copy(*info);
618  *params_->mutable_info() = **&_tmp;
619  }
620  }
621 
622  request.mutable_data()->set_allocated_setloglevel(params_);
623 
624  auto span = ::elt::mal::util::tracing::createSpan(
625  "SetLogLevel", {::opentracing::SetTag {
626  ::opentracing::ext::span_kind, ::opentracing::ext::span_kind_rpc_client }});
627 
628  return sendRequest(request, std::move(span)).then([](
629  ::elt::mal::future<::generated::zpb::hellomalif::StdCmds_Reply> replyFut) {
630  auto reply = replyFut.get();
631  auto code = reply.header().code();
632 
633  if (code != ::elt::mal::zpb::rr::CompletionCode::COMPLETED) {
634  std::ostringstream errMsg;
635 
636  errMsg << "Code:" << code << " Message:";
637  reply.header().has_exceptionmessage() ?
638  errMsg << reply.header().exceptionmessage() : errMsg << "Unknown error message";
639 
640  code == ::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION ?
641  ::elt::mal::throw_exception(::elt::mal::UnhandledRemoteException(errMsg.str())) :
642  ::elt::mal::throw_exception(::elt::mal::MalException(errMsg.str()));
643  }
644  auto data = reply.data();
645  if (data.setloglevel().has_exexceptionerr()) {
646  ::elt::mal::throw_exception(::hellomalif::zpb::ExceptionErrImpl(data.setloglevel().exexceptionerr()));
647  }
648  return (std::string)data.setloglevel().retval();
649  });
650  }
651 
652 };
653 
654 
656  public:
658  const ::elt::mal::Uri &uri,
659  const std::vector<std::shared_ptr<::elt::mal::rr::qos::QoS>> &standardQoS,
660  const ::elt::mal::Mal::Properties &malSpecificProperties,
661  const std::shared_ptr<::elt::mal::ZpbMal> &zpbMal)
662  : m_delegate(uri, standardQoS, malSpecificProperties, zpbMal), m_timeoutMs{} {
663  m_timeoutMs = ::elt::mal::util::getReplyTimeQoS(standardQoS);
664  }
665 
666  std::shared_ptr<::elt::mal::Mal> getMal() const override {
667  return m_delegate.getMal();
668  }
669 
670  std::string Init() override {
671  auto future = m_delegate.Init();
672  if (::elt::mal::future_status::ready
673  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
674  return future.get();
675  } else {
676  throw ::elt::mal::TimeoutException("timeout");
677  }
678  }
679 
680  std::string Reset() override {
681  auto future = m_delegate.Reset();
682  if (::elt::mal::future_status::ready
683  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
684  return future.get();
685  } else {
686  throw ::elt::mal::TimeoutException("timeout");
687  }
688  }
689 
690  std::string Enable() override {
691  auto future = m_delegate.Enable();
692  if (::elt::mal::future_status::ready
693  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
694  return future.get();
695  } else {
696  throw ::elt::mal::TimeoutException("timeout");
697  }
698  }
699 
700  std::string Disable() override {
701  auto future = m_delegate.Disable();
702  if (::elt::mal::future_status::ready
703  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
704  return future.get();
705  } else {
706  throw ::elt::mal::TimeoutException("timeout");
707  }
708  }
709 
710  std::string GetState() override {
711  auto future = m_delegate.GetState();
712  if (::elt::mal::future_status::ready
713  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
714  return future.get();
715  } else {
716  throw ::elt::mal::TimeoutException("timeout");
717  }
718  }
719 
720  std::string GetStatus() override {
721  auto future = m_delegate.GetStatus();
722  if (::elt::mal::future_status::ready
723  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
724  return future.get();
725  } else {
726  throw ::elt::mal::TimeoutException("timeout");
727  }
728  }
729 
730  std::string GetVersion() override {
731  auto future = m_delegate.GetVersion();
732  if (::elt::mal::future_status::ready
733  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
734  return future.get();
735  } else {
736  throw ::elt::mal::TimeoutException("timeout");
737  }
738  }
739 
740  std::string Stop() override {
741  auto future = m_delegate.Stop();
742  if (::elt::mal::future_status::ready
743  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
744  return future.get();
745  } else {
746  throw ::elt::mal::TimeoutException("timeout");
747  }
748  }
749 
750  std::string Exit() override {
751  auto future = m_delegate.Exit();
752  if (::elt::mal::future_status::ready
753  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
754  return future.get();
755  } else {
756  throw ::elt::mal::TimeoutException("timeout");
757  }
758  }
759 
760  std::string SetLogLevel( const std::shared_ptr<::hellomalif::LogInfo>& info) override {
761  auto future = m_delegate.SetLogLevel(info);
762  if (::elt::mal::future_status::ready
763  == future.wait_for(boost::chrono::milliseconds(m_timeoutMs))) {
764  return future.get();
765  } else {
766  throw ::elt::mal::TimeoutException("timeout");
767  }
768  }
769 
770 
771 
772  void close() override {
773  m_delegate.close();
774  }
775 
776  ::elt::mal::future<void> asyncConnect() override {
777  return m_delegate.asyncConnect();
778  }
779 
780  ::elt::mal::rr::ListenerRegistration registerConnectionListener(ConnectionListener listener) override {
781  return m_delegate.registerConnectionListener(listener);
782  }
783 
784  private:
786  int64_t m_timeoutMs;
787 };
788 
789 
790 class AsyncStdCmdsImpl : virtual public ::elt::mal::rr::ZpbRrEntity {
791  public:
793  ::elt::mal::rr::ZpbServer &zpbServer,
794  const std::shared_ptr<::hellomalif::AsyncStdCmds> &entity,
795  const std::shared_ptr<::elt::mal::Mal> &mal)
796  : m_zpbServer(zpbServer), m_entity(entity), m_mal(mal) {}
797 
798 
799  void processRequest(zmq::socket_t &socket,
800  const std::string &id, const std::string &topicIdFrame,
801  const std::string &headerFrame,
802  const ::elt::mal::zpb::rr::ZpbHeader &header) {
803  if (!::elt::mal::util::getSocketHasRcvMore(socket)) {
804  std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader> unhandledExReplyHeader(
805  new ::elt::mal::zpb::rr::ReplyHeader());
806 
807  unhandledExReplyHeader->set_code(::elt::mal::zpb::rr::CompletionCode::INVALID_ARGUMENT);
808  unhandledExReplyHeader->set_exceptionmessage("missing request frame");
809 
810  sendReply(socket, id, topicIdFrame, headerFrame, std::move(unhandledExReplyHeader),
811  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return>());
812 
813  return;
814  }
815 
817 
818  //auto requestStr = ::elt::mal::util::readFrame(socket);
819  zmq::message_t msgFrame;
820  socket.recv(&msgFrame, 0);
821 
822  if (!request.ParseFromArray(msgFrame.data(), msgFrame.size())) {
823  std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader> unhandledExReplyHeader(
824  new ::elt::mal::zpb::rr::ReplyHeader());
825 
826  unhandledExReplyHeader->set_code(::elt::mal::zpb::rr::CompletionCode::INVALID_ARGUMENT);
827  unhandledExReplyHeader->set_exceptionmessage("Invalid Request: Request parsing failed");
828 
829  sendReply(socket, id, topicIdFrame, headerFrame, std::move(unhandledExReplyHeader),
830  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return>());
831 
832  return;
833  }
834 
835  auto call = request.mutable_data();
836 
837  if (call->has_init()) {
838  auto span = std::shared_ptr<::opentracing::Span>();
839  if (header.has_trace()) {
840  auto spanUnique = ::elt::mal::util::tracing::createSpan(
841  "StdCmds::Init", header.trace(), ::opentracing::ext::span_kind_rpc_server);
842  span = std::move(spanUnique);
843  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
844  }
845  auto params_ = call->mutable_init();
846 
847  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
848  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
849 
850  ::elt::mal::rr::ServerContextProvider::setInstance<
851  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
852 
853  m_entity->Init().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
854  (::elt::mal::future<std::string> f) {
855  if (!f.has_exception()) {
856  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
857  new ::generated::zpb::hellomalif::StdCmds_Return());
858 
859  auto out = new ::generated::zpb::hellomalif::StdCmds_Init_Out();
860 
861  out->set_retval(f.get());
862 
863  data->set_allocated_init(out);
864  if (span) { span->Finish();}
865  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
866  } else {
867  try {
868  ::elt::mal::rethrow_exception(f.get_exception_ptr());
869  }
870  catch (::hellomalif::ExceptionErr &e) {
871  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
872 
874 
875  auto out = new ::generated::zpb::hellomalif::StdCmds_Init_Out();
876 
877  *out->mutable_exexceptionerr() = **&_ex;
878 
879  data->set_allocated_init(out);
880  if (span) { span->Finish();}
881  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
882  } catch (...) {}
883  if (span) { span->Finish();}
884  sendUnhandledExceptionReply(socket, id, topicIdFrame,
885  headerFrame, f.get_exception_ptr());
886  }
887  });
888 
889  } else if (call->has_reset()) {
890  auto span = std::shared_ptr<::opentracing::Span>();
891  if (header.has_trace()) {
892  auto spanUnique = ::elt::mal::util::tracing::createSpan(
893  "StdCmds::Reset", header.trace(), ::opentracing::ext::span_kind_rpc_server);
894  span = std::move(spanUnique);
895  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
896  }
897  auto params_ = call->mutable_reset();
898 
899  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
900  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
901 
902  ::elt::mal::rr::ServerContextProvider::setInstance<
903  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
904 
905  m_entity->Reset().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
906  (::elt::mal::future<std::string> f) {
907  if (!f.has_exception()) {
908  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
909  new ::generated::zpb::hellomalif::StdCmds_Return());
910 
911  auto out = new ::generated::zpb::hellomalif::StdCmds_Reset_Out();
912 
913  out->set_retval(f.get());
914 
915  data->set_allocated_reset(out);
916  if (span) { span->Finish();}
917  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
918  } else {
919  try {
920  ::elt::mal::rethrow_exception(f.get_exception_ptr());
921  }
922  catch (::hellomalif::ExceptionErr &e) {
923  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
924 
926 
927  auto out = new ::generated::zpb::hellomalif::StdCmds_Reset_Out();
928 
929  *out->mutable_exexceptionerr() = **&_ex;
930 
931  data->set_allocated_reset(out);
932  if (span) { span->Finish();}
933  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
934  } catch (...) {}
935  if (span) { span->Finish();}
936  sendUnhandledExceptionReply(socket, id, topicIdFrame,
937  headerFrame, f.get_exception_ptr());
938  }
939  });
940 
941  } else if (call->has_enable()) {
942  auto span = std::shared_ptr<::opentracing::Span>();
943  if (header.has_trace()) {
944  auto spanUnique = ::elt::mal::util::tracing::createSpan(
945  "StdCmds::Enable", header.trace(), ::opentracing::ext::span_kind_rpc_server);
946  span = std::move(spanUnique);
947  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
948  }
949  auto params_ = call->mutable_enable();
950 
951  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
952  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
953 
954  ::elt::mal::rr::ServerContextProvider::setInstance<
955  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
956 
957  m_entity->Enable().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
958  (::elt::mal::future<std::string> f) {
959  if (!f.has_exception()) {
960  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
961  new ::generated::zpb::hellomalif::StdCmds_Return());
962 
963  auto out = new ::generated::zpb::hellomalif::StdCmds_Enable_Out();
964 
965  out->set_retval(f.get());
966 
967  data->set_allocated_enable(out);
968  if (span) { span->Finish();}
969  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
970  } else {
971  try {
972  ::elt::mal::rethrow_exception(f.get_exception_ptr());
973  }
974  catch (::hellomalif::ExceptionErr &e) {
975  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
976 
978 
979  auto out = new ::generated::zpb::hellomalif::StdCmds_Enable_Out();
980 
981  *out->mutable_exexceptionerr() = **&_ex;
982 
983  data->set_allocated_enable(out);
984  if (span) { span->Finish();}
985  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
986  } catch (...) {}
987  if (span) { span->Finish();}
988  sendUnhandledExceptionReply(socket, id, topicIdFrame,
989  headerFrame, f.get_exception_ptr());
990  }
991  });
992 
993  } else if (call->has_disable()) {
994  auto span = std::shared_ptr<::opentracing::Span>();
995  if (header.has_trace()) {
996  auto spanUnique = ::elt::mal::util::tracing::createSpan(
997  "StdCmds::Disable", header.trace(), ::opentracing::ext::span_kind_rpc_server);
998  span = std::move(spanUnique);
999  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1000  }
1001  auto params_ = call->mutable_disable();
1002 
1003  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1004  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1005 
1006  ::elt::mal::rr::ServerContextProvider::setInstance<
1007  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1008 
1009  m_entity->Disable().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1010  (::elt::mal::future<std::string> f) {
1011  if (!f.has_exception()) {
1012  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1013  new ::generated::zpb::hellomalif::StdCmds_Return());
1014 
1015  auto out = new ::generated::zpb::hellomalif::StdCmds_Disable_Out();
1016 
1017  out->set_retval(f.get());
1018 
1019  data->set_allocated_disable(out);
1020  if (span) { span->Finish();}
1021  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1022  } else {
1023  try {
1024  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1025  }
1026  catch (::hellomalif::ExceptionErr &e) {
1027  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1028 
1030 
1031  auto out = new ::generated::zpb::hellomalif::StdCmds_Disable_Out();
1032 
1033  *out->mutable_exexceptionerr() = **&_ex;
1034 
1035  data->set_allocated_disable(out);
1036  if (span) { span->Finish();}
1037  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1038  } catch (...) {}
1039  if (span) { span->Finish();}
1040  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1041  headerFrame, f.get_exception_ptr());
1042  }
1043  });
1044 
1045  } else if (call->has_getstate()) {
1046  auto span = std::shared_ptr<::opentracing::Span>();
1047  if (header.has_trace()) {
1048  auto spanUnique = ::elt::mal::util::tracing::createSpan(
1049  "StdCmds::GetState", header.trace(), ::opentracing::ext::span_kind_rpc_server);
1050  span = std::move(spanUnique);
1051  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1052  }
1053  auto params_ = call->mutable_getstate();
1054 
1055  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1056  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1057 
1058  ::elt::mal::rr::ServerContextProvider::setInstance<
1059  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1060 
1061  m_entity->GetState().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1062  (::elt::mal::future<std::string> f) {
1063  if (!f.has_exception()) {
1064  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1065  new ::generated::zpb::hellomalif::StdCmds_Return());
1066 
1067  auto out = new ::generated::zpb::hellomalif::StdCmds_GetState_Out();
1068 
1069  out->set_retval(f.get());
1070 
1071  data->set_allocated_getstate(out);
1072  if (span) { span->Finish();}
1073  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1074  } else {
1075  try {
1076  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1077  }
1078  catch (::hellomalif::ExceptionErr &e) {
1079  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1080 
1082 
1083  auto out = new ::generated::zpb::hellomalif::StdCmds_GetState_Out();
1084 
1085  *out->mutable_exexceptionerr() = **&_ex;
1086 
1087  data->set_allocated_getstate(out);
1088  if (span) { span->Finish();}
1089  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1090  } catch (...) {}
1091  if (span) { span->Finish();}
1092  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1093  headerFrame, f.get_exception_ptr());
1094  }
1095  });
1096 
1097  } else if (call->has_getstatus()) {
1098  auto span = std::shared_ptr<::opentracing::Span>();
1099  if (header.has_trace()) {
1100  auto spanUnique = ::elt::mal::util::tracing::createSpan(
1101  "StdCmds::GetStatus", header.trace(), ::opentracing::ext::span_kind_rpc_server);
1102  span = std::move(spanUnique);
1103  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1104  }
1105  auto params_ = call->mutable_getstatus();
1106 
1107  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1108  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1109 
1110  ::elt::mal::rr::ServerContextProvider::setInstance<
1111  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1112 
1113  m_entity->GetStatus().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1114  (::elt::mal::future<std::string> f) {
1115  if (!f.has_exception()) {
1116  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1117  new ::generated::zpb::hellomalif::StdCmds_Return());
1118 
1119  auto out = new ::generated::zpb::hellomalif::StdCmds_GetStatus_Out();
1120 
1121  out->set_retval(f.get());
1122 
1123  data->set_allocated_getstatus(out);
1124  if (span) { span->Finish();}
1125  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1126  } else {
1127  try {
1128  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1129  }
1130  catch (::hellomalif::ExceptionErr &e) {
1131  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1132 
1134 
1135  auto out = new ::generated::zpb::hellomalif::StdCmds_GetStatus_Out();
1136 
1137  *out->mutable_exexceptionerr() = **&_ex;
1138 
1139  data->set_allocated_getstatus(out);
1140  if (span) { span->Finish();}
1141  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1142  } catch (...) {}
1143  if (span) { span->Finish();}
1144  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1145  headerFrame, f.get_exception_ptr());
1146  }
1147  });
1148 
1149  } else if (call->has_getversion()) {
1150  auto span = std::shared_ptr<::opentracing::Span>();
1151  if (header.has_trace()) {
1152  auto spanUnique = ::elt::mal::util::tracing::createSpan(
1153  "StdCmds::GetVersion", header.trace(), ::opentracing::ext::span_kind_rpc_server);
1154  span = std::move(spanUnique);
1155  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1156  }
1157  auto params_ = call->mutable_getversion();
1158 
1159  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1160  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1161 
1162  ::elt::mal::rr::ServerContextProvider::setInstance<
1163  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1164 
1165  m_entity->GetVersion().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1166  (::elt::mal::future<std::string> f) {
1167  if (!f.has_exception()) {
1168  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1169  new ::generated::zpb::hellomalif::StdCmds_Return());
1170 
1171  auto out = new ::generated::zpb::hellomalif::StdCmds_GetVersion_Out();
1172 
1173  out->set_retval(f.get());
1174 
1175  data->set_allocated_getversion(out);
1176  if (span) { span->Finish();}
1177  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1178  } else {
1179  try {
1180  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1181  }
1182  catch (::hellomalif::ExceptionErr &e) {
1183  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1184 
1186 
1187  auto out = new ::generated::zpb::hellomalif::StdCmds_GetVersion_Out();
1188 
1189  *out->mutable_exexceptionerr() = **&_ex;
1190 
1191  data->set_allocated_getversion(out);
1192  if (span) { span->Finish();}
1193  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1194  } catch (...) {}
1195  if (span) { span->Finish();}
1196  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1197  headerFrame, f.get_exception_ptr());
1198  }
1199  });
1200 
1201  } else if (call->has_stop()) {
1202  auto span = std::shared_ptr<::opentracing::Span>();
1203  if (header.has_trace()) {
1204  auto spanUnique = ::elt::mal::util::tracing::createSpan(
1205  "StdCmds::Stop", header.trace(), ::opentracing::ext::span_kind_rpc_server);
1206  span = std::move(spanUnique);
1207  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1208  }
1209  auto params_ = call->mutable_stop();
1210 
1211  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1212  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1213 
1214  ::elt::mal::rr::ServerContextProvider::setInstance<
1215  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1216 
1217  m_entity->Stop().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1218  (::elt::mal::future<std::string> f) {
1219  if (!f.has_exception()) {
1220  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1221  new ::generated::zpb::hellomalif::StdCmds_Return());
1222 
1223  auto out = new ::generated::zpb::hellomalif::StdCmds_Stop_Out();
1224 
1225  out->set_retval(f.get());
1226 
1227  data->set_allocated_stop(out);
1228  if (span) { span->Finish();}
1229  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1230  } else {
1231  try {
1232  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1233  }
1234  catch (::hellomalif::ExceptionErr &e) {
1235  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1236 
1238 
1239  auto out = new ::generated::zpb::hellomalif::StdCmds_Stop_Out();
1240 
1241  *out->mutable_exexceptionerr() = **&_ex;
1242 
1243  data->set_allocated_stop(out);
1244  if (span) { span->Finish();}
1245  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1246  } catch (...) {}
1247  if (span) { span->Finish();}
1248  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1249  headerFrame, f.get_exception_ptr());
1250  }
1251  });
1252 
1253  } else if (call->has_exit()) {
1254  auto span = std::shared_ptr<::opentracing::Span>();
1255  if (header.has_trace()) {
1256  auto spanUnique = ::elt::mal::util::tracing::createSpan(
1257  "StdCmds::Exit", header.trace(), ::opentracing::ext::span_kind_rpc_server);
1258  span = std::move(spanUnique);
1259  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1260  }
1261  auto params_ = call->mutable_exit();
1262 
1263  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1264  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1265 
1266  ::elt::mal::rr::ServerContextProvider::setInstance<
1267  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1268 
1269  m_entity->Exit().then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1270  (::elt::mal::future<std::string> f) {
1271  if (!f.has_exception()) {
1272  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1273  new ::generated::zpb::hellomalif::StdCmds_Return());
1274 
1275  auto out = new ::generated::zpb::hellomalif::StdCmds_Exit_Out();
1276 
1277  out->set_retval(f.get());
1278 
1279  data->set_allocated_exit(out);
1280  if (span) { span->Finish();}
1281  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1282  } else {
1283  try {
1284  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1285  }
1286  catch (::hellomalif::ExceptionErr &e) {
1287  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1288 
1290 
1291  auto out = new ::generated::zpb::hellomalif::StdCmds_Exit_Out();
1292 
1293  *out->mutable_exexceptionerr() = **&_ex;
1294 
1295  data->set_allocated_exit(out);
1296  if (span) { span->Finish();}
1297  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1298  } catch (...) {}
1299  if (span) { span->Finish();}
1300  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1301  headerFrame, f.get_exception_ptr());
1302  }
1303  });
1304 
1305  } else if (call->has_setloglevel()) {
1306  auto span = std::shared_ptr<::opentracing::Span>();
1307  if (header.has_trace()) {
1308  auto spanUnique = ::elt::mal::util::tracing::createSpan(
1309  "StdCmds::SetLogLevel", header.trace(), ::opentracing::ext::span_kind_rpc_server);
1310  span = std::move(spanUnique);
1311  ::elt::mal::util::tracing::ScopeManagerFactory::getScopeManager().activate(span);
1312  }
1313  auto params_ = call->mutable_setloglevel();
1314 
1315  auto serverContext = std::unique_ptr<::elt::mal::rr::ServerContext<std::string>>(
1316  new ::elt::mal::rr::ServerContextZpb<std::string>(m_mal));
1317 
1318  ::elt::mal::rr::ServerContextProvider::setInstance<
1319  ::elt::mal::rr::ServerContext<std::string>>(serverContext);
1320 
1321  m_entity->SetLogLevel(std::shared_ptr< ::hellomalif::LogInfo>(new ::hellomalif::zpb::LogInfoImpl(params_->mutable_info()))).then(m_zpbServer.getExecutor(), [this, &socket, id, topicIdFrame, headerFrame, params_, span]
1322  (::elt::mal::future<std::string> f) {
1323  if (!f.has_exception()) {
1324  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(
1325  new ::generated::zpb::hellomalif::StdCmds_Return());
1326 
1327  auto out = new ::generated::zpb::hellomalif::StdCmds_SetLogLevel_Out();
1328 
1329  out->set_retval(f.get());
1330 
1331  data->set_allocated_setloglevel(out);
1332  if (span) { span->Finish();}
1333  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1334  } else {
1335  try {
1336  ::elt::mal::rethrow_exception(f.get_exception_ptr());
1337  }
1338  catch (::hellomalif::ExceptionErr &e) {
1339  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data(new ::generated::zpb::hellomalif::StdCmds_Return());
1340 
1342 
1343  auto out = new ::generated::zpb::hellomalif::StdCmds_SetLogLevel_Out();
1344 
1345  *out->mutable_exexceptionerr() = **&_ex;
1346 
1347  data->set_allocated_setloglevel(out);
1348  if (span) { span->Finish();}
1349  sendCompletedReply(socket, id, topicIdFrame, headerFrame, std::move(data));
1350  } catch (...) {}
1351  if (span) { span->Finish();}
1352  sendUnhandledExceptionReply(socket, id, topicIdFrame,
1353  headerFrame, f.get_exception_ptr());
1354  }
1355  });
1356 
1357 } else {
1358 std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader> unhandledExReplyHeader(
1359  new ::elt::mal::zpb::rr::ReplyHeader());
1360 
1361 unhandledExReplyHeader->set_code(::elt::mal::zpb::rr::CompletionCode::UNKNOWN_OPERATION);
1362 
1363 sendReply(socket, id, topicIdFrame, headerFrame, std::move(unhandledExReplyHeader),
1364  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return>());
1365 }
1366  }
1367 
1369  zmq::socket_t &socket, const std::string &id, const std::string &topicIdFrame,
1370  const std::string &headerFrame,
1371  std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader> replyHeader,
1372  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data) {
1374 
1375  reply.set_allocated_header(replyHeader.release());
1376 
1377  if (data) {
1378  reply.set_allocated_data(data.release());
1379  }
1380 
1381  auto replyStr = reply.SerializeAsString();
1382 
1383  m_zpbServer.sendReply(socket, id, topicIdFrame, headerFrame, replyStr);
1384  }
1385 
1387  zmq::socket_t &socket, const std::string &id,
1388  const std::string &topicIdFrame, const std::string &headerFrame,
1389  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return> data) {
1390  std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader> completedReplyHeader(
1391  new ::elt::mal::zpb::rr::ReplyHeader());
1392 
1393  completedReplyHeader->set_code(::elt::mal::zpb::rr::CompletionCode::COMPLETED);
1394 
1395  sendReply(socket, id, topicIdFrame, headerFrame,
1396  std::move(completedReplyHeader), std::move(data));
1397  }
1398 
1400  zmq::socket_t &socket, const std::string &id, const std::string &topicIdFrame,
1401  const std::string &headerFrame, ::elt::mal::exception_ptr exceptionPtr) {
1402  std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader> unhandledExReplyHeader(
1403  new ::elt::mal::zpb::rr::ReplyHeader());
1404 
1405  unhandledExReplyHeader->set_code(::elt::mal::zpb::rr::CompletionCode::UNKNOWN_EXCEPTION);
1406 
1407  std::string exceptionMessage = "Unknown";
1408 
1409  try {
1410  ::elt::mal::rethrow_exception(exceptionPtr);
1411  } catch (std::exception &e) {
1412  exceptionMessage = e.what();
1413  } catch (...) {}
1414 
1415  unhandledExReplyHeader->set_exceptionmessage(exceptionMessage);
1416 
1417  sendReply(socket, id, topicIdFrame, headerFrame, std::move(unhandledExReplyHeader),
1418  std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return>());
1419  }
1420 
1421  private:
1422  ::elt::mal::rr::ZpbServer &m_zpbServer;
1423  std::shared_ptr<::hellomalif::AsyncStdCmds> m_entity;
1424  const std::shared_ptr<::elt::mal::Mal>& m_mal;
1425 };
1426 
1427 
1428 } // namespace zpb
1429 } // namespace hellomalif
1430 
1431 
1432 
1433 
1434 
1435 
1436 
hellomalif::ExceptionErr::desc
std::string desc
Definition: Hellomalif.hpp:46
generated
Definition: exmalif.pb.h:50
hellomalif::zpb::StdCmdsSyncImpl::StdCmdsSyncImpl
StdCmdsSyncImpl(const ::elt::mal::Uri &uri, const std::vector< std::shared_ptr<::elt::mal::rr::qos::QoS >> &standardQoS, const ::elt::mal::Mal::Properties &malSpecificProperties, const std::shared_ptr<::elt::mal::ZpbMal > &zpbMal)
Definition: ZpbHellomalifImpl.hpp:657
hellorad.level
level
Definition: hellorad.py:30
hellomalif::StdCmdsSync
Definition: Hellomalif.hpp:122
hellomalif::zpb::AsyncStdCmdsImpl::processRequest
void processRequest(zmq::socket_t &socket, const std::string &id, const std::string &topicIdFrame, const std::string &headerFrame, const ::elt::mal::zpb::rr::ZpbHeader &header)
Definition: ZpbHellomalifImpl.hpp:799
generated::zpb::hellomalif::StdCmds_SetLogLevel_In::mutable_info
::generated::zpb::hellomalif::LogInfo * mutable_info()
Definition: hellomalif.pb.h:3948
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl(const ::hellomalif::ExceptionErr &malVal)
Definition: ZpbHellomalifImpl.hpp:56
hellomalif::zpb::StdCmdsSyncImpl::registerConnectionListener
::elt::mal::rr::ListenerRegistration registerConnectionListener(ConnectionListener listener) override
Definition: ZpbHellomalifImpl.hpp:780
generated::zpb::hellomalif::StdCmds_Call::set_allocated_stop
void set_allocated_stop(::generated::zpb::hellomalif::StdCmds_Stop_In *stop)
hellomalif::zpb::LogInfoImpl::LogInfoImpl
LogInfoImpl(const ::generated::zpb::hellomalif::LogInfo &inner)
Definition: ZpbHellomalifImpl.hpp:125
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl(ExceptionErrImpl &&rhs)
Definition: ZpbHellomalifImpl.hpp:69
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::Reset
::elt::mal::future< std::string > Reset() override
Definition: ZpbHellomalifImpl.hpp:309
hellomalif::zpb::LogInfoImpl::LogInfoImpl
LogInfoImpl(::generated::zpb::hellomalif::LogInfo *inner)
Definition: ZpbHellomalifImpl.hpp:120
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::Init
::elt::mal::future< std::string > Init() override
Definition: ZpbHellomalifImpl.hpp:272
hellomalif::LogInfo
Definition: Hellomalif.hpp:53
generated::zpb::hellomalif::StdCmds_Call::set_allocated_init
void set_allocated_init(::generated::zpb::hellomalif::StdCmds_Init_In *init)
hellomalif::zpb::AsyncStdCmdsImpl::sendUnhandledExceptionReply
void sendUnhandledExceptionReply(zmq::socket_t &socket, const std::string &id, const std::string &topicIdFrame, const std::string &headerFrame, ::elt::mal::exception_ptr exceptionPtr)
Definition: ZpbHellomalifImpl.hpp:1399
hellomalif::zpb::LogInfoImpl
Definition: ZpbHellomalifImpl.hpp:113
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::Exit
::elt::mal::future< std::string > Exit() override
Definition: ZpbHellomalifImpl.hpp:568
generated::zpb::hellomalif::StdCmds_Call::set_allocated_exit
void set_allocated_exit(::generated::zpb::hellomalif::StdCmds_Exit_In *exit)
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::GetVersion
::elt::mal::future< std::string > GetVersion() override
Definition: ZpbHellomalifImpl.hpp:494
generated::zpb::hellomalif::StdCmds_Reply::set_allocated_data
void set_allocated_data(::generated::zpb::hellomalif::StdCmds_Return *data)
Definition: hellomalif.pb.h:6375
hellomalif::zpb::StdCmdsSyncImpl::Enable
std::string Enable() override
Definition: ZpbHellomalifImpl.hpp:690
hellomalif::zpb::StdCmdsSyncImpl::SetLogLevel
std::string SetLogLevel(const std::shared_ptr<::hellomalif::LogInfo > &info) override
Definition: ZpbHellomalifImpl.hpp:760
generated::zpb::hellomalif::StdCmds_Call::set_allocated_setloglevel
void set_allocated_setloglevel(::generated::zpb::hellomalif::StdCmds_SetLogLevel_In *setloglevel)
hellomalif::zpb::ExceptionErrImpl::copy
void copy(const ::hellomalif::ExceptionErr &from)
Definition: ZpbHellomalifImpl.hpp:81
generated::zpb::hellomalif::StdCmds_Exit_In
Definition: hellomalif.pb.h:1267
generated::zpb::hellomalif::StdCmds_Reply::set_allocated_header
void set_allocated_header(::elt::mal::zpb::rr::ReplyHeader *header)
Definition: hellomalif.pb.h:6317
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl(const ::generated::zpb::hellomalif::ExceptionErr &inner)
Definition: ZpbHellomalifImpl.hpp:51
hellomalif::zpb::StdCmdsSyncImpl
Definition: ZpbHellomalifImpl.hpp:655
hellomalif::zpb::LogInfoImpl::typeHash
static int32_t typeHash()
Definition: ZpbHellomalifImpl.hpp:226
hellomalif::zpb::LogInfoImpl::LogInfoImpl
LogInfoImpl()
Definition: ZpbHellomalifImpl.hpp:117
hellomalif::zpb::StdCmdsSyncImpl::close
void close() override
Definition: ZpbHellomalifImpl.hpp:772
hellomalif::zpb::StdCmdsAsyncImpl
Definition: ZpbHellomalifImpl.hpp:253
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::StdCmdsAsyncImpl
StdCmdsAsyncImpl(const ::elt::mal::Uri &uri, const std::vector< std::shared_ptr<::elt::mal::rr::qos::QoS >> &standardQoS, const ::elt::mal::Mal::Properties &malSpecificProperties, const std::shared_ptr<::elt::mal::ZpbMal > &zpbMal)
Definition: ZpbHellomalifImpl.hpp:263
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl(const ExceptionErrImpl &rhs)
Definition: ZpbHellomalifImpl.hpp:66
scxml4py.activity.logger
logger
Definition: activity.py:32
hellomalif::zpb::LogInfoImpl::LogInfoImpl
LogInfoImpl(const std::string &level, const std::string &logger)
Definition: ZpbHellomalifImpl.hpp:130
hellomalif::ExceptionErr
Definition: Hellomalif.hpp:28
hellomalif::zpb::LogInfoImpl::getLevel
std::string getLevel() const override
Definition: ZpbHellomalifImpl.hpp:145
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >
Definition: ZpbHellomalifImpl.hpp:261
hellomalif::zpb::LogInfoImpl::setLevel
void setLevel(const std::string &level) override
Definition: ZpbHellomalifImpl.hpp:149
generated::zpb::hellomalif::StdCmds_GetStatus_In
Definition: hellomalif.pb.h:955
hellomalif::zpb::LogInfoImpl::fromByteArray
bool fromByteArray(const std::string &data) override
Definition: ZpbHellomalifImpl.hpp:200
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::GetStatus
::elt::mal::future< std::string > GetStatus() override
Definition: ZpbHellomalifImpl.hpp:457
generated::zpb::hellomalif::StdCmds_Reply
Definition: hellomalif.pb.h:3533
hellomalif::zpb::StdCmdsSyncImpl::GetStatus
std::string GetStatus() override
Definition: ZpbHellomalifImpl.hpp:720
hellomalif::zpb::StdCmdsSyncImpl::GetState
std::string GetState() override
Definition: ZpbHellomalifImpl.hpp:710
generated::zpb::hellomalif::LogInfo
Definition: hellomalif.pb.h:292
hellomalif::zpb::StdCmdsSyncImpl::Init
std::string Init() override
Definition: ZpbHellomalifImpl.hpp:670
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::SetLogLevel
::elt::mal::future< std::string > SetLogLevel(const std::shared_ptr<::hellomalif::LogInfo > &info) override
Definition: ZpbHellomalifImpl.hpp:605
hellomalif::zpb::LogInfoImpl::LogInfoImpl
LogInfoImpl(LogInfoImpl &&rhs)
Definition: ZpbHellomalifImpl.hpp:138
generated::zpb::hellomalif::StdCmds_Enable_In
Definition: hellomalif.pb.h:643
generated::zpb::hellomalif::StdCmds_Init_In
Definition: hellomalif.pb.h:435
hellomalif::zpb::LogInfoImpl::operator=
LogInfoImpl & operator=(const LogInfoImpl &that)
Definition: ZpbHellomalifImpl.hpp:140
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::Disable
::elt::mal::future< std::string > Disable() override
Definition: ZpbHellomalifImpl.hpp:383
hellomalif::zpb::ExceptionErrImpl::ZpbType
::generated::zpb::hellomalif::ExceptionErr ZpbType
Definition: ZpbHellomalifImpl.hpp:41
hellomalif::zpb::LogInfoImpl::LogInfoImpl
LogInfoImpl(const LogInfoImpl &rhs)
Definition: ZpbHellomalifImpl.hpp:136
generated::zpb::hellomalif::StdCmds_Request
Definition: hellomalif.pb.h:1758
hellomalif::zpb::AsyncStdCmdsImpl::sendReply
void sendReply(zmq::socket_t &socket, const std::string &id, const std::string &topicIdFrame, const std::string &headerFrame, std::unique_ptr<::elt::mal::zpb::rr::ReplyHeader > replyHeader, std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return > data)
Definition: ZpbHellomalifImpl.hpp:1368
hellomalif::zpb::AsyncStdCmdsImpl::AsyncStdCmdsImpl
AsyncStdCmdsImpl(::elt::mal::rr::ZpbServer &zpbServer, const std::shared_ptr<::hellomalif::AsyncStdCmds > &entity, const std::shared_ptr<::elt::mal::Mal > &mal)
Definition: ZpbHellomalifImpl.hpp:792
generated::zpb::hellomalif::ExceptionErr
Definition: hellomalif.pb.h:170
hellomalif::zpb::AsyncStdCmdsImpl::sendCompletedReply
void sendCompletedReply(zmq::socket_t &socket, const std::string &id, const std::string &topicIdFrame, const std::string &headerFrame, std::unique_ptr<::generated::zpb::hellomalif::StdCmds_Return > data)
Definition: ZpbHellomalifImpl.hpp:1386
hellomalif::zpb::StdCmdsSyncImpl::Stop
std::string Stop() override
Definition: ZpbHellomalifImpl.hpp:740
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl()
Definition: ZpbHellomalifImpl.hpp:43
elt
Definition: Exmalif.hpp:418
hellomalif::zpb::StdCmdsSyncImpl::asyncConnect
::elt::mal::future< void > asyncConnect() override
Definition: ZpbHellomalifImpl.hpp:776
generated::zpb::hellomalif::StdCmds_GetVersion_In
Definition: hellomalif.pb.h:1059
hellomalif::zpb::ExceptionErrImpl
Definition: ZpbHellomalifImpl.hpp:39
hellomalif::zpb::StdCmdsSyncImpl::getMal
std::shared_ptr<::elt::mal::Mal > getMal() const override
Definition: ZpbHellomalifImpl.hpp:666
hellomalif::zpb::LogInfoImpl::toByteArray
bool toByteArray(zmq::message_t &msg) const override
Definition: ZpbHellomalifImpl.hpp:191
hellomalif::zpb::ExceptionErrImpl::operator=
ExceptionErrImpl & operator=(const ExceptionErrImpl &that)
Definition: ZpbHellomalifImpl.hpp:72
generated::zpb::hellomalif::StdCmds_Call::set_allocated_disable
void set_allocated_disable(::generated::zpb::hellomalif::StdCmds_Disable_In *disable)
generated::zpb::hellomalif::StdCmds_Request::mutable_data
::generated::zpb::hellomalif::StdCmds_Call * mutable_data()
Definition: hellomalif.pb.h:4517
generated::zpb::hellomalif::StdCmds_Call::set_allocated_enable
void set_allocated_enable(::generated::zpb::hellomalif::StdCmds_Enable_In *enable)
generated::zpb::hellomalif::StdCmds_Call::set_allocated_getversion
void set_allocated_getversion(::generated::zpb::hellomalif::StdCmds_GetVersion_In *getversion)
hellomalif::zpb::LogInfoImpl::hasKey
bool hasKey() const override
Definition: ZpbHellomalifImpl.hpp:187
generated::zpb::hellomalif::StdCmds_GetState_In
Definition: hellomalif.pb.h:851
hellomalif::zpb::LogInfoImpl::getLogger
std::string getLogger() const override
Definition: ZpbHellomalifImpl.hpp:152
hellomalif::zpb::LogInfoImpl::copy
void copy(const ::hellomalif::LogInfo &from) override
Definition: ZpbHellomalifImpl.hpp:209
hellomalif::zpb::LogInfoImpl::keyHash
std::size_t keyHash() const
Definition: ZpbHellomalifImpl.hpp:177
hellomalif::zpb::StdCmdsSyncImpl::Reset
std::string Reset() override
Definition: ZpbHellomalifImpl.hpp:680
hellomalif::zpb::LogInfoImpl::clone
std::unique_ptr<::hellomalif::LogInfo > clone() const override
Definition: ZpbHellomalifImpl.hpp:160
std
Definition: errors.hpp:58
hellomalif::zpb::StdCmdsSyncImpl::Disable
std::string Disable() override
Definition: ZpbHellomalifImpl.hpp:700
generated::zpb::hellomalif::StdCmds_Call::set_allocated_getstatus
void set_allocated_getstatus(::generated::zpb::hellomalif::StdCmds_GetStatus_In *getstatus)
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl(const std::string &desc)
Definition: ZpbHellomalifImpl.hpp:61
hellomalif::zpb::LogInfoImpl::fromByteArray
bool fromByteArray(const void *data, std::size_t size) override
Definition: ZpbHellomalifImpl.hpp:204
generated::zpb::hellomalif::StdCmds_Stop_In
Definition: hellomalif.pb.h:1163
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::Stop
::elt::mal::future< std::string > Stop() override
Definition: ZpbHellomalifImpl.hpp:531
hellomalif::zpb::ExceptionErrImpl::ExceptionErrImpl
ExceptionErrImpl(::generated::zpb::hellomalif::ExceptionErr *inner)
Definition: ZpbHellomalifImpl.hpp:46
hellomalif::StdCmdsAsync
Definition: Hellomalif.hpp:128
generated::zpb::hellomalif::StdCmds_SetLogLevel_In
Definition: hellomalif.pb.h:1371
hellomalif::zpb::LogInfoImpl::ZpbType
::generated::zpb::hellomalif::LogInfo ZpbType
Definition: ZpbHellomalifImpl.hpp:115
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::GetState
::elt::mal::future< std::string > GetState() override
Definition: ZpbHellomalifImpl.hpp:420
generated::zpb::hellomalif::StdCmds_Call::set_allocated_getstate
void set_allocated_getstate(::generated::zpb::hellomalif::StdCmds_GetState_In *getstate)
hellomalif::zpb::LogInfoImpl::toByteArray
bool toByteArray(std::string &output) const override
Definition: ZpbHellomalifImpl.hpp:196
generated::zpb::hellomalif::StdCmds_Disable_In
Definition: hellomalif.pb.h:747
hellomalif::zpb::AsyncStdCmdsImpl
Definition: ZpbHellomalifImpl.hpp:790
generated::zpb::hellomalif::StdCmds_Reset_In
Definition: hellomalif.pb.h:539
hellomalif::zpb::LogInfoImpl::cloneKey
std::unique_ptr<::hellomalif::LogInfo > cloneKey() const override
Definition: ZpbHellomalifImpl.hpp:182
hellomalif
Definition: Hellomalif.hpp:25
hellomalif::zpb::ExceptionErrImpl::getDesc
std::string getDesc() const override
Definition: ZpbHellomalifImpl.hpp:77
generated::zpb::hellomalif::StdCmds_Call::set_allocated_reset
void set_allocated_reset(::generated::zpb::hellomalif::StdCmds_Reset_In *reset)
hellomalif::zpb::StdCmdsSyncImpl::GetVersion
std::string GetVersion() override
Definition: ZpbHellomalifImpl.hpp:730
hellomalif::zpb::LogInfoImpl::keyEquals
bool keyEquals(const ::hellomalif::LogInfo &other) const override
Definition: ZpbHellomalifImpl.hpp:173
hellomalif::zpb::LogInfoImpl::setLogger
void setLogger(const std::string &logger) override
Definition: ZpbHellomalifImpl.hpp:156
hellomalif::zpb::StdCmdsAsyncImpl<::hellomalif::StdCmdsAsync >::Enable
::elt::mal::future< std::string > Enable() override
Definition: ZpbHellomalifImpl.hpp:346
hellomalif::zpb::StdCmdsSyncImpl::Exit
std::string Exit() override
Definition: ZpbHellomalifImpl.hpp:750