httpserver

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2024 License: AGPL-3.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrorWithStatusCode

type ErrorWithStatusCode struct {
	Err        error
	StatusCode int
}

ErrorWithStatusCode is error with HTTP status code.

The given StatusCode is sent to client when the error is passed to Errorf.

func (*ErrorWithStatusCode) Error

func (e *ErrorWithStatusCode) Error() string

Error implements error interface.

func (*ErrorWithStatusCode) Unwrap

func (e *ErrorWithStatusCode) Unwrap() error

Unwrap returns e.Err.

This is used by standard errors package. See https://golang.org/pkg/errors

Jump to

Keyboard shortcuts

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