ipregion

package
v0.0.0-...-e7f8777 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IP2Region

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

func NewIP2Region

func NewIP2Region(path string) (*IP2Region, error)

func (*IP2Region) Search

func (r *IP2Region) Search(ip string) (*IPInfo, error)

type IPInfo

type IPInfo struct {
	Country string
	Region  string
	City    string
	ISP     string
}

type IPRegion

type IPRegion interface {
	Search(ip string) (*IPInfo, error)
}

Jump to

Keyboard shortcuts

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