router

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Context

type Context struct {
	Helper httpserver.HelperInterface
	// contains filtered or unexported fields
}

Context ...

func NewService

func NewService(router httpserver.RouterInterface, helper httpserver.HelperInterface, middleware ma.Middleware, prefix string) Context

func (*Context) InitOptionsRoute

func (r *Context) InitOptionsRoute()

func (*Context) RegisterEndpoint

func (r *Context) RegisterEndpoint(info EndpointInfo)

RegisterEndpoint ...

func (*Context) RegisterEndpointWithPrefix

func (r *Context) RegisterEndpointWithPrefix(info EndpointInfo, prefix string)

RegisterEndpointWithPrefix ...

func (*Context) RegisterRootEndpoint added in v1.3.0

func (r *Context) RegisterRootEndpoint(info EndpointInfo)

RegisterRootEndpoint ...

func (*Context) ServeHTTP

func (r *Context) ServeHTTP(w http.ResponseWriter, req *http.Request)

type EndpointInfo

type EndpointInfo struct {
	HTTPMethod    string
	URLPattern    string
	Handler       handler.EndpointHandler
	Verifications []constants.VerificationType
}

Jump to

Keyboard shortcuts

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