Documentation
¶
Index ¶
- func EAlreadyExists(msg string, err error, arg ...interface{}) error
- func EBadRequest(msg string, err error, arg ...interface{}) error
- func EInternal(msg string, err error, arg ...interface{}) error
- func ENotExists(msg string, err error, arg ...interface{}) error
- func ENotFound(msg string, err error, arg ...interface{}) error
- func EUnauthorized(msg string, err error, arg ...interface{}) error
- func EValidation(msg string, err error, arg ...interface{}) error
- func Is(t Type, err error) bool
- func New(t Type, msg string, err error) error
- type Error
- type Type
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EAlreadyExists ¶
EAlreadyExists creates an error of type EAlreadyExistsl
func EBadRequest ¶
EBadRequest creates an error of type BadRequest
func ENotExists ¶
ENotExists creates an error of type NotExist
func EUnauthorized ¶
EUnauthorized creates an error of type Unauthorized
func EValidation ¶
EValidation creates an error of type Validationn
Types ¶
type Type ¶
type Type string
Type defines the type of an error
const ( // Internal error Internal Type = "internal" // NotFound error means that a specific item does not exist NotFound Type = "not_found" // BadRequest error BadRequest Type = "bad_request" // Validation error Validation Type = "validation" // AlreadyExists error AlreadyExists Type = "already_exists" Unauthorized Type = "unauthorized" )
Click to show internal directories.
Click to hide internal directories.