Cloudreve/ent/share/where.go

553 lines
18 KiB
Go

// Code generated by ent, DO NOT EDIT.
package share
import (
"time"
"entgo.io/ent/dialect/sql"
"entgo.io/ent/dialect/sql/sqlgraph"
"github.com/cloudreve/Cloudreve/v4/ent/predicate"
)
// ID filters vertices based on their ID field.
func ID(id int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldID, id))
}
// IDEQ applies the EQ predicate on the ID field.
func IDEQ(id int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldID, id))
}
// IDNEQ applies the NEQ predicate on the ID field.
func IDNEQ(id int) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldID, id))
}
// IDIn applies the In predicate on the ID field.
func IDIn(ids ...int) predicate.Share {
return predicate.Share(sql.FieldIn(FieldID, ids...))
}
// IDNotIn applies the NotIn predicate on the ID field.
func IDNotIn(ids ...int) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldID, ids...))
}
// IDGT applies the GT predicate on the ID field.
func IDGT(id int) predicate.Share {
return predicate.Share(sql.FieldGT(FieldID, id))
}
// IDGTE applies the GTE predicate on the ID field.
func IDGTE(id int) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldID, id))
}
// IDLT applies the LT predicate on the ID field.
func IDLT(id int) predicate.Share {
return predicate.Share(sql.FieldLT(FieldID, id))
}
// IDLTE applies the LTE predicate on the ID field.
func IDLTE(id int) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldID, id))
}
// CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAt(v time.Time) predicate.Share {
return predicate.Share(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.Share {
return predicate.Share(sql.FieldEQ(FieldUpdatedAt, v))
}
// DeletedAt applies equality check predicate on the "deleted_at" field. It's identical to DeletedAtEQ.
func DeletedAt(v time.Time) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldDeletedAt, v))
}
// Password applies equality check predicate on the "password" field. It's identical to PasswordEQ.
func Password(v string) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldPassword, v))
}
// Views applies equality check predicate on the "views" field. It's identical to ViewsEQ.
func Views(v int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldViews, v))
}
// Downloads applies equality check predicate on the "downloads" field. It's identical to DownloadsEQ.
func Downloads(v int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldDownloads, v))
}
// Expires applies equality check predicate on the "expires" field. It's identical to ExpiresEQ.
func Expires(v time.Time) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldExpires, v))
}
// RemainDownloads applies equality check predicate on the "remain_downloads" field. It's identical to RemainDownloadsEQ.
func RemainDownloads(v int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldRemainDownloads, v))
}
// CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldCreatedAt, v))
}
// CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldCreatedAt, v))
}
// CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldIn(FieldCreatedAt, vs...))
}
// CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func CreatedAtNotIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldCreatedAt, vs...))
}
// CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGT(FieldCreatedAt, v))
}
// CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtGTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldCreatedAt, v))
}
// CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLT(FieldCreatedAt, v))
}
// CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtLTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldCreatedAt, v))
}
// UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldUpdatedAt, v))
}
// UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldUpdatedAt, v))
}
// UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldIn(FieldUpdatedAt, vs...))
}
// UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func UpdatedAtNotIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldUpdatedAt, vs...))
}
// UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGT(FieldUpdatedAt, v))
}
// UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtGTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldUpdatedAt, v))
}
// UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLT(FieldUpdatedAt, v))
}
// UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtLTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldUpdatedAt, v))
}
// DeletedAtEQ applies the EQ predicate on the "deleted_at" field.
func DeletedAtEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldDeletedAt, v))
}
// DeletedAtNEQ applies the NEQ predicate on the "deleted_at" field.
func DeletedAtNEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldDeletedAt, v))
}
// DeletedAtIn applies the In predicate on the "deleted_at" field.
func DeletedAtIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldIn(FieldDeletedAt, vs...))
}
// DeletedAtNotIn applies the NotIn predicate on the "deleted_at" field.
func DeletedAtNotIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldDeletedAt, vs...))
}
// DeletedAtGT applies the GT predicate on the "deleted_at" field.
func DeletedAtGT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGT(FieldDeletedAt, v))
}
// DeletedAtGTE applies the GTE predicate on the "deleted_at" field.
func DeletedAtGTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldDeletedAt, v))
}
// DeletedAtLT applies the LT predicate on the "deleted_at" field.
func DeletedAtLT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLT(FieldDeletedAt, v))
}
// DeletedAtLTE applies the LTE predicate on the "deleted_at" field.
func DeletedAtLTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldDeletedAt, v))
}
// DeletedAtIsNil applies the IsNil predicate on the "deleted_at" field.
func DeletedAtIsNil() predicate.Share {
return predicate.Share(sql.FieldIsNull(FieldDeletedAt))
}
// DeletedAtNotNil applies the NotNil predicate on the "deleted_at" field.
func DeletedAtNotNil() predicate.Share {
return predicate.Share(sql.FieldNotNull(FieldDeletedAt))
}
// PasswordEQ applies the EQ predicate on the "password" field.
func PasswordEQ(v string) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldPassword, v))
}
// PasswordNEQ applies the NEQ predicate on the "password" field.
func PasswordNEQ(v string) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldPassword, v))
}
// PasswordIn applies the In predicate on the "password" field.
func PasswordIn(vs ...string) predicate.Share {
return predicate.Share(sql.FieldIn(FieldPassword, vs...))
}
// PasswordNotIn applies the NotIn predicate on the "password" field.
func PasswordNotIn(vs ...string) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldPassword, vs...))
}
// PasswordGT applies the GT predicate on the "password" field.
func PasswordGT(v string) predicate.Share {
return predicate.Share(sql.FieldGT(FieldPassword, v))
}
// PasswordGTE applies the GTE predicate on the "password" field.
func PasswordGTE(v string) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldPassword, v))
}
// PasswordLT applies the LT predicate on the "password" field.
func PasswordLT(v string) predicate.Share {
return predicate.Share(sql.FieldLT(FieldPassword, v))
}
// PasswordLTE applies the LTE predicate on the "password" field.
func PasswordLTE(v string) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldPassword, v))
}
// PasswordContains applies the Contains predicate on the "password" field.
func PasswordContains(v string) predicate.Share {
return predicate.Share(sql.FieldContains(FieldPassword, v))
}
// PasswordHasPrefix applies the HasPrefix predicate on the "password" field.
func PasswordHasPrefix(v string) predicate.Share {
return predicate.Share(sql.FieldHasPrefix(FieldPassword, v))
}
// PasswordHasSuffix applies the HasSuffix predicate on the "password" field.
func PasswordHasSuffix(v string) predicate.Share {
return predicate.Share(sql.FieldHasSuffix(FieldPassword, v))
}
// PasswordIsNil applies the IsNil predicate on the "password" field.
func PasswordIsNil() predicate.Share {
return predicate.Share(sql.FieldIsNull(FieldPassword))
}
// PasswordNotNil applies the NotNil predicate on the "password" field.
func PasswordNotNil() predicate.Share {
return predicate.Share(sql.FieldNotNull(FieldPassword))
}
// PasswordEqualFold applies the EqualFold predicate on the "password" field.
func PasswordEqualFold(v string) predicate.Share {
return predicate.Share(sql.FieldEqualFold(FieldPassword, v))
}
// PasswordContainsFold applies the ContainsFold predicate on the "password" field.
func PasswordContainsFold(v string) predicate.Share {
return predicate.Share(sql.FieldContainsFold(FieldPassword, v))
}
// ViewsEQ applies the EQ predicate on the "views" field.
func ViewsEQ(v int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldViews, v))
}
// ViewsNEQ applies the NEQ predicate on the "views" field.
func ViewsNEQ(v int) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldViews, v))
}
// ViewsIn applies the In predicate on the "views" field.
func ViewsIn(vs ...int) predicate.Share {
return predicate.Share(sql.FieldIn(FieldViews, vs...))
}
// ViewsNotIn applies the NotIn predicate on the "views" field.
func ViewsNotIn(vs ...int) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldViews, vs...))
}
// ViewsGT applies the GT predicate on the "views" field.
func ViewsGT(v int) predicate.Share {
return predicate.Share(sql.FieldGT(FieldViews, v))
}
// ViewsGTE applies the GTE predicate on the "views" field.
func ViewsGTE(v int) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldViews, v))
}
// ViewsLT applies the LT predicate on the "views" field.
func ViewsLT(v int) predicate.Share {
return predicate.Share(sql.FieldLT(FieldViews, v))
}
// ViewsLTE applies the LTE predicate on the "views" field.
func ViewsLTE(v int) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldViews, v))
}
// DownloadsEQ applies the EQ predicate on the "downloads" field.
func DownloadsEQ(v int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldDownloads, v))
}
// DownloadsNEQ applies the NEQ predicate on the "downloads" field.
func DownloadsNEQ(v int) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldDownloads, v))
}
// DownloadsIn applies the In predicate on the "downloads" field.
func DownloadsIn(vs ...int) predicate.Share {
return predicate.Share(sql.FieldIn(FieldDownloads, vs...))
}
// DownloadsNotIn applies the NotIn predicate on the "downloads" field.
func DownloadsNotIn(vs ...int) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldDownloads, vs...))
}
// DownloadsGT applies the GT predicate on the "downloads" field.
func DownloadsGT(v int) predicate.Share {
return predicate.Share(sql.FieldGT(FieldDownloads, v))
}
// DownloadsGTE applies the GTE predicate on the "downloads" field.
func DownloadsGTE(v int) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldDownloads, v))
}
// DownloadsLT applies the LT predicate on the "downloads" field.
func DownloadsLT(v int) predicate.Share {
return predicate.Share(sql.FieldLT(FieldDownloads, v))
}
// DownloadsLTE applies the LTE predicate on the "downloads" field.
func DownloadsLTE(v int) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldDownloads, v))
}
// ExpiresEQ applies the EQ predicate on the "expires" field.
func ExpiresEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldExpires, v))
}
// ExpiresNEQ applies the NEQ predicate on the "expires" field.
func ExpiresNEQ(v time.Time) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldExpires, v))
}
// ExpiresIn applies the In predicate on the "expires" field.
func ExpiresIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldIn(FieldExpires, vs...))
}
// ExpiresNotIn applies the NotIn predicate on the "expires" field.
func ExpiresNotIn(vs ...time.Time) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldExpires, vs...))
}
// ExpiresGT applies the GT predicate on the "expires" field.
func ExpiresGT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGT(FieldExpires, v))
}
// ExpiresGTE applies the GTE predicate on the "expires" field.
func ExpiresGTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldExpires, v))
}
// ExpiresLT applies the LT predicate on the "expires" field.
func ExpiresLT(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLT(FieldExpires, v))
}
// ExpiresLTE applies the LTE predicate on the "expires" field.
func ExpiresLTE(v time.Time) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldExpires, v))
}
// ExpiresIsNil applies the IsNil predicate on the "expires" field.
func ExpiresIsNil() predicate.Share {
return predicate.Share(sql.FieldIsNull(FieldExpires))
}
// ExpiresNotNil applies the NotNil predicate on the "expires" field.
func ExpiresNotNil() predicate.Share {
return predicate.Share(sql.FieldNotNull(FieldExpires))
}
// RemainDownloadsEQ applies the EQ predicate on the "remain_downloads" field.
func RemainDownloadsEQ(v int) predicate.Share {
return predicate.Share(sql.FieldEQ(FieldRemainDownloads, v))
}
// RemainDownloadsNEQ applies the NEQ predicate on the "remain_downloads" field.
func RemainDownloadsNEQ(v int) predicate.Share {
return predicate.Share(sql.FieldNEQ(FieldRemainDownloads, v))
}
// RemainDownloadsIn applies the In predicate on the "remain_downloads" field.
func RemainDownloadsIn(vs ...int) predicate.Share {
return predicate.Share(sql.FieldIn(FieldRemainDownloads, vs...))
}
// RemainDownloadsNotIn applies the NotIn predicate on the "remain_downloads" field.
func RemainDownloadsNotIn(vs ...int) predicate.Share {
return predicate.Share(sql.FieldNotIn(FieldRemainDownloads, vs...))
}
// RemainDownloadsGT applies the GT predicate on the "remain_downloads" field.
func RemainDownloadsGT(v int) predicate.Share {
return predicate.Share(sql.FieldGT(FieldRemainDownloads, v))
}
// RemainDownloadsGTE applies the GTE predicate on the "remain_downloads" field.
func RemainDownloadsGTE(v int) predicate.Share {
return predicate.Share(sql.FieldGTE(FieldRemainDownloads, v))
}
// RemainDownloadsLT applies the LT predicate on the "remain_downloads" field.
func RemainDownloadsLT(v int) predicate.Share {
return predicate.Share(sql.FieldLT(FieldRemainDownloads, v))
}
// RemainDownloadsLTE applies the LTE predicate on the "remain_downloads" field.
func RemainDownloadsLTE(v int) predicate.Share {
return predicate.Share(sql.FieldLTE(FieldRemainDownloads, v))
}
// RemainDownloadsIsNil applies the IsNil predicate on the "remain_downloads" field.
func RemainDownloadsIsNil() predicate.Share {
return predicate.Share(sql.FieldIsNull(FieldRemainDownloads))
}
// RemainDownloadsNotNil applies the NotNil predicate on the "remain_downloads" field.
func RemainDownloadsNotNil() predicate.Share {
return predicate.Share(sql.FieldNotNull(FieldRemainDownloads))
}
// PropsIsNil applies the IsNil predicate on the "props" field.
func PropsIsNil() predicate.Share {
return predicate.Share(sql.FieldIsNull(FieldProps))
}
// PropsNotNil applies the NotNil predicate on the "props" field.
func PropsNotNil() predicate.Share {
return predicate.Share(sql.FieldNotNull(FieldProps))
}
// HasUser applies the HasEdge predicate on the "user" edge.
func HasUser() predicate.Share {
return predicate.Share(func(s *sql.Selector) {
step := sqlgraph.NewStep(
sqlgraph.From(Table, FieldID),
sqlgraph.Edge(sqlgraph.M2O, true, UserTable, UserColumn),
)
sqlgraph.HasNeighbors(s, step)
})
}
// HasUserWith applies the HasEdge predicate on the "user" edge with a given conditions (other predicates).
func HasUserWith(preds ...predicate.User) predicate.Share {
return predicate.Share(func(s *sql.Selector) {
step := newUserStep()
sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
for _, p := range preds {
p(s)
}
})
})
}
// HasFile applies the HasEdge predicate on the "file" edge.
func HasFile() predicate.Share {
return predicate.Share(func(s *sql.Selector) {
step := sqlgraph.NewStep(
sqlgraph.From(Table, FieldID),
sqlgraph.Edge(sqlgraph.M2O, true, FileTable, FileColumn),
)
sqlgraph.HasNeighbors(s, step)
})
}
// HasFileWith applies the HasEdge predicate on the "file" edge with a given conditions (other predicates).
func HasFileWith(preds ...predicate.File) predicate.Share {
return predicate.Share(func(s *sql.Selector) {
step := newFileStep()
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.Share) predicate.Share {
return predicate.Share(sql.AndPredicates(predicates...))
}
// Or groups predicates with the OR operator between them.
func Or(predicates ...predicate.Share) predicate.Share {
return predicate.Share(sql.OrPredicates(predicates...))
}
// Not applies the not operator on the given predicate.
func Not(p predicate.Share) predicate.Share {
return predicate.Share(sql.NotPredicates(p))
}