YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
INavigation2DMsgs.cpp
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-License-Identifier: BSD-3-Clause
4 */
5
6// Autogenerated by Thrift Compiler (0.14.1-yarped)
7//
8// This is an automatically generated file.
9// It could get re-generated if the ALLOW_IDL_GENERATION flag is on.
10
11#include <INavigation2DMsgs.h>
12
14
15#include <algorithm>
16
17// stop_navigation_RPC helper class declaration
20{
21public:
23 bool write(yarp::os::ConnectionWriter& connection) const override;
24 bool read(yarp::os::ConnectionReader& connection) override;
25
26 class Command :
28 {
29 public:
30 Command() = default;
31 ~Command() override = default;
32
33 bool write(yarp::os::ConnectionWriter& connection) const override;
34 bool read(yarp::os::ConnectionReader& connection) override;
35
36 bool write(const yarp::os::idl::WireWriter& writer) const override;
37 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
38 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
39
40 bool read(yarp::os::idl::WireReader& reader) override;
43 };
44
45 class Reply :
47 {
48 public:
49 Reply() = default;
50 ~Reply() override = default;
51
52 bool write(yarp::os::ConnectionWriter& connection) const override;
53 bool read(yarp::os::ConnectionReader& connection) override;
54
55 bool write(const yarp::os::idl::WireWriter& writer) const override;
56 bool read(yarp::os::idl::WireReader& reader) override;
57
58 bool return_helper{false};
59 };
60
61 using funcptr_t = bool (*)();
62 void call(INavigation2DMsgs* ptr);
63
66
67 static constexpr const char* s_tag{"stop_navigation_RPC"};
68 static constexpr size_t s_tag_len{3};
69 static constexpr size_t s_cmd_len{3};
70 static constexpr size_t s_reply_len{1};
71 static constexpr const char* s_prototype{"bool INavigation2DMsgs::stop_navigation_RPC()"};
72 static constexpr const char* s_help{""};
73};
74
75// resume_navigation_RPC helper class declaration
78{
79public:
81 bool write(yarp::os::ConnectionWriter& connection) const override;
82 bool read(yarp::os::ConnectionReader& connection) override;
83
84 class Command :
86 {
87 public:
88 Command() = default;
89 ~Command() override = default;
90
91 bool write(yarp::os::ConnectionWriter& connection) const override;
92 bool read(yarp::os::ConnectionReader& connection) override;
93
94 bool write(const yarp::os::idl::WireWriter& writer) const override;
95 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
96 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
97
98 bool read(yarp::os::idl::WireReader& reader) override;
101 };
102
103 class Reply :
105 {
106 public:
107 Reply() = default;
108 ~Reply() override = default;
109
110 bool write(yarp::os::ConnectionWriter& connection) const override;
111 bool read(yarp::os::ConnectionReader& connection) override;
112
113 bool write(const yarp::os::idl::WireWriter& writer) const override;
114 bool read(yarp::os::idl::WireReader& reader) override;
115
116 bool return_helper{false};
117 };
118
119 using funcptr_t = bool (*)();
120 void call(INavigation2DMsgs* ptr);
121
124
125 static constexpr const char* s_tag{"resume_navigation_RPC"};
126 static constexpr size_t s_tag_len{3};
127 static constexpr size_t s_cmd_len{3};
128 static constexpr size_t s_reply_len{1};
129 static constexpr const char* s_prototype{"bool INavigation2DMsgs::resume_navigation_RPC()"};
130 static constexpr const char* s_help{""};
131};
132
133// suspend_navigation_RPC helper class declaration
135 public yarp::os::Portable
136{
137public:
139 explicit INavigation2DMsgs_suspend_navigation_RPC_helper(const double time_s);
140 bool write(yarp::os::ConnectionWriter& connection) const override;
141 bool read(yarp::os::ConnectionReader& connection) override;
142
143 class Command :
145 {
146 public:
147 Command() = default;
148 explicit Command(const double time_s);
149
150 ~Command() override = default;
151
152 bool write(yarp::os::ConnectionWriter& connection) const override;
153 bool read(yarp::os::ConnectionReader& connection) override;
154
155 bool write(const yarp::os::idl::WireWriter& writer) const override;
156 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
157 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
158
159 bool read(yarp::os::idl::WireReader& reader) override;
162
163 double time_s{0.0};
164 };
165
166 class Reply :
168 {
169 public:
170 Reply() = default;
171 ~Reply() override = default;
172
173 bool write(yarp::os::ConnectionWriter& connection) const override;
174 bool read(yarp::os::ConnectionReader& connection) override;
175
176 bool write(const yarp::os::idl::WireWriter& writer) const override;
177 bool read(yarp::os::idl::WireReader& reader) override;
178
179 bool return_helper{false};
180 };
181
182 using funcptr_t = bool (*)(const double);
183 void call(INavigation2DMsgs* ptr);
184
187
188 static constexpr const char* s_tag{"suspend_navigation_RPC"};
189 static constexpr size_t s_tag_len{3};
190 static constexpr size_t s_cmd_len{4};
191 static constexpr size_t s_reply_len{1};
192 static constexpr const char* s_prototype{"bool INavigation2DMsgs::suspend_navigation_RPC(const double time_s)"};
193 static constexpr const char* s_help{""};
194};
195
196// recompute_current_navigation_path_RPC helper class declaration
198 public yarp::os::Portable
199{
200public:
202 bool write(yarp::os::ConnectionWriter& connection) const override;
203 bool read(yarp::os::ConnectionReader& connection) override;
204
205 class Command :
207 {
208 public:
209 Command() = default;
210 ~Command() override = default;
211
212 bool write(yarp::os::ConnectionWriter& connection) const override;
213 bool read(yarp::os::ConnectionReader& connection) override;
214
215 bool write(const yarp::os::idl::WireWriter& writer) const override;
216 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
217 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
218
219 bool read(yarp::os::idl::WireReader& reader) override;
222 };
223
224 class Reply :
226 {
227 public:
228 Reply() = default;
229 ~Reply() override = default;
230
231 bool write(yarp::os::ConnectionWriter& connection) const override;
232 bool read(yarp::os::ConnectionReader& connection) override;
233
234 bool write(const yarp::os::idl::WireWriter& writer) const override;
235 bool read(yarp::os::idl::WireReader& reader) override;
236
237 bool return_helper{false};
238 };
239
240 using funcptr_t = bool (*)();
241 void call(INavigation2DMsgs* ptr);
242
245
246 static constexpr const char* s_tag{"recompute_current_navigation_path_RPC"};
247 static constexpr size_t s_tag_len{5};
248 static constexpr size_t s_cmd_len{5};
249 static constexpr size_t s_reply_len{1};
250 static constexpr const char* s_prototype{"bool INavigation2DMsgs::recompute_current_navigation_path_RPC()"};
251 static constexpr const char* s_help{""};
252};
253
254// get_navigation_status_RPC helper class declaration
256 public yarp::os::Portable
257{
258public:
260 bool write(yarp::os::ConnectionWriter& connection) const override;
261 bool read(yarp::os::ConnectionReader& connection) override;
262
263 class Command :
265 {
266 public:
267 Command() = default;
268 ~Command() override = default;
269
270 bool write(yarp::os::ConnectionWriter& connection) const override;
271 bool read(yarp::os::ConnectionReader& connection) override;
272
273 bool write(const yarp::os::idl::WireWriter& writer) const override;
274 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
275 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
276
277 bool read(yarp::os::idl::WireReader& reader) override;
280 };
281
282 class Reply :
284 {
285 public:
286 Reply() = default;
287 ~Reply() override = default;
288
289 bool write(yarp::os::ConnectionWriter& connection) const override;
290 bool read(yarp::os::ConnectionReader& connection) override;
291
292 bool write(const yarp::os::idl::WireWriter& writer) const override;
293 bool read(yarp::os::idl::WireReader& reader) override;
294
296 };
297
299 void call(INavigation2DMsgs* ptr);
300
303
304 static constexpr const char* s_tag{"get_navigation_status_RPC"};
305 static constexpr size_t s_tag_len{4};
306 static constexpr size_t s_cmd_len{4};
307 static constexpr size_t s_reply_len{2};
308 static constexpr const char* s_prototype{"return_get_navigation_status INavigation2DMsgs::get_navigation_status_RPC()"};
309 static constexpr const char* s_help{""};
310};
311
312// get_current_nav_waypoint_RPC helper class declaration
314 public yarp::os::Portable
315{
316public:
318 bool write(yarp::os::ConnectionWriter& connection) const override;
319 bool read(yarp::os::ConnectionReader& connection) override;
320
321 class Command :
323 {
324 public:
325 Command() = default;
326 ~Command() override = default;
327
328 bool write(yarp::os::ConnectionWriter& connection) const override;
329 bool read(yarp::os::ConnectionReader& connection) override;
330
331 bool write(const yarp::os::idl::WireWriter& writer) const override;
332 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
333 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
334
335 bool read(yarp::os::idl::WireReader& reader) override;
338 };
339
340 class Reply :
342 {
343 public:
344 Reply() = default;
345 ~Reply() override = default;
346
347 bool write(yarp::os::ConnectionWriter& connection) const override;
348 bool read(yarp::os::ConnectionReader& connection) override;
349
350 bool write(const yarp::os::idl::WireWriter& writer) const override;
351 bool read(yarp::os::idl::WireReader& reader) override;
352
354 };
355
357 void call(INavigation2DMsgs* ptr);
358
361
362 static constexpr const char* s_tag{"get_current_nav_waypoint_RPC"};
363 static constexpr size_t s_tag_len{5};
364 static constexpr size_t s_cmd_len{5};
365 static constexpr size_t s_reply_len{2};
366 static constexpr const char* s_prototype{"return_get_current_nav_waypoint INavigation2DMsgs::get_current_nav_waypoint_RPC()"};
367 static constexpr const char* s_help{""};
368};
369
370// get_all_navigation_waypoints_RPC helper class declaration
372 public yarp::os::Portable
373{
374public:
377 bool write(yarp::os::ConnectionWriter& connection) const override;
378 bool read(yarp::os::ConnectionReader& connection) override;
379
380 class Command :
382 {
383 public:
384 Command() = default;
386
387 ~Command() override = default;
388
389 bool write(yarp::os::ConnectionWriter& connection) const override;
390 bool read(yarp::os::ConnectionReader& connection) override;
391
392 bool write(const yarp::os::idl::WireWriter& writer) const override;
393 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
394 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
395
396 bool read(yarp::os::idl::WireReader& reader) override;
399
401 };
402
403 class Reply :
405 {
406 public:
407 Reply() = default;
408 ~Reply() override = default;
409
410 bool write(yarp::os::ConnectionWriter& connection) const override;
411 bool read(yarp::os::ConnectionReader& connection) override;
412
413 bool write(const yarp::os::idl::WireWriter& writer) const override;
414 bool read(yarp::os::idl::WireReader& reader) override;
415
417 };
418
420 void call(INavigation2DMsgs* ptr);
421
424
425 static constexpr const char* s_tag{"get_all_navigation_waypoints_RPC"};
426 static constexpr size_t s_tag_len{5};
427 static constexpr size_t s_cmd_len{6};
428 static constexpr size_t s_reply_len{2};
429 static constexpr const char* s_prototype{"return_get_all_nav_waypoints INavigation2DMsgs::get_all_navigation_waypoints_RPC(const yarp::dev::Nav2D::TrajectoryTypeEnum trajectory_type)"};
430 static constexpr const char* s_help{""};
431};
432
433// get_current_navigation_map_RPC helper class declaration
435 public yarp::os::Portable
436{
437public:
440 bool write(yarp::os::ConnectionWriter& connection) const override;
441 bool read(yarp::os::ConnectionReader& connection) override;
442
443 class Command :
445 {
446 public:
447 Command() = default;
449
450 ~Command() override = default;
451
452 bool write(yarp::os::ConnectionWriter& connection) const override;
453 bool read(yarp::os::ConnectionReader& connection) override;
454
455 bool write(const yarp::os::idl::WireWriter& writer) const override;
456 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
457 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
458
459 bool read(yarp::os::idl::WireReader& reader) override;
462
464 };
465
466 class Reply :
468 {
469 public:
470 Reply() = default;
471 ~Reply() override = default;
472
473 bool write(yarp::os::ConnectionWriter& connection) const override;
474 bool read(yarp::os::ConnectionReader& connection) override;
475
476 bool write(const yarp::os::idl::WireWriter& writer) const override;
477 bool read(yarp::os::idl::WireReader& reader) override;
478
480 };
481
483 void call(INavigation2DMsgs* ptr);
484
487
488 static constexpr const char* s_tag{"get_current_navigation_map_RPC"};
489 static constexpr size_t s_tag_len{5};
490 static constexpr size_t s_cmd_len{6};
491 static constexpr size_t s_reply_len{2};
492 static constexpr const char* s_prototype{"return_get_current_nav_map INavigation2DMsgs::get_current_navigation_map_RPC(const yarp::dev::Nav2D::NavigationMapTypeEnum map_type)"};
493 static constexpr const char* s_help{""};
494};
495
496// goto_target_by_absolute_location_RPC helper class declaration
498 public yarp::os::Portable
499{
500public:
503 bool write(yarp::os::ConnectionWriter& connection) const override;
504 bool read(yarp::os::ConnectionReader& connection) override;
505
506 class Command :
508 {
509 public:
510 Command() = default;
512
513 ~Command() override = default;
514
515 bool write(yarp::os::ConnectionWriter& connection) const override;
516 bool read(yarp::os::ConnectionReader& connection) override;
517
518 bool write(const yarp::os::idl::WireWriter& writer) const override;
519 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
520 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
521
522 bool read(yarp::os::idl::WireReader& reader) override;
525
527 };
528
529 class Reply :
531 {
532 public:
533 Reply() = default;
534 ~Reply() override = default;
535
536 bool write(yarp::os::ConnectionWriter& connection) const override;
537 bool read(yarp::os::ConnectionReader& connection) override;
538
539 bool write(const yarp::os::idl::WireWriter& writer) const override;
540 bool read(yarp::os::idl::WireReader& reader) override;
541
542 bool return_helper{false};
543 };
544
546 void call(INavigation2DMsgs* ptr);
547
550
551 static constexpr const char* s_tag{"goto_target_by_absolute_location_RPC"};
552 static constexpr size_t s_tag_len{6};
553 static constexpr size_t s_cmd_len{7};
554 static constexpr size_t s_reply_len{1};
555 static constexpr const char* s_prototype{"bool INavigation2DMsgs::goto_target_by_absolute_location_RPC(const yarp::dev::Nav2D::Map2DLocation& loc)"};
556 static constexpr const char* s_help{""};
557};
558
559// goto_target_by_relative_location1_RPC helper class declaration
561 public yarp::os::Portable
562{
563public:
566 bool write(yarp::os::ConnectionWriter& connection) const override;
567 bool read(yarp::os::ConnectionReader& connection) override;
568
569 class Command :
571 {
572 public:
573 Command() = default;
574 Command(const double x, const double y);
575
576 ~Command() override = default;
577
578 bool write(yarp::os::ConnectionWriter& connection) const override;
579 bool read(yarp::os::ConnectionReader& connection) override;
580
581 bool write(const yarp::os::idl::WireWriter& writer) const override;
582 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
583 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
584
585 bool read(yarp::os::idl::WireReader& reader) override;
588
589 double x{0.0};
590 double y{0.0};
591 };
592
593 class Reply :
595 {
596 public:
597 Reply() = default;
598 ~Reply() override = default;
599
600 bool write(yarp::os::ConnectionWriter& connection) const override;
601 bool read(yarp::os::ConnectionReader& connection) override;
602
603 bool write(const yarp::os::idl::WireWriter& writer) const override;
604 bool read(yarp::os::idl::WireReader& reader) override;
605
606 bool return_helper{false};
607 };
608
609 using funcptr_t = bool (*)(const double, const double);
610 void call(INavigation2DMsgs* ptr);
611
614
615 static constexpr const char* s_tag{"goto_target_by_relative_location1_RPC"};
616 static constexpr size_t s_tag_len{6};
617 static constexpr size_t s_cmd_len{8};
618 static constexpr size_t s_reply_len{1};
619 static constexpr const char* s_prototype{"bool INavigation2DMsgs::goto_target_by_relative_location1_RPC(const double x, const double y)"};
620 static constexpr const char* s_help{""};
621};
622
623// goto_target_by_relative_location2_RPC helper class declaration
625 public yarp::os::Portable
626{
627public:
629 INavigation2DMsgs_goto_target_by_relative_location2_RPC_helper(const double x, const double y, const double theta);
630 bool write(yarp::os::ConnectionWriter& connection) const override;
631 bool read(yarp::os::ConnectionReader& connection) override;
632
633 class Command :
635 {
636 public:
637 Command() = default;
638 Command(const double x, const double y, const double theta);
639
640 ~Command() override = default;
641
642 bool write(yarp::os::ConnectionWriter& connection) const override;
643 bool read(yarp::os::ConnectionReader& connection) override;
644
645 bool write(const yarp::os::idl::WireWriter& writer) const override;
646 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
647 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
648
649 bool read(yarp::os::idl::WireReader& reader) override;
652
653 double x{0.0};
654 double y{0.0};
655 double theta{0.0};
656 };
657
658 class Reply :
660 {
661 public:
662 Reply() = default;
663 ~Reply() override = default;
664
665 bool write(yarp::os::ConnectionWriter& connection) const override;
666 bool read(yarp::os::ConnectionReader& connection) override;
667
668 bool write(const yarp::os::idl::WireWriter& writer) const override;
669 bool read(yarp::os::idl::WireReader& reader) override;
670
671 bool return_helper{false};
672 };
673
674 using funcptr_t = bool (*)(const double, const double, const double);
675 void call(INavigation2DMsgs* ptr);
676
679
680 static constexpr const char* s_tag{"goto_target_by_relative_location2_RPC"};
681 static constexpr size_t s_tag_len{6};
682 static constexpr size_t s_cmd_len{9};
683 static constexpr size_t s_reply_len{1};
684 static constexpr const char* s_prototype{"bool INavigation2DMsgs::goto_target_by_relative_location2_RPC(const double x, const double y, const double theta)"};
685 static constexpr const char* s_help{""};
686};
687
688// get_absolute_location_of_current_target_RPC helper class declaration
690 public yarp::os::Portable
691{
692public:
694 bool write(yarp::os::ConnectionWriter& connection) const override;
695 bool read(yarp::os::ConnectionReader& connection) override;
696
697 class Command :
699 {
700 public:
701 Command() = default;
702 ~Command() override = default;
703
704 bool write(yarp::os::ConnectionWriter& connection) const override;
705 bool read(yarp::os::ConnectionReader& connection) override;
706
707 bool write(const yarp::os::idl::WireWriter& writer) const override;
708 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
709 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
710
711 bool read(yarp::os::idl::WireReader& reader) override;
714 };
715
716 class Reply :
718 {
719 public:
720 Reply() = default;
721 ~Reply() override = default;
722
723 bool write(yarp::os::ConnectionWriter& connection) const override;
724 bool read(yarp::os::ConnectionReader& connection) override;
725
726 bool write(const yarp::os::idl::WireWriter& writer) const override;
727 bool read(yarp::os::idl::WireReader& reader) override;
728
730 };
731
733 void call(INavigation2DMsgs* ptr);
734
737
738 static constexpr const char* s_tag{"get_absolute_location_of_current_target_RPC"};
739 static constexpr size_t s_tag_len{7};
740 static constexpr size_t s_cmd_len{7};
741 static constexpr size_t s_reply_len{2};
742 static constexpr const char* s_prototype{"return_get_abs_loc_of_curr_target INavigation2DMsgs::get_absolute_location_of_current_target_RPC()"};
743 static constexpr const char* s_help{""};
744};
745
746// get_relative_location_of_current_target_RPC helper class declaration
748 public yarp::os::Portable
749{
750public:
752 bool write(yarp::os::ConnectionWriter& connection) const override;
753 bool read(yarp::os::ConnectionReader& connection) override;
754
755 class Command :
757 {
758 public:
759 Command() = default;
760 ~Command() override = default;
761
762 bool write(yarp::os::ConnectionWriter& connection) const override;
763 bool read(yarp::os::ConnectionReader& connection) override;
764
765 bool write(const yarp::os::idl::WireWriter& writer) const override;
766 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
767 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
768
769 bool read(yarp::os::idl::WireReader& reader) override;
772 };
773
774 class Reply :
776 {
777 public:
778 Reply() = default;
779 ~Reply() override = default;
780
781 bool write(yarp::os::ConnectionWriter& connection) const override;
782 bool read(yarp::os::ConnectionReader& connection) override;
783
784 bool write(const yarp::os::idl::WireWriter& writer) const override;
785 bool read(yarp::os::idl::WireReader& reader) override;
786
788 };
789
791 void call(INavigation2DMsgs* ptr);
792
795
796 static constexpr const char* s_tag{"get_relative_location_of_current_target_RPC"};
797 static constexpr size_t s_tag_len{7};
798 static constexpr size_t s_cmd_len{7};
799 static constexpr size_t s_reply_len{4};
800 static constexpr const char* s_prototype{"return_get_rel_loc_of_curr_target INavigation2DMsgs::get_relative_location_of_current_target_RPC()"};
801 static constexpr const char* s_help{""};
802};
803
804// goto_target_by_absolute_location_and_set_name_RPC helper class declaration
806 public yarp::os::Portable
807{
808public:
811 bool write(yarp::os::ConnectionWriter& connection) const override;
812 bool read(yarp::os::ConnectionReader& connection) override;
813
814 class Command :
816 {
817 public:
818 Command() = default;
819 Command(const yarp::dev::Nav2D::Map2DLocation& loc, const std::string& name);
820
821 ~Command() override = default;
822
823 bool write(yarp::os::ConnectionWriter& connection) const override;
824 bool read(yarp::os::ConnectionReader& connection) override;
825
826 bool write(const yarp::os::idl::WireWriter& writer) const override;
827 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
828 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
829
830 bool read(yarp::os::idl::WireReader& reader) override;
833
835 std::string name{};
836 };
837
838 class Reply :
840 {
841 public:
842 Reply() = default;
843 ~Reply() override = default;
844
845 bool write(yarp::os::ConnectionWriter& connection) const override;
846 bool read(yarp::os::ConnectionReader& connection) override;
847
848 bool write(const yarp::os::idl::WireWriter& writer) const override;
849 bool read(yarp::os::idl::WireReader& reader) override;
850
851 bool return_helper{false};
852 };
853
854 using funcptr_t = bool (*)(const yarp::dev::Nav2D::Map2DLocation&, const std::string&);
855 void call(INavigation2DMsgs* ptr);
856
859
860 static constexpr const char* s_tag{"goto_target_by_absolute_location_and_set_name_RPC"};
861 static constexpr size_t s_tag_len{9};
862 static constexpr size_t s_cmd_len{11};
863 static constexpr size_t s_reply_len{1};
864 static constexpr const char* s_prototype{"bool INavigation2DMsgs::goto_target_by_absolute_location_and_set_name_RPC(const yarp::dev::Nav2D::Map2DLocation& loc, const std::string& name)"};
865 static constexpr const char* s_help{""};
866};
867
868// apply_velocity_command_RPC helper class declaration
870 public yarp::os::Portable
871{
872public:
874 INavigation2DMsgs_apply_velocity_command_RPC_helper(const double x_vel, const double y_vel, const double theta_vel, const double timeout);
875 bool write(yarp::os::ConnectionWriter& connection) const override;
876 bool read(yarp::os::ConnectionReader& connection) override;
877
878 class Command :
880 {
881 public:
882 Command() = default;
883 Command(const double x_vel, const double y_vel, const double theta_vel, const double timeout);
884
885 ~Command() override = default;
886
887 bool write(yarp::os::ConnectionWriter& connection) const override;
888 bool read(yarp::os::ConnectionReader& connection) override;
889
890 bool write(const yarp::os::idl::WireWriter& writer) const override;
891 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
892 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
893
894 bool read(yarp::os::idl::WireReader& reader) override;
897
898 double x_vel{0.0};
899 double y_vel{0.0};
900 double theta_vel{0.0};
901 double timeout{0.0};
902 };
903
904 class Reply :
906 {
907 public:
908 Reply() = default;
909 ~Reply() override = default;
910
911 bool write(yarp::os::ConnectionWriter& connection) const override;
912 bool read(yarp::os::ConnectionReader& connection) override;
913
914 bool write(const yarp::os::idl::WireWriter& writer) const override;
915 bool read(yarp::os::idl::WireReader& reader) override;
916
917 bool return_helper{false};
918 };
919
920 using funcptr_t = bool (*)(const double, const double, const double, const double);
921 void call(INavigation2DMsgs* ptr);
922
925
926 static constexpr const char* s_tag{"apply_velocity_command_RPC"};
927 static constexpr size_t s_tag_len{4};
928 static constexpr size_t s_cmd_len{8};
929 static constexpr size_t s_reply_len{1};
930 static constexpr const char* s_prototype{"bool INavigation2DMsgs::apply_velocity_command_RPC(const double x_vel, const double y_vel, const double theta_vel, const double timeout)"};
931 static constexpr const char* s_help{""};
932};
933
934// get_last_velocity_command_RPC helper class declaration
936 public yarp::os::Portable
937{
938public:
940 bool write(yarp::os::ConnectionWriter& connection) const override;
941 bool read(yarp::os::ConnectionReader& connection) override;
942
943 class Command :
945 {
946 public:
947 Command() = default;
948 ~Command() override = default;
949
950 bool write(yarp::os::ConnectionWriter& connection) const override;
951 bool read(yarp::os::ConnectionReader& connection) override;
952
953 bool write(const yarp::os::idl::WireWriter& writer) const override;
954 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
955 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
956
957 bool read(yarp::os::idl::WireReader& reader) override;
960 };
961
962 class Reply :
964 {
965 public:
966 Reply() = default;
967 ~Reply() override = default;
968
969 bool write(yarp::os::ConnectionWriter& connection) const override;
970 bool read(yarp::os::ConnectionReader& connection) override;
971
972 bool write(const yarp::os::idl::WireWriter& writer) const override;
973 bool read(yarp::os::idl::WireReader& reader) override;
974
976 };
977
979 void call(INavigation2DMsgs* ptr);
980
983
984 static constexpr const char* s_tag{"get_last_velocity_command_RPC"};
985 static constexpr size_t s_tag_len{5};
986 static constexpr size_t s_cmd_len{5};
987 static constexpr size_t s_reply_len{4};
988 static constexpr const char* s_prototype{"return_get_last_velocity_command INavigation2DMsgs::get_last_velocity_command_RPC()"};
989 static constexpr const char* s_help{""};
990};
991
992// get_name_of_current_target_RPC helper class declaration
994 public yarp::os::Portable
995{
996public:
998 bool write(yarp::os::ConnectionWriter& connection) const override;
999 bool read(yarp::os::ConnectionReader& connection) override;
1000
1001 class Command :
1003 {
1004 public:
1005 Command() = default;
1006 ~Command() override = default;
1007
1008 bool write(yarp::os::ConnectionWriter& connection) const override;
1009 bool read(yarp::os::ConnectionReader& connection) override;
1010
1011 bool write(const yarp::os::idl::WireWriter& writer) const override;
1012 bool writeTag(const yarp::os::idl::WireWriter& writer) const;
1013 bool writeArgs(const yarp::os::idl::WireWriter& writer) const;
1014
1015 bool read(yarp::os::idl::WireReader& reader) override;
1016 bool readTag(yarp::os::idl::WireReader& reader);
1017 bool readArgs(yarp::os::idl::WireReader& reader);
1018 };
1019
1020 class Reply :
1022 {
1023 public:
1024 Reply() = default;
1025 ~Reply() override = default;
1026
1027 bool write(yarp::os::ConnectionWriter& connection) const override;
1028 bool read(yarp::os::ConnectionReader& connection) override;
1029
1030 bool write(const yarp::os::idl::WireWriter& writer) const override;
1031 bool read(yarp::os::idl::WireReader& reader) override;
1032
1034 };
1035
1037 void call(INavigation2DMsgs* ptr);
1038
1041
1042 static constexpr const char* s_tag{"get_name_of_current_target_RPC"};
1043 static constexpr size_t s_tag_len{6};
1044 static constexpr size_t s_cmd_len{6};
1045 static constexpr size_t s_reply_len{2};
1046 static constexpr const char* s_prototype{"return_get_name_of_current_target INavigation2DMsgs::get_name_of_current_target_RPC()"};
1047 static constexpr const char* s_help{""};
1048};
1049
1050// stop_navigation_RPC helper class implementation
1052{
1053 return cmd.write(connection);
1054}
1055
1060
1062{
1063 yarp::os::idl::WireWriter writer(connection);
1064 if (!writer.writeListHeader(s_cmd_len)) {
1065 return false;
1066 }
1067 return write(writer);
1068}
1069
1071{
1072 yarp::os::idl::WireReader reader(connection);
1073 if (!reader.readListHeader()) {
1074 reader.fail();
1075 return false;
1076 }
1077 return read(reader);
1078}
1079
1081{
1082 if (!writeTag(writer)) {
1083 return false;
1084 }
1085 if (!writeArgs(writer)) {
1086 return false;
1087 }
1088 return true;
1089}
1090
1092{
1093 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1094 return false;
1095 }
1096 return true;
1097}
1098
1100{
1101 return true;
1102}
1103
1105{
1106 if (!readTag(reader)) {
1107 return false;
1108 }
1109 if (!readArgs(reader)) {
1110 return false;
1111 }
1112 return true;
1113}
1114
1116{
1117 std::string tag = reader.readTag(s_tag_len);
1118 if (reader.isError()) {
1119 return false;
1120 }
1121 if (tag != s_tag) {
1122 reader.fail();
1123 return false;
1124 }
1125 return true;
1126}
1127
1129{
1130 if (!reader.noMore()) {
1131 reader.fail();
1132 return false;
1133 }
1134 return true;
1135}
1136
1138{
1139 yarp::os::idl::WireWriter writer(connection);
1140 return write(writer);
1141}
1142
1144{
1145 yarp::os::idl::WireReader reader(connection);
1146 return read(reader);
1147}
1148
1150{
1151 if (!writer.isNull()) {
1152 if (!writer.writeListHeader(s_reply_len)) {
1153 return false;
1154 }
1155 if (!writer.writeBool(return_helper)) {
1156 return false;
1157 }
1158 }
1159 return true;
1160}
1161
1163{
1164 if (!reader.readListReturn()) {
1165 return false;
1166 }
1167 if (reader.noMore()) {
1168 reader.fail();
1169 return false;
1170 }
1171 if (!reader.readBool(return_helper)) {
1172 reader.fail();
1173 return false;
1174 }
1175 return true;
1176}
1177
1182
1183// resume_navigation_RPC helper class implementation
1185{
1186 return cmd.write(connection);
1187}
1188
1193
1195{
1196 yarp::os::idl::WireWriter writer(connection);
1197 if (!writer.writeListHeader(s_cmd_len)) {
1198 return false;
1199 }
1200 return write(writer);
1201}
1202
1204{
1205 yarp::os::idl::WireReader reader(connection);
1206 if (!reader.readListHeader()) {
1207 reader.fail();
1208 return false;
1209 }
1210 return read(reader);
1211}
1212
1214{
1215 if (!writeTag(writer)) {
1216 return false;
1217 }
1218 if (!writeArgs(writer)) {
1219 return false;
1220 }
1221 return true;
1222}
1223
1225{
1226 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1227 return false;
1228 }
1229 return true;
1230}
1231
1233{
1234 return true;
1235}
1236
1238{
1239 if (!readTag(reader)) {
1240 return false;
1241 }
1242 if (!readArgs(reader)) {
1243 return false;
1244 }
1245 return true;
1246}
1247
1249{
1250 std::string tag = reader.readTag(s_tag_len);
1251 if (reader.isError()) {
1252 return false;
1253 }
1254 if (tag != s_tag) {
1255 reader.fail();
1256 return false;
1257 }
1258 return true;
1259}
1260
1262{
1263 if (!reader.noMore()) {
1264 reader.fail();
1265 return false;
1266 }
1267 return true;
1268}
1269
1271{
1272 yarp::os::idl::WireWriter writer(connection);
1273 return write(writer);
1274}
1275
1277{
1278 yarp::os::idl::WireReader reader(connection);
1279 return read(reader);
1280}
1281
1283{
1284 if (!writer.isNull()) {
1285 if (!writer.writeListHeader(s_reply_len)) {
1286 return false;
1287 }
1288 if (!writer.writeBool(return_helper)) {
1289 return false;
1290 }
1291 }
1292 return true;
1293}
1294
1296{
1297 if (!reader.readListReturn()) {
1298 return false;
1299 }
1300 if (reader.noMore()) {
1301 reader.fail();
1302 return false;
1303 }
1304 if (!reader.readBool(return_helper)) {
1305 reader.fail();
1306 return false;
1307 }
1308 return true;
1309}
1310
1315
1316// suspend_navigation_RPC helper class implementation
1321
1323{
1324 return cmd.write(connection);
1325}
1326
1331
1333 time_s{time_s}
1334{
1335}
1336
1338{
1339 yarp::os::idl::WireWriter writer(connection);
1340 if (!writer.writeListHeader(s_cmd_len)) {
1341 return false;
1342 }
1343 return write(writer);
1344}
1345
1347{
1348 yarp::os::idl::WireReader reader(connection);
1349 if (!reader.readListHeader()) {
1350 reader.fail();
1351 return false;
1352 }
1353 return read(reader);
1354}
1355
1357{
1358 if (!writeTag(writer)) {
1359 return false;
1360 }
1361 if (!writeArgs(writer)) {
1362 return false;
1363 }
1364 return true;
1365}
1366
1368{
1369 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1370 return false;
1371 }
1372 return true;
1373}
1374
1376{
1377 if (!writer.writeFloat64(time_s)) {
1378 return false;
1379 }
1380 return true;
1381}
1382
1384{
1385 if (!readTag(reader)) {
1386 return false;
1387 }
1388 if (!readArgs(reader)) {
1389 return false;
1390 }
1391 return true;
1392}
1393
1395{
1396 std::string tag = reader.readTag(s_tag_len);
1397 if (reader.isError()) {
1398 return false;
1399 }
1400 if (tag != s_tag) {
1401 reader.fail();
1402 return false;
1403 }
1404 return true;
1405}
1406
1408{
1409 if (reader.noMore()) {
1410 reader.fail();
1411 return false;
1412 }
1413 if (!reader.readFloat64(time_s)) {
1414 reader.fail();
1415 return false;
1416 }
1417 if (!reader.noMore()) {
1418 reader.fail();
1419 return false;
1420 }
1421 return true;
1422}
1423
1425{
1426 yarp::os::idl::WireWriter writer(connection);
1427 return write(writer);
1428}
1429
1431{
1432 yarp::os::idl::WireReader reader(connection);
1433 return read(reader);
1434}
1435
1437{
1438 if (!writer.isNull()) {
1439 if (!writer.writeListHeader(s_reply_len)) {
1440 return false;
1441 }
1442 if (!writer.writeBool(return_helper)) {
1443 return false;
1444 }
1445 }
1446 return true;
1447}
1448
1450{
1451 if (!reader.readListReturn()) {
1452 return false;
1453 }
1454 if (reader.noMore()) {
1455 reader.fail();
1456 return false;
1457 }
1458 if (!reader.readBool(return_helper)) {
1459 reader.fail();
1460 return false;
1461 }
1462 return true;
1463}
1464
1469
1470// recompute_current_navigation_path_RPC helper class implementation
1475
1480
1482{
1483 yarp::os::idl::WireWriter writer(connection);
1484 if (!writer.writeListHeader(s_cmd_len)) {
1485 return false;
1486 }
1487 return write(writer);
1488}
1489
1491{
1492 yarp::os::idl::WireReader reader(connection);
1493 if (!reader.readListHeader()) {
1494 reader.fail();
1495 return false;
1496 }
1497 return read(reader);
1498}
1499
1501{
1502 if (!writeTag(writer)) {
1503 return false;
1504 }
1505 if (!writeArgs(writer)) {
1506 return false;
1507 }
1508 return true;
1509}
1510
1512{
1513 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1514 return false;
1515 }
1516 return true;
1517}
1518
1520{
1521 return true;
1522}
1523
1525{
1526 if (!readTag(reader)) {
1527 return false;
1528 }
1529 if (!readArgs(reader)) {
1530 return false;
1531 }
1532 return true;
1533}
1534
1536{
1537 std::string tag = reader.readTag(s_tag_len);
1538 if (reader.isError()) {
1539 return false;
1540 }
1541 if (tag != s_tag) {
1542 reader.fail();
1543 return false;
1544 }
1545 return true;
1546}
1547
1549{
1550 if (!reader.noMore()) {
1551 reader.fail();
1552 return false;
1553 }
1554 return true;
1555}
1556
1562
1568
1570{
1571 if (!writer.isNull()) {
1572 if (!writer.writeListHeader(s_reply_len)) {
1573 return false;
1574 }
1575 if (!writer.writeBool(return_helper)) {
1576 return false;
1577 }
1578 }
1579 return true;
1580}
1581
1583{
1584 if (!reader.readListReturn()) {
1585 return false;
1586 }
1587 if (reader.noMore()) {
1588 reader.fail();
1589 return false;
1590 }
1591 if (!reader.readBool(return_helper)) {
1592 reader.fail();
1593 return false;
1594 }
1595 return true;
1596}
1597
1602
1603// get_navigation_status_RPC helper class implementation
1605{
1606 return cmd.write(connection);
1607}
1608
1613
1615{
1616 yarp::os::idl::WireWriter writer(connection);
1617 if (!writer.writeListHeader(s_cmd_len)) {
1618 return false;
1619 }
1620 return write(writer);
1621}
1622
1624{
1625 yarp::os::idl::WireReader reader(connection);
1626 if (!reader.readListHeader()) {
1627 reader.fail();
1628 return false;
1629 }
1630 return read(reader);
1631}
1632
1634{
1635 if (!writeTag(writer)) {
1636 return false;
1637 }
1638 if (!writeArgs(writer)) {
1639 return false;
1640 }
1641 return true;
1642}
1643
1645{
1646 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1647 return false;
1648 }
1649 return true;
1650}
1651
1653{
1654 return true;
1655}
1656
1658{
1659 if (!readTag(reader)) {
1660 return false;
1661 }
1662 if (!readArgs(reader)) {
1663 return false;
1664 }
1665 return true;
1666}
1667
1669{
1670 std::string tag = reader.readTag(s_tag_len);
1671 if (reader.isError()) {
1672 return false;
1673 }
1674 if (tag != s_tag) {
1675 reader.fail();
1676 return false;
1677 }
1678 return true;
1679}
1680
1682{
1683 if (!reader.noMore()) {
1684 reader.fail();
1685 return false;
1686 }
1687 return true;
1688}
1689
1691{
1692 yarp::os::idl::WireWriter writer(connection);
1693 return write(writer);
1694}
1695
1701
1703{
1704 if (!writer.isNull()) {
1705 if (!writer.writeListHeader(s_reply_len)) {
1706 return false;
1707 }
1708 if (!writer.write(return_helper)) {
1709 return false;
1710 }
1711 }
1712 return true;
1713}
1714
1716{
1717 if (!reader.readListReturn()) {
1718 return false;
1719 }
1720 if (reader.noMore()) {
1721 reader.fail();
1722 return false;
1723 }
1724 if (!reader.read(return_helper)) {
1725 reader.fail();
1726 return false;
1727 }
1728 return true;
1729}
1730
1735
1736// get_current_nav_waypoint_RPC helper class implementation
1741
1746
1748{
1749 yarp::os::idl::WireWriter writer(connection);
1750 if (!writer.writeListHeader(s_cmd_len)) {
1751 return false;
1752 }
1753 return write(writer);
1754}
1755
1757{
1758 yarp::os::idl::WireReader reader(connection);
1759 if (!reader.readListHeader()) {
1760 reader.fail();
1761 return false;
1762 }
1763 return read(reader);
1764}
1765
1767{
1768 if (!writeTag(writer)) {
1769 return false;
1770 }
1771 if (!writeArgs(writer)) {
1772 return false;
1773 }
1774 return true;
1775}
1776
1778{
1779 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1780 return false;
1781 }
1782 return true;
1783}
1784
1786{
1787 return true;
1788}
1789
1791{
1792 if (!readTag(reader)) {
1793 return false;
1794 }
1795 if (!readArgs(reader)) {
1796 return false;
1797 }
1798 return true;
1799}
1800
1802{
1803 std::string tag = reader.readTag(s_tag_len);
1804 if (reader.isError()) {
1805 return false;
1806 }
1807 if (tag != s_tag) {
1808 reader.fail();
1809 return false;
1810 }
1811 return true;
1812}
1813
1815{
1816 if (!reader.noMore()) {
1817 reader.fail();
1818 return false;
1819 }
1820 return true;
1821}
1822
1824{
1825 yarp::os::idl::WireWriter writer(connection);
1826 return write(writer);
1827}
1828
1834
1836{
1837 if (!writer.isNull()) {
1838 if (!writer.writeListHeader(s_reply_len)) {
1839 return false;
1840 }
1841 if (!writer.write(return_helper)) {
1842 return false;
1843 }
1844 }
1845 return true;
1846}
1847
1849{
1850 if (!reader.readListReturn()) {
1851 return false;
1852 }
1853 if (reader.noMore()) {
1854 reader.fail();
1855 return false;
1856 }
1857 if (!reader.read(return_helper)) {
1858 reader.fail();
1859 return false;
1860 }
1861 return true;
1862}
1863
1868
1869// get_all_navigation_waypoints_RPC helper class implementation
1874
1879
1884
1889
1891{
1892 yarp::os::idl::WireWriter writer(connection);
1893 if (!writer.writeListHeader(s_cmd_len)) {
1894 return false;
1895 }
1896 return write(writer);
1897}
1898
1900{
1901 yarp::os::idl::WireReader reader(connection);
1902 if (!reader.readListHeader()) {
1903 reader.fail();
1904 return false;
1905 }
1906 return read(reader);
1907}
1908
1910{
1911 if (!writeTag(writer)) {
1912 return false;
1913 }
1914 if (!writeArgs(writer)) {
1915 return false;
1916 }
1917 return true;
1918}
1919
1921{
1922 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
1923 return false;
1924 }
1925 return true;
1926}
1927
1929{
1930 if (!writer.writeVocab32(static_cast<yarp::conf::vocab32_t>(trajectory_type))) {
1931 return false;
1932 }
1933 return true;
1934}
1935
1937{
1938 if (!readTag(reader)) {
1939 return false;
1940 }
1941 if (!readArgs(reader)) {
1942 return false;
1943 }
1944 return true;
1945}
1946
1948{
1949 std::string tag = reader.readTag(s_tag_len);
1950 if (reader.isError()) {
1951 return false;
1952 }
1953 if (tag != s_tag) {
1954 reader.fail();
1955 return false;
1956 }
1957 return true;
1958}
1959
1961{
1962 if (reader.noMore()) {
1963 reader.fail();
1964 return false;
1965 }
1966 yarp::conf::vocab32_t _ecast;
1967 if (!reader.readVocab32(_ecast)) {
1968 reader.fail();
1969 return false;
1970 }
1971 trajectory_type = static_cast<yarp::dev::Nav2D::TrajectoryTypeEnum>(_ecast);
1972 if (!reader.noMore()) {
1973 reader.fail();
1974 return false;
1975 }
1976 return true;
1977}
1978
1984
1990
1992{
1993 if (!writer.isNull()) {
1994 if (!writer.writeListHeader(s_reply_len)) {
1995 return false;
1996 }
1997 if (!writer.write(return_helper)) {
1998 return false;
1999 }
2000 }
2001 return true;
2002}
2003
2005{
2006 if (!reader.readListReturn()) {
2007 return false;
2008 }
2009 if (reader.noMore()) {
2010 reader.fail();
2011 return false;
2012 }
2013 if (!reader.read(return_helper)) {
2014 reader.fail();
2015 return false;
2016 }
2017 return true;
2018}
2019
2024
2025// get_current_navigation_map_RPC helper class implementation
2030
2035
2040
2045
2047{
2048 yarp::os::idl::WireWriter writer(connection);
2049 if (!writer.writeListHeader(s_cmd_len)) {
2050 return false;
2051 }
2052 return write(writer);
2053}
2054
2056{
2057 yarp::os::idl::WireReader reader(connection);
2058 if (!reader.readListHeader()) {
2059 reader.fail();
2060 return false;
2061 }
2062 return read(reader);
2063}
2064
2066{
2067 if (!writeTag(writer)) {
2068 return false;
2069 }
2070 if (!writeArgs(writer)) {
2071 return false;
2072 }
2073 return true;
2074}
2075
2077{
2078 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
2079 return false;
2080 }
2081 return true;
2082}
2083
2085{
2086 if (!writer.writeVocab32(static_cast<yarp::conf::vocab32_t>(map_type))) {
2087 return false;
2088 }
2089 return true;
2090}
2091
2093{
2094 if (!readTag(reader)) {
2095 return false;
2096 }
2097 if (!readArgs(reader)) {
2098 return false;
2099 }
2100 return true;
2101}
2102
2104{
2105 std::string tag = reader.readTag(s_tag_len);
2106 if (reader.isError()) {
2107 return false;
2108 }
2109 if (tag != s_tag) {
2110 reader.fail();
2111 return false;
2112 }
2113 return true;
2114}
2115
2117{
2118 if (reader.noMore()) {
2119 reader.fail();
2120 return false;
2121 }
2122 yarp::conf::vocab32_t _ecast;
2123 if (!reader.readVocab32(_ecast)) {
2124 reader.fail();
2125 return false;
2126 }
2127 map_type = static_cast<yarp::dev::Nav2D::NavigationMapTypeEnum>(_ecast);
2128 if (!reader.noMore()) {
2129 reader.fail();
2130 return false;
2131 }
2132 return true;
2133}
2134
2140
2146
2148{
2149 if (!writer.isNull()) {
2150 if (!writer.writeListHeader(s_reply_len)) {
2151 return false;
2152 }
2153 if (!writer.write(return_helper)) {
2154 return false;
2155 }
2156 }
2157 return true;
2158}
2159
2161{
2162 if (!reader.readListReturn()) {
2163 return false;
2164 }
2165 if (reader.noMore()) {
2166 reader.fail();
2167 return false;
2168 }
2169 if (!reader.read(return_helper)) {
2170 reader.fail();
2171 return false;
2172 }
2173 return true;
2174}
2175
2180
2181// goto_target_by_absolute_location_RPC helper class implementation
2186
2191
2196
2201
2203{
2204 yarp::os::idl::WireWriter writer(connection);
2205 if (!writer.writeListHeader(s_cmd_len)) {
2206 return false;
2207 }
2208 return write(writer);
2209}
2210
2212{
2213 yarp::os::idl::WireReader reader(connection);
2214 if (!reader.readListHeader()) {
2215 reader.fail();
2216 return false;
2217 }
2218 return read(reader);
2219}
2220
2222{
2223 if (!writeTag(writer)) {
2224 return false;
2225 }
2226 if (!writeArgs(writer)) {
2227 return false;
2228 }
2229 return true;
2230}
2231
2233{
2234 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
2235 return false;
2236 }
2237 return true;
2238}
2239
2241{
2242 if (!writer.writeNested(loc)) {
2243 return false;
2244 }
2245 return true;
2246}
2247
2249{
2250 if (!readTag(reader)) {
2251 return false;
2252 }
2253 if (!readArgs(reader)) {
2254 return false;
2255 }
2256 return true;
2257}
2258
2260{
2261 std::string tag = reader.readTag(s_tag_len);
2262 if (reader.isError()) {
2263 return false;
2264 }
2265 if (tag != s_tag) {
2266 reader.fail();
2267 return false;
2268 }
2269 return true;
2270}
2271
2273{
2274 if (reader.noMore()) {
2275 reader.fail();
2276 return false;
2277 }
2278 if (!reader.readNested(loc)) {
2279 reader.fail();
2280 return false;
2281 }
2282 if (!reader.noMore()) {
2283 reader.fail();
2284 return false;
2285 }
2286 return true;
2287}
2288
2294
2300
2302{
2303 if (!writer.isNull()) {
2304 if (!writer.writeListHeader(s_reply_len)) {
2305 return false;
2306 }
2307 if (!writer.writeBool(return_helper)) {
2308 return false;
2309 }
2310 }
2311 return true;
2312}
2313
2315{
2316 if (!reader.readListReturn()) {
2317 return false;
2318 }
2319 if (reader.noMore()) {
2320 reader.fail();
2321 return false;
2322 }
2323 if (!reader.readBool(return_helper)) {
2324 reader.fail();
2325 return false;
2326 }
2327 return true;
2328}
2329
2334
2335// goto_target_by_relative_location1_RPC helper class implementation
2340
2345
2350
2352 x{x},
2353 y{y}
2354{
2355}
2356
2358{
2359 yarp::os::idl::WireWriter writer(connection);
2360 if (!writer.writeListHeader(s_cmd_len)) {
2361 return false;
2362 }
2363 return write(writer);
2364}
2365
2367{
2368 yarp::os::idl::WireReader reader(connection);
2369 if (!reader.readListHeader()) {
2370 reader.fail();
2371 return false;
2372 }
2373 return read(reader);
2374}
2375
2377{
2378 if (!writeTag(writer)) {
2379 return false;
2380 }
2381 if (!writeArgs(writer)) {
2382 return false;
2383 }
2384 return true;
2385}
2386
2388{
2389 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
2390 return false;
2391 }
2392 return true;
2393}
2394
2396{
2397 if (!writer.writeFloat64(x)) {
2398 return false;
2399 }
2400 if (!writer.writeFloat64(y)) {
2401 return false;
2402 }
2403 return true;
2404}
2405
2407{
2408 if (!readTag(reader)) {
2409 return false;
2410 }
2411 if (!readArgs(reader)) {
2412 return false;
2413 }
2414 return true;
2415}
2416
2418{
2419 std::string tag = reader.readTag(s_tag_len);
2420 if (reader.isError()) {
2421 return false;
2422 }
2423 if (tag != s_tag) {
2424 reader.fail();
2425 return false;
2426 }
2427 return true;
2428}
2429
2431{
2432 if (reader.noMore()) {
2433 reader.fail();
2434 return false;
2435 }
2436 if (!reader.readFloat64(x)) {
2437 reader.fail();
2438 return false;
2439 }
2440 if (reader.noMore()) {
2441 reader.fail();
2442 return false;
2443 }
2444 if (!reader.readFloat64(y)) {
2445 reader.fail();
2446 return false;
2447 }
2448 if (!reader.noMore()) {
2449 reader.fail();
2450 return false;
2451 }
2452 return true;
2453}
2454
2460
2466
2468{
2469 if (!writer.isNull()) {
2470 if (!writer.writeListHeader(s_reply_len)) {
2471 return false;
2472 }
2473 if (!writer.writeBool(return_helper)) {
2474 return false;
2475 }
2476 }
2477 return true;
2478}
2479
2481{
2482 if (!reader.readListReturn()) {
2483 return false;
2484 }
2485 if (reader.noMore()) {
2486 reader.fail();
2487 return false;
2488 }
2489 if (!reader.readBool(return_helper)) {
2490 reader.fail();
2491 return false;
2492 }
2493 return true;
2494}
2495
2500
2501// goto_target_by_relative_location2_RPC helper class implementation
2506
2511
2516
2518 x{x},
2519 y{y},
2520 theta{theta}
2521{
2522}
2523
2525{
2526 yarp::os::idl::WireWriter writer(connection);
2527 if (!writer.writeListHeader(s_cmd_len)) {
2528 return false;
2529 }
2530 return write(writer);
2531}
2532
2534{
2535 yarp::os::idl::WireReader reader(connection);
2536 if (!reader.readListHeader()) {
2537 reader.fail();
2538 return false;
2539 }
2540 return read(reader);
2541}
2542
2544{
2545 if (!writeTag(writer)) {
2546 return false;
2547 }
2548 if (!writeArgs(writer)) {
2549 return false;
2550 }
2551 return true;
2552}
2553
2555{
2556 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
2557 return false;
2558 }
2559 return true;
2560}
2561
2563{
2564 if (!writer.writeFloat64(x)) {
2565 return false;
2566 }
2567 if (!writer.writeFloat64(y)) {
2568 return false;
2569 }
2570 if (!writer.writeFloat64(theta)) {
2571 return false;
2572 }
2573 return true;
2574}
2575
2577{
2578 if (!readTag(reader)) {
2579 return false;
2580 }
2581 if (!readArgs(reader)) {
2582 return false;
2583 }
2584 return true;
2585}
2586
2588{
2589 std::string tag = reader.readTag(s_tag_len);
2590 if (reader.isError()) {
2591 return false;
2592 }
2593 if (tag != s_tag) {
2594 reader.fail();
2595 return false;
2596 }
2597 return true;
2598}
2599
2601{
2602 if (reader.noMore()) {
2603 reader.fail();
2604 return false;
2605 }
2606 if (!reader.readFloat64(x)) {
2607 reader.fail();
2608 return false;
2609 }
2610 if (reader.noMore()) {
2611 reader.fail();
2612 return false;
2613 }
2614 if (!reader.readFloat64(y)) {
2615 reader.fail();
2616 return false;
2617 }
2618 if (reader.noMore()) {
2619 reader.fail();
2620 return false;
2621 }
2622 if (!reader.readFloat64(theta)) {
2623 reader.fail();
2624 return false;
2625 }
2626 if (!reader.noMore()) {
2627 reader.fail();
2628 return false;
2629 }
2630 return true;
2631}
2632
2638
2644
2646{
2647 if (!writer.isNull()) {
2648 if (!writer.writeListHeader(s_reply_len)) {
2649 return false;
2650 }
2651 if (!writer.writeBool(return_helper)) {
2652 return false;
2653 }
2654 }
2655 return true;
2656}
2657
2659{
2660 if (!reader.readListReturn()) {
2661 return false;
2662 }
2663 if (reader.noMore()) {
2664 reader.fail();
2665 return false;
2666 }
2667 if (!reader.readBool(return_helper)) {
2668 reader.fail();
2669 return false;
2670 }
2671 return true;
2672}
2673
2678
2679// get_absolute_location_of_current_target_RPC helper class implementation
2684
2689
2691{
2692 yarp::os::idl::WireWriter writer(connection);
2693 if (!writer.writeListHeader(s_cmd_len)) {
2694 return false;
2695 }
2696 return write(writer);
2697}
2698
2700{
2701 yarp::os::idl::WireReader reader(connection);
2702 if (!reader.readListHeader()) {
2703 reader.fail();
2704 return false;
2705 }
2706 return read(reader);
2707}
2708
2710{
2711 if (!writeTag(writer)) {
2712 return false;
2713 }
2714 if (!writeArgs(writer)) {
2715 return false;
2716 }
2717 return true;
2718}
2719
2721{
2722 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
2723 return false;
2724 }
2725 return true;
2726}
2727
2732
2734{
2735 if (!readTag(reader)) {
2736 return false;
2737 }
2738 if (!readArgs(reader)) {
2739 return false;
2740 }
2741 return true;
2742}
2743
2745{
2746 std::string tag = reader.readTag(s_tag_len);
2747 if (reader.isError()) {
2748 return false;
2749 }
2750 if (tag != s_tag) {
2751 reader.fail();
2752 return false;
2753 }
2754 return true;
2755}
2756
2758{
2759 if (!reader.noMore()) {
2760 reader.fail();
2761 return false;
2762 }
2763 return true;
2764}
2765
2771
2777
2779{
2780 if (!writer.isNull()) {
2781 if (!writer.writeListHeader(s_reply_len)) {
2782 return false;
2783 }
2784 if (!writer.write(return_helper)) {
2785 return false;
2786 }
2787 }
2788 return true;
2789}
2790
2792{
2793 if (!reader.readListReturn()) {
2794 return false;
2795 }
2796 if (reader.noMore()) {
2797 reader.fail();
2798 return false;
2799 }
2800 if (!reader.read(return_helper)) {
2801 reader.fail();
2802 return false;
2803 }
2804 return true;
2805}
2806
2811
2812// get_relative_location_of_current_target_RPC helper class implementation
2817
2822
2824{
2825 yarp::os::idl::WireWriter writer(connection);
2826 if (!writer.writeListHeader(s_cmd_len)) {
2827 return false;
2828 }
2829 return write(writer);
2830}
2831
2833{
2834 yarp::os::idl::WireReader reader(connection);
2835 if (!reader.readListHeader()) {
2836 reader.fail();
2837 return false;
2838 }
2839 return read(reader);
2840}
2841
2843{
2844 if (!writeTag(writer)) {
2845 return false;
2846 }
2847 if (!writeArgs(writer)) {
2848 return false;
2849 }
2850 return true;
2851}
2852
2854{
2855 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
2856 return false;
2857 }
2858 return true;
2859}
2860
2865
2867{
2868 if (!readTag(reader)) {
2869 return false;
2870 }
2871 if (!readArgs(reader)) {
2872 return false;
2873 }
2874 return true;
2875}
2876
2878{
2879 std::string tag = reader.readTag(s_tag_len);
2880 if (reader.isError()) {
2881 return false;
2882 }
2883 if (tag != s_tag) {
2884 reader.fail();
2885 return false;
2886 }
2887 return true;
2888}
2889
2891{
2892 if (!reader.noMore()) {
2893 reader.fail();
2894 return false;
2895 }
2896 return true;
2897}
2898
2904
2910
2912{
2913 if (!writer.isNull()) {
2914 if (!writer.writeListHeader(s_reply_len)) {
2915 return false;
2916 }
2917 if (!writer.write(return_helper)) {
2918 return false;
2919 }
2920 }
2921 return true;
2922}
2923
2925{
2926 if (!reader.readListReturn()) {
2927 return false;
2928 }
2929 if (reader.noMore()) {
2930 reader.fail();
2931 return false;
2932 }
2933 if (!reader.read(return_helper)) {
2934 reader.fail();
2935 return false;
2936 }
2937 return true;
2938}
2939
2944
2945// goto_target_by_absolute_location_and_set_name_RPC helper class implementation
2950
2955
2960
2966
2968{
2969 yarp::os::idl::WireWriter writer(connection);
2970 if (!writer.writeListHeader(s_cmd_len)) {
2971 return false;
2972 }
2973 return write(writer);
2974}
2975
2977{
2978 yarp::os::idl::WireReader reader(connection);
2979 if (!reader.readListHeader()) {
2980 reader.fail();
2981 return false;
2982 }
2983 return read(reader);
2984}
2985
2987{
2988 if (!writeTag(writer)) {
2989 return false;
2990 }
2991 if (!writeArgs(writer)) {
2992 return false;
2993 }
2994 return true;
2995}
2996
2998{
2999 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
3000 return false;
3001 }
3002 return true;
3003}
3004
3006{
3007 if (!writer.writeNested(loc)) {
3008 return false;
3009 }
3010 if (!writer.writeString(name)) {
3011 return false;
3012 }
3013 return true;
3014}
3015
3017{
3018 if (!readTag(reader)) {
3019 return false;
3020 }
3021 if (!readArgs(reader)) {
3022 return false;
3023 }
3024 return true;
3025}
3026
3028{
3029 std::string tag = reader.readTag(s_tag_len);
3030 if (reader.isError()) {
3031 return false;
3032 }
3033 if (tag != s_tag) {
3034 reader.fail();
3035 return false;
3036 }
3037 return true;
3038}
3039
3041{
3042 if (reader.noMore()) {
3043 reader.fail();
3044 return false;
3045 }
3046 if (!reader.readNested(loc)) {
3047 reader.fail();
3048 return false;
3049 }
3050 if (reader.noMore()) {
3051 reader.fail();
3052 return false;
3053 }
3054 if (!reader.readString(name)) {
3055 reader.fail();
3056 return false;
3057 }
3058 if (!reader.noMore()) {
3059 reader.fail();
3060 return false;
3061 }
3062 return true;
3063}
3064
3070
3076
3078{
3079 if (!writer.isNull()) {
3080 if (!writer.writeListHeader(s_reply_len)) {
3081 return false;
3082 }
3083 if (!writer.writeBool(return_helper)) {
3084 return false;
3085 }
3086 }
3087 return true;
3088}
3089
3091{
3092 if (!reader.readListReturn()) {
3093 return false;
3094 }
3095 if (reader.noMore()) {
3096 reader.fail();
3097 return false;
3098 }
3099 if (!reader.readBool(return_helper)) {
3100 reader.fail();
3101 return false;
3102 }
3103 return true;
3104}
3105
3110
3111// apply_velocity_command_RPC helper class implementation
3112INavigation2DMsgs_apply_velocity_command_RPC_helper::INavigation2DMsgs_apply_velocity_command_RPC_helper(const double x_vel, const double y_vel, const double theta_vel, const double timeout) :
3113 cmd{x_vel, y_vel, theta_vel, timeout}
3114{
3115}
3116
3118{
3119 return cmd.write(connection);
3120}
3121
3126
3127INavigation2DMsgs_apply_velocity_command_RPC_helper::Command::Command(const double x_vel, const double y_vel, const double theta_vel, const double timeout) :
3128 x_vel{x_vel},
3129 y_vel{y_vel},
3130 theta_vel{theta_vel},
3131 timeout{timeout}
3132{
3133}
3134
3136{
3137 yarp::os::idl::WireWriter writer(connection);
3138 if (!writer.writeListHeader(s_cmd_len)) {
3139 return false;
3140 }
3141 return write(writer);
3142}
3143
3145{
3146 yarp::os::idl::WireReader reader(connection);
3147 if (!reader.readListHeader()) {
3148 reader.fail();
3149 return false;
3150 }
3151 return read(reader);
3152}
3153
3155{
3156 if (!writeTag(writer)) {
3157 return false;
3158 }
3159 if (!writeArgs(writer)) {
3160 return false;
3161 }
3162 return true;
3163}
3164
3166{
3167 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
3168 return false;
3169 }
3170 return true;
3171}
3172
3174{
3175 if (!writer.writeFloat64(x_vel)) {
3176 return false;
3177 }
3178 if (!writer.writeFloat64(y_vel)) {
3179 return false;
3180 }
3181 if (!writer.writeFloat64(theta_vel)) {
3182 return false;
3183 }
3184 if (!writer.writeFloat64(timeout)) {
3185 return false;
3186 }
3187 return true;
3188}
3189
3191{
3192 if (!readTag(reader)) {
3193 return false;
3194 }
3195 if (!readArgs(reader)) {
3196 return false;
3197 }
3198 return true;
3199}
3200
3202{
3203 std::string tag = reader.readTag(s_tag_len);
3204 if (reader.isError()) {
3205 return false;
3206 }
3207 if (tag != s_tag) {
3208 reader.fail();
3209 return false;
3210 }
3211 return true;
3212}
3213
3215{
3216 if (reader.noMore()) {
3217 reader.fail();
3218 return false;
3219 }
3220 if (!reader.readFloat64(x_vel)) {
3221 reader.fail();
3222 return false;
3223 }
3224 if (reader.noMore()) {
3225 reader.fail();
3226 return false;
3227 }
3228 if (!reader.readFloat64(y_vel)) {
3229 reader.fail();
3230 return false;
3231 }
3232 if (reader.noMore()) {
3233 reader.fail();
3234 return false;
3235 }
3236 if (!reader.readFloat64(theta_vel)) {
3237 reader.fail();
3238 return false;
3239 }
3240 if (reader.noMore()) {
3241 reader.fail();
3242 return false;
3243 }
3244 if (!reader.readFloat64(timeout)) {
3245 reader.fail();
3246 return false;
3247 }
3248 if (!reader.noMore()) {
3249 reader.fail();
3250 return false;
3251 }
3252 return true;
3253}
3254
3256{
3257 yarp::os::idl::WireWriter writer(connection);
3258 return write(writer);
3259}
3260
3266
3268{
3269 if (!writer.isNull()) {
3270 if (!writer.writeListHeader(s_reply_len)) {
3271 return false;
3272 }
3273 if (!writer.writeBool(return_helper)) {
3274 return false;
3275 }
3276 }
3277 return true;
3278}
3279
3281{
3282 if (!reader.readListReturn()) {
3283 return false;
3284 }
3285 if (reader.noMore()) {
3286 reader.fail();
3287 return false;
3288 }
3289 if (!reader.readBool(return_helper)) {
3290 reader.fail();
3291 return false;
3292 }
3293 return true;
3294}
3295
3300
3301// get_last_velocity_command_RPC helper class implementation
3306
3311
3313{
3314 yarp::os::idl::WireWriter writer(connection);
3315 if (!writer.writeListHeader(s_cmd_len)) {
3316 return false;
3317 }
3318 return write(writer);
3319}
3320
3322{
3323 yarp::os::idl::WireReader reader(connection);
3324 if (!reader.readListHeader()) {
3325 reader.fail();
3326 return false;
3327 }
3328 return read(reader);
3329}
3330
3332{
3333 if (!writeTag(writer)) {
3334 return false;
3335 }
3336 if (!writeArgs(writer)) {
3337 return false;
3338 }
3339 return true;
3340}
3341
3343{
3344 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
3345 return false;
3346 }
3347 return true;
3348}
3349
3351{
3352 return true;
3353}
3354
3356{
3357 if (!readTag(reader)) {
3358 return false;
3359 }
3360 if (!readArgs(reader)) {
3361 return false;
3362 }
3363 return true;
3364}
3365
3367{
3368 std::string tag = reader.readTag(s_tag_len);
3369 if (reader.isError()) {
3370 return false;
3371 }
3372 if (tag != s_tag) {
3373 reader.fail();
3374 return false;
3375 }
3376 return true;
3377}
3378
3380{
3381 if (!reader.noMore()) {
3382 reader.fail();
3383 return false;
3384 }
3385 return true;
3386}
3387
3389{
3390 yarp::os::idl::WireWriter writer(connection);
3391 return write(writer);
3392}
3393
3399
3401{
3402 if (!writer.isNull()) {
3403 if (!writer.writeListHeader(s_reply_len)) {
3404 return false;
3405 }
3406 if (!writer.write(return_helper)) {
3407 return false;
3408 }
3409 }
3410 return true;
3411}
3412
3414{
3415 if (!reader.readListReturn()) {
3416 return false;
3417 }
3418 if (reader.noMore()) {
3419 reader.fail();
3420 return false;
3421 }
3422 if (!reader.read(return_helper)) {
3423 reader.fail();
3424 return false;
3425 }
3426 return true;
3427}
3428
3433
3434// get_name_of_current_target_RPC helper class implementation
3439
3444
3446{
3447 yarp::os::idl::WireWriter writer(connection);
3448 if (!writer.writeListHeader(s_cmd_len)) {
3449 return false;
3450 }
3451 return write(writer);
3452}
3453
3455{
3456 yarp::os::idl::WireReader reader(connection);
3457 if (!reader.readListHeader()) {
3458 reader.fail();
3459 return false;
3460 }
3461 return read(reader);
3462}
3463
3465{
3466 if (!writeTag(writer)) {
3467 return false;
3468 }
3469 if (!writeArgs(writer)) {
3470 return false;
3471 }
3472 return true;
3473}
3474
3476{
3477 if (!writer.writeTag(s_tag, 1, s_tag_len)) {
3478 return false;
3479 }
3480 return true;
3481}
3482
3484{
3485 return true;
3486}
3487
3489{
3490 if (!readTag(reader)) {
3491 return false;
3492 }
3493 if (!readArgs(reader)) {
3494 return false;
3495 }
3496 return true;
3497}
3498
3500{
3501 std::string tag = reader.readTag(s_tag_len);
3502 if (reader.isError()) {
3503 return false;
3504 }
3505 if (tag != s_tag) {
3506 reader.fail();
3507 return false;
3508 }
3509 return true;
3510}
3511
3513{
3514 if (!reader.noMore()) {
3515 reader.fail();
3516 return false;
3517 }
3518 return true;
3519}
3520
3526
3532
3534{
3535 if (!writer.isNull()) {
3536 if (!writer.writeListHeader(s_reply_len)) {
3537 return false;
3538 }
3539 if (!writer.write(return_helper)) {
3540 return false;
3541 }
3542 }
3543 return true;
3544}
3545
3547{
3548 if (!reader.readListReturn()) {
3549 return false;
3550 }
3551 if (reader.noMore()) {
3552 reader.fail();
3553 return false;
3554 }
3555 if (!reader.read(return_helper)) {
3556 reader.fail();
3557 return false;
3558 }
3559 return true;
3560}
3561
3566
3567// Constructor
3569{
3570 yarp().setOwner(*this);
3571}
3572
3574{
3575 if (!yarp().canWrite()) {
3577 }
3579 bool ok = yarp().write(helper, helper);
3580 return ok ? helper.reply.return_helper : bool{};
3581}
3582
3584{
3585 if (!yarp().canWrite()) {
3587 }
3589 bool ok = yarp().write(helper, helper);
3590 return ok ? helper.reply.return_helper : bool{};
3591}
3592
3594{
3595 if (!yarp().canWrite()) {
3597 }
3599 bool ok = yarp().write(helper, helper);
3600 return ok ? helper.reply.return_helper : bool{};
3601}
3602
3604{
3605 if (!yarp().canWrite()) {
3607 }
3609 bool ok = yarp().write(helper, helper);
3610 return ok ? helper.reply.return_helper : bool{};
3611}
3612
3614{
3615 if (!yarp().canWrite()) {
3617 }
3619 bool ok = yarp().write(helper, helper);
3620 return ok ? helper.reply.return_helper : return_get_navigation_status{};
3621}
3622
3624{
3625 if (!yarp().canWrite()) {
3627 }
3629 bool ok = yarp().write(helper, helper);
3630 return ok ? helper.reply.return_helper : return_get_current_nav_waypoint{};
3631}
3632
3634{
3635 if (!yarp().canWrite()) {
3637 }
3639 bool ok = yarp().write(helper, helper);
3640 return ok ? helper.reply.return_helper : return_get_all_nav_waypoints{};
3641}
3642
3644{
3645 if (!yarp().canWrite()) {
3647 }
3649 bool ok = yarp().write(helper, helper);
3650 return ok ? helper.reply.return_helper : return_get_current_nav_map{};
3651}
3652
3654{
3655 if (!yarp().canWrite()) {
3657 }
3659 bool ok = yarp().write(helper, helper);
3660 return ok ? helper.reply.return_helper : bool{};
3661}
3662
3664{
3665 if (!yarp().canWrite()) {
3667 }
3669 bool ok = yarp().write(helper, helper);
3670 return ok ? helper.reply.return_helper : bool{};
3671}
3672
3673bool INavigation2DMsgs::goto_target_by_relative_location2_RPC(const double x, const double y, const double theta)
3674{
3675 if (!yarp().canWrite()) {
3677 }
3679 bool ok = yarp().write(helper, helper);
3680 return ok ? helper.reply.return_helper : bool{};
3681}
3682
3692
3702
3704{
3705 if (!yarp().canWrite()) {
3707 }
3709 bool ok = yarp().write(helper, helper);
3710 return ok ? helper.reply.return_helper : bool{};
3711}
3712
3713bool INavigation2DMsgs::apply_velocity_command_RPC(const double x_vel, const double y_vel, const double theta_vel, const double timeout)
3714{
3715 if (!yarp().canWrite()) {
3717 }
3718 INavigation2DMsgs_apply_velocity_command_RPC_helper helper{x_vel, y_vel, theta_vel, timeout};
3719 bool ok = yarp().write(helper, helper);
3720 return ok ? helper.reply.return_helper : bool{};
3721}
3722
3724{
3725 if (!yarp().canWrite()) {
3727 }
3729 bool ok = yarp().write(helper, helper);
3730 return ok ? helper.reply.return_helper : return_get_last_velocity_command{};
3731}
3732
3734{
3735 if (!yarp().canWrite()) {
3737 }
3739 bool ok = yarp().write(helper, helper);
3740 return ok ? helper.reply.return_helper : return_get_name_of_current_target{};
3741}
3742
3743// help method
3744std::vector<std::string> INavigation2DMsgs::help(const std::string& functionName)
3745{
3746 bool showAll = (functionName == "--all");
3747 std::vector<std::string> helpString;
3748 if (showAll) {
3749 helpString.emplace_back("*** Available commands:");
3767 helpString.emplace_back("help");
3768 } else {
3771 }
3774 }
3777 }
3780 }
3783 }
3786 }
3789 }
3792 }
3795 }
3798 }
3801 }
3804 }
3807 }
3810 }
3813 }
3816 }
3819 }
3820 if (functionName == "help") {
3821 helpString.emplace_back("std::vector<std::string> help(const std::string& functionName = \"--all\")");
3822 helpString.emplace_back("Return list of available commands, or help message for a specific function");
3823 helpString.emplace_back("@param functionName name of command for which to get a detailed description. If none or '--all' is provided, print list of available commands");
3824 helpString.emplace_back("@return list of strings (one string per line)");
3825 }
3826 }
3827 if (helpString.empty()) {
3828 helpString.emplace_back("Command not found");
3829 }
3830 return helpString;
3831}
3832
3833// read from ConnectionReader
3835{
3836 constexpr size_t max_tag_len = 9;
3837 size_t tag_len = 1;
3838
3839 yarp::os::idl::WireReader reader(connection);
3840 reader.expectAccept();
3841 if (!reader.readListHeader()) {
3842 reader.fail();
3843 return false;
3844 }
3845
3846 std::string tag = reader.readTag(1);
3847 bool direct = (tag == "__direct__");
3848 if (direct) {
3849 tag = reader.readTag(1);
3850 }
3851 while (tag_len <= max_tag_len && !reader.isError()) {
3854 if (!helper.cmd.readArgs(reader)) {
3855 return false;
3856 }
3857
3858 helper.call(this);
3859
3860 yarp::os::idl::WireWriter writer(reader);
3861 if (!helper.reply.write(writer)) {
3862 return false;
3863 }
3864 reader.accept();
3865 return true;
3866 }
3869 if (!helper.cmd.readArgs(reader)) {
3870 return false;
3871 }
3872
3873 helper.call(this);
3874
3875 yarp::os::idl::WireWriter writer(reader);
3876 if (!helper.reply.write(writer)) {
3877 return false;
3878 }
3879 reader.accept();
3880 return true;
3881 }
3884 if (!helper.cmd.readArgs(reader)) {
3885 return false;
3886 }
3887
3888 helper.call(this);
3889
3890 yarp::os::idl::WireWriter writer(reader);
3891 if (!helper.reply.write(writer)) {
3892 return false;
3893 }
3894 reader.accept();
3895 return true;
3896 }
3899 if (!helper.cmd.readArgs(reader)) {
3900 return false;
3901 }
3902
3903 helper.call(this);
3904
3905 yarp::os::idl::WireWriter writer(reader);
3906 if (!helper.reply.write(writer)) {
3907 return false;
3908 }
3909 reader.accept();
3910 return true;
3911 }
3914 if (!helper.cmd.readArgs(reader)) {
3915 return false;
3916 }
3917
3918 helper.call(this);
3919
3920 yarp::os::idl::WireWriter writer(reader);
3921 if (!helper.reply.write(writer)) {
3922 return false;
3923 }
3924 reader.accept();
3925 return true;
3926 }
3929 if (!helper.cmd.readArgs(reader)) {
3930 return false;
3931 }
3932
3933 helper.call(this);
3934
3935 yarp::os::idl::WireWriter writer(reader);
3936 if (!helper.reply.write(writer)) {
3937 return false;
3938 }
3939 reader.accept();
3940 return true;
3941 }
3944 if (!helper.cmd.readArgs(reader)) {
3945 return false;
3946 }
3947
3948 helper.call(this);
3949
3950 yarp::os::idl::WireWriter writer(reader);
3951 if (!helper.reply.write(writer)) {
3952 return false;
3953 }
3954 reader.accept();
3955 return true;
3956 }
3959 if (!helper.cmd.readArgs(reader)) {
3960 return false;
3961 }
3962
3963 helper.call(this);
3964
3965 yarp::os::idl::WireWriter writer(reader);
3966 if (!helper.reply.write(writer)) {
3967 return false;
3968 }
3969 reader.accept();
3970 return true;
3971 }
3974 if (!helper.cmd.readArgs(reader)) {
3975 return false;
3976 }
3977
3978 helper.call(this);
3979
3980 yarp::os::idl::WireWriter writer(reader);
3981 if (!helper.reply.write(writer)) {
3982 return false;
3983 }
3984 reader.accept();
3985 return true;
3986 }
3989 if (!helper.cmd.readArgs(reader)) {
3990 return false;
3991 }
3992
3993 helper.call(this);
3994
3995 yarp::os::idl::WireWriter writer(reader);
3996 if (!helper.reply.write(writer)) {
3997 return false;
3998 }
3999 reader.accept();
4000 return true;
4001 }
4004 if (!helper.cmd.readArgs(reader)) {
4005 return false;
4006 }
4007
4008 helper.call(this);
4009
4010 yarp::os::idl::WireWriter writer(reader);
4011 if (!helper.reply.write(writer)) {
4012 return false;
4013 }
4014 reader.accept();
4015 return true;
4016 }
4019 if (!helper.cmd.readArgs(reader)) {
4020 return false;
4021 }
4022
4023 helper.call(this);
4024
4025 yarp::os::idl::WireWriter writer(reader);
4026 if (!helper.reply.write(writer)) {
4027 return false;
4028 }
4029 reader.accept();
4030 return true;
4031 }
4034 if (!helper.cmd.readArgs(reader)) {
4035 return false;
4036 }
4037
4038 helper.call(this);
4039
4040 yarp::os::idl::WireWriter writer(reader);
4041 if (!helper.reply.write(writer)) {
4042 return false;
4043 }
4044 reader.accept();
4045 return true;
4046 }
4049 if (!helper.cmd.readArgs(reader)) {
4050 return false;
4051 }
4052
4053 helper.call(this);
4054
4055 yarp::os::idl::WireWriter writer(reader);
4056 if (!helper.reply.write(writer)) {
4057 return false;
4058 }
4059 reader.accept();
4060 return true;
4061 }
4064 if (!helper.cmd.readArgs(reader)) {
4065 return false;
4066 }
4067
4068 helper.call(this);
4069
4070 yarp::os::idl::WireWriter writer(reader);
4071 if (!helper.reply.write(writer)) {
4072 return false;
4073 }
4074 reader.accept();
4075 return true;
4076 }
4079 if (!helper.cmd.readArgs(reader)) {
4080 return false;
4081 }
4082
4083 helper.call(this);
4084
4085 yarp::os::idl::WireWriter writer(reader);
4086 if (!helper.reply.write(writer)) {
4087 return false;
4088 }
4089 reader.accept();
4090 return true;
4091 }
4093