Open 1ec5 opened 6 years ago
mapbox/mapbox-java#582 is the equivalent issue for the Android and Java SE platforms.
https://github.com/mapbox/mapbox-java/issues/582#issuecomment-350839494 points out that there are a ton of possible values, which may make it impractical to provide constants for each value. How else would be we improve the discoverability of this feature?
The Geocoding API has introduced experimental support for category search, which is analogous to MapKit’s MKLocalSearch/MKLocalSearchRequest API. The Geocoding API doesn’t currently support natural language queries; instead, you specify one of a number of predefined keywords as the query and
pointOfInterest
as thescope
(and typically afocalLocation
). An application can present the user with a series of buttons for common categories to search for, similar to the one in Apple’s Maps application.Category search currently works without any modifications to this library. However, we can improve the feature’s discoverability by providing an enumeration of the supported categories. Since the set of categories is open-ended and subject to change, it’ll need to be an extensible string enumeration, similar to the profile identifiers exposed by MapboxDirections.swift. We should mark this enumeration with the
- experimental
documentation command until the “Preview” tag is removed from the API documentation./cc @frederoni @bsudekum