http

package
v1.6.18 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BatchRequest added in v1.6.6

type BatchRequest struct {
	Path   string          `json:"path"`
	Method string          `json:"method"`
	Body   json.RawMessage `json:"body,omitempty"`
}

type BatchResponse added in v1.6.6

type BatchResponse struct {
	Path   string          `json:"path"`
	Method string          `json:"method"`
	Body   json.RawMessage `json:"body,omitempty"`
	Status int             `json:"status"`
}

func (*BatchResponse) Error added in v1.6.6

func (b *BatchResponse) Error(httpErr *utils.HTTPError) (err error)

type HttpManagerCtx

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

func New

func New(WebSocketManager types.WebSocketManager, ApiManager types.ApiManager, config *config.Server) *HttpManagerCtx

func (*HttpManagerCtx) Shutdown

func (manager *HttpManagerCtx) Shutdown() error

func (*HttpManagerCtx) Start

func (manager *HttpManagerCtx) Start()

type RouterOption added in v1.6.16

type RouterOption func(*router)

func WithCORS added in v1.6.16

func WithCORS(allowOrigin func(origin string) bool) RouterOption

func WithLogger added in v1.6.16

func WithLogger(logger zerolog.Logger) RouterOption

func WithPathPrefix added in v1.6.16

func WithPathPrefix(prefix string) RouterOption

func WithRealIP added in v1.6.16

func WithRealIP() RouterOption

func WithRecoverer added in v1.6.16

func WithRecoverer() RouterOption

func WithRequestID added in v1.6.16

func WithRequestID() RouterOption

Jump to

Keyboard shortcuts

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