typedresp

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2026 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Error

type Error struct {
	Status  int
	Message string
}

func ErrStatus

func ErrStatus(status int, message string) Error

func NewErr

func NewErr(err error) Error

func (Error) Error

func (e Error) Error() string

type Response

type Response struct {
	// contains filtered or unexported fields
}

func JSON

func JSON(status int, v any) Response

func NoContent

func NoContent() Response

func Stream

func Stream(status int, body io.ReadCloser) Response

func Text

func Text(status int, s string) Response

func (Response) Write

func (r Response) Write(w http.ResponseWriter, logger *zap.Logger)

Jump to

Keyboard shortcuts

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