Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // FeedEnd this error happens when the feed runs out of proxies to check FeedEnd = errors.New("feed end") )
View Source
var Judges = map[string]Judge{ "azenv.php": AZEnvPhpJudge{}, "proxyjudge.us": ProxyjudgeUsJudge{}, }
Functions ¶
Types ¶
type AZEnvPhpJudge ¶ added in v0.0.2
type AZEnvPhpJudge struct{}
func (AZEnvPhpJudge) TargetURL ¶ added in v0.0.2
func (j AZEnvPhpJudge) TargetURL() string
func (AZEnvPhpJudge) Timeout ¶ added in v0.0.2
func (j AZEnvPhpJudge) Timeout() time.Duration
type CheckResult ¶ added in v0.0.2
func Check ¶ added in v0.0.2
func Check(proxyAddr string, judge Judge) (result CheckResult)
type Feed ¶ added in v0.0.2
type Feed interface { // Next // Returns a string in ip:port format of the next proxy to check Next() (string, error) }
Feed Data source interface. Encapsulates the logic of extracting the next proxy for verification.
type FileFeed ¶ added in v0.0.2
type FileFeed struct {
// contains filtered or unexported fields
}
FileFeed Proxy feed from file stream, like stdin, os file.
func NewFileFeed ¶ added in v0.0.2
type Judge ¶ added in v0.0.2
type Judge interface { // TargetURL Returns the url to which you need to contact through the proxy TargetURL() string // Timeout Returns the recommended timeout for this referee Timeout() time.Duration }
Judge The proxy judge encapsulates the logic of interaction with the proxy judge
type ProxyjudgeUsJudge ¶ added in v0.0.5
type ProxyjudgeUsJudge struct{}
func (ProxyjudgeUsJudge) TargetURL ¶ added in v0.0.5
func (j ProxyjudgeUsJudge) TargetURL() string
func (ProxyjudgeUsJudge) Timeout ¶ added in v0.0.5
func (j ProxyjudgeUsJudge) Timeout() time.Duration
type SliceFeed ¶ added in v0.0.2
type SliceFeed struct {
// contains filtered or unexported fields
}
SliceFeed Proxy feed from string slice like this []string{"108.20.30.1:500", "89.33.123.100:40", "50.73.100.1:55"}
func NewSliceFeed ¶ added in v0.0.2
Source Files ¶
Click to show internal directories.
Click to hide internal directories.