urlopener

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 25, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Schemes = []string{
	"http",
	"https",
	"file",
	"oci",
	"oci+http",
	"oci+https",
}

Functions

This section is empty.

Types

type URLOpener

type URLOpener struct {
	// contains filtered or unexported fields
}

func New

func New() *URLOpener

func (*URLOpener) Open

func (o *URLOpener) Open(ctx context.Context, u *url.URL, sha256sum string) (io.ReadCloser, int64, error)

Open opens the URL. The sha256sum argument is only used for resolving the OCI URLs. It is up to the caller to validate the sha256sum of the returned stream.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL