Added flatbuffers output support to the 'Nearest' service.

This commit is contained in:
Denis Chaplygin
2019-08-06 15:31:39 +03:00
parent acd3e81ab4
commit 9d7a74445d
7 changed files with 147 additions and 59 deletions
+6
View File
@@ -62,6 +62,12 @@ NearestService::RunQuery(std::size_t prefix_length, std::string &query, osrm::en
}
BOOST_ASSERT(parameters->IsValid());
if (parameters->format)
{
if (parameters->format == engine::api::BaseParameters::OutputFormatType::FLATBUFFERS) {
result = flatbuffers::FlatBufferBuilder();
}
}
return BaseService::routing_machine.Nearest(*parameters, result);
}
}