errors

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Error

type Error struct {
	// contains filtered or unexported fields
}

Error represents a GO error but with more features - such as a cause and a call stack.

func New

func New(message string, a ...interface{}) Error

New creates a new instance of Error.

func (Error) Cause

func (instance Error) Cause() interface{}

Cause queries the cause that causes this error. If there is no cause nil is returned.

func (Error) CausedBy

func (instance Error) CausedBy(what interface{}) Error

CausedBy is a shortcut for Cause to use a builder pattern.

func (Error) Error

func (instance Error) Error() string

func (Error) Message

func (instance Error) Message() string

Message queries the error message.

func (Error) Stack

func (instance Error) Stack() stack.Stack

Stack queries the stack at the point this Error instance was created.

func (Error) String

func (instance Error) String() string

Jump to

Keyboard shortcuts

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