Apply clang-format again
This commit is contained in:
@@ -107,12 +107,11 @@ trimLaneString(std::string lane_string, std::int32_t count_left, std::int32_t co
|
||||
return extractor::guidance::trimLaneString(std::move(lane_string), count_left, count_right);
|
||||
}
|
||||
|
||||
inline std::string
|
||||
applyAccessTokens(const std::string &lane_string, const std::string &access_tokens)
|
||||
inline std::string applyAccessTokens(const std::string &lane_string,
|
||||
const std::string &access_tokens)
|
||||
{
|
||||
return extractor::guidance::applyAccessTokens(lane_string, access_tokens);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#ifndef EXTRACTION_WAY_HPP
|
||||
#define EXTRACTION_WAY_HPP
|
||||
|
||||
#include "extractor/travel_mode.hpp"
|
||||
#include "extractor/guidance/road_classification.hpp"
|
||||
#include "extractor/travel_mode.hpp"
|
||||
#include "util/guidance/turn_lanes.hpp"
|
||||
#include "util/typedefs.hpp"
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#ifndef EXTRACTOR_CALLBACKS_HPP
|
||||
#define EXTRACTOR_CALLBACKS_HPP
|
||||
|
||||
#include "util/typedefs.hpp"
|
||||
#include "extractor/guidance/turn_lane_types.hpp"
|
||||
#include "util/typedefs.hpp"
|
||||
|
||||
#include <boost/functional/hash.hpp>
|
||||
#include <boost/optional/optional_fwd.hpp>
|
||||
@@ -40,7 +40,10 @@ class ExtractorCallbacks
|
||||
using MapKey = std::pair<std::string, std::string>;
|
||||
using MapVal = unsigned;
|
||||
std::unordered_map<MapKey, MapVal, boost::hash<MapKey>> string_map;
|
||||
std::unordered_map<guidance::TurnLaneDescription,LaneDescriptionID,guidance::TurnLaneDescription_hash> lane_description_map;
|
||||
std::unordered_map<guidance::TurnLaneDescription,
|
||||
LaneDescriptionID,
|
||||
guidance::TurnLaneDescription_hash>
|
||||
lane_description_map;
|
||||
ExtractionContainers &external_memory;
|
||||
|
||||
public:
|
||||
|
||||
@@ -84,16 +84,10 @@ class RoadClassification
|
||||
bool IsLowPriorityRoadClass() const { return (0 != may_be_ignored); }
|
||||
void SetLowPriorityFlag(const bool new_value) { may_be_ignored = new_value; }
|
||||
|
||||
std::uint32_t GetPriority() const
|
||||
{
|
||||
return static_cast<std::uint32_t>(road_priority_class);
|
||||
}
|
||||
std::uint32_t GetPriority() const { return static_cast<std::uint32_t>(road_priority_class); }
|
||||
|
||||
RoadPriorityClass::Enum GetClass() const { return road_priority_class; }
|
||||
void SetClass(const RoadPriorityClass::Enum new_value)
|
||||
{
|
||||
road_priority_class = new_value;
|
||||
}
|
||||
void SetClass(const RoadPriorityClass::Enum new_value) { road_priority_class = new_value; }
|
||||
|
||||
bool operator==(const RoadClassification &other) const
|
||||
{
|
||||
@@ -102,10 +96,7 @@ class RoadClassification
|
||||
road_priority_class == other.road_priority_class;
|
||||
}
|
||||
|
||||
bool operator!=(const RoadClassification &other ) const
|
||||
{
|
||||
return !(*this == other);
|
||||
}
|
||||
bool operator!=(const RoadClassification &other) const { return !(*this == other); }
|
||||
|
||||
std::string ToString() const
|
||||
{
|
||||
@@ -116,7 +107,9 @@ class RoadClassification
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
static_assert(sizeof(RoadClassification) == 1,"Road Classification should fit a byte. Increasing this has a severe impact on memory.");
|
||||
static_assert(
|
||||
sizeof(RoadClassification) == 1,
|
||||
"Road Classification should fit a byte. Increasing this has a severe impact on memory.");
|
||||
|
||||
inline bool canBeSeenAsFork(const RoadClassification first, const RoadClassification second)
|
||||
{
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
#define OSRM_EXTRACTOR_GUIDANCE_SLIPROAD_HANDLER_HPP_
|
||||
|
||||
#include "extractor/guidance/intersection.hpp"
|
||||
#include "extractor/guidance/intersection_handler.hpp"
|
||||
#include "extractor/guidance/intersection_generator.hpp"
|
||||
#include "extractor/guidance/intersection_handler.hpp"
|
||||
#include "extractor/query_node.hpp"
|
||||
|
||||
#include "util/name_table.hpp"
|
||||
@@ -42,6 +42,7 @@ class SliproadHandler : public IntersectionHandler
|
||||
Intersection operator()(const NodeID nid,
|
||||
const EdgeID via_eid,
|
||||
Intersection intersection) const override final;
|
||||
|
||||
private:
|
||||
const IntersectionGenerator &intersection_generator;
|
||||
};
|
||||
|
||||
@@ -61,7 +61,8 @@ class TurnHandler : public IntersectionHandler
|
||||
handleDistinctConflict(const EdgeID via_edge, ConnectedRoad &left, ConnectedRoad &right) const;
|
||||
|
||||
// Classification
|
||||
std::pair<std::size_t, std::size_t> findFork(const EdgeID via_edge, const Intersection &intersection) const;
|
||||
std::pair<std::size_t, std::size_t> findFork(const EdgeID via_edge,
|
||||
const Intersection &intersection) const;
|
||||
|
||||
Intersection assignLeftTurns(const EdgeID via_edge,
|
||||
Intersection intersection,
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#ifndef OSRM_EXTRACTOR_GUIDANCE_TURN_LANE_DATA_HPP_
|
||||
#define OSRM_EXTRACTOR_GUIDANCE_TURN_LANE_DATA_HPP_
|
||||
|
||||
#include "util/typedefs.hpp"
|
||||
#include "extractor/guidance/turn_lane_types.hpp"
|
||||
#include "util/typedefs.hpp"
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
|
||||
@@ -10,9 +10,9 @@
|
||||
#include <boost/assert.hpp>
|
||||
#include <boost/functional/hash_fwd.hpp>
|
||||
|
||||
#include "util/json_container.hpp"
|
||||
#include "util/simple_logger.hpp"
|
||||
#include "util/typedefs.hpp"
|
||||
#include "util/json_container.hpp"
|
||||
|
||||
namespace osrm
|
||||
{
|
||||
|
||||
@@ -141,7 +141,6 @@ struct InternalExtractorEdge
|
||||
return v;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -112,20 +112,19 @@ inline bool NodeBasedEdge::operator<(const NodeBasedEdge &other) const
|
||||
return source < other.source;
|
||||
}
|
||||
|
||||
inline NodeBasedEdgeWithOSM::NodeBasedEdgeWithOSM(
|
||||
OSMNodeID source,
|
||||
OSMNodeID target,
|
||||
NodeID name_id,
|
||||
EdgeWeight weight,
|
||||
bool forward,
|
||||
bool backward,
|
||||
bool roundabout,
|
||||
bool access_restricted,
|
||||
bool startpoint,
|
||||
TravelMode travel_mode,
|
||||
bool is_split,
|
||||
const LaneDescriptionID lane_description_id,
|
||||
guidance::RoadClassification road_classification)
|
||||
inline NodeBasedEdgeWithOSM::NodeBasedEdgeWithOSM(OSMNodeID source,
|
||||
OSMNodeID target,
|
||||
NodeID name_id,
|
||||
EdgeWeight weight,
|
||||
bool forward,
|
||||
bool backward,
|
||||
bool roundabout,
|
||||
bool access_restricted,
|
||||
bool startpoint,
|
||||
TravelMode travel_mode,
|
||||
bool is_split,
|
||||
const LaneDescriptionID lane_description_id,
|
||||
guidance::RoadClassification road_classification)
|
||||
: NodeBasedEdge(SPECIAL_NODEID,
|
||||
SPECIAL_NODEID,
|
||||
name_id,
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
|
||||
#include "util/coordinate.hpp"
|
||||
|
||||
#include <limits>
|
||||
#include <cstdint>
|
||||
#include <limits>
|
||||
|
||||
namespace osrm
|
||||
{
|
||||
@@ -15,8 +15,8 @@ namespace extractor
|
||||
|
||||
struct QueryNode
|
||||
{
|
||||
using key_type = OSMNodeID; // type of NodeID
|
||||
using value_type = std::int32_t; // type of lat,lons
|
||||
using key_type = OSMNodeID; // type of NodeID
|
||||
using value_type = std::int32_t; // type of lat,lons
|
||||
|
||||
explicit QueryNode(const util::FixedLongitude lon_,
|
||||
const util::FixedLatitude lat_,
|
||||
|
||||
@@ -48,7 +48,7 @@ class LuaScriptingEnvironment final : public ScriptingEnvironment
|
||||
explicit LuaScriptingEnvironment(const std::string &file_name);
|
||||
~LuaScriptingEnvironment() override = default;
|
||||
|
||||
const ProfileProperties& GetProfileProperties() override;
|
||||
const ProfileProperties &GetProfileProperties() override;
|
||||
|
||||
LuaScriptingContext &GetLuaContext();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user