RoutingSummary
المدة والمسافة من نقطة الانطلاق في المسار إلى مكان في الردّ، وجزء ثانٍ من هذا المكان إلى الوجهة، إذا طُلب ذلك ملاحظة: تؤدي إضافة routingSummaries
في قناع الحقل بدون تضمين المَعلمة routingParameters.origin
أو المَعلمة searchAlongRouteParameters.polyline.encodedPolyline
في الطلب أيضًا إلى حدوث خطأ.
تمثيل JSON |
{
"legs": [
{
object (Leg )
}
],
"directionsUri": string
} |
الحقول |
legs[] |
object (Leg )
مراحل الرحلة عند احتساب مدة التنقّل والمسافة من نقطة انطلاق محدّدة، يحتوي legs على رحلة واحدة تحتوي على المدة والمسافة من نقطة الانطلاق إلى الوجهة. عند إجراء بحث على طول المسار، يحتوي legs على مرحلتين: الأولى من نقطة الانطلاق إلى المكان، والثانية من المكان إلى الوجهة.
|
directionsUri |
string
رابط لعرض الاتجاهات على "خرائط Google" باستخدام نقاط الالتقاء من ملخّص المسار المحدّد لا يمكن ضمان أن يكون المسار الذي تم إنشاؤه باستخدام هذا الرابط هو نفسه المسار المستخدَم لإنشاء ملخّص التوجيه. يستخدم الرابط المعلومات المقدَّمة في الطلب، من حقول تشمل routingParameters وsearchAlongRouteParameters عند الاقتضاء، لإنشاء رابط التوجيهات.
|
الساق
الرحلة هي جزء واحد من رحلة من موقع إلى آخر.
تمثيل JSON |
{
"duration": string,
"distanceMeters": integer
} |
الحقول |
duration |
string (Duration format)
المدة التي يستغرقها إكمال هذه المرحلة من الرحلة المدة بالثواني مع ما يصل إلى تسعة أرقام كسور، وتنتهي بـ "s ". مثال: "3.5s" .
|
distanceMeters |
integer
المسافة التي قطعتها هذه المرحلة من الرحلة
|
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2025-02-27 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-02-27 (حسب التوقيت العالمي المتفَّق عليه)"],[[["Routing Summary provides the duration and distance between an origin and a destination, or between an origin, a place, and a destination when searching along a route."],["It includes a directions URI for viewing the route on Google Maps."],["A Leg within the Routing Summary represents a portion of the journey, containing duration and distance in meters."],["When searching along a route, the `legs` field will contain two legs: one from the origin to the place and another from the place to the destination."]]],["The content details routing summary data, including journey legs and a directions link. A routing summary contains \"legs,\" with each leg representing a portion of a journey. Each `leg` provides `duration` (time to complete the leg) and `distanceMeters`. The `directionsUri` field provides a Google Maps link for directions. When searching along a route, the summary includes two legs, otherwise it only includes one. Including `routingSummaries` in a request requires including an `origin` or `encodedPolyline` parameter.\n"]]