【问题标题】:Retrieval of Area Shapes - Here Maps API with V7区域形状的检索 - Here Maps API with V7
【发布时间】:2021-08-19 17:54:12
【问题描述】:

有没有办法检索多个多边形, 例如,如果我应该使用附加数据作为 'city' 搜索 "ABC""XYZ",那么我应该都被绘制多边形。

据我了解,在 V6.2 中,我们只能使用 searchText 和附加数据检索单个多边形。

【问题讨论】:

    标签: here-api geocode here-maps-rest


    【解决方案1】:

    我不清楚这个要求。你能分享一个请求的例子吗?

    通常,响应包含一个 Shape 元素,其中包含 WKT(众所周知的文本)格式的请求大纲。根据请求的区域是否连续,这将是 POLYGON 或 MULTIPOLYGON 几何体。

    例如:

    https://geocoder.api.here.com/6.2/geocode.json
    ?app_id={{app_id}}
    &app_code={{app_code}}
    &searchtext=10115+DE
    &additionaldata=IncludeShapeLevel,postalCode

    示例响应

    "Shape": {
    "_type": "WKTShapeType",
    "Value": "POLYGON ((13.36566 52.53586, 13.36575 52.53579, 13.36582 52.53574, 13.36599 52.53564, ..., 13.36566 52.53586))"
    }

    可以使用 JavaScript 绘制响应数据。 这是使用地理编码版本 6 的示例:https://developer.here.com/cn/documentation/geocoder/topics/example-reverse-geocoding-shape.html

    但是,最新的 Geocode 版本 7 目前缺少此功能。 https://developer.here.com/documentation/geocoding-search-api/migration_guide/migration-geocoder/topics-api/geocoding.html

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-09-07
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多