-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy patherrors.go
17 lines (15 loc) · 1.12 KB
/
errors.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
package kodr
import "errors"
var (
ErrMatrixDimensionMismatch = errors.New("can't perform matrix multiplication")
ErrAllUsefulPiecesReceived = errors.New("no more pieces required for decoding")
ErrMoreUsefulPiecesRequired = errors.New("not enough pieces received yet to decode")
ErrCopyFailedDuringPieceConstruction = errors.New("failed to copy whole data before splitting into pieces")
ErrPieceCountMoreThanTotalBytes = errors.New("requested piece count > total bytes of original data")
ErrZeroPieceSize = errors.New("pieces can't be sized as zero byte")
ErrBadPieceCount = errors.New("minimum 2 pieces required for RLNC")
ErrCodedDataLengthMismatch = errors.New("coded data length != coded piece count x coded piece length")
ErrCodingVectorLengthMismatch = errors.New("coding vector length > coded piece length ( in total )")
ErrPieceNotDecodedYet = errors.New("piece not decoded yet, more pieces required")
ErrPieceOutOfBound = errors.New("requested piece index >= pieceCount ( pieces coded together )")
)