source

package
v0.7.1-alpha Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2019 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewSourceDevice

func NewSourceDevice(attrs fs.DeviceAttrs) fs.Source

func NewSourceDir

func NewSourceDir(attrs fs.FileAttrs) fs.Source

func NewSourceFifo

func NewSourceFifo(attrs fs.DeviceAttrs) *sourceFifo

func NewSourceFile

func NewSourceFile(reader fs.Readable, attrs fs.FileAttrs) *sourceFile

func NewSourceFileHashed

func NewSourceFileHashed(reader fs.Readable, attrs fs.FileAttrs, hash string) *sourceFile
func NewSourceSymlink(attrs fs.FileAttrs) fs.Source

func NewSourceTar

func NewSourceTar(file string) *sourceTar

func NewSourceTarBz

func NewSourceTarBz(file string) fs.Source

func NewSourceTarGz

func NewSourceTarGz(file string) fs.Source

func NewSourceURL

func NewSourceURL(url *url.URL, etagCache HttpHeaderCache, chown idutils.UserIds) fs.Source
func NewSourceUpperLink(s fs.Source) fs.Source

func NewSourceWhiteout

func NewSourceWhiteout() fs.Source

Types

type HttpHeaderCache

type HttpHeaderCache interface {
	// Restores cached attrs or null
	GetHttpHeaders(url string) (*HttpHeaders, error)
	// Stores URL attrs
	PutHttpHeaders(url string, attrs *HttpHeaders) error
}

func NewHttpHeaderCache

func NewHttpHeaderCache(dir string) HttpHeaderCache

type HttpHeaders

type HttpHeaders struct {
	ContentLength int64
	Etag          string
	LastModified  string
}

type NoopHttpHeaderCache

type NoopHttpHeaderCache string

func (NoopHttpHeaderCache) GetHttpHeaders

func (c NoopHttpHeaderCache) GetHttpHeaders(url string) (*HttpHeaders, error)

func (NoopHttpHeaderCache) PutHttpHeaders

func (c NoopHttpHeaderCache) PutHttpHeaders(url string, attrs *HttpHeaders) error

type SourceDir

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

func (*SourceDir) Attrs

func (s *SourceDir) Attrs() fs.NodeInfo

func (*SourceDir) DeriveAttrs

func (s *SourceDir) DeriveAttrs() (fs.DerivedAttrs, error)

func (*SourceDir) String

func (s *SourceDir) String() string

func (*SourceDir) Write

func (s *SourceDir) Write(dest, name string, w fs.Writer, _ map[fs.Source]string) error
type SourceUpperLink struct {
	fs.Source
}

func (*SourceUpperLink) Write

func (f *SourceUpperLink) Write(path, name string, w fs.Writer, written map[fs.Source]string) (err error)

type Sources

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

func NewSources

func NewSources(fsEval fseval.FsEval, attrMapper fs.AttrMapper) *Sources

func (*Sources) File

func (s *Sources) File(file string, fi os.FileInfo, usr *idutils.UserIds) (r fs.Source, err error)

func (*Sources) FileOverlay

func (s *Sources) FileOverlay(file string, fi os.FileInfo, usr *idutils.UserIds) (r fs.Source, err error)

Jump to

Keyboard shortcuts

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