Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRetryableClient ¶
NewRetryableClient creates a new http client with retryablehttp.Client as transport
Types ¶
type RFC7232HttpClient ¶
type RFC7232HttpClient struct {
// contains filtered or unexported fields
}
RFC7232HttpClient is a custom client with support for RFC7232 conditional headers
func NewRfc7232HttpClient ¶
func NewRfc7232HttpClient() *RFC7232HttpClient
NewRfc7232HttpClient initializes a new RFC7232HttpClient using the NewRetryableClient function
func (*RFC7232HttpClient) GetWithCondition ¶
func (hc *RFC7232HttpClient) GetWithCondition(url string, etag string, lastModified time.Time) (*http.Response, error)
GetWithCondition reads a file from an HTTP endpoint using conditional headers
func (*RFC7232HttpClient) ReadRemoteOrCached ¶
func (hc *RFC7232HttpClient) ReadRemoteOrCached(url string) (io.ReadCloser, error)
Click to show internal directories.
Click to hide internal directories.