wrapper

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ResponseWriterNoBody

type ResponseWriterNoBody struct {
	http.ResponseWriter
}

ResponseWriterNoBody is a wrapper used to suprress the body of the response to a request. Mainly used for HEAD requests.

func NewResponseWriterNoBody

func NewResponseWriterNoBody(w http.ResponseWriter) *ResponseWriterNoBody

NewResponseWriterNoBody creates a new ResponseWriterNoBody.

func (ResponseWriterNoBody) Header

func (w ResponseWriterNoBody) Header() http.Header

Header executes the Header method from the http.ResponseWriter.

func (ResponseWriterNoBody) Write

func (w ResponseWriterNoBody) Write(data []byte) (int, error)

Write suprresses the body.

func (ResponseWriterNoBody) WriteHeader

func (w ResponseWriterNoBody) WriteHeader(statusCode int)

WriteHeader writes the header to the http.ResponseWriter.

Jump to

Keyboard shortcuts

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