netparser

package
v0.0.0-...-c355f4f Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CloseIPGeoLocation

func CloseIPGeoLocation()

CloseIPGeoLocation 关闭查询服务(可选,但推荐在程序退出时调用)

func ExtractIPRegionDB

func ExtractIPRegionDB() (string, error)

ExtractIPRegionDB 从嵌入的文件系统中提取 IP2Region 数据库

func GetIPLocation

func GetIPLocation(ip string) (string, string, error)

GetIPLocation 获取 IP 的地理位置信息

func InitIPGeoLocation

func InitIPGeoLocation() error

InitIPGeoLocation 初始化 IP 地理位置查询

func InitPVFilters

func InitPVFilters()

InitPVFilters 初始化PV过滤规则

func ParseUserAgent

func ParseUserAgent(uaString string) (browser, os, device string)

ParseUserAgent 解析 User-Agent 字符串

func ShouldCountAsPageView

func ShouldCountAsPageView(statusCode int, path string, ip string) int

ShouldCountAsPageView 判断是否符合 PV 过滤条件

Types

This section is empty.

Jump to

Keyboard shortcuts

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