fs

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2023 License: GPL-3.0, GPL-3.0 Imports: 2 Imported by: 0

Documentation

Overview

Package fs is an abstraction for OS/filesystem functions that may be missing or require special handling. For example, WASM.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Abs added in v0.19.0

func Abs(pth string) (string, error)

Abs is an abstraction of filepath.Abs().

func MkdirAll

func MkdirAll(pth string, perm os.FileMode) error

MkdirAll is an abstraction of os.MkdirAll().

Types

type File

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

File is an abstraction of os.File.

func Create

func Create(pth string) (*File, error)

File is an abstraction of os.Create().

func Open

func Open(pth string) (*File, error)

File is an abstraction of os.Open().

func (*File) Close

func (f *File) Close() error

Close is an abstraction of os.File.Close().

func (*File) Read

func (f *File) Read(p []byte) (n int, err error)

Close is an abstraction of os.File.Read().

func (*File) Write

func (f *File) Write(p []byte) (n int, err error)

Close is an abstraction of os.File.Write().

Jump to

Keyboard shortcuts

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