server

package
v0.0.0-...-0ae60ed Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	R *gin.Engine
)

Functions

func Init

func Init()

func Start

func Start(port string)

Types

type Response

type Response[T any] struct {
	Message string `json:"message"`
	Data    T      `json:"data"`
}

func EmptyResponse

func EmptyResponse() Response[any]

func ErrorResponse

func ErrorResponse(err error) Response[string]

func OKResponse

func OKResponse[T any](data T) Response[T]

Jump to

Keyboard shortcuts

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