2016-02-12 19:48:14 -05:00
|
|
|
#ifndef TABLE_HPP
|
|
|
|
#define TABLE_HPP
|
|
|
|
|
|
|
|
#include "engine/plugins/plugin_base.hpp"
|
|
|
|
|
|
|
|
#include "engine/api/table_parameters.hpp"
|
|
|
|
#include "engine/routing_algorithms/many_to_many.hpp"
|
|
|
|
#include "engine/search_engine_data.hpp"
|
|
|
|
#include "util/json_container.hpp"
|
|
|
|
|
|
|
|
namespace osrm
|
|
|
|
{
|
|
|
|
namespace engine
|
|
|
|
{
|
|
|
|
namespace plugins
|
|
|
|
{
|
|
|
|
|
|
|
|
class TablePlugin final : public BasePlugin
|
|
|
|
{
|
|
|
|
public:
|
2016-10-05 19:05:03 -04:00
|
|
|
explicit TablePlugin(const int max_locations_distance_table);
|
2016-02-12 19:48:14 -05:00
|
|
|
|
2016-10-05 19:05:03 -04:00
|
|
|
Status HandleRequest(const std::shared_ptr<datafacade::BaseDataFacade> facade,
|
|
|
|
const api::TableParameters ¶ms,
|
2016-10-14 09:55:21 -04:00
|
|
|
util::json::Object &result) const;
|
2016-02-17 16:49:44 -05:00
|
|
|
|
|
|
|
private:
|
2016-10-14 09:55:21 -04:00
|
|
|
mutable SearchEngineData heaps;
|
|
|
|
mutable routing_algorithms::ManyToManyRouting<datafacade::BaseDataFacade> distance_table;
|
|
|
|
const int max_locations_distance_table;
|
2016-02-12 19:48:14 -05:00
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif // TABLE_HPP
|