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

Function clonePolicyMetadata

tools/compiler/compiler.go:547–555  ·  view source on GitHub ↗
(p *policy.Policy)

Source from the content-addressed store, hash-verified

545}
546
547func clonePolicyMetadata(p *policy.Policy) map[string]any {
548 metadataKeys := p.MetadataKeys()
549 metadata := make(map[string]any, len(metadataKeys))
550 for _, key := range metadataKeys {
551 value, _ := p.Metadata(key)
552 metadata[key] = value
553 }
554 return metadata
555}
556
557// RawExpression is an InputExpression which loads a CEL expression from a string.
558type RawExpression struct {

Callers 1

CreateASTMethod · 0.85

Calls 2

MetadataKeysMethod · 0.80
MetadataMethod · 0.80

Tested by

no test coverage detected