Documentation
¶
Index ¶
Constants ¶
View Source
const ( Forbidden = int64(1) Allow = int64(2) Formal = int64(3) Pay = int64(4) AllowDown = int64(1) ForbiddenDown = int64(0) AuthOK = 1 AuthNotOK = 0 )
auth const
Variables ¶
View Source
var ( PlayAuth = map[int64]string{ Forbidden: "play_forbidden", Allow: "play_allown", Formal: "play_formal_member", Pay: "play_pay_member", } DownAuth = map[int64]string{ ForbiddenDown: "down_forbidden", AllowDown: "down_allown", } )
for prom
Functions ¶
This section is empty.
Types ¶
type AnonymousIP ¶
type AnonymousIP struct { IsAnonymous bool `json:"is_anonymous" maxminddb:"is_anonymous"` IsAnonymousVPN bool `json:"is_anonymous_vpn" maxminddb:"is_anonymous_vpn"` IsHostingProvider bool `json:"is_hosting_provider" maxminddb:"is_hosting_provider"` IsPublicProxy bool `json:"is_public_proxy" maxminddb:"is_public_proxy"` IsTorExitNode bool `json:"is_tor_exit_node" maxminddb:"is_tor_exit_node"` }
AnonymousIP IP database.
type IP ¶
type IP struct { Addr string `json:"addr"` Country string `json:"country"` Province string `json:"province"` City string `json:"city"` ISP string `json:"isp"` ZoneID []int64 `json:"zone_id"` }
IP dont' use this, will del soon. use InfoComplete.
type Info ¶
type Info struct { Addr string `json:"addr"` Country string `json:"country"` Province string `json:"province"` City string `json:"city"` ISP string `json:"isp"` Latitude float64 `json:"latitude"` Longitude float64 `json:"longitude"` ZoneID int64 `json:"zoneId"` CountryCode int `json:"country_code"` }
Info ipinfo with the smallest zone_id.
type InfoComplete ¶
type InfoComplete struct { Addr string `json:"addr"` Country string `json:"country"` Province string `json:"province"` City string `json:"city"` ISP string `json:"isp"` Latitude float64 `json:"latitude"` Longitude float64 `json:"longitude"` ZoneID []int64 `json:"zone_id"` CountryCode int `json:"country_code"` }
InfoComplete ipinfo with all zone_id.
type TmpInfo ¶
type TmpInfo struct { Addr string `json:"addr"` ZoneID int64 `json:"zoneId"` Country string `json:"country"` Province string `json:"province"` City string `json:"city"` }
TmpInfo old api will del soon
type Version ¶
type Version struct { UpdateTimeV4 string `json:"ipv4_flagship_ipdb_update_time"` NewestV4 string `json:""ipv4_flagship_ipdb_newest_url` StableV4 string `json:"ipv4_flagship_ipdb_stable_url"` UpdateTimeV6 string `json:"ipv6_flagship_ipdb_update_time"` NewestV6 string `json:""ipv6_flagship_ipdb_newest_url` StableV6 string `json:"ipv6_flagship_ipdb_stable_url"` }
Version for check ip library.
Click to show internal directories.
Click to hide internal directories.