support

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: May 17, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoIndex = errors.New("manifest does not support access to subsequent artifacts")

Functions

func AdjustSize

func AdjustSize(d *artdesc.Descriptor, size int64) error

func NewArtifact

func NewArtifact(container NamespaceAccessImpl, defs ...cpi.Artifact) (cpi.ArtifactAccess, error)

func NewArtifactForBlob

func NewArtifactForBlob(container NamespaceAccessImpl, blob blobaccess.BlobAccess, closer ...io.Closer) (cpi.ArtifactAccess, error)

func NewNamespaceAccess added in v0.3.0

func NewNamespaceAccess(namespace string, c NamespaceContainer, repo cpi.RepositoryViewManager, kind ...string) (cpi.NamespaceAccess, error)

Types

type ArtifactAccessImpl added in v0.3.0

type ArtifactAccessImpl struct {
	cpi.ArtifactAccessImplBase
	// contains filtered or unexported fields
}

func (*ArtifactAccessImpl) AddArtifact added in v0.3.0

func (a *ArtifactAccessImpl) AddArtifact(art cpi.Artifact, platform *artdesc.Platform) (cpi.BlobAccess, error)

func (*ArtifactAccessImpl) AddBlob added in v0.3.0

func (a *ArtifactAccessImpl) AddBlob(access cpi.BlobAccess) error

func (*ArtifactAccessImpl) AddLayer added in v0.3.0

func (a *ArtifactAccessImpl) AddLayer(blob cpi.BlobAccess, d *cpi.Descriptor) (int, error)

func (*ArtifactAccessImpl) Artifact added in v0.3.0

func (a *ArtifactAccessImpl) Artifact() *artdesc.Artifact

func (*ArtifactAccessImpl) Blob added in v0.3.0

func (a *ArtifactAccessImpl) Blob() (cpi.BlobAccess, error)

func (*ArtifactAccessImpl) Digest added in v0.3.0

func (a *ArtifactAccessImpl) Digest() digest.Digest

func (*ArtifactAccessImpl) GetArtifact added in v0.3.0

func (a *ArtifactAccessImpl) GetArtifact(digest digest.Digest) (cpi.ArtifactAccess, error)

func (*ArtifactAccessImpl) GetBlob added in v0.3.0

func (a *ArtifactAccessImpl) GetBlob(digest digest.Digest) (cpi.BlobAccess, error)

func (*ArtifactAccessImpl) GetBlobData added in v0.3.0

func (a *ArtifactAccessImpl) GetBlobData(digest digest.Digest) (int64, cpi.DataAccess, error)

func (*ArtifactAccessImpl) GetBlobDescriptor added in v0.3.0

func (a *ArtifactAccessImpl) GetBlobDescriptor(digest digest.Digest) *cpi.Descriptor

func (*ArtifactAccessImpl) GetDescriptor added in v0.3.0

func (a *ArtifactAccessImpl) GetDescriptor() *artdesc.Artifact

func (*ArtifactAccessImpl) Index added in v0.3.0

func (a *ArtifactAccessImpl) Index() (*artdesc.Index, error)

func (*ArtifactAccessImpl) IndexAccess added in v0.3.0

func (*ArtifactAccessImpl) IsIndex added in v0.3.0

func (a *ArtifactAccessImpl) IsIndex() bool

func (*ArtifactAccessImpl) IsManifest added in v0.3.0

func (a *ArtifactAccessImpl) IsManifest() bool

func (*ArtifactAccessImpl) IsReadOnly added in v0.3.0

func (a *ArtifactAccessImpl) IsReadOnly() bool

func (*ArtifactAccessImpl) IsValid added in v0.7.0

func (a *ArtifactAccessImpl) IsValid() bool

func (*ArtifactAccessImpl) Manifest added in v0.3.0

func (a *ArtifactAccessImpl) Manifest() (*artdesc.Manifest, error)

func (*ArtifactAccessImpl) ManifestAccess added in v0.3.0

func (*ArtifactAccessImpl) NewArtifact added in v0.3.0

func (a *ArtifactAccessImpl) NewArtifact(art ...cpi.Artifact) (cpi.ArtifactAccess, error)

type ArtifactSetBlobAccess added in v0.3.0

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

func NewArtifactSetBlobAccess added in v0.3.0

func NewArtifactSetBlobAccess(container NamespaceAccessImpl) *ArtifactSetBlobAccess

func (*ArtifactSetBlobAccess) AddArtifact added in v0.3.0

func (a *ArtifactSetBlobAccess) AddArtifact(artifact cpi.Artifact, tags ...string) (access blobaccess.BlobAccess, err error)

func (*ArtifactSetBlobAccess) AddBlob added in v0.3.0

func (a *ArtifactSetBlobAccess) AddBlob(blob cpi.BlobAccess) error

func (*ArtifactSetBlobAccess) GetBlob added in v0.3.0

func (a *ArtifactSetBlobAccess) GetBlob(digest digest.Digest) (cpi.BlobAccess, error)

func (*ArtifactSetBlobAccess) GetBlobData added in v0.3.0

func (a *ArtifactSetBlobAccess) GetBlobData(digest digest.Digest) (int64, cpi.DataAccess, error)

func (*ArtifactSetBlobAccess) GetBlobDescriptor added in v0.3.0

func (a *ArtifactSetBlobAccess) GetBlobDescriptor(digest digest.Digest) *cpi.Descriptor

func (*ArtifactSetBlobAccess) IsReadOnly added in v0.3.0

func (a *ArtifactSetBlobAccess) IsReadOnly() bool

type BlobProvider added in v0.3.0

type BlobProvider interface {
	refmgmt.Allocatable
	cpi.BlobSource
	cpi.BlobSink
}

BlobProvider manages the technical access to blobs.

type IndexAccess added in v0.3.0

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

func NewIndexForArtifact

func NewIndexForArtifact(master cpi.ArtifactAccess, a *ArtifactAccessImpl) *IndexAccess

func (*IndexAccess) AddArtifact added in v0.3.0

func (a *IndexAccess) AddArtifact(art cpi.Artifact, platform *artdesc.Platform) (access blobaccess.BlobAccess, err error)

func (*IndexAccess) AddBlob added in v0.3.0

func (i *IndexAccess) AddBlob(blob internal.BlobAccess) error

func (*IndexAccess) Artifact added in v0.3.0

func (i *IndexAccess) Artifact() *artdesc.Artifact

func (*IndexAccess) Blob added in v0.3.0

func (a *IndexAccess) Blob() (cpi.BlobAccess, error)

func (*IndexAccess) Digest added in v0.3.0

func (a *IndexAccess) Digest() digest.Digest

func (*IndexAccess) GetArtifact added in v0.3.0

func (i *IndexAccess) GetArtifact(digest digest.Digest) (internal.ArtifactAccess, error)

func (*IndexAccess) GetBlob added in v0.3.0

func (i *IndexAccess) GetBlob(digest digest.Digest) (internal.BlobAccess, error)

func (*IndexAccess) GetBlobDescriptor added in v0.3.0

func (i *IndexAccess) GetBlobDescriptor(digest digest.Digest) *cpi.Descriptor

func (*IndexAccess) GetDescriptor added in v0.3.0

func (i *IndexAccess) GetDescriptor() *artdesc.Index

func (*IndexAccess) Index added in v0.3.0

func (i *IndexAccess) Index() (*artdesc.Index, error)

func (*IndexAccess) IsIndex added in v0.3.0

func (a *IndexAccess) IsIndex() bool

func (*IndexAccess) IsManifest added in v0.3.0

func (a *IndexAccess) IsManifest() bool

func (*IndexAccess) IsReadOnly added in v0.3.0

func (a *IndexAccess) IsReadOnly() bool

func (*IndexAccess) IsValid added in v0.7.0

func (a *IndexAccess) IsValid() bool

func (*IndexAccess) Manifest added in v0.3.0

func (i *IndexAccess) Manifest() (*artdesc.Manifest, error)

func (*IndexAccess) NewArtifact added in v0.3.0

func (i *IndexAccess) NewArtifact(art ...cpi.Artifact) (cpi.ArtifactAccess, error)

type ManifestAccess added in v0.3.0

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

func NewManifestForArtifact

func NewManifestForArtifact(master cpi.ArtifactAccess, a *ArtifactAccessImpl) *ManifestAccess

func (*ManifestAccess) AddBlob added in v0.3.0

func (m *ManifestAccess) AddBlob(access cpi.BlobAccess) error

func (*ManifestAccess) AddLayer added in v0.3.0

func (m *ManifestAccess) AddLayer(blob cpi.BlobAccess, d *artdesc.Descriptor) (int, error)

func (*ManifestAccess) Artifact added in v0.3.0

func (m *ManifestAccess) Artifact() *artdesc.Artifact

func (*ManifestAccess) Blob added in v0.3.0

func (a *ManifestAccess) Blob() (cpi.BlobAccess, error)

func (*ManifestAccess) Digest added in v0.3.0

func (a *ManifestAccess) Digest() digest.Digest

func (*ManifestAccess) GetBlob added in v0.3.0

func (m *ManifestAccess) GetBlob(digest digest.Digest) (cpi.BlobAccess, error)

func (*ManifestAccess) GetBlobDescriptor added in v0.3.0

func (m *ManifestAccess) GetBlobDescriptor(digest digest.Digest) *cpi.Descriptor

func (*ManifestAccess) GetConfigBlob added in v0.3.0

func (m *ManifestAccess) GetConfigBlob() (cpi.BlobAccess, error)

func (*ManifestAccess) GetDescriptor added in v0.3.0

func (m *ManifestAccess) GetDescriptor() *artdesc.Manifest

func (*ManifestAccess) Index added in v0.3.0

func (m *ManifestAccess) Index() (*artdesc.Index, error)

func (*ManifestAccess) IsIndex added in v0.3.0

func (a *ManifestAccess) IsIndex() bool

func (*ManifestAccess) IsManifest added in v0.3.0

func (a *ManifestAccess) IsManifest() bool

func (*ManifestAccess) IsReadOnly added in v0.3.0

func (a *ManifestAccess) IsReadOnly() bool

func (*ManifestAccess) IsValid added in v0.7.0

func (a *ManifestAccess) IsValid() bool

func (*ManifestAccess) Manifest added in v0.3.0

func (m *ManifestAccess) Manifest() (*artdesc.Manifest, error)

func (*ManifestAccess) SetConfigBlob added in v0.3.0

func (m *ManifestAccess) SetConfigBlob(blob cpi.BlobAccess, d *artdesc.Descriptor) error

type NamespaceAccessImpl added in v0.3.0

type NamespaceAccessImpl interface {
	cpi.NamespaceAccessImpl

	// GetBlobDescriptor(digest digest.Digest) *cpi.Descriptor
	IsReadOnly() bool

	WithContainer(container NamespaceContainer) NamespaceAccessImpl
}

func NewNamespaceAccessImpl added in v0.3.0

func NewNamespaceAccessImpl(namespace string, c NamespaceContainer, repo cpi.RepositoryViewManager) (NamespaceAccessImpl, error)

type NamespaceContainer added in v0.3.0

type NamespaceContainer interface {
	SetImplementation(impl NamespaceAccessImpl)

	IsReadOnly() bool

	cpi.BlobSource
	cpi.BlobSink

	Close() error

	GetArtifact(i NamespaceAccessImpl, vers string) (cpi.ArtifactAccess, error)
	NewArtifact(i NamespaceAccessImpl, arts ...cpi.Artifact) (cpi.ArtifactAccess, error)

	AddArtifact(artifact cpi.Artifact, tags ...string) (access blobaccess.BlobAccess, err error)

	AddTags(digest digest.Digest, tags ...string) error
	ListTags() ([]string, error)
	HasArtifact(vers string) (bool, error)
}

NamespaceContainer is the interface used by subsequent access objects to access the base implementation.

func GetArtifactSetContainer added in v0.3.0

func GetArtifactSetContainer(i cpi.NamespaceAccessImpl) (NamespaceContainer, error)

Jump to

Keyboard shortcuts

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