MCPcopy
hub / github.com/google/mangle / NewSimpleColumnStoreFromBytes

Function NewSimpleColumnStoreFromBytes

factstore/simplecolumn.go:189–193  ·  view source on GitHub ↗

NewSimpleColumnStoreFromBytes returns a new fact store backed by data in simplecolumn format.

(data []byte)

Source from the content-addressed store, hash-verified

187
188// NewSimpleColumnStoreFromBytes returns a new fact store backed by data in simplecolumn format.
189func NewSimpleColumnStoreFromBytes(data []byte) (*SimpleColumnStore, error) {
190 return NewSimpleColumnStore(func() (io.ReadCloser, error) {
191 return io.NopCloser(bytes.NewReader(data)), nil
192 })
193}
194
195// NewSimpleColumnStoreFromGzipBytes returns a new fact store backed by data that is
196// a gzipped file in simplecolumn format.

Callers 2

TestEmptyStoreFunction · 0.85
TestNewBytesFunction · 0.85

Calls 1

NewSimpleColumnStoreFunction · 0.85

Tested by 2

TestEmptyStoreFunction · 0.68
TestNewBytesFunction · 0.68