// Code generated by ent, DO NOT EDIT.

package invitecode

import (
	"time"

	"entgo.io/ent/dialect/sql"
	"github.com/chaitin/MonkeyCode/backend/consts"
	"github.com/chaitin/MonkeyCode/backend/db/predicate"
	"github.com/google/uuid"
)

// ID filters vertices based on their ID field.
func ID(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldID, id))
}

// IDEQ applies the EQ predicate on the ID field.
func IDEQ(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldID, id))
}

// IDNEQ applies the NEQ predicate on the ID field.
func IDNEQ(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNEQ(FieldID, id))
}

// IDIn applies the In predicate on the ID field.
func IDIn(ids ...uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldIn(FieldID, ids...))
}

// IDNotIn applies the NotIn predicate on the ID field.
func IDNotIn(ids ...uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNotIn(FieldID, ids...))
}

// IDGT applies the GT predicate on the ID field.
func IDGT(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGT(FieldID, id))
}

// IDGTE applies the GTE predicate on the ID field.
func IDGTE(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGTE(FieldID, id))
}

// IDLT applies the LT predicate on the ID field.
func IDLT(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLT(FieldID, id))
}

// IDLTE applies the LTE predicate on the ID field.
func IDLTE(id uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLTE(FieldID, id))
}

// AdminID applies equality check predicate on the "admin_id" field. It's identical to AdminIDEQ.
func AdminID(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldAdminID, v))
}

// Code applies equality check predicate on the "code" field. It's identical to CodeEQ.
func Code(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldCode, v))
}

// Status applies equality check predicate on the "status" field. It's identical to StatusEQ.
func Status(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldEQ(FieldStatus, vc))
}

// CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAt(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldCreatedAt, v))
}

// UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
func UpdatedAt(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldUpdatedAt, v))
}

// ExpiredAt applies equality check predicate on the "expired_at" field. It's identical to ExpiredAtEQ.
func ExpiredAt(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldExpiredAt, v))
}

// AdminIDEQ applies the EQ predicate on the "admin_id" field.
func AdminIDEQ(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldAdminID, v))
}

// AdminIDNEQ applies the NEQ predicate on the "admin_id" field.
func AdminIDNEQ(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNEQ(FieldAdminID, v))
}

// AdminIDIn applies the In predicate on the "admin_id" field.
func AdminIDIn(vs ...uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldIn(FieldAdminID, vs...))
}

// AdminIDNotIn applies the NotIn predicate on the "admin_id" field.
func AdminIDNotIn(vs ...uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNotIn(FieldAdminID, vs...))
}

// AdminIDGT applies the GT predicate on the "admin_id" field.
func AdminIDGT(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGT(FieldAdminID, v))
}

// AdminIDGTE applies the GTE predicate on the "admin_id" field.
func AdminIDGTE(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGTE(FieldAdminID, v))
}

// AdminIDLT applies the LT predicate on the "admin_id" field.
func AdminIDLT(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLT(FieldAdminID, v))
}

// AdminIDLTE applies the LTE predicate on the "admin_id" field.
func AdminIDLTE(v uuid.UUID) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLTE(FieldAdminID, v))
}

// CodeEQ applies the EQ predicate on the "code" field.
func CodeEQ(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldCode, v))
}

// CodeNEQ applies the NEQ predicate on the "code" field.
func CodeNEQ(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNEQ(FieldCode, v))
}

// CodeIn applies the In predicate on the "code" field.
func CodeIn(vs ...string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldIn(FieldCode, vs...))
}

// CodeNotIn applies the NotIn predicate on the "code" field.
func CodeNotIn(vs ...string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNotIn(FieldCode, vs...))
}

// CodeGT applies the GT predicate on the "code" field.
func CodeGT(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGT(FieldCode, v))
}

// CodeGTE applies the GTE predicate on the "code" field.
func CodeGTE(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGTE(FieldCode, v))
}

// CodeLT applies the LT predicate on the "code" field.
func CodeLT(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLT(FieldCode, v))
}

// CodeLTE applies the LTE predicate on the "code" field.
func CodeLTE(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLTE(FieldCode, v))
}

// CodeContains applies the Contains predicate on the "code" field.
func CodeContains(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldContains(FieldCode, v))
}

// CodeHasPrefix applies the HasPrefix predicate on the "code" field.
func CodeHasPrefix(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldHasPrefix(FieldCode, v))
}

// CodeHasSuffix applies the HasSuffix predicate on the "code" field.
func CodeHasSuffix(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldHasSuffix(FieldCode, v))
}

// CodeEqualFold applies the EqualFold predicate on the "code" field.
func CodeEqualFold(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEqualFold(FieldCode, v))
}

// CodeContainsFold applies the ContainsFold predicate on the "code" field.
func CodeContainsFold(v string) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldContainsFold(FieldCode, v))
}

// StatusEQ applies the EQ predicate on the "status" field.
func StatusEQ(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldEQ(FieldStatus, vc))
}

// StatusNEQ applies the NEQ predicate on the "status" field.
func StatusNEQ(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldNEQ(FieldStatus, vc))
}

// StatusIn applies the In predicate on the "status" field.
func StatusIn(vs ...consts.InviteCodeStatus) predicate.InviteCode {
	v := make([]any, len(vs))
	for i := range v {
		v[i] = string(vs[i])
	}
	return predicate.InviteCode(sql.FieldIn(FieldStatus, v...))
}

// StatusNotIn applies the NotIn predicate on the "status" field.
func StatusNotIn(vs ...consts.InviteCodeStatus) predicate.InviteCode {
	v := make([]any, len(vs))
	for i := range v {
		v[i] = string(vs[i])
	}
	return predicate.InviteCode(sql.FieldNotIn(FieldStatus, v...))
}

// StatusGT applies the GT predicate on the "status" field.
func StatusGT(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldGT(FieldStatus, vc))
}

// StatusGTE applies the GTE predicate on the "status" field.
func StatusGTE(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldGTE(FieldStatus, vc))
}

// StatusLT applies the LT predicate on the "status" field.
func StatusLT(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldLT(FieldStatus, vc))
}

// StatusLTE applies the LTE predicate on the "status" field.
func StatusLTE(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldLTE(FieldStatus, vc))
}

// StatusContains applies the Contains predicate on the "status" field.
func StatusContains(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldContains(FieldStatus, vc))
}

// StatusHasPrefix applies the HasPrefix predicate on the "status" field.
func StatusHasPrefix(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldHasPrefix(FieldStatus, vc))
}

// StatusHasSuffix applies the HasSuffix predicate on the "status" field.
func StatusHasSuffix(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldHasSuffix(FieldStatus, vc))
}

// StatusEqualFold applies the EqualFold predicate on the "status" field.
func StatusEqualFold(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldEqualFold(FieldStatus, vc))
}

// StatusContainsFold applies the ContainsFold predicate on the "status" field.
func StatusContainsFold(v consts.InviteCodeStatus) predicate.InviteCode {
	vc := string(v)
	return predicate.InviteCode(sql.FieldContainsFold(FieldStatus, vc))
}

// CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtEQ(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldCreatedAt, v))
}

// CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNEQ(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNEQ(FieldCreatedAt, v))
}

// CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtIn(vs ...time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldIn(FieldCreatedAt, vs...))
}

// CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func CreatedAtNotIn(vs ...time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNotIn(FieldCreatedAt, vs...))
}

// CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGT(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGT(FieldCreatedAt, v))
}

// CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtGTE(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGTE(FieldCreatedAt, v))
}

// CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLT(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLT(FieldCreatedAt, v))
}

// CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtLTE(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLTE(FieldCreatedAt, v))
}

// UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtEQ(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldUpdatedAt, v))
}

// UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNEQ(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNEQ(FieldUpdatedAt, v))
}

// UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtIn(vs ...time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldIn(FieldUpdatedAt, vs...))
}

// UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func UpdatedAtNotIn(vs ...time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNotIn(FieldUpdatedAt, vs...))
}

// UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGT(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGT(FieldUpdatedAt, v))
}

// UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtGTE(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGTE(FieldUpdatedAt, v))
}

// UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLT(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLT(FieldUpdatedAt, v))
}

// UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtLTE(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLTE(FieldUpdatedAt, v))
}

// ExpiredAtEQ applies the EQ predicate on the "expired_at" field.
func ExpiredAtEQ(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldEQ(FieldExpiredAt, v))
}

// ExpiredAtNEQ applies the NEQ predicate on the "expired_at" field.
func ExpiredAtNEQ(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNEQ(FieldExpiredAt, v))
}

// ExpiredAtIn applies the In predicate on the "expired_at" field.
func ExpiredAtIn(vs ...time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldIn(FieldExpiredAt, vs...))
}

// ExpiredAtNotIn applies the NotIn predicate on the "expired_at" field.
func ExpiredAtNotIn(vs ...time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldNotIn(FieldExpiredAt, vs...))
}

// ExpiredAtGT applies the GT predicate on the "expired_at" field.
func ExpiredAtGT(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGT(FieldExpiredAt, v))
}

// ExpiredAtGTE applies the GTE predicate on the "expired_at" field.
func ExpiredAtGTE(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldGTE(FieldExpiredAt, v))
}

// ExpiredAtLT applies the LT predicate on the "expired_at" field.
func ExpiredAtLT(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLT(FieldExpiredAt, v))
}

// ExpiredAtLTE applies the LTE predicate on the "expired_at" field.
func ExpiredAtLTE(v time.Time) predicate.InviteCode {
	return predicate.InviteCode(sql.FieldLTE(FieldExpiredAt, v))
}

// And groups predicates with the AND operator between them.
func And(predicates ...predicate.InviteCode) predicate.InviteCode {
	return predicate.InviteCode(sql.AndPredicates(predicates...))
}

// Or groups predicates with the OR operator between them.
func Or(predicates ...predicate.InviteCode) predicate.InviteCode {
	return predicate.InviteCode(sql.OrPredicates(predicates...))
}

// Not applies the not operator on the given predicate.
func Not(p predicate.InviteCode) predicate.InviteCode {
	return predicate.InviteCode(sql.NotPredicates(p))
}
