file

package
v0.0.0-...-284e23e Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2018 License: MPL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Chunk

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

func NewChunk

func NewChunk(id int64, size int64) *Chunk

type File

type File struct {
	Path string
	Size uint64
	// contains filtered or unexported fields
}

func NewFile

func NewFile(path string) *File

type FileSystem

type FileSystem interface {
}

func NewFileSystem

func NewFileSystem(kv kv.KV) (FileSystem, error)

type Range

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

func NewRange

func NewRange(chunkID uint64, chunkOffset uint64, size uint64, fileOffset uint64) *Range

type RangeSystem

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

func NewRangeSystem

func NewRangeSystem() *RangeSystem

func (*RangeSystem) CreateRange

func (rs *RangeSystem) CreateRange(fileOffset uint64, chunkID uint64, chunkOffset uint64) (*Range, error)

TODO Seems like the range needs to know where the last range ended. Consider where these numbers are being calculated

func (*RangeSystem) GetRange

func (rs *RangeSystem) GetRange(fileOffset uint64) (*Range, error)

type Replica

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

func NewReplica

func NewReplica(name string, chunkIDs []int64) *Replica

Directories

Path Synopsis
kv

Jump to

Keyboard shortcuts

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