在Here iOS SDK中,如何在点击时使NMAMapMarker显示标注? [英] In the Here iOS SDK, how can I make an NMAMapMarker show a callout when tapped?

查看:56
本文介绍了在Here iOS SDK中,如何在点击时使NMAMapMarker显示标注?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在构建一个包含Here map&搜索功能,而我目前正在使用入门版" SDK.当前,当应用执行搜索时,会为每个搜索结果创建一个NMAMapMarker.我希望用户点击MapMarker时地图显示某种标注或信息框(例如,当您点击Apple Maps中的图钉时会发生什么),但我不知道SDK中是否包含此功能

I'm building an iOS app that includes Here map & search features, and I'm currently using the "starter" SDK. Currently, when the app performs a search, an NMAMapMarker is created for each search result. I'd like the map display some kind of callout or information box when the user taps on a MapMarker (like what happens when you tap a pin in Apple Maps), but I can't figure out if this feature is included in the SDK.

我知道有一个didSelectObject委托方法,但是我是否必须创建一个自定义视图并手动显示它?我还注意到,"Premium" SDK包含一个NMAMapOverlay.轻按时,这是显示信息框的更好选择吗?最后,我在NMAView的继承图中注意到( https://developer.here.com/mobile-sdks/documentation/ios-hybrid-plus/topics_api_nlp_hybrid_plus/interfacenmaviewobject.html )中有一个NMALabledMapMarker,但我在API中找不到其他任何相关信息参考.这是在MapMarker上显示有关位置的一些基本信息的好方法吗?在Here地图上显示某地方的基本信息的最佳方法是什么?

I know there's a didSelectObject delegate method, but do I have to create a custom view and manually present it? I also noticed that the "Premium" SDK includes an NMAMapOverlay. Is this a better option for displaying info boxes when being tapped? And finally, I noticed in the inheritance diagram of NMAView (https://developer.here.com/mobile-sdks/documentation/ios-hybrid-plus/topics_api_nlp_hybrid_plus/interfacenmaviewobject.html) there's an NMALabledMapMarker, but I can't find anything else about it in the API reference. Would this be a good way to show some basic information about a place on a MapMarker? What's the best way to show basic info about a place on a Here map?

推荐答案

NMAMapOverlay现在是唯一的选项.此功能仅在适用于iOS Premium的HERE SDK中提供.

The NMAMapOverlay is the only option right now. This functionality is only provided within the HERE SDK for iOS Premium.

这篇关于在Here iOS SDK中,如何在点击时使NMAMapMarker显示标注?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆