MCPcopy Create free account
hub / github.com/comaps/comaps / DeserializeRoutePoint

Function DeserializeRoutePoint

libs/map/routing_manager.cpp:140–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

138}
139
140RouteMarkData DeserializeRoutePoint(json_t * node)
141{
142 ASSERT(node != nullptr, ());
143 RouteMarkData data;
144
145 int type = 0;
146 FromJSONObject(node, "type", type);
147 data.m_pointType = static_cast<RouteMarkType>(type);
148
149 FromJSONObject(node, "title", data.m_title);
150 FromJSONObject(node, "subtitle", data.m_subTitle);
151
152 FromJSONObject(node, "x", data.m_position.x);
153 FromJSONObject(node, "y", data.m_position.y);
154
155 FromJSONObject(node, "replaceWithMyPosition", data.m_replaceWithMyPositionAfterRestart);
156
157 return data;
158}
159
160string SerializeRoutePoints(vector<RouteMarkData> const & points)
161{

Callers 1

DeserializeRoutePointsFunction · 0.85

Calls 2

ASSERTFunction · 0.85
FromJSONObjectFunction · 0.50

Tested by

no test coverage detected