rexErrors

package
v1.1.58 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LangZhCN = "zh-CN"
	LangZhTW = "zh-TW"
	LangEnUS = "en-US"
)

Variables

This section is empty.

Functions

func New

func New(code int32, msg string) error

New creates a new CodeMsg.

func Quick

func Quick(code int32, Lang string) error

func StatusText added in v1.1.58

func StatusText(code int32, v ...any) string

Types

type CodeMsg

type CodeMsg struct {
	Code int32
	Msg  string
}

func (*CodeMsg) Error

func (c *CodeMsg) Error() string

type CommonResponse added in v1.1.58

type CommonResponse struct {
	Code      int32       `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	Msg       string      `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
	RequestID string      `protobuf:"bytes,3,opt,name=requestID,proto3" json:"requestID,omitempty"`
	Path      string      `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
	Data      interface{} `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"`
}

type ListData added in v1.1.58

type ListData struct {
	List     interface{} `json:"list"`
	Total    int64       `json:"total"`
	Page     int         `json:"page"`
	PageSize int         `json:"pageSize"`
}

Jump to

Keyboard shortcuts

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