filestore

package
v0.0.0-...-ecdd364 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package filestore provides read and write access to local filesystem.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileStore

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

FileStore represents a file on the filesytem.

func New

func New(path string) *FileStore

New returns a local filesystem object with a file path.

func (*FileStore) Load

func (s *FileStore) Load() ([]byte, error)

Load returns a file contents from the filesystem.

func (*FileStore) Save

func (s *FileStore) Save(b []byte) error

Save writes a file to the filesystem and returns an error if one occurs.

Jump to

Keyboard shortcuts

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