rgeod

package
v0.0.0-...-4c2d33b Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrAlreadyRunning = errors.New("rgeo daemon already running")
View Source
var ErrNotReady = errors.New("rgeo daemon not ready")

Functions

This section is empty.

Types

type ReverseGeocodeService

type ReverseGeocodeService struct {
	*RgeoDaemon
}

func (*ReverseGeocodeService) GetGeometry

func (*ReverseGeocodeService) GetLocation

func (*ReverseGeocodeService) Ping

type RgeoDaemon

type RgeoDaemon struct {
	// contains filtered or unexported fields
}

RgeoDaemon is the daemon for the rgeod RPC service. Rgeo is useful as a daemon because - it takes a long time (1m?) to initialize an instance with all datasets (cities, countries, provinces, US counties) - it might make sense to cache calls to avoid hitting the actual backing rgeo API - there might be other uses in other places for reverse geocoding later, and transport agnostic keeps options open.

func NewDaemon

func NewDaemon(config *params.RgeoDaemonConfig) (*RgeoDaemon, error)

func (*RgeoDaemon) Start

func (d *RgeoDaemon) Start() error

Start starts the daemon and does not wait for it to complete.

func (*RgeoDaemon) Stop

func (d *RgeoDaemon) Stop() error

Stop stops the daemon and waits for it to complete.

Jump to

Keyboard shortcuts

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