Documentation
¶
Index ¶
- func BaseHandler[Req any, Resp any, Handler HandlerInterface[Req, Resp]](core requestCore.RequestCoreInterface, handler Handler, args ...any) any
- func Dml[Req libQuery.DmlModel](title, key string, core requestCore.RequestCoreInterface) any
- func DmlHandler[Req libQuery.DmlModel](title, key, path string, core requestCore.RequestCoreInterface, ...) any
- func DmlHandlerOld[Req libQuery.DmlModel](title, key string, core requestCore.RequestCoreInterface, mode libRequest.Type, ...) any
- func ExecDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, ...) (map[string]any, response.ErrorState)
- func ExecuteDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, ...) (map[string]any, response.ErrorState)
- func FinalizeDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, ...)
- func PreControlDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, ...) response.ErrorState
- type DmlHandlerType
- func (h DmlHandlerType[Req, Resp]) Finalizer(req HandlerRequest[Req, Resp])
- func (h DmlHandlerType[Req, Resp]) Handler(req HandlerRequest[Req, Resp]) (Resp, response.ErrorState)
- func (h DmlHandlerType[Req, Resp]) Initializer(req HandlerRequest[Req, Resp]) response.ErrorState
- func (h DmlHandlerType[Req, Resp]) Parameters() (string, libRequest.Type, bool, bool, string)
- type HandlerInterface
- type HandlerRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BaseHandler ¶
func BaseHandler[Req any, Resp any, Handler HandlerInterface[Req, Resp]]( core requestCore.RequestCoreInterface, handler Handler, args ...any, ) any
func Dml ¶
func Dml[Req libQuery.DmlModel]( title, key string, core requestCore.RequestCoreInterface, ) any
func DmlHandler ¶
func DmlHandler[Req libQuery.DmlModel]( title, key, path string, core requestCore.RequestCoreInterface, mode libRequest.Type, validateHeader bool, ) any
func DmlHandlerOld ¶ added in v0.9.2
func DmlHandlerOld[Req libQuery.DmlModel]( title, key string, core requestCore.RequestCoreInterface, mode libRequest.Type, validateHeader bool, ) any
func ExecDML ¶
func ExecDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, core requestCore.RequestCoreInterface) (map[string]any, response.ErrorState)
func ExecuteDML ¶
func ExecuteDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, core requestCore.RequestCoreInterface) (map[string]any, response.ErrorState)
func FinalizeDML ¶
func FinalizeDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, core requestCore.RequestCoreInterface)
func PreControlDML ¶
func PreControlDML(request libQuery.DmlModel, key, title string, w webFramework.WebFramework, core requestCore.RequestCoreInterface) response.ErrorState
Types ¶
type DmlHandlerType ¶
type DmlHandlerType[Req libQuery.DmlModel, Resp map[string]any] struct { Title string Path string Mode libRequest.Type VerifyHeader bool Key string }
func (DmlHandlerType[Req, Resp]) Finalizer ¶
func (h DmlHandlerType[Req, Resp]) Finalizer(req HandlerRequest[Req, Resp])
func (DmlHandlerType[Req, Resp]) Handler ¶
func (h DmlHandlerType[Req, Resp]) Handler(req HandlerRequest[Req, Resp]) (Resp, response.ErrorState)
func (DmlHandlerType[Req, Resp]) Initializer ¶
func (h DmlHandlerType[Req, Resp]) Initializer(req HandlerRequest[Req, Resp]) response.ErrorState
func (DmlHandlerType[Req, Resp]) Parameters ¶
func (h DmlHandlerType[Req, Resp]) Parameters() (string, libRequest.Type, bool, bool, string)
type HandlerInterface ¶
type HandlerInterface[Req any, Resp any] interface { // returns handler title // Request Bodymode // and validate header option // and save to request table option // and url path of handler Parameters() (string, libRequest.Type, bool, bool, string) // runs after validating request Initializer(req HandlerRequest[Req, Resp]) response.ErrorState // main handler runs after initialize Handler(req HandlerRequest[Req, Resp]) (Resp, response.ErrorState) // runs after sending back response Finalizer(req HandlerRequest[Req, Resp]) }
type HandlerRequest ¶
type HandlerRequest[Req any, Resp any] struct { Title string Core requestCore.RequestCoreInterface Header *libRequest.RequestHeader Request *Req Response Resp W webFramework.WebFramework Args []any }
Click to show internal directories.
Click to hide internal directories.