expose the TransportError and the ApplicationError

This commit is contained in:
Marten Seemann 2021-04-25 18:47:04 +07:00
parent f5238bf7b1
commit 42b61729bd
23 changed files with 126 additions and 106 deletions

30
errors.go Normal file
View file

@ -0,0 +1,30 @@
package quic
import "github.com/lucas-clemente/quic-go/internal/qerr"
type (
TransportError = qerr.TransportError
ApplicationError = qerr.ApplicationError
TransportErrorCode = qerr.TransportErrorCode
ApplicationErrorCode = qerr.ApplicationErrorCode
)
const (
NoError = qerr.NoError
InternalError = qerr.InternalError
ConnectionRefused = qerr.ConnectionRefused
FlowControlError = qerr.FlowControlError
StreamLimitError = qerr.StreamLimitError
StreamStateError = qerr.StreamStateError
FinalSizeError = qerr.FinalSizeError
FrameEncodingError = qerr.FrameEncodingError
TransportParameterError = qerr.TransportParameterError
ConnectionIDLimitError = qerr.ConnectionIDLimitError
ProtocolViolation = qerr.ProtocolViolation
InvalidToken = qerr.InvalidToken
ApplicationErrorErrorCode = qerr.ApplicationErrorErrorCode
CryptoBufferExceeded = qerr.CryptoBufferExceeded
KeyUpdateError = qerr.KeyUpdateError
AEADLimitReached = qerr.AEADLimitReached
NoViablePathError = qerr.NoViablePathError
)