Documentation
¶
Index ¶
- type Client
- func (c *Client) Delete(ctx context.Context, req *Request, resp interface{}) error
- func (c *Client) Get(ctx context.Context, req *Request, resp interface{}) error
- func (c *Client) Post(ctx context.Context, req *Request, resp interface{}) error
- func (c *Client) Put(ctx context.Context, req *Request, resp interface{}) error
- type Option
- type Request
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is the client for HTTP requests.
type Option ¶ added in v0.0.2
type Option interface {
Apply(cli *Client)
}
func WithGlobalTimeout ¶ added in v0.0.2
WithGlobalTimeout is the option that adds global timeout to the client.
Example:
WithGlobalTimeout(time.Second * 5)
Click to show internal directories.
Click to hide internal directories.