24 #include <interfaces/NavGraphGeneratorInterface.h>
26 #include <core/exceptions/software.h>
59 NavGraphGeneratorInterface::NavGraphGeneratorInterface() : Interface()
61 data_size =
sizeof(NavGraphGeneratorInterface_data_t);
62 data_ptr = malloc(data_size);
63 data = (NavGraphGeneratorInterface_data_t *)data_ptr;
64 data_ts = (interface_data_ts_t *)data_ptr;
65 memset(data_ptr, 0, data_size);
66 enum_map_ConnectionMode[(int)NOT_CONNECTED] =
"NOT_CONNECTED";
67 enum_map_ConnectionMode[(int)UNCONNECTED] =
"UNCONNECTED";
68 enum_map_ConnectionMode[(int)CLOSEST_NODE] =
"CLOSEST_NODE";
69 enum_map_ConnectionMode[(int)CLOSEST_EDGE] =
"CLOSEST_EDGE";
70 enum_map_ConnectionMode[(int)CLOSEST_EDGE_OR_NODE] =
"CLOSEST_EDGE_OR_NODE";
71 enum_map_FilterType[(int)FILTER_EDGES_BY_MAP] =
"FILTER_EDGES_BY_MAP";
72 enum_map_FilterType[(int)FILTER_ORPHAN_NODES] =
"FILTER_ORPHAN_NODES";
73 enum_map_FilterType[(int)FILTER_MULTI_GRAPH] =
"FILTER_MULTI_GRAPH";
74 enum_map_EdgeMode[(int)NO_INTERSECTION] =
"NO_INTERSECTION";
75 enum_map_EdgeMode[(int)SPLIT_INTERSECTION] =
"SPLIT_INTERSECTION";
76 enum_map_EdgeMode[(int)FORCE] =
"FORCE";
77 enum_map_Algorithm[(int)ALGORITHM_VORONOI] =
"ALGORITHM_VORONOI";
78 enum_map_Algorithm[(int)ALGORITHM_GRID] =
"ALGORITHM_GRID";
79 add_fieldinfo(IFT_UINT32,
"msgid", 1, &data->msgid);
80 add_fieldinfo(IFT_BOOL,
"final", 1, &data->final);
81 add_fieldinfo(IFT_BOOL,
"ok", 1, &data->ok);
82 add_fieldinfo(IFT_STRING,
"error_message", 128, data->error_message);
83 add_messageinfo(
"ClearMessage");
84 add_messageinfo(
"SetAlgorithmMessage");
85 add_messageinfo(
"SetAlgorithmParameterMessage");
86 add_messageinfo(
"SetBoundingBoxMessage");
87 add_messageinfo(
"SetFilterMessage");
88 add_messageinfo(
"SetFilterParamFloatMessage");
89 add_messageinfo(
"AddMapObstaclesMessage");
90 add_messageinfo(
"AddObstacleMessage");
91 add_messageinfo(
"RemoveObstacleMessage");
92 add_messageinfo(
"AddPointOfInterestMessage");
93 add_messageinfo(
"AddPointOfInterestWithOriMessage");
94 add_messageinfo(
"SetPointOfInterestPropertyMessage");
95 add_messageinfo(
"AddEdgeMessage");
96 add_messageinfo(
"SetGraphDefaultPropertyMessage");
97 add_messageinfo(
"SetCopyGraphDefaultPropertiesMessage");
98 add_messageinfo(
"RemovePointOfInterestMessage");
99 add_messageinfo(
"ComputeMessage");
100 unsigned char tmp_hash[] = {0xec, 0x52, 0xc2, 0x84, 0x36, 0x53, 0x28, 0xc3, 0xdd, 0x79, 0x9f, 0x29, 0xe0, 0x48, 0xab, 0x6};
105 NavGraphGeneratorInterface::~NavGraphGeneratorInterface()
114 NavGraphGeneratorInterface::tostring_ConnectionMode(ConnectionMode value)
const
117 case NOT_CONNECTED:
return "NOT_CONNECTED";
118 case UNCONNECTED:
return "UNCONNECTED";
119 case CLOSEST_NODE:
return "CLOSEST_NODE";
120 case CLOSEST_EDGE:
return "CLOSEST_EDGE";
121 case CLOSEST_EDGE_OR_NODE:
return "CLOSEST_EDGE_OR_NODE";
122 default:
return "UNKNOWN";
130 NavGraphGeneratorInterface::tostring_FilterType(FilterType value)
const
133 case FILTER_EDGES_BY_MAP:
return "FILTER_EDGES_BY_MAP";
134 case FILTER_ORPHAN_NODES:
return "FILTER_ORPHAN_NODES";
135 case FILTER_MULTI_GRAPH:
return "FILTER_MULTI_GRAPH";
136 default:
return "UNKNOWN";
144 NavGraphGeneratorInterface::tostring_EdgeMode(EdgeMode value)
const
147 case NO_INTERSECTION:
return "NO_INTERSECTION";
148 case SPLIT_INTERSECTION:
return "SPLIT_INTERSECTION";
149 case FORCE:
return "FORCE";
150 default:
return "UNKNOWN";
158 NavGraphGeneratorInterface::tostring_Algorithm(Algorithm value)
const
161 case ALGORITHM_VORONOI:
return "ALGORITHM_VORONOI";
162 case ALGORITHM_GRID:
return "ALGORITHM_GRID";
163 default:
return "UNKNOWN";
175 NavGraphGeneratorInterface::msgid()
const
185 NavGraphGeneratorInterface::maxlenof_msgid()
const
198 NavGraphGeneratorInterface::set_msgid(
const uint32_t new_msgid)
200 data->msgid = new_msgid;
213 NavGraphGeneratorInterface::is_final()
const
223 NavGraphGeneratorInterface::maxlenof_final()
const
237 NavGraphGeneratorInterface::set_final(
const bool new_final)
239 data->final = new_final;
251 NavGraphGeneratorInterface::is_ok()
const
261 NavGraphGeneratorInterface::maxlenof_ok()
const
274 NavGraphGeneratorInterface::set_ok(
const bool new_ok)
288 NavGraphGeneratorInterface::error_message()
const
290 return data->error_message;
298 NavGraphGeneratorInterface::maxlenof_error_message()
const
311 NavGraphGeneratorInterface::set_error_message(
const char * new_error_message)
313 strncpy(data->error_message, new_error_message,
sizeof(data->error_message)-1);
314 data->error_message[
sizeof(data->error_message)-1] = 0;
320 NavGraphGeneratorInterface::create_message(
const char *type)
const
322 if ( strncmp(
"ClearMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
324 }
else if ( strncmp(
"SetAlgorithmMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
326 }
else if ( strncmp(
"SetAlgorithmParameterMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
327 return new SetAlgorithmParameterMessage();
328 }
else if ( strncmp(
"SetBoundingBoxMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
329 return new SetBoundingBoxMessage();
330 }
else if ( strncmp(
"SetFilterMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
331 return new SetFilterMessage();
332 }
else if ( strncmp(
"SetFilterParamFloatMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
333 return new SetFilterParamFloatMessage();
334 }
else if ( strncmp(
"AddMapObstaclesMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
335 return new AddMapObstaclesMessage();
336 }
else if ( strncmp(
"AddObstacleMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
337 return new AddObstacleMessage();
338 }
else if ( strncmp(
"RemoveObstacleMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
339 return new RemoveObstacleMessage();
340 }
else if ( strncmp(
"AddPointOfInterestMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
341 return new AddPointOfInterestMessage();
342 }
else if ( strncmp(
"AddPointOfInterestWithOriMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
343 return new AddPointOfInterestWithOriMessage();
344 }
else if ( strncmp(
"SetPointOfInterestPropertyMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
345 return new SetPointOfInterestPropertyMessage();
346 }
else if ( strncmp(
"AddEdgeMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
347 return new AddEdgeMessage();
348 }
else if ( strncmp(
"SetGraphDefaultPropertyMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
349 return new SetGraphDefaultPropertyMessage();
350 }
else if ( strncmp(
"SetCopyGraphDefaultPropertiesMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
351 return new SetCopyGraphDefaultPropertiesMessage();
352 }
else if ( strncmp(
"RemovePointOfInterestMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
353 return new RemovePointOfInterestMessage();
354 }
else if ( strncmp(
"ComputeMessage", type, INTERFACE_MESSAGE_TYPE_SIZE_ - 1) == 0 ) {
355 return new ComputeMessage();
357 throw UnknownTypeException(
"The given type '%s' does not match any known "
358 "message type for this interface type.", type);
367 NavGraphGeneratorInterface::copy_values(
const Interface *other)
369 const NavGraphGeneratorInterface *oi =
dynamic_cast<const NavGraphGeneratorInterface *
>(other);
371 throw TypeMismatchException(
"Can only copy values from interface of same type (%s vs. %s)",
372 type(), other->type());
374 memcpy(data, oi->data,
sizeof(NavGraphGeneratorInterface_data_t));
378 NavGraphGeneratorInterface::enum_tostring(
const char *enumtype,
int val)
const
380 if (strcmp(enumtype,
"ConnectionMode") == 0) {
381 return tostring_ConnectionMode((ConnectionMode)val);
383 if (strcmp(enumtype,
"FilterType") == 0) {
386 if (strcmp(enumtype,
"EdgeMode") == 0) {
387 return tostring_EdgeMode((EdgeMode)val);
389 if (strcmp(enumtype,
"Algorithm") == 0) {
390 return tostring_Algorithm((Algorithm)val);
392 throw UnknownTypeException(
"Unknown enum type %s", enumtype);
404 NavGraphGeneratorInterface::ClearMessage::ClearMessage() : Message(
"ClearMessage")
409 data = (ClearMessage_data_t *)
data_ptr;
411 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
412 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
413 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
414 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
421 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
440 data = (ClearMessage_data_t *)
data_ptr;
467 data_size =
sizeof(SetAlgorithmMessage_data_t);
470 data = (SetAlgorithmMessage_data_t *)
data_ptr;
472 data->algorithm = ini_algorithm;
473 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
474 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
475 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
476 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
483 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
491 data_size =
sizeof(SetAlgorithmMessage_data_t);
494 data = (SetAlgorithmMessage_data_t *)
data_ptr;
496 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
497 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
498 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
499 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
506 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
526 data = (SetAlgorithmMessage_data_t *)
data_ptr;
558 data->algorithm = new_algorithm;
584 data_size =
sizeof(SetAlgorithmParameterMessage_data_t);
587 data = (SetAlgorithmParameterMessage_data_t *)
data_ptr;
589 strncpy(data->param, ini_param, 32-1);
590 data->param[32-1] = 0;
591 strncpy(data->value, ini_value, 64-1);
592 data->value[64-1] = 0;
593 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
594 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
595 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
596 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
603 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
612 data_size =
sizeof(SetAlgorithmParameterMessage_data_t);
615 data = (SetAlgorithmParameterMessage_data_t *)
data_ptr;
617 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
618 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
619 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
620 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
627 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
648 data = (SetAlgorithmParameterMessage_data_t *)
data_ptr;
684 strncpy(data->param, new_param,
sizeof(data->param)-1);
685 data->param[
sizeof(data->param)-1] = 0;
721 strncpy(data->value, new_value,
sizeof(data->value)-1);
722 data->value[
sizeof(data->value)-1] = 0;
750 data_size =
sizeof(SetBoundingBoxMessage_data_t);
753 data = (SetBoundingBoxMessage_data_t *)
data_ptr;
755 data->p1_x = ini_p1_x;
756 data->p1_y = ini_p1_y;
757 data->p2_x = ini_p2_x;
758 data->p2_y = ini_p2_y;
759 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
760 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
761 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
762 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
769 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
780 data_size =
sizeof(SetBoundingBoxMessage_data_t);
783 data = (SetBoundingBoxMessage_data_t *)
data_ptr;
785 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
786 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
787 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
788 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
795 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
818 data = (SetBoundingBoxMessage_data_t *)
data_ptr;
850 data->p1_x = new_p1_x;
880 data->p1_y = new_p1_y;
910 data->p2_x = new_p2_x;
940 data->p2_y = new_p2_y;
966 data_size =
sizeof(SetFilterMessage_data_t);
969 data = (SetFilterMessage_data_t *)
data_ptr;
971 data->filter = ini_filter;
972 data->enable = ini_enable;
973 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
974 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
975 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
976 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
983 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
992 data_size =
sizeof(SetFilterMessage_data_t);
995 data = (SetFilterMessage_data_t *)
data_ptr;
997 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
998 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
999 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1000 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1007 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1028 data = (SetFilterMessage_data_t *)
data_ptr;
1062 data->filter = new_filter;
1073 return data->enable;
1094 data->enable = new_enable;
1121 data_size =
sizeof(SetFilterParamFloatMessage_data_t);
1124 data = (SetFilterParamFloatMessage_data_t *)
data_ptr;
1126 data->filter = ini_filter;
1127 strncpy(data->param, ini_param, 32-1);
1128 data->param[32-1] = 0;
1129 data->value = ini_value;
1130 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1131 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1132 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1133 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1140 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1150 data_size =
sizeof(SetFilterParamFloatMessage_data_t);
1153 data = (SetFilterParamFloatMessage_data_t *)
data_ptr;
1155 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1156 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1157 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1158 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1165 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1187 data = (SetFilterParamFloatMessage_data_t *)
data_ptr;
1221 data->filter = new_filter;
1253 strncpy(data->param, new_param,
sizeof(data->param)-1);
1254 data->param[
sizeof(data->param)-1] = 0;
1286 data->value = new_value;
1311 data_size =
sizeof(AddMapObstaclesMessage_data_t);
1314 data = (AddMapObstaclesMessage_data_t *)
data_ptr;
1316 data->max_line_point_distance = ini_max_line_point_distance;
1317 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1318 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1319 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1320 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1327 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1335 data_size =
sizeof(AddMapObstaclesMessage_data_t);
1338 data = (AddMapObstaclesMessage_data_t *)
data_ptr;
1340 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1341 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1342 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1343 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1350 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1370 data = (AddMapObstaclesMessage_data_t *)
data_ptr;
1385 return data->max_line_point_distance;
1408 data->max_line_point_distance = new_max_line_point_distance;
1435 data_size =
sizeof(AddObstacleMessage_data_t);
1438 data = (AddObstacleMessage_data_t *)
data_ptr;
1440 strncpy(data->name, ini_name, 64-1);
1441 data->name[64-1] = 0;
1444 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1445 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1446 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1447 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1454 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1464 data_size =
sizeof(AddObstacleMessage_data_t);
1467 data = (AddObstacleMessage_data_t *)
data_ptr;
1469 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1470 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1471 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1472 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1479 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1501 data = (AddObstacleMessage_data_t *)
data_ptr;
1537 strncpy(data->name, new_name,
sizeof(data->name)-1);
1538 data->name[
sizeof(data->name)-1] = 0;
1623 data_size =
sizeof(RemoveObstacleMessage_data_t);
1626 data = (RemoveObstacleMessage_data_t *)
data_ptr;
1628 strncpy(data->name, ini_name, 64-1);
1629 data->name[64-1] = 0;
1630 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1631 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1632 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1633 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1640 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1648 data_size =
sizeof(RemoveObstacleMessage_data_t);
1651 data = (RemoveObstacleMessage_data_t *)
data_ptr;
1653 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1654 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1655 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1656 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1663 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1683 data = (RemoveObstacleMessage_data_t *)
data_ptr;
1719 strncpy(data->name, new_name,
sizeof(data->name)-1);
1720 data->name[
sizeof(data->name)-1] = 0;
1748 data_size =
sizeof(AddPointOfInterestMessage_data_t);
1751 data = (AddPointOfInterestMessage_data_t *)
data_ptr;
1753 strncpy(data->name, ini_name, 64-1);
1754 data->name[64-1] = 0;
1757 data->mode = ini_mode;
1758 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1759 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1760 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1761 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1768 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1779 data_size =
sizeof(AddPointOfInterestMessage_data_t);
1782 data = (AddPointOfInterestMessage_data_t *)
data_ptr;
1784 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1785 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1786 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1787 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1794 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
1817 data = (AddPointOfInterestMessage_data_t *)
data_ptr;
1853 strncpy(data->name, new_name,
sizeof(data->name)-1);
1854 data->name[
sizeof(data->name)-1] = 0;
1948 data->mode = new_mode;
1977 data_size =
sizeof(AddPointOfInterestWithOriMessage_data_t);
1980 data = (AddPointOfInterestWithOriMessage_data_t *)
data_ptr;
1982 strncpy(data->name, ini_name, 64-1);
1983 data->name[64-1] = 0;
1986 data->ori = ini_ori;
1987 data->mode = ini_mode;
1988 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
1989 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
1990 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
1991 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
1998 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2010 data_size =
sizeof(AddPointOfInterestWithOriMessage_data_t);
2013 data = (AddPointOfInterestWithOriMessage_data_t *)
data_ptr;
2015 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2016 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2017 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2018 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2025 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2049 data = (AddPointOfInterestWithOriMessage_data_t *)
data_ptr;
2085 strncpy(data->name, new_name,
sizeof(data->name)-1);
2086 data->name[
sizeof(data->name)-1] = 0;
2176 data->ori = new_ori;
2210 data->mode = new_mode;
2237 data_size =
sizeof(SetPointOfInterestPropertyMessage_data_t);
2240 data = (SetPointOfInterestPropertyMessage_data_t *)
data_ptr;
2242 strncpy(data->name, ini_name, 64-1);
2243 data->name[64-1] = 0;
2244 strncpy(data->property_name, ini_property_name, 64-1);
2245 data->property_name[64-1] = 0;
2246 strncpy(data->property_value, ini_property_value, 1024-1);
2247 data->property_value[1024-1] = 0;
2248 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2249 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2250 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2251 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2258 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2268 data_size =
sizeof(SetPointOfInterestPropertyMessage_data_t);
2271 data = (SetPointOfInterestPropertyMessage_data_t *)
data_ptr;
2273 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2274 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2275 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2276 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2283 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2305 data = (SetPointOfInterestPropertyMessage_data_t *)
data_ptr;
2341 strncpy(data->name, new_name,
sizeof(data->name)-1);
2342 data->name[
sizeof(data->name)-1] = 0;
2352 return data->property_name;
2372 strncpy(data->property_name, new_property_name,
sizeof(data->property_name)-1);
2373 data->property_name[
sizeof(data->property_name)-1] = 0;
2384 return data->property_value;
2405 strncpy(data->property_value, new_property_value,
sizeof(data->property_value)-1);
2406 data->property_value[
sizeof(data->property_value)-1] = 0;
2434 data_size =
sizeof(AddEdgeMessage_data_t);
2437 data = (AddEdgeMessage_data_t *)
data_ptr;
2439 strncpy(data->p1, ini_p1, 64-1);
2441 strncpy(data->p2, ini_p2, 64-1);
2443 data->directed = ini_directed;
2444 data->mode = ini_mode;
2445 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2446 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2447 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2448 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2455 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2466 data_size =
sizeof(AddEdgeMessage_data_t);
2469 data = (AddEdgeMessage_data_t *)
data_ptr;
2471 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2472 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2473 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2474 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2481 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2504 data = (AddEdgeMessage_data_t *)
data_ptr;
2536 strncpy(data->p1, new_p1,
sizeof(data->p1)-1);
2537 data->p1[
sizeof(data->p1)-1] = 0;
2567 strncpy(data->p2, new_p2,
sizeof(data->p2)-1);
2568 data->p2[
sizeof(data->p2)-1] = 0;
2581 return data->directed;
2604 data->directed = new_directed;
2634 data->mode = new_mode;
2660 data_size =
sizeof(SetGraphDefaultPropertyMessage_data_t);
2663 data = (SetGraphDefaultPropertyMessage_data_t *)
data_ptr;
2665 strncpy(data->property_name, ini_property_name, 64-1);
2666 data->property_name[64-1] = 0;
2667 strncpy(data->property_value, ini_property_value, 1024-1);
2668 data->property_value[1024-1] = 0;
2669 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2670 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2671 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2672 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2679 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2688 data_size =
sizeof(SetGraphDefaultPropertyMessage_data_t);
2691 data = (SetGraphDefaultPropertyMessage_data_t *)
data_ptr;
2693 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2694 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2695 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2696 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2703 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2724 data = (SetGraphDefaultPropertyMessage_data_t *)
data_ptr;
2736 return data->property_name;
2756 strncpy(data->property_name, new_property_name,
sizeof(data->property_name)-1);
2757 data->property_name[
sizeof(data->property_name)-1] = 0;
2768 return data->property_value;
2789 strncpy(data->property_value, new_property_value,
sizeof(data->property_value)-1);
2790 data->property_value[
sizeof(data->property_value)-1] = 0;
2815 data_size =
sizeof(SetCopyGraphDefaultPropertiesMessage_data_t);
2818 data = (SetCopyGraphDefaultPropertiesMessage_data_t *)
data_ptr;
2820 data->enable_copy = ini_enable_copy;
2821 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2822 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2823 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2824 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2831 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2839 data_size =
sizeof(SetCopyGraphDefaultPropertiesMessage_data_t);
2842 data = (SetCopyGraphDefaultPropertiesMessage_data_t *)
data_ptr;
2844 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2845 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2846 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2847 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2854 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2874 data = (SetCopyGraphDefaultPropertiesMessage_data_t *)
data_ptr;
2887 return data->enable_copy;
2908 data->enable_copy = new_enable_copy;
2933 data_size =
sizeof(RemovePointOfInterestMessage_data_t);
2936 data = (RemovePointOfInterestMessage_data_t *)
data_ptr;
2938 strncpy(data->name, ini_name, 64-1);
2939 data->name[64-1] = 0;
2940 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2941 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2942 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2943 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2950 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2958 data_size =
sizeof(RemovePointOfInterestMessage_data_t);
2961 data = (RemovePointOfInterestMessage_data_t *)
data_ptr;
2963 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
2964 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
2965 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
2966 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
2973 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
2993 data = (RemovePointOfInterestMessage_data_t *)
data_ptr;
3029 strncpy(data->name, new_name,
sizeof(data->name)-1);
3030 data->name[
sizeof(data->name)-1] = 0;
3053 data_size =
sizeof(ComputeMessage_data_t);
3056 data = (ComputeMessage_data_t *)
data_ptr;
3058 enum_map_ConnectionMode[(int)
NOT_CONNECTED] =
"NOT_CONNECTED";
3059 enum_map_ConnectionMode[(int)
UNCONNECTED] =
"UNCONNECTED";
3060 enum_map_ConnectionMode[(int)
CLOSEST_NODE] =
"CLOSEST_NODE";
3061 enum_map_ConnectionMode[(int)
CLOSEST_EDGE] =
"CLOSEST_EDGE";
3068 enum_map_EdgeMode[(int)
FORCE] =
"FORCE";
3087 data = (ComputeMessage_data_t *)
data_ptr;
3117 const SetAlgorithmParameterMessage *m2 =
dynamic_cast<const SetAlgorithmParameterMessage *
>(message);
3121 const SetBoundingBoxMessage *m3 =
dynamic_cast<const SetBoundingBoxMessage *
>(message);
3125 const SetFilterMessage *m4 =
dynamic_cast<const SetFilterMessage *
>(message);
3129 const SetFilterParamFloatMessage *m5 =
dynamic_cast<const SetFilterParamFloatMessage *
>(message);
3133 const AddMapObstaclesMessage *m6 =
dynamic_cast<const AddMapObstaclesMessage *
>(message);
3137 const AddObstacleMessage *m7 =
dynamic_cast<const AddObstacleMessage *
>(message);
3141 const RemoveObstacleMessage *m8 =
dynamic_cast<const RemoveObstacleMessage *
>(message);
3145 const AddPointOfInterestMessage *m9 =
dynamic_cast<const AddPointOfInterestMessage *
>(message);
3149 const AddPointOfInterestWithOriMessage *m10 =
dynamic_cast<const AddPointOfInterestWithOriMessage *
>(message);
3150 if ( m10 != NULL ) {
3153 const SetPointOfInterestPropertyMessage *m11 =
dynamic_cast<const SetPointOfInterestPropertyMessage *
>(message);
3154 if ( m11 != NULL ) {
3157 const AddEdgeMessage *m12 =
dynamic_cast<const AddEdgeMessage *
>(message);
3158 if ( m12 != NULL ) {
3161 const SetGraphDefaultPropertyMessage *m13 =
dynamic_cast<const SetGraphDefaultPropertyMessage *
>(message);
3162 if ( m13 != NULL ) {
3165 const SetCopyGraphDefaultPropertiesMessage *m14 =
dynamic_cast<const SetCopyGraphDefaultPropertiesMessage *
>(message);
3166 if ( m14 != NULL ) {
3169 const RemovePointOfInterestMessage *m15 =
dynamic_cast<const RemovePointOfInterestMessage *
>(message);
3170 if ( m15 != NULL ) {
3173 const ComputeMessage *m16 =
dynamic_cast<const ComputeMessage *
>(message);
3174 if ( m16 != NULL ) {
3181 EXPORT_INTERFACE(NavGraphGeneratorInterface)