Documentation ¶
Index ¶
- func GetAndUnmarshalXML[T any](ctx context.Context, httpClient *HttpClient, url string, ...) (*T, error)
- func HostEtcJoin(parts ...string) string
- func HostVarJoin(parts ...string) string
- func UrlHasSuffix(rawUrl string, suffix string) bool
- func UrlJoinPath(base string, elems ...string) (string, error)
- type FetchedData
- type HttpClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAndUnmarshalXML ¶
func HostEtcJoin ¶
func HostVarJoin ¶
func UrlHasSuffix ¶
Types ¶
type FetchedData ¶
type FetchedData struct {
// contains filtered or unexported fields
}
func (*FetchedData) Data ¶
func (d *FetchedData) Data() ([]byte, error)
func (*FetchedData) Reader ¶
func (d *FetchedData) Reader() (io.ReadCloser, error)
type HttpClient ¶
type HttpClient struct {
// contains filtered or unexported fields
}
func NewHttpClientFromInner ¶
func NewHttpClientFromInner(inner *http.Client) *HttpClient
func (*HttpClient) Get ¶
func (hc *HttpClient) Get(ctx context.Context, url string) (FetchedData, error)
func (*HttpClient) GetWithChecksum ¶
func (hc *HttpClient) GetWithChecksum(ctx context.Context, url string, checksum *types.Checksum) (FetchedData, error)
Click to show internal directories.
Click to hide internal directories.