Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GeoService ¶
type GeoService struct { // Filename of the MaxMind city database ("GeoIP2-City.mmdb"). Path string // contains filtered or unexported fields }
GeoService is a service for looking up geolocation by IP address using a MaxMind database.
https://dev.maxmind.com/geoip/geoip2/geolite2/
func (*GeoService) Close ¶
func (s *GeoService) Close() error
Close closes the internal reader, if set.
func (*GeoService) Open ¶
func (s *GeoService) Open() (err error)
Open initializes the internal reader with the service's file path.
Click to show internal directories.
Click to hide internal directories.