MCPcopy Index your code
hub / github.com/GoEdgeLab/EdgeNode / AddCost

Method AddCost

internal/utils/dbs/query_stat.go:20–30  ·  view source on GitHub ↗
(cost float64)

Source from the content-addressed store, hash-verified

18}
19
20func (this *QueryStat) AddCost(cost float64) {
21 if this.CostMin == 0 || this.CostMin > cost {
22 this.CostMin = cost
23 }
24 if this.CostMax == 0 || this.CostMax < cost {
25 this.CostMax = cost
26 }
27
28 this.CostTotal += cost
29 this.Calls++
30}

Callers 1

EndMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected