Versions in this module Expand all Collapse all v2 v2.3.1 Jan 29, 2026 Changes in this version + var DefaultIPSourcePriority = []IPSource + func FormDataDecode[T any](r *http.Request, sizes ...int64) (*T, error) + func FormDecode(r *http.Request, dst any) error + func GetHeaderValueFormatInt(header http.Header, fields ...string) (map[string]int, error) + func GetQueryValueFromQuery2Int(qs url.Values, fields string, defaultValue ...int) (int, bool) + func GetQueryValueFromRequest2Int(r *http.Request, fields string, defaultValue ...int) (int, bool) + func Getip(r *http.Request, policys ...IPSource) string + func JsonDecodePtr[T interface{ ... }, E any](r *http.Request, target ...T) (T, error) + func JsonDecode[T any](r *http.Request) (T, error) + func QueryDecode(u url.Values, dst any) error + type File struct + Body *bytes.Buffer + Filename string + Header textproto.MIMEHeader + Size int64 + type Files []File + type IPParsePolicy []IPSource + func (p IPParsePolicy) GetFromIPSources(sources *IPSources) string + func (p IPParsePolicy) GetIP(r *http.Request) string + type IPSource string + const HeaderCFConnectingIP + const HeaderForwarded + const HeaderHTTPClientIP + const HeaderHTTPXForwardedFor + const HeaderTrueClientIP + const HeaderVia + const HeaderXForwardedFor + const HeaderXForwardedHost + const HeaderXForwardedProto + const HeaderXRealIP + const RemoteAddr + func (s IPSource) String() string + type IPSources struct + CFConnectingIP string + Forwarded string + HTTPClientIP string + HTTPXForwardedFor string + RemoteAddr string + TrueClientIP string + Via string + XForwardedFor string + XForwardedHost string + XForwardedProto string + XRealIP string + func ParseRequestIPSources(r *http.Request) IPSources v2.3.0 Dec 9, 2025