Generalize directShortestPathSearch interface
This commit is contained in:
parent
3534203083
commit
aa736dbe3a
@ -21,19 +21,10 @@ namespace routing_algorithms
|
|||||||
/// by the previous route.
|
/// by the previous route.
|
||||||
/// This variation is only an optimazation for graphs with slow queries, for example
|
/// This variation is only an optimazation for graphs with slow queries, for example
|
||||||
/// not fully contracted graphs.
|
/// not fully contracted graphs.
|
||||||
InternalRouteResult directShortestPathSearch(
|
template <typename Algorithm>
|
||||||
SearchEngineData<ch::Algorithm> &engine_working_data,
|
InternalRouteResult
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<ch::Algorithm> &facade,
|
directShortestPathSearch(SearchEngineData<Algorithm> &engine_working_data,
|
||||||
const PhantomNodes &phantom_nodes);
|
const datafacade::ContiguousInternalMemoryDataFacade<Algorithm> &facade,
|
||||||
|
|
||||||
InternalRouteResult directShortestPathSearch(
|
|
||||||
SearchEngineData<corech::Algorithm> &engine_working_data,
|
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<corech::Algorithm> &facade,
|
|
||||||
const PhantomNodes &phantom_nodes);
|
|
||||||
|
|
||||||
InternalRouteResult directShortestPathSearch(
|
|
||||||
SearchEngineData<mld::Algorithm> &engine_working_data,
|
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<mld::Algorithm> &facade,
|
|
||||||
const PhantomNodes &phantom_nodes);
|
const PhantomNodes &phantom_nodes);
|
||||||
|
|
||||||
} // namespace routing_algorithms
|
} // namespace routing_algorithms
|
||||||
|
@ -44,8 +44,6 @@ extractRoute(const datafacade::ContiguousInternalMemoryDataFacade<AlgorithmT> &f
|
|||||||
return raw_route_data;
|
return raw_route_data;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace detail
|
|
||||||
{
|
|
||||||
/// This is a striped down version of the general shortest path algorithm.
|
/// This is a striped down version of the general shortest path algorithm.
|
||||||
/// The general algorithm always computes two queries for each leg. This is only
|
/// The general algorithm always computes two queries for each leg. This is only
|
||||||
/// necessary in case of vias, where the directions of the start node is constrainted
|
/// necessary in case of vias, where the directions of the start node is constrainted
|
||||||
@ -53,8 +51,8 @@ namespace detail
|
|||||||
/// This variation is only an optimazation for graphs with slow queries, for example
|
/// This variation is only an optimazation for graphs with slow queries, for example
|
||||||
/// not fully contracted graphs.
|
/// not fully contracted graphs.
|
||||||
template <typename Algorithm>
|
template <typename Algorithm>
|
||||||
InternalRouteResult directShortestPathSearchImpl(
|
InternalRouteResult
|
||||||
SearchEngineData<Algorithm> &engine_working_data,
|
directShortestPathSearch(SearchEngineData<Algorithm> &engine_working_data,
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<Algorithm> &facade,
|
const datafacade::ContiguousInternalMemoryDataFacade<Algorithm> &facade,
|
||||||
const PhantomNodes &phantom_nodes)
|
const PhantomNodes &phantom_nodes)
|
||||||
{
|
{
|
||||||
@ -100,24 +98,17 @@ InternalRouteResult directShortestPathSearchImpl(
|
|||||||
return extractRoute(facade, weight, phantom_nodes, unpacked_nodes, unpacked_edges);
|
return extractRoute(facade, weight, phantom_nodes, unpacked_nodes, unpacked_edges);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace ch
|
template InternalRouteResult directShortestPathSearch(
|
||||||
|
|
||||||
InternalRouteResult directShortestPathSearch(
|
|
||||||
SearchEngineData<corech::Algorithm> &engine_working_data,
|
SearchEngineData<corech::Algorithm> &engine_working_data,
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<corech::Algorithm> &facade,
|
const datafacade::ContiguousInternalMemoryDataFacade<corech::Algorithm> &facade,
|
||||||
const PhantomNodes &phantom_nodes)
|
const PhantomNodes &phantom_nodes);
|
||||||
{
|
|
||||||
return detail::directShortestPathSearchImpl(engine_working_data, facade, phantom_nodes);
|
|
||||||
}
|
|
||||||
|
|
||||||
InternalRouteResult directShortestPathSearch(
|
template InternalRouteResult directShortestPathSearch(
|
||||||
SearchEngineData<ch::Algorithm> &engine_working_data,
|
SearchEngineData<ch::Algorithm> &engine_working_data,
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<ch::Algorithm> &facade,
|
const datafacade::ContiguousInternalMemoryDataFacade<ch::Algorithm> &facade,
|
||||||
const PhantomNodes &phantom_nodes)
|
const PhantomNodes &phantom_nodes);
|
||||||
{
|
|
||||||
return detail::directShortestPathSearchImpl(engine_working_data, facade, phantom_nodes);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
template <>
|
||||||
InternalRouteResult directShortestPathSearch(
|
InternalRouteResult directShortestPathSearch(
|
||||||
SearchEngineData<mld::Algorithm> &engine_working_data,
|
SearchEngineData<mld::Algorithm> &engine_working_data,
|
||||||
const datafacade::ContiguousInternalMemoryDataFacade<mld::Algorithm> &facade,
|
const datafacade::ContiguousInternalMemoryDataFacade<mld::Algorithm> &facade,
|
||||||
|
Loading…
Reference in New Issue
Block a user