httputil

package
v0.0.0-...-779d743 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Error

func Error(w http.ResponseWriter, error string, code int)

Error encodes json error payload into ResponseWriter.

func Respond

func Respond(w http.ResponseWriter, entity interface{})

Respond json encodes entity into ResponseWriter or error if encoding failed.

Types

This section is empty.

Jump to

Keyboard shortcuts

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