error

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HiveError

type HiveError struct {
	Path   string `json:"path"`
	Status int    `json:"status"`
	Title  string `json:"title"`
	Detail string `json:"detail"`
}

HiveError represent the server themisError format

func NewHiveBadRequestError

func NewHiveBadRequestError(ctx iris.Context, detail string) *HiveError

NewHiveBadRequestError - create a new HiveError for a 400 themisError code //path is the endpoint where the themisError happened //detail is the themisError description

func NewHiveInternalServerError

func NewHiveInternalServerError(ctx iris.Context, detail string) *HiveError

NewHiveInternalServerError - create a new HiveError for a 500 themisError code //path is the endpoint where the themisError happened //detail is the themisError description

func NewHiveUnauthorizedError

func NewHiveUnauthorizedError(ctx iris.Context, detail string) *HiveError

NewHiveUnauthorizedError - create a new HiveError for a 401 themisError code //path is the endpoint where the themisError happened //detail is the themisError description

Jump to

Keyboard shortcuts

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