forked from gosnmp/gosnmp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pdutype_string.go
42 lines (36 loc) · 1007 Bytes
/
pdutype_string.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
// Code generated by "stringer -type=PDUType"; DO NOT EDIT.
package gosnmp
import "strconv"
func _() {
// An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again.
var x [1]struct{}
_ = x[Sequence-48]
_ = x[GetRequest-160]
_ = x[GetNextRequest-161]
_ = x[GetResponse-162]
_ = x[SetRequest-163]
_ = x[Trap-164]
_ = x[GetBulkRequest-165]
_ = x[InformRequest-166]
_ = x[SNMPv2Trap-167]
_ = x[Report-168]
}
const (
_PDUType_name_0 = "Sequence"
_PDUType_name_1 = "GetRequestGetNextRequestGetResponseSetRequestTrapGetBulkRequestInformRequestSNMPv2TrapReport"
)
var (
_PDUType_index_1 = [...]uint8{0, 10, 24, 35, 45, 49, 63, 76, 86, 92}
)
func (i PDUType) String() string {
switch {
case i == 48:
return _PDUType_name_0
case 160 <= i && i <= 168:
i -= 160
return _PDUType_name_1[_PDUType_index_1[i]:_PDUType_index_1[i+1]]
default:
return "PDUType(" + strconv.FormatInt(int64(i), 10) + ")"
}
}