andreynovikov / trekarta

Simple, responsive map for your trek. You decide how to journey today, not the application!
https://trekarta.info
GNU General Public License v3.0
169 stars 25 forks source link

Introduce a new map provider API which enables not to know maps at compile-time #194

Closed qnga closed 6 months ago

qnga commented 2 years ago

Related to #182.

This new API will enable to develop a plugin letting users select maps of interest from a built-in repository, and even provide their own WMTS URLs.

qnga commented 2 years ago

Hello, Do you plan to review this PR? I've got my plugin basically ready for publishing. It wouldn't make much sense if it's not compatible with a published Trekarta build though.

StrikeLines commented 1 year ago

We are also very interested in using this PR to view WMTS. Any plans to merge it with production?

andreynovikov commented 7 months ago

If you are still interested, I will work on that.

qnga commented 7 months ago

I am still interested!

andreynovikov commented 7 months ago

Ok, can you fix conflicts as I've made many changes to MainActivity.java since that. And can you also explain what you mean by "not to know maps at compile-time"? This is about plugin compilation, yes?

andreynovikov commented 7 months ago

Also I would prefer if you will rewrite current providers instead of introducing new ones. As all current plugins are written by me: https://github.com/andreynovikov/trekarta-online-maps I would rather update them to conform with new API.

andreynovikov commented 7 months ago

May be you also have any idea on this?

qnga commented 7 months ago

And can you also explain what you mean by "not to know maps at compile-time"? This is about plugin compilation, yes?

Yes, with my API, maps are not necessarily known when you compile the plugin app. That enables plugin apps to let users choose maps they are interested in and provide service keys for them.

I'll update the PR soon.

qnga commented 7 months ago

Done. I merged master and removed the old map provider API.

As to tile expiration, I guess we could use HTP cache-control headers. I don't think that would be related to plugins though, as they provide URLs for tiles rather than doing any request themselves.