// Code generated by ent, DO NOT EDIT.

package tokenpartialrevocationsecretshare

import (
	"time"

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

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

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

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

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

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

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

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

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

// IDLTE applies the LTE predicate on the ID field.
func IDLTE(id uuid.UUID) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(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.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(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.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldEQ(FieldUpdateTime, v))
}

// OperatorIdentityPublicKey applies equality check predicate on the "operator_identity_public_key" field. It's identical to OperatorIdentityPublicKeyEQ.
func OperatorIdentityPublicKey(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldEQ(FieldOperatorIdentityPublicKey, v))
}

// SecretShare applies equality check predicate on the "secret_share" field. It's identical to SecretShareEQ.
func SecretShare(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldEQ(FieldSecretShare, v))
}

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

// OperatorIdentityPublicKeyEQ applies the EQ predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyEQ(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldEQ(FieldOperatorIdentityPublicKey, v))
}

// OperatorIdentityPublicKeyNEQ applies the NEQ predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyNEQ(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldNEQ(FieldOperatorIdentityPublicKey, v))
}

// OperatorIdentityPublicKeyIn applies the In predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyIn(vs ...keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldIn(FieldOperatorIdentityPublicKey, vs...))
}

// OperatorIdentityPublicKeyNotIn applies the NotIn predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyNotIn(vs ...keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldNotIn(FieldOperatorIdentityPublicKey, vs...))
}

// OperatorIdentityPublicKeyGT applies the GT predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyGT(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldGT(FieldOperatorIdentityPublicKey, v))
}

// OperatorIdentityPublicKeyGTE applies the GTE predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyGTE(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldGTE(FieldOperatorIdentityPublicKey, v))
}

// OperatorIdentityPublicKeyLT applies the LT predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyLT(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldLT(FieldOperatorIdentityPublicKey, v))
}

// OperatorIdentityPublicKeyLTE applies the LTE predicate on the "operator_identity_public_key" field.
func OperatorIdentityPublicKeyLTE(v keys.Public) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldLTE(FieldOperatorIdentityPublicKey, v))
}

// SecretShareEQ applies the EQ predicate on the "secret_share" field.
func SecretShareEQ(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldEQ(FieldSecretShare, v))
}

// SecretShareNEQ applies the NEQ predicate on the "secret_share" field.
func SecretShareNEQ(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldNEQ(FieldSecretShare, v))
}

// SecretShareIn applies the In predicate on the "secret_share" field.
func SecretShareIn(vs ...keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldIn(FieldSecretShare, vs...))
}

// SecretShareNotIn applies the NotIn predicate on the "secret_share" field.
func SecretShareNotIn(vs ...keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldNotIn(FieldSecretShare, vs...))
}

// SecretShareGT applies the GT predicate on the "secret_share" field.
func SecretShareGT(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldGT(FieldSecretShare, v))
}

// SecretShareGTE applies the GTE predicate on the "secret_share" field.
func SecretShareGTE(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldGTE(FieldSecretShare, v))
}

// SecretShareLT applies the LT predicate on the "secret_share" field.
func SecretShareLT(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldLT(FieldSecretShare, v))
}

// SecretShareLTE applies the LTE predicate on the "secret_share" field.
func SecretShareLTE(v keys.Private) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.FieldLTE(FieldSecretShare, v))
}

// HasTokenOutput applies the HasEdge predicate on the "token_output" edge.
func HasTokenOutput() predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, true, TokenOutputTable, TokenOutputColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasTokenOutputWith applies the HasEdge predicate on the "token_output" edge with a given conditions (other predicates).
func HasTokenOutputWith(preds ...predicate.TokenOutput) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(func(s *sql.Selector) {
		step := newTokenOutputStep()
		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.TokenPartialRevocationSecretShare) predicate.TokenPartialRevocationSecretShare {
	return predicate.TokenPartialRevocationSecretShare(sql.AndPredicates(predicates...))
}

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

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