powergate: github.com/textileio/powergate/iplocation Index | Files | Directories

package iplocation

import "github.com/textileio/powergate/iplocation"

Index

Package Files

iplocation.go

Variables

var (
    // ErrCantResolve indicates that geoinformation couldn't be resolved for a host.
    ErrCantResolve = errors.New("can't resolve multiaddr location information")
)

type Location Uses

type Location struct {
    Country   string
    Latitude  float64
    Longitude float64
}

Location contains geoinformation.

type LocationResolver Uses

type LocationResolver interface {
    Resolve(mas []multiaddr.Multiaddr) (Location, error)
}

LocationResolver resolver gets location information from a set of multiaddresses of a single host.

Directories

PathSynopsis
maxmind

Package iplocation imports 2 packages (graph) and is imported by 18 packages. Updated 2020-09-21. Refresh now. Tools for package owners.