Welcome to mirror list, hosted at ThFree Co, Russian Federation.

routing_result_graph.hpp « routing - github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: d125ef9f41008f600f480d12bf7919a1e061c9d5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#pragma once

#include "routing/loaded_path_segment.hpp"
#include "routing/road_graph.hpp"
#include "routing/turn_candidate.hpp"

#include <cstddef>

namespace routing
{
namespace turns
{
/*!
 * \brief The IRoutingResult interface for the routing result. Uncouple router from the
 * annotation code that describes turns. See routers for detail implementations.
 */
class IRoutingResult
{
public:
  /// \returns information about all route segments.
  virtual TUnpackedPathSegments const & GetSegments() const = 0;
  /// \brief For a |segmentRange|, |junctionPoint| and |ingoingPoint| (point before the |junctionPoint|)
  /// this method computes number of ingoing ways to |junctionPoint| and fills |outgoingTurns|.
  /// \note This method should not be called for |segmentRange| of fake edges.
  /// So method |segmentRange.IsClear()| should return false.
  virtual void GetPossibleTurns(SegmentRange const & segmentRange, m2::PointD const & junctionPoint,
                                size_t & ingoingCount, TurnCandidates & outgoingTurns) const = 0;
  virtual double GetPathLength() const = 0;
  virtual Junction GetStartPoint() const = 0;
  virtual Junction GetEndPoint() const = 0;

  virtual ~IRoutingResult() = default;
};
}  // namespace routing
}  // namespace turns