qqwry

package
v1.0.205 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func OnlineDownload

func OnlineDownload()

Types

type Client

type Client struct {
	Offset   uint32
	ItemLen  uint32
	IndexLen uint32
}

func New

func New(filepath string) (*Client, error)

func NewBuff added in v1.0.161

func NewBuff(file []byte) (*Client, error)

func (*Client) Query

func (c *Client) Query(ipAddress net.IP) (result QueryResult, err error)

Query ip地址查询对应归属地信息

func (*Client) QueryIP added in v1.0.161

func (c *Client) QueryIP(ipAddressStr string) (result QueryResult, err error)

QueryIP ip地址查询对应归属地信息

type QueryResult

type QueryResult struct {
	Ip      string `json:"ip,omitempty"`      // ip
	Country string `json:"country,omitempty"` // 国家或地区
	Area    string `json:"area,omitempty"`    // 区域
}

QueryResult 返回

Jump to

Keyboard shortcuts

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