// Code generated by ent, DO NOT EDIT.

package tokentransaction

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"
	"github.com/lightsparkdev/spark/so/ent/schema/schematype"
)

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

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

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

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

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

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

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

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

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

// PartialTokenTransactionHash applies equality check predicate on the "partial_token_transaction_hash" field. It's identical to PartialTokenTransactionHashEQ.
func PartialTokenTransactionHash(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldPartialTokenTransactionHash, v))
}

// FinalizedTokenTransactionHash applies equality check predicate on the "finalized_token_transaction_hash" field. It's identical to FinalizedTokenTransactionHashEQ.
func FinalizedTokenTransactionHash(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldFinalizedTokenTransactionHash, v))
}

// OperatorSignature applies equality check predicate on the "operator_signature" field. It's identical to OperatorSignatureEQ.
func OperatorSignature(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldOperatorSignature, v))
}

// ExpiryTime applies equality check predicate on the "expiry_time" field. It's identical to ExpiryTimeEQ.
func ExpiryTime(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldExpiryTime, v))
}

// CoordinatorPublicKey applies equality check predicate on the "coordinator_public_key" field. It's identical to CoordinatorPublicKeyEQ.
func CoordinatorPublicKey(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldCoordinatorPublicKey, v))
}

// ClientCreatedTimestamp applies equality check predicate on the "client_created_timestamp" field. It's identical to ClientCreatedTimestampEQ.
func ClientCreatedTimestamp(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldClientCreatedTimestamp, v))
}

// Version applies equality check predicate on the "version" field. It's identical to VersionEQ.
func Version(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldEQ(FieldVersion, vc))
}

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

// PartialTokenTransactionHashEQ applies the EQ predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashEQ(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldPartialTokenTransactionHash, v))
}

// PartialTokenTransactionHashNEQ applies the NEQ predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashNEQ(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNEQ(FieldPartialTokenTransactionHash, v))
}

// PartialTokenTransactionHashIn applies the In predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashIn(vs ...[]byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIn(FieldPartialTokenTransactionHash, vs...))
}

// PartialTokenTransactionHashNotIn applies the NotIn predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashNotIn(vs ...[]byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotIn(FieldPartialTokenTransactionHash, vs...))
}

// PartialTokenTransactionHashGT applies the GT predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashGT(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGT(FieldPartialTokenTransactionHash, v))
}

// PartialTokenTransactionHashGTE applies the GTE predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashGTE(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGTE(FieldPartialTokenTransactionHash, v))
}

// PartialTokenTransactionHashLT applies the LT predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashLT(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLT(FieldPartialTokenTransactionHash, v))
}

// PartialTokenTransactionHashLTE applies the LTE predicate on the "partial_token_transaction_hash" field.
func PartialTokenTransactionHashLTE(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLTE(FieldPartialTokenTransactionHash, v))
}

// FinalizedTokenTransactionHashEQ applies the EQ predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashEQ(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldFinalizedTokenTransactionHash, v))
}

// FinalizedTokenTransactionHashNEQ applies the NEQ predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashNEQ(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNEQ(FieldFinalizedTokenTransactionHash, v))
}

// FinalizedTokenTransactionHashIn applies the In predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashIn(vs ...[]byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIn(FieldFinalizedTokenTransactionHash, vs...))
}

// FinalizedTokenTransactionHashNotIn applies the NotIn predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashNotIn(vs ...[]byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotIn(FieldFinalizedTokenTransactionHash, vs...))
}

// FinalizedTokenTransactionHashGT applies the GT predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashGT(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGT(FieldFinalizedTokenTransactionHash, v))
}

// FinalizedTokenTransactionHashGTE applies the GTE predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashGTE(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGTE(FieldFinalizedTokenTransactionHash, v))
}

// FinalizedTokenTransactionHashLT applies the LT predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashLT(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLT(FieldFinalizedTokenTransactionHash, v))
}

// FinalizedTokenTransactionHashLTE applies the LTE predicate on the "finalized_token_transaction_hash" field.
func FinalizedTokenTransactionHashLTE(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLTE(FieldFinalizedTokenTransactionHash, v))
}

// OperatorSignatureEQ applies the EQ predicate on the "operator_signature" field.
func OperatorSignatureEQ(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldOperatorSignature, v))
}

// OperatorSignatureNEQ applies the NEQ predicate on the "operator_signature" field.
func OperatorSignatureNEQ(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNEQ(FieldOperatorSignature, v))
}

// OperatorSignatureIn applies the In predicate on the "operator_signature" field.
func OperatorSignatureIn(vs ...[]byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIn(FieldOperatorSignature, vs...))
}

// OperatorSignatureNotIn applies the NotIn predicate on the "operator_signature" field.
func OperatorSignatureNotIn(vs ...[]byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotIn(FieldOperatorSignature, vs...))
}

// OperatorSignatureGT applies the GT predicate on the "operator_signature" field.
func OperatorSignatureGT(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGT(FieldOperatorSignature, v))
}

// OperatorSignatureGTE applies the GTE predicate on the "operator_signature" field.
func OperatorSignatureGTE(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGTE(FieldOperatorSignature, v))
}

// OperatorSignatureLT applies the LT predicate on the "operator_signature" field.
func OperatorSignatureLT(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLT(FieldOperatorSignature, v))
}

// OperatorSignatureLTE applies the LTE predicate on the "operator_signature" field.
func OperatorSignatureLTE(v []byte) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLTE(FieldOperatorSignature, v))
}

// OperatorSignatureIsNil applies the IsNil predicate on the "operator_signature" field.
func OperatorSignatureIsNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIsNull(FieldOperatorSignature))
}

// OperatorSignatureNotNil applies the NotNil predicate on the "operator_signature" field.
func OperatorSignatureNotNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotNull(FieldOperatorSignature))
}

// StatusEQ applies the EQ predicate on the "status" field.
func StatusEQ(v schematype.TokenTransactionStatus) predicate.TokenTransaction {
	vc := v
	return predicate.TokenTransaction(sql.FieldEQ(FieldStatus, vc))
}

// StatusNEQ applies the NEQ predicate on the "status" field.
func StatusNEQ(v schematype.TokenTransactionStatus) predicate.TokenTransaction {
	vc := v
	return predicate.TokenTransaction(sql.FieldNEQ(FieldStatus, vc))
}

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

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

// StatusIsNil applies the IsNil predicate on the "status" field.
func StatusIsNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIsNull(FieldStatus))
}

// StatusNotNil applies the NotNil predicate on the "status" field.
func StatusNotNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotNull(FieldStatus))
}

// ExpiryTimeEQ applies the EQ predicate on the "expiry_time" field.
func ExpiryTimeEQ(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldExpiryTime, v))
}

// ExpiryTimeNEQ applies the NEQ predicate on the "expiry_time" field.
func ExpiryTimeNEQ(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNEQ(FieldExpiryTime, v))
}

// ExpiryTimeIn applies the In predicate on the "expiry_time" field.
func ExpiryTimeIn(vs ...time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIn(FieldExpiryTime, vs...))
}

// ExpiryTimeNotIn applies the NotIn predicate on the "expiry_time" field.
func ExpiryTimeNotIn(vs ...time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotIn(FieldExpiryTime, vs...))
}

// ExpiryTimeGT applies the GT predicate on the "expiry_time" field.
func ExpiryTimeGT(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGT(FieldExpiryTime, v))
}

// ExpiryTimeGTE applies the GTE predicate on the "expiry_time" field.
func ExpiryTimeGTE(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGTE(FieldExpiryTime, v))
}

// ExpiryTimeLT applies the LT predicate on the "expiry_time" field.
func ExpiryTimeLT(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLT(FieldExpiryTime, v))
}

// ExpiryTimeLTE applies the LTE predicate on the "expiry_time" field.
func ExpiryTimeLTE(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLTE(FieldExpiryTime, v))
}

// ExpiryTimeIsNil applies the IsNil predicate on the "expiry_time" field.
func ExpiryTimeIsNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIsNull(FieldExpiryTime))
}

// ExpiryTimeNotNil applies the NotNil predicate on the "expiry_time" field.
func ExpiryTimeNotNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotNull(FieldExpiryTime))
}

// CoordinatorPublicKeyEQ applies the EQ predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyEQ(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldCoordinatorPublicKey, v))
}

// CoordinatorPublicKeyNEQ applies the NEQ predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyNEQ(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNEQ(FieldCoordinatorPublicKey, v))
}

// CoordinatorPublicKeyIn applies the In predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyIn(vs ...keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIn(FieldCoordinatorPublicKey, vs...))
}

// CoordinatorPublicKeyNotIn applies the NotIn predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyNotIn(vs ...keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotIn(FieldCoordinatorPublicKey, vs...))
}

// CoordinatorPublicKeyGT applies the GT predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyGT(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGT(FieldCoordinatorPublicKey, v))
}

// CoordinatorPublicKeyGTE applies the GTE predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyGTE(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGTE(FieldCoordinatorPublicKey, v))
}

// CoordinatorPublicKeyLT applies the LT predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyLT(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLT(FieldCoordinatorPublicKey, v))
}

// CoordinatorPublicKeyLTE applies the LTE predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyLTE(v keys.Public) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLTE(FieldCoordinatorPublicKey, v))
}

// CoordinatorPublicKeyIsNil applies the IsNil predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyIsNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIsNull(FieldCoordinatorPublicKey))
}

// CoordinatorPublicKeyNotNil applies the NotNil predicate on the "coordinator_public_key" field.
func CoordinatorPublicKeyNotNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotNull(FieldCoordinatorPublicKey))
}

// ClientCreatedTimestampEQ applies the EQ predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampEQ(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldEQ(FieldClientCreatedTimestamp, v))
}

// ClientCreatedTimestampNEQ applies the NEQ predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampNEQ(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNEQ(FieldClientCreatedTimestamp, v))
}

// ClientCreatedTimestampIn applies the In predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampIn(vs ...time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIn(FieldClientCreatedTimestamp, vs...))
}

// ClientCreatedTimestampNotIn applies the NotIn predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampNotIn(vs ...time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotIn(FieldClientCreatedTimestamp, vs...))
}

// ClientCreatedTimestampGT applies the GT predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampGT(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGT(FieldClientCreatedTimestamp, v))
}

// ClientCreatedTimestampGTE applies the GTE predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampGTE(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldGTE(FieldClientCreatedTimestamp, v))
}

// ClientCreatedTimestampLT applies the LT predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampLT(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLT(FieldClientCreatedTimestamp, v))
}

// ClientCreatedTimestampLTE applies the LTE predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampLTE(v time.Time) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldLTE(FieldClientCreatedTimestamp, v))
}

// ClientCreatedTimestampIsNil applies the IsNil predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampIsNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldIsNull(FieldClientCreatedTimestamp))
}

// ClientCreatedTimestampNotNil applies the NotNil predicate on the "client_created_timestamp" field.
func ClientCreatedTimestampNotNil() predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.FieldNotNull(FieldClientCreatedTimestamp))
}

// VersionEQ applies the EQ predicate on the "version" field.
func VersionEQ(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldEQ(FieldVersion, vc))
}

// VersionNEQ applies the NEQ predicate on the "version" field.
func VersionNEQ(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldNEQ(FieldVersion, vc))
}

// VersionIn applies the In predicate on the "version" field.
func VersionIn(vs ...schematype.TokenTransactionVersion) predicate.TokenTransaction {
	v := make([]any, len(vs))
	for i := range v {
		v[i] = int(vs[i])
	}
	return predicate.TokenTransaction(sql.FieldIn(FieldVersion, v...))
}

// VersionNotIn applies the NotIn predicate on the "version" field.
func VersionNotIn(vs ...schematype.TokenTransactionVersion) predicate.TokenTransaction {
	v := make([]any, len(vs))
	for i := range v {
		v[i] = int(vs[i])
	}
	return predicate.TokenTransaction(sql.FieldNotIn(FieldVersion, v...))
}

// VersionGT applies the GT predicate on the "version" field.
func VersionGT(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldGT(FieldVersion, vc))
}

// VersionGTE applies the GTE predicate on the "version" field.
func VersionGTE(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldGTE(FieldVersion, vc))
}

// VersionLT applies the LT predicate on the "version" field.
func VersionLT(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldLT(FieldVersion, vc))
}

// VersionLTE applies the LTE predicate on the "version" field.
func VersionLTE(v schematype.TokenTransactionVersion) predicate.TokenTransaction {
	vc := int(v)
	return predicate.TokenTransaction(sql.FieldLTE(FieldVersion, vc))
}

// HasSpentOutput applies the HasEdge predicate on the "spent_output" edge.
func HasSpentOutput() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.O2M, true, SpentOutputTable, SpentOutputColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasSpentOutputWith applies the HasEdge predicate on the "spent_output" edge with a given conditions (other predicates).
func HasSpentOutputWith(preds ...predicate.TokenOutput) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newSpentOutputStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasSpentOutputV2 applies the HasEdge predicate on the "spent_output_v2" edge.
func HasSpentOutputV2() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2M, true, SpentOutputV2Table, SpentOutputV2PrimaryKey...),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasSpentOutputV2With applies the HasEdge predicate on the "spent_output_v2" edge with a given conditions (other predicates).
func HasSpentOutputV2With(preds ...predicate.TokenOutput) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newSpentOutputV2Step()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasCreatedOutput applies the HasEdge predicate on the "created_output" edge.
func HasCreatedOutput() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.O2M, true, CreatedOutputTable, CreatedOutputColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasCreatedOutputWith applies the HasEdge predicate on the "created_output" edge with a given conditions (other predicates).
func HasCreatedOutputWith(preds ...predicate.TokenOutput) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newCreatedOutputStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasMint applies the HasEdge predicate on the "mint" edge.
func HasMint() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, false, MintTable, MintColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasMintWith applies the HasEdge predicate on the "mint" edge with a given conditions (other predicates).
func HasMintWith(preds ...predicate.TokenMint) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newMintStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasCreate applies the HasEdge predicate on the "create" edge.
func HasCreate() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, false, CreateTable, CreateColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasCreateWith applies the HasEdge predicate on the "create" edge with a given conditions (other predicates).
func HasCreateWith(preds ...predicate.TokenCreate) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newCreateStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasPaymentIntent applies the HasEdge predicate on the "payment_intent" edge.
func HasPaymentIntent() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, false, PaymentIntentTable, PaymentIntentColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasPaymentIntentWith applies the HasEdge predicate on the "payment_intent" edge with a given conditions (other predicates).
func HasPaymentIntentWith(preds ...predicate.PaymentIntent) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newPaymentIntentStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasPeerSignatures applies the HasEdge predicate on the "peer_signatures" edge.
func HasPeerSignatures() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.O2M, false, PeerSignaturesTable, PeerSignaturesColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasPeerSignaturesWith applies the HasEdge predicate on the "peer_signatures" edge with a given conditions (other predicates).
func HasPeerSignaturesWith(preds ...predicate.TokenTransactionPeerSignature) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newPeerSignaturesStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasSparkInvoice applies the HasEdge predicate on the "spark_invoice" edge.
func HasSparkInvoice() predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2M, false, SparkInvoiceTable, SparkInvoicePrimaryKey...),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasSparkInvoiceWith applies the HasEdge predicate on the "spark_invoice" edge with a given conditions (other predicates).
func HasSparkInvoiceWith(preds ...predicate.SparkInvoice) predicate.TokenTransaction {
	return predicate.TokenTransaction(func(s *sql.Selector) {
		step := newSparkInvoiceStep()
		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.TokenTransaction) predicate.TokenTransaction {
	return predicate.TokenTransaction(sql.AndPredicates(predicates...))
}

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

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