নির্দেশ সার্ভিস ক্লাস
google.maps . DirectionsService
ক্লাস
দুই বা ততোধিক স্থানের মধ্যে দিকনির্দেশ কম্পিউট করার জন্য একটি পরিষেবা।
const {DirectionsService} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
কনস্ট্রাক্টর | |
---|---|
DirectionsService | DirectionsService() পরামিতি: কোনোটিই নয় একটি DirectionsService একটি নতুন দৃষ্টান্ত তৈরি করে যা Google সার্ভারগুলিতে দিকনির্দেশের প্রশ্ন পাঠায়৷ |
পদ্ধতি | |
---|---|
route | route(request[, callback]) পরামিতি:
রিটার্ন মান: Promise < DirectionsResult > একটি দিকনির্দেশ অনুসন্ধান অনুরোধ ইস্যু করুন। |
নির্দেশাবলী অনুরোধ ইন্টারফেস
google.maps . DirectionsRequest
ইন্টারফেস
একটি দিকনির্দেশের প্রশ্ন DirectionsService
এ পাঠানো হবে।
বৈশিষ্ট্য | |
---|---|
destination | প্রকার: string| LatLng | Place | LatLngLiteral গন্তব্যের অবস্থান। এটি জিওকোড করার জন্য একটি স্ট্রিং, বা একটি LatLng , বা একটি Place হিসাবে নির্দিষ্ট করা যেতে পারে। প্রয়োজন। |
origin | প্রকার: string| LatLng | Place | LatLngLiteral উৎপত্তির অবস্থান। এটি জিওকোড করার জন্য একটি স্ট্রিং, বা একটি LatLng , বা একটি Place হিসাবে নির্দিষ্ট করা যেতে পারে। প্রয়োজন। |
travelMode | প্রকার: TravelMode রাউটিং এর প্রকার অনুরোধ করা হয়েছে। প্রয়োজন। |
avoidFerries optional | প্রকার: boolean optional true হলে, যেখানে সম্ভব ফেরি এড়াতে দিকনির্দেশ পরিষেবাকে নির্দেশ দেয়৷ ঐচ্ছিক। |
avoidHighways optional | প্রকার: boolean optional true হলে, যেখানে সম্ভব হাইওয়েগুলি এড়াতে নির্দেশ পরিষেবাকে নির্দেশ দেয়৷ ঐচ্ছিক। |
avoidTolls optional | প্রকার: boolean optional true হলে, যেখানে সম্ভব টোল রাস্তা এড়াতে দিকনির্দেশ পরিষেবাকে নির্দেশ দেয়৷ ঐচ্ছিক। |
drivingOptions optional | প্রকার: DrivingOptions optional সেটিংস যা শুধুমাত্র অনুরোধের ক্ষেত্রে প্রযোজ্য যেখানে travelMode DRIVING । এই বস্তুটি অন্যান্য ভ্রমণ মোডের জন্য কোন প্রভাব ফেলবে না। |
language optional | প্রকার: string optional যখন সম্ভব তখন যে ভাষার ফলাফল দেওয়া উচিত তার জন্য একটি ভাষা শনাক্তকারী। সমর্থিত ভাষার তালিকা দেখুন। |
optimizeWaypoints optional | প্রকার: boolean optional যদি true তে সেট করা হয়, তাহলে রুটের সামগ্রিক খরচ কমানোর জন্য DirectionsService সরবরাহ করা মধ্যবর্তী ওয়েপয়েন্টগুলিকে পুনরায় অর্ডার করার চেষ্টা করবে। যদি ওয়েপয়েন্টগুলি অপ্টিমাইজ করা হয়, নতুন অর্ডার নির্ধারণ করতে প্রতিক্রিয়াতে DirectionsRoute.waypoint_order পরিদর্শন করুন। |
provideRouteAlternatives optional | প্রকার: boolean optional রুট বিকল্প প্রদান করা উচিত কি না. ঐচ্ছিক। |
region optional | প্রকার: string optional জিওকোডিং অনুরোধের জন্য একটি পক্ষপাত হিসাবে ব্যবহৃত অঞ্চল কোড। অঞ্চল কোড একটি ccTLD ("টপ-লেভেল ডোমেন") দুই-অক্ষরের মান গ্রহণ করে। কিছু উল্লেখযোগ্য ব্যতিক্রম সহ বেশিরভাগ ccTLD কোডগুলি ISO 3166-1 কোডগুলির সাথে অভিন্ন। উদাহরণস্বরূপ, যুক্তরাজ্যের ccTLD হল "uk" ( .co.uk ) যেখানে এর ISO 3166-1 কোড হল "gb" (প্রযুক্তিগতভাবে "দ্য ইউনাইটেড কিংডম অফ গ্রেট ব্রিটেন এবং উত্তর আয়ারল্যান্ড" এর সত্তার জন্য)। |
transitOptions optional | প্রকার: TransitOptions optional সেটিংস যা শুধুমাত্র অনুরোধের ক্ষেত্রে প্রযোজ্য যেখানে travelMode TRANSIT হয়। এই বস্তুটি অন্যান্য ভ্রমণ মোডের জন্য কোন প্রভাব ফেলবে না। |
unitSystem optional | প্রকার: UnitSystem optional ডিফল্ট: মূল দেশে ব্যবহৃত ইউনিট সিস্টেম। দূরত্ব প্রদর্শন করার সময় ব্যবহার করার জন্য পছন্দের ইউনিট সিস্টেম। |
waypoints optional | প্রকার: Array < DirectionsWaypoint > optional মধ্যবর্তী পথপয়েন্টের অ্যারে। এই অ্যারের প্রতিটি ওয়েপয়েন্টের মাধ্যমে উৎপত্তি থেকে গন্তব্য পর্যন্ত দিকনির্দেশ গণনা করা হয়। অনুমোদিত সর্বাধিক সংখ্যক ওয়েপয়েন্টের জন্য বিকাশকারীর নির্দেশিকা দেখুন। ট্রানজিট দিকনির্দেশের জন্য ওয়েপয়েন্ট সমর্থিত নয়। ঐচ্ছিক। |
দিকনির্দেশ স্ট্যাটাস ধ্রুবক
google.maps . DirectionsStatus
ধ্রুবক
একটি কল টু route()
সম্পূর্ণ হওয়ার পরে DirectionsService
দ্বারা স্ট্যাটাস ফেরত দেওয়া হয়। মান দ্বারা, বা ধ্রুবকের নাম ব্যবহার করে এইগুলি নির্দিষ্ট করুন। উদাহরণস্বরূপ, 'OK'
বা google.maps.DirectionsStatus.OK
।
const {DirectionsStatus} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
INVALID_REQUEST | প্রদত্ত DirectionsRequest অবৈধ ছিল৷ |
MAX_WAYPOINTS_EXCEEDED | DirectionsRequest এ অনেকগুলো DirectionsWaypoint s প্রদান করা হয়েছে। অনুমোদিত সর্বাধিক সংখ্যক ওয়েপয়েন্টের জন্য বিকাশকারীর নির্দেশিকা দেখুন। |
NOT_FOUND | উত্স, গন্তব্য, বা পথপয়েন্টগুলির মধ্যে অন্তত একটি জিওকোড করা যায়নি৷ |
OK | প্রতিক্রিয়াটিতে একটি বৈধ DirectionsResult রয়েছে। |
OVER_QUERY_LIMIT | ওয়েবপৃষ্ঠাটি খুব অল্প সময়ের মধ্যে অনুরোধের সীমা অতিক্রম করেছে৷ |
REQUEST_DENIED | ওয়েবপৃষ্ঠাটি দিকনির্দেশ পরিষেবা ব্যবহার করার অনুমতি নেই৷ |
UNKNOWN_ERROR | একটি সার্ভার ত্রুটির কারণে একটি দিকনির্দেশের অনুরোধ প্রক্রিয়া করা যায়নি৷ আপনি আবার চেষ্টা করলে অনুরোধ সফল হতে পারে। |
ZERO_RESULTS | উৎপত্তিস্থল এবং গন্তব্যের মধ্যে কোনো পথ খুঁজে পাওয়া যায়নি। |
দিকনির্দেশ ফলাফল ইন্টারফেস
google.maps . DirectionsResult
ইন্টারফেস
দিকনির্দেশের প্রতিক্রিয়া দিকনির্দেশ সার্ভার থেকে পুনরুদ্ধার করা হয়েছে। আপনি একটি DirectionsRenderer
ব্যবহার করে এইগুলিকে রেন্ডার করতে পারেন বা এই বস্তুটিকে পার্স করতে পারেন এবং নিজেই রেন্ডার করতে পারেন৷ Google মানচিত্র প্ল্যাটফর্ম পরিষেবার শর্তাবলীতে উল্লিখিত হিসাবে আপনাকে সতর্কতা এবং কপিরাইট প্রদর্শন করতে হবে৷ মনে রাখবেন যে যদিও এই ফলাফলটি "JSON-এর মতো" তবে এটি কঠোরভাবে JSON নয়, কারণ এটি পরোক্ষভাবে LatLng
বস্তুগুলিকে অন্তর্ভুক্ত করে৷
বৈশিষ্ট্য | |
---|---|
routes | প্রকার: Array < DirectionsRoute > DirectionsRoute s এর একটি অ্যারে, যার প্রতিটিতে পা এবং ধাপগুলি সম্পর্কে তথ্য রয়েছে যা এটি তৈরি করা হয়েছে। শুধুমাত্র একটি রুট থাকবে যদি না DirectionsRequest টি প্রোভাইড provideRouteAlternatives true সেট করা হয়। |
available_travel_modes optional | প্রকার: Array < TravelMode > optional উপলব্ধ ভ্রমণ মোড একটি অ্যারে রয়েছে. এই ক্ষেত্রটি ফেরত দেওয়া হয় যখন একটি অনুরোধ একটি ভ্রমণ মোড নির্দিষ্ট করে এবং কোন ফলাফল পায় না। অ্যারেতে প্রদত্ত ওয়েপয়েন্টের সেটের দেশগুলিতে উপলব্ধ ভ্রমণ মোড রয়েছে। এক বা একাধিক ওয়েপয়েন্ট 'ওয়েপয়েন্টের মাধ্যমে' হলে এই ক্ষেত্রটি ফেরত দেওয়া হয় না। |
geocoded_waypoints optional | প্রকার: Array < DirectionsGeocodedWaypoint > optional DirectionsGeocodedWaypoint একটি অ্যারে জিওকোডেড ওয়েপয়েন্ট, যার প্রতিটিতে উৎপত্তি, গন্তব্য এবং পথপয়েন্টের জিওকোডিং সম্পর্কে তথ্য রয়েছে। |
দিকনির্দেশ রেন্ডারার ক্লাস
google.maps . DirectionsRenderer
ক্লাস
DirectionsService
থেকে প্রাপ্ত দিকনির্দেশ রেন্ডার করে।
এই ক্লাস MVCObject
প্রসারিত.
const {DirectionsRenderer} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
কনস্ট্রাক্টর | |
---|---|
DirectionsRenderer | DirectionsRenderer([opts]) পরামিতি:
প্রদত্ত বিকল্পগুলির সাথে রেন্ডারার তৈরি করে। নির্দেশাবলী একটি মানচিত্রে (ভিজ্যুয়াল ওভারলে হিসাবে) বা অতিরিক্তভাবে একটি <div> প্যানেলে (পাঠ্য নির্দেশাবলী হিসাবে) রেন্ডার করা যেতে পারে। |
পদ্ধতি | |
---|---|
getDirections | getDirections() পরামিতি: কোনোটিই নয় রিটার্ন মান: DirectionsResult রেন্ডারারের বর্তমান নির্দেশের সেট প্রদান করে। |
getMap | getMap() পরামিতি: কোনোটিই নয় রিটার্ন মান: Map যে মানচিত্রটিতে DirectionsResult রেন্ডার করা হয়েছে সেটি দেখায়। |
getPanel | getPanel() পরামিতি: কোনোটিই নয় রিটার্ন মান: HTMLElement |null <div> প্যানেলটি ফেরত দেয় যেখানে DirectionsResult রেন্ডার করা হয়। |
getRouteIndex | getRouteIndex() পরামিতি: কোনোটিই নয় রিটার্ন মান: number এই DirectionsRenderer অবজেক্ট দ্বারা ব্যবহৃত বর্তমান (শূন্য-ভিত্তিক) রুট সূচী প্রদান করে। |
setDirections | setDirections(directions) পরামিতি:
রিটার্ন মান: কোনটিই নয় DirectionsService থেকে ফলাফল ব্যবহার করতে রেন্ডারার সেট করুন। এই পদ্ধতিতে নির্দেশাবলীর একটি বৈধ সেট সেট করা রেন্ডারারের মনোনীত মানচিত্র এবং প্যানেলে দিকনির্দেশগুলি প্রদর্শন করবে৷ |
setMap | setMap(map) পরামিতি:
রিটার্ন মান: কোনটিই নয় এই পদ্ধতিটি মানচিত্রটি নির্দিষ্ট করে যা নির্দেশাবলী রেন্ডার করা হবে। মানচিত্র থেকে দিকনির্দেশ সরাতে null পাস করুন। |
setOptions | setOptions(options) পরামিতি:
রিটার্ন মান: কোনটিই নয় আরম্ভ করার পরে এই DirectionsRenderer বিকল্প সেটিংস পরিবর্তন করুন। |
setPanel | setPanel(panel) পরামিতি:
রিটার্ন মান: কোনটিই নয় এই পদ্ধতিটি একটি <div> এ নির্দেশনা রেন্ডার করে। প্যানেল থেকে বিষয়বস্তু সরাতে null পাস করুন। |
setRouteIndex | setRouteIndex(routeIndex) পরামিতি:
রিটার্ন মান: কোনটিই নয় রেন্ডার করার জন্য DirectionsResult অবজেক্টে রুটের (শূন্য-ভিত্তিক) সূচক সেট করুন। ডিফল্টরূপে, অ্যারের প্রথম রুটটি রেন্ডার করা হবে। |
উত্তরাধিকারসূত্রে পাওয়া: addListener , bindTo , get , notify , set , setValues , unbind , unbindAll |
ঘটনা | |
---|---|
directions_changed | function() যুক্তি: কোনটিই না রেন্ডার করা দিকনির্দেশ পরিবর্তিত হলে এই ইভেন্টটি চালু করা হয়, হয় যখন একটি নতুন DirectionsResult সেট করা হয় বা ব্যবহারকারী যখন দিকনির্দেশের পথে পরিবর্তনটি টেনে আনা শেষ করে। |
দিকনির্দেশ রেন্ডারার বিকল্প ইন্টারফেস
google.maps . DirectionsRendererOptions
ইন্টারফেস
এই অবজেক্টটি এমন বৈশিষ্ট্যগুলিকে সংজ্ঞায়িত করে যা একটি DirectionsRenderer
অবজেক্টে সেট করা যেতে পারে।
বৈশিষ্ট্য | |
---|---|
directions optional | প্রকার: DirectionsResult optional ম্যাপে এবং/অথবা একটি <div> প্যানেলে দেখানোর দিকনির্দেশ, DirectionsService থেকে একটি DirectionsResult অবজেক্ট হিসেবে পুনরুদ্ধার করা হয়েছে। |
draggable optional | প্রকার: boolean optional true হলে, ব্যবহারকারীকে এই DirectionsRenderer দ্বারা রেন্ডার করা রুটের পাথগুলিকে টেনে আনতে এবং পরিবর্তন করার অনুমতি দেয়। |
hideRouteList optional | প্রকার: boolean optional ডিফল্ট: false এই বৈশিষ্ট্যটি নির্দেশ করে যে রেন্ডারার নির্দেশ প্যানেলে দেখানো রুটের একটি ব্যবহারকারী-নির্বাচনযোগ্য তালিকা প্রদান করবে কিনা। |
infoWindow optional | প্রকার: InfoWindow optional InfoWindow যেখানে একটি মার্কার ক্লিক করা হলে পাঠ্য তথ্য রেন্ডার করা হয়। বিদ্যমান তথ্য উইন্ডো বিষয়বস্তু ওভাররাইট করা হবে এবং এর অবস্থান সরানো হবে। যদি কোন তথ্য উইন্ডো নির্দিষ্ট করা না থাকে, DirectionsRenderer তার নিজস্ব তথ্য উইন্ডো তৈরি করবে এবং ব্যবহার করবে। এই সম্পত্তি উপেক্ষা করা হবে যদি suppressInfoWindows true সেট করা হয়। |
map optional | প্রকার: Map optional যে মানচিত্রে দিকনির্দেশ প্রদর্শন করতে হবে। |
markerOptions optional | প্রকার: MarkerOptions optional মার্কার জন্য বিকল্প. DirectionsRenderer দ্বারা রেন্ডার করা সমস্ত মার্কার এই বিকল্পগুলি ব্যবহার করবে৷ |
panel optional | প্রকার: HTMLElement optional <div> যেটিতে দিকনির্দেশের ধাপগুলি প্রদর্শন করা হবে। |
polylineOptions optional | প্রকার: PolylineOptions optional পলিলাইনগুলির জন্য বিকল্পগুলি। DirectionsRenderer দ্বারা রেন্ডার করা সমস্ত পলিলাইন এই বিকল্পগুলি ব্যবহার করবে। |
preserveViewport optional | প্রকার: boolean optional ডিফল্ট: false যদি এই বিকল্পটি true সেট করা থাকে বা মানচিত্রের কেন্দ্র এবং জুম কখনই সেট করা না থাকে, ইনপুট মানচিত্রটি কেন্দ্রীভূত হয় এবং এই নির্দেশের সেটের বাউন্ডিং বাক্সে জুম করা হয়। |
routeIndex optional | প্রকার: number optional DirectionsResult অবজেক্টের মধ্যে রুটের সূচী। ডিফল্ট মান 0। |
suppressBicyclingLayer optional | প্রকার: boolean optional যখন সাইকেল চালানোর দিকনির্দেশ অনুরোধ করা হয় তখন BicyclingLayer রেন্ডারিং দমন করুন। |
suppressInfoWindows optional | প্রকার: boolean optional তথ্য উইন্ডোর রেন্ডারিং দমন করুন। |
suppressMarkers optional | প্রকার: boolean optional মার্কার রেন্ডারিং দমন করুন. |
suppressPolylines optional | প্রকার: boolean optional পলিলাইনের রেন্ডারিং দমন করুন। |
দিকনির্দেশ ওয়েপয়েন্ট ইন্টারফেস
google.maps . DirectionsWaypoint
ইন্টারফেস
একটি DirectionsWaypoint
উত্স এবং গন্তব্যের মধ্যে একটি অবস্থান উপস্থাপন করে যার মাধ্যমে ট্রিপটি রুট করা উচিত।
বৈশিষ্ট্য | |
---|---|
location optional | প্রকার: string| LatLng | LatLngLiteral | Place optional ওয়েপয়েন্ট অবস্থান। একটি ঠিকানা স্ট্রিং, একটি LatLng , বা একটি Place হতে পারে। ঐচ্ছিক। |
stopover optional | প্রকার: boolean optional ডিফল্ট: true true হলে, নির্দেশ করে যে এই ওয়েপয়েন্টটি উৎপত্তি এবং গন্তব্যের মধ্যে একটি স্টপ। এটি রুটটিকে দুটি পায়ে বিভক্ত করার প্রভাব রয়েছে। false হলে, নির্দেশ করে যে এই ওয়েপয়েন্টের মধ্য দিয়ে যাওয়ার জন্য রুটটি পক্ষপাতদুষ্ট হওয়া উচিত, কিন্তু দুটি পায়ে বিভক্ত নয়। আপনি যদি একটি মানচিত্রে ব্যবহারকারীর ওয়েপয়েন্ট টেনে নেওয়ার প্রতিক্রিয়া হিসাবে একটি রুট তৈরি করতে চান তবে এটি কার্যকর। |
দিকনির্দেশ জিওকোডেড ওয়েপয়েন্ট ইন্টারফেস
google.maps . DirectionsGeocodedWaypoint
ইন্টারফেস
একটি একক জিওকোডেড ওয়েপয়েন্ট।
বৈশিষ্ট্য | |
---|---|
partial_match optional | প্রকার: boolean optional জিওকোডার আসল ওয়েপয়েন্টের জন্য সঠিক মিল ফেরত দেয়নি কিনা, যদিও এটি অনুরোধ করা ঠিকানার অংশের সাথে মেলে। |
place_id optional | প্রকার: string optional ওয়েপয়েন্টের সাথে সংশ্লিষ্ট স্থান আইডি। প্লেস আইডিগুলি অনন্যভাবে Google Places ডাটাবেসে এবং Google মানচিত্রে একটি স্থান চিহ্নিত করে৷ Places API ডেভেলপার গাইডে Place ID সম্পর্কে আরও জানুন। |
types optional | প্রকার: Array <string> optional প্রত্যাবর্তিত জিওকোডেড উপাদানের ধরন নির্দেশ করে স্ট্রিংগুলির একটি অ্যারে৷ সম্ভাব্য স্ট্রিংগুলির একটি তালিকার জন্য, বিকাশকারীর গাইডের ঠিকানা উপাদান প্রকার বিভাগটি পড়ুন। |
দিকনির্দেশ রুট ইন্টারফেস
google.maps . DirectionsRoute
ইন্টারফেস
একটি একক রুট যেখানে একটি DirectionsResult
পাগুলির একটি সেট রয়েছে। মনে রাখবেন যে যদিও এই বস্তুটি "JSON-এর মতো", এটি কঠোরভাবে JSON নয়, কারণ এটি প্রত্যক্ষ এবং পরোক্ষভাবে LatLng
অবজেক্টগুলিকে অন্তর্ভুক্ত করে৷
বৈশিষ্ট্য | |
---|---|
bounds | প্রকার: LatLngBounds এই রুট জন্য সীমানা. |
copyrights | প্রকার: string এই রুটের জন্য কপিরাইট টেক্সট প্রদর্শিত হবে। |
legs | প্রকার: Array < DirectionsLeg > DirectionsLeg s-এর একটি অ্যারে, যার প্রতিটিতে এটি তৈরি করা ধাপগুলির সম্পর্কে তথ্য রয়েছে। প্রতিটি স্টপওভার ওয়েপয়েন্ট বা নির্দিষ্ট গন্তব্যের জন্য একটি পা থাকবে। সুতরাং স্টপওভার ওয়েপয়েন্ট ছাড়া একটি রুটে একটি DirectionsLeg লেগ থাকবে এবং একটি স্টপওভার ওয়েপয়েন্ট সহ একটি রুটে দুটি থাকবে। |
overview_path | LatLng s এর একটি অ্যারে এই রুটের পুরো কোর্সের প্রতিনিধিত্ব করে। যেখানে অল্প সংখ্যক শীর্ষবিন্দুর প্রয়োজন হয় (যেমন স্ট্যাটিক মানচিত্র API URL গুলি) প্রেক্ষাপটে উপযোগী করার জন্য পথটিকে সরলীকৃত করা হয়েছে। |
overview_polyline | প্রকার: string overview_path এ রুটের একটি এনকোড করা পলিলাইন উপস্থাপনা । এই পলিলাইনটি ফলাফলের দিকগুলির একটি আনুমানিক (মসৃণ) পথ। |
summary | প্রকার: string রুটটির জন্য একটি সংক্ষিপ্ত পাঠ্য বিবরণ রয়েছে, নামকরণের জন্য উপযুক্ত এবং বিকল্পগুলি থেকে রুটটিকে দ্ব্যর্থহীন করে তোলার জন্য উপযুক্ত৷ |
warnings | প্রকার: Array <string> এই দিকনির্দেশগুলি দেখানোর সময় সতর্কতাগুলি প্রদর্শিত হবে৷ |
waypoint_order | প্রকার: Array <number> যদি optimizeWaypoints true তে সেট করা হয়, তাহলে এই ক্ষেত্রটিতে ইনপুট ওয়েপয়েন্টের পুনঃক্রমানুবর্তিতা থাকবে। উদাহরণস্বরূপ, যদি ইনপুট ছিল:মূল: লস অ্যাঞ্জেলেস ওয়েপয়েন্ট: ডালাস, ব্যাঙ্গর, ফিনিক্স গন্তব্য: নিউইয়র্ক এবং অপ্টিমাইজড আউটপুট নিম্নরূপ আদেশ করা হয়েছিল: মূল: লস অ্যাঞ্জেলেস ওয়েপয়েন্ট: ফিনিক্স, ডালাস, ব্যাঙ্গর গন্তব্য: নিউইয়র্ক তাহলে এই ক্ষেত্রটি একটি Array হবে যেখানে [2, 0, 1] মান রয়েছে। মনে রাখবেন যে ওয়েপয়েন্টের সংখ্যা শূন্য-ভিত্তিক।যদি কোনো ইনপুট ওয়েপয়েন্টের stopover false সেট করা থাকে, তাহলে এই ক্ষেত্রটি খালি থাকবে, যেহেতু রুট অপ্টিমাইজেশান এই ধরনের প্রশ্নের জন্য উপলব্ধ নয়। |
fare optional | প্রকার: TransitFare optional পুরো ট্রানজিট ট্রিপের মোট ভাড়া। শুধুমাত্র ট্রানজিট অনুরোধের ক্ষেত্রে প্রযোজ্য। |
দিকনির্দেশ লেগ ইন্টারফেস
google.maps . DirectionsLeg
ইন্টারফেস
একটি একক পা একটি DirectionsResult
ধাপগুলির একটি সেট নিয়ে গঠিত। পায়ের কিছু ক্ষেত্র সব অনুরোধের জন্য ফেরত নাও যেতে পারে। মনে রাখবেন যে এই ফলাফলটি "JSON-এর মতো" হলেও এটি কঠোরভাবে JSON নয়, কারণ এটি প্রত্যক্ষ এবং পরোক্ষভাবে LatLng
অবজেক্টগুলিকে অন্তর্ভুক্ত করে।
বৈশিষ্ট্য | |
---|---|
end_address | প্রকার: string এই পায়ের গন্তব্যের ঠিকানা। এই বিষয়বস্তু যেমন আছে পড়া বোঝানো হয়. ফরম্যাট করা ঠিকানা প্রোগ্রাম্যাটিকভাবে পার্স করবেন না। |
end_location | প্রকার: LatLng DirectionsService শুরু এবং শেষ অবস্থানে নিকটতম পরিবহন বিকল্প (সাধারণত একটি রাস্তা) ব্যবহার করে অবস্থানের মধ্যে দিকনির্দেশ গণনা করে। end_location প্রকৃত জিওকোডেড গন্তব্য নির্দেশ করে, যা শেষ ধাপের end_location থেকে ভিন্ন হতে পারে যদি, উদাহরণস্বরূপ, রাস্তাটি এই পায়ের গন্তব্যের কাছাকাছি না হয়। |
start_address | প্রকার: string এই পায়ের উৎপত্তির ঠিকানা। এই বিষয়বস্তু যেমন আছে পড়া বোঝানো হয়. ফরম্যাট করা ঠিকানা প্রোগ্রাম্যাটিকভাবে পার্স করবেন না। |
start_location | প্রকার: LatLng DirectionsService শুরু এবং শেষ অবস্থানে নিকটতম পরিবহন বিকল্প (সাধারণত একটি রাস্তা) ব্যবহার করে অবস্থানের মধ্যে দিকনির্দেশ গণনা করে। start_location প্রকৃত জিওকোডেড উৎপত্তি নির্দেশ করে, যা প্রথম ধাপের start_location থেকে ভিন্ন হতে পারে যদি, উদাহরণস্বরূপ, রাস্তাটি এই পায়ের উৎসের কাছাকাছি না হয়। |
steps | প্রকার: Array < DirectionsStep > DirectionsStep s এর একটি অ্যারে, যার প্রতিটিতে এই পায়ের পৃথক পদক্ষেপ সম্পর্কে তথ্য রয়েছে। |
traffic_speed_entry | প্রকার: Array <?> পা বরাবর ট্রাফিক গতি সম্পর্কে তথ্য. |
via_waypoints | এই লেগ বরাবর নন-স্টপওভার ওয়েপয়েন্টের একটি অ্যারে, যা মূল অনুরোধে নির্দিষ্ট করা হয়েছিল। বিকল্প রুটে অপ্রচলিত । সংস্করণ 3.27 হবে API-এর শেষ সংস্করণ যা বিকল্প রুটে অতিরিক্ত টেনে আনা যায় এমন দিকনির্দেশ বাস্তবায়নের জন্য দিকনির্দেশ পরিষেবা ব্যবহার করার সময়, বিকল্প রুটের টেনে আনা অক্ষম করার পরামর্শ দেওয়া হয়। শুধুমাত্র প্রধান রুট টেনে আনা উচিত। ব্যবহারকারীরা মূল রুটটি টেনে আনতে পারবেন যতক্ষণ না এটি একটি বিকল্প রুটের সাথে মেলে। |
arrival_time optional | প্রকার: Time optional এই পায়ের জন্য একটি আনুমানিক আগমন সময়. শুধুমাত্র ট্রানজিট অনুরোধের জন্য প্রযোজ্য। |
departure_time optional | প্রকার: Time optional এই পায়ের জন্য একটি আনুমানিক প্রস্থান সময়. শুধুমাত্র ট্রানজিট অনুরোধের জন্য প্রযোজ্য। |
distance optional | প্রকার: Distance optional এই পা দ্বারা আচ্ছাদিত মোট দূরত্ব. এই সম্পত্তি অনির্ধারিত হতে পারে কারণ দূরত্ব অজানা হতে পারে। |
duration optional | প্রকার: Duration optional এই পায়ের মোট সময়কাল। এই সম্পত্তি undefined হতে পারে কারণ সময়কাল অজানা হতে পারে। |
duration_in_traffic optional | প্রকার: Duration optional trafficModel সম্পত্তি দ্বারা নির্দেশিত ট্রাফিক পরিস্থিতি বিবেচনা করে এই পায়ের মোট সময়কাল। এই সম্পত্তি undefined হতে পারে কারণ সময়কাল অজানা হতে পারে। |
দিকনির্দেশ স্টেপ ইন্টারফেস
google.maps . DirectionsStep
ইন্টারফেস
একটি একক DirectionsStep
একটি DirectionsResult
ধাপ। কিছু ক্ষেত্র undefined
হতে পারে। মনে রাখবেন যে এই বস্তুটি "JSON-এর মত" হলেও এটি কঠোরভাবে JSON নয়, কারণ এতে সরাসরি LatLng
অবজেক্ট রয়েছে।
বৈশিষ্ট্য | |
---|---|
encoded_lat_lngs | প্রকার: string ধাপের একটি এনকোডেড পলিলাইন উপস্থাপনা । এটি ধাপের একটি আনুমানিক (মসৃণ) পথ। |
end_location | প্রকার: LatLng এই ধাপের শেষ অবস্থান। |
end_point | প্রকার: LatLng এই ধাপের শেষ অবস্থান। |
instructions | প্রকার: string এই পদক্ষেপের জন্য নির্দেশাবলী। |
lat_lngs | LatLng s এর একটি ক্রম এই ধাপের কোর্স বর্ণনা করে। এটি ধাপের একটি আনুমানিক (মসৃণ) পথ। |
maneuver | প্রকার: string বর্তমান পদক্ষেপের জন্য যে পদক্ষেপ নিতে হবে তা রয়েছে ( turn-left , merge , straight , ইত্যাদি)। মান পরিবর্তন সাপেক্ষে, এবং নতুন মান পূর্ব বিজ্ঞপ্তি ছাড়াই চালু করা যেতে পারে. |
path | LatLng s এর একটি ক্রম এই ধাপের কোর্স বর্ণনা করে। এটি ধাপের একটি আনুমানিক (মসৃণ) পথ। |
start_location | প্রকার: LatLng এই ধাপের শুরুর অবস্থান। |
start_point | প্রকার: LatLng এই ধাপের শুরুর অবস্থান। |
travel_mode | প্রকার: TravelMode এই ধাপে ব্যবহৃত ভ্রমণের মোড। |
distance optional | প্রকার: Distance optional এই পদক্ষেপ দ্বারা আচ্ছাদিত দূরত্ব. এই সম্পত্তি undefined হতে পারে কারণ দূরত্ব অজানা হতে পারে। |
duration optional | প্রকার: Duration optional সেকেন্ডে এবং পাঠ্য আকারে এই পদক্ষেপটি সম্পাদন করার জন্য সাধারণ সময় প্রয়োজন। এই সম্পত্তি undefined হতে পারে কারণ সময়কাল অজানা হতে পারে। |
polyline optional polyline optional | প্রকার: DirectionsPolyline optional একটি একক সম্পত্তি, 'পয়েন্ট' সহ একটি বস্তু রয়েছে, যা ধাপের একটি এনকোডেড পলিলাইন উপস্থাপনা ধারণ করে। এই পলিলাইনটি ধাপের একটি আনুমানিক (মসৃণ) পথ। |
steps optional | প্রকার: Array < DirectionsStep > optional এই ধাপের উপ-পদক্ষেপ। ট্রানজিট রুটের অ-ট্রানজিট বিভাগের জন্য নির্দিষ্ট করা হয়েছে। |
transit optional | প্রকার: TransitDetails optional এই ধাপ সম্পর্কে ট্রানজিট-নির্দিষ্ট বিবরণ। এই ধাপের ভ্রমণ মোড TRANSIT না হলে এই সম্পত্তিটি অনির্ধারিত হবে। |
transit_details optional | প্রকার: TransitDetails optional ভ্রমণ মোড TRANSIT হলে এই ধাপের সাথে সম্পর্কিত বিশদ বিবরণ। |
দিকনির্দেশ পলিলাইন ইন্টারফেস
google.maps . DirectionsPolyline
ইন্টারফেস
একটি DirectionsStep
পলিলাইন বর্ণনা করার জন্য একটি points
বৈশিষ্ট্য ধারণকারী একটি বস্তু।
বৈশিষ্ট্য | |
---|---|
points | প্রকার: string একটি এনকোডেড পলিলাইন । |
স্থান ইন্টারফেস
google.maps . Place
ইন্টারফেস
DirectionsRequest
বা DistanceMatrixRequest
এর জন্য একটি স্থান সনাক্ত করতে, সনাক্ত করতে বা বর্ণনা করতে প্রয়োজনীয় তথ্য রয়েছে৷ এই প্রসঙ্গে, "স্থান" মানে একটি ব্যবসা, আগ্রহের স্থান, বা ভৌগলিক অবস্থান। একটি স্থান সম্পর্কে তথ্য আনার জন্য, PlacesService
দেখুন।
বৈশিষ্ট্য | |
---|---|
location optional | প্রকার: LatLng | LatLngLiteral optional এই স্থান দ্বারা বর্ণিত সত্তার LatLng . |
placeId optional | প্রকার: string optional জায়গার আইডি (যেমন ব্যবসা বা আগ্রহের জায়গা)। স্থান আইডি হল Google মানচিত্র ডাটাবেসের একটি স্থানের একটি অনন্য শনাক্তকারী৷ মনে রাখবেন যে placeId হল একটি স্থান শনাক্ত করার সবচেয়ে সঠিক উপায়। যদি সম্ভব হয়, তাহলে আপনাকে একটি query পরিবর্তে placeId উল্লেখ করতে হবে। প্লেস এপিআই-এর যেকোনো অনুরোধ থেকে একটি স্থান আইডি পুনরুদ্ধার করা যেতে পারে, যেমন একটি পাঠ্য অনুসন্ধান । জিওকোডিং এপিআই-তে অনুরোধ থেকে স্থানের আইডিগুলিও পুনরুদ্ধার করা যেতে পারে। আরও তথ্যের জন্য, স্থান আইডিগুলির ওভারভিউ দেখুন। |
query optional | প্রকার: string optional একটি অনুসন্ধান ক্যোয়ারী স্থানটি বর্ণনা করে (যেমন একটি ব্যবসা বা আগ্রহের স্থান)। একটি উদাহরণ প্রশ্ন হল "Quay, Upper Level, Overseas Passenger Terminal 5 Hickson Road, The Rocks NSW"। যদি সম্ভব হয়, তাহলে আপনাকে একটি query পরিবর্তে placeId উল্লেখ করতে হবে। এপিআই একটি জায়গায় কোয়েরি স্ট্রিং সমাধান করার সঠিকতার গ্যারান্টি দেয় না। যদি placeId এবং query উভয়ই প্রদান করা হয়, একটি ত্রুটি ঘটে। |
TravelMode ধ্রুবক
google.maps . TravelMode
ধ্রুবক
বৈধ ভ্রমণের মোড যা একটি DirectionsRequest
এ নির্দিষ্ট করা যেতে পারে এবং সেইসাথে একটি DirectionsStep
এ ফিরে আসা ভ্রমণ মোডগুলি। মান দ্বারা, বা ধ্রুবকের নাম ব্যবহার করে এইগুলি নির্দিষ্ট করুন। উদাহরণস্বরূপ, 'BICYCLING'
বা google.maps.TravelMode.BICYCLING
।
const {TravelMode} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BICYCLING | সাইকেল চালানোর দিকনির্দেশের অনুরোধ নির্দিষ্ট করে। |
DRIVING | একটি ড্রাইভিং দিকনির্দেশের অনুরোধ নির্দিষ্ট করে। |
TRANSIT | একটি ট্রানজিট দিকনির্দেশের অনুরোধ নির্দিষ্ট করে। |
WALKING | হাঁটার দিকনির্দেশের অনুরোধ নির্দিষ্ট করে। |
ড্রাইভিং অপশন ইন্টারফেস
google.maps . DrivingOptions
ইন্টারফেস
যখন ভ্রমণ মোড DRIVING
এ সেট করা থাকে তখন DirectionsRequest
কনফিগার করে।
বৈশিষ্ট্য | |
---|---|
departureTime | প্রকার: Date রুটের জন্য কাঙ্খিত প্রস্থানের সময়, Date অবজেক্ট হিসাবে নির্দিষ্ট করা হয়েছে। Date অবজেক্টটি 1 জানুয়ারী 1970 সাল থেকে মিলিসেকেন্ডে সময় পরিমাপ করে। এটি একটি DrivingOptions বৈধ হওয়ার জন্য নির্দিষ্ট করা আবশ্যক। প্রস্থানের সময় বর্তমান সময়ে বা ভবিষ্যতে কিছু সময় সেট করা আবশ্যক। এটা অতীত হতে পারে না। |
trafficModel optional | প্রকার: TrafficModel optional ট্র্যাফিকের সময়কালের পূর্বাভাস দেওয়ার সময় ব্যবহার করার জন্য পছন্দের অনুমান। ডিফল্ট হল BEST_GUESS । |
ট্রাফিক মডেল ধ্রুবক
google.maps . TrafficModel
ধ্রুবক
ট্র্যাফিকের সময়কালের পূর্বাভাস দেওয়ার সময় ব্যবহার করা অনুমান। একটি DirectionsRequest
বা DistanceMatrixRequest
অংশ হিসাবে নির্দিষ্ট করা হয়েছে। মান দ্বারা, বা ধ্রুবকের নাম ব্যবহার করে এইগুলি নির্দিষ্ট করুন। উদাহরণস্বরূপ, 'bestguess'
বা google.maps.TrafficModel.BEST_GUESS
।
const {TrafficModel} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BEST_GUESS | ট্রাফিকের মধ্যে অতিবাহিত সময়ের সর্বোত্তম অনুমান করতে ঐতিহাসিক ট্রাফিক ডেটা ব্যবহার করুন। |
OPTIMISTIC | ট্রাফিকের সময়কাল কত হবে তার একটি আশাবাদী অনুমান করতে ঐতিহাসিক ট্রাফিক ডেটা ব্যবহার করুন। |
PESSIMISTIC | ট্রাফিকের সময়কাল কী হবে তার একটি হতাশাবাদী অনুমান করতে ঐতিহাসিক ট্রাফিক ডেটা ব্যবহার করুন। |
TransitOptions ইন্টারফেস
google.maps . TransitOptions
ইন্টারফেস
যখন ভ্রমণ মোডটি TRANSIT-এ সেট করা থাকে তখন TransitOptions অবজেক্টকে একটি DirectionsRequest
এ অন্তর্ভুক্ত করতে হবে।
বৈশিষ্ট্য | |
---|---|
arrivalTime optional | প্রকার: Date optional রুটের জন্য কাঙ্খিত আগমনের সময়, তারিখ অবজেক্ট হিসাবে নির্দিষ্ট করা হয়েছে। তারিখ অবজেক্ট 1 জানুয়ারী 1970 থেকে মিলিসেকেন্ডে সময় পরিমাপ করে। যদি আগমনের সময় নির্দিষ্ট করা হয়, প্রস্থানের সময় উপেক্ষা করা হয়। |
departureTime optional | প্রকার: Date optional রুটের জন্য কাঙ্খিত প্রস্থানের সময়, তারিখ অবজেক্ট হিসাবে নির্দিষ্ট করা হয়েছে। তারিখ অবজেক্টটি 1 জানুয়ারী 1970 সাল থেকে মিলিসেকেন্ডে সময় পরিমাপ করে। যদি প্রস্থানের সময় বা আগমনের সময় নির্দিষ্ট করা না থাকে তবে সময়টিকে "এখন" বলে ধরে নেওয়া হয়। |
modes optional | প্রকার: Array < TransitMode > optional ট্রানজিটের এক বা একাধিক পছন্দের মোড, যেমন বাস বা ট্রেন। যদি কোন পছন্দ না দেওয়া হয়, API ডিফল্ট সেরা রুট প্রদান করে। |
routingPreference optional | প্রকার: TransitRoutePreference optional একটি পছন্দ যা ট্রানজিট রুটের পছন্দকে পক্ষপাতিত্ব করতে পারে, যেমন কম হাঁটা। যদি কোন পছন্দ না দেওয়া হয়, API ডিফল্ট সেরা রুট প্রদান করে। |
ট্রানজিটমোড ধ্রুবক
google.maps . TransitMode
ধ্রুবক
বৈধ ট্রানজিট মোড যেমন বাস যা একটি TransitOptions
এ নির্দিষ্ট করা যেতে পারে। মান দ্বারা, বা ধ্রুবকের নাম ব্যবহার করে এইগুলি নির্দিষ্ট করুন। উদাহরণস্বরূপ, 'BUS'
বা google.maps.TransitMode.BUS
।
const {TransitMode} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BUS | বাসকে ট্রানজিটের পছন্দের মোড হিসাবে নির্দিষ্ট করে। |
RAIL | ট্রানজিটের একটি পছন্দের মোড হিসাবে রেলকে নির্দিষ্ট করে। |
SUBWAY | ট্রানজিটের একটি পছন্দের মোড হিসাবে পাতাল রেলকে নির্দিষ্ট করে৷ |
TRAIN | ট্রানজিটের একটি পছন্দের মোড হিসাবে ট্রেনকে নির্দিষ্ট করে৷ |
TRAM | ট্রানজিটের একটি পছন্দের মোড হিসাবে ট্রামকে নির্দিষ্ট করে৷ |
TransitRoutePreference ধ্রুবক
google.maps . TransitRoutePreference
ধ্রুবক
বৈধ ট্রানজিট রুট প্রকার যা একটি TransitOptions
এ নির্দিষ্ট করা যেতে পারে। মান দ্বারা, বা ধ্রুবকের নাম ব্যবহার করে এইগুলি নির্দিষ্ট করুন। উদাহরণস্বরূপ, 'LESS_WALKING'
বা google.maps.TransitRoutePreference.LESS_WALKING
।
const {TransitRoutePreference} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
FEWER_TRANSFERS | নির্দিষ্ট করে যে গণনা করা রুটটি সীমিত সংখ্যক স্থানান্তর পছন্দ করবে৷ |
LESS_WALKING | নির্দিষ্ট করে যে গণনা করা রুট সীমিত পরিমাণে হাঁটা পছন্দ করবে। |
ট্রানজিটফেয়ার ইন্টারফেস
google.maps . TransitFare
ইন্টারফেস
মান এবং মুদ্রা সমন্বিত একটি DirectionsRoute
ভাড়া।
বৈশিষ্ট্য | |
---|---|
currency | প্রকার: string একটি ISO 4217 মুদ্রা কোড যে মুদ্রায় ভাড়া প্রকাশ করা হয়েছে তা নির্দেশ করে। |
value | প্রকার: number ভাড়ার সংখ্যাসূচক মান, প্রদত্ত currency প্রকাশ করা হয়। |
Transit Details ইন্টারফেস
google.maps . TransitDetails
ইন্টারফেস
এই ধাপে ব্যবহৃত প্রস্থান, আগমন এবং ট্রানজিটের মোড সম্পর্কে বিশদ বিবরণ।
বৈশিষ্ট্য | |
---|---|
arrival_stop | প্রকার: TransitStop এই ট্রানজিট ধাপের আগমন স্টপ। |
arrival_time | প্রকার: Time এই ধাপের আগমনের সময়, একটি Time অবজেক্ট হিসাবে নির্দিষ্ট করা হয়েছে। |
departure_stop | প্রকার: TransitStop এই ট্রানজিট ধাপের প্রস্থান স্টপ। |
departure_time | প্রকার: Time এই ধাপের প্রস্থানের সময়, একটি টাইম অবজেক্ট হিসাবে নির্দিষ্ট করা হয়েছে। |
headsign | প্রকার: string এই লাইনে যে দিক দিয়ে ভ্রমণ করতে হবে, কারণ এটি গাড়িতে বা প্রস্থান স্টপে চিহ্নিত করা আছে। |
headway | প্রকার: number এই স্টপে সমান যানবাহনের মধ্যে প্রত্যাশিত সেকেন্ডের সংখ্যা। |
line | প্রকার: TransitLine এই ধাপে ব্যবহৃত ট্রানজিট লাইন সম্পর্কে বিশদ বিবরণ। |
num_stops | প্রকার: number এই ধাপে স্টপের সংখ্যা। আগমন স্টপ অন্তর্ভুক্ত, কিন্তু প্রস্থান স্টপ নয়. |
trip_short_name | প্রকার: string পাঠ্য যা যাত্রীদের একটি ট্রানজিট ট্রিপ সনাক্ত করতে সময়সূচী এবং সাইন বোর্ডে প্রদর্শিত হয়, উদাহরণস্বরূপ, কমিউটার রেল ট্রিপের জন্য ট্রেন নম্বর সনাক্ত করতে। পাঠ্যটি একটি পরিষেবা দিনের মধ্যে একটি ট্রিপকে অনন্যভাবে চিহ্নিত করে৷ |
ট্রানজিটস্টপ ইন্টারফেস
google.maps . TransitStop
ইন্টারফেস
একটি ট্রানজিট স্টপ বা স্টেশন সম্পর্কে বিশদ বিবরণ।
বৈশিষ্ট্য | |
---|---|
location | প্রকার: LatLng এই স্টপ অবস্থান. |
name | প্রকার: string এই ট্রানজিট স্টপের নাম। |
ট্রানজিটলাইন ইন্টারফেস
google.maps . TransitLine
ইন্টারফেস
এই ট্রানজিট ধাপটি পরিচালনা করে এমন ট্রানজিট লাইন সম্পর্কে তথ্য।
বৈশিষ্ট্য | |
---|---|
agencies | প্রকার: Array < TransitAgency > যে ট্রানজিট এজেন্সি এই ট্রানজিট লাইনটি পরিচালনা করে। |
color | প্রকার: string এই ট্রানজিট লাইনের সাইনেজে সাধারণত ব্যবহৃত রঙ, একটি হেক্স স্ট্রিং হিসাবে উপস্থাপিত হয়। |
icon | প্রকার: string এই লাইনের সাথে যুক্ত একটি আইকনের URL। |
name | প্রকার: string এই ট্রানজিট লাইনের পুরো নাম, যেমন "8 এভিনিউ লোকাল"। |
short_name | প্রকার: string এই ট্রানজিট লাইনের সংক্ষিপ্ত নাম, যেমন "E"। |
text_color | প্রকার: string এই ট্রানজিট লাইনের সাইনেজে সাধারণত ব্যবহৃত পাঠ্যের রঙ, একটি হেক্স স্ট্রিং হিসাবে উপস্থাপিত হয়। |
url | প্রকার: string এজেন্সির URL যা এই ট্রানজিট লাইনের জন্য নির্দিষ্ট। |
vehicle | প্রকার: TransitVehicle ব্যবহৃত গাড়ির ধরন, যেমন ট্রেন বা বাস। |
ট্রানজিট এজেন্সি ইন্টারফেস
google.maps . TransitAgency
ইন্টারফেস
একটি এজেন্সি সম্পর্কে তথ্য যা একটি ট্রানজিট লাইন পরিচালনা করে।
বৈশিষ্ট্য | |
---|---|
name | প্রকার: string এই ট্রানজিট এজেন্সির নাম। |
phone | প্রকার: string ট্রানজিট এজেন্সির ফোন নম্বর। |
url | প্রকার: string ট্রানজিট এজেন্সির URL। |
ট্রানজিট যানবাহন ইন্টারফেস
google.maps . TransitVehicle
ইন্টারফেস
ট্রানজিট লাইনে চালিত গাড়ির তথ্য।
বৈশিষ্ট্য | |
---|---|
icon | প্রকার: string একটি আইকনের জন্য একটি URL যা এই লাইনে ব্যবহৃত গাড়ির প্রকারের সাথে সঙ্গতিপূর্ণ। |
local_icon | প্রকার: string আরও সাধারণ আইকনের পরিবর্তে এই অঞ্চলে ব্যবহৃত গাড়ির প্রকারের সাথে সামঞ্জস্যপূর্ণ একটি আইকনের URL। |
name | প্রকার: string এই ধরনের ট্রানজিট যানের একটি নাম, যেমন "ট্রেন" বা "বাস"। |
type | প্রকার: VehicleType ব্যবহৃত গাড়ির ধরন, যেমন ট্রেন, বাস বা ফেরি। |
যানবাহনের ধরন ধ্রুবক
google.maps . VehicleType
ধ্রুবক
গাড়ির প্রকারের জন্য সম্ভাব্য মান।
const {VehicleType} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BUS | বাস। |
CABLE_CAR | একটি যান যা একটি তারের উপর চলে, সাধারণত মাটিতে। এরিয়াল ক্যাবল কারগুলি GONDOLA_LIFT প্রকারের হতে পারে৷ |
COMMUTER_TRAIN | কমিউটার রেল। |
FERRY | ফেরি। |
FUNICULAR | একটি যান যা একটি তারের দ্বারা একটি খাড়া বাঁক পর্যন্ত টানা হয়। |
GONDOLA_LIFT | একটি বায়বীয় তারের গাড়ি। |
HEAVY_RAIL | ভারী রেল। |
HIGH_SPEED_TRAIN | উচ্চ গতির ট্রেন. |
INTERCITY_BUS | আন্তঃনগর বাস। |
METRO_RAIL | হালকা রেল। |
MONORAIL | মনোরেল। |
OTHER | অন্যান্য যানবাহন। |
RAIL | রেল। |
SHARE_TAXI | শেয়ার ট্যাক্সি হল এক ধরণের বাস পরিবহন যা এর রুটে যে কোন জায়গায় যাত্রীদের নামানোর এবং তোলার ক্ষমতা। সাধারণত শেয়ার ট্যাক্সি মিনিবাস যানবাহন ব্যবহার করে। |
SUBWAY | আন্ডারগ্রাউন্ড লাইট রেল। |
TRAM | মাটির উপরে হালকা রেল। |
TROLLEYBUS | ট্রলিবাস। |
ইউনিটসিস্টেম ধ্রুবক
google.maps . UnitSystem
ধ্রুবক
বৈধ একক সিস্টেম যা DirectionsRequest
নির্দিষ্ট করা যেতে পারে।
const {UnitSystem} = await google.maps.importLibrary("core")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
IMPERIAL | নির্দেশ DirectionsResult যে দূরত্বগুলি ইম্পেরিয়াল ইউনিটে প্রকাশ করা উচিত। |
METRIC | নির্দিষ্ট করে যে DirectionsResult দূরত্বগুলি মেট্রিক ইউনিটে প্রকাশ করা উচিত। |
দূরত্ব ইন্টারফেস
google.maps . Distance
ইন্টারফেস
একটি সংখ্যাসূচক মান এবং একটি প্রদর্শন স্ট্রিং হিসাবে দূরত্বের একটি উপস্থাপনা৷
বৈশিষ্ট্য | |
---|---|
text | প্রকার: string অনুরোধে নির্দিষ্ট UnitSystem ব্যবহার করে দূরত্বের মানের একটি স্ট্রিং উপস্থাপনা। |
value | প্রকার: number দূরত্ব মিটারে। |
সময়কাল ইন্টারফেস
google.maps . Duration
ইন্টারফেস
একটি সাংখ্যিক মান এবং একটি প্রদর্শন স্ট্রিং হিসাবে সময়কালের একটি উপস্থাপনা৷
বৈশিষ্ট্য | |
---|---|
text | প্রকার: string সময়কাল মানের একটি স্ট্রিং উপস্থাপনা। |
value | প্রকার: number সেকেন্ডে সময়কাল। |
সময় ইন্টারফেস
google.maps . Time
ইন্টারফেস
একটি তারিখ বস্তু, একটি স্থানীয় স্ট্রিং এবং একটি সময় অঞ্চল হিসাবে সময়ের উপস্থাপনা৷
বৈশিষ্ট্য | |
---|---|
text | প্রকার: string সময়ের মান প্রতিনিধিত্বকারী একটি স্ট্রিং। সময়টি ট্রানজিট স্টপের সময় অঞ্চলে প্রদর্শিত হয়। |
time_zone | প্রকার: string এই স্টপটি যে টাইম জোনে রয়েছে। মান হল IANA টাইম জোন ডেটাবেসে সংজ্ঞায়িত সময় অঞ্চলের নাম, যেমন "America/New_York"। |
value | প্রকার: Date এই প্রস্থান বা আগমনের সময়, জাভাস্ক্রিপ্ট তারিখ অবজেক্ট হিসাবে নির্দিষ্ট করা হয়েছে। |
দিকনির্দেশ ট্রাভেলমোড ধ্রুবক
google.maps . DirectionsTravelMode
ধ্রুবক
নির্দেশ ইউনিটসিস্টেম ধ্রুবক
google.maps . DirectionsUnitSystem
ধ্রুবক
নির্দেশ সার্ভিস ক্লাস
google.maps . DirectionsService
ক্লাস
দুই বা ততোধিক স্থানের মধ্যে দিকনির্দেশ কম্পিউট করার জন্য একটি পরিষেবা।
const {DirectionsService} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
কনস্ট্রাক্টর | |
---|---|
DirectionsService | DirectionsService() পরামিতি: কোনোটিই নয় একটি DirectionsService একটি নতুন দৃষ্টান্ত তৈরি করে যা Google সার্ভারগুলিতে দিকনির্দেশের প্রশ্ন পাঠায়৷ |
পদ্ধতি | |
---|---|
route | route(request[, callback]) পরামিতি:
রিটার্ন মান: Promise < DirectionsResult > একটি দিকনির্দেশ অনুসন্ধান অনুরোধ ইস্যু করুন। |
নির্দেশাবলী অনুরোধ ইন্টারফেস
google.maps . DirectionsRequest
ইন্টারফেস
একটি দিকনির্দেশের প্রশ্ন DirectionsService
এ পাঠানো হবে।
বৈশিষ্ট্য | |
---|---|
destination | প্রকার: string| LatLng | Place | LatLngLiteral গন্তব্যের অবস্থান। এটি জিওকোড করার জন্য একটি স্ট্রিং, বা একটি LatLng , বা একটি Place হিসাবে নির্দিষ্ট করা যেতে পারে। প্রয়োজন। |
origin | প্রকার: string| LatLng | Place | LatLngLiteral উৎপত্তির অবস্থান। এটি জিওকোড করার জন্য একটি স্ট্রিং, বা একটি LatLng , বা একটি Place হিসাবে নির্দিষ্ট করা যেতে পারে। প্রয়োজন। |
travelMode | প্রকার: TravelMode রাউটিং এর প্রকার অনুরোধ করা হয়েছে। প্রয়োজন। |
avoidFerries optional | প্রকার: boolean optional true হলে, যেখানে সম্ভব ফেরি এড়াতে দিকনির্দেশ পরিষেবাকে নির্দেশ দেয়৷ ঐচ্ছিক। |
avoidHighways optional | প্রকার: boolean optional true হলে, যেখানে সম্ভব হাইওয়েগুলি এড়াতে নির্দেশ পরিষেবাকে নির্দেশ দেয়৷ ঐচ্ছিক। |
avoidTolls optional | প্রকার: boolean optional true হলে, যেখানে সম্ভব টোল রাস্তা এড়াতে দিকনির্দেশ পরিষেবাকে নির্দেশ দেয়৷ ঐচ্ছিক। |
drivingOptions optional | প্রকার: DrivingOptions optional সেটিংস যা শুধুমাত্র অনুরোধের ক্ষেত্রে প্রযোজ্য যেখানে travelMode DRIVING । এই বস্তুটি অন্যান্য ভ্রমণ মোডের জন্য কোন প্রভাব ফেলবে না। |
language optional | প্রকার: string optional যখন সম্ভব তখন যে ভাষার ফলাফল দেওয়া উচিত তার জন্য একটি ভাষা শনাক্তকারী। সমর্থিত ভাষার তালিকা দেখুন। |
optimizeWaypoints optional | প্রকার: boolean optional যদি true তে সেট করা হয়, তাহলে রুটের সামগ্রিক খরচ কমানোর জন্য DirectionsService সরবরাহ করা মধ্যবর্তী ওয়েপয়েন্টগুলিকে পুনরায় অর্ডার করার চেষ্টা করবে। যদি ওয়েপয়েন্টগুলি অপ্টিমাইজ করা হয়, নতুন অর্ডার নির্ধারণ করতে প্রতিক্রিয়াতে DirectionsRoute.waypoint_order পরিদর্শন করুন। |
provideRouteAlternatives optional | প্রকার: boolean optional রুট বিকল্প প্রদান করা উচিত কি না. ঐচ্ছিক। |
region optional | প্রকার: string optional জিওকোডিং অনুরোধের জন্য একটি পক্ষপাত হিসাবে ব্যবহৃত অঞ্চল কোড। অঞ্চল কোড একটি ccTLD ("টপ-লেভেল ডোমেন") দুই-অক্ষরের মান গ্রহণ করে। কিছু উল্লেখযোগ্য ব্যতিক্রম সহ বেশিরভাগ ccTLD কোডগুলি ISO 3166-1 কোডগুলির সাথে অভিন্ন। উদাহরণস্বরূপ, যুক্তরাজ্যের ccTLD হল "uk" ( .co.uk ) যেখানে এর ISO 3166-1 কোড হল "gb" (প্রযুক্তিগতভাবে "দ্য ইউনাইটেড কিংডম অফ গ্রেট ব্রিটেন এবং উত্তর আয়ারল্যান্ড" এর সত্তার জন্য)। |
transitOptions optional | প্রকার: TransitOptions optional সেটিংস যা শুধুমাত্র অনুরোধের ক্ষেত্রে প্রযোজ্য যেখানে travelMode TRANSIT হয়। এই বস্তুটি অন্যান্য ভ্রমণ মোডের জন্য কোন প্রভাব ফেলবে না। |
unitSystem optional | প্রকার: UnitSystem optional ডিফল্ট: মূল দেশে ব্যবহৃত ইউনিট সিস্টেম। দূরত্ব প্রদর্শন করার সময় ব্যবহার করার জন্য পছন্দের ইউনিট সিস্টেম। |
waypoints optional | প্রকার: Array < DirectionsWaypoint > optional মধ্যবর্তী পথপয়েন্টের অ্যারে। এই অ্যারের প্রতিটি ওয়েপয়েন্টের মাধ্যমে উৎপত্তি থেকে গন্তব্য পর্যন্ত দিকনির্দেশ গণনা করা হয়। অনুমোদিত সর্বাধিক সংখ্যক ওয়েপয়েন্টের জন্য বিকাশকারীর নির্দেশিকা দেখুন। ট্রানজিট দিকনির্দেশের জন্য ওয়েপয়েন্ট সমর্থিত নয়। ঐচ্ছিক। |
দিকনির্দেশ স্ট্যাটাস ধ্রুবক
google.maps . DirectionsStatus
ধ্রুবক
একটি কল টু route()
সম্পূর্ণ হওয়ার পরে DirectionsService
দ্বারা স্ট্যাটাস ফেরত দেওয়া হয়। মান দ্বারা, বা ধ্রুবকের নাম ব্যবহার করে এইগুলি নির্দিষ্ট করুন। উদাহরণস্বরূপ, 'OK'
বা google.maps.DirectionsStatus.OK
।
const {DirectionsStatus} = await google.maps.importLibrary("routes")
কল করে অ্যাক্সেস করুন। Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
INVALID_REQUEST | প্রদত্ত DirectionsRequest অবৈধ ছিল৷ |
MAX_WAYPOINTS_EXCEEDED | DirectionsRequest এ অনেকগুলো DirectionsWaypoint s প্রদান করা হয়েছে। অনুমোদিত সর্বাধিক সংখ্যক ওয়েপয়েন্টের জন্য বিকাশকারীর নির্দেশিকা দেখুন। |
NOT_FOUND | উত্স, গন্তব্য, বা পথপয়েন্টগুলির মধ্যে অন্তত একটি জিওকোড করা যায়নি৷ |
OK | প্রতিক্রিয়াটিতে একটি বৈধ DirectionsResult রয়েছে। |
OVER_QUERY_LIMIT | ওয়েবপৃষ্ঠাটি খুব অল্প সময়ের মধ্যে অনুরোধের সীমা অতিক্রম করেছে৷ |
REQUEST_DENIED | ওয়েবপৃষ্ঠাটি দিকনির্দেশ পরিষেবা ব্যবহার করার অনুমতি নেই৷ |
UNKNOWN_ERROR | একটি সার্ভার ত্রুটির কারণে একটি দিকনির্দেশের অনুরোধ প্রক্রিয়া করা যায়নি৷ আপনি আবার চেষ্টা করলে অনুরোধ সফল হতে পারে। |
ZERO_RESULTS | উৎপত্তিস্থল এবং গন্তব্যের মধ্যে কোনো পথ খুঁজে পাওয়া যায়নি। |
দিকনির্দেশ ফলাফল ইন্টারফেস
google.maps . DirectionsResult
ইন্টারফেস
দিকনির্দেশের প্রতিক্রিয়া দিকনির্দেশ সার্ভার থেকে পুনরুদ্ধার করা হয়েছে। আপনি একটি DirectionsRenderer
ব্যবহার করে এইগুলিকে রেন্ডার করতে পারেন বা এই বস্তুটিকে পার্স করতে পারেন এবং নিজেই রেন্ডার করতে পারেন৷ Google মানচিত্র প্ল্যাটফর্ম পরিষেবার শর্তাবলীতে উল্লিখিত হিসাবে আপনাকে সতর্কতা এবং কপিরাইট প্রদর্শন করতে হবে৷ মনে রাখবেন যে যদিও এই ফলাফলটি "JSON-এর মতো" তবে এটি কঠোরভাবে JSON নয়, কারণ এটি পরোক্ষভাবে LatLng
বস্তুগুলিকে অন্তর্ভুক্ত করে৷
বৈশিষ্ট্য | |
---|---|
routes | প্রকার: Array < DirectionsRoute > DirectionsRoute s এর একটি অ্যারে, যার প্রতিটিতে পা এবং ধাপগুলি সম্পর্কে তথ্য রয়েছে যা এটি তৈরি করা হয়েছে। শুধুমাত্র একটি রুট থাকবে যদি না DirectionsRequest টি প্রোভাইড provideRouteAlternatives true সেট করা হয়। |
available_travel_modes optional | প্রকার: Array < TravelMode > optional উপলব্ধ ভ্রমণ মোড একটি অ্যারে রয়েছে. এই ক্ষেত্রটি ফেরত দেওয়া হয় যখন একটি অনুরোধ একটি ভ্রমণ মোড নির্দিষ্ট করে এবং কোন ফলাফল পায় না। অ্যারেতে প্রদত্ত ওয়েপয়েন্টের সেটের দেশগুলিতে উপলব্ধ ভ্রমণ মোড রয়েছে। এক বা একাধিক ওয়েপয়েন্ট 'ওয়েপয়েন্টের মাধ্যমে' হলে এই ক্ষেত্রটি ফেরত দেওয়া হয় না। |
geocoded_waypoints optional | প্রকার: Array < DirectionsGeocodedWaypoint > optional DirectionsGeocodedWaypoint একটি অ্যারে জিওকোডেড ওয়েপয়েন্ট, যার প্রতিটিতে উৎপত্তি, গন্তব্য এবং পথপয়েন্টের জিওকোডিং সম্পর্কে তথ্য রয়েছে। |
DirectionsRenderer class
google.maps . DirectionsRenderer
class
Renders directions obtained from the DirectionsService
.
এই ক্লাস MVCObject
প্রসারিত.
Access by calling const {DirectionsRenderer} = await google.maps.importLibrary("routes")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
কনস্ট্রাক্টর | |
---|---|
DirectionsRenderer | DirectionsRenderer([opts]) পরামিতি:
Creates the renderer with the given options. Directions can be rendered on a map (as visual overlays) or additionally on a <div> panel (as textual instructions). |
পদ্ধতি | |
---|---|
getDirections | getDirections() পরামিতি: কোনোটিই নয় Return Value: DirectionsResult Returns the renderer's current set of directions. |
getMap | getMap() পরামিতি: কোনোটিই নয় Return Value: Map Returns the map on which the DirectionsResult is rendered. |
getPanel | getPanel() পরামিতি: কোনোটিই নয় Return Value: HTMLElement |null Returns the panel <div> in which the DirectionsResult is rendered. |
getRouteIndex | getRouteIndex() পরামিতি: কোনোটিই নয় রিটার্ন মান: number Returns the current (zero-based) route index in use by this DirectionsRenderer object. |
setDirections | setDirections(directions) পরামিতি:
রিটার্ন মান: কোনটিই নয় Set the renderer to use the result from the DirectionsService . Setting a valid set of directions in this manner will display the directions on the renderer's designated map and panel. |
setMap | setMap(map) পরামিতি:
রিটার্ন মান: কোনটিই নয় This method specifies the map on which directions will be rendered. Pass null to remove the directions from the map. |
setOptions | setOptions(options) পরামিতি:
রিটার্ন মান: কোনটিই নয় Change the options settings of this DirectionsRenderer after initialization. |
setPanel | setPanel(panel) পরামিতি:
রিটার্ন মান: কোনটিই নয় This method renders the directions in a <div> . Pass null to remove the content from the panel. |
setRouteIndex | setRouteIndex(routeIndex) পরামিতি:
রিটার্ন মান: কোনটিই নয় Set the (zero-based) index of the route in the DirectionsResult object to render. By default, the first route in the array will be rendered. |
উত্তরাধিকারসূত্রে পাওয়া: addListener , bindTo , get , notify , set , setValues , unbind , unbindAll |
ঘটনা | |
---|---|
directions_changed | function() যুক্তি: কোনটিই না This event is fired when the rendered directions change, either when a new DirectionsResult is set or when the user finishes dragging a change to the directions path. |
DirectionsRendererOptions interface
google.maps . DirectionsRendererOptions
interface
This object defines the properties that can be set on a DirectionsRenderer
object.
বৈশিষ্ট্য | |
---|---|
directions optional | Type: DirectionsResult optional The directions to display on the map and/or in a <div> panel, retrieved as a DirectionsResult object from DirectionsService . |
draggable optional | প্রকার: boolean optional If true , allows the user to drag and modify the paths of routes rendered by this DirectionsRenderer . |
hideRouteList optional | প্রকার: boolean optional ডিফল্ট: false This property indicates whether the renderer should provide a user-selectable list of routes shown in the directions panel. |
infoWindow optional | Type: InfoWindow optional The InfoWindow in which to render text information when a marker is clicked. Existing info window content will be overwritten and its position moved. If no info window is specified, the DirectionsRenderer will create and use its own info window. This property will be ignored if suppressInfoWindows is set to true . |
map optional | Type: Map optional Map on which to display the directions. |
markerOptions optional | Type: MarkerOptions optional Options for the markers. All markers rendered by the DirectionsRenderer will use these options. |
panel optional | Type: HTMLElement optional The <div> in which to display the directions steps. |
polylineOptions optional | Type: PolylineOptions optional Options for the polylines. All polylines rendered by the DirectionsRenderer will use these options. |
preserveViewport optional | প্রকার: boolean optional ডিফল্ট: false If this option is set to true or the map's center and zoom were never set, the input map is centered and zoomed to the bounding box of this set of directions. |
routeIndex optional | প্রকার: number optional The index of the route within the DirectionsResult object. The default value is 0. |
suppressBicyclingLayer optional | প্রকার: boolean optional Suppress the rendering of the BicyclingLayer when bicycling directions are requested. |
suppressInfoWindows optional | প্রকার: boolean optional Suppress the rendering of info windows. |
suppressMarkers optional | প্রকার: boolean optional Suppress the rendering of markers. |
suppressPolylines optional | প্রকার: boolean optional Suppress the rendering of polylines. |
DirectionsWaypoint interface
google.maps . DirectionsWaypoint
interface
A DirectionsWaypoint
represents a location between origin and destination through which the trip should be routed.
বৈশিষ্ট্য | |
---|---|
location optional | Type: string| LatLng | LatLngLiteral | Place optional Waypoint location. Can be an address string, a LatLng , or a Place . Optional. |
stopover optional | প্রকার: boolean optional ডিফল্ট: true If true , indicates that this waypoint is a stop between the origin and destination. This has the effect of splitting the route into two legs. If false , indicates that the route should be biased to go through this waypoint, but not split into two legs. This is useful if you want to create a route in response to the user dragging waypoints on a map. |
DirectionsGeocodedWaypoint interface
google.maps . DirectionsGeocodedWaypoint
interface
A single geocoded waypoint.
বৈশিষ্ট্য | |
---|---|
partial_match optional | প্রকার: boolean optional Whether the geocoder did not return an exact match for the original waypoint, though it was able to match part of the requested address. |
place_id optional | প্রকার: string optional The place ID associated with the waypoint. Place IDs uniquely identify a place in the Google Places database and on Google Maps. Learn more about Place IDs in the Places API developer guide. |
types optional | Type: Array <string> optional An array of strings denoting the type of the returned geocoded element. For a list of possible strings, refer to the Address Component Types section of the Developer's Guide. |
DirectionsRoute interface
google.maps . DirectionsRoute
interface
A single route containing a set of legs in a DirectionsResult
. Note that though this object is "JSON-like," it is not strictly JSON, as it directly and indirectly includes LatLng
objects.
বৈশিষ্ট্য | |
---|---|
bounds | Type: LatLngBounds The bounds for this route. |
copyrights | প্রকার: string Copyrights text to be displayed for this route. |
legs | Type: Array < DirectionsLeg > An array of DirectionsLeg s, each of which contains information about the steps of which it is composed. There will be one leg for each stopover waypoint or destination specified. So a route with no stopover waypoints will contain one DirectionsLeg and a route with one stopover waypoint will contain two. |
overview_path | An array of LatLng s representing the entire course of this route. The path is simplified in order to make it suitable in contexts where a small number of vertices is required (such as Static Maps API URLs). |
overview_polyline | প্রকার: string An encoded polyline representation of the route in overview_path. This polyline is an approximate (smoothed) path of the resulting directions. |
summary | প্রকার: string Contains a short textual description for the route, suitable for naming and disambiguating the route from alternatives. |
warnings | Type: Array <string> Warnings to be displayed when showing these directions. |
waypoint_order | Type: Array <number> If optimizeWaypoints was set to true , this field will contain the re-ordered permutation of the input waypoints. For example, if the input was:Origin: Los Angeles Waypoints: Dallas, Bangor, Phoenix Destination: New York and the optimized output was ordered as follows: Origin: Los Angeles Waypoints: Phoenix, Dallas, Bangor Destination: New York then this field will be an Array containing the values [2, 0, 1]. Note that the numbering of waypoints is zero-based.If any of the input waypoints has stopover set to false , this field will be empty, since route optimization is not available for such queries. |
fare optional | Type: TransitFare optional The total fare for the whole transit trip. Only applicable to transit requests. |
DirectionsLeg interface
google.maps . DirectionsLeg
interface
A single leg consisting of a set of steps in a DirectionsResult
. Some fields in the leg may not be returned for all requests. Note that though this result is "JSON-like," it is not strictly JSON, as it directly and indirectly includes LatLng
objects.
বৈশিষ্ট্য | |
---|---|
end_address | প্রকার: string The address of the destination of this leg. This content is meant to be read as-is. Do not programmatically parse the formatted address. |
end_location | Type: LatLng The DirectionsService calculates directions between locations by using the nearest transportation option (usually a road) at the start and end locations. end_location indicates the actual geocoded destination, which may be different than the end_location of the last step if, for example, the road is not near the destination of this leg. |
start_address | প্রকার: string The address of the origin of this leg. This content is meant to be read as-is. Do not programmatically parse the formatted address. |
start_location | Type: LatLng The DirectionsService calculates directions between locations by using the nearest transportation option (usually a road) at the start and end locations. start_location indicates the actual geocoded origin, which may be different than the start_location of the first step if, for example, the road is not near the origin of this leg. |
steps | Type: Array < DirectionsStep > An array of DirectionsStep s, each of which contains information about the individual steps in this leg. |
traffic_speed_entry | Type: Array <?> Information about traffic speed along the leg. |
via_waypoints | An array of non-stopover waypoints along this leg, which were specified in the original request. Deprecated in alternative routes . Version 3.27 will be the last version of the API that adds extra When using the Directions Service to implement draggable directions, it is recommended to disable dragging of alternative routes. Only the main route should be draggable. Users can drag the main route until it matches an alternative route. |
arrival_time optional | Type: Time optional An estimated arrival time for this leg. Only applicable for TRANSIT requests. |
departure_time optional | Type: Time optional An estimated departure time for this leg. Only applicable for TRANSIT requests. |
distance optional | Type: Distance optional The total distance covered by this leg. This property may be undefined as the distance may be unknown. |
duration optional | Type: Duration optional The total duration of this leg. This property may be undefined as the duration may be unknown. |
duration_in_traffic optional | Type: Duration optional The total duration of this leg, taking into account the traffic conditions indicated by the trafficModel property. This property may be undefined as the duration may be unknown. |
DirectionsStep interface
google.maps . DirectionsStep
interface
A single DirectionsStep
in a DirectionsResult
. Some fields may be undefined
. Note that though this object is "JSON-like," it is not strictly JSON, as it directly includes LatLng
objects.
বৈশিষ্ট্য | |
---|---|
encoded_lat_lngs | প্রকার: string An encoded polyline representation of the step. This is an approximate (smoothed) path of the step. |
end_location | Type: LatLng The ending location of this step. |
end_point | Type: LatLng The ending location of this step. |
instructions | প্রকার: string Instructions for this step. |
lat_lngs | A sequence of LatLng s describing the course of this step. This is an approximate (smoothed) path of the step. |
maneuver | প্রকার: string Contains the action to take for the current step ( turn-left , merge , straight , etc.). Values are subject to change, and new values may be introduced without prior notice. |
path | A sequence of LatLng s describing the course of this step. This is an approximate (smoothed) path of the step. |
start_location | Type: LatLng The starting location of this step. |
start_point | Type: LatLng The starting location of this step. |
travel_mode | Type: TravelMode The mode of travel used in this step. |
distance optional | Type: Distance optional The distance covered by this step. This property may be undefined as the distance may be unknown. |
duration optional | Type: Duration optional The typical time required to perform this step in seconds and in text form. This property may be undefined as the duration may be unknown. |
polyline optional polyline optional | Type: DirectionsPolyline optional Contains an object with a single property, 'points', that holds an encoded polyline representation of the step. This polyline is an approximate (smoothed) path of the step. |
steps optional | Type: Array < DirectionsStep > optional Sub-steps of this step. Specified for non-transit sections of transit routes. |
transit optional | Type: TransitDetails optional Transit-specific details about this step. This property will be undefined unless the travel mode of this step is TRANSIT . |
transit_details optional | Type: TransitDetails optional Details pertaining to this step if the travel mode is TRANSIT . |
DirectionsPolyline interface
google.maps . DirectionsPolyline
interface
An object containing a points
property to describe the polyline of a DirectionsStep
.
বৈশিষ্ট্য | |
---|---|
points | প্রকার: string An encoded polyline . |
Place interface
google.maps . Place
interface
Contains information needed to locate, identify, or describe a place for a DirectionsRequest
or DistanceMatrixRequest
. In this context, "place" means a business, point of interest, or geographic location. For fetching information about a place, see PlacesService
.
বৈশিষ্ট্য | |
---|---|
location optional | প্রকার: LatLng | LatLngLiteral optional The LatLng of the entity described by this place. |
placeId optional | প্রকার: string optional The place ID of the place (such as a business or point of interest). The place ID is a unique identifier of a place in the Google Maps database. Note that the placeId is the most accurate way of identifying a place. If possible, you should specify the placeId rather than a query . A place ID can be retrieved from any request to the Places API, such as a TextSearch . Place IDs can also be retrieved from requests to the Geocoding API. For more information, see the overview of place IDs . |
query optional | প্রকার: string optional A search query describing the place (such as a business or point of interest). An example query is "Quay, Upper Level, Overseas Passenger Terminal 5 Hickson Road, The Rocks NSW". If possible, you should specify the placeId rather than a query . The API does not guarantee the accuracy of resolving the query string to a place. If both the placeId and query are provided, an error occurs. |
TravelMode constants
google.maps . TravelMode
constants
The valid travel modes that can be specified in a DirectionsRequest
as well as the travel modes returned in a DirectionsStep
. Specify these by value, or by using the constant's name. For example, 'BICYCLING'
or google.maps.TravelMode.BICYCLING
.
Access by calling const {TravelMode} = await google.maps.importLibrary("routes")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BICYCLING | Specifies a bicycling directions request. |
DRIVING | Specifies a driving directions request. |
TRANSIT | Specifies a transit directions request. |
WALKING | Specifies a walking directions request. |
DrivingOptions interface
google.maps . DrivingOptions
interface
Configures the DirectionsRequest
when the travel mode is set to DRIVING
.
বৈশিষ্ট্য | |
---|---|
departureTime | Type: Date The desired departure time for the route, specified as a Date object. The Date object measures time in milliseconds since 1 January 1970. This must be specified for a DrivingOptions to be valid. The departure time must be set to the current time or some time in the future. It cannot be in the past. |
trafficModel optional | Type: TrafficModel optional The preferred assumption to use when predicting duration in traffic. The default is BEST_GUESS . |
TrafficModel constants
google.maps . TrafficModel
constants
The assumptions to use when predicting duration in traffic. Specified as part of a DirectionsRequest
or DistanceMatrixRequest
. Specify these by value, or by using the constant's name. For example, 'bestguess'
or google.maps.TrafficModel.BEST_GUESS
.
Access by calling const {TrafficModel} = await google.maps.importLibrary("routes")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BEST_GUESS | Use historical traffic data to best estimate the time spent in traffic. |
OPTIMISTIC | Use historical traffic data to make an optimistic estimate of what the duration in traffic will be. |
PESSIMISTIC | Use historical traffic data to make a pessimistic estimate of what the duration in traffic will be. |
TransitOptions interface
google.maps . TransitOptions
interface
The TransitOptions object to be included in a DirectionsRequest
when the travel mode is set to TRANSIT.
বৈশিষ্ট্য | |
---|---|
arrivalTime optional | Type: Date optional The desired arrival time for the route, specified as a Date object. The Date object measures time in milliseconds since 1 January 1970. If arrival time is specified, departure time is ignored. |
departureTime optional | Type: Date optional The desired departure time for the route, specified as a Date object. The Date object measures time in milliseconds since 1 January 1970. If neither departure time nor arrival time is specified, the time is assumed to be "now". |
modes optional | Type: Array < TransitMode > optional One or more preferred modes of transit, such as bus or train. If no preference is given, the API returns the default best route. |
routingPreference optional | Type: TransitRoutePreference optional A preference that can bias the choice of transit route, such as less walking. If no preference is given, the API returns the default best route. |
TransitMode constants
google.maps . TransitMode
constants
The valid transit mode eg bus that can be specified in a TransitOptions
. Specify these by value, or by using the constant's name. For example, 'BUS'
or google.maps.TransitMode.BUS
.
Access by calling const {TransitMode} = await google.maps.importLibrary("routes")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BUS | Specifies bus as a preferred mode of transit. |
RAIL | Specifies rail as a preferred mode of transit. |
SUBWAY | Specifies subway as a preferred mode of transit. |
TRAIN | Specifies train as a preferred mode of transit. |
TRAM | Specifies tram as a preferred mode of transit. |
TransitRoutePreference constants
google.maps . TransitRoutePreference
constants
The valid transit route type that can be specified in a TransitOptions
. Specify these by value, or by using the constant's name. For example, 'LESS_WALKING'
or google.maps.TransitRoutePreference.LESS_WALKING
.
Access by calling const {TransitRoutePreference} = await google.maps.importLibrary("routes")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
FEWER_TRANSFERS | Specifies that the calculated route should prefer a limited number of transfers. |
LESS_WALKING | Specifies that the calculated route should prefer limited amounts of walking. |
TransitFare interface
google.maps . TransitFare
interface
A fare of a DirectionsRoute
consisting of value and currency.
বৈশিষ্ট্য | |
---|---|
currency | প্রকার: string An ISO 4217 currency code indicating the currency in which the fare is expressed. |
value | প্রকার: number The numerical value of the fare, expressed in the given currency . |
TransitDetails interface
google.maps . TransitDetails
interface
Details about the departure, arrival, and mode of transit used in this step.
বৈশিষ্ট্য | |
---|---|
arrival_stop | Type: TransitStop The arrival stop of this transit step. |
arrival_time | Type: Time The arrival time of this step, specified as a Time object. |
departure_stop | Type: TransitStop The departure stop of this transit step. |
departure_time | Type: Time The departure time of this step, specified as a Time object. |
headsign | প্রকার: string The direction in which to travel on this line, as it is marked on the vehicle or at the departure stop. |
headway | প্রকার: number The expected number of seconds between equivalent vehicles at this stop. |
line | Type: TransitLine Details about the transit line used in this step. |
num_stops | প্রকার: number The number of stops on this step. Includes the arrival stop, but not the departure stop. |
trip_short_name | প্রকার: string The text that appears in schedules and sign boards to identify a transit trip to passengers, for example, to identify train numbers for commuter rail trips. The text uniquely identifies a trip within a service day. |
TransitStop interface
google.maps . TransitStop
interface
Details about a transit stop or station.
বৈশিষ্ট্য | |
---|---|
location | Type: LatLng The location of this stop. |
name | প্রকার: string The name of this transit stop. |
TransitLine interface
google.maps . TransitLine
interface
Information about the transit line that operates this transit step.
বৈশিষ্ট্য | |
---|---|
agencies | Type: Array < TransitAgency > The transit agency that operates this transit line. |
color | প্রকার: string The color commonly used in signage for this transit line, represented as a hex string. |
icon | প্রকার: string The URL for an icon associated with this line. |
name | প্রকার: string The full name of this transit line, eg "8 Avenue Local". |
short_name | প্রকার: string The short name of this transit line, eg "E". |
text_color | প্রকার: string The text color commonly used in signage for this transit line, represented as a hex string. |
url | প্রকার: string The agency's URL which is specific to this transit line. |
vehicle | Type: TransitVehicle The type of vehicle used, eg train or bus. |
TransitAgency interface
google.maps . TransitAgency
interface
Information about an agency that operates a transit line.
বৈশিষ্ট্য | |
---|---|
name | প্রকার: string The name of this transit agency. |
phone | প্রকার: string The transit agency's phone number. |
url | প্রকার: string The transit agency's URL. |
TransitVehicle interface
google.maps . TransitVehicle
interface
Information about the vehicle that operates on a transit line.
বৈশিষ্ট্য | |
---|---|
icon | প্রকার: string A URL for an icon that corresponds to the type of vehicle used on this line. |
local_icon | প্রকার: string A URL for an icon that corresponds to the type of vehicle used in this region instead of the more general icon. |
name | প্রকার: string A name for this type of TransitVehicle, eg "Train" or "Bus". |
type | Type: VehicleType The type of vehicle used, eg train, bus, or ferry. |
VehicleType constants
google.maps . VehicleType
constants
Possible values for vehicle types.
Access by calling const {VehicleType} = await google.maps.importLibrary("routes")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
BUS | Bus. |
CABLE_CAR | A vehicle that operates on a cable, usually on the ground. Aerial cable cars may be of the type GONDOLA_LIFT . |
COMMUTER_TRAIN | Commuter rail. |
FERRY | Ferry. |
FUNICULAR | A vehicle that is pulled up a steep incline by a cable. |
GONDOLA_LIFT | An aerial cable car. |
HEAVY_RAIL | Heavy rail. |
HIGH_SPEED_TRAIN | High speed train. |
INTERCITY_BUS | Intercity bus. |
METRO_RAIL | Light rail. |
MONORAIL | Monorail. |
OTHER | Other vehicles. |
RAIL | Rail. |
SHARE_TAXI | Share taxi is a sort of bus transport with ability to drop off and pick up passengers anywhere on its route. Generally share taxi uses minibus vehicles. |
SUBWAY | Underground light rail. |
TRAM | Above ground light rail. |
TROLLEYBUS | Trolleybus. |
UnitSystem constants
google.maps . UnitSystem
constants
The valid unit systems that can be specified in a DirectionsRequest
.
Access by calling const {UnitSystem} = await google.maps.importLibrary("core")
. Maps JavaScript API-এ লাইব্রেরিগুলি দেখুন।
ধ্রুবক | |
---|---|
IMPERIAL | Specifies that distances in the DirectionsResult should be expressed in imperial units. |
METRIC | Specifies that distances in the DirectionsResult should be expressed in metric units. |
Distance interface
google.maps . Distance
interface
A representation of distance as a numeric value and a display string.
বৈশিষ্ট্য | |
---|---|
text | প্রকার: string A string representation of the distance value, using the UnitSystem specified in the request. |
value | প্রকার: number The distance in meters. |
Duration interface
google.maps . Duration
interface
A representation of duration as a numeric value and a display string.
বৈশিষ্ট্য | |
---|---|
text | প্রকার: string A string representation of the duration value. |
value | প্রকার: number The duration in seconds. |
Time interface
google.maps . Time
interface
A representation of time as a Date object, a localized string, and a time zone.
বৈশিষ্ট্য | |
---|---|
text | প্রকার: string A string representing the time's value. The time is displayed in the time zone of the transit stop. |
time_zone | প্রকার: string The time zone in which this stop lies. The value is the name of the time zone as defined in the IANA Time Zone Database, eg "America/New_York". |
value | Type: Date The time of this departure or arrival, specified as a JavaScript Date object. |
DirectionsTravelMode constants
google.maps . DirectionsTravelMode
constants
DirectionsUnitSystem constants
google.maps . DirectionsUnitSystem
constants