gotiofs

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2026 License: GPL-3.0 Imports: 12 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

package gotiofs provides an adapter from Got to an io/fs.FS

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDirEntry

func NewDirEntry(x gotfs.DirEnt, getInfo func() (iofs.FileInfo, error)) iofs.DirEntry

func Stat

func Stat(ctx context.Context, fsag *gotfs.Machine, ms stores.Reading, root gotfs.Root, p string) (iofs.FileInfo, error)

Types

type FS

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

FS implements io/fs.FS

func New

func New(ctx context.Context, b marks.Mark) *FS

func (*FS) Open

func (s *FS) Open(name string) (iofs.File, error)

type File

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

func NewFile

func NewFile(ctx context.Context, fsag *gotfs.Machine, txn volumes.Tx, root gotfs.Root, p string) *File

func (*File) Close

func (f *File) Close() error

func (*File) Read

func (f *File) Read(buf []byte) (int, error)

func (*File) ReadAt

func (f *File) ReadAt(buf []byte, off int64) (int, error)

func (*File) ReadDir

func (f *File) ReadDir(n int) (ret []iofs.DirEntry, _ error)

func (*File) Seek

func (f *File) Seek(offset int64, whence int) (int64, error)

func (*File) Stat

func (f *File) Stat() (iofs.FileInfo, error)

Jump to

Keyboard shortcuts

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