MCPcopy
hub / github.com/go-gorm/gorm / Not

Function Not

clause/where.go:152–162  ·  view source on GitHub ↗
(exprs ...Expression)

Source from the content-addressed store, hash-verified

150}
151
152func Not(exprs ...Expression) Expression {
153 if len(exprs) == 0 {
154 return nil
155 }
156 if len(exprs) == 1 {
157 if andCondition, ok := exprs[0].(AndConditions); ok {
158 exprs = andCondition.Exprs
159 }
160 }
161 return NotConditions{Exprs: exprs}
162}
163
164type NotConditions struct {
165 Exprs []Expression

Callers 3

NotMethod · 0.92
ReplaceMethod · 0.92
TestWhereFunction · 0.92

Calls

no outgoing calls

Tested by 1

TestWhereFunction · 0.74