gcfopen

package
v0.0.0-...-54f7cab Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FileStatIfExists

func FileStatIfExists(path string) fs.FileInfo

FileStatIfExists returns the file info if the file exists, otherwise nil

func OpenFile

func OpenFile(path string, opts ...OpenOption) (*os.File, error)

Types

type OpenOption

type OpenOption func(*openOption)

func WithDisablePathCreation

func WithDisablePathCreation() OpenOption

func WithIncrementalSuffixIfExists

func WithIncrementalSuffixIfExists(fn func(string, fs.FileInfo) bool) OpenOption

func WithMustExistsBefore

func WithMustExistsBefore() OpenOption

func WithPerm

func WithPerm(perm fs.FileMode) OpenOption

func WithReadOnly

func WithReadOnly() OpenOption

func WithTruncate

func WithTruncate() OpenOption

func WithWriteOnly

func WithWriteOnly() OpenOption

Jump to

Keyboard shortcuts

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