Documentation ¶
Overview ¶
Package tlerr defines the errors of the translib library.
The Error() method of the error interface for these functions returns the English version, and are only meant for log files.
For message strings that are returned to the users, the localization will happen at when the GNMI/REST client's locale is known. Hence, it cannot occur here.
Index ¶
- type AlreadyExistsError
- type AuthorizationError
- type InternalError
- type InvalidArgsError
- type NotFoundError
- type NotSupportedError
- type TranslibCVLFailure
- type TranslibDBCannotOpen
- type TranslibDBNotInit
- type TranslibDBSubscribeFail
- type TranslibRedisClientEntryNotExist
- type TranslibSyntaxValidationError
- type TranslibTransactionFail
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AlreadyExistsError ¶
type AlreadyExistsError errordata
AlreadyExistsError indicates resource exists error.
func AlreadyExists ¶
func AlreadyExists(msg string, args ...interface{}) AlreadyExistsError
AlreadyExists creates a AlreadyExistsError
func (AlreadyExistsError) Error ¶
func (e AlreadyExistsError) Error() string
type AuthorizationError ¶
type AuthorizationError errordata
AuthorizationError indicates the user is not authorized for an operation.
func (AuthorizationError) Error ¶
func (e AuthorizationError) Error() string
type InternalError ¶
type InternalError errordata
InternalError indicates a generic error during app execution.
func (InternalError) Error ¶
func (e InternalError) Error() string
type InvalidArgsError ¶
type InvalidArgsError errordata
InvalidArgsError indicates bad request error.
func InvalidArgs ¶
func InvalidArgs(msg string, args ...interface{}) InvalidArgsError
InvalidArgs creates a InvalidArgsError
func (InvalidArgsError) Error ¶
func (e InvalidArgsError) Error() string
type NotFoundError ¶
type NotFoundError errordata
NotFoundError indicates resource not found error.
func NotFound ¶
func NotFound(msg string, args ...interface{}) NotFoundError
NotFound creates a NotFoundError
func (NotFoundError) Error ¶
func (e NotFoundError) Error() string
type NotSupportedError ¶
type NotSupportedError errordata
NotSupportedError indicates unspported operation error.
func NotSupported ¶
func NotSupported(msg string, args ...interface{}) NotSupportedError
NotSupported creates a NotSupportedError
func (NotSupportedError) Error ¶
func (e NotSupportedError) Error() string
type TranslibCVLFailure ¶
type TranslibCVLFailure struct { Code int CVLErrorInfo cvl.CVLErrorInfo }
func (TranslibCVLFailure) Error ¶
func (e TranslibCVLFailure) Error() string
type TranslibDBCannotOpen ¶
type TranslibDBCannotOpen struct { }
func (TranslibDBCannotOpen) Error ¶
func (e TranslibDBCannotOpen) Error() string
type TranslibDBNotInit ¶
type TranslibDBNotInit struct { }
func (TranslibDBNotInit) Error ¶
func (e TranslibDBNotInit) Error() string
type TranslibDBSubscribeFail ¶
type TranslibDBSubscribeFail struct { }
func (TranslibDBSubscribeFail) Error ¶
func (e TranslibDBSubscribeFail) Error() string
type TranslibRedisClientEntryNotExist ¶
type TranslibRedisClientEntryNotExist struct {
Entry string
}
func (TranslibRedisClientEntryNotExist) Error ¶
func (e TranslibRedisClientEntryNotExist) Error() string
type TranslibSyntaxValidationError ¶
type TranslibSyntaxValidationError struct { StatusCode int // status code ErrorStr error // error message }
func (TranslibSyntaxValidationError) Error ¶
func (e TranslibSyntaxValidationError) Error() string
type TranslibTransactionFail ¶
type TranslibTransactionFail struct { }
func (TranslibTransactionFail) Error ¶
func (e TranslibTransactionFail) Error() string