Documentation ¶
Index ¶
- type CookieJar
- type HttpClient
- func (this *HttpClient) SetCookieJar(j *CookieJar) *HttpClient
- func (this *HttpClient) SetProxy(proxyUrl string)
- func (this *HttpClient) SetRedirect(f func(req *http.Request, via []*http.Request) error) *HttpClient
- func (this *HttpClient) SetSkipVerify(isSkipVerify bool)
- func (this *HttpClient) SetTimeout(t time.Duration) *HttpClient
- func (this *HttpClient) SetTransport(t *http.Transport) *HttpClient
- type Request
- func (this *Request) End() (*http.Response, string, error)
- func (this *Request) EndBytes() (*http.Response, []byte, error)
- func (this *Request) EndFile(savePath, saveFileName string) (*http.Response, error)
- func (this *Request) Send(a ...interface{}) *Request
- func (this *Request) SetCookies(cookies *[]*http.Cookie) *Request
- func (this *Request) SetData(name, value string) *Request
- func (this *Request) SetFileData(name, value string, isFile bool) *Request
- func (this *Request) SetHeader(name, value string) *Request
- func (this *Request) SetJsonData(s string) *Request
- func (this *Request) SetMethod(name string) *Request
- func (this *Request) SetUrl(url string) *Request
- func (this *Request) SetVerbose(d bool) *Request
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CookieJar ¶
type CookieJar struct {
// contains filtered or unexported fields
}
func NewCookieJar ¶
func NewCookieJar() *CookieJar
type HttpClient ¶
type HttpClient struct {
// contains filtered or unexported fields
}
func NewHttpClient ¶
func NewHttpClient() *HttpClient
func (*HttpClient) SetCookieJar ¶
func (this *HttpClient) SetCookieJar(j *CookieJar) *HttpClient
func (*HttpClient) SetProxy ¶
func (this *HttpClient) SetProxy(proxyUrl string)
func (*HttpClient) SetRedirect ¶
func (this *HttpClient) SetRedirect(f func(req *http.Request, via []*http.Request) error) *HttpClient
func (*HttpClient) SetSkipVerify ¶
func (this *HttpClient) SetSkipVerify(isSkipVerify bool)
func (*HttpClient) SetTimeout ¶
func (this *HttpClient) SetTimeout(t time.Duration) *HttpClient
func (*HttpClient) SetTransport ¶
func (this *HttpClient) SetTransport(t *http.Transport) *HttpClient
type Request ¶
type Request struct {
// contains filtered or unexported fields
}
func NewRequest ¶
func NewRequest(client *HttpClient) *Request
func (*Request) SetFileData ¶
func (*Request) SetJsonData ¶
func (*Request) SetVerbose ¶
Click to show internal directories.
Click to hide internal directories.