dhttp

package
v0.1.40 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2022 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HTTPBody

func HTTPBody(ctx context.Context, httpClient *http.Client, buf *bytes.Buffer, method, url string, header http.Header, reqBody, respBody, errBody any) (respCode int, err error)

func HTTPSimple

func HTTPSimple(ctx context.Context, httpClient *http.Client, method, url string, header http.Header, respBody, errBody any) (respCode int, err error)

func WriteErr

func WriteErr(logger dlog.Logger, resp http.ResponseWriter, err error)

func WriteJSON

func WriteJSON(resp http.ResponseWriter, statusCode int, v any)

Types

This section is empty.

Jump to

Keyboard shortcuts

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