简体   繁体   English

如何删除tomtom maps sdk中的路由?

[英]How to remove route in tomtom maps sdk?

Is there a way to remove the route without clearing the markers?有没有办法在不清除标记的情况下删除路线? Using function clear() is really bad.使用函数 clear() 真的很糟糕。

 tomtomMap.clear();
    route = null;
    origin = null;
    destination = null;

Is there a function clearRoute() that do not clear the markers.是否有不清除标记的函数 clearRoute()。

Take a look at the API reference看一下API参考

https://d221h2fa9j1k6s.cloudfront.net/downloads/mapssdk/APIReferences/JavaDocMap_2.4.376/index.html https://d221h2fa9j1k6s.cloudfront.net/downloads/mapssdk/APIReferences/JavaDocMap_2.4.376/index.html

I was able to test the function in my project and verified that it works.我能够在我的项目中测试该功能并验证它是否有效。

tomtomMap.clearRoute() should solve your problem. tomtomMap.clearRoute() 应该可以解决您的问题。

Regards!问候!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM