-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patherrorcode_string.go
More file actions
70 lines (64 loc) · 1.99 KB
/
errorcode_string.go
File metadata and controls
70 lines (64 loc) · 1.99 KB
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
// Code generated by "stringer -type=ErrorCode"; DO NOT EDIT.
package ignite
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[Success-0]
_ = x[Failed-1]
_ = x[InvalidOpCode-2]
_ = x[InvalidNodeState-10]
_ = x[FunctionalityDisabled-100]
_ = x[CacheDoesNotExists-1000]
_ = x[CacheExists-1001]
_ = x[CacheConfigInvalid-1002]
_ = x[TooManyCursors-1010]
_ = x[ResourceDoesNotExists-1011]
_ = x[SecurityViolation-1012]
_ = x[TxLimitExceeded-1020]
_ = x[TxNotFound-1021]
_ = x[TooManyComputeTasks-1030]
_ = x[AuthFailed-2000]
}
const (
_ErrorCode_name_0 = "SuccessFailedInvalidOpCode"
_ErrorCode_name_1 = "InvalidNodeState"
_ErrorCode_name_2 = "FunctionalityDisabled"
_ErrorCode_name_3 = "CacheDoesNotExistsCacheExistsCacheConfigInvalid"
_ErrorCode_name_4 = "TooManyCursorsResourceDoesNotExistsSecurityViolation"
_ErrorCode_name_5 = "TxLimitExceededTxNotFound"
_ErrorCode_name_6 = "TooManyComputeTasks"
_ErrorCode_name_7 = "AuthFailed"
)
var (
_ErrorCode_index_0 = [...]uint8{0, 7, 13, 26}
_ErrorCode_index_3 = [...]uint8{0, 18, 29, 47}
_ErrorCode_index_4 = [...]uint8{0, 14, 35, 52}
_ErrorCode_index_5 = [...]uint8{0, 15, 25}
)
func (i ErrorCode) String() string {
switch {
case i <= 2:
return _ErrorCode_name_0[_ErrorCode_index_0[i]:_ErrorCode_index_0[i+1]]
case i == 10:
return _ErrorCode_name_1
case i == 100:
return _ErrorCode_name_2
case 1000 <= i && i <= 1002:
i -= 1000
return _ErrorCode_name_3[_ErrorCode_index_3[i]:_ErrorCode_index_3[i+1]]
case 1010 <= i && i <= 1012:
i -= 1010
return _ErrorCode_name_4[_ErrorCode_index_4[i]:_ErrorCode_index_4[i+1]]
case 1020 <= i && i <= 1021:
i -= 1020
return _ErrorCode_name_5[_ErrorCode_index_5[i]:_ErrorCode_index_5[i+1]]
case i == 1030:
return _ErrorCode_name_6
case i == 2000:
return _ErrorCode_name_7
default:
return "ErrorCode(" + strconv.FormatInt(int64(i), 10) + ")"
}
}