MCPcopy
hub / github.com/dgraph-io/dgraph / validFuncName

Function validFuncName

dql/parser.go:1697–1708  ·  view source on GitHub ↗
(name string)

Source from the content-addressed store, hash-verified

1695}
1696
1697func validFuncName(name string) bool {
1698 if isGeoFunc(name) || IsInequalityFn(name) {
1699 return true
1700 }
1701
1702 switch name {
1703 case "regexp", "anyofterms", "allofterms", "alloftext", "anyoftext", "ngram",
1704 "has", "uid", "uid_in", "anyof", "allof", "type", "match", "similar_to":
1705 return true
1706 }
1707 return false
1708}
1709
1710type regexArgs struct {
1711 expr string

Callers 1

getRootFunction · 0.85

Calls 2

isGeoFuncFunction · 0.85
IsInequalityFnFunction · 0.85

Tested by

no test coverage detected