handlers

package
v0.0.0-...-e5e8710 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPResponse

type HTTPResponse struct {
	StatusCode int
	Headers    map[string]string
	Message    string
	Data       interface{}
}

func (HTTPResponse) BadRequest

func (h HTTPResponse) BadRequest(err error) HTTPResponse

func (HTTPResponse) BadRequestf

func (h HTTPResponse) BadRequestf(format string, a ...any) HTTPResponse

func (HTTPResponse) Error

func (h HTTPResponse) Error(err error) HTTPResponse

func (HTTPResponse) Errorf

func (h HTTPResponse) Errorf(format string, a ...any) HTTPResponse

func (HTTPResponse) Header

func (h HTTPResponse) Header(key, value string) HTTPResponse

func (HTTPResponse) NotFound

func (h HTTPResponse) NotFound() HTTPResponse

func (HTTPResponse) Ok

func (h HTTPResponse) Ok(message string, data interface{}) HTTPResponse

func (HTTPResponse) Response

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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