You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/profiles.md
+4-52Lines changed: 4 additions & 52 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -104,6 +104,7 @@ max_speed_for_map_matching | Float | Maximum vehicle speed to be as
104
104
max_turn_weight | Float | Maximum turn penalty weight
105
105
force_split_edges | Boolean | True value forces a split of forward and backward edges of extracted ways and guarantees that `process_segment` will be called for all segments (default `false`)
106
106
107
+
107
108
The following additional global properties can be set in the hash you return in the `setup` function:
108
109
109
110
Attribute | Type | Notes
@@ -113,6 +114,7 @@ excludable | Sequence of Sets | Determines which class
113
114
classes | Sequence | Determines the allowed classes that can be referenced using `{forward,backward}_classes` on the way in the `process_way` function.
114
115
restrictions | Sequence | Determines which turn restrictions will be used for this profile.
115
116
suffix_list | Set | List of name suffixes needed for determining if "Highway 101 NW" the same road as "Highway 101 ES".
117
+
relation_types | Sequence | Determines wich relations should be cached for processing in this profile. It contains relations types
Process an OSM node to determine whether this node is a barrier or can be passed and whether passing it incurs a delay.
@@ -122,7 +124,7 @@ Argument | Description
122
124
profile | The configuration table you returned in `setup`.
123
125
node | The input node to process (read-only).
124
126
result | The output that you will modify.
125
-
relations| The list of relation attributes passed from `process_relation` function for this node.
127
+
relations| Storage of relations to access relations, where `node` is a member.
126
128
127
129
The following attributes can be set on `result`:
128
130
@@ -139,7 +141,7 @@ Argument | Description
139
141
profile | The configuration table you returned in `setup`.
140
142
node | The input way to process (read-only).
141
143
result | The output that you will modify.
142
-
relations| The list of relation attributes passed from `process_relation` function for this way.
144
+
relations| Storage of relations to access relations, where `way` is a member.
143
145
144
146
Importantly it will set `result.forward_mode` and `result.backward_mode` to indicate the travel mode in each direction, as well as set `result.forward_speed` and `result.backward_speed` to integer values representing the speed for traversing the way.
145
147
@@ -179,56 +181,6 @@ road_classification.road_priority_class | Enum | Guidance: order in priority
179
181
road_classification.may_be_ignored | Boolean | Guidance: way is non-highway
180
182
road_classification.num_lanes | Unsigned | Guidance: total number of lanes in way
181
183
182
-
### process_relation(profile, relation, result)
183
-
184
-
Supported since API **version 3**.
185
-
186
-
Given an OpenStreetMap relation, the `process_relation` function should setup values into result structure.
0 commit comments