Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

client class should be replaceable #22

Closed
nilsnolde opened this issue Jun 11, 2021 · 1 comment
Closed

client class should be replaceable #22

nilsnolde opened this issue Jun 11, 2021 · 1 comment

Comments

@nilsnolde
Copy link
Member

nilsnolde commented Jun 11, 2021

The main advantage of this package IMO is the parsing of the response. We could re-use this in our valhalla QGIS plugin, but for that to work we need to be able to replace the client with a custom one (not using the requests package, but QgsNetworkAccessManager). That's a little bit of a bigger job of refactoring to make it possible:

  • change the pattern to not have a base Router class but rather a client class which can get passed to the individual router classes
  • the new (default) client class should be an abstract base class (similar to Router right now) which one can inherit from to build a new client class

should be doable in a backwards-compatible way.

@nilsnolde
Copy link
Member Author

landed with #25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant