errs

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Cause

func Cause(err error) error

func GetHttpCode

func GetHttpCode(e error) int

func Wrap

func Wrap(err error, message string) error

Types

type ErrorType

type ErrorType uint
const (
	Unknown ErrorType = iota
	Invalidated
	Unauthorized
	Forbidden
	NotFound
	Conflict
	Failed
)

func GetType

func GetType(e error) ErrorType

func (ErrorType) Errorf

func (et ErrorType) Errorf(format string, args ...interface{}) error

func (ErrorType) New

func (et ErrorType) New(message string) error

func (ErrorType) Wrap

func (et ErrorType) Wrap(err error, message string) error

func (ErrorType) Wrapf

func (et ErrorType) Wrapf(err error, format string, args ...interface{}) error

Jump to

Keyboard shortcuts

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