router

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package router provides implementation of Go API for routing http Handler wrapped by rest.Func

Package router provides implementation of Go API for routing http Handler wrapped by rest.Func

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(opts ...Option) http.Handler

New returns REST route&method information from handler interface.

Types

type Option

type Option func(*router)

Option represents the functional option for router.

func WithErrGroup

func WithErrGroup(eg errgroup.Group) Option

WithErrGroup returns the option to set the error group for the router.

func WithHandler

func WithHandler(h rest.Handler) Option

WithHandler returns the option to set the handler for the router.

func WithTimeout

func WithTimeout(timeout string) Option

WithTimeout returns the option to set the timeout for the router.

Jump to

Keyboard shortcuts

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