BHoM / BHoM/OpenStreetMap_Toolkit
Wrap GeoSearch queries into a single method
- Dominant language
- C#
- Stars
- 4
- Forks
- 2
- Avg merge
- 10d 18h
- Merged PRs (30d)
- 1
Description
Anticipating #67 (name based queries) that will add to the existing OpenStreetMap type queries based on key value pairs the proposal here is to consider generalising the geospatial search.
The goal is to make a user friendly `GeoSearch` that returns a `GetRequest` ready for the `HTTPAdapter` to Pull (or maybe the HTTPAdapter part is also wrapped up and return results?)

4 simple inputs are the input basic requirement:
1. searchFor (mandatory)
2. searchIn (optional)
3. settings (optional)
4. active (run)
### Mandatory **what to search for**
- OSM objects (defined by standard OSM key or **category** and type (if no type all types in category))
- Addresses (or part addresses)
- Free form queries (taking advantage of [Nominatim special phrases](https://wiki.openstreetmap.org/wiki/Nominatim/Special_Phrases/EN))

### Optional **where to search in** (default is the world):
- latitude, longitude point and radius string
- point (as per[ geojson point spec](https://datatracker.ietf.org/doc/html/rfc7946#section-3.1.2)) and radius
- boundingbox (as per [geojson spec](https://datatracker.ietf.org/doc/html/rfc7946#section-5))
- polygon (as per [geojson spec](https://datatracker.ietf.org/doc/html/rfc7946#section-3.1.6))

### Optional **settings** (default is to return geojson formatted data + polygons, limit result to 50, provide all details, search all countries)

At most simple this could unlock the potential of a search like this:

Steps towards this (each an individual PR):
1. Merge PR #66
2. Add basic unwrapped Nominatin requests #67
3. Add prototype GeoJson objects (just in the OpenStreetMap_Toolkit as a start)
4. Add converts ToGeoJson and FromGeoJson (including extending the ToUTM converts to convert GeoJson to Universal Transverse Mercator)
5. Add OpenStreetMap_Toolkit request builder to return a correctly configured `GetRequest`.
6. Wrap the GeoSearch as described above.
@rwemay @al-fisher any further thoughts on this one?
Contributor guide
Assessment
This issue has not been assessed yet.