bitbucket.org/Aishee/synsec@v0.0.0-20210414005726-236fc01a153d/pkg/database/ent/alert/where.go (about)

     1  // Code generated by entc, DO NOT EDIT.
     2  
     3  package alert
     4  
     5  import (
     6  	"time"
     7  
     8  	"entgo.io/ent/dialect/sql"
     9  	"entgo.io/ent/dialect/sql/sqlgraph"
    10  	"bitbucket.org/Aishee/synsec/pkg/database/ent/predicate"
    11  )
    12  
    13  // ID filters vertices based on their ID field.
    14  func ID(id int) predicate.Alert {
    15  	return predicate.Alert(func(s *sql.Selector) {
    16  		s.Where(sql.EQ(s.C(FieldID), id))
    17  	})
    18  }
    19  
    20  // IDEQ applies the EQ predicate on the ID field.
    21  func IDEQ(id int) predicate.Alert {
    22  	return predicate.Alert(func(s *sql.Selector) {
    23  		s.Where(sql.EQ(s.C(FieldID), id))
    24  	})
    25  }
    26  
    27  // IDNEQ applies the NEQ predicate on the ID field.
    28  func IDNEQ(id int) predicate.Alert {
    29  	return predicate.Alert(func(s *sql.Selector) {
    30  		s.Where(sql.NEQ(s.C(FieldID), id))
    31  	})
    32  }
    33  
    34  // IDIn applies the In predicate on the ID field.
    35  func IDIn(ids ...int) predicate.Alert {
    36  	return predicate.Alert(func(s *sql.Selector) {
    37  		// if not arguments were provided, append the FALSE constants,
    38  		// since we can't apply "IN ()". This will make this predicate falsy.
    39  		if len(ids) == 0 {
    40  			s.Where(sql.False())
    41  			return
    42  		}
    43  		v := make([]interface{}, len(ids))
    44  		for i := range v {
    45  			v[i] = ids[i]
    46  		}
    47  		s.Where(sql.In(s.C(FieldID), v...))
    48  	})
    49  }
    50  
    51  // IDNotIn applies the NotIn predicate on the ID field.
    52  func IDNotIn(ids ...int) predicate.Alert {
    53  	return predicate.Alert(func(s *sql.Selector) {
    54  		// if not arguments were provided, append the FALSE constants,
    55  		// since we can't apply "IN ()". This will make this predicate falsy.
    56  		if len(ids) == 0 {
    57  			s.Where(sql.False())
    58  			return
    59  		}
    60  		v := make([]interface{}, len(ids))
    61  		for i := range v {
    62  			v[i] = ids[i]
    63  		}
    64  		s.Where(sql.NotIn(s.C(FieldID), v...))
    65  	})
    66  }
    67  
    68  // IDGT applies the GT predicate on the ID field.
    69  func IDGT(id int) predicate.Alert {
    70  	return predicate.Alert(func(s *sql.Selector) {
    71  		s.Where(sql.GT(s.C(FieldID), id))
    72  	})
    73  }
    74  
    75  // IDGTE applies the GTE predicate on the ID field.
    76  func IDGTE(id int) predicate.Alert {
    77  	return predicate.Alert(func(s *sql.Selector) {
    78  		s.Where(sql.GTE(s.C(FieldID), id))
    79  	})
    80  }
    81  
    82  // IDLT applies the LT predicate on the ID field.
    83  func IDLT(id int) predicate.Alert {
    84  	return predicate.Alert(func(s *sql.Selector) {
    85  		s.Where(sql.LT(s.C(FieldID), id))
    86  	})
    87  }
    88  
    89  // IDLTE applies the LTE predicate on the ID field.
    90  func IDLTE(id int) predicate.Alert {
    91  	return predicate.Alert(func(s *sql.Selector) {
    92  		s.Where(sql.LTE(s.C(FieldID), id))
    93  	})
    94  }
    95  
    96  // CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
    97  func CreatedAt(v time.Time) predicate.Alert {
    98  	return predicate.Alert(func(s *sql.Selector) {
    99  		s.Where(sql.EQ(s.C(FieldCreatedAt), v))
   100  	})
   101  }
   102  
   103  // UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
   104  func UpdatedAt(v time.Time) predicate.Alert {
   105  	return predicate.Alert(func(s *sql.Selector) {
   106  		s.Where(sql.EQ(s.C(FieldUpdatedAt), v))
   107  	})
   108  }
   109  
   110  // Scenario applies equality check predicate on the "scenario" field. It's identical to ScenarioEQ.
   111  func Scenario(v string) predicate.Alert {
   112  	return predicate.Alert(func(s *sql.Selector) {
   113  		s.Where(sql.EQ(s.C(FieldScenario), v))
   114  	})
   115  }
   116  
   117  // BucketId applies equality check predicate on the "bucketId" field. It's identical to BucketIdEQ.
   118  func BucketId(v string) predicate.Alert {
   119  	return predicate.Alert(func(s *sql.Selector) {
   120  		s.Where(sql.EQ(s.C(FieldBucketId), v))
   121  	})
   122  }
   123  
   124  // Message applies equality check predicate on the "message" field. It's identical to MessageEQ.
   125  func Message(v string) predicate.Alert {
   126  	return predicate.Alert(func(s *sql.Selector) {
   127  		s.Where(sql.EQ(s.C(FieldMessage), v))
   128  	})
   129  }
   130  
   131  // EventsCount applies equality check predicate on the "eventsCount" field. It's identical to EventsCountEQ.
   132  func EventsCount(v int32) predicate.Alert {
   133  	return predicate.Alert(func(s *sql.Selector) {
   134  		s.Where(sql.EQ(s.C(FieldEventsCount), v))
   135  	})
   136  }
   137  
   138  // StartedAt applies equality check predicate on the "startedAt" field. It's identical to StartedAtEQ.
   139  func StartedAt(v time.Time) predicate.Alert {
   140  	return predicate.Alert(func(s *sql.Selector) {
   141  		s.Where(sql.EQ(s.C(FieldStartedAt), v))
   142  	})
   143  }
   144  
   145  // StoppedAt applies equality check predicate on the "stoppedAt" field. It's identical to StoppedAtEQ.
   146  func StoppedAt(v time.Time) predicate.Alert {
   147  	return predicate.Alert(func(s *sql.Selector) {
   148  		s.Where(sql.EQ(s.C(FieldStoppedAt), v))
   149  	})
   150  }
   151  
   152  // SourceIp applies equality check predicate on the "sourceIp" field. It's identical to SourceIpEQ.
   153  func SourceIp(v string) predicate.Alert {
   154  	return predicate.Alert(func(s *sql.Selector) {
   155  		s.Where(sql.EQ(s.C(FieldSourceIp), v))
   156  	})
   157  }
   158  
   159  // SourceRange applies equality check predicate on the "sourceRange" field. It's identical to SourceRangeEQ.
   160  func SourceRange(v string) predicate.Alert {
   161  	return predicate.Alert(func(s *sql.Selector) {
   162  		s.Where(sql.EQ(s.C(FieldSourceRange), v))
   163  	})
   164  }
   165  
   166  // SourceAsNumber applies equality check predicate on the "sourceAsNumber" field. It's identical to SourceAsNumberEQ.
   167  func SourceAsNumber(v string) predicate.Alert {
   168  	return predicate.Alert(func(s *sql.Selector) {
   169  		s.Where(sql.EQ(s.C(FieldSourceAsNumber), v))
   170  	})
   171  }
   172  
   173  // SourceAsName applies equality check predicate on the "sourceAsName" field. It's identical to SourceAsNameEQ.
   174  func SourceAsName(v string) predicate.Alert {
   175  	return predicate.Alert(func(s *sql.Selector) {
   176  		s.Where(sql.EQ(s.C(FieldSourceAsName), v))
   177  	})
   178  }
   179  
   180  // SourceCountry applies equality check predicate on the "sourceCountry" field. It's identical to SourceCountryEQ.
   181  func SourceCountry(v string) predicate.Alert {
   182  	return predicate.Alert(func(s *sql.Selector) {
   183  		s.Where(sql.EQ(s.C(FieldSourceCountry), v))
   184  	})
   185  }
   186  
   187  // SourceLatitude applies equality check predicate on the "sourceLatitude" field. It's identical to SourceLatitudeEQ.
   188  func SourceLatitude(v float32) predicate.Alert {
   189  	return predicate.Alert(func(s *sql.Selector) {
   190  		s.Where(sql.EQ(s.C(FieldSourceLatitude), v))
   191  	})
   192  }
   193  
   194  // SourceLongitude applies equality check predicate on the "sourceLongitude" field. It's identical to SourceLongitudeEQ.
   195  func SourceLongitude(v float32) predicate.Alert {
   196  	return predicate.Alert(func(s *sql.Selector) {
   197  		s.Where(sql.EQ(s.C(FieldSourceLongitude), v))
   198  	})
   199  }
   200  
   201  // SourceScope applies equality check predicate on the "sourceScope" field. It's identical to SourceScopeEQ.
   202  func SourceScope(v string) predicate.Alert {
   203  	return predicate.Alert(func(s *sql.Selector) {
   204  		s.Where(sql.EQ(s.C(FieldSourceScope), v))
   205  	})
   206  }
   207  
   208  // SourceValue applies equality check predicate on the "sourceValue" field. It's identical to SourceValueEQ.
   209  func SourceValue(v string) predicate.Alert {
   210  	return predicate.Alert(func(s *sql.Selector) {
   211  		s.Where(sql.EQ(s.C(FieldSourceValue), v))
   212  	})
   213  }
   214  
   215  // Capacity applies equality check predicate on the "capacity" field. It's identical to CapacityEQ.
   216  func Capacity(v int32) predicate.Alert {
   217  	return predicate.Alert(func(s *sql.Selector) {
   218  		s.Where(sql.EQ(s.C(FieldCapacity), v))
   219  	})
   220  }
   221  
   222  // LeakSpeed applies equality check predicate on the "leakSpeed" field. It's identical to LeakSpeedEQ.
   223  func LeakSpeed(v string) predicate.Alert {
   224  	return predicate.Alert(func(s *sql.Selector) {
   225  		s.Where(sql.EQ(s.C(FieldLeakSpeed), v))
   226  	})
   227  }
   228  
   229  // ScenarioVersion applies equality check predicate on the "scenarioVersion" field. It's identical to ScenarioVersionEQ.
   230  func ScenarioVersion(v string) predicate.Alert {
   231  	return predicate.Alert(func(s *sql.Selector) {
   232  		s.Where(sql.EQ(s.C(FieldScenarioVersion), v))
   233  	})
   234  }
   235  
   236  // ScenarioHash applies equality check predicate on the "scenarioHash" field. It's identical to ScenarioHashEQ.
   237  func ScenarioHash(v string) predicate.Alert {
   238  	return predicate.Alert(func(s *sql.Selector) {
   239  		s.Where(sql.EQ(s.C(FieldScenarioHash), v))
   240  	})
   241  }
   242  
   243  // Simulated applies equality check predicate on the "simulated" field. It's identical to SimulatedEQ.
   244  func Simulated(v bool) predicate.Alert {
   245  	return predicate.Alert(func(s *sql.Selector) {
   246  		s.Where(sql.EQ(s.C(FieldSimulated), v))
   247  	})
   248  }
   249  
   250  // CreatedAtEQ applies the EQ predicate on the "created_at" field.
   251  func CreatedAtEQ(v time.Time) predicate.Alert {
   252  	return predicate.Alert(func(s *sql.Selector) {
   253  		s.Where(sql.EQ(s.C(FieldCreatedAt), v))
   254  	})
   255  }
   256  
   257  // CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
   258  func CreatedAtNEQ(v time.Time) predicate.Alert {
   259  	return predicate.Alert(func(s *sql.Selector) {
   260  		s.Where(sql.NEQ(s.C(FieldCreatedAt), v))
   261  	})
   262  }
   263  
   264  // CreatedAtIn applies the In predicate on the "created_at" field.
   265  func CreatedAtIn(vs ...time.Time) predicate.Alert {
   266  	v := make([]interface{}, len(vs))
   267  	for i := range v {
   268  		v[i] = vs[i]
   269  	}
   270  	return predicate.Alert(func(s *sql.Selector) {
   271  		// if not arguments were provided, append the FALSE constants,
   272  		// since we can't apply "IN ()". This will make this predicate falsy.
   273  		if len(v) == 0 {
   274  			s.Where(sql.False())
   275  			return
   276  		}
   277  		s.Where(sql.In(s.C(FieldCreatedAt), v...))
   278  	})
   279  }
   280  
   281  // CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
   282  func CreatedAtNotIn(vs ...time.Time) predicate.Alert {
   283  	v := make([]interface{}, len(vs))
   284  	for i := range v {
   285  		v[i] = vs[i]
   286  	}
   287  	return predicate.Alert(func(s *sql.Selector) {
   288  		// if not arguments were provided, append the FALSE constants,
   289  		// since we can't apply "IN ()". This will make this predicate falsy.
   290  		if len(v) == 0 {
   291  			s.Where(sql.False())
   292  			return
   293  		}
   294  		s.Where(sql.NotIn(s.C(FieldCreatedAt), v...))
   295  	})
   296  }
   297  
   298  // CreatedAtGT applies the GT predicate on the "created_at" field.
   299  func CreatedAtGT(v time.Time) predicate.Alert {
   300  	return predicate.Alert(func(s *sql.Selector) {
   301  		s.Where(sql.GT(s.C(FieldCreatedAt), v))
   302  	})
   303  }
   304  
   305  // CreatedAtGTE applies the GTE predicate on the "created_at" field.
   306  func CreatedAtGTE(v time.Time) predicate.Alert {
   307  	return predicate.Alert(func(s *sql.Selector) {
   308  		s.Where(sql.GTE(s.C(FieldCreatedAt), v))
   309  	})
   310  }
   311  
   312  // CreatedAtLT applies the LT predicate on the "created_at" field.
   313  func CreatedAtLT(v time.Time) predicate.Alert {
   314  	return predicate.Alert(func(s *sql.Selector) {
   315  		s.Where(sql.LT(s.C(FieldCreatedAt), v))
   316  	})
   317  }
   318  
   319  // CreatedAtLTE applies the LTE predicate on the "created_at" field.
   320  func CreatedAtLTE(v time.Time) predicate.Alert {
   321  	return predicate.Alert(func(s *sql.Selector) {
   322  		s.Where(sql.LTE(s.C(FieldCreatedAt), v))
   323  	})
   324  }
   325  
   326  // UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
   327  func UpdatedAtEQ(v time.Time) predicate.Alert {
   328  	return predicate.Alert(func(s *sql.Selector) {
   329  		s.Where(sql.EQ(s.C(FieldUpdatedAt), v))
   330  	})
   331  }
   332  
   333  // UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
   334  func UpdatedAtNEQ(v time.Time) predicate.Alert {
   335  	return predicate.Alert(func(s *sql.Selector) {
   336  		s.Where(sql.NEQ(s.C(FieldUpdatedAt), v))
   337  	})
   338  }
   339  
   340  // UpdatedAtIn applies the In predicate on the "updated_at" field.
   341  func UpdatedAtIn(vs ...time.Time) predicate.Alert {
   342  	v := make([]interface{}, len(vs))
   343  	for i := range v {
   344  		v[i] = vs[i]
   345  	}
   346  	return predicate.Alert(func(s *sql.Selector) {
   347  		// if not arguments were provided, append the FALSE constants,
   348  		// since we can't apply "IN ()". This will make this predicate falsy.
   349  		if len(v) == 0 {
   350  			s.Where(sql.False())
   351  			return
   352  		}
   353  		s.Where(sql.In(s.C(FieldUpdatedAt), v...))
   354  	})
   355  }
   356  
   357  // UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
   358  func UpdatedAtNotIn(vs ...time.Time) predicate.Alert {
   359  	v := make([]interface{}, len(vs))
   360  	for i := range v {
   361  		v[i] = vs[i]
   362  	}
   363  	return predicate.Alert(func(s *sql.Selector) {
   364  		// if not arguments were provided, append the FALSE constants,
   365  		// since we can't apply "IN ()". This will make this predicate falsy.
   366  		if len(v) == 0 {
   367  			s.Where(sql.False())
   368  			return
   369  		}
   370  		s.Where(sql.NotIn(s.C(FieldUpdatedAt), v...))
   371  	})
   372  }
   373  
   374  // UpdatedAtGT applies the GT predicate on the "updated_at" field.
   375  func UpdatedAtGT(v time.Time) predicate.Alert {
   376  	return predicate.Alert(func(s *sql.Selector) {
   377  		s.Where(sql.GT(s.C(FieldUpdatedAt), v))
   378  	})
   379  }
   380  
   381  // UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
   382  func UpdatedAtGTE(v time.Time) predicate.Alert {
   383  	return predicate.Alert(func(s *sql.Selector) {
   384  		s.Where(sql.GTE(s.C(FieldUpdatedAt), v))
   385  	})
   386  }
   387  
   388  // UpdatedAtLT applies the LT predicate on the "updated_at" field.
   389  func UpdatedAtLT(v time.Time) predicate.Alert {
   390  	return predicate.Alert(func(s *sql.Selector) {
   391  		s.Where(sql.LT(s.C(FieldUpdatedAt), v))
   392  	})
   393  }
   394  
   395  // UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
   396  func UpdatedAtLTE(v time.Time) predicate.Alert {
   397  	return predicate.Alert(func(s *sql.Selector) {
   398  		s.Where(sql.LTE(s.C(FieldUpdatedAt), v))
   399  	})
   400  }
   401  
   402  // ScenarioEQ applies the EQ predicate on the "scenario" field.
   403  func ScenarioEQ(v string) predicate.Alert {
   404  	return predicate.Alert(func(s *sql.Selector) {
   405  		s.Where(sql.EQ(s.C(FieldScenario), v))
   406  	})
   407  }
   408  
   409  // ScenarioNEQ applies the NEQ predicate on the "scenario" field.
   410  func ScenarioNEQ(v string) predicate.Alert {
   411  	return predicate.Alert(func(s *sql.Selector) {
   412  		s.Where(sql.NEQ(s.C(FieldScenario), v))
   413  	})
   414  }
   415  
   416  // ScenarioIn applies the In predicate on the "scenario" field.
   417  func ScenarioIn(vs ...string) predicate.Alert {
   418  	v := make([]interface{}, len(vs))
   419  	for i := range v {
   420  		v[i] = vs[i]
   421  	}
   422  	return predicate.Alert(func(s *sql.Selector) {
   423  		// if not arguments were provided, append the FALSE constants,
   424  		// since we can't apply "IN ()". This will make this predicate falsy.
   425  		if len(v) == 0 {
   426  			s.Where(sql.False())
   427  			return
   428  		}
   429  		s.Where(sql.In(s.C(FieldScenario), v...))
   430  	})
   431  }
   432  
   433  // ScenarioNotIn applies the NotIn predicate on the "scenario" field.
   434  func ScenarioNotIn(vs ...string) predicate.Alert {
   435  	v := make([]interface{}, len(vs))
   436  	for i := range v {
   437  		v[i] = vs[i]
   438  	}
   439  	return predicate.Alert(func(s *sql.Selector) {
   440  		// if not arguments were provided, append the FALSE constants,
   441  		// since we can't apply "IN ()". This will make this predicate falsy.
   442  		if len(v) == 0 {
   443  			s.Where(sql.False())
   444  			return
   445  		}
   446  		s.Where(sql.NotIn(s.C(FieldScenario), v...))
   447  	})
   448  }
   449  
   450  // ScenarioGT applies the GT predicate on the "scenario" field.
   451  func ScenarioGT(v string) predicate.Alert {
   452  	return predicate.Alert(func(s *sql.Selector) {
   453  		s.Where(sql.GT(s.C(FieldScenario), v))
   454  	})
   455  }
   456  
   457  // ScenarioGTE applies the GTE predicate on the "scenario" field.
   458  func ScenarioGTE(v string) predicate.Alert {
   459  	return predicate.Alert(func(s *sql.Selector) {
   460  		s.Where(sql.GTE(s.C(FieldScenario), v))
   461  	})
   462  }
   463  
   464  // ScenarioLT applies the LT predicate on the "scenario" field.
   465  func ScenarioLT(v string) predicate.Alert {
   466  	return predicate.Alert(func(s *sql.Selector) {
   467  		s.Where(sql.LT(s.C(FieldScenario), v))
   468  	})
   469  }
   470  
   471  // ScenarioLTE applies the LTE predicate on the "scenario" field.
   472  func ScenarioLTE(v string) predicate.Alert {
   473  	return predicate.Alert(func(s *sql.Selector) {
   474  		s.Where(sql.LTE(s.C(FieldScenario), v))
   475  	})
   476  }
   477  
   478  // ScenarioContains applies the Contains predicate on the "scenario" field.
   479  func ScenarioContains(v string) predicate.Alert {
   480  	return predicate.Alert(func(s *sql.Selector) {
   481  		s.Where(sql.Contains(s.C(FieldScenario), v))
   482  	})
   483  }
   484  
   485  // ScenarioHasPrefix applies the HasPrefix predicate on the "scenario" field.
   486  func ScenarioHasPrefix(v string) predicate.Alert {
   487  	return predicate.Alert(func(s *sql.Selector) {
   488  		s.Where(sql.HasPrefix(s.C(FieldScenario), v))
   489  	})
   490  }
   491  
   492  // ScenarioHasSuffix applies the HasSuffix predicate on the "scenario" field.
   493  func ScenarioHasSuffix(v string) predicate.Alert {
   494  	return predicate.Alert(func(s *sql.Selector) {
   495  		s.Where(sql.HasSuffix(s.C(FieldScenario), v))
   496  	})
   497  }
   498  
   499  // ScenarioEqualFold applies the EqualFold predicate on the "scenario" field.
   500  func ScenarioEqualFold(v string) predicate.Alert {
   501  	return predicate.Alert(func(s *sql.Selector) {
   502  		s.Where(sql.EqualFold(s.C(FieldScenario), v))
   503  	})
   504  }
   505  
   506  // ScenarioContainsFold applies the ContainsFold predicate on the "scenario" field.
   507  func ScenarioContainsFold(v string) predicate.Alert {
   508  	return predicate.Alert(func(s *sql.Selector) {
   509  		s.Where(sql.ContainsFold(s.C(FieldScenario), v))
   510  	})
   511  }
   512  
   513  // BucketIdEQ applies the EQ predicate on the "bucketId" field.
   514  func BucketIdEQ(v string) predicate.Alert {
   515  	return predicate.Alert(func(s *sql.Selector) {
   516  		s.Where(sql.EQ(s.C(FieldBucketId), v))
   517  	})
   518  }
   519  
   520  // BucketIdNEQ applies the NEQ predicate on the "bucketId" field.
   521  func BucketIdNEQ(v string) predicate.Alert {
   522  	return predicate.Alert(func(s *sql.Selector) {
   523  		s.Where(sql.NEQ(s.C(FieldBucketId), v))
   524  	})
   525  }
   526  
   527  // BucketIdIn applies the In predicate on the "bucketId" field.
   528  func BucketIdIn(vs ...string) predicate.Alert {
   529  	v := make([]interface{}, len(vs))
   530  	for i := range v {
   531  		v[i] = vs[i]
   532  	}
   533  	return predicate.Alert(func(s *sql.Selector) {
   534  		// if not arguments were provided, append the FALSE constants,
   535  		// since we can't apply "IN ()". This will make this predicate falsy.
   536  		if len(v) == 0 {
   537  			s.Where(sql.False())
   538  			return
   539  		}
   540  		s.Where(sql.In(s.C(FieldBucketId), v...))
   541  	})
   542  }
   543  
   544  // BucketIdNotIn applies the NotIn predicate on the "bucketId" field.
   545  func BucketIdNotIn(vs ...string) predicate.Alert {
   546  	v := make([]interface{}, len(vs))
   547  	for i := range v {
   548  		v[i] = vs[i]
   549  	}
   550  	return predicate.Alert(func(s *sql.Selector) {
   551  		// if not arguments were provided, append the FALSE constants,
   552  		// since we can't apply "IN ()". This will make this predicate falsy.
   553  		if len(v) == 0 {
   554  			s.Where(sql.False())
   555  			return
   556  		}
   557  		s.Where(sql.NotIn(s.C(FieldBucketId), v...))
   558  	})
   559  }
   560  
   561  // BucketIdGT applies the GT predicate on the "bucketId" field.
   562  func BucketIdGT(v string) predicate.Alert {
   563  	return predicate.Alert(func(s *sql.Selector) {
   564  		s.Where(sql.GT(s.C(FieldBucketId), v))
   565  	})
   566  }
   567  
   568  // BucketIdGTE applies the GTE predicate on the "bucketId" field.
   569  func BucketIdGTE(v string) predicate.Alert {
   570  	return predicate.Alert(func(s *sql.Selector) {
   571  		s.Where(sql.GTE(s.C(FieldBucketId), v))
   572  	})
   573  }
   574  
   575  // BucketIdLT applies the LT predicate on the "bucketId" field.
   576  func BucketIdLT(v string) predicate.Alert {
   577  	return predicate.Alert(func(s *sql.Selector) {
   578  		s.Where(sql.LT(s.C(FieldBucketId), v))
   579  	})
   580  }
   581  
   582  // BucketIdLTE applies the LTE predicate on the "bucketId" field.
   583  func BucketIdLTE(v string) predicate.Alert {
   584  	return predicate.Alert(func(s *sql.Selector) {
   585  		s.Where(sql.LTE(s.C(FieldBucketId), v))
   586  	})
   587  }
   588  
   589  // BucketIdContains applies the Contains predicate on the "bucketId" field.
   590  func BucketIdContains(v string) predicate.Alert {
   591  	return predicate.Alert(func(s *sql.Selector) {
   592  		s.Where(sql.Contains(s.C(FieldBucketId), v))
   593  	})
   594  }
   595  
   596  // BucketIdHasPrefix applies the HasPrefix predicate on the "bucketId" field.
   597  func BucketIdHasPrefix(v string) predicate.Alert {
   598  	return predicate.Alert(func(s *sql.Selector) {
   599  		s.Where(sql.HasPrefix(s.C(FieldBucketId), v))
   600  	})
   601  }
   602  
   603  // BucketIdHasSuffix applies the HasSuffix predicate on the "bucketId" field.
   604  func BucketIdHasSuffix(v string) predicate.Alert {
   605  	return predicate.Alert(func(s *sql.Selector) {
   606  		s.Where(sql.HasSuffix(s.C(FieldBucketId), v))
   607  	})
   608  }
   609  
   610  // BucketIdIsNil applies the IsNil predicate on the "bucketId" field.
   611  func BucketIdIsNil() predicate.Alert {
   612  	return predicate.Alert(func(s *sql.Selector) {
   613  		s.Where(sql.IsNull(s.C(FieldBucketId)))
   614  	})
   615  }
   616  
   617  // BucketIdNotNil applies the NotNil predicate on the "bucketId" field.
   618  func BucketIdNotNil() predicate.Alert {
   619  	return predicate.Alert(func(s *sql.Selector) {
   620  		s.Where(sql.NotNull(s.C(FieldBucketId)))
   621  	})
   622  }
   623  
   624  // BucketIdEqualFold applies the EqualFold predicate on the "bucketId" field.
   625  func BucketIdEqualFold(v string) predicate.Alert {
   626  	return predicate.Alert(func(s *sql.Selector) {
   627  		s.Where(sql.EqualFold(s.C(FieldBucketId), v))
   628  	})
   629  }
   630  
   631  // BucketIdContainsFold applies the ContainsFold predicate on the "bucketId" field.
   632  func BucketIdContainsFold(v string) predicate.Alert {
   633  	return predicate.Alert(func(s *sql.Selector) {
   634  		s.Where(sql.ContainsFold(s.C(FieldBucketId), v))
   635  	})
   636  }
   637  
   638  // MessageEQ applies the EQ predicate on the "message" field.
   639  func MessageEQ(v string) predicate.Alert {
   640  	return predicate.Alert(func(s *sql.Selector) {
   641  		s.Where(sql.EQ(s.C(FieldMessage), v))
   642  	})
   643  }
   644  
   645  // MessageNEQ applies the NEQ predicate on the "message" field.
   646  func MessageNEQ(v string) predicate.Alert {
   647  	return predicate.Alert(func(s *sql.Selector) {
   648  		s.Where(sql.NEQ(s.C(FieldMessage), v))
   649  	})
   650  }
   651  
   652  // MessageIn applies the In predicate on the "message" field.
   653  func MessageIn(vs ...string) predicate.Alert {
   654  	v := make([]interface{}, len(vs))
   655  	for i := range v {
   656  		v[i] = vs[i]
   657  	}
   658  	return predicate.Alert(func(s *sql.Selector) {
   659  		// if not arguments were provided, append the FALSE constants,
   660  		// since we can't apply "IN ()". This will make this predicate falsy.
   661  		if len(v) == 0 {
   662  			s.Where(sql.False())
   663  			return
   664  		}
   665  		s.Where(sql.In(s.C(FieldMessage), v...))
   666  	})
   667  }
   668  
   669  // MessageNotIn applies the NotIn predicate on the "message" field.
   670  func MessageNotIn(vs ...string) predicate.Alert {
   671  	v := make([]interface{}, len(vs))
   672  	for i := range v {
   673  		v[i] = vs[i]
   674  	}
   675  	return predicate.Alert(func(s *sql.Selector) {
   676  		// if not arguments were provided, append the FALSE constants,
   677  		// since we can't apply "IN ()". This will make this predicate falsy.
   678  		if len(v) == 0 {
   679  			s.Where(sql.False())
   680  			return
   681  		}
   682  		s.Where(sql.NotIn(s.C(FieldMessage), v...))
   683  	})
   684  }
   685  
   686  // MessageGT applies the GT predicate on the "message" field.
   687  func MessageGT(v string) predicate.Alert {
   688  	return predicate.Alert(func(s *sql.Selector) {
   689  		s.Where(sql.GT(s.C(FieldMessage), v))
   690  	})
   691  }
   692  
   693  // MessageGTE applies the GTE predicate on the "message" field.
   694  func MessageGTE(v string) predicate.Alert {
   695  	return predicate.Alert(func(s *sql.Selector) {
   696  		s.Where(sql.GTE(s.C(FieldMessage), v))
   697  	})
   698  }
   699  
   700  // MessageLT applies the LT predicate on the "message" field.
   701  func MessageLT(v string) predicate.Alert {
   702  	return predicate.Alert(func(s *sql.Selector) {
   703  		s.Where(sql.LT(s.C(FieldMessage), v))
   704  	})
   705  }
   706  
   707  // MessageLTE applies the LTE predicate on the "message" field.
   708  func MessageLTE(v string) predicate.Alert {
   709  	return predicate.Alert(func(s *sql.Selector) {
   710  		s.Where(sql.LTE(s.C(FieldMessage), v))
   711  	})
   712  }
   713  
   714  // MessageContains applies the Contains predicate on the "message" field.
   715  func MessageContains(v string) predicate.Alert {
   716  	return predicate.Alert(func(s *sql.Selector) {
   717  		s.Where(sql.Contains(s.C(FieldMessage), v))
   718  	})
   719  }
   720  
   721  // MessageHasPrefix applies the HasPrefix predicate on the "message" field.
   722  func MessageHasPrefix(v string) predicate.Alert {
   723  	return predicate.Alert(func(s *sql.Selector) {
   724  		s.Where(sql.HasPrefix(s.C(FieldMessage), v))
   725  	})
   726  }
   727  
   728  // MessageHasSuffix applies the HasSuffix predicate on the "message" field.
   729  func MessageHasSuffix(v string) predicate.Alert {
   730  	return predicate.Alert(func(s *sql.Selector) {
   731  		s.Where(sql.HasSuffix(s.C(FieldMessage), v))
   732  	})
   733  }
   734  
   735  // MessageIsNil applies the IsNil predicate on the "message" field.
   736  func MessageIsNil() predicate.Alert {
   737  	return predicate.Alert(func(s *sql.Selector) {
   738  		s.Where(sql.IsNull(s.C(FieldMessage)))
   739  	})
   740  }
   741  
   742  // MessageNotNil applies the NotNil predicate on the "message" field.
   743  func MessageNotNil() predicate.Alert {
   744  	return predicate.Alert(func(s *sql.Selector) {
   745  		s.Where(sql.NotNull(s.C(FieldMessage)))
   746  	})
   747  }
   748  
   749  // MessageEqualFold applies the EqualFold predicate on the "message" field.
   750  func MessageEqualFold(v string) predicate.Alert {
   751  	return predicate.Alert(func(s *sql.Selector) {
   752  		s.Where(sql.EqualFold(s.C(FieldMessage), v))
   753  	})
   754  }
   755  
   756  // MessageContainsFold applies the ContainsFold predicate on the "message" field.
   757  func MessageContainsFold(v string) predicate.Alert {
   758  	return predicate.Alert(func(s *sql.Selector) {
   759  		s.Where(sql.ContainsFold(s.C(FieldMessage), v))
   760  	})
   761  }
   762  
   763  // EventsCountEQ applies the EQ predicate on the "eventsCount" field.
   764  func EventsCountEQ(v int32) predicate.Alert {
   765  	return predicate.Alert(func(s *sql.Selector) {
   766  		s.Where(sql.EQ(s.C(FieldEventsCount), v))
   767  	})
   768  }
   769  
   770  // EventsCountNEQ applies the NEQ predicate on the "eventsCount" field.
   771  func EventsCountNEQ(v int32) predicate.Alert {
   772  	return predicate.Alert(func(s *sql.Selector) {
   773  		s.Where(sql.NEQ(s.C(FieldEventsCount), v))
   774  	})
   775  }
   776  
   777  // EventsCountIn applies the In predicate on the "eventsCount" field.
   778  func EventsCountIn(vs ...int32) predicate.Alert {
   779  	v := make([]interface{}, len(vs))
   780  	for i := range v {
   781  		v[i] = vs[i]
   782  	}
   783  	return predicate.Alert(func(s *sql.Selector) {
   784  		// if not arguments were provided, append the FALSE constants,
   785  		// since we can't apply "IN ()". This will make this predicate falsy.
   786  		if len(v) == 0 {
   787  			s.Where(sql.False())
   788  			return
   789  		}
   790  		s.Where(sql.In(s.C(FieldEventsCount), v...))
   791  	})
   792  }
   793  
   794  // EventsCountNotIn applies the NotIn predicate on the "eventsCount" field.
   795  func EventsCountNotIn(vs ...int32) predicate.Alert {
   796  	v := make([]interface{}, len(vs))
   797  	for i := range v {
   798  		v[i] = vs[i]
   799  	}
   800  	return predicate.Alert(func(s *sql.Selector) {
   801  		// if not arguments were provided, append the FALSE constants,
   802  		// since we can't apply "IN ()". This will make this predicate falsy.
   803  		if len(v) == 0 {
   804  			s.Where(sql.False())
   805  			return
   806  		}
   807  		s.Where(sql.NotIn(s.C(FieldEventsCount), v...))
   808  	})
   809  }
   810  
   811  // EventsCountGT applies the GT predicate on the "eventsCount" field.
   812  func EventsCountGT(v int32) predicate.Alert {
   813  	return predicate.Alert(func(s *sql.Selector) {
   814  		s.Where(sql.GT(s.C(FieldEventsCount), v))
   815  	})
   816  }
   817  
   818  // EventsCountGTE applies the GTE predicate on the "eventsCount" field.
   819  func EventsCountGTE(v int32) predicate.Alert {
   820  	return predicate.Alert(func(s *sql.Selector) {
   821  		s.Where(sql.GTE(s.C(FieldEventsCount), v))
   822  	})
   823  }
   824  
   825  // EventsCountLT applies the LT predicate on the "eventsCount" field.
   826  func EventsCountLT(v int32) predicate.Alert {
   827  	return predicate.Alert(func(s *sql.Selector) {
   828  		s.Where(sql.LT(s.C(FieldEventsCount), v))
   829  	})
   830  }
   831  
   832  // EventsCountLTE applies the LTE predicate on the "eventsCount" field.
   833  func EventsCountLTE(v int32) predicate.Alert {
   834  	return predicate.Alert(func(s *sql.Selector) {
   835  		s.Where(sql.LTE(s.C(FieldEventsCount), v))
   836  	})
   837  }
   838  
   839  // EventsCountIsNil applies the IsNil predicate on the "eventsCount" field.
   840  func EventsCountIsNil() predicate.Alert {
   841  	return predicate.Alert(func(s *sql.Selector) {
   842  		s.Where(sql.IsNull(s.C(FieldEventsCount)))
   843  	})
   844  }
   845  
   846  // EventsCountNotNil applies the NotNil predicate on the "eventsCount" field.
   847  func EventsCountNotNil() predicate.Alert {
   848  	return predicate.Alert(func(s *sql.Selector) {
   849  		s.Where(sql.NotNull(s.C(FieldEventsCount)))
   850  	})
   851  }
   852  
   853  // StartedAtEQ applies the EQ predicate on the "startedAt" field.
   854  func StartedAtEQ(v time.Time) predicate.Alert {
   855  	return predicate.Alert(func(s *sql.Selector) {
   856  		s.Where(sql.EQ(s.C(FieldStartedAt), v))
   857  	})
   858  }
   859  
   860  // StartedAtNEQ applies the NEQ predicate on the "startedAt" field.
   861  func StartedAtNEQ(v time.Time) predicate.Alert {
   862  	return predicate.Alert(func(s *sql.Selector) {
   863  		s.Where(sql.NEQ(s.C(FieldStartedAt), v))
   864  	})
   865  }
   866  
   867  // StartedAtIn applies the In predicate on the "startedAt" field.
   868  func StartedAtIn(vs ...time.Time) predicate.Alert {
   869  	v := make([]interface{}, len(vs))
   870  	for i := range v {
   871  		v[i] = vs[i]
   872  	}
   873  	return predicate.Alert(func(s *sql.Selector) {
   874  		// if not arguments were provided, append the FALSE constants,
   875  		// since we can't apply "IN ()". This will make this predicate falsy.
   876  		if len(v) == 0 {
   877  			s.Where(sql.False())
   878  			return
   879  		}
   880  		s.Where(sql.In(s.C(FieldStartedAt), v...))
   881  	})
   882  }
   883  
   884  // StartedAtNotIn applies the NotIn predicate on the "startedAt" field.
   885  func StartedAtNotIn(vs ...time.Time) predicate.Alert {
   886  	v := make([]interface{}, len(vs))
   887  	for i := range v {
   888  		v[i] = vs[i]
   889  	}
   890  	return predicate.Alert(func(s *sql.Selector) {
   891  		// if not arguments were provided, append the FALSE constants,
   892  		// since we can't apply "IN ()". This will make this predicate falsy.
   893  		if len(v) == 0 {
   894  			s.Where(sql.False())
   895  			return
   896  		}
   897  		s.Where(sql.NotIn(s.C(FieldStartedAt), v...))
   898  	})
   899  }
   900  
   901  // StartedAtGT applies the GT predicate on the "startedAt" field.
   902  func StartedAtGT(v time.Time) predicate.Alert {
   903  	return predicate.Alert(func(s *sql.Selector) {
   904  		s.Where(sql.GT(s.C(FieldStartedAt), v))
   905  	})
   906  }
   907  
   908  // StartedAtGTE applies the GTE predicate on the "startedAt" field.
   909  func StartedAtGTE(v time.Time) predicate.Alert {
   910  	return predicate.Alert(func(s *sql.Selector) {
   911  		s.Where(sql.GTE(s.C(FieldStartedAt), v))
   912  	})
   913  }
   914  
   915  // StartedAtLT applies the LT predicate on the "startedAt" field.
   916  func StartedAtLT(v time.Time) predicate.Alert {
   917  	return predicate.Alert(func(s *sql.Selector) {
   918  		s.Where(sql.LT(s.C(FieldStartedAt), v))
   919  	})
   920  }
   921  
   922  // StartedAtLTE applies the LTE predicate on the "startedAt" field.
   923  func StartedAtLTE(v time.Time) predicate.Alert {
   924  	return predicate.Alert(func(s *sql.Selector) {
   925  		s.Where(sql.LTE(s.C(FieldStartedAt), v))
   926  	})
   927  }
   928  
   929  // StartedAtIsNil applies the IsNil predicate on the "startedAt" field.
   930  func StartedAtIsNil() predicate.Alert {
   931  	return predicate.Alert(func(s *sql.Selector) {
   932  		s.Where(sql.IsNull(s.C(FieldStartedAt)))
   933  	})
   934  }
   935  
   936  // StartedAtNotNil applies the NotNil predicate on the "startedAt" field.
   937  func StartedAtNotNil() predicate.Alert {
   938  	return predicate.Alert(func(s *sql.Selector) {
   939  		s.Where(sql.NotNull(s.C(FieldStartedAt)))
   940  	})
   941  }
   942  
   943  // StoppedAtEQ applies the EQ predicate on the "stoppedAt" field.
   944  func StoppedAtEQ(v time.Time) predicate.Alert {
   945  	return predicate.Alert(func(s *sql.Selector) {
   946  		s.Where(sql.EQ(s.C(FieldStoppedAt), v))
   947  	})
   948  }
   949  
   950  // StoppedAtNEQ applies the NEQ predicate on the "stoppedAt" field.
   951  func StoppedAtNEQ(v time.Time) predicate.Alert {
   952  	return predicate.Alert(func(s *sql.Selector) {
   953  		s.Where(sql.NEQ(s.C(FieldStoppedAt), v))
   954  	})
   955  }
   956  
   957  // StoppedAtIn applies the In predicate on the "stoppedAt" field.
   958  func StoppedAtIn(vs ...time.Time) predicate.Alert {
   959  	v := make([]interface{}, len(vs))
   960  	for i := range v {
   961  		v[i] = vs[i]
   962  	}
   963  	return predicate.Alert(func(s *sql.Selector) {
   964  		// if not arguments were provided, append the FALSE constants,
   965  		// since we can't apply "IN ()". This will make this predicate falsy.
   966  		if len(v) == 0 {
   967  			s.Where(sql.False())
   968  			return
   969  		}
   970  		s.Where(sql.In(s.C(FieldStoppedAt), v...))
   971  	})
   972  }
   973  
   974  // StoppedAtNotIn applies the NotIn predicate on the "stoppedAt" field.
   975  func StoppedAtNotIn(vs ...time.Time) predicate.Alert {
   976  	v := make([]interface{}, len(vs))
   977  	for i := range v {
   978  		v[i] = vs[i]
   979  	}
   980  	return predicate.Alert(func(s *sql.Selector) {
   981  		// if not arguments were provided, append the FALSE constants,
   982  		// since we can't apply "IN ()". This will make this predicate falsy.
   983  		if len(v) == 0 {
   984  			s.Where(sql.False())
   985  			return
   986  		}
   987  		s.Where(sql.NotIn(s.C(FieldStoppedAt), v...))
   988  	})
   989  }
   990  
   991  // StoppedAtGT applies the GT predicate on the "stoppedAt" field.
   992  func StoppedAtGT(v time.Time) predicate.Alert {
   993  	return predicate.Alert(func(s *sql.Selector) {
   994  		s.Where(sql.GT(s.C(FieldStoppedAt), v))
   995  	})
   996  }
   997  
   998  // StoppedAtGTE applies the GTE predicate on the "stoppedAt" field.
   999  func StoppedAtGTE(v time.Time) predicate.Alert {
  1000  	return predicate.Alert(func(s *sql.Selector) {
  1001  		s.Where(sql.GTE(s.C(FieldStoppedAt), v))
  1002  	})
  1003  }
  1004  
  1005  // StoppedAtLT applies the LT predicate on the "stoppedAt" field.
  1006  func StoppedAtLT(v time.Time) predicate.Alert {
  1007  	return predicate.Alert(func(s *sql.Selector) {
  1008  		s.Where(sql.LT(s.C(FieldStoppedAt), v))
  1009  	})
  1010  }
  1011  
  1012  // StoppedAtLTE applies the LTE predicate on the "stoppedAt" field.
  1013  func StoppedAtLTE(v time.Time) predicate.Alert {
  1014  	return predicate.Alert(func(s *sql.Selector) {
  1015  		s.Where(sql.LTE(s.C(FieldStoppedAt), v))
  1016  	})
  1017  }
  1018  
  1019  // StoppedAtIsNil applies the IsNil predicate on the "stoppedAt" field.
  1020  func StoppedAtIsNil() predicate.Alert {
  1021  	return predicate.Alert(func(s *sql.Selector) {
  1022  		s.Where(sql.IsNull(s.C(FieldStoppedAt)))
  1023  	})
  1024  }
  1025  
  1026  // StoppedAtNotNil applies the NotNil predicate on the "stoppedAt" field.
  1027  func StoppedAtNotNil() predicate.Alert {
  1028  	return predicate.Alert(func(s *sql.Selector) {
  1029  		s.Where(sql.NotNull(s.C(FieldStoppedAt)))
  1030  	})
  1031  }
  1032  
  1033  // SourceIpEQ applies the EQ predicate on the "sourceIp" field.
  1034  func SourceIpEQ(v string) predicate.Alert {
  1035  	return predicate.Alert(func(s *sql.Selector) {
  1036  		s.Where(sql.EQ(s.C(FieldSourceIp), v))
  1037  	})
  1038  }
  1039  
  1040  // SourceIpNEQ applies the NEQ predicate on the "sourceIp" field.
  1041  func SourceIpNEQ(v string) predicate.Alert {
  1042  	return predicate.Alert(func(s *sql.Selector) {
  1043  		s.Where(sql.NEQ(s.C(FieldSourceIp), v))
  1044  	})
  1045  }
  1046  
  1047  // SourceIpIn applies the In predicate on the "sourceIp" field.
  1048  func SourceIpIn(vs ...string) predicate.Alert {
  1049  	v := make([]interface{}, len(vs))
  1050  	for i := range v {
  1051  		v[i] = vs[i]
  1052  	}
  1053  	return predicate.Alert(func(s *sql.Selector) {
  1054  		// if not arguments were provided, append the FALSE constants,
  1055  		// since we can't apply "IN ()". This will make this predicate falsy.
  1056  		if len(v) == 0 {
  1057  			s.Where(sql.False())
  1058  			return
  1059  		}
  1060  		s.Where(sql.In(s.C(FieldSourceIp), v...))
  1061  	})
  1062  }
  1063  
  1064  // SourceIpNotIn applies the NotIn predicate on the "sourceIp" field.
  1065  func SourceIpNotIn(vs ...string) predicate.Alert {
  1066  	v := make([]interface{}, len(vs))
  1067  	for i := range v {
  1068  		v[i] = vs[i]
  1069  	}
  1070  	return predicate.Alert(func(s *sql.Selector) {
  1071  		// if not arguments were provided, append the FALSE constants,
  1072  		// since we can't apply "IN ()". This will make this predicate falsy.
  1073  		if len(v) == 0 {
  1074  			s.Where(sql.False())
  1075  			return
  1076  		}
  1077  		s.Where(sql.NotIn(s.C(FieldSourceIp), v...))
  1078  	})
  1079  }
  1080  
  1081  // SourceIpGT applies the GT predicate on the "sourceIp" field.
  1082  func SourceIpGT(v string) predicate.Alert {
  1083  	return predicate.Alert(func(s *sql.Selector) {
  1084  		s.Where(sql.GT(s.C(FieldSourceIp), v))
  1085  	})
  1086  }
  1087  
  1088  // SourceIpGTE applies the GTE predicate on the "sourceIp" field.
  1089  func SourceIpGTE(v string) predicate.Alert {
  1090  	return predicate.Alert(func(s *sql.Selector) {
  1091  		s.Where(sql.GTE(s.C(FieldSourceIp), v))
  1092  	})
  1093  }
  1094  
  1095  // SourceIpLT applies the LT predicate on the "sourceIp" field.
  1096  func SourceIpLT(v string) predicate.Alert {
  1097  	return predicate.Alert(func(s *sql.Selector) {
  1098  		s.Where(sql.LT(s.C(FieldSourceIp), v))
  1099  	})
  1100  }
  1101  
  1102  // SourceIpLTE applies the LTE predicate on the "sourceIp" field.
  1103  func SourceIpLTE(v string) predicate.Alert {
  1104  	return predicate.Alert(func(s *sql.Selector) {
  1105  		s.Where(sql.LTE(s.C(FieldSourceIp), v))
  1106  	})
  1107  }
  1108  
  1109  // SourceIpContains applies the Contains predicate on the "sourceIp" field.
  1110  func SourceIpContains(v string) predicate.Alert {
  1111  	return predicate.Alert(func(s *sql.Selector) {
  1112  		s.Where(sql.Contains(s.C(FieldSourceIp), v))
  1113  	})
  1114  }
  1115  
  1116  // SourceIpHasPrefix applies the HasPrefix predicate on the "sourceIp" field.
  1117  func SourceIpHasPrefix(v string) predicate.Alert {
  1118  	return predicate.Alert(func(s *sql.Selector) {
  1119  		s.Where(sql.HasPrefix(s.C(FieldSourceIp), v))
  1120  	})
  1121  }
  1122  
  1123  // SourceIpHasSuffix applies the HasSuffix predicate on the "sourceIp" field.
  1124  func SourceIpHasSuffix(v string) predicate.Alert {
  1125  	return predicate.Alert(func(s *sql.Selector) {
  1126  		s.Where(sql.HasSuffix(s.C(FieldSourceIp), v))
  1127  	})
  1128  }
  1129  
  1130  // SourceIpIsNil applies the IsNil predicate on the "sourceIp" field.
  1131  func SourceIpIsNil() predicate.Alert {
  1132  	return predicate.Alert(func(s *sql.Selector) {
  1133  		s.Where(sql.IsNull(s.C(FieldSourceIp)))
  1134  	})
  1135  }
  1136  
  1137  // SourceIpNotNil applies the NotNil predicate on the "sourceIp" field.
  1138  func SourceIpNotNil() predicate.Alert {
  1139  	return predicate.Alert(func(s *sql.Selector) {
  1140  		s.Where(sql.NotNull(s.C(FieldSourceIp)))
  1141  	})
  1142  }
  1143  
  1144  // SourceIpEqualFold applies the EqualFold predicate on the "sourceIp" field.
  1145  func SourceIpEqualFold(v string) predicate.Alert {
  1146  	return predicate.Alert(func(s *sql.Selector) {
  1147  		s.Where(sql.EqualFold(s.C(FieldSourceIp), v))
  1148  	})
  1149  }
  1150  
  1151  // SourceIpContainsFold applies the ContainsFold predicate on the "sourceIp" field.
  1152  func SourceIpContainsFold(v string) predicate.Alert {
  1153  	return predicate.Alert(func(s *sql.Selector) {
  1154  		s.Where(sql.ContainsFold(s.C(FieldSourceIp), v))
  1155  	})
  1156  }
  1157  
  1158  // SourceRangeEQ applies the EQ predicate on the "sourceRange" field.
  1159  func SourceRangeEQ(v string) predicate.Alert {
  1160  	return predicate.Alert(func(s *sql.Selector) {
  1161  		s.Where(sql.EQ(s.C(FieldSourceRange), v))
  1162  	})
  1163  }
  1164  
  1165  // SourceRangeNEQ applies the NEQ predicate on the "sourceRange" field.
  1166  func SourceRangeNEQ(v string) predicate.Alert {
  1167  	return predicate.Alert(func(s *sql.Selector) {
  1168  		s.Where(sql.NEQ(s.C(FieldSourceRange), v))
  1169  	})
  1170  }
  1171  
  1172  // SourceRangeIn applies the In predicate on the "sourceRange" field.
  1173  func SourceRangeIn(vs ...string) predicate.Alert {
  1174  	v := make([]interface{}, len(vs))
  1175  	for i := range v {
  1176  		v[i] = vs[i]
  1177  	}
  1178  	return predicate.Alert(func(s *sql.Selector) {
  1179  		// if not arguments were provided, append the FALSE constants,
  1180  		// since we can't apply "IN ()". This will make this predicate falsy.
  1181  		if len(v) == 0 {
  1182  			s.Where(sql.False())
  1183  			return
  1184  		}
  1185  		s.Where(sql.In(s.C(FieldSourceRange), v...))
  1186  	})
  1187  }
  1188  
  1189  // SourceRangeNotIn applies the NotIn predicate on the "sourceRange" field.
  1190  func SourceRangeNotIn(vs ...string) predicate.Alert {
  1191  	v := make([]interface{}, len(vs))
  1192  	for i := range v {
  1193  		v[i] = vs[i]
  1194  	}
  1195  	return predicate.Alert(func(s *sql.Selector) {
  1196  		// if not arguments were provided, append the FALSE constants,
  1197  		// since we can't apply "IN ()". This will make this predicate falsy.
  1198  		if len(v) == 0 {
  1199  			s.Where(sql.False())
  1200  			return
  1201  		}
  1202  		s.Where(sql.NotIn(s.C(FieldSourceRange), v...))
  1203  	})
  1204  }
  1205  
  1206  // SourceRangeGT applies the GT predicate on the "sourceRange" field.
  1207  func SourceRangeGT(v string) predicate.Alert {
  1208  	return predicate.Alert(func(s *sql.Selector) {
  1209  		s.Where(sql.GT(s.C(FieldSourceRange), v))
  1210  	})
  1211  }
  1212  
  1213  // SourceRangeGTE applies the GTE predicate on the "sourceRange" field.
  1214  func SourceRangeGTE(v string) predicate.Alert {
  1215  	return predicate.Alert(func(s *sql.Selector) {
  1216  		s.Where(sql.GTE(s.C(FieldSourceRange), v))
  1217  	})
  1218  }
  1219  
  1220  // SourceRangeLT applies the LT predicate on the "sourceRange" field.
  1221  func SourceRangeLT(v string) predicate.Alert {
  1222  	return predicate.Alert(func(s *sql.Selector) {
  1223  		s.Where(sql.LT(s.C(FieldSourceRange), v))
  1224  	})
  1225  }
  1226  
  1227  // SourceRangeLTE applies the LTE predicate on the "sourceRange" field.
  1228  func SourceRangeLTE(v string) predicate.Alert {
  1229  	return predicate.Alert(func(s *sql.Selector) {
  1230  		s.Where(sql.LTE(s.C(FieldSourceRange), v))
  1231  	})
  1232  }
  1233  
  1234  // SourceRangeContains applies the Contains predicate on the "sourceRange" field.
  1235  func SourceRangeContains(v string) predicate.Alert {
  1236  	return predicate.Alert(func(s *sql.Selector) {
  1237  		s.Where(sql.Contains(s.C(FieldSourceRange), v))
  1238  	})
  1239  }
  1240  
  1241  // SourceRangeHasPrefix applies the HasPrefix predicate on the "sourceRange" field.
  1242  func SourceRangeHasPrefix(v string) predicate.Alert {
  1243  	return predicate.Alert(func(s *sql.Selector) {
  1244  		s.Where(sql.HasPrefix(s.C(FieldSourceRange), v))
  1245  	})
  1246  }
  1247  
  1248  // SourceRangeHasSuffix applies the HasSuffix predicate on the "sourceRange" field.
  1249  func SourceRangeHasSuffix(v string) predicate.Alert {
  1250  	return predicate.Alert(func(s *sql.Selector) {
  1251  		s.Where(sql.HasSuffix(s.C(FieldSourceRange), v))
  1252  	})
  1253  }
  1254  
  1255  // SourceRangeIsNil applies the IsNil predicate on the "sourceRange" field.
  1256  func SourceRangeIsNil() predicate.Alert {
  1257  	return predicate.Alert(func(s *sql.Selector) {
  1258  		s.Where(sql.IsNull(s.C(FieldSourceRange)))
  1259  	})
  1260  }
  1261  
  1262  // SourceRangeNotNil applies the NotNil predicate on the "sourceRange" field.
  1263  func SourceRangeNotNil() predicate.Alert {
  1264  	return predicate.Alert(func(s *sql.Selector) {
  1265  		s.Where(sql.NotNull(s.C(FieldSourceRange)))
  1266  	})
  1267  }
  1268  
  1269  // SourceRangeEqualFold applies the EqualFold predicate on the "sourceRange" field.
  1270  func SourceRangeEqualFold(v string) predicate.Alert {
  1271  	return predicate.Alert(func(s *sql.Selector) {
  1272  		s.Where(sql.EqualFold(s.C(FieldSourceRange), v))
  1273  	})
  1274  }
  1275  
  1276  // SourceRangeContainsFold applies the ContainsFold predicate on the "sourceRange" field.
  1277  func SourceRangeContainsFold(v string) predicate.Alert {
  1278  	return predicate.Alert(func(s *sql.Selector) {
  1279  		s.Where(sql.ContainsFold(s.C(FieldSourceRange), v))
  1280  	})
  1281  }
  1282  
  1283  // SourceAsNumberEQ applies the EQ predicate on the "sourceAsNumber" field.
  1284  func SourceAsNumberEQ(v string) predicate.Alert {
  1285  	return predicate.Alert(func(s *sql.Selector) {
  1286  		s.Where(sql.EQ(s.C(FieldSourceAsNumber), v))
  1287  	})
  1288  }
  1289  
  1290  // SourceAsNumberNEQ applies the NEQ predicate on the "sourceAsNumber" field.
  1291  func SourceAsNumberNEQ(v string) predicate.Alert {
  1292  	return predicate.Alert(func(s *sql.Selector) {
  1293  		s.Where(sql.NEQ(s.C(FieldSourceAsNumber), v))
  1294  	})
  1295  }
  1296  
  1297  // SourceAsNumberIn applies the In predicate on the "sourceAsNumber" field.
  1298  func SourceAsNumberIn(vs ...string) predicate.Alert {
  1299  	v := make([]interface{}, len(vs))
  1300  	for i := range v {
  1301  		v[i] = vs[i]
  1302  	}
  1303  	return predicate.Alert(func(s *sql.Selector) {
  1304  		// if not arguments were provided, append the FALSE constants,
  1305  		// since we can't apply "IN ()". This will make this predicate falsy.
  1306  		if len(v) == 0 {
  1307  			s.Where(sql.False())
  1308  			return
  1309  		}
  1310  		s.Where(sql.In(s.C(FieldSourceAsNumber), v...))
  1311  	})
  1312  }
  1313  
  1314  // SourceAsNumberNotIn applies the NotIn predicate on the "sourceAsNumber" field.
  1315  func SourceAsNumberNotIn(vs ...string) predicate.Alert {
  1316  	v := make([]interface{}, len(vs))
  1317  	for i := range v {
  1318  		v[i] = vs[i]
  1319  	}
  1320  	return predicate.Alert(func(s *sql.Selector) {
  1321  		// if not arguments were provided, append the FALSE constants,
  1322  		// since we can't apply "IN ()". This will make this predicate falsy.
  1323  		if len(v) == 0 {
  1324  			s.Where(sql.False())
  1325  			return
  1326  		}
  1327  		s.Where(sql.NotIn(s.C(FieldSourceAsNumber), v...))
  1328  	})
  1329  }
  1330  
  1331  // SourceAsNumberGT applies the GT predicate on the "sourceAsNumber" field.
  1332  func SourceAsNumberGT(v string) predicate.Alert {
  1333  	return predicate.Alert(func(s *sql.Selector) {
  1334  		s.Where(sql.GT(s.C(FieldSourceAsNumber), v))
  1335  	})
  1336  }
  1337  
  1338  // SourceAsNumberGTE applies the GTE predicate on the "sourceAsNumber" field.
  1339  func SourceAsNumberGTE(v string) predicate.Alert {
  1340  	return predicate.Alert(func(s *sql.Selector) {
  1341  		s.Where(sql.GTE(s.C(FieldSourceAsNumber), v))
  1342  	})
  1343  }
  1344  
  1345  // SourceAsNumberLT applies the LT predicate on the "sourceAsNumber" field.
  1346  func SourceAsNumberLT(v string) predicate.Alert {
  1347  	return predicate.Alert(func(s *sql.Selector) {
  1348  		s.Where(sql.LT(s.C(FieldSourceAsNumber), v))
  1349  	})
  1350  }
  1351  
  1352  // SourceAsNumberLTE applies the LTE predicate on the "sourceAsNumber" field.
  1353  func SourceAsNumberLTE(v string) predicate.Alert {
  1354  	return predicate.Alert(func(s *sql.Selector) {
  1355  		s.Where(sql.LTE(s.C(FieldSourceAsNumber), v))
  1356  	})
  1357  }
  1358  
  1359  // SourceAsNumberContains applies the Contains predicate on the "sourceAsNumber" field.
  1360  func SourceAsNumberContains(v string) predicate.Alert {
  1361  	return predicate.Alert(func(s *sql.Selector) {
  1362  		s.Where(sql.Contains(s.C(FieldSourceAsNumber), v))
  1363  	})
  1364  }
  1365  
  1366  // SourceAsNumberHasPrefix applies the HasPrefix predicate on the "sourceAsNumber" field.
  1367  func SourceAsNumberHasPrefix(v string) predicate.Alert {
  1368  	return predicate.Alert(func(s *sql.Selector) {
  1369  		s.Where(sql.HasPrefix(s.C(FieldSourceAsNumber), v))
  1370  	})
  1371  }
  1372  
  1373  // SourceAsNumberHasSuffix applies the HasSuffix predicate on the "sourceAsNumber" field.
  1374  func SourceAsNumberHasSuffix(v string) predicate.Alert {
  1375  	return predicate.Alert(func(s *sql.Selector) {
  1376  		s.Where(sql.HasSuffix(s.C(FieldSourceAsNumber), v))
  1377  	})
  1378  }
  1379  
  1380  // SourceAsNumberIsNil applies the IsNil predicate on the "sourceAsNumber" field.
  1381  func SourceAsNumberIsNil() predicate.Alert {
  1382  	return predicate.Alert(func(s *sql.Selector) {
  1383  		s.Where(sql.IsNull(s.C(FieldSourceAsNumber)))
  1384  	})
  1385  }
  1386  
  1387  // SourceAsNumberNotNil applies the NotNil predicate on the "sourceAsNumber" field.
  1388  func SourceAsNumberNotNil() predicate.Alert {
  1389  	return predicate.Alert(func(s *sql.Selector) {
  1390  		s.Where(sql.NotNull(s.C(FieldSourceAsNumber)))
  1391  	})
  1392  }
  1393  
  1394  // SourceAsNumberEqualFold applies the EqualFold predicate on the "sourceAsNumber" field.
  1395  func SourceAsNumberEqualFold(v string) predicate.Alert {
  1396  	return predicate.Alert(func(s *sql.Selector) {
  1397  		s.Where(sql.EqualFold(s.C(FieldSourceAsNumber), v))
  1398  	})
  1399  }
  1400  
  1401  // SourceAsNumberContainsFold applies the ContainsFold predicate on the "sourceAsNumber" field.
  1402  func SourceAsNumberContainsFold(v string) predicate.Alert {
  1403  	return predicate.Alert(func(s *sql.Selector) {
  1404  		s.Where(sql.ContainsFold(s.C(FieldSourceAsNumber), v))
  1405  	})
  1406  }
  1407  
  1408  // SourceAsNameEQ applies the EQ predicate on the "sourceAsName" field.
  1409  func SourceAsNameEQ(v string) predicate.Alert {
  1410  	return predicate.Alert(func(s *sql.Selector) {
  1411  		s.Where(sql.EQ(s.C(FieldSourceAsName), v))
  1412  	})
  1413  }
  1414  
  1415  // SourceAsNameNEQ applies the NEQ predicate on the "sourceAsName" field.
  1416  func SourceAsNameNEQ(v string) predicate.Alert {
  1417  	return predicate.Alert(func(s *sql.Selector) {
  1418  		s.Where(sql.NEQ(s.C(FieldSourceAsName), v))
  1419  	})
  1420  }
  1421  
  1422  // SourceAsNameIn applies the In predicate on the "sourceAsName" field.
  1423  func SourceAsNameIn(vs ...string) predicate.Alert {
  1424  	v := make([]interface{}, len(vs))
  1425  	for i := range v {
  1426  		v[i] = vs[i]
  1427  	}
  1428  	return predicate.Alert(func(s *sql.Selector) {
  1429  		// if not arguments were provided, append the FALSE constants,
  1430  		// since we can't apply "IN ()". This will make this predicate falsy.
  1431  		if len(v) == 0 {
  1432  			s.Where(sql.False())
  1433  			return
  1434  		}
  1435  		s.Where(sql.In(s.C(FieldSourceAsName), v...))
  1436  	})
  1437  }
  1438  
  1439  // SourceAsNameNotIn applies the NotIn predicate on the "sourceAsName" field.
  1440  func SourceAsNameNotIn(vs ...string) predicate.Alert {
  1441  	v := make([]interface{}, len(vs))
  1442  	for i := range v {
  1443  		v[i] = vs[i]
  1444  	}
  1445  	return predicate.Alert(func(s *sql.Selector) {
  1446  		// if not arguments were provided, append the FALSE constants,
  1447  		// since we can't apply "IN ()". This will make this predicate falsy.
  1448  		if len(v) == 0 {
  1449  			s.Where(sql.False())
  1450  			return
  1451  		}
  1452  		s.Where(sql.NotIn(s.C(FieldSourceAsName), v...))
  1453  	})
  1454  }
  1455  
  1456  // SourceAsNameGT applies the GT predicate on the "sourceAsName" field.
  1457  func SourceAsNameGT(v string) predicate.Alert {
  1458  	return predicate.Alert(func(s *sql.Selector) {
  1459  		s.Where(sql.GT(s.C(FieldSourceAsName), v))
  1460  	})
  1461  }
  1462  
  1463  // SourceAsNameGTE applies the GTE predicate on the "sourceAsName" field.
  1464  func SourceAsNameGTE(v string) predicate.Alert {
  1465  	return predicate.Alert(func(s *sql.Selector) {
  1466  		s.Where(sql.GTE(s.C(FieldSourceAsName), v))
  1467  	})
  1468  }
  1469  
  1470  // SourceAsNameLT applies the LT predicate on the "sourceAsName" field.
  1471  func SourceAsNameLT(v string) predicate.Alert {
  1472  	return predicate.Alert(func(s *sql.Selector) {
  1473  		s.Where(sql.LT(s.C(FieldSourceAsName), v))
  1474  	})
  1475  }
  1476  
  1477  // SourceAsNameLTE applies the LTE predicate on the "sourceAsName" field.
  1478  func SourceAsNameLTE(v string) predicate.Alert {
  1479  	return predicate.Alert(func(s *sql.Selector) {
  1480  		s.Where(sql.LTE(s.C(FieldSourceAsName), v))
  1481  	})
  1482  }
  1483  
  1484  // SourceAsNameContains applies the Contains predicate on the "sourceAsName" field.
  1485  func SourceAsNameContains(v string) predicate.Alert {
  1486  	return predicate.Alert(func(s *sql.Selector) {
  1487  		s.Where(sql.Contains(s.C(FieldSourceAsName), v))
  1488  	})
  1489  }
  1490  
  1491  // SourceAsNameHasPrefix applies the HasPrefix predicate on the "sourceAsName" field.
  1492  func SourceAsNameHasPrefix(v string) predicate.Alert {
  1493  	return predicate.Alert(func(s *sql.Selector) {
  1494  		s.Where(sql.HasPrefix(s.C(FieldSourceAsName), v))
  1495  	})
  1496  }
  1497  
  1498  // SourceAsNameHasSuffix applies the HasSuffix predicate on the "sourceAsName" field.
  1499  func SourceAsNameHasSuffix(v string) predicate.Alert {
  1500  	return predicate.Alert(func(s *sql.Selector) {
  1501  		s.Where(sql.HasSuffix(s.C(FieldSourceAsName), v))
  1502  	})
  1503  }
  1504  
  1505  // SourceAsNameIsNil applies the IsNil predicate on the "sourceAsName" field.
  1506  func SourceAsNameIsNil() predicate.Alert {
  1507  	return predicate.Alert(func(s *sql.Selector) {
  1508  		s.Where(sql.IsNull(s.C(FieldSourceAsName)))
  1509  	})
  1510  }
  1511  
  1512  // SourceAsNameNotNil applies the NotNil predicate on the "sourceAsName" field.
  1513  func SourceAsNameNotNil() predicate.Alert {
  1514  	return predicate.Alert(func(s *sql.Selector) {
  1515  		s.Where(sql.NotNull(s.C(FieldSourceAsName)))
  1516  	})
  1517  }
  1518  
  1519  // SourceAsNameEqualFold applies the EqualFold predicate on the "sourceAsName" field.
  1520  func SourceAsNameEqualFold(v string) predicate.Alert {
  1521  	return predicate.Alert(func(s *sql.Selector) {
  1522  		s.Where(sql.EqualFold(s.C(FieldSourceAsName), v))
  1523  	})
  1524  }
  1525  
  1526  // SourceAsNameContainsFold applies the ContainsFold predicate on the "sourceAsName" field.
  1527  func SourceAsNameContainsFold(v string) predicate.Alert {
  1528  	return predicate.Alert(func(s *sql.Selector) {
  1529  		s.Where(sql.ContainsFold(s.C(FieldSourceAsName), v))
  1530  	})
  1531  }
  1532  
  1533  // SourceCountryEQ applies the EQ predicate on the "sourceCountry" field.
  1534  func SourceCountryEQ(v string) predicate.Alert {
  1535  	return predicate.Alert(func(s *sql.Selector) {
  1536  		s.Where(sql.EQ(s.C(FieldSourceCountry), v))
  1537  	})
  1538  }
  1539  
  1540  // SourceCountryNEQ applies the NEQ predicate on the "sourceCountry" field.
  1541  func SourceCountryNEQ(v string) predicate.Alert {
  1542  	return predicate.Alert(func(s *sql.Selector) {
  1543  		s.Where(sql.NEQ(s.C(FieldSourceCountry), v))
  1544  	})
  1545  }
  1546  
  1547  // SourceCountryIn applies the In predicate on the "sourceCountry" field.
  1548  func SourceCountryIn(vs ...string) predicate.Alert {
  1549  	v := make([]interface{}, len(vs))
  1550  	for i := range v {
  1551  		v[i] = vs[i]
  1552  	}
  1553  	return predicate.Alert(func(s *sql.Selector) {
  1554  		// if not arguments were provided, append the FALSE constants,
  1555  		// since we can't apply "IN ()". This will make this predicate falsy.
  1556  		if len(v) == 0 {
  1557  			s.Where(sql.False())
  1558  			return
  1559  		}
  1560  		s.Where(sql.In(s.C(FieldSourceCountry), v...))
  1561  	})
  1562  }
  1563  
  1564  // SourceCountryNotIn applies the NotIn predicate on the "sourceCountry" field.
  1565  func SourceCountryNotIn(vs ...string) predicate.Alert {
  1566  	v := make([]interface{}, len(vs))
  1567  	for i := range v {
  1568  		v[i] = vs[i]
  1569  	}
  1570  	return predicate.Alert(func(s *sql.Selector) {
  1571  		// if not arguments were provided, append the FALSE constants,
  1572  		// since we can't apply "IN ()". This will make this predicate falsy.
  1573  		if len(v) == 0 {
  1574  			s.Where(sql.False())
  1575  			return
  1576  		}
  1577  		s.Where(sql.NotIn(s.C(FieldSourceCountry), v...))
  1578  	})
  1579  }
  1580  
  1581  // SourceCountryGT applies the GT predicate on the "sourceCountry" field.
  1582  func SourceCountryGT(v string) predicate.Alert {
  1583  	return predicate.Alert(func(s *sql.Selector) {
  1584  		s.Where(sql.GT(s.C(FieldSourceCountry), v))
  1585  	})
  1586  }
  1587  
  1588  // SourceCountryGTE applies the GTE predicate on the "sourceCountry" field.
  1589  func SourceCountryGTE(v string) predicate.Alert {
  1590  	return predicate.Alert(func(s *sql.Selector) {
  1591  		s.Where(sql.GTE(s.C(FieldSourceCountry), v))
  1592  	})
  1593  }
  1594  
  1595  // SourceCountryLT applies the LT predicate on the "sourceCountry" field.
  1596  func SourceCountryLT(v string) predicate.Alert {
  1597  	return predicate.Alert(func(s *sql.Selector) {
  1598  		s.Where(sql.LT(s.C(FieldSourceCountry), v))
  1599  	})
  1600  }
  1601  
  1602  // SourceCountryLTE applies the LTE predicate on the "sourceCountry" field.
  1603  func SourceCountryLTE(v string) predicate.Alert {
  1604  	return predicate.Alert(func(s *sql.Selector) {
  1605  		s.Where(sql.LTE(s.C(FieldSourceCountry), v))
  1606  	})
  1607  }
  1608  
  1609  // SourceCountryContains applies the Contains predicate on the "sourceCountry" field.
  1610  func SourceCountryContains(v string) predicate.Alert {
  1611  	return predicate.Alert(func(s *sql.Selector) {
  1612  		s.Where(sql.Contains(s.C(FieldSourceCountry), v))
  1613  	})
  1614  }
  1615  
  1616  // SourceCountryHasPrefix applies the HasPrefix predicate on the "sourceCountry" field.
  1617  func SourceCountryHasPrefix(v string) predicate.Alert {
  1618  	return predicate.Alert(func(s *sql.Selector) {
  1619  		s.Where(sql.HasPrefix(s.C(FieldSourceCountry), v))
  1620  	})
  1621  }
  1622  
  1623  // SourceCountryHasSuffix applies the HasSuffix predicate on the "sourceCountry" field.
  1624  func SourceCountryHasSuffix(v string) predicate.Alert {
  1625  	return predicate.Alert(func(s *sql.Selector) {
  1626  		s.Where(sql.HasSuffix(s.C(FieldSourceCountry), v))
  1627  	})
  1628  }
  1629  
  1630  // SourceCountryIsNil applies the IsNil predicate on the "sourceCountry" field.
  1631  func SourceCountryIsNil() predicate.Alert {
  1632  	return predicate.Alert(func(s *sql.Selector) {
  1633  		s.Where(sql.IsNull(s.C(FieldSourceCountry)))
  1634  	})
  1635  }
  1636  
  1637  // SourceCountryNotNil applies the NotNil predicate on the "sourceCountry" field.
  1638  func SourceCountryNotNil() predicate.Alert {
  1639  	return predicate.Alert(func(s *sql.Selector) {
  1640  		s.Where(sql.NotNull(s.C(FieldSourceCountry)))
  1641  	})
  1642  }
  1643  
  1644  // SourceCountryEqualFold applies the EqualFold predicate on the "sourceCountry" field.
  1645  func SourceCountryEqualFold(v string) predicate.Alert {
  1646  	return predicate.Alert(func(s *sql.Selector) {
  1647  		s.Where(sql.EqualFold(s.C(FieldSourceCountry), v))
  1648  	})
  1649  }
  1650  
  1651  // SourceCountryContainsFold applies the ContainsFold predicate on the "sourceCountry" field.
  1652  func SourceCountryContainsFold(v string) predicate.Alert {
  1653  	return predicate.Alert(func(s *sql.Selector) {
  1654  		s.Where(sql.ContainsFold(s.C(FieldSourceCountry), v))
  1655  	})
  1656  }
  1657  
  1658  // SourceLatitudeEQ applies the EQ predicate on the "sourceLatitude" field.
  1659  func SourceLatitudeEQ(v float32) predicate.Alert {
  1660  	return predicate.Alert(func(s *sql.Selector) {
  1661  		s.Where(sql.EQ(s.C(FieldSourceLatitude), v))
  1662  	})
  1663  }
  1664  
  1665  // SourceLatitudeNEQ applies the NEQ predicate on the "sourceLatitude" field.
  1666  func SourceLatitudeNEQ(v float32) predicate.Alert {
  1667  	return predicate.Alert(func(s *sql.Selector) {
  1668  		s.Where(sql.NEQ(s.C(FieldSourceLatitude), v))
  1669  	})
  1670  }
  1671  
  1672  // SourceLatitudeIn applies the In predicate on the "sourceLatitude" field.
  1673  func SourceLatitudeIn(vs ...float32) predicate.Alert {
  1674  	v := make([]interface{}, len(vs))
  1675  	for i := range v {
  1676  		v[i] = vs[i]
  1677  	}
  1678  	return predicate.Alert(func(s *sql.Selector) {
  1679  		// if not arguments were provided, append the FALSE constants,
  1680  		// since we can't apply "IN ()". This will make this predicate falsy.
  1681  		if len(v) == 0 {
  1682  			s.Where(sql.False())
  1683  			return
  1684  		}
  1685  		s.Where(sql.In(s.C(FieldSourceLatitude), v...))
  1686  	})
  1687  }
  1688  
  1689  // SourceLatitudeNotIn applies the NotIn predicate on the "sourceLatitude" field.
  1690  func SourceLatitudeNotIn(vs ...float32) predicate.Alert {
  1691  	v := make([]interface{}, len(vs))
  1692  	for i := range v {
  1693  		v[i] = vs[i]
  1694  	}
  1695  	return predicate.Alert(func(s *sql.Selector) {
  1696  		// if not arguments were provided, append the FALSE constants,
  1697  		// since we can't apply "IN ()". This will make this predicate falsy.
  1698  		if len(v) == 0 {
  1699  			s.Where(sql.False())
  1700  			return
  1701  		}
  1702  		s.Where(sql.NotIn(s.C(FieldSourceLatitude), v...))
  1703  	})
  1704  }
  1705  
  1706  // SourceLatitudeGT applies the GT predicate on the "sourceLatitude" field.
  1707  func SourceLatitudeGT(v float32) predicate.Alert {
  1708  	return predicate.Alert(func(s *sql.Selector) {
  1709  		s.Where(sql.GT(s.C(FieldSourceLatitude), v))
  1710  	})
  1711  }
  1712  
  1713  // SourceLatitudeGTE applies the GTE predicate on the "sourceLatitude" field.
  1714  func SourceLatitudeGTE(v float32) predicate.Alert {
  1715  	return predicate.Alert(func(s *sql.Selector) {
  1716  		s.Where(sql.GTE(s.C(FieldSourceLatitude), v))
  1717  	})
  1718  }
  1719  
  1720  // SourceLatitudeLT applies the LT predicate on the "sourceLatitude" field.
  1721  func SourceLatitudeLT(v float32) predicate.Alert {
  1722  	return predicate.Alert(func(s *sql.Selector) {
  1723  		s.Where(sql.LT(s.C(FieldSourceLatitude), v))
  1724  	})
  1725  }
  1726  
  1727  // SourceLatitudeLTE applies the LTE predicate on the "sourceLatitude" field.
  1728  func SourceLatitudeLTE(v float32) predicate.Alert {
  1729  	return predicate.Alert(func(s *sql.Selector) {
  1730  		s.Where(sql.LTE(s.C(FieldSourceLatitude), v))
  1731  	})
  1732  }
  1733  
  1734  // SourceLatitudeIsNil applies the IsNil predicate on the "sourceLatitude" field.
  1735  func SourceLatitudeIsNil() predicate.Alert {
  1736  	return predicate.Alert(func(s *sql.Selector) {
  1737  		s.Where(sql.IsNull(s.C(FieldSourceLatitude)))
  1738  	})
  1739  }
  1740  
  1741  // SourceLatitudeNotNil applies the NotNil predicate on the "sourceLatitude" field.
  1742  func SourceLatitudeNotNil() predicate.Alert {
  1743  	return predicate.Alert(func(s *sql.Selector) {
  1744  		s.Where(sql.NotNull(s.C(FieldSourceLatitude)))
  1745  	})
  1746  }
  1747  
  1748  // SourceLongitudeEQ applies the EQ predicate on the "sourceLongitude" field.
  1749  func SourceLongitudeEQ(v float32) predicate.Alert {
  1750  	return predicate.Alert(func(s *sql.Selector) {
  1751  		s.Where(sql.EQ(s.C(FieldSourceLongitude), v))
  1752  	})
  1753  }
  1754  
  1755  // SourceLongitudeNEQ applies the NEQ predicate on the "sourceLongitude" field.
  1756  func SourceLongitudeNEQ(v float32) predicate.Alert {
  1757  	return predicate.Alert(func(s *sql.Selector) {
  1758  		s.Where(sql.NEQ(s.C(FieldSourceLongitude), v))
  1759  	})
  1760  }
  1761  
  1762  // SourceLongitudeIn applies the In predicate on the "sourceLongitude" field.
  1763  func SourceLongitudeIn(vs ...float32) predicate.Alert {
  1764  	v := make([]interface{}, len(vs))
  1765  	for i := range v {
  1766  		v[i] = vs[i]
  1767  	}
  1768  	return predicate.Alert(func(s *sql.Selector) {
  1769  		// if not arguments were provided, append the FALSE constants,
  1770  		// since we can't apply "IN ()". This will make this predicate falsy.
  1771  		if len(v) == 0 {
  1772  			s.Where(sql.False())
  1773  			return
  1774  		}
  1775  		s.Where(sql.In(s.C(FieldSourceLongitude), v...))
  1776  	})
  1777  }
  1778  
  1779  // SourceLongitudeNotIn applies the NotIn predicate on the "sourceLongitude" field.
  1780  func SourceLongitudeNotIn(vs ...float32) predicate.Alert {
  1781  	v := make([]interface{}, len(vs))
  1782  	for i := range v {
  1783  		v[i] = vs[i]
  1784  	}
  1785  	return predicate.Alert(func(s *sql.Selector) {
  1786  		// if not arguments were provided, append the FALSE constants,
  1787  		// since we can't apply "IN ()". This will make this predicate falsy.
  1788  		if len(v) == 0 {
  1789  			s.Where(sql.False())
  1790  			return
  1791  		}
  1792  		s.Where(sql.NotIn(s.C(FieldSourceLongitude), v...))
  1793  	})
  1794  }
  1795  
  1796  // SourceLongitudeGT applies the GT predicate on the "sourceLongitude" field.
  1797  func SourceLongitudeGT(v float32) predicate.Alert {
  1798  	return predicate.Alert(func(s *sql.Selector) {
  1799  		s.Where(sql.GT(s.C(FieldSourceLongitude), v))
  1800  	})
  1801  }
  1802  
  1803  // SourceLongitudeGTE applies the GTE predicate on the "sourceLongitude" field.
  1804  func SourceLongitudeGTE(v float32) predicate.Alert {
  1805  	return predicate.Alert(func(s *sql.Selector) {
  1806  		s.Where(sql.GTE(s.C(FieldSourceLongitude), v))
  1807  	})
  1808  }
  1809  
  1810  // SourceLongitudeLT applies the LT predicate on the "sourceLongitude" field.
  1811  func SourceLongitudeLT(v float32) predicate.Alert {
  1812  	return predicate.Alert(func(s *sql.Selector) {
  1813  		s.Where(sql.LT(s.C(FieldSourceLongitude), v))
  1814  	})
  1815  }
  1816  
  1817  // SourceLongitudeLTE applies the LTE predicate on the "sourceLongitude" field.
  1818  func SourceLongitudeLTE(v float32) predicate.Alert {
  1819  	return predicate.Alert(func(s *sql.Selector) {
  1820  		s.Where(sql.LTE(s.C(FieldSourceLongitude), v))
  1821  	})
  1822  }
  1823  
  1824  // SourceLongitudeIsNil applies the IsNil predicate on the "sourceLongitude" field.
  1825  func SourceLongitudeIsNil() predicate.Alert {
  1826  	return predicate.Alert(func(s *sql.Selector) {
  1827  		s.Where(sql.IsNull(s.C(FieldSourceLongitude)))
  1828  	})
  1829  }
  1830  
  1831  // SourceLongitudeNotNil applies the NotNil predicate on the "sourceLongitude" field.
  1832  func SourceLongitudeNotNil() predicate.Alert {
  1833  	return predicate.Alert(func(s *sql.Selector) {
  1834  		s.Where(sql.NotNull(s.C(FieldSourceLongitude)))
  1835  	})
  1836  }
  1837  
  1838  // SourceScopeEQ applies the EQ predicate on the "sourceScope" field.
  1839  func SourceScopeEQ(v string) predicate.Alert {
  1840  	return predicate.Alert(func(s *sql.Selector) {
  1841  		s.Where(sql.EQ(s.C(FieldSourceScope), v))
  1842  	})
  1843  }
  1844  
  1845  // SourceScopeNEQ applies the NEQ predicate on the "sourceScope" field.
  1846  func SourceScopeNEQ(v string) predicate.Alert {
  1847  	return predicate.Alert(func(s *sql.Selector) {
  1848  		s.Where(sql.NEQ(s.C(FieldSourceScope), v))
  1849  	})
  1850  }
  1851  
  1852  // SourceScopeIn applies the In predicate on the "sourceScope" field.
  1853  func SourceScopeIn(vs ...string) predicate.Alert {
  1854  	v := make([]interface{}, len(vs))
  1855  	for i := range v {
  1856  		v[i] = vs[i]
  1857  	}
  1858  	return predicate.Alert(func(s *sql.Selector) {
  1859  		// if not arguments were provided, append the FALSE constants,
  1860  		// since we can't apply "IN ()". This will make this predicate falsy.
  1861  		if len(v) == 0 {
  1862  			s.Where(sql.False())
  1863  			return
  1864  		}
  1865  		s.Where(sql.In(s.C(FieldSourceScope), v...))
  1866  	})
  1867  }
  1868  
  1869  // SourceScopeNotIn applies the NotIn predicate on the "sourceScope" field.
  1870  func SourceScopeNotIn(vs ...string) predicate.Alert {
  1871  	v := make([]interface{}, len(vs))
  1872  	for i := range v {
  1873  		v[i] = vs[i]
  1874  	}
  1875  	return predicate.Alert(func(s *sql.Selector) {
  1876  		// if not arguments were provided, append the FALSE constants,
  1877  		// since we can't apply "IN ()". This will make this predicate falsy.
  1878  		if len(v) == 0 {
  1879  			s.Where(sql.False())
  1880  			return
  1881  		}
  1882  		s.Where(sql.NotIn(s.C(FieldSourceScope), v...))
  1883  	})
  1884  }
  1885  
  1886  // SourceScopeGT applies the GT predicate on the "sourceScope" field.
  1887  func SourceScopeGT(v string) predicate.Alert {
  1888  	return predicate.Alert(func(s *sql.Selector) {
  1889  		s.Where(sql.GT(s.C(FieldSourceScope), v))
  1890  	})
  1891  }
  1892  
  1893  // SourceScopeGTE applies the GTE predicate on the "sourceScope" field.
  1894  func SourceScopeGTE(v string) predicate.Alert {
  1895  	return predicate.Alert(func(s *sql.Selector) {
  1896  		s.Where(sql.GTE(s.C(FieldSourceScope), v))
  1897  	})
  1898  }
  1899  
  1900  // SourceScopeLT applies the LT predicate on the "sourceScope" field.
  1901  func SourceScopeLT(v string) predicate.Alert {
  1902  	return predicate.Alert(func(s *sql.Selector) {
  1903  		s.Where(sql.LT(s.C(FieldSourceScope), v))
  1904  	})
  1905  }
  1906  
  1907  // SourceScopeLTE applies the LTE predicate on the "sourceScope" field.
  1908  func SourceScopeLTE(v string) predicate.Alert {
  1909  	return predicate.Alert(func(s *sql.Selector) {
  1910  		s.Where(sql.LTE(s.C(FieldSourceScope), v))
  1911  	})
  1912  }
  1913  
  1914  // SourceScopeContains applies the Contains predicate on the "sourceScope" field.
  1915  func SourceScopeContains(v string) predicate.Alert {
  1916  	return predicate.Alert(func(s *sql.Selector) {
  1917  		s.Where(sql.Contains(s.C(FieldSourceScope), v))
  1918  	})
  1919  }
  1920  
  1921  // SourceScopeHasPrefix applies the HasPrefix predicate on the "sourceScope" field.
  1922  func SourceScopeHasPrefix(v string) predicate.Alert {
  1923  	return predicate.Alert(func(s *sql.Selector) {
  1924  		s.Where(sql.HasPrefix(s.C(FieldSourceScope), v))
  1925  	})
  1926  }
  1927  
  1928  // SourceScopeHasSuffix applies the HasSuffix predicate on the "sourceScope" field.
  1929  func SourceScopeHasSuffix(v string) predicate.Alert {
  1930  	return predicate.Alert(func(s *sql.Selector) {
  1931  		s.Where(sql.HasSuffix(s.C(FieldSourceScope), v))
  1932  	})
  1933  }
  1934  
  1935  // SourceScopeIsNil applies the IsNil predicate on the "sourceScope" field.
  1936  func SourceScopeIsNil() predicate.Alert {
  1937  	return predicate.Alert(func(s *sql.Selector) {
  1938  		s.Where(sql.IsNull(s.C(FieldSourceScope)))
  1939  	})
  1940  }
  1941  
  1942  // SourceScopeNotNil applies the NotNil predicate on the "sourceScope" field.
  1943  func SourceScopeNotNil() predicate.Alert {
  1944  	return predicate.Alert(func(s *sql.Selector) {
  1945  		s.Where(sql.NotNull(s.C(FieldSourceScope)))
  1946  	})
  1947  }
  1948  
  1949  // SourceScopeEqualFold applies the EqualFold predicate on the "sourceScope" field.
  1950  func SourceScopeEqualFold(v string) predicate.Alert {
  1951  	return predicate.Alert(func(s *sql.Selector) {
  1952  		s.Where(sql.EqualFold(s.C(FieldSourceScope), v))
  1953  	})
  1954  }
  1955  
  1956  // SourceScopeContainsFold applies the ContainsFold predicate on the "sourceScope" field.
  1957  func SourceScopeContainsFold(v string) predicate.Alert {
  1958  	return predicate.Alert(func(s *sql.Selector) {
  1959  		s.Where(sql.ContainsFold(s.C(FieldSourceScope), v))
  1960  	})
  1961  }
  1962  
  1963  // SourceValueEQ applies the EQ predicate on the "sourceValue" field.
  1964  func SourceValueEQ(v string) predicate.Alert {
  1965  	return predicate.Alert(func(s *sql.Selector) {
  1966  		s.Where(sql.EQ(s.C(FieldSourceValue), v))
  1967  	})
  1968  }
  1969  
  1970  // SourceValueNEQ applies the NEQ predicate on the "sourceValue" field.
  1971  func SourceValueNEQ(v string) predicate.Alert {
  1972  	return predicate.Alert(func(s *sql.Selector) {
  1973  		s.Where(sql.NEQ(s.C(FieldSourceValue), v))
  1974  	})
  1975  }
  1976  
  1977  // SourceValueIn applies the In predicate on the "sourceValue" field.
  1978  func SourceValueIn(vs ...string) predicate.Alert {
  1979  	v := make([]interface{}, len(vs))
  1980  	for i := range v {
  1981  		v[i] = vs[i]
  1982  	}
  1983  	return predicate.Alert(func(s *sql.Selector) {
  1984  		// if not arguments were provided, append the FALSE constants,
  1985  		// since we can't apply "IN ()". This will make this predicate falsy.
  1986  		if len(v) == 0 {
  1987  			s.Where(sql.False())
  1988  			return
  1989  		}
  1990  		s.Where(sql.In(s.C(FieldSourceValue), v...))
  1991  	})
  1992  }
  1993  
  1994  // SourceValueNotIn applies the NotIn predicate on the "sourceValue" field.
  1995  func SourceValueNotIn(vs ...string) predicate.Alert {
  1996  	v := make([]interface{}, len(vs))
  1997  	for i := range v {
  1998  		v[i] = vs[i]
  1999  	}
  2000  	return predicate.Alert(func(s *sql.Selector) {
  2001  		// if not arguments were provided, append the FALSE constants,
  2002  		// since we can't apply "IN ()". This will make this predicate falsy.
  2003  		if len(v) == 0 {
  2004  			s.Where(sql.False())
  2005  			return
  2006  		}
  2007  		s.Where(sql.NotIn(s.C(FieldSourceValue), v...))
  2008  	})
  2009  }
  2010  
  2011  // SourceValueGT applies the GT predicate on the "sourceValue" field.
  2012  func SourceValueGT(v string) predicate.Alert {
  2013  	return predicate.Alert(func(s *sql.Selector) {
  2014  		s.Where(sql.GT(s.C(FieldSourceValue), v))
  2015  	})
  2016  }
  2017  
  2018  // SourceValueGTE applies the GTE predicate on the "sourceValue" field.
  2019  func SourceValueGTE(v string) predicate.Alert {
  2020  	return predicate.Alert(func(s *sql.Selector) {
  2021  		s.Where(sql.GTE(s.C(FieldSourceValue), v))
  2022  	})
  2023  }
  2024  
  2025  // SourceValueLT applies the LT predicate on the "sourceValue" field.
  2026  func SourceValueLT(v string) predicate.Alert {
  2027  	return predicate.Alert(func(s *sql.Selector) {
  2028  		s.Where(sql.LT(s.C(FieldSourceValue), v))
  2029  	})
  2030  }
  2031  
  2032  // SourceValueLTE applies the LTE predicate on the "sourceValue" field.
  2033  func SourceValueLTE(v string) predicate.Alert {
  2034  	return predicate.Alert(func(s *sql.Selector) {
  2035  		s.Where(sql.LTE(s.C(FieldSourceValue), v))
  2036  	})
  2037  }
  2038  
  2039  // SourceValueContains applies the Contains predicate on the "sourceValue" field.
  2040  func SourceValueContains(v string) predicate.Alert {
  2041  	return predicate.Alert(func(s *sql.Selector) {
  2042  		s.Where(sql.Contains(s.C(FieldSourceValue), v))
  2043  	})
  2044  }
  2045  
  2046  // SourceValueHasPrefix applies the HasPrefix predicate on the "sourceValue" field.
  2047  func SourceValueHasPrefix(v string) predicate.Alert {
  2048  	return predicate.Alert(func(s *sql.Selector) {
  2049  		s.Where(sql.HasPrefix(s.C(FieldSourceValue), v))
  2050  	})
  2051  }
  2052  
  2053  // SourceValueHasSuffix applies the HasSuffix predicate on the "sourceValue" field.
  2054  func SourceValueHasSuffix(v string) predicate.Alert {
  2055  	return predicate.Alert(func(s *sql.Selector) {
  2056  		s.Where(sql.HasSuffix(s.C(FieldSourceValue), v))
  2057  	})
  2058  }
  2059  
  2060  // SourceValueIsNil applies the IsNil predicate on the "sourceValue" field.
  2061  func SourceValueIsNil() predicate.Alert {
  2062  	return predicate.Alert(func(s *sql.Selector) {
  2063  		s.Where(sql.IsNull(s.C(FieldSourceValue)))
  2064  	})
  2065  }
  2066  
  2067  // SourceValueNotNil applies the NotNil predicate on the "sourceValue" field.
  2068  func SourceValueNotNil() predicate.Alert {
  2069  	return predicate.Alert(func(s *sql.Selector) {
  2070  		s.Where(sql.NotNull(s.C(FieldSourceValue)))
  2071  	})
  2072  }
  2073  
  2074  // SourceValueEqualFold applies the EqualFold predicate on the "sourceValue" field.
  2075  func SourceValueEqualFold(v string) predicate.Alert {
  2076  	return predicate.Alert(func(s *sql.Selector) {
  2077  		s.Where(sql.EqualFold(s.C(FieldSourceValue), v))
  2078  	})
  2079  }
  2080  
  2081  // SourceValueContainsFold applies the ContainsFold predicate on the "sourceValue" field.
  2082  func SourceValueContainsFold(v string) predicate.Alert {
  2083  	return predicate.Alert(func(s *sql.Selector) {
  2084  		s.Where(sql.ContainsFold(s.C(FieldSourceValue), v))
  2085  	})
  2086  }
  2087  
  2088  // CapacityEQ applies the EQ predicate on the "capacity" field.
  2089  func CapacityEQ(v int32) predicate.Alert {
  2090  	return predicate.Alert(func(s *sql.Selector) {
  2091  		s.Where(sql.EQ(s.C(FieldCapacity), v))
  2092  	})
  2093  }
  2094  
  2095  // CapacityNEQ applies the NEQ predicate on the "capacity" field.
  2096  func CapacityNEQ(v int32) predicate.Alert {
  2097  	return predicate.Alert(func(s *sql.Selector) {
  2098  		s.Where(sql.NEQ(s.C(FieldCapacity), v))
  2099  	})
  2100  }
  2101  
  2102  // CapacityIn applies the In predicate on the "capacity" field.
  2103  func CapacityIn(vs ...int32) predicate.Alert {
  2104  	v := make([]interface{}, len(vs))
  2105  	for i := range v {
  2106  		v[i] = vs[i]
  2107  	}
  2108  	return predicate.Alert(func(s *sql.Selector) {
  2109  		// if not arguments were provided, append the FALSE constants,
  2110  		// since we can't apply "IN ()". This will make this predicate falsy.
  2111  		if len(v) == 0 {
  2112  			s.Where(sql.False())
  2113  			return
  2114  		}
  2115  		s.Where(sql.In(s.C(FieldCapacity), v...))
  2116  	})
  2117  }
  2118  
  2119  // CapacityNotIn applies the NotIn predicate on the "capacity" field.
  2120  func CapacityNotIn(vs ...int32) predicate.Alert {
  2121  	v := make([]interface{}, len(vs))
  2122  	for i := range v {
  2123  		v[i] = vs[i]
  2124  	}
  2125  	return predicate.Alert(func(s *sql.Selector) {
  2126  		// if not arguments were provided, append the FALSE constants,
  2127  		// since we can't apply "IN ()". This will make this predicate falsy.
  2128  		if len(v) == 0 {
  2129  			s.Where(sql.False())
  2130  			return
  2131  		}
  2132  		s.Where(sql.NotIn(s.C(FieldCapacity), v...))
  2133  	})
  2134  }
  2135  
  2136  // CapacityGT applies the GT predicate on the "capacity" field.
  2137  func CapacityGT(v int32) predicate.Alert {
  2138  	return predicate.Alert(func(s *sql.Selector) {
  2139  		s.Where(sql.GT(s.C(FieldCapacity), v))
  2140  	})
  2141  }
  2142  
  2143  // CapacityGTE applies the GTE predicate on the "capacity" field.
  2144  func CapacityGTE(v int32) predicate.Alert {
  2145  	return predicate.Alert(func(s *sql.Selector) {
  2146  		s.Where(sql.GTE(s.C(FieldCapacity), v))
  2147  	})
  2148  }
  2149  
  2150  // CapacityLT applies the LT predicate on the "capacity" field.
  2151  func CapacityLT(v int32) predicate.Alert {
  2152  	return predicate.Alert(func(s *sql.Selector) {
  2153  		s.Where(sql.LT(s.C(FieldCapacity), v))
  2154  	})
  2155  }
  2156  
  2157  // CapacityLTE applies the LTE predicate on the "capacity" field.
  2158  func CapacityLTE(v int32) predicate.Alert {
  2159  	return predicate.Alert(func(s *sql.Selector) {
  2160  		s.Where(sql.LTE(s.C(FieldCapacity), v))
  2161  	})
  2162  }
  2163  
  2164  // CapacityIsNil applies the IsNil predicate on the "capacity" field.
  2165  func CapacityIsNil() predicate.Alert {
  2166  	return predicate.Alert(func(s *sql.Selector) {
  2167  		s.Where(sql.IsNull(s.C(FieldCapacity)))
  2168  	})
  2169  }
  2170  
  2171  // CapacityNotNil applies the NotNil predicate on the "capacity" field.
  2172  func CapacityNotNil() predicate.Alert {
  2173  	return predicate.Alert(func(s *sql.Selector) {
  2174  		s.Where(sql.NotNull(s.C(FieldCapacity)))
  2175  	})
  2176  }
  2177  
  2178  // LeakSpeedEQ applies the EQ predicate on the "leakSpeed" field.
  2179  func LeakSpeedEQ(v string) predicate.Alert {
  2180  	return predicate.Alert(func(s *sql.Selector) {
  2181  		s.Where(sql.EQ(s.C(FieldLeakSpeed), v))
  2182  	})
  2183  }
  2184  
  2185  // LeakSpeedNEQ applies the NEQ predicate on the "leakSpeed" field.
  2186  func LeakSpeedNEQ(v string) predicate.Alert {
  2187  	return predicate.Alert(func(s *sql.Selector) {
  2188  		s.Where(sql.NEQ(s.C(FieldLeakSpeed), v))
  2189  	})
  2190  }
  2191  
  2192  // LeakSpeedIn applies the In predicate on the "leakSpeed" field.
  2193  func LeakSpeedIn(vs ...string) predicate.Alert {
  2194  	v := make([]interface{}, len(vs))
  2195  	for i := range v {
  2196  		v[i] = vs[i]
  2197  	}
  2198  	return predicate.Alert(func(s *sql.Selector) {
  2199  		// if not arguments were provided, append the FALSE constants,
  2200  		// since we can't apply "IN ()". This will make this predicate falsy.
  2201  		if len(v) == 0 {
  2202  			s.Where(sql.False())
  2203  			return
  2204  		}
  2205  		s.Where(sql.In(s.C(FieldLeakSpeed), v...))
  2206  	})
  2207  }
  2208  
  2209  // LeakSpeedNotIn applies the NotIn predicate on the "leakSpeed" field.
  2210  func LeakSpeedNotIn(vs ...string) predicate.Alert {
  2211  	v := make([]interface{}, len(vs))
  2212  	for i := range v {
  2213  		v[i] = vs[i]
  2214  	}
  2215  	return predicate.Alert(func(s *sql.Selector) {
  2216  		// if not arguments were provided, append the FALSE constants,
  2217  		// since we can't apply "IN ()". This will make this predicate falsy.
  2218  		if len(v) == 0 {
  2219  			s.Where(sql.False())
  2220  			return
  2221  		}
  2222  		s.Where(sql.NotIn(s.C(FieldLeakSpeed), v...))
  2223  	})
  2224  }
  2225  
  2226  // LeakSpeedGT applies the GT predicate on the "leakSpeed" field.
  2227  func LeakSpeedGT(v string) predicate.Alert {
  2228  	return predicate.Alert(func(s *sql.Selector) {
  2229  		s.Where(sql.GT(s.C(FieldLeakSpeed), v))
  2230  	})
  2231  }
  2232  
  2233  // LeakSpeedGTE applies the GTE predicate on the "leakSpeed" field.
  2234  func LeakSpeedGTE(v string) predicate.Alert {
  2235  	return predicate.Alert(func(s *sql.Selector) {
  2236  		s.Where(sql.GTE(s.C(FieldLeakSpeed), v))
  2237  	})
  2238  }
  2239  
  2240  // LeakSpeedLT applies the LT predicate on the "leakSpeed" field.
  2241  func LeakSpeedLT(v string) predicate.Alert {
  2242  	return predicate.Alert(func(s *sql.Selector) {
  2243  		s.Where(sql.LT(s.C(FieldLeakSpeed), v))
  2244  	})
  2245  }
  2246  
  2247  // LeakSpeedLTE applies the LTE predicate on the "leakSpeed" field.
  2248  func LeakSpeedLTE(v string) predicate.Alert {
  2249  	return predicate.Alert(func(s *sql.Selector) {
  2250  		s.Where(sql.LTE(s.C(FieldLeakSpeed), v))
  2251  	})
  2252  }
  2253  
  2254  // LeakSpeedContains applies the Contains predicate on the "leakSpeed" field.
  2255  func LeakSpeedContains(v string) predicate.Alert {
  2256  	return predicate.Alert(func(s *sql.Selector) {
  2257  		s.Where(sql.Contains(s.C(FieldLeakSpeed), v))
  2258  	})
  2259  }
  2260  
  2261  // LeakSpeedHasPrefix applies the HasPrefix predicate on the "leakSpeed" field.
  2262  func LeakSpeedHasPrefix(v string) predicate.Alert {
  2263  	return predicate.Alert(func(s *sql.Selector) {
  2264  		s.Where(sql.HasPrefix(s.C(FieldLeakSpeed), v))
  2265  	})
  2266  }
  2267  
  2268  // LeakSpeedHasSuffix applies the HasSuffix predicate on the "leakSpeed" field.
  2269  func LeakSpeedHasSuffix(v string) predicate.Alert {
  2270  	return predicate.Alert(func(s *sql.Selector) {
  2271  		s.Where(sql.HasSuffix(s.C(FieldLeakSpeed), v))
  2272  	})
  2273  }
  2274  
  2275  // LeakSpeedIsNil applies the IsNil predicate on the "leakSpeed" field.
  2276  func LeakSpeedIsNil() predicate.Alert {
  2277  	return predicate.Alert(func(s *sql.Selector) {
  2278  		s.Where(sql.IsNull(s.C(FieldLeakSpeed)))
  2279  	})
  2280  }
  2281  
  2282  // LeakSpeedNotNil applies the NotNil predicate on the "leakSpeed" field.
  2283  func LeakSpeedNotNil() predicate.Alert {
  2284  	return predicate.Alert(func(s *sql.Selector) {
  2285  		s.Where(sql.NotNull(s.C(FieldLeakSpeed)))
  2286  	})
  2287  }
  2288  
  2289  // LeakSpeedEqualFold applies the EqualFold predicate on the "leakSpeed" field.
  2290  func LeakSpeedEqualFold(v string) predicate.Alert {
  2291  	return predicate.Alert(func(s *sql.Selector) {
  2292  		s.Where(sql.EqualFold(s.C(FieldLeakSpeed), v))
  2293  	})
  2294  }
  2295  
  2296  // LeakSpeedContainsFold applies the ContainsFold predicate on the "leakSpeed" field.
  2297  func LeakSpeedContainsFold(v string) predicate.Alert {
  2298  	return predicate.Alert(func(s *sql.Selector) {
  2299  		s.Where(sql.ContainsFold(s.C(FieldLeakSpeed), v))
  2300  	})
  2301  }
  2302  
  2303  // ScenarioVersionEQ applies the EQ predicate on the "scenarioVersion" field.
  2304  func ScenarioVersionEQ(v string) predicate.Alert {
  2305  	return predicate.Alert(func(s *sql.Selector) {
  2306  		s.Where(sql.EQ(s.C(FieldScenarioVersion), v))
  2307  	})
  2308  }
  2309  
  2310  // ScenarioVersionNEQ applies the NEQ predicate on the "scenarioVersion" field.
  2311  func ScenarioVersionNEQ(v string) predicate.Alert {
  2312  	return predicate.Alert(func(s *sql.Selector) {
  2313  		s.Where(sql.NEQ(s.C(FieldScenarioVersion), v))
  2314  	})
  2315  }
  2316  
  2317  // ScenarioVersionIn applies the In predicate on the "scenarioVersion" field.
  2318  func ScenarioVersionIn(vs ...string) predicate.Alert {
  2319  	v := make([]interface{}, len(vs))
  2320  	for i := range v {
  2321  		v[i] = vs[i]
  2322  	}
  2323  	return predicate.Alert(func(s *sql.Selector) {
  2324  		// if not arguments were provided, append the FALSE constants,
  2325  		// since we can't apply "IN ()". This will make this predicate falsy.
  2326  		if len(v) == 0 {
  2327  			s.Where(sql.False())
  2328  			return
  2329  		}
  2330  		s.Where(sql.In(s.C(FieldScenarioVersion), v...))
  2331  	})
  2332  }
  2333  
  2334  // ScenarioVersionNotIn applies the NotIn predicate on the "scenarioVersion" field.
  2335  func ScenarioVersionNotIn(vs ...string) predicate.Alert {
  2336  	v := make([]interface{}, len(vs))
  2337  	for i := range v {
  2338  		v[i] = vs[i]
  2339  	}
  2340  	return predicate.Alert(func(s *sql.Selector) {
  2341  		// if not arguments were provided, append the FALSE constants,
  2342  		// since we can't apply "IN ()". This will make this predicate falsy.
  2343  		if len(v) == 0 {
  2344  			s.Where(sql.False())
  2345  			return
  2346  		}
  2347  		s.Where(sql.NotIn(s.C(FieldScenarioVersion), v...))
  2348  	})
  2349  }
  2350  
  2351  // ScenarioVersionGT applies the GT predicate on the "scenarioVersion" field.
  2352  func ScenarioVersionGT(v string) predicate.Alert {
  2353  	return predicate.Alert(func(s *sql.Selector) {
  2354  		s.Where(sql.GT(s.C(FieldScenarioVersion), v))
  2355  	})
  2356  }
  2357  
  2358  // ScenarioVersionGTE applies the GTE predicate on the "scenarioVersion" field.
  2359  func ScenarioVersionGTE(v string) predicate.Alert {
  2360  	return predicate.Alert(func(s *sql.Selector) {
  2361  		s.Where(sql.GTE(s.C(FieldScenarioVersion), v))
  2362  	})
  2363  }
  2364  
  2365  // ScenarioVersionLT applies the LT predicate on the "scenarioVersion" field.
  2366  func ScenarioVersionLT(v string) predicate.Alert {
  2367  	return predicate.Alert(func(s *sql.Selector) {
  2368  		s.Where(sql.LT(s.C(FieldScenarioVersion), v))
  2369  	})
  2370  }
  2371  
  2372  // ScenarioVersionLTE applies the LTE predicate on the "scenarioVersion" field.
  2373  func ScenarioVersionLTE(v string) predicate.Alert {
  2374  	return predicate.Alert(func(s *sql.Selector) {
  2375  		s.Where(sql.LTE(s.C(FieldScenarioVersion), v))
  2376  	})
  2377  }
  2378  
  2379  // ScenarioVersionContains applies the Contains predicate on the "scenarioVersion" field.
  2380  func ScenarioVersionContains(v string) predicate.Alert {
  2381  	return predicate.Alert(func(s *sql.Selector) {
  2382  		s.Where(sql.Contains(s.C(FieldScenarioVersion), v))
  2383  	})
  2384  }
  2385  
  2386  // ScenarioVersionHasPrefix applies the HasPrefix predicate on the "scenarioVersion" field.
  2387  func ScenarioVersionHasPrefix(v string) predicate.Alert {
  2388  	return predicate.Alert(func(s *sql.Selector) {
  2389  		s.Where(sql.HasPrefix(s.C(FieldScenarioVersion), v))
  2390  	})
  2391  }
  2392  
  2393  // ScenarioVersionHasSuffix applies the HasSuffix predicate on the "scenarioVersion" field.
  2394  func ScenarioVersionHasSuffix(v string) predicate.Alert {
  2395  	return predicate.Alert(func(s *sql.Selector) {
  2396  		s.Where(sql.HasSuffix(s.C(FieldScenarioVersion), v))
  2397  	})
  2398  }
  2399  
  2400  // ScenarioVersionIsNil applies the IsNil predicate on the "scenarioVersion" field.
  2401  func ScenarioVersionIsNil() predicate.Alert {
  2402  	return predicate.Alert(func(s *sql.Selector) {
  2403  		s.Where(sql.IsNull(s.C(FieldScenarioVersion)))
  2404  	})
  2405  }
  2406  
  2407  // ScenarioVersionNotNil applies the NotNil predicate on the "scenarioVersion" field.
  2408  func ScenarioVersionNotNil() predicate.Alert {
  2409  	return predicate.Alert(func(s *sql.Selector) {
  2410  		s.Where(sql.NotNull(s.C(FieldScenarioVersion)))
  2411  	})
  2412  }
  2413  
  2414  // ScenarioVersionEqualFold applies the EqualFold predicate on the "scenarioVersion" field.
  2415  func ScenarioVersionEqualFold(v string) predicate.Alert {
  2416  	return predicate.Alert(func(s *sql.Selector) {
  2417  		s.Where(sql.EqualFold(s.C(FieldScenarioVersion), v))
  2418  	})
  2419  }
  2420  
  2421  // ScenarioVersionContainsFold applies the ContainsFold predicate on the "scenarioVersion" field.
  2422  func ScenarioVersionContainsFold(v string) predicate.Alert {
  2423  	return predicate.Alert(func(s *sql.Selector) {
  2424  		s.Where(sql.ContainsFold(s.C(FieldScenarioVersion), v))
  2425  	})
  2426  }
  2427  
  2428  // ScenarioHashEQ applies the EQ predicate on the "scenarioHash" field.
  2429  func ScenarioHashEQ(v string) predicate.Alert {
  2430  	return predicate.Alert(func(s *sql.Selector) {
  2431  		s.Where(sql.EQ(s.C(FieldScenarioHash), v))
  2432  	})
  2433  }
  2434  
  2435  // ScenarioHashNEQ applies the NEQ predicate on the "scenarioHash" field.
  2436  func ScenarioHashNEQ(v string) predicate.Alert {
  2437  	return predicate.Alert(func(s *sql.Selector) {
  2438  		s.Where(sql.NEQ(s.C(FieldScenarioHash), v))
  2439  	})
  2440  }
  2441  
  2442  // ScenarioHashIn applies the In predicate on the "scenarioHash" field.
  2443  func ScenarioHashIn(vs ...string) predicate.Alert {
  2444  	v := make([]interface{}, len(vs))
  2445  	for i := range v {
  2446  		v[i] = vs[i]
  2447  	}
  2448  	return predicate.Alert(func(s *sql.Selector) {
  2449  		// if not arguments were provided, append the FALSE constants,
  2450  		// since we can't apply "IN ()". This will make this predicate falsy.
  2451  		if len(v) == 0 {
  2452  			s.Where(sql.False())
  2453  			return
  2454  		}
  2455  		s.Where(sql.In(s.C(FieldScenarioHash), v...))
  2456  	})
  2457  }
  2458  
  2459  // ScenarioHashNotIn applies the NotIn predicate on the "scenarioHash" field.
  2460  func ScenarioHashNotIn(vs ...string) predicate.Alert {
  2461  	v := make([]interface{}, len(vs))
  2462  	for i := range v {
  2463  		v[i] = vs[i]
  2464  	}
  2465  	return predicate.Alert(func(s *sql.Selector) {
  2466  		// if not arguments were provided, append the FALSE constants,
  2467  		// since we can't apply "IN ()". This will make this predicate falsy.
  2468  		if len(v) == 0 {
  2469  			s.Where(sql.False())
  2470  			return
  2471  		}
  2472  		s.Where(sql.NotIn(s.C(FieldScenarioHash), v...))
  2473  	})
  2474  }
  2475  
  2476  // ScenarioHashGT applies the GT predicate on the "scenarioHash" field.
  2477  func ScenarioHashGT(v string) predicate.Alert {
  2478  	return predicate.Alert(func(s *sql.Selector) {
  2479  		s.Where(sql.GT(s.C(FieldScenarioHash), v))
  2480  	})
  2481  }
  2482  
  2483  // ScenarioHashGTE applies the GTE predicate on the "scenarioHash" field.
  2484  func ScenarioHashGTE(v string) predicate.Alert {
  2485  	return predicate.Alert(func(s *sql.Selector) {
  2486  		s.Where(sql.GTE(s.C(FieldScenarioHash), v))
  2487  	})
  2488  }
  2489  
  2490  // ScenarioHashLT applies the LT predicate on the "scenarioHash" field.
  2491  func ScenarioHashLT(v string) predicate.Alert {
  2492  	return predicate.Alert(func(s *sql.Selector) {
  2493  		s.Where(sql.LT(s.C(FieldScenarioHash), v))
  2494  	})
  2495  }
  2496  
  2497  // ScenarioHashLTE applies the LTE predicate on the "scenarioHash" field.
  2498  func ScenarioHashLTE(v string) predicate.Alert {
  2499  	return predicate.Alert(func(s *sql.Selector) {
  2500  		s.Where(sql.LTE(s.C(FieldScenarioHash), v))
  2501  	})
  2502  }
  2503  
  2504  // ScenarioHashContains applies the Contains predicate on the "scenarioHash" field.
  2505  func ScenarioHashContains(v string) predicate.Alert {
  2506  	return predicate.Alert(func(s *sql.Selector) {
  2507  		s.Where(sql.Contains(s.C(FieldScenarioHash), v))
  2508  	})
  2509  }
  2510  
  2511  // ScenarioHashHasPrefix applies the HasPrefix predicate on the "scenarioHash" field.
  2512  func ScenarioHashHasPrefix(v string) predicate.Alert {
  2513  	return predicate.Alert(func(s *sql.Selector) {
  2514  		s.Where(sql.HasPrefix(s.C(FieldScenarioHash), v))
  2515  	})
  2516  }
  2517  
  2518  // ScenarioHashHasSuffix applies the HasSuffix predicate on the "scenarioHash" field.
  2519  func ScenarioHashHasSuffix(v string) predicate.Alert {
  2520  	return predicate.Alert(func(s *sql.Selector) {
  2521  		s.Where(sql.HasSuffix(s.C(FieldScenarioHash), v))
  2522  	})
  2523  }
  2524  
  2525  // ScenarioHashIsNil applies the IsNil predicate on the "scenarioHash" field.
  2526  func ScenarioHashIsNil() predicate.Alert {
  2527  	return predicate.Alert(func(s *sql.Selector) {
  2528  		s.Where(sql.IsNull(s.C(FieldScenarioHash)))
  2529  	})
  2530  }
  2531  
  2532  // ScenarioHashNotNil applies the NotNil predicate on the "scenarioHash" field.
  2533  func ScenarioHashNotNil() predicate.Alert {
  2534  	return predicate.Alert(func(s *sql.Selector) {
  2535  		s.Where(sql.NotNull(s.C(FieldScenarioHash)))
  2536  	})
  2537  }
  2538  
  2539  // ScenarioHashEqualFold applies the EqualFold predicate on the "scenarioHash" field.
  2540  func ScenarioHashEqualFold(v string) predicate.Alert {
  2541  	return predicate.Alert(func(s *sql.Selector) {
  2542  		s.Where(sql.EqualFold(s.C(FieldScenarioHash), v))
  2543  	})
  2544  }
  2545  
  2546  // ScenarioHashContainsFold applies the ContainsFold predicate on the "scenarioHash" field.
  2547  func ScenarioHashContainsFold(v string) predicate.Alert {
  2548  	return predicate.Alert(func(s *sql.Selector) {
  2549  		s.Where(sql.ContainsFold(s.C(FieldScenarioHash), v))
  2550  	})
  2551  }
  2552  
  2553  // SimulatedEQ applies the EQ predicate on the "simulated" field.
  2554  func SimulatedEQ(v bool) predicate.Alert {
  2555  	return predicate.Alert(func(s *sql.Selector) {
  2556  		s.Where(sql.EQ(s.C(FieldSimulated), v))
  2557  	})
  2558  }
  2559  
  2560  // SimulatedNEQ applies the NEQ predicate on the "simulated" field.
  2561  func SimulatedNEQ(v bool) predicate.Alert {
  2562  	return predicate.Alert(func(s *sql.Selector) {
  2563  		s.Where(sql.NEQ(s.C(FieldSimulated), v))
  2564  	})
  2565  }
  2566  
  2567  // HasOwner applies the HasEdge predicate on the "owner" edge.
  2568  func HasOwner() predicate.Alert {
  2569  	return predicate.Alert(func(s *sql.Selector) {
  2570  		step := sqlgraph.NewStep(
  2571  			sqlgraph.From(Table, FieldID),
  2572  			sqlgraph.To(OwnerTable, FieldID),
  2573  			sqlgraph.Edge(sqlgraph.M2O, true, OwnerTable, OwnerColumn),
  2574  		)
  2575  		sqlgraph.HasNeighbors(s, step)
  2576  	})
  2577  }
  2578  
  2579  // HasOwnerWith applies the HasEdge predicate on the "owner" edge with a given conditions (other predicates).
  2580  func HasOwnerWith(preds ...predicate.Machine) predicate.Alert {
  2581  	return predicate.Alert(func(s *sql.Selector) {
  2582  		step := sqlgraph.NewStep(
  2583  			sqlgraph.From(Table, FieldID),
  2584  			sqlgraph.To(OwnerInverseTable, FieldID),
  2585  			sqlgraph.Edge(sqlgraph.M2O, true, OwnerTable, OwnerColumn),
  2586  		)
  2587  		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  2588  			for _, p := range preds {
  2589  				p(s)
  2590  			}
  2591  		})
  2592  	})
  2593  }
  2594  
  2595  // HasDecisions applies the HasEdge predicate on the "decisions" edge.
  2596  func HasDecisions() predicate.Alert {
  2597  	return predicate.Alert(func(s *sql.Selector) {
  2598  		step := sqlgraph.NewStep(
  2599  			sqlgraph.From(Table, FieldID),
  2600  			sqlgraph.To(DecisionsTable, FieldID),
  2601  			sqlgraph.Edge(sqlgraph.O2M, false, DecisionsTable, DecisionsColumn),
  2602  		)
  2603  		sqlgraph.HasNeighbors(s, step)
  2604  	})
  2605  }
  2606  
  2607  // HasDecisionsWith applies the HasEdge predicate on the "decisions" edge with a given conditions (other predicates).
  2608  func HasDecisionsWith(preds ...predicate.Decision) predicate.Alert {
  2609  	return predicate.Alert(func(s *sql.Selector) {
  2610  		step := sqlgraph.NewStep(
  2611  			sqlgraph.From(Table, FieldID),
  2612  			sqlgraph.To(DecisionsInverseTable, FieldID),
  2613  			sqlgraph.Edge(sqlgraph.O2M, false, DecisionsTable, DecisionsColumn),
  2614  		)
  2615  		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  2616  			for _, p := range preds {
  2617  				p(s)
  2618  			}
  2619  		})
  2620  	})
  2621  }
  2622  
  2623  // HasEvents applies the HasEdge predicate on the "events" edge.
  2624  func HasEvents() predicate.Alert {
  2625  	return predicate.Alert(func(s *sql.Selector) {
  2626  		step := sqlgraph.NewStep(
  2627  			sqlgraph.From(Table, FieldID),
  2628  			sqlgraph.To(EventsTable, FieldID),
  2629  			sqlgraph.Edge(sqlgraph.O2M, false, EventsTable, EventsColumn),
  2630  		)
  2631  		sqlgraph.HasNeighbors(s, step)
  2632  	})
  2633  }
  2634  
  2635  // HasEventsWith applies the HasEdge predicate on the "events" edge with a given conditions (other predicates).
  2636  func HasEventsWith(preds ...predicate.Event) predicate.Alert {
  2637  	return predicate.Alert(func(s *sql.Selector) {
  2638  		step := sqlgraph.NewStep(
  2639  			sqlgraph.From(Table, FieldID),
  2640  			sqlgraph.To(EventsInverseTable, FieldID),
  2641  			sqlgraph.Edge(sqlgraph.O2M, false, EventsTable, EventsColumn),
  2642  		)
  2643  		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  2644  			for _, p := range preds {
  2645  				p(s)
  2646  			}
  2647  		})
  2648  	})
  2649  }
  2650  
  2651  // HasMetas applies the HasEdge predicate on the "metas" edge.
  2652  func HasMetas() predicate.Alert {
  2653  	return predicate.Alert(func(s *sql.Selector) {
  2654  		step := sqlgraph.NewStep(
  2655  			sqlgraph.From(Table, FieldID),
  2656  			sqlgraph.To(MetasTable, FieldID),
  2657  			sqlgraph.Edge(sqlgraph.O2M, false, MetasTable, MetasColumn),
  2658  		)
  2659  		sqlgraph.HasNeighbors(s, step)
  2660  	})
  2661  }
  2662  
  2663  // HasMetasWith applies the HasEdge predicate on the "metas" edge with a given conditions (other predicates).
  2664  func HasMetasWith(preds ...predicate.Meta) predicate.Alert {
  2665  	return predicate.Alert(func(s *sql.Selector) {
  2666  		step := sqlgraph.NewStep(
  2667  			sqlgraph.From(Table, FieldID),
  2668  			sqlgraph.To(MetasInverseTable, FieldID),
  2669  			sqlgraph.Edge(sqlgraph.O2M, false, MetasTable, MetasColumn),
  2670  		)
  2671  		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  2672  			for _, p := range preds {
  2673  				p(s)
  2674  			}
  2675  		})
  2676  	})
  2677  }
  2678  
  2679  // And groups predicates with the AND operator between them.
  2680  func And(predicates ...predicate.Alert) predicate.Alert {
  2681  	return predicate.Alert(func(s *sql.Selector) {
  2682  		s1 := s.Clone().SetP(nil)
  2683  		for _, p := range predicates {
  2684  			p(s1)
  2685  		}
  2686  		s.Where(s1.P())
  2687  	})
  2688  }
  2689  
  2690  // Or groups predicates with the OR operator between them.
  2691  func Or(predicates ...predicate.Alert) predicate.Alert {
  2692  	return predicate.Alert(func(s *sql.Selector) {
  2693  		s1 := s.Clone().SetP(nil)
  2694  		for i, p := range predicates {
  2695  			if i > 0 {
  2696  				s1.Or()
  2697  			}
  2698  			p(s1)
  2699  		}
  2700  		s.Where(s1.P())
  2701  	})
  2702  }
  2703  
  2704  // Not applies the not operator on the given predicate.
  2705  func Not(p predicate.Alert) predicate.Alert {
  2706  	return predicate.Alert(func(s *sql.Selector) {
  2707  		p(s.Not())
  2708  	})
  2709  }