geonames

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Geonames

type Geonames struct {
	URL  *string
	Path *string
}

Geonames implements neargo.GeoSource by downloading and parsing a zip file from geonames.org.

func (*Geonames) Flag

func (g *Geonames) Flag()

Flag adds cli flags to configure Geonames using the cli.

func (Geonames) GetGeoData

func (g Geonames) GetGeoData() (result []server.Geo, err error)

GetGeoData downloads a geonames zip file (if it doesn't exist yet), unpacks it and then parses the csv files in it. (ignoring "readme.txt" file)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL