MCPcopy Create free account
hub / github.com/chainreactors/spray / CountString

Method CountString

pkg/statistor.go:113–127  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

111}
112
113func (stat *Statistor) CountString() string {
114 if len(stat.Counts) == 0 {
115 return ""
116 }
117 var s strings.Builder
118 s.WriteString("[stat] ")
119 s.WriteString(stat.BaseUrl)
120 for k, v := range stat.Counts {
121 if k == 0 {
122 continue
123 }
124 s.WriteString(fmt.Sprintf(" %d: %d,", k, v))
125 }
126 return s.String()
127}
128
129func (stat *Statistor) SourceString() string {
130 if len(stat.Sources) == 0 {

Callers 1

PrintStatMethod · 0.80

Calls 1

StringMethod · 0.95

Tested by

no test coverage detected