MCPcopy Create free account
hub / github.com/vektah/gqlparser / IsValidIntString

Function IsValidIntString

validator/vars.go:273–280  ·  view source on GitHub ↗
(val reflect.Value, kind reflect.Kind)

Source from the content-addressed store, hash-verified

271}
272
273func IsValidIntString(val reflect.Value, kind reflect.Kind) bool {
274 if kind != reflect.String {
275 return false
276 }
277 _, e := strconv.ParseInt(fmt.Sprintf("%v", val.Interface()), 10, 64)
278
279 return e == nil
280}
281
282func IsValidFloatString(val reflect.Value, kind reflect.Kind) bool {
283 if kind != reflect.String {

Callers 1

validateVarTypeMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…