routes

package
v3.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2022 License: MIT Imports: 12 Imported by: 1

Documentation

Index

Constants

View Source
const ApiDocPath = "/api/docs"
View Source
const HelthPath = "/health"

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiDoc

type ApiDoc struct {
	Debug bool
}

func (*ApiDoc) Handle

func (a *ApiDoc) Handle(w http.ResponseWriter, r *http.Request, _ map[string]string)

func (*ApiDoc) Method

func (a *ApiDoc) Method() string

func (*ApiDoc) Middlewares

func (a *ApiDoc) Middlewares() []middlewares.Middleware

func (*ApiDoc) Path

func (a *ApiDoc) Path() string

func (*ApiDoc) SetClient

func (a *ApiDoc) SetClient(client *grpc.ClientConn)

type ApiDocRedirect

type ApiDocRedirect struct {
}

func (*ApiDocRedirect) Handle

func (a *ApiDocRedirect) Handle(w http.ResponseWriter, r *http.Request, _ map[string]string)

func (*ApiDocRedirect) Method

func (a *ApiDocRedirect) Method() string

func (*ApiDocRedirect) Middlewares

func (a *ApiDocRedirect) Middlewares() []middlewares.Middleware

func (*ApiDocRedirect) Path

func (a *ApiDocRedirect) Path() string

func (*ApiDocRedirect) SetClient

func (a *ApiDocRedirect) SetClient(client *grpc.ClientConn)

type Health

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

func (*Health) Handle

func (h *Health) Handle(w http.ResponseWriter, r *http.Request, _ map[string]string)

func (*Health) Method

func (h *Health) Method() string

func (*Health) Middlewares

func (h *Health) Middlewares() []middlewares.Middleware

func (*Health) Path

func (h *Health) Path() string

func (*Health) SetClient

func (h *Health) SetClient(client *grpc.ClientConn)

type Route

type Route interface {
	Path() string
	Method() string
	Handle(w http.ResponseWriter, r *http.Request, params map[string]string)
	SetClient(client *grpc.ClientConn)
	Middlewares() []middlewares.Middleware
}

Jump to

Keyboard shortcuts

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