debug

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2022 License: Zlib Imports: 4 Imported by: 1

Documentation

Index

Constants

View Source
const (
	DUnkLevel       = Level(0)
	DNormalLevel    = Level(1)
	DImportantLevel = Level(2)
	DTightLevel     = Level(3) // 紧级
	DFatalLevel     = Level(4) // 致命
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Debug

type Debug struct {
	Code    int32
	Name    string //服务模板名称
	Content string //简单描述
	Stack   string //调用堆栈
	Level   Level  //级别(严重程度)
	Error   error
}

func New

func New(code int32) Debug

func NewStack

func NewStack(code int32) Debug

func (Debug) String added in v0.1.2

func (d Debug) String() string

func (Debug) WithDetail added in v0.1.2

func (d Debug) WithDetail(format string, a ...interface{}) Debug

func (Debug) WithError added in v0.1.2

func (d Debug) WithError(er error) Debug

func (Debug) WithLevel added in v0.1.2

func (d Debug) WithLevel(l Level) Debug

func (Debug) WithStack added in v0.1.2

func (d Debug) WithStack() Debug

type Level

type Level int32

Jump to

Keyboard shortcuts

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