rest_errors

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2021 License: MIT Imports: 4 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RestErr

type RestErr interface {
	Message() string
	Status() int
	Error() string
	Causes() []interface{}
}

func NewBadRequestError

func NewBadRequestError(message string, err error) RestErr

func NewInternalServerError

func NewInternalServerError(message string, err error) RestErr

func NewNotFoundError

func NewNotFoundError(message string, err error) RestErr

func NewRestError

func NewRestError(message string, status int, err string, causes []interface{}) RestErr

func NewRestErrorFromBytes

func NewRestErrorFromBytes(bytes []byte) (RestErr, error)

func NewUnauthorizedError

func NewUnauthorizedError(message string) RestErr

Jump to

Keyboard shortcuts

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