Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Middleware ¶
type Middleware struct {
// contains filtered or unexported fields
}
Middleware struct
func NewMiddleware ¶
func NewMiddleware( handler gonethttphandler.Handler, validator govalidatorstructmappervalidator.Service, generator govalidatorstructmapper.Generator, ) (*Middleware, error)
NewMiddleware creates a new Middleware instance
func (*Middleware) Validate ¶
func (m *Middleware) Validate( body interface{}, validatorFns ...func(*validation.StructValidations) error, ) func(next http.Handler) http.Handler
Validate validates the request body and stores it in the context
Click to show internal directories.
Click to hide internal directories.