sign_error

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Feb 2, 2022 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrUnknown = iota
	ErrBindReqFailed
	ErrAuthFailed
	ErrHandle
	ErrRPCRequest
	ErrInternal
	ErrInvalidParam
)

Variables

View Source
var (
	ErrMap = map[int]string{
		ErrUnknown:       "未知错误",
		ErrBindReqFailed: "解析请求错误",
		ErrAuthFailed:    "认证失败",
		ErrRPCRequest:    "服务调用失败",
		ErrInternal:      "内部错误",
		ErrInvalidParam:  "无效数据",
		ErrHandle:        "处理请求错误",
	}
)

todo: 代码自动生成

Functions

func New

func New(code int, format string, a ...interface{}) error

Types

type SignError

type SignError struct {
	Code        int
	CodeDesc    string
	Description string
}

func (*SignError) Error

func (se *SignError) Error() string

Jump to

Keyboard shortcuts

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