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

Support multiple road classes in RouteOptions.roadClassesToAvoid and RouteOptions.roadClassesToAllow properties #664

Merged
merged 8 commits into from
Mar 18, 2022

Conversation

azarovalex
Copy link
Contributor

Directions server-side API now allows passing multiple road classes in these fields, so the corresponding SDK code is updated.

Looks like RoadClasses.tunnel and RoadClasses.restricted are not supported by Directions API in RouteOptions.roadClassesToAvoid anymore, so I updated documentation for these properties.

Error when trying to avoid tunnels:
image

@1ec5 Looks like RoadClasses.tunnel and RoadClasses.restricted were only used in RouteOptions.roadClassesToAvoid , now that Directions API doesn't support them, should we mark these properties as deprecated?

@azarovalex azarovalex force-pushed the azarovalex/multiple-avoid-classes branch from fc62551 to 8da8838 Compare March 14, 2022 17:36
@azarovalex azarovalex requested review from 1ec5 and a team March 14, 2022 19:56
@1ec5
Copy link
Contributor

1ec5 commented Mar 16, 2022

Looks like RoadClasses.tunnel and RoadClasses.restricted were only used in RouteOptions.roadClassesToAvoid , now that Directions API doesn't support them, should we mark these properties as deprecated?

No, these options are still used by Intersection.outletRoadClasses. It’s just that the developer can’t use them with RouteOptions.

Sources/MapboxDirections/RoadClasses.swift Outdated Show resolved Hide resolved
Sources/MapboxDirections/RouteOptions.swift Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
@azarovalex azarovalex requested review from 1ec5 and bamx23 March 17, 2022 16:55
@azarovalex azarovalex merged commit eb7b3b4 into main Mar 18, 2022
@azarovalex azarovalex deleted the azarovalex/multiple-avoid-classes branch March 18, 2022 10: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

Successfully merging this pull request may close these issues.

3 participants