Documentation ¶
Index ¶
- func Form(r *http.Request, dst any) error
- func JSON(w http.ResponseWriter, r *http.Request, dst interface{}) error
- func JSONStrict(w http.ResponseWriter, r *http.Request, dst interface{}) error
- func PostForm(r *http.Request, dst any) error
- func Query(r *http.Request, dst any) error
- func QueryBool(r *http.Request, key string) bool
- func QueryFloat64(r *http.Request, key string) float64
- func QueryInt(r *http.Request, key string) int
- func QueryInt64(r *http.Request, key string) int64
- func QueryIsTrue(r *http.Request, key string) bool
- func QueryString(r *http.Request, key string) string
- func URLParamBool(r *http.Request, key string) bool
- func URLParamFloat64(r *http.Request, key string) float64
- func URLParamInt64(r *http.Request, key string) int64
- func URLParamString(r *http.Request, key string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func JSON ¶
func JSON(w http.ResponseWriter, r *http.Request, dst interface{}) error
JSON decodes the JSON in an HTTP request into a struct. From: autostrada.dev
func JSONStrict ¶
func JSONStrict(w http.ResponseWriter, r *http.Request, dst interface{}) error
JSONStrict decodes the JSON in an HTTP request into a struct, and From: autostrada.dev
func QueryBool ¶
QueryBool returns the value of a query string parameter as a bool in an HTTP request.
func QueryFloat64 ¶
QueryFloat64 returns the value of a query string parameter as a float64 in an HTTP request.
func QueryInt ¶
QueryInt returns the value of a query string parameter as an int in an HTTP request.
func QueryInt64 ¶
QueryInt64 returns the value of a query string parameter as an int64 in an HTTP request.
func QueryIsTrue ¶
QueryIsTrue checks if a query string parameter is set to a truthy value.
func QueryString ¶
QueryString returns the value of a query string parameter in an HTTP request.
Types ¶
This section is empty.