dataman

package
v0.0.0-...-d40ae05 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2017 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataManager

type DataManager interface {
	Close() error
	DirectFile() file.File
	RollbackFile() file.File

	Alloc(size int64) (int64, error)
	Free(off int64) error
	UsableSize(off int64) (int64, error)
	Commit() error
}

type DataManagerLocked

type DataManagerLocked struct {
	DataManager
	sync.Mutex
}

type SimpleDataManager

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

func NewSimpleDataManager

func NewSimpleDataManager(f file.File) (*SimpleDataManager, error)

func (*SimpleDataManager) Alloc

func (s *SimpleDataManager) Alloc(size int64) (int64, error)

func (*SimpleDataManager) Close

func (s *SimpleDataManager) Close() error

func (*SimpleDataManager) Commit

func (s *SimpleDataManager) Commit() error

func (*SimpleDataManager) DirectFile

func (s *SimpleDataManager) DirectFile() file.File

func (*SimpleDataManager) Free

func (s *SimpleDataManager) Free(off int64) error

func (*SimpleDataManager) RollbackFile

func (s *SimpleDataManager) RollbackFile() file.File

func (*SimpleDataManager) UsableSize

func (s *SimpleDataManager) UsableSize(off int64) (int64, error)

Jump to

Keyboard shortcuts

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