MCPcopy Create free account
hub / github.com/google/mangle / NewSimpleInMemoryStore

Function NewSimpleInMemoryStore

factstore/factstore.go:131–135  ·  view source on GitHub ↗

NewSimpleInMemoryStore constructs a new SimpleInMemoryStore.

()

Source from the content-addressed store, hash-verified

129
130// NewSimpleInMemoryStore constructs a new SimpleInMemoryStore.
131func NewSimpleInMemoryStore() SimpleInMemoryStore {
132 return SimpleInMemoryStore{
133 NewInMemoryStore[map[uint64]ast.Atom](),
134 }
135}
136
137// GetFacts implementation that looks up facts from an in-memory map.
138func (s SimpleInMemoryStore) GetFacts(a ast.Atom, fn func(ast.Atom) error) error {

Callers 15

NewFunction · 0.92
TestShortestPathsFunction · 0.92
runEvalFunction · 0.92
TestRewriteIdempotencyFunction · 0.92
TestNegationFunction · 0.92
TestNegationOrderFunction · 0.92
TestSimpleEvalFunction · 0.92
TestSimpleEvalDeferFunction · 0.92
TestManyPathsFunction · 0.92
TestNonLinearFunction · 0.92
TestBuiltinFunction · 0.92
TestListMapStructFunction · 0.92

Calls 1

NewInMemoryStoreFunction · 0.85

Tested by 15

TestShortestPathsFunction · 0.74
runEvalFunction · 0.74
TestRewriteIdempotencyFunction · 0.74
TestNegationFunction · 0.74
TestNegationOrderFunction · 0.74
TestSimpleEvalFunction · 0.74
TestSimpleEvalDeferFunction · 0.74
TestManyPathsFunction · 0.74
TestNonLinearFunction · 0.74
TestBuiltinFunction · 0.74
TestListMapStructFunction · 0.74
TestTransformFunction · 0.74