Documentation ¶
Overview ¶
Package server provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen version v1.11.0 DO NOT EDIT.
Package server provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen version v1.11.0 DO NOT EDIT.
Index ¶
- func Handler(si ServerInterface) http.Handler
- func HandlerFromMux(si ServerInterface, r chi.Router) http.Handler
- func HandlerFromMuxWithBaseURL(si ServerInterface, r chi.Router, baseURL string) http.Handler
- func HandlerWithOptions(si ServerInterface, options ChiServerOptions) http.Handler
- func RunGRPCServerOnAddr(addr string, registerServer func(server *grpc.Server))
- func RunGrpcServer(registerServer func(server *grpc.Server))
- func RunHTTPServer(createHandler func(router chi.Router) http.Handler)
- func RunHTTPServerOnAddr(addr string, createHandler func(router chi.Router) http.Handler)
- type ChiServerOptions
- type Error
- type GetSession
- type InvalidParamFormatError
- type MiddlewareFunc
- type PostSession
- type RequiredHeaderError
- type RequiredParamError
- type ServerInterface
- type ServerInterfaceWrapper
- type SetSessionJSONBody
- type SetSessionJSONRequestBody
- type TooManyValuesForParamError
- type UnescapedCookieParamError
- type UnmarshalingParamError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Handler ¶
func Handler(si ServerInterface) http.Handler
Handler creates http.Handler with routing matching OpenAPI spec.
func HandlerFromMux ¶
func HandlerFromMux(si ServerInterface, r chi.Router) http.Handler
HandlerFromMux creates http.Handler with routing matching OpenAPI spec based on the provided mux.
func HandlerFromMuxWithBaseURL ¶
func HandlerFromMuxWithBaseURL(si ServerInterface, r chi.Router, baseURL string) http.Handler
func HandlerWithOptions ¶
func HandlerWithOptions(si ServerInterface, options ChiServerOptions) http.Handler
HandlerWithOptions creates http.Handler with additional options
func RunGRPCServerOnAddr ¶
func RunGrpcServer ¶
func RunHTTPServer ¶
func RunHTTPServerOnAddr ¶
Types ¶
type ChiServerOptions ¶
type ChiServerOptions struct { BaseURL string BaseRouter chi.Router Middlewares []MiddlewareFunc ErrorHandlerFunc func(w http.ResponseWriter, r *http.Request, err error) }
type GetSession ¶
type GetSession struct {
Values *map[string]interface{} `json:"values,omitempty"`
}
GetSession defines model for GetSession.
type InvalidParamFormatError ¶
func (*InvalidParamFormatError) Error ¶
func (e *InvalidParamFormatError) Error() string
func (*InvalidParamFormatError) Unwrap ¶
func (e *InvalidParamFormatError) Unwrap() error
type MiddlewareFunc ¶
type MiddlewareFunc func(http.HandlerFunc) http.HandlerFunc
type PostSession ¶
type PostSession struct { SessionKey string `json:"sessionKey"` SessionValue map[string]interface{} `json:"sessionValue"` }
PostSession defines model for PostSession.
type RequiredHeaderError ¶
func (*RequiredHeaderError) Error ¶
func (e *RequiredHeaderError) Error() string
func (*RequiredHeaderError) Unwrap ¶
func (e *RequiredHeaderError) Unwrap() error
type RequiredParamError ¶
type RequiredParamError struct {
ParamName string
}
func (*RequiredParamError) Error ¶
func (e *RequiredParamError) Error() string
type ServerInterface ¶
type ServerInterface interface { // (POST /session) SetSession(w http.ResponseWriter, r *http.Request) // (DELETE /session/{sessionId}) DeleteSession(w http.ResponseWriter, r *http.Request, sessionId string) // (GET /session/{sessionId}) GetSession(w http.ResponseWriter, r *http.Request, sessionId string) }
ServerInterface represents all server handlers.
type ServerInterfaceWrapper ¶
type ServerInterfaceWrapper struct { Handler ServerInterface HandlerMiddlewares []MiddlewareFunc ErrorHandlerFunc func(w http.ResponseWriter, r *http.Request, err error) }
ServerInterfaceWrapper converts contexts to parameters.
func (*ServerInterfaceWrapper) DeleteSession ¶
func (siw *ServerInterfaceWrapper) DeleteSession(w http.ResponseWriter, r *http.Request)
DeleteSession operation middleware
func (*ServerInterfaceWrapper) GetSession ¶
func (siw *ServerInterfaceWrapper) GetSession(w http.ResponseWriter, r *http.Request)
GetSession operation middleware
func (*ServerInterfaceWrapper) SetSession ¶
func (siw *ServerInterfaceWrapper) SetSession(w http.ResponseWriter, r *http.Request)
SetSession operation middleware
type SetSessionJSONBody ¶
type SetSessionJSONBody = PostSession
SetSessionJSONBody defines parameters for SetSession.
type SetSessionJSONRequestBody ¶
type SetSessionJSONRequestBody = SetSessionJSONBody
SetSessionJSONRequestBody defines body for SetSession for application/json ContentType.
type TooManyValuesForParamError ¶
func (*TooManyValuesForParamError) Error ¶
func (e *TooManyValuesForParamError) Error() string
type UnescapedCookieParamError ¶
func (*UnescapedCookieParamError) Error ¶
func (e *UnescapedCookieParamError) Error() string
func (*UnescapedCookieParamError) Unwrap ¶
func (e *UnescapedCookieParamError) Unwrap() error
type UnmarshalingParamError ¶
func (*UnmarshalingParamError) Error ¶
func (e *UnmarshalingParamError) Error() string
func (*UnmarshalingParamError) Unwrap ¶
func (e *UnmarshalingParamError) Unwrap() error