middleware

package
v0.0.0-...-e92691c Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2019 License: MIT Imports: 1 Imported by: 0

README

Adapters

Set of HTTP Handlers

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

type Adapter func(http.Handler) http.Handler

Adapter represents middleware abstraction

type Chain

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

Chain holds a slice of adapters

func New

func New(adapters ...Adapter) Chain

New returns new adapter chain

func (Chain) Append

func (c Chain) Append(adapters ...Adapter) Chain

Append adapters to the current chain

func (Chain) Extend

func (c Chain) Extend(chain Chain) Chain

Extend the adapter chain

func (Chain) Then

func (c Chain) Then(h http.Handler) http.Handler

Then chains middleware

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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