1
0
api/ent/users/where.go

2006 lines
56 KiB
Go
Raw Normal View History

2022-08-31 06:18:14 +00:00
// Code generated by entc, DO NOT EDIT.
package users
import (
"t/ent/predicate"
"time"
"entgo.io/ent/dialect/sql"
)
// ID filters vertices based on their ID field.
func ID(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldID), id))
})
}
// IDEQ applies the EQ predicate on the ID field.
func IDEQ(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldID), id))
})
}
// IDNEQ applies the NEQ predicate on the ID field.
func IDNEQ(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldID), id))
})
}
// IDIn applies the In predicate on the ID field.
func IDIn(ids ...int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(ids) == 0 {
s.Where(sql.False())
return
}
v := make([]interface{}, len(ids))
for i := range v {
v[i] = ids[i]
}
s.Where(sql.In(s.C(FieldID), v...))
})
}
// IDNotIn applies the NotIn predicate on the ID field.
func IDNotIn(ids ...int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(ids) == 0 {
s.Where(sql.False())
return
}
v := make([]interface{}, len(ids))
for i := range v {
v[i] = ids[i]
}
s.Where(sql.NotIn(s.C(FieldID), v...))
})
}
// IDGT applies the GT predicate on the ID field.
func IDGT(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldID), id))
})
}
// IDGTE applies the GTE predicate on the ID field.
func IDGTE(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldID), id))
})
}
// IDLT applies the LT predicate on the ID field.
func IDLT(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldID), id))
})
}
// IDLTE applies the LTE predicate on the ID field.
func IDLTE(id int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldID), id))
})
}
// User applies equality check predicate on the "user" field. It's identical to UserEQ.
func User(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldUser), v))
})
}
// Chara applies equality check predicate on the "chara" field. It's identical to CharaEQ.
func Chara(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldChara), v))
})
}
// Skill applies equality check predicate on the "skill" field. It's identical to SkillEQ.
func Skill(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldSkill), v))
})
}
// Hp applies equality check predicate on the "hp" field. It's identical to HpEQ.
func Hp(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldHp), v))
})
}
// Attack applies equality check predicate on the "attack" field. It's identical to AttackEQ.
func Attack(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldAttack), v))
})
}
// Defense applies equality check predicate on the "defense" field. It's identical to DefenseEQ.
func Defense(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldDefense), v))
})
}
// Critical applies equality check predicate on the "critical" field. It's identical to CriticalEQ.
func Critical(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldCritical), v))
})
}
// Battle applies equality check predicate on the "battle" field. It's identical to BattleEQ.
func Battle(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldBattle), v))
})
}
// Win applies equality check predicate on the "win" field. It's identical to WinEQ.
func Win(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldWin), v))
})
}
// Day applies equality check predicate on the "day" field. It's identical to DayEQ.
func Day(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldDay), v))
})
}
// Percentage applies equality check predicate on the "percentage" field. It's identical to PercentageEQ.
func Percentage(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldPercentage), v))
})
}
// Limit applies equality check predicate on the "limit" field. It's identical to LimitEQ.
func Limit(v bool) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldLimit), v))
})
}
// Status applies equality check predicate on the "status" field. It's identical to StatusEQ.
func Status(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldStatus), v))
})
}
// Comment applies equality check predicate on the "comment" field. It's identical to CommentEQ.
func Comment(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldComment), v))
})
}
// CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAt(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldCreatedAt), v))
})
}
// Next applies equality check predicate on the "next" field. It's identical to NextEQ.
func Next(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldNext), v))
})
}
// UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
func UpdatedAt(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldUpdatedAt), v))
})
}
// URL applies equality check predicate on the "url" field. It's identical to URLEQ.
func URL(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldURL), v))
})
}
// UserEQ applies the EQ predicate on the "user" field.
func UserEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldUser), v))
})
}
// UserNEQ applies the NEQ predicate on the "user" field.
func UserNEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldUser), v))
})
}
// UserIn applies the In predicate on the "user" field.
func UserIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldUser), v...))
})
}
// UserNotIn applies the NotIn predicate on the "user" field.
func UserNotIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldUser), v...))
})
}
// UserGT applies the GT predicate on the "user" field.
func UserGT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldUser), v))
})
}
// UserGTE applies the GTE predicate on the "user" field.
func UserGTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldUser), v))
})
}
// UserLT applies the LT predicate on the "user" field.
func UserLT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldUser), v))
})
}
// UserLTE applies the LTE predicate on the "user" field.
func UserLTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldUser), v))
})
}
// UserContains applies the Contains predicate on the "user" field.
func UserContains(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.Contains(s.C(FieldUser), v))
})
}
// UserHasPrefix applies the HasPrefix predicate on the "user" field.
func UserHasPrefix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasPrefix(s.C(FieldUser), v))
})
}
// UserHasSuffix applies the HasSuffix predicate on the "user" field.
func UserHasSuffix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasSuffix(s.C(FieldUser), v))
})
}
// UserEqualFold applies the EqualFold predicate on the "user" field.
func UserEqualFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EqualFold(s.C(FieldUser), v))
})
}
// UserContainsFold applies the ContainsFold predicate on the "user" field.
func UserContainsFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.ContainsFold(s.C(FieldUser), v))
})
}
// CharaEQ applies the EQ predicate on the "chara" field.
func CharaEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldChara), v))
})
}
// CharaNEQ applies the NEQ predicate on the "chara" field.
func CharaNEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldChara), v))
})
}
// CharaIn applies the In predicate on the "chara" field.
func CharaIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldChara), v...))
})
}
// CharaNotIn applies the NotIn predicate on the "chara" field.
func CharaNotIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldChara), v...))
})
}
// CharaGT applies the GT predicate on the "chara" field.
func CharaGT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldChara), v))
})
}
// CharaGTE applies the GTE predicate on the "chara" field.
func CharaGTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldChara), v))
})
}
// CharaLT applies the LT predicate on the "chara" field.
func CharaLT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldChara), v))
})
}
// CharaLTE applies the LTE predicate on the "chara" field.
func CharaLTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldChara), v))
})
}
// CharaContains applies the Contains predicate on the "chara" field.
func CharaContains(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.Contains(s.C(FieldChara), v))
})
}
// CharaHasPrefix applies the HasPrefix predicate on the "chara" field.
func CharaHasPrefix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasPrefix(s.C(FieldChara), v))
})
}
// CharaHasSuffix applies the HasSuffix predicate on the "chara" field.
func CharaHasSuffix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasSuffix(s.C(FieldChara), v))
})
}
// CharaIsNil applies the IsNil predicate on the "chara" field.
func CharaIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldChara)))
})
}
// CharaNotNil applies the NotNil predicate on the "chara" field.
func CharaNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldChara)))
})
}
// CharaEqualFold applies the EqualFold predicate on the "chara" field.
func CharaEqualFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EqualFold(s.C(FieldChara), v))
})
}
// CharaContainsFold applies the ContainsFold predicate on the "chara" field.
func CharaContainsFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.ContainsFold(s.C(FieldChara), v))
})
}
// SkillEQ applies the EQ predicate on the "skill" field.
func SkillEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldSkill), v))
})
}
// SkillNEQ applies the NEQ predicate on the "skill" field.
func SkillNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldSkill), v))
})
}
// SkillIn applies the In predicate on the "skill" field.
func SkillIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldSkill), v...))
})
}
// SkillNotIn applies the NotIn predicate on the "skill" field.
func SkillNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldSkill), v...))
})
}
// SkillGT applies the GT predicate on the "skill" field.
func SkillGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldSkill), v))
})
}
// SkillGTE applies the GTE predicate on the "skill" field.
func SkillGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldSkill), v))
})
}
// SkillLT applies the LT predicate on the "skill" field.
func SkillLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldSkill), v))
})
}
// SkillLTE applies the LTE predicate on the "skill" field.
func SkillLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldSkill), v))
})
}
// SkillIsNil applies the IsNil predicate on the "skill" field.
func SkillIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldSkill)))
})
}
// SkillNotNil applies the NotNil predicate on the "skill" field.
func SkillNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldSkill)))
})
}
// HpEQ applies the EQ predicate on the "hp" field.
func HpEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldHp), v))
})
}
// HpNEQ applies the NEQ predicate on the "hp" field.
func HpNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldHp), v))
})
}
// HpIn applies the In predicate on the "hp" field.
func HpIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldHp), v...))
})
}
// HpNotIn applies the NotIn predicate on the "hp" field.
func HpNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldHp), v...))
})
}
// HpGT applies the GT predicate on the "hp" field.
func HpGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldHp), v))
})
}
// HpGTE applies the GTE predicate on the "hp" field.
func HpGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldHp), v))
})
}
// HpLT applies the LT predicate on the "hp" field.
func HpLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldHp), v))
})
}
// HpLTE applies the LTE predicate on the "hp" field.
func HpLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldHp), v))
})
}
// HpIsNil applies the IsNil predicate on the "hp" field.
func HpIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldHp)))
})
}
// HpNotNil applies the NotNil predicate on the "hp" field.
func HpNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldHp)))
})
}
// AttackEQ applies the EQ predicate on the "attack" field.
func AttackEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldAttack), v))
})
}
// AttackNEQ applies the NEQ predicate on the "attack" field.
func AttackNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldAttack), v))
})
}
// AttackIn applies the In predicate on the "attack" field.
func AttackIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldAttack), v...))
})
}
// AttackNotIn applies the NotIn predicate on the "attack" field.
func AttackNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldAttack), v...))
})
}
// AttackGT applies the GT predicate on the "attack" field.
func AttackGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldAttack), v))
})
}
// AttackGTE applies the GTE predicate on the "attack" field.
func AttackGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldAttack), v))
})
}
// AttackLT applies the LT predicate on the "attack" field.
func AttackLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldAttack), v))
})
}
// AttackLTE applies the LTE predicate on the "attack" field.
func AttackLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldAttack), v))
})
}
// AttackIsNil applies the IsNil predicate on the "attack" field.
func AttackIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldAttack)))
})
}
// AttackNotNil applies the NotNil predicate on the "attack" field.
func AttackNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldAttack)))
})
}
// DefenseEQ applies the EQ predicate on the "defense" field.
func DefenseEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldDefense), v))
})
}
// DefenseNEQ applies the NEQ predicate on the "defense" field.
func DefenseNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldDefense), v))
})
}
// DefenseIn applies the In predicate on the "defense" field.
func DefenseIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldDefense), v...))
})
}
// DefenseNotIn applies the NotIn predicate on the "defense" field.
func DefenseNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldDefense), v...))
})
}
// DefenseGT applies the GT predicate on the "defense" field.
func DefenseGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldDefense), v))
})
}
// DefenseGTE applies the GTE predicate on the "defense" field.
func DefenseGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldDefense), v))
})
}
// DefenseLT applies the LT predicate on the "defense" field.
func DefenseLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldDefense), v))
})
}
// DefenseLTE applies the LTE predicate on the "defense" field.
func DefenseLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldDefense), v))
})
}
// DefenseIsNil applies the IsNil predicate on the "defense" field.
func DefenseIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldDefense)))
})
}
// DefenseNotNil applies the NotNil predicate on the "defense" field.
func DefenseNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldDefense)))
})
}
// CriticalEQ applies the EQ predicate on the "critical" field.
func CriticalEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldCritical), v))
})
}
// CriticalNEQ applies the NEQ predicate on the "critical" field.
func CriticalNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldCritical), v))
})
}
// CriticalIn applies the In predicate on the "critical" field.
func CriticalIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldCritical), v...))
})
}
// CriticalNotIn applies the NotIn predicate on the "critical" field.
func CriticalNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldCritical), v...))
})
}
// CriticalGT applies the GT predicate on the "critical" field.
func CriticalGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldCritical), v))
})
}
// CriticalGTE applies the GTE predicate on the "critical" field.
func CriticalGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldCritical), v))
})
}
// CriticalLT applies the LT predicate on the "critical" field.
func CriticalLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldCritical), v))
})
}
// CriticalLTE applies the LTE predicate on the "critical" field.
func CriticalLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldCritical), v))
})
}
// CriticalIsNil applies the IsNil predicate on the "critical" field.
func CriticalIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldCritical)))
})
}
// CriticalNotNil applies the NotNil predicate on the "critical" field.
func CriticalNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldCritical)))
})
}
// BattleEQ applies the EQ predicate on the "battle" field.
func BattleEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldBattle), v))
})
}
// BattleNEQ applies the NEQ predicate on the "battle" field.
func BattleNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldBattle), v))
})
}
// BattleIn applies the In predicate on the "battle" field.
func BattleIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldBattle), v...))
})
}
// BattleNotIn applies the NotIn predicate on the "battle" field.
func BattleNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldBattle), v...))
})
}
// BattleGT applies the GT predicate on the "battle" field.
func BattleGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldBattle), v))
})
}
// BattleGTE applies the GTE predicate on the "battle" field.
func BattleGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldBattle), v))
})
}
// BattleLT applies the LT predicate on the "battle" field.
func BattleLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldBattle), v))
})
}
// BattleLTE applies the LTE predicate on the "battle" field.
func BattleLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldBattle), v))
})
}
// BattleIsNil applies the IsNil predicate on the "battle" field.
func BattleIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldBattle)))
})
}
// BattleNotNil applies the NotNil predicate on the "battle" field.
func BattleNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldBattle)))
})
}
// WinEQ applies the EQ predicate on the "win" field.
func WinEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldWin), v))
})
}
// WinNEQ applies the NEQ predicate on the "win" field.
func WinNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldWin), v))
})
}
// WinIn applies the In predicate on the "win" field.
func WinIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldWin), v...))
})
}
// WinNotIn applies the NotIn predicate on the "win" field.
func WinNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldWin), v...))
})
}
// WinGT applies the GT predicate on the "win" field.
func WinGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldWin), v))
})
}
// WinGTE applies the GTE predicate on the "win" field.
func WinGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldWin), v))
})
}
// WinLT applies the LT predicate on the "win" field.
func WinLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldWin), v))
})
}
// WinLTE applies the LTE predicate on the "win" field.
func WinLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldWin), v))
})
}
// WinIsNil applies the IsNil predicate on the "win" field.
func WinIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldWin)))
})
}
// WinNotNil applies the NotNil predicate on the "win" field.
func WinNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldWin)))
})
}
// DayEQ applies the EQ predicate on the "day" field.
func DayEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldDay), v))
})
}
// DayNEQ applies the NEQ predicate on the "day" field.
func DayNEQ(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldDay), v))
})
}
// DayIn applies the In predicate on the "day" field.
func DayIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldDay), v...))
})
}
// DayNotIn applies the NotIn predicate on the "day" field.
func DayNotIn(vs ...int) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldDay), v...))
})
}
// DayGT applies the GT predicate on the "day" field.
func DayGT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldDay), v))
})
}
// DayGTE applies the GTE predicate on the "day" field.
func DayGTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldDay), v))
})
}
// DayLT applies the LT predicate on the "day" field.
func DayLT(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldDay), v))
})
}
// DayLTE applies the LTE predicate on the "day" field.
func DayLTE(v int) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldDay), v))
})
}
// DayIsNil applies the IsNil predicate on the "day" field.
func DayIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldDay)))
})
}
// DayNotNil applies the NotNil predicate on the "day" field.
func DayNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldDay)))
})
}
// PercentageEQ applies the EQ predicate on the "percentage" field.
func PercentageEQ(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldPercentage), v))
})
}
// PercentageNEQ applies the NEQ predicate on the "percentage" field.
func PercentageNEQ(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldPercentage), v))
})
}
// PercentageIn applies the In predicate on the "percentage" field.
func PercentageIn(vs ...float64) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldPercentage), v...))
})
}
// PercentageNotIn applies the NotIn predicate on the "percentage" field.
func PercentageNotIn(vs ...float64) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldPercentage), v...))
})
}
// PercentageGT applies the GT predicate on the "percentage" field.
func PercentageGT(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldPercentage), v))
})
}
// PercentageGTE applies the GTE predicate on the "percentage" field.
func PercentageGTE(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldPercentage), v))
})
}
// PercentageLT applies the LT predicate on the "percentage" field.
func PercentageLT(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldPercentage), v))
})
}
// PercentageLTE applies the LTE predicate on the "percentage" field.
func PercentageLTE(v float64) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldPercentage), v))
})
}
// PercentageIsNil applies the IsNil predicate on the "percentage" field.
func PercentageIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldPercentage)))
})
}
// PercentageNotNil applies the NotNil predicate on the "percentage" field.
func PercentageNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldPercentage)))
})
}
// LimitEQ applies the EQ predicate on the "limit" field.
func LimitEQ(v bool) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldLimit), v))
})
}
// LimitNEQ applies the NEQ predicate on the "limit" field.
func LimitNEQ(v bool) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldLimit), v))
})
}
// LimitIsNil applies the IsNil predicate on the "limit" field.
func LimitIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldLimit)))
})
}
// LimitNotNil applies the NotNil predicate on the "limit" field.
func LimitNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldLimit)))
})
}
// StatusEQ applies the EQ predicate on the "status" field.
func StatusEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldStatus), v))
})
}
// StatusNEQ applies the NEQ predicate on the "status" field.
func StatusNEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldStatus), v))
})
}
// StatusIn applies the In predicate on the "status" field.
func StatusIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldStatus), v...))
})
}
// StatusNotIn applies the NotIn predicate on the "status" field.
func StatusNotIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldStatus), v...))
})
}
// StatusGT applies the GT predicate on the "status" field.
func StatusGT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldStatus), v))
})
}
// StatusGTE applies the GTE predicate on the "status" field.
func StatusGTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldStatus), v))
})
}
// StatusLT applies the LT predicate on the "status" field.
func StatusLT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldStatus), v))
})
}
// StatusLTE applies the LTE predicate on the "status" field.
func StatusLTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldStatus), v))
})
}
// StatusContains applies the Contains predicate on the "status" field.
func StatusContains(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.Contains(s.C(FieldStatus), v))
})
}
// StatusHasPrefix applies the HasPrefix predicate on the "status" field.
func StatusHasPrefix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasPrefix(s.C(FieldStatus), v))
})
}
// StatusHasSuffix applies the HasSuffix predicate on the "status" field.
func StatusHasSuffix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasSuffix(s.C(FieldStatus), v))
})
}
// StatusIsNil applies the IsNil predicate on the "status" field.
func StatusIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldStatus)))
})
}
// StatusNotNil applies the NotNil predicate on the "status" field.
func StatusNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldStatus)))
})
}
// StatusEqualFold applies the EqualFold predicate on the "status" field.
func StatusEqualFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EqualFold(s.C(FieldStatus), v))
})
}
// StatusContainsFold applies the ContainsFold predicate on the "status" field.
func StatusContainsFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.ContainsFold(s.C(FieldStatus), v))
})
}
// CommentEQ applies the EQ predicate on the "comment" field.
func CommentEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldComment), v))
})
}
// CommentNEQ applies the NEQ predicate on the "comment" field.
func CommentNEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldComment), v))
})
}
// CommentIn applies the In predicate on the "comment" field.
func CommentIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldComment), v...))
})
}
// CommentNotIn applies the NotIn predicate on the "comment" field.
func CommentNotIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldComment), v...))
})
}
// CommentGT applies the GT predicate on the "comment" field.
func CommentGT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldComment), v))
})
}
// CommentGTE applies the GTE predicate on the "comment" field.
func CommentGTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldComment), v))
})
}
// CommentLT applies the LT predicate on the "comment" field.
func CommentLT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldComment), v))
})
}
// CommentLTE applies the LTE predicate on the "comment" field.
func CommentLTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldComment), v))
})
}
// CommentContains applies the Contains predicate on the "comment" field.
func CommentContains(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.Contains(s.C(FieldComment), v))
})
}
// CommentHasPrefix applies the HasPrefix predicate on the "comment" field.
func CommentHasPrefix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasPrefix(s.C(FieldComment), v))
})
}
// CommentHasSuffix applies the HasSuffix predicate on the "comment" field.
func CommentHasSuffix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasSuffix(s.C(FieldComment), v))
})
}
// CommentIsNil applies the IsNil predicate on the "comment" field.
func CommentIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldComment)))
})
}
// CommentNotNil applies the NotNil predicate on the "comment" field.
func CommentNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldComment)))
})
}
// CommentEqualFold applies the EqualFold predicate on the "comment" field.
func CommentEqualFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EqualFold(s.C(FieldComment), v))
})
}
// CommentContainsFold applies the ContainsFold predicate on the "comment" field.
func CommentContainsFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.ContainsFold(s.C(FieldComment), v))
})
}
// CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtEQ(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldCreatedAt), v))
})
}
// CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNEQ(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldCreatedAt), v))
})
}
// CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtIn(vs ...time.Time) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldCreatedAt), v...))
})
}
// CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func CreatedAtNotIn(vs ...time.Time) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldCreatedAt), v...))
})
}
// CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGT(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldCreatedAt), v))
})
}
// CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtGTE(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldCreatedAt), v))
})
}
// CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLT(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldCreatedAt), v))
})
}
// CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtLTE(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldCreatedAt), v))
})
}
// CreatedAtIsNil applies the IsNil predicate on the "created_at" field.
func CreatedAtIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldCreatedAt)))
})
}
// CreatedAtNotNil applies the NotNil predicate on the "created_at" field.
func CreatedAtNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldCreatedAt)))
})
}
// NextEQ applies the EQ predicate on the "next" field.
func NextEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldNext), v))
})
}
// NextNEQ applies the NEQ predicate on the "next" field.
func NextNEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldNext), v))
})
}
// NextIn applies the In predicate on the "next" field.
func NextIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldNext), v...))
})
}
// NextNotIn applies the NotIn predicate on the "next" field.
func NextNotIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldNext), v...))
})
}
// NextGT applies the GT predicate on the "next" field.
func NextGT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldNext), v))
})
}
// NextGTE applies the GTE predicate on the "next" field.
func NextGTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldNext), v))
})
}
// NextLT applies the LT predicate on the "next" field.
func NextLT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldNext), v))
})
}
// NextLTE applies the LTE predicate on the "next" field.
func NextLTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldNext), v))
})
}
// NextContains applies the Contains predicate on the "next" field.
func NextContains(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.Contains(s.C(FieldNext), v))
})
}
// NextHasPrefix applies the HasPrefix predicate on the "next" field.
func NextHasPrefix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasPrefix(s.C(FieldNext), v))
})
}
// NextHasSuffix applies the HasSuffix predicate on the "next" field.
func NextHasSuffix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasSuffix(s.C(FieldNext), v))
})
}
// NextIsNil applies the IsNil predicate on the "next" field.
func NextIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldNext)))
})
}
// NextNotNil applies the NotNil predicate on the "next" field.
func NextNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldNext)))
})
}
// NextEqualFold applies the EqualFold predicate on the "next" field.
func NextEqualFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EqualFold(s.C(FieldNext), v))
})
}
// NextContainsFold applies the ContainsFold predicate on the "next" field.
func NextContainsFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.ContainsFold(s.C(FieldNext), v))
})
}
// UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtEQ(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldUpdatedAt), v))
})
}
// UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNEQ(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldUpdatedAt), v))
})
}
// UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtIn(vs ...time.Time) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldUpdatedAt), v...))
})
}
// UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func UpdatedAtNotIn(vs ...time.Time) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldUpdatedAt), v...))
})
}
// UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGT(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldUpdatedAt), v))
})
}
// UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtGTE(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldUpdatedAt), v))
})
}
// UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLT(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldUpdatedAt), v))
})
}
// UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtLTE(v time.Time) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldUpdatedAt), v))
})
}
// UpdatedAtIsNil applies the IsNil predicate on the "updated_at" field.
func UpdatedAtIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldUpdatedAt)))
})
}
// UpdatedAtNotNil applies the NotNil predicate on the "updated_at" field.
func UpdatedAtNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldUpdatedAt)))
})
}
// URLEQ applies the EQ predicate on the "url" field.
func URLEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EQ(s.C(FieldURL), v))
})
}
// URLNEQ applies the NEQ predicate on the "url" field.
func URLNEQ(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NEQ(s.C(FieldURL), v))
})
}
// URLIn applies the In predicate on the "url" field.
func URLIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.In(s.C(FieldURL), v...))
})
}
// URLNotIn applies the NotIn predicate on the "url" field.
func URLNotIn(vs ...string) predicate.Users {
v := make([]interface{}, len(vs))
for i := range v {
v[i] = vs[i]
}
return predicate.Users(func(s *sql.Selector) {
// if not arguments were provided, append the FALSE constants,
// since we can't apply "IN ()". This will make this predicate falsy.
if len(v) == 0 {
s.Where(sql.False())
return
}
s.Where(sql.NotIn(s.C(FieldURL), v...))
})
}
// URLGT applies the GT predicate on the "url" field.
func URLGT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GT(s.C(FieldURL), v))
})
}
// URLGTE applies the GTE predicate on the "url" field.
func URLGTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.GTE(s.C(FieldURL), v))
})
}
// URLLT applies the LT predicate on the "url" field.
func URLLT(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LT(s.C(FieldURL), v))
})
}
// URLLTE applies the LTE predicate on the "url" field.
func URLLTE(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.LTE(s.C(FieldURL), v))
})
}
// URLContains applies the Contains predicate on the "url" field.
func URLContains(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.Contains(s.C(FieldURL), v))
})
}
// URLHasPrefix applies the HasPrefix predicate on the "url" field.
func URLHasPrefix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasPrefix(s.C(FieldURL), v))
})
}
// URLHasSuffix applies the HasSuffix predicate on the "url" field.
func URLHasSuffix(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.HasSuffix(s.C(FieldURL), v))
})
}
// URLIsNil applies the IsNil predicate on the "url" field.
func URLIsNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.IsNull(s.C(FieldURL)))
})
}
// URLNotNil applies the NotNil predicate on the "url" field.
func URLNotNil() predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.NotNull(s.C(FieldURL)))
})
}
// URLEqualFold applies the EqualFold predicate on the "url" field.
func URLEqualFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.EqualFold(s.C(FieldURL), v))
})
}
// URLContainsFold applies the ContainsFold predicate on the "url" field.
func URLContainsFold(v string) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s.Where(sql.ContainsFold(s.C(FieldURL), v))
})
}
// And groups predicates with the AND operator between them.
func And(predicates ...predicate.Users) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s1 := s.Clone().SetP(nil)
for _, p := range predicates {
p(s1)
}
s.Where(s1.P())
})
}
// Or groups predicates with the OR operator between them.
func Or(predicates ...predicate.Users) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
s1 := s.Clone().SetP(nil)
for i, p := range predicates {
if i > 0 {
s1.Or()
}
p(s1)
}
s.Where(s1.P())
})
}
// Not applies the not operator on the given predicate.
func Not(p predicate.Users) predicate.Users {
return predicate.Users(func(s *sql.Selector) {
p(s.Not())
})
}