github.com/crowdsecurity/crowdsec@v1.6.1/pkg/database/ent/configitem/where.go (about)

     1  // Code generated by ent, DO NOT EDIT.
     2  
     3  package configitem
     4  
     5  import (
     6  	"time"
     7  
     8  	"entgo.io/ent/dialect/sql"
     9  	"github.com/crowdsecurity/crowdsec/pkg/database/ent/predicate"
    10  )
    11  
    12  // ID filters vertices based on their ID field.
    13  func ID(id int) predicate.ConfigItem {
    14  	return predicate.ConfigItem(sql.FieldEQ(FieldID, id))
    15  }
    16  
    17  // IDEQ applies the EQ predicate on the ID field.
    18  func IDEQ(id int) predicate.ConfigItem {
    19  	return predicate.ConfigItem(sql.FieldEQ(FieldID, id))
    20  }
    21  
    22  // IDNEQ applies the NEQ predicate on the ID field.
    23  func IDNEQ(id int) predicate.ConfigItem {
    24  	return predicate.ConfigItem(sql.FieldNEQ(FieldID, id))
    25  }
    26  
    27  // IDIn applies the In predicate on the ID field.
    28  func IDIn(ids ...int) predicate.ConfigItem {
    29  	return predicate.ConfigItem(sql.FieldIn(FieldID, ids...))
    30  }
    31  
    32  // IDNotIn applies the NotIn predicate on the ID field.
    33  func IDNotIn(ids ...int) predicate.ConfigItem {
    34  	return predicate.ConfigItem(sql.FieldNotIn(FieldID, ids...))
    35  }
    36  
    37  // IDGT applies the GT predicate on the ID field.
    38  func IDGT(id int) predicate.ConfigItem {
    39  	return predicate.ConfigItem(sql.FieldGT(FieldID, id))
    40  }
    41  
    42  // IDGTE applies the GTE predicate on the ID field.
    43  func IDGTE(id int) predicate.ConfigItem {
    44  	return predicate.ConfigItem(sql.FieldGTE(FieldID, id))
    45  }
    46  
    47  // IDLT applies the LT predicate on the ID field.
    48  func IDLT(id int) predicate.ConfigItem {
    49  	return predicate.ConfigItem(sql.FieldLT(FieldID, id))
    50  }
    51  
    52  // IDLTE applies the LTE predicate on the ID field.
    53  func IDLTE(id int) predicate.ConfigItem {
    54  	return predicate.ConfigItem(sql.FieldLTE(FieldID, id))
    55  }
    56  
    57  // CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
    58  func CreatedAt(v time.Time) predicate.ConfigItem {
    59  	return predicate.ConfigItem(sql.FieldEQ(FieldCreatedAt, v))
    60  }
    61  
    62  // UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
    63  func UpdatedAt(v time.Time) predicate.ConfigItem {
    64  	return predicate.ConfigItem(sql.FieldEQ(FieldUpdatedAt, v))
    65  }
    66  
    67  // Name applies equality check predicate on the "name" field. It's identical to NameEQ.
    68  func Name(v string) predicate.ConfigItem {
    69  	return predicate.ConfigItem(sql.FieldEQ(FieldName, v))
    70  }
    71  
    72  // Value applies equality check predicate on the "value" field. It's identical to ValueEQ.
    73  func Value(v string) predicate.ConfigItem {
    74  	return predicate.ConfigItem(sql.FieldEQ(FieldValue, v))
    75  }
    76  
    77  // CreatedAtEQ applies the EQ predicate on the "created_at" field.
    78  func CreatedAtEQ(v time.Time) predicate.ConfigItem {
    79  	return predicate.ConfigItem(sql.FieldEQ(FieldCreatedAt, v))
    80  }
    81  
    82  // CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
    83  func CreatedAtNEQ(v time.Time) predicate.ConfigItem {
    84  	return predicate.ConfigItem(sql.FieldNEQ(FieldCreatedAt, v))
    85  }
    86  
    87  // CreatedAtIn applies the In predicate on the "created_at" field.
    88  func CreatedAtIn(vs ...time.Time) predicate.ConfigItem {
    89  	return predicate.ConfigItem(sql.FieldIn(FieldCreatedAt, vs...))
    90  }
    91  
    92  // CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
    93  func CreatedAtNotIn(vs ...time.Time) predicate.ConfigItem {
    94  	return predicate.ConfigItem(sql.FieldNotIn(FieldCreatedAt, vs...))
    95  }
    96  
    97  // CreatedAtGT applies the GT predicate on the "created_at" field.
    98  func CreatedAtGT(v time.Time) predicate.ConfigItem {
    99  	return predicate.ConfigItem(sql.FieldGT(FieldCreatedAt, v))
   100  }
   101  
   102  // CreatedAtGTE applies the GTE predicate on the "created_at" field.
   103  func CreatedAtGTE(v time.Time) predicate.ConfigItem {
   104  	return predicate.ConfigItem(sql.FieldGTE(FieldCreatedAt, v))
   105  }
   106  
   107  // CreatedAtLT applies the LT predicate on the "created_at" field.
   108  func CreatedAtLT(v time.Time) predicate.ConfigItem {
   109  	return predicate.ConfigItem(sql.FieldLT(FieldCreatedAt, v))
   110  }
   111  
   112  // CreatedAtLTE applies the LTE predicate on the "created_at" field.
   113  func CreatedAtLTE(v time.Time) predicate.ConfigItem {
   114  	return predicate.ConfigItem(sql.FieldLTE(FieldCreatedAt, v))
   115  }
   116  
   117  // CreatedAtIsNil applies the IsNil predicate on the "created_at" field.
   118  func CreatedAtIsNil() predicate.ConfigItem {
   119  	return predicate.ConfigItem(sql.FieldIsNull(FieldCreatedAt))
   120  }
   121  
   122  // CreatedAtNotNil applies the NotNil predicate on the "created_at" field.
   123  func CreatedAtNotNil() predicate.ConfigItem {
   124  	return predicate.ConfigItem(sql.FieldNotNull(FieldCreatedAt))
   125  }
   126  
   127  // UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
   128  func UpdatedAtEQ(v time.Time) predicate.ConfigItem {
   129  	return predicate.ConfigItem(sql.FieldEQ(FieldUpdatedAt, v))
   130  }
   131  
   132  // UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
   133  func UpdatedAtNEQ(v time.Time) predicate.ConfigItem {
   134  	return predicate.ConfigItem(sql.FieldNEQ(FieldUpdatedAt, v))
   135  }
   136  
   137  // UpdatedAtIn applies the In predicate on the "updated_at" field.
   138  func UpdatedAtIn(vs ...time.Time) predicate.ConfigItem {
   139  	return predicate.ConfigItem(sql.FieldIn(FieldUpdatedAt, vs...))
   140  }
   141  
   142  // UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
   143  func UpdatedAtNotIn(vs ...time.Time) predicate.ConfigItem {
   144  	return predicate.ConfigItem(sql.FieldNotIn(FieldUpdatedAt, vs...))
   145  }
   146  
   147  // UpdatedAtGT applies the GT predicate on the "updated_at" field.
   148  func UpdatedAtGT(v time.Time) predicate.ConfigItem {
   149  	return predicate.ConfigItem(sql.FieldGT(FieldUpdatedAt, v))
   150  }
   151  
   152  // UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
   153  func UpdatedAtGTE(v time.Time) predicate.ConfigItem {
   154  	return predicate.ConfigItem(sql.FieldGTE(FieldUpdatedAt, v))
   155  }
   156  
   157  // UpdatedAtLT applies the LT predicate on the "updated_at" field.
   158  func UpdatedAtLT(v time.Time) predicate.ConfigItem {
   159  	return predicate.ConfigItem(sql.FieldLT(FieldUpdatedAt, v))
   160  }
   161  
   162  // UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
   163  func UpdatedAtLTE(v time.Time) predicate.ConfigItem {
   164  	return predicate.ConfigItem(sql.FieldLTE(FieldUpdatedAt, v))
   165  }
   166  
   167  // UpdatedAtIsNil applies the IsNil predicate on the "updated_at" field.
   168  func UpdatedAtIsNil() predicate.ConfigItem {
   169  	return predicate.ConfigItem(sql.FieldIsNull(FieldUpdatedAt))
   170  }
   171  
   172  // UpdatedAtNotNil applies the NotNil predicate on the "updated_at" field.
   173  func UpdatedAtNotNil() predicate.ConfigItem {
   174  	return predicate.ConfigItem(sql.FieldNotNull(FieldUpdatedAt))
   175  }
   176  
   177  // NameEQ applies the EQ predicate on the "name" field.
   178  func NameEQ(v string) predicate.ConfigItem {
   179  	return predicate.ConfigItem(sql.FieldEQ(FieldName, v))
   180  }
   181  
   182  // NameNEQ applies the NEQ predicate on the "name" field.
   183  func NameNEQ(v string) predicate.ConfigItem {
   184  	return predicate.ConfigItem(sql.FieldNEQ(FieldName, v))
   185  }
   186  
   187  // NameIn applies the In predicate on the "name" field.
   188  func NameIn(vs ...string) predicate.ConfigItem {
   189  	return predicate.ConfigItem(sql.FieldIn(FieldName, vs...))
   190  }
   191  
   192  // NameNotIn applies the NotIn predicate on the "name" field.
   193  func NameNotIn(vs ...string) predicate.ConfigItem {
   194  	return predicate.ConfigItem(sql.FieldNotIn(FieldName, vs...))
   195  }
   196  
   197  // NameGT applies the GT predicate on the "name" field.
   198  func NameGT(v string) predicate.ConfigItem {
   199  	return predicate.ConfigItem(sql.FieldGT(FieldName, v))
   200  }
   201  
   202  // NameGTE applies the GTE predicate on the "name" field.
   203  func NameGTE(v string) predicate.ConfigItem {
   204  	return predicate.ConfigItem(sql.FieldGTE(FieldName, v))
   205  }
   206  
   207  // NameLT applies the LT predicate on the "name" field.
   208  func NameLT(v string) predicate.ConfigItem {
   209  	return predicate.ConfigItem(sql.FieldLT(FieldName, v))
   210  }
   211  
   212  // NameLTE applies the LTE predicate on the "name" field.
   213  func NameLTE(v string) predicate.ConfigItem {
   214  	return predicate.ConfigItem(sql.FieldLTE(FieldName, v))
   215  }
   216  
   217  // NameContains applies the Contains predicate on the "name" field.
   218  func NameContains(v string) predicate.ConfigItem {
   219  	return predicate.ConfigItem(sql.FieldContains(FieldName, v))
   220  }
   221  
   222  // NameHasPrefix applies the HasPrefix predicate on the "name" field.
   223  func NameHasPrefix(v string) predicate.ConfigItem {
   224  	return predicate.ConfigItem(sql.FieldHasPrefix(FieldName, v))
   225  }
   226  
   227  // NameHasSuffix applies the HasSuffix predicate on the "name" field.
   228  func NameHasSuffix(v string) predicate.ConfigItem {
   229  	return predicate.ConfigItem(sql.FieldHasSuffix(FieldName, v))
   230  }
   231  
   232  // NameEqualFold applies the EqualFold predicate on the "name" field.
   233  func NameEqualFold(v string) predicate.ConfigItem {
   234  	return predicate.ConfigItem(sql.FieldEqualFold(FieldName, v))
   235  }
   236  
   237  // NameContainsFold applies the ContainsFold predicate on the "name" field.
   238  func NameContainsFold(v string) predicate.ConfigItem {
   239  	return predicate.ConfigItem(sql.FieldContainsFold(FieldName, v))
   240  }
   241  
   242  // ValueEQ applies the EQ predicate on the "value" field.
   243  func ValueEQ(v string) predicate.ConfigItem {
   244  	return predicate.ConfigItem(sql.FieldEQ(FieldValue, v))
   245  }
   246  
   247  // ValueNEQ applies the NEQ predicate on the "value" field.
   248  func ValueNEQ(v string) predicate.ConfigItem {
   249  	return predicate.ConfigItem(sql.FieldNEQ(FieldValue, v))
   250  }
   251  
   252  // ValueIn applies the In predicate on the "value" field.
   253  func ValueIn(vs ...string) predicate.ConfigItem {
   254  	return predicate.ConfigItem(sql.FieldIn(FieldValue, vs...))
   255  }
   256  
   257  // ValueNotIn applies the NotIn predicate on the "value" field.
   258  func ValueNotIn(vs ...string) predicate.ConfigItem {
   259  	return predicate.ConfigItem(sql.FieldNotIn(FieldValue, vs...))
   260  }
   261  
   262  // ValueGT applies the GT predicate on the "value" field.
   263  func ValueGT(v string) predicate.ConfigItem {
   264  	return predicate.ConfigItem(sql.FieldGT(FieldValue, v))
   265  }
   266  
   267  // ValueGTE applies the GTE predicate on the "value" field.
   268  func ValueGTE(v string) predicate.ConfigItem {
   269  	return predicate.ConfigItem(sql.FieldGTE(FieldValue, v))
   270  }
   271  
   272  // ValueLT applies the LT predicate on the "value" field.
   273  func ValueLT(v string) predicate.ConfigItem {
   274  	return predicate.ConfigItem(sql.FieldLT(FieldValue, v))
   275  }
   276  
   277  // ValueLTE applies the LTE predicate on the "value" field.
   278  func ValueLTE(v string) predicate.ConfigItem {
   279  	return predicate.ConfigItem(sql.FieldLTE(FieldValue, v))
   280  }
   281  
   282  // ValueContains applies the Contains predicate on the "value" field.
   283  func ValueContains(v string) predicate.ConfigItem {
   284  	return predicate.ConfigItem(sql.FieldContains(FieldValue, v))
   285  }
   286  
   287  // ValueHasPrefix applies the HasPrefix predicate on the "value" field.
   288  func ValueHasPrefix(v string) predicate.ConfigItem {
   289  	return predicate.ConfigItem(sql.FieldHasPrefix(FieldValue, v))
   290  }
   291  
   292  // ValueHasSuffix applies the HasSuffix predicate on the "value" field.
   293  func ValueHasSuffix(v string) predicate.ConfigItem {
   294  	return predicate.ConfigItem(sql.FieldHasSuffix(FieldValue, v))
   295  }
   296  
   297  // ValueEqualFold applies the EqualFold predicate on the "value" field.
   298  func ValueEqualFold(v string) predicate.ConfigItem {
   299  	return predicate.ConfigItem(sql.FieldEqualFold(FieldValue, v))
   300  }
   301  
   302  // ValueContainsFold applies the ContainsFold predicate on the "value" field.
   303  func ValueContainsFold(v string) predicate.ConfigItem {
   304  	return predicate.ConfigItem(sql.FieldContainsFold(FieldValue, v))
   305  }
   306  
   307  // And groups predicates with the AND operator between them.
   308  func And(predicates ...predicate.ConfigItem) predicate.ConfigItem {
   309  	return predicate.ConfigItem(sql.AndPredicates(predicates...))
   310  }
   311  
   312  // Or groups predicates with the OR operator between them.
   313  func Or(predicates ...predicate.ConfigItem) predicate.ConfigItem {
   314  	return predicate.ConfigItem(sql.OrPredicates(predicates...))
   315  }
   316  
   317  // Not applies the not operator on the given predicate.
   318  func Not(p predicate.ConfigItem) predicate.ConfigItem {
   319  	return predicate.ConfigItem(sql.NotPredicates(p))
   320  }