MCPcopy
hub / github.com/perkeep/perkeep / Blob

Struct Blob

pkg/blob/blob.go:32–37  ·  view source on GitHub ↗

Blob represents a blob. Use the methods Size, SizedRef and ReadAll to query and get data from Blob.

Source from the content-addressed store, hash-verified

30// Blob represents a blob. Use the methods Size, SizedRef and
31// ReadAll to query and get data from Blob.
32type Blob struct {
33 ref Ref
34 size uint32
35 readAll func(context.Context) ([]byte, error)
36 mem atomic.Value // of []byte, if in memory
37}
38
39// NewBlob constructs a Blob from its Ref, size and a function that
40// returns the contents of the blob. Any error in the function newReader when

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected