Documentation ¶
Index ¶
Constants ¶
View Source
const ( //CoordinatesMaxLength Maximum length of the coordinates array CoordinatesMaxLength = 500 //Polygon constant Polygon Polygon = "Polygon" //Multipolygon constant MultiPolygon Multipolygon = "MultiPolygon" //OsmURL Url to fetch the OSM data for an area OsmURL = "https://nominatim.openstreetmap.org/search.php?q=%s+&polygon_geojson=1&format=json" // nominatim is a UI for OSM data //Administrative is a type of geoJSON Administrative = "administrative" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GeometryUtils ¶
GeometryUtils struct to configure GeometryUtils
func (*GeometryUtils) CombinePolygons ¶
func (g *GeometryUtils) CombinePolygons(ctx context.Context, areas []string) (schema.GeoJson, error)
CombinePolygons function to combine polygons or multipolygons
func (*GeometryUtils) FetchPolygons ¶
func (g *GeometryUtils) FetchPolygons(ctx context.Context, areas []string) ([]schema.GeoJson, error)
FetchPolygons function gets the definitions from OSM
Click to show internal directories.
Click to hide internal directories.