Documentation
¶
Index ¶
- type DownloadAsFileOptions
- func (d *DownloadAsFileOptions) GetDeepCopy() (copy *DownloadAsFileOptions)
- func (d *DownloadAsFileOptions) GetOutputPath() (outputPath string, err error)
- func (d *DownloadAsFileOptions) GetOverwriteExisting() (overwriteExisting bool)
- func (d *DownloadAsFileOptions) GetRequestOptions() (requestOptions *RequestOptions, err error)
- func (d *DownloadAsFileOptions) SetOutputPath(outputPath string) (err error)
- func (d *DownloadAsFileOptions) SetOverwriteExisting(overwriteExisting bool)
- func (d *DownloadAsFileOptions) SetRequestOptions(requestOptions *RequestOptions) (err error)
- type RequestOptions
- func (r *RequestOptions) GetDeepCopy() (copy *RequestOptions)
- func (r *RequestOptions) GetMethod() (method string, err error)
- func (r *RequestOptions) GetMethodOrDefault() (method string, err error)
- func (r *RequestOptions) GetPort() (port int, err error)
- func (r *RequestOptions) GetSkipTLSvalidation() (skipTLSvalidation bool)
- func (r *RequestOptions) GetUrl() (url string, err error)
- func (r *RequestOptions) IsMethodSet() (isSet bool)
- func (r *RequestOptions) SetMethod(method string) (err error)
- func (r *RequestOptions) SetPort(port int) (err error)
- func (r *RequestOptions) SetSkipTLSvalidation(skipTLSvalidation bool)
- func (r *RequestOptions) SetUrl(url string) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DownloadAsFileOptions ¶
type DownloadAsFileOptions struct {
RequestOptions *RequestOptions
OutputPath string
OverwriteExisting bool
// If Sha256Sum is set:
// - The download will be skipped if OutputPath has already the expected content.
// - The download is validated.
Sha256Sum string
}
func NewDownloadAsFileOptions ¶
func NewDownloadAsFileOptions() (d *DownloadAsFileOptions)
func (*DownloadAsFileOptions) GetDeepCopy ¶
func (d *DownloadAsFileOptions) GetDeepCopy() (copy *DownloadAsFileOptions)
func (*DownloadAsFileOptions) GetOutputPath ¶
func (d *DownloadAsFileOptions) GetOutputPath() (outputPath string, err error)
func (*DownloadAsFileOptions) GetOverwriteExisting ¶
func (d *DownloadAsFileOptions) GetOverwriteExisting() (overwriteExisting bool)
func (*DownloadAsFileOptions) GetRequestOptions ¶
func (d *DownloadAsFileOptions) GetRequestOptions() (requestOptions *RequestOptions, err error)
func (*DownloadAsFileOptions) SetOutputPath ¶
func (d *DownloadAsFileOptions) SetOutputPath(outputPath string) (err error)
func (*DownloadAsFileOptions) SetOverwriteExisting ¶
func (d *DownloadAsFileOptions) SetOverwriteExisting(overwriteExisting bool)
func (*DownloadAsFileOptions) SetRequestOptions ¶
func (d *DownloadAsFileOptions) SetRequestOptions(requestOptions *RequestOptions) (err error)
type RequestOptions ¶
type RequestOptions struct {
// Url to request
Url string
// Port to use.
// Overrides the port defined in URL if specified.
Port int
// Request method like GET, POST...
Method string
// Skip TLS validation
SkipTLSvalidation bool
}
func NewRequestOptions ¶
func NewRequestOptions() (r *RequestOptions)
func (*RequestOptions) GetDeepCopy ¶
func (r *RequestOptions) GetDeepCopy() (copy *RequestOptions)
func (*RequestOptions) GetMethod ¶
func (r *RequestOptions) GetMethod() (method string, err error)
func (*RequestOptions) GetMethodOrDefault ¶
func (r *RequestOptions) GetMethodOrDefault() (method string, err error)
func (*RequestOptions) GetPort ¶
func (r *RequestOptions) GetPort() (port int, err error)
func (*RequestOptions) GetSkipTLSvalidation ¶
func (r *RequestOptions) GetSkipTLSvalidation() (skipTLSvalidation bool)
func (*RequestOptions) GetUrl ¶
func (r *RequestOptions) GetUrl() (url string, err error)
func (*RequestOptions) IsMethodSet ¶
func (r *RequestOptions) IsMethodSet() (isSet bool)
func (*RequestOptions) SetMethod ¶
func (r *RequestOptions) SetMethod(method string) (err error)
func (*RequestOptions) SetPort ¶
func (r *RequestOptions) SetPort(port int) (err error)
func (*RequestOptions) SetSkipTLSvalidation ¶
func (r *RequestOptions) SetSkipTLSvalidation(skipTLSvalidation bool)
func (*RequestOptions) SetUrl ¶
func (r *RequestOptions) SetUrl(url string) (err error)
Click to show internal directories.
Click to hide internal directories.