MCPcopy Create free account
hub / github.com/cel-expr/cel-go / ByteSource

Function ByteSource

policy/source.go:22–24  ·  view source on GitHub ↗

ByteSource converts a byte sequence and location description to a model.Source.

(contents []byte, location string)

Source from the content-addressed store, hash-verified

20
21// ByteSource converts a byte sequence and location description to a model.Source.
22func ByteSource(contents []byte, location string) *Source {
23 return StringSource(string(contents), location)
24}
25
26// StringSource converts a string and location description to a model.Source.
27func StringSource(contents, location string) *Source {

Callers 2

CreateASTMethod · 0.92
readPolicyFunction · 0.85

Calls 1

StringSourceFunction · 0.85

Tested by 1

readPolicyFunction · 0.68