file

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: May 28, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExistPath

func ExistPath(name string) bool

func ExtencionFile

func ExtencionFile(filename string) string

func MakeFile

func MakeFile(folder, name, model string, args ...any) (string, error)

func MakeFolder

func MakeFolder(names ...string) (string, error)

func RemoveFile

func RemoveFile(path string) (bool, error)

func WatcherPath

func WatcherPath(path string)

Types

type SyncFile

type SyncFile struct {
	CreatedAt time.Time
	UpdatedAt time.Time
	Id        string
	Name      string
	Dir       string
	Path      string
	Data      []byte
	// contains filtered or unexported fields
}

func NewSyncFile

func NewSyncFile(dataDirectory, name string, initialData any) (*SyncFile, error)

func (*SyncFile) Delete

func (s *SyncFile) Delete() error

* * Delete * @return error *

func (*SyncFile) Load added in v0.1.0

func (s *SyncFile) Load(v any) error

* * Load * @param v any * @return error *

func (*SyncFile) Save

func (s *SyncFile) Save() error

* * Save * @return error *

func (*SyncFile) Set

func (s *SyncFile) Set(data []byte, saved bool) error

* * Set * @param data []byte, saved bool * @return error *

Jump to

Keyboard shortcuts

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