vfs

package
v1.37.0 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsNotExist added in v1.29.0

func IsNotExist(err error) bool

Types

type ErrNotExist added in v1.29.0

type ErrNotExist struct {
	Inner error
}

func (ErrNotExist) Error added in v1.29.0

func (e ErrNotExist) Error() string

type File

type File interface {
	io.Reader
	io.Closer
}

File represents an open file, which will typically be the response body of a Pages request.

type Root added in v1.24.0

type Root interface {
	Lstat(ctx context.Context, name string) (os.FileInfo, error)
	Readlink(ctx context.Context, name string) (string, error)
	Open(ctx context.Context, name string) (File, error)
}

Root abstracts the things Pages needs to serve a static site from a given root rootPath.

type SeekableFile added in v1.26.0

type SeekableFile interface {
	File
	io.Seeker
}

SeekableFile represents a seekable file, which will typically be the response body of a Pages request.

type VFS

type VFS interface {
	Root(ctx context.Context, path string) (Root, error)
	Name() string
	Reconfigure(config *config.Config) error
}

VFS abstracts the things Pages needs to serve a static site from disk.

func Instrumented

func Instrumented(fs VFS) VFS

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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