package
0.0.0-20250116175909-676c6f4008ca
Repository: https://github.com/wealeson1/wcpvs.git
Documentation: pkg.go.dev

# Functions

AddParam 根据不同的请求方法添加参数,目前先不考虑其他类型的参数,JSON或者XML。.
CacheMissByAge 判断缓存是否命中,根据响应中的Age.
CacheMissByExpires 判断缓存是否命中,根据响应中的 Expires 头.
CacheMissByOthers 判断缓存是否命中,根据响应中的其他可疑头.
CacheMissByXCH 判断缓存是否命中,根据响应中的X-Cache-Hits.
CacheMissByXI 判断缓存是否命中,根据响应中的X-Iinfo.
CloneRequest 克隆一个 *http.Request 对象,包括其方法、URL、头字段和正文。.
CloseReader 关闭Read,如果存在错误使程序崩溃.
HasCustomHeaders 检查响应中是否存在 customHeaders 中的响应头 respHeaders 必须是两个请求的后一个响应的响应头.
No description provided by the author
IsCacheMiss 根据响应的 Header 判断是否命中缓存,未命中返回true,命中返回false.
IsCacheValidByAge 根据响应头中的 Age 判断是否命中缓存.
IsCacheValidByExpires 根据 Expire 和 Date 判断是否存在缓存机制.
IsCacheValidByOtherCustomHeaders 根据其他的 CustomHeaders 判断是否存在缓存机制.
IsCacheValidByXCacheHits 根据响应头中的 x-cache-hits 判断缓存是否有效.
IsCacheValidByXInfo 根据响应头中的 x-iinfo 判断缓存是否有效.
NewCrawler returns a new standard crawler instance.
RandInt64 生成一个安全的随机 int64 值。 @param nil @return int64 返回生成的随机int64.
No description provided by the author
RandomString 生成一个指定长度的随机字符串 @param len int 指定生成随机数的长度 @return string 返回生成的随机字符串,长度为 param len.
ReadFileToSlice 读取文件的每行,返回一个[]string @param path string 待读取文件路径 @return result []string 读取的内容 @return err error 错误类型.
removeDuplicatesAndParams 处理URL列表,移除参数并去重.

# Variables

No description provided by the author
No description provided by the author

# Structs

Crawler is a standard crawler instance.
No description provided by the author