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

Function stringTrimCostModel

ext/strings.go:932–937  ·  view source on GitHub ↗
(id string)

Source from the content-addressed store, hash-verified

930}
931
932func stringTrimCostModel(id string) cost.OverloadModel {
933 return cost.MemberOverload(id,
934 stringTransformEvalCost(),
935 cost.ResultSize(cost.AtMost(cost.Target())),
936 )
937}
938
939// stringSubstringCostModel models s.substring(start): it drops at least start units of the
940// receiver, and at most 4 times as many under the aggregate strategy (where each code point takes

Callers 1

CompileOptionsMethod · 0.85

Calls 5

MemberOverloadFunction · 0.92
ResultSizeFunction · 0.92
AtMostFunction · 0.92
TargetFunction · 0.92
stringTransformEvalCostFunction · 0.85

Tested by

no test coverage detected