scihttp

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2023 License: MIT Imports: 5 Imported by: 0

README

scihttp

Documentation

Overview

Package scihttp contains Scienti's common HTTP library.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NotImplementedError

func NotImplementedError(w http.ResponseWriter)

Types

type Context

type Context struct {
	context.Context
	// contains filtered or unexported fields
}

func (*Context) Request

func (ctx *Context) Request() *http.Request

func (*Context) ResponseWriter

func (ctx *Context) ResponseWriter() http.ResponseWriter

type Middleware

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

func NewMiddleware

func NewMiddleware(pre http.HandlerFunc, post http.HandlerFunc) *Middleware

func (*Middleware) Handler

func (mdw *Middleware) Handler(h httprouter.Handle) httprouter.Handle

func (*Middleware) Next

func (*Middleware) ServeHTTP

func (mdw *Middleware) ServeHTTP(w http.ResponseWriter, r *http.Request)

type MiddlewareChainNode

type MiddlewareChainNode interface {
	Next(m *Middleware) MiddlewareChainNode
	Handler(h httprouter.Handle) httprouter.Handle
}

func NewMiddlewarePipeline

func NewMiddlewarePipeline() MiddlewareChainNode

type MiddlewarePipeline

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

func (*MiddlewarePipeline) HandleHTTP

func (*MiddlewarePipeline) Handler

func (*MiddlewarePipeline) Next

Jump to

Keyboard shortcuts

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