errors

package
v0.0.0-...-88bf645 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUnknown = New(0, "unknown error.")

Functions

This section is empty.

Types

type Error

type Error struct {
	Code    uint   `json:"code"`
	Message string `json:"message"`
	Cause   error  `json:"cause"`
}

func New

func New(code uint, message string) Error

func (Error) Error

func (m Error) Error() string

func (Error) Format

func (m Error) Format(param ...any) Error

func (Error) Is

func (m Error) Is(target error) bool

func (Error) Unwrap

func (m Error) Unwrap() error

func (Error) Wrap

func (m Error) Wrap(cause error) Error

Jump to

Keyboard shortcuts

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