現在、
Routes Preferred API は一部のお客様のみご利用いただけます。詳しくは、
営業担当者までお問い合わせください。
Vehicle Stop-over Qualifier を使用する
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
車両の停車地修飾子を使用すると、ウェイポイントが乗車または降車のための停車地として使用されることを指定できます。これにより、計算された経路が、乗車や降車に適さない道路(高速道路やトンネルなど)で始まったり、終点になったりすることを防ぐことができます。
使用例
地上の道路がトンネル内の道路を横切る状況について考えてみましょう。2 つの道路が交差する地点(地図に表示される地点)にウェイポイントを指定すると、生成されるルートは道路またはトンネルのいずれかで開始または終了します。トンネル内で乗車や降車のために停車できないため、問題が生じます。
ウェイポイントを乗車 / 降車に使用する場合は、vehicleStopover
フィールドを設定します。これにより、乗車 / 降車が可能な道路(つまり、地表の道路)でルートの始点または終点が確実に設定されます。
例
次の例は、vehicleStopover
修飾子を設定する方法を示しています。
{
"vehicleStopover": true,
"location": {
"latLng": {
"latitude":37.419734,
"longitude":-122.0827784
}
}
}
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2024-11-23 UTC。
[null,null,["最終更新日 2024-11-23 UTC。"],[[["\u003cp\u003eThe Vehicle Stop-over qualifier ensures routes start and end at locations suitable for pickups and drop-offs, avoiding unsuitable roads like highways or tunnels.\u003c/p\u003e\n"],["\u003cp\u003eBy setting \u003ccode\u003evehicleStopover\u003c/code\u003e to true for a waypoint, the calculated route will prioritize accessible roads for pickup and drop-off points.\u003c/p\u003e\n"],["\u003cp\u003eThis feature is particularly useful when a waypoint is located near restricted areas like tunnels, ensuring the route directs to a safe and accessible nearby road.\u003c/p\u003e\n"]]],["The `vehicleStopover` qualifier designates a waypoint for pick-up or drop-off. Setting `vehicleStopover` to `true` ensures the route begins or ends on a suitable road, avoiding unsuitable locations like highways or tunnels. Without this, a waypoint at an intersection (e.g., surface road over a tunnel) could lead to a route beginning or ending in the tunnel. The example demonstrates setting `vehicleStopover` to `true` within a waypoint's definition.\n"],null,["# Use the Vehicle Stop-over Qualifier\n\nYou can use the Vehicle Stop-over qualifier to specify that a waypoint is meant\nto be used for stopping for picking-up or dropping-off. This ensures that the\ncalculated route won't begin or end on a road that is unsuitable for pickup and\ndrop-off (for example, a highway or tunnel).\n\nExample use case\n----------------\n\nConsider the situation where a surface road crosses over a road inside a tunnel.\nIf you were to specify a waypoint located where the two roads intersect (as seen\non a map), then the resulting route would begin or end on either the surface\nroad or the tunnel. This presents a problem because you can't stop in tunnels to\nmake pickups or drop-offs.\n\nIf you want to use the waypoint for a pickup or drop-off, then you could set the\n`vehicleStopover` field, which ensures that the resulting route begins or ends\non a road that allows pickups and drop-offs (that is, on the surface road).\n\nExample\n-------\n\nThe following example demonstrates how to set the\n[`vehicleStopover`](/maps/documentation/routes_preferred/reference/rest/v1alpha/TopLevel/computeRoutes#Waypoint.FIELDS.vehicle_stopover) qualifier. \n\n```cplint\n{\n \"vehicleStopover\": true,\n \"location\": {\n \"latLng\": {\n \"latitude\":37.419734,\n \"longitude\":-122.0827784\n }\n }\n}\n```"]]