respond

package
v0.0.0-...-24cb8d0 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Payload

func Payload(where, from string) string

func SwaggerJSONHandler

func SwaggerJSONHandler(v string) (f func(ctx *routing.Context) error)

func WithJSON

func WithJSON(ctx *routing.Context, code int, payload t.Payload)

func WithWrapErrJSON

func WithWrapErrJSON(ctx *routing.Context, code int, e Error, payload t.Payload)

Types

type Error

type Error struct {
	API     string
	Func    string
	Err     error
	Payload string
}

Payload format: "where: from" i.e. "request: json.Unmarshal"

Jump to

Keyboard shortcuts

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