echoutils

package
v0.0.0-...-134a4a7 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2019 License: BSD-3-Clause, MIT Imports: 10 Imported by: 0

README

echoutils

echo 框架辅助库

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AsyncResponse

func AsyncResponse(ctx echo.Context, logicInstance interface{}, methodName string, args ...interface{}) error

func Fail

func Fail(ctx echo.Context, code int, msg string) error

func IsAsync

func IsAsync(ctx echo.Context) bool

IsAsync 是否异步处理

func Success

func Success(ctx echo.Context, data interface{}) error

func WrapContext

func WrapContext(ctx context.Context) context.Context

WrapContext 返回一个 context.Context 实例。如果 ctx == nil,需要确保 调用 logger.PutLogger()

func WrapEchoContext

func WrapEchoContext(ctx echo.Context) context.Context

WrapContext 返回一个 context.Context 实例

Types

This section is empty.

Jump to

Keyboard shortcuts

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