meta

package
v0.0.0-...-ef20d85 Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileMeta

type FileMeta struct {
	FileName string
	Size     int64
	CheckSum string
	Backups  []string //server Id
}

type Meta

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

func GetMeta

func GetMeta() *Meta

func (*Meta) Close

func (m *Meta) Close() error

func (*Meta) Get

func (m *Meta) Get(path string) *FileMeta

func (*Meta) Query

func (m *Meta) Query(filter func(path string, fm FileMeta) bool)

func (*Meta) Register

func (m *Meta) Register(path string, fm FileMeta) error

func (*Meta) RegisterDir

func (m *Meta) RegisterDir(dirName, fileNamePattern string) error

func (*Meta) RegisterFile

func (m *Meta) RegisterFile(path, fileName string) error

func (*Meta) Remove

func (m *Meta) Remove(path string)

func (*Meta) Stat

func (m *Meta) Stat() Stat

type Stat

type Stat struct {
	Count int
	Size  int64
}

Jump to

Keyboard shortcuts

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