Documentation ¶
Index ¶
- Variables
- func TestContent(t *testing.T, scope Scope, wg *pr2.WaitGroup)
- func TestContentSB(t *testing.T)
- type ChunkThreshold
- type Content
- type ContentReader
- type Def
- func (_ Def) ChunkArgs() (ChunkThreshold, MaxChunkSize)
- func (_ Def) Funcs(fetch entity.Fetch, newContentReader NewContentReader, ...) (iterSubs IterSubs, findFileInSubs FindFileInSubs)
- func (_ Def) NewContentReader(fetch entity.Fetch) NewContentReader
- func (_ Def) NewFileFS(iterSubs IterSubs, newContentReadre NewContentReader, ...) NewFileFS
- func (_ Def) ToContents(save entity.SaveEntity, chunkThreshold ChunkThreshold, ...) ToContents
- func (_ Def) WriteContents(fetch entity.Fetch) WriteContents
- type DirEntry
- type FS
- type File
- func (f *File) GetDevice(_ Scope) uint64
- func (f *File) GetIsDir(_ Scope) bool
- func (f *File) GetModTime(_ Scope) time.Time
- func (f *File) GetMode(_ Scope) os.FileMode
- func (f *File) GetName(_ Scope) string
- func (f *File) GetSize(_ Scope) int64
- func (f *File) GetTreeSize(scope Scope) int64
- func (f *File) GetWeight(scope Scope) int
- func (f File) MarshalSB(ctx sb.Ctx, cont sb.Proc) sb.Proc
- func (f *File) WithReader(scope Scope, fn func(io.Reader) error) (err error)
- type FindFileInSubs
- type Handle
- type Info
- type IterSubs
- type Key
- type MaxChunkSize
- type NewContentReader
- type NewFileFS
- type Pack
- type Scope
- type Sub
- type Subs
- type ToContents
- type WriteContents
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotDir = errors.New("not a dir")
Functions ¶
func TestContentSB ¶
Types ¶
type ChunkThreshold ¶
type ChunkThreshold int64
type ContentReader ¶
type ContentReader struct {
// contains filtered or unexported fields
}
type Def ¶
type Def struct{}
func (Def) ChunkArgs ¶
func (_ Def) ChunkArgs() (ChunkThreshold, MaxChunkSize)
func (Def) Funcs ¶
func (_ Def) Funcs( fetch entity.Fetch, newContentReader NewContentReader, newHashState key.NewHashState, ) ( iterSubs IterSubs, findFileInSubs FindFileInSubs, )
func (Def) NewContentReader ¶
func (_ Def) NewContentReader( fetch entity.Fetch, ) NewContentReader
func (Def) NewFileFS ¶
func (_ Def) NewFileFS( iterSubs IterSubs, newContentReadre NewContentReader, findFileInSubs FindFileInSubs, ) NewFileFS
func (Def) ToContents ¶
func (_ Def) ToContents( save entity.SaveEntity, chunkThreshold ChunkThreshold, maxChunkSize MaxChunkSize, ) ToContents
func (Def) WriteContents ¶
func (_ Def) WriteContents( fetch entity.Fetch, ) WriteContents
type File ¶
type File struct { ModTime time.Time Name string Subs Subs Contents []Key ChunkLengths []int64 ContentBytes []byte Size int64 Mode os.FileMode IsDir bool }
func (*File) GetTreeSize ¶
type Handle ¶
type Handle struct { io.ReadSeeker // contains filtered or unexported fields }
type MaxChunkSize ¶
type MaxChunkSize int64
type NewContentReader ¶
type NewContentReader func( keys []Key, lengths []int64, ) *ContentReader
type ToContents ¶
Click to show internal directories.
Click to hide internal directories.