beegoutil

package module
v0.0.0-...-ed08d07 Latest Latest
Warning

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

Go to latest
Published: May 22, 2019 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ResponseError

func ResponseError(errMsg string, controller beego.Controller, response StatusMessageModelInterface, status, httpStatus int)

ResponseError responds the client with given status and message for error.

func ResponseIfError

func ResponseIfError(err error, controller beego.Controller, response StatusMessageModelInterface, status, httpStatus int) bool

ResponseIfError responds the client with given status and message if error is encountered

Types

type StatusMessageModelInterface

type StatusMessageModelInterface interface {
	SetStatus(status int)
	SetMessage(message string)
}

StatusMessageModelInterface defines the StatusMessageModeInterface

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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