// Code generated by ent, DO NOT EDIT.

package entitydkgkey

import (
	"time"

	"entgo.io/ent/dialect/sql"
	"entgo.io/ent/dialect/sql/sqlgraph"
	"github.com/google/uuid"
	"github.com/lightsparkdev/spark/so/ent/predicate"
)

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

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

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

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

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

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

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

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

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

// CreateTime applies equality check predicate on the "create_time" field. It's identical to CreateTimeEQ.
func CreateTime(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEQ(FieldCreateTime, v))
}

// UpdateTime applies equality check predicate on the "update_time" field. It's identical to UpdateTimeEQ.
func UpdateTime(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEQ(FieldUpdateTime, v))
}

// KeyType applies equality check predicate on the "key_type" field. It's identical to KeyTypeEQ.
func KeyType(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEQ(FieldKeyType, v))
}

// CreateTimeEQ applies the EQ predicate on the "create_time" field.
func CreateTimeEQ(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEQ(FieldCreateTime, v))
}

// CreateTimeNEQ applies the NEQ predicate on the "create_time" field.
func CreateTimeNEQ(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldNEQ(FieldCreateTime, v))
}

// CreateTimeIn applies the In predicate on the "create_time" field.
func CreateTimeIn(vs ...time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldIn(FieldCreateTime, vs...))
}

// CreateTimeNotIn applies the NotIn predicate on the "create_time" field.
func CreateTimeNotIn(vs ...time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldNotIn(FieldCreateTime, vs...))
}

// CreateTimeGT applies the GT predicate on the "create_time" field.
func CreateTimeGT(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldGT(FieldCreateTime, v))
}

// CreateTimeGTE applies the GTE predicate on the "create_time" field.
func CreateTimeGTE(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldGTE(FieldCreateTime, v))
}

// CreateTimeLT applies the LT predicate on the "create_time" field.
func CreateTimeLT(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldLT(FieldCreateTime, v))
}

// CreateTimeLTE applies the LTE predicate on the "create_time" field.
func CreateTimeLTE(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldLTE(FieldCreateTime, v))
}

// UpdateTimeEQ applies the EQ predicate on the "update_time" field.
func UpdateTimeEQ(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEQ(FieldUpdateTime, v))
}

// UpdateTimeNEQ applies the NEQ predicate on the "update_time" field.
func UpdateTimeNEQ(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldNEQ(FieldUpdateTime, v))
}

// UpdateTimeIn applies the In predicate on the "update_time" field.
func UpdateTimeIn(vs ...time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldIn(FieldUpdateTime, vs...))
}

// UpdateTimeNotIn applies the NotIn predicate on the "update_time" field.
func UpdateTimeNotIn(vs ...time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldNotIn(FieldUpdateTime, vs...))
}

// UpdateTimeGT applies the GT predicate on the "update_time" field.
func UpdateTimeGT(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldGT(FieldUpdateTime, v))
}

// UpdateTimeGTE applies the GTE predicate on the "update_time" field.
func UpdateTimeGTE(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldGTE(FieldUpdateTime, v))
}

// UpdateTimeLT applies the LT predicate on the "update_time" field.
func UpdateTimeLT(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldLT(FieldUpdateTime, v))
}

// UpdateTimeLTE applies the LTE predicate on the "update_time" field.
func UpdateTimeLTE(v time.Time) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldLTE(FieldUpdateTime, v))
}

// KeyTypeEQ applies the EQ predicate on the "key_type" field.
func KeyTypeEQ(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEQ(FieldKeyType, v))
}

// KeyTypeNEQ applies the NEQ predicate on the "key_type" field.
func KeyTypeNEQ(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldNEQ(FieldKeyType, v))
}

// KeyTypeIn applies the In predicate on the "key_type" field.
func KeyTypeIn(vs ...string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldIn(FieldKeyType, vs...))
}

// KeyTypeNotIn applies the NotIn predicate on the "key_type" field.
func KeyTypeNotIn(vs ...string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldNotIn(FieldKeyType, vs...))
}

// KeyTypeGT applies the GT predicate on the "key_type" field.
func KeyTypeGT(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldGT(FieldKeyType, v))
}

// KeyTypeGTE applies the GTE predicate on the "key_type" field.
func KeyTypeGTE(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldGTE(FieldKeyType, v))
}

// KeyTypeLT applies the LT predicate on the "key_type" field.
func KeyTypeLT(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldLT(FieldKeyType, v))
}

// KeyTypeLTE applies the LTE predicate on the "key_type" field.
func KeyTypeLTE(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldLTE(FieldKeyType, v))
}

// KeyTypeContains applies the Contains predicate on the "key_type" field.
func KeyTypeContains(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldContains(FieldKeyType, v))
}

// KeyTypeHasPrefix applies the HasPrefix predicate on the "key_type" field.
func KeyTypeHasPrefix(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldHasPrefix(FieldKeyType, v))
}

// KeyTypeHasSuffix applies the HasSuffix predicate on the "key_type" field.
func KeyTypeHasSuffix(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldHasSuffix(FieldKeyType, v))
}

// KeyTypeEqualFold applies the EqualFold predicate on the "key_type" field.
func KeyTypeEqualFold(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldEqualFold(FieldKeyType, v))
}

// KeyTypeContainsFold applies the ContainsFold predicate on the "key_type" field.
func KeyTypeContainsFold(v string) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(sql.FieldContainsFold(FieldKeyType, v))
}

// HasSigningKeyshare applies the HasEdge predicate on the "signing_keyshare" edge.
func HasSigningKeyshare() predicate.EntityDkgKey {
	return predicate.EntityDkgKey(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, false, SigningKeyshareTable, SigningKeyshareColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasSigningKeyshareWith applies the HasEdge predicate on the "signing_keyshare" edge with a given conditions (other predicates).
func HasSigningKeyshareWith(preds ...predicate.SigningKeyshare) predicate.EntityDkgKey {
	return predicate.EntityDkgKey(func(s *sql.Selector) {
		step := newSigningKeyshareStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

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

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

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