-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy patherrors.go
More file actions
37 lines (26 loc) · 1.3 KB
/
errors.go
File metadata and controls
37 lines (26 loc) · 1.3 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
package pkg
var ErrMultimap = NewDecodeError("invalid multimap")
var ErrMultimapCountLimit = NewDecodeError("too many elements in the multimap")
var ErrInvalidRefNum = NewDecodeError("invalid refNum")
var ErrInvalidOneOfType = NewDecodeError("invalid oneof type")
var ErrInvalidHeader = NewDecodeError("invalid FixedHeader")
var ErrInvalidHeaderSignature = NewDecodeError("invalid FixedHeader signature")
var ErrInvalidFormatVersion = NewDecodeError("invalid format version in the FixedHeader")
var ErrInvalidCompression = NewDecodeError("invalid compression method")
var ErrInvalidVarHeader = NewDecodeError("invalid VarHeader")
var ErrFrameSizeLimit = NewDecodeError("frame is too large")
var ErrColumnSizeLimitExceeded = NewDecodeError("column size limit exceeded")
var ErrTotalColumnSizeLimitExceeded = NewDecodeError("total column size limit exceeded")
var ErrRecordAllocLimitExceeded = NewDecodeError("record allocation limit exceeded")
var ErrTooManyFieldsToDecode = NewDecodeError("too many fields to decode")
var ErrEmptyRootStructDisallowed = NewDecodeError("cannot decode empty root struct")
var ErrDecodeError = NewDecodeError("decoding error")
type DecodeError struct {
msg string
}
func (e *DecodeError) Error() string {
return e.msg
}
func NewDecodeError(msg string) error {
return &DecodeError{msg: msg}
}