msg

package
v0.0.0-...-5974b80 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2023 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MSG_LEVEL_INFO  = "level_info"
	MSG_LEVEL_WARN  = "level_warn"
	MSG_LEVEL_ERROR = "level_error"
	MSG_LEVEL_FATAL = "level_fatal"
)
View Source
const (
	MSG_SUCCESS = "id_success"
	MSG_FAIL    = "id_fail"
	MSG_ERROR   = "id_error"
	MSG_FATAL   = "id_fatal"
)
View Source
const (
	MSG_SUCCESS_PART    = "success_part"
	MSG_UNKNOWN_ERROR   = "unknown_error"
	MSG_UNKNOWN_OPERATE = "unknown_operate"

	MSG_FORBID_NOAUTH = "forbid_noauth"

	MSG_BATCH_FORBID = "batch_forbid"
	MSG_BATCH_OVER   = "batch_over"

	MSG_SESSION_INVALID = "session_invalid"
	MSG_SESSION_TIMEOUT = "session_timeout"

	MSG_PARA_ABSENT = "para_absent"
	MSG_OBJ_EXIST   = "obj_exist"
	MSG_OBJ_NOEXIST = "obj_noexist"

	MSG_LICENSE_INVALID = "license_invalid"
	MSG_LICENSE_VOID    = "license_void"

	MSG_LICENSE_NOENOUGH = "license_noenough"
	MSG_LICENSE_Expired  = "license_expired"
)

Variables

This section is empty.

Functions

func Reg

func Reg(level string, msgId string, msgInfo string)

func RegError

func RegError(msgId string, msgInfo string)

func RegFatal

func RegFatal(msgId string, msgInfo string)

func RegInfo

func RegInfo(msgId string, msgInfo string)

func RegWarn

func RegWarn(msgId string, msgInfo string)

Types

type FastMsg

type FastMsg struct {
	Level   string `json:"level"`
	MsgId   string `json:"msgId"`
	MsgInfo string `json:"msgInfo"`
}

func Item

func Item(msgId string) (msg *FastMsg, ok bool)

type MsgBuffInfo

type MsgBuffInfo struct {
	MapMsg map[string](*FastMsg)
}

Jump to

Keyboard shortcuts

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