Documentation ¶
Index ¶
- func Register(name string, fnc ProviderFunc)
- type ErrHTTPStatus
- type HTTPClient
- func (c *HTTPClient) DoHTML(ctx context.Context, req *http.Request) (*goquery.Document, error)
- func (c *HTTPClient) DoRaw(ctx context.Context, req *http.Request) (*http.Response, error)
- func (c *HTTPClient) Get(ctx context.Context, path string, params url.Values) (*http.Response, error)
- func (c *HTTPClient) GetHTML(ctx context.Context, path string, params url.Values) (*goquery.Document, error)
- func (c *HTTPClient) GetJSON(ctx context.Context, path string, params url.Values, dst interface{}) error
- func (c *HTTPClient) GetRequest(path string, params url.Values) (*http.Request, error)
- func (c *HTTPClient) GetXML(ctx context.Context, path string, params url.Values, dst interface{}) error
- func (c *HTTPClient) PostHTML(ctx context.Context, path string, params url.Values) (*goquery.Document, error)
- func (c *HTTPClient) SetHTTPClient(cli *http.Client)
- type Provider
- type ProviderFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Register ¶
func Register(name string, fnc ProviderFunc)
Types ¶
type ErrHTTPStatus ¶
func (*ErrHTTPStatus) Error ¶
func (e *ErrHTTPStatus) Error() string
type HTTPClient ¶
type HTTPClient struct {
// contains filtered or unexported fields
}
func NewHTTPClient ¶
func NewHTTPClient(base string) HTTPClient
func (*HTTPClient) GetRequest ¶
func (*HTTPClient) SetHTTPClient ¶
func (c *HTTPClient) SetHTTPClient(cli *http.Client)
type ProviderFunc ¶
func List ¶
func List() []ProviderFunc
Click to show internal directories.
Click to hide internal directories.