@@ -44,8 +44,8 @@ type Type string
4444type TypeN int
4545
4646// String returns the string representation of the metric type.
47- func (i TypeN ) String () Type {
48- return MetricTypeNMap [i ]
47+ func (i TypeN ) String () string {
48+ return string ( TypeNMap [i ])
4949}
5050
5151// NString returns the string representation of the metric type as an integer.
@@ -55,7 +55,7 @@ func (i TypeN) NString() string {
5555
5656// Supported metric types.
5757const (
58- // GaugeN defines a OpenMetrics gauge.
58+ // GaugeN defines an OpenMetrics gauge.
5959 GaugeN TypeN = iota
6060
6161 // InfoN defines an OpenMetrics info.
@@ -64,14 +64,14 @@ const (
6464 // StateSetN defines an OpenMetrics stateset.
6565 StateSetN
6666
67- // CounterN defines a OpenMetrics counter.
67+ // CounterN defines an OpenMetrics counter.
6868 CounterN
6969)
7070
7171// Supported metric types.
7272var (
7373
74- // Gauge defines a OpenMetrics gauge.
74+ // Gauge defines an OpenMetrics gauge.
7575 Gauge Type = "gauge"
7676
7777 // Info defines an OpenMetrics info.
@@ -80,19 +80,19 @@ var (
8080 // StateSet defines an OpenMetrics stateset.
8181 StateSet Type = "stateset"
8282
83- // Counter defines a OpenMetrics counter.
83+ // Counter defines an OpenMetrics counter.
8484 Counter Type = "counter"
8585
86- // MetricTypeNMap is a map of MetricTypeN to MetricType.
87- MetricTypeNMap = map [TypeN ]Type {
86+ // TypeNMap is a map of MetricTypeN to MetricType.
87+ TypeNMap = map [TypeN ]Type {
8888 GaugeN : Gauge ,
8989 InfoN : Info ,
9090 StateSetN : StateSet ,
9191 CounterN : Counter ,
9292 }
9393
94- // MetricTypeMap is a map of MetricType to MetricTypeN.
95- MetricTypeMap = map [Type ]TypeN {
94+ // TypeMap is a map of MetricType to MetricTypeN.
95+ TypeMap = map [Type ]TypeN {
9696 Gauge : GaugeN ,
9797 Info : InfoN ,
9898 StateSet : StateSetN ,
0 commit comments