Geometry Library

Lớp mã hoá

Lớp google.maps.geometry.encoding

Tiện ích để mã hoá và giải mã đường nhiều đoạn.

Truy cập bằng cách gọi const {encoding} = await google.maps.importLibrary("geometry").
Xem Thư viện trong Maps JavaScript API.

decodePath
decodePath(encodedPath)
Tham số: 
  • encodedPathstring
Giá trị trả về:  Array<LatLng>
Giải mã một chuỗi đường dẫn được mã hoá thành một chuỗi LatLng.
encodePath
encodePath(path)
Tham số: