Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientProvider ¶
type ClientProvider struct {
// contains filtered or unexported fields
}
ClientProvider ...
func NewClientProvider ¶
func NewClientProvider(timeout time.Duration, allowRedirect bool) *ClientProvider
NewClientProvider initiate a new client object
timeout - http request time allowRedirect - allow request redirects on requested url or not
func (*ClientProvider) Request ¶
func (h *ClientProvider) Request(url string, method string, header map[string]string, body []byte, params map[string]string) (statusCode int, resBody []byte, err error)
Request http
func (*ClientProvider) RequestCSV ¶
func (h *ClientProvider) RequestCSV(url string) ([][]string, error)
RequestCSV requests http API that returns csv result
Click to show internal directories.
Click to hide internal directories.