errors

package
v1.0.12 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 4, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	New          = errors.New
	Wrap         = errors.Wrap
	Wrapf        = errors.Wrapf
	WithStack    = errors.WithStack
	WithMessage  = errors.WithMessage
	WithMessagef = errors.WithMessagef
)

定义别名

View Source
var (
	Success        = New("请求成功")
	CreatedSuccess = New("创建成功")
	UpdatedSuccess = New("更新成功")
	DeletedSuccess = New("删除成功")
	GetSuccess     = New("查询成功")

	ErrEncryptFailed = New("密码加密失败!")
	ErrUserExists    = New("账户已存在!")

	ErrDeletedFail             = New("删除失败")
	ErrTimeOut                 = New("操作超时")
	ErrBadRequest              = New("请求发生错误")
	ErrInvalidParent           = New("无效的父级节点")
	ErrNotAllowDeleteWithChild = New("含有子级,不能删除")
	ErrNotAllowDelete          = New("资源不允许删除")
	ErrInvalidUserName         = New("无效的用户名")
	ErrInvalidPassword         = New("无效的密码")
	ErrInvalidUser             = New("无效的用户")
	ErrUserDisable             = New("用户被禁用,请联系管理员")

	ErrUnAuthorized           = New("非法访问")
	ErrNoPermission           = New("无访问权限")
	ErrInvalidToken           = New("令牌失效")
	ErrNotFound               = New("资源不存在")
	ErrMethodNotAllow         = New("方法不被允许")
	ErrTooManyRequests        = New("请求过于频繁")
	ErrInternalServer         = New("服务器发生错误")
	ErrInvalidParam           = New("请求参数异常")
	ErrInvalidParamParseParse = New("请求参数解析异常")

	ErrDBNotFound = New("数据库不存在!")
)

定义错误

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL