mirror of
https://codeberg.org/comaps/comaps
synced 2026-01-04 11:53:47 +00:00
[traffic] Ignore access flags when decoding closure events
Fixes decoding of closures which are mapped in OSM as access restrictions Signed-off-by: mvglasow <michael -at- vonglasow.com>
This commit is contained in:
@@ -88,6 +88,11 @@ protected:
|
||||
*/
|
||||
std::map<std::string, traffxml::TraffMessage> & m_messageCache;
|
||||
|
||||
/**
|
||||
* @brief Consolidated traffic impact of the message currently being decoded
|
||||
*/
|
||||
std::optional<traffxml::TrafficImpact> m_trafficImpact;
|
||||
|
||||
private:
|
||||
};
|
||||
|
||||
@@ -321,6 +326,18 @@ public:
|
||||
routing::RoadGeometry const & to_road, bool is_left_hand_traffic = false) const override;
|
||||
double GetFerryLandingPenalty(Purpose /* purpose */) const override;
|
||||
|
||||
/**
|
||||
* @brief Whether access restrictions are ignored.
|
||||
*
|
||||
* A return value of false indicates that access restrictions should be observed, which is the
|
||||
* default behavior for a routing use case. If true, it indicates that routing should ignore
|
||||
* access restrictions. This is needed to resolve traffic message locations; it could also be
|
||||
* used e.g. for emergency vehicle use cases.
|
||||
*
|
||||
* This implementation may return true or false, depending on the location being decoded.
|
||||
*/
|
||||
bool IsAccessIgnored() override;
|
||||
|
||||
private:
|
||||
RoutingTraffDecoder & m_decoder;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user