middleware

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

* @Descripttion: * @version: * @Author: lfzxs@qq.com * @Date: 2023-11-08 14:40:59 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2023-11-09 14:54:50

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MiddlewareHandlerResponse

func MiddlewareHandlerResponse(r *ghttp.Request)

MiddlewareHandlerResponse is the default middleware handling handler response object and its error.

Types

type DefaultHandlerResponse

type DefaultHandlerResponse struct {
	Code    int         `json:"code"    dc:"Error code"`
	Message string      `json:"message" dc:"Error message"`
	Data    interface{} `json:"data"    dc:"Result data for certain request according API definition"`
	TraceID string      `json:"traceId" dc:"链路id"`
}

DefaultHandlerResponse is the default implementation of HandlerResponse.

Jump to

Keyboard shortcuts

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