model

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Proxy

type Proxy struct {
	IP        string    `json:"ip"`
	Port      string    `json:"port"`
	Type      ProxyType `json:"type"`      // 代理类型
	Anonymous bool      `json:"anonymous"` // 是否高匿
	Speed     int64     `json:"speed"`     // 响应速度(毫秒)
	Score     int       `json:"score"`     // 可用性评分
	LastCheck time.Time `json:"last_check"`
}

type ProxyList

type ProxyList []*Proxy

type ProxyType

type ProxyType string

ProxyType 代理类型

const (
	ProxyTypeHTTP   ProxyType = "http"
	ProxyTypeHTTPS  ProxyType = "https"
	ProxyTypeSOCKS4 ProxyType = "socks4"
	ProxyTypeSOCKS5 ProxyType = "socks5"
)

func (ProxyType) IsValid

func (t ProxyType) IsValid() bool

IsValid 检查代理类型是否有效

Jump to

Keyboard shortcuts

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