Documentation
¶
Index ¶
- func ReadAll(r io.Reader, size int) (buff []byte, err error)
- func UnZipHttpResp(response *http.Response, size int) ([]byte, error)
- func UnZipRetryResp(response *resty.Response, size int) ([]byte, error)
- type ApiSpider
- type Buffer
- type CloudflareSpider
- type CookieCallBack
- type DhtmlSpider
- type FileSpider
- type ProxyCallBack
- type Request
- type Response
- type ShtmlSpider
- type SocketProxyCallBack
- type Spider
- type SpiderType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UnZipHttpResp ¶ added in v0.7.8
func UnZipRetryResp ¶ added in v0.7.8
Types ¶
type ApiSpider ¶
func NewSingleApiSpider ¶ added in v0.6.4
type Buffer ¶
type Buffer struct {
// contains filtered or unexported fields
}
先看一下Buffer的定义,有帮助下面理解
type CloudflareSpider ¶ added in v0.7.0
func NewCloudflareSpider ¶ added in v0.7.0
func NewCloudflareSpider(size int) *CloudflareSpider
请求数据最大size限制
type CookieCallBack ¶ added in v0.3.3
type DhtmlSpider ¶
type DhtmlSpider struct {
// contains filtered or unexported fields
}
func NewDhtmlSpider ¶
func NewDhtmlSpider() *DhtmlSpider
type FileSpider ¶
func NewSingleFileSpider ¶ added in v0.6.4
func NewSingleFileSpider(size int) *FileSpider
type ProxyCallBack ¶
type ProxyCallBack func() string
type Request ¶
type Request struct { Url string Method string Param string Headers map[string]string Timeout time.Duration Retry int ProxyCallBack ProxyCallBack SocketProxyCallBack SocketProxyCallBack CookieCallBack CookieCallBack }
type Response ¶
type Response struct { RedirectUrl string Cookies []*http.Cookie Header http.Header SpiderType SpiderType // contains filtered or unexported fields }
func (*Response) GetCharset ¶
func (*Response) GetContent ¶
type ShtmlSpider ¶
func NewSingleShtmlSpider ¶ added in v0.6.4
type SocketProxyCallBack ¶ added in v0.2.4
Source Files
¶
Click to show internal directories.
Click to hide internal directories.