From 8e100ea1a019bff099cc9b8b15c5b4c0da0d2f35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96mer=20Faruk=20=C3=96zdemir?= <44067394+FarukOzderim@users.noreply.github.com> Date: Sat, 4 Sep 2021 14:33:10 +0300 Subject: [PATCH] Update api.md (#6054) * Update api.md alternatives_count was missing in this document, Copied from here: https://github.com/Project-OSRM/osrm-backend/blob/master/docs/http.md#waypoint-object --- docs/nodejs/api.md | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/nodejs/api.md b/docs/nodejs/api.md index 9bff3ada8c6..72b463f0bab 100644 --- a/docs/nodejs/api.md +++ b/docs/nodejs/api.md @@ -244,9 +244,16 @@ osrm.match(options, function(err, response) { Returns **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** containing `tracepoints` and `matchings`. **`tracepoints`** Array of [`Ẁaypoint`](#waypoint) objects representing all points of the trace in order. If the trace point was ommited by map matching because it is an outlier, the entry will be null. - Each `Waypoint` object includes two additional properties, 1) `matchings_index`: Index to the - [`Route`](#route) object in matchings the sub-trace was matched to, 2) `waypoint_index`: Index of + Each `Waypoint` object has the following additional properties, + + 1) `matchings_index`: Index to the + [`Route`](#route) object in matchings the sub-trace was matched to, + + 2) `waypoint_index`: Index of the waypoint inside the matched route. + + 3) `alternatives_count`: Number of probable alternative matchings for this trace point. A value of zero indicate that this point was matched unambiguously. Split the trace at these points for incremental map matching. + **`matchings`** is an array of [`Route`](#route) objects that assemble the trace. Each `Route` object has an additional `confidence` property, which is the confidence of the matching. float value between `0` and `1`. `1` is very confident that the matching is correct.