Debian Codegraph @

sdk/metric/metricdata/temporality_string.go

raw
1 // Code generated by "stringer -type=Temporality"; DO NOT EDIT.
2
3 package metricdata
4
5 import "strconv"
6
7 func _() {
8 // An "invalid array index" compiler error signifies that the constant values have changed.
9 // Re-run the stringer command to generate them again.
10 var x [1]struct{}
11 _ = x[undefinedTemporality-0]
12 _ = x[CumulativeTemporality-1]
13 _ = x[DeltaTemporality-2]
14 }
15
16 const _Temporality_name = "undefinedTemporalityCumulativeTemporalityDeltaTemporality"
17
18 var _Temporality_index = [...]uint8{0, 20, 41, 57}
19
20 func (i Temporality) String() string {
21 idx := int(i) - 0
22 if i < 0 || idx >= len(_Temporality_index)-1 {
23 return "Temporality(" + strconv.FormatInt(int64(i), 10) + ")"
24 }
25 return _Temporality_name[_Temporality_index[idx]:_Temporality_index[idx+1]]
26 }