// QueryGetFloat64 gets the float64 by key from the request query, if it exists.
// Otherwise, returns 0.0.
// error returned if there is a parsing error.
487486
func QueryGetFloat64(request *http.Request, key string) (float64, error) {
	return ParseFloat64(QueryGet(request, key))
}
360520
func (k *Key) InFloat64(defaultVal float64, candidates []float64) float64 {
	val := k.MustFloat64()
	for _, cand := range candidates {
		if val == cand {
			return val
		}
	}
	return defaultVal
}
722505
func (p *Params) Float64(key string) (float64, error) {
	return strconv.ParseFloat(p.Get(key), 64)
}
99330
func (ctx *Context) QueryFloat32(key string, defaults ...float32) float32 {
	return (*Queries)(ctx.req).MustFloat32(key, defaults...)
}
421162
func GetFloat64OrDefault(key string, defVal float64) float64 {
	viperLock.RLock()
	defer viperLock.RUnlock()

	if val := viper.GetFloat64(key); val != 0 {
		return val
	}

	return defVal
}
1088583
func (s *Session) GetFloat(ctx context.Context, key string) float64 {
	val := s.Get(ctx, key)
	f, ok := val.(float64)
	if !ok {
		return 0
	}
	return f
}
481032
func Float64(f float64) NullFloat64 {
	return NullFloat64{
		sql.NullFloat64{
			Float64: f,
			Valid:   true,
		},
	}
}
1123972
func (r Row) GetFloat64(colIdx int) float64 {
	col := r.c.columns[colIdx]
	return *(*float64)(unsafe.Pointer(&col.data[r.idx*8]))
}
1157919
func (RPCResponse *RPCResponse) GetFloat() (float64, error) {
	val, ok := RPCResponse.Result.(json.Number)
	if !ok {
		return 0, fmt.Errorf("could not parse float64 from %s", RPCResponse.Result)
	}

	f, err := val.Float64()
	if err != nil {
		return 0, err
	}

	return f, nil
}
1203852
func ParamFloat64(r *http.Request, name string, defaultValue float64) float64 {
	value, err := strconv.ParseFloat(r.FormValue(name), 10)
	if err != nil {
		return defaultValue
	}
	return value
}
208395
func getFloat(unk interface{}) float64 {
	switch i := unk.(type) {
	case float64:
		return i
	case string:
		f, err := strconv.ParseFloat(i, 64)
		if err != nil || math.IsNaN(f) {
			return float64(0)
		}
		return f
	default:
		return float64(0)
	}
}
572252
func toFloat64(v reflect.Value) float64 {
	f, _ := tryToFloat64(v)
	return f
}
1295207
func GetFloat64(key string, defaultValue float64) float64 {
	result, err := factory.GetValue(key).ToFloat64()
	if err != nil {
		return defaultValue
	}
	return result
}
1173657
func (s *Session) GetFloat(key string, def float64) float64 {
	v, ok := s.Values[key]
	if !ok {
		return def
	}

	return v.(float64)
}
1076473
func Float64() float64 {
	mu.Lock()
	res := r.Float64()
	mu.Unlock()
	return res
}
156016
func ParseQueryFloat(param string, req *http.Request, params imageserver.Params) error {
	s := req.URL.Query().Get(param)
	if s == "" {
		return nil
	}
	f, err := strconv.ParseFloat(s, 64)
	if err != nil {
		return newParseTypeParamError(param, "float", err)
	}
	params.Set(param, f)
	return nil
}
264204
func Float64(key string, fallback float64) float64 {
	return DefaultClient.Float64(key, fallback)
}