Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DepDownloader ¶
type DepDownloader struct { *OciDownloader *GitDownloader }
DepDownloader is the downloader for the package. Only support the OCI and git source.
func NewOciDownloader ¶
func NewOciDownloader(platform string) *DepDownloader
func (*DepDownloader) Download ¶
func (d *DepDownloader) Download(opts DownloadOptions) error
type DownloadOptions ¶
type DownloadOptions struct { // LocalPath is the local path to download the package. LocalPath string // Source is the source of the package. including git, oci, local. Source pkg.Source // Settings is the default settings and authrization information. Settings settings.Settings // LogWriter is the writer to write the log. LogWriter io.Writer }
DownloadOptions is the options for downloading a package.
func NewDownloadOptions ¶
func NewDownloadOptions(opts ...Option) *DownloadOptions
type Downloader ¶
type Downloader interface {
Download(opts DownloadOptions) error
}
Downloader is the interface for downloading a package.
type GitDownloader ¶
type GitDownloader struct{}
GitDownloader is the downloader for the git source.
func (*GitDownloader) Download ¶
func (d *GitDownloader) Download(opts DownloadOptions) error
type OciDownloader ¶
type OciDownloader struct {
Platform string
}
OciDownloader is the downloader for the OCI source.
func (*OciDownloader) Download ¶
func (d *OciDownloader) Download(opts DownloadOptions) error
type Option ¶
type Option func(*DownloadOptions)
func WithLocalPath ¶
func WithLogWriter ¶
func WithSettings ¶
func WithSource ¶
Click to show internal directories.
Click to hide internal directories.