Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Dirs) predicate.Dirs
- func CreateTime(v time.Time) predicate.Dirs
- func CreateTimeEQ(v time.Time) predicate.Dirs
- func CreateTimeGT(v time.Time) predicate.Dirs
- func CreateTimeGTE(v time.Time) predicate.Dirs
- func CreateTimeIn(vs ...time.Time) predicate.Dirs
- func CreateTimeLT(v time.Time) predicate.Dirs
- func CreateTimeLTE(v time.Time) predicate.Dirs
- func CreateTimeNEQ(v time.Time) predicate.Dirs
- func CreateTimeNotIn(vs ...time.Time) predicate.Dirs
- func HasOwner() predicate.Dirs
- func HasOwnerWith(preds ...predicate.Users) predicate.Dirs
- func HasPdir() predicate.Dirs
- func HasPdirWith(preds ...predicate.Dirs) predicate.Dirs
- func HasSaves() predicate.Dirs
- func HasSavesWith(preds ...predicate.Saves) predicate.Dirs
- func HasSubdir() predicate.Dirs
- func HasSubdirWith(preds ...predicate.Dirs) predicate.Dirs
- func ID(id uint64) predicate.Dirs
- func IDEQ(id uint64) predicate.Dirs
- func IDGT(id uint64) predicate.Dirs
- func IDGTE(id uint64) predicate.Dirs
- func IDIn(ids ...uint64) predicate.Dirs
- func IDLT(id uint64) predicate.Dirs
- func IDLTE(id uint64) predicate.Dirs
- func IDNEQ(id uint64) predicate.Dirs
- func IDNotIn(ids ...uint64) predicate.Dirs
- func Name(v string) predicate.Dirs
- func NameContains(v string) predicate.Dirs
- func NameContainsFold(v string) predicate.Dirs
- func NameEQ(v string) predicate.Dirs
- func NameEqualFold(v string) predicate.Dirs
- func NameGT(v string) predicate.Dirs
- func NameGTE(v string) predicate.Dirs
- func NameHasPrefix(v string) predicate.Dirs
- func NameHasSuffix(v string) predicate.Dirs
- func NameIn(vs ...string) predicate.Dirs
- func NameLT(v string) predicate.Dirs
- func NameLTE(v string) predicate.Dirs
- func NameNEQ(v string) predicate.Dirs
- func NameNotIn(vs ...string) predicate.Dirs
- func Not(p predicate.Dirs) predicate.Dirs
- func Or(predicates ...predicate.Dirs) predicate.Dirs
- func UpdateTime(v time.Time) predicate.Dirs
- func UpdateTimeEQ(v time.Time) predicate.Dirs
- func UpdateTimeGT(v time.Time) predicate.Dirs
- func UpdateTimeGTE(v time.Time) predicate.Dirs
- func UpdateTimeIn(vs ...time.Time) predicate.Dirs
- func UpdateTimeLT(v time.Time) predicate.Dirs
- func UpdateTimeLTE(v time.Time) predicate.Dirs
- func UpdateTimeNEQ(v time.Time) predicate.Dirs
- func UpdateTimeNotIn(vs ...time.Time) predicate.Dirs
- func ValidColumn(column string) bool
- type OrderOption
- func ByCreateTime(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByName(opts ...sql.OrderTermOption) OrderOption
- func ByOwnerField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByPdir(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func ByPdirCount(opts ...sql.OrderTermOption) OrderOption
- func BySaves(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func BySavesCount(opts ...sql.OrderTermOption) OrderOption
- func BySubdir(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func BySubdirCount(opts ...sql.OrderTermOption) OrderOption
- func ByUpdateTime(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the dirs type in the database. Label = "dirs" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldCreateTime holds the string denoting the create_time field in the database. FieldCreateTime = "create_time" // FieldUpdateTime holds the string denoting the update_time field in the database. FieldUpdateTime = "update_time" // FieldName holds the string denoting the name field in the database. FieldName = "name" // EdgeOwner holds the string denoting the owner edge name in mutations. EdgeOwner = "owner" // EdgeSaves holds the string denoting the saves edge name in mutations. EdgeSaves = "saves" // EdgeSubdir holds the string denoting the subdir edge name in mutations. EdgeSubdir = "subdir" // EdgePdir holds the string denoting the pdir edge name in mutations. EdgePdir = "pdir" // Table holds the table name of the dirs in the database. Table = "dirs" // OwnerTable is the table that holds the owner relation/edge. OwnerTable = "dirs" // OwnerInverseTable is the table name for the Users entity. // It exists in this package in order to avoid circular dependency with the "users" package. OwnerInverseTable = "users" // OwnerColumn is the table column denoting the owner relation/edge. OwnerColumn = "users_dirs" // SavesTable is the table that holds the saves relation/edge. The primary key declared below. SavesTable = "dirs_saves" // SavesInverseTable is the table name for the Saves entity. // It exists in this package in order to avoid circular dependency with the "saves" package. SavesInverseTable = "saves" // SubdirTable is the table that holds the subdir relation/edge. The primary key declared below. SubdirTable = "dirs_subdir" // PdirTable is the table that holds the pdir relation/edge. The primary key declared below. PdirTable = "dirs_subdir" )
Variables ¶
var ( // SavesPrimaryKey and SavesColumn2 are the table columns denoting the // primary key for the saves relation (M2M). SavesPrimaryKey = []string{"dirs_id", "saves_id"} // SubdirPrimaryKey and SubdirColumn2 are the table columns denoting the // primary key for the subdir relation (M2M). SubdirPrimaryKey = []string{"dirs_id", "pdir_id"} // PdirPrimaryKey and PdirColumn2 are the table columns denoting the // primary key for the pdir relation (M2M). PdirPrimaryKey = []string{"dirs_id", "pdir_id"} )
var ( // DefaultCreateTime holds the default value on creation for the "create_time" field. DefaultCreateTime func() time.Time // DefaultUpdateTime holds the default value on creation for the "update_time" field. DefaultUpdateTime func() time.Time // UpdateDefaultUpdateTime holds the default value on update for the "update_time" field. UpdateDefaultUpdateTime func() time.Time )
var Columns = []string{ FieldID, FieldCreateTime, FieldUpdateTime, FieldName, }
Columns holds all SQL columns for dirs fields.
var ForeignKeys = []string{
"users_dirs",
}
ForeignKeys holds the SQL foreign-keys that are owned by the "dirs" table and are not defined as standalone fields in the schema.
Functions ¶
func CreateTime ¶
CreateTime applies equality check predicate on the "create_time" field. It's identical to CreateTimeEQ.
func CreateTimeEQ ¶
CreateTimeEQ applies the EQ predicate on the "create_time" field.
func CreateTimeGT ¶
CreateTimeGT applies the GT predicate on the "create_time" field.
func CreateTimeGTE ¶
CreateTimeGTE applies the GTE predicate on the "create_time" field.
func CreateTimeIn ¶
CreateTimeIn applies the In predicate on the "create_time" field.
func CreateTimeLT ¶
CreateTimeLT applies the LT predicate on the "create_time" field.
func CreateTimeLTE ¶
CreateTimeLTE applies the LTE predicate on the "create_time" field.
func CreateTimeNEQ ¶
CreateTimeNEQ applies the NEQ predicate on the "create_time" field.
func CreateTimeNotIn ¶
CreateTimeNotIn applies the NotIn predicate on the "create_time" field.
func HasOwnerWith ¶
HasOwnerWith applies the HasEdge predicate on the "owner" edge with a given conditions (other predicates).
func HasPdirWith ¶
HasPdirWith applies the HasEdge predicate on the "pdir" edge with a given conditions (other predicates).
func HasSavesWith ¶
HasSavesWith applies the HasEdge predicate on the "saves" edge with a given conditions (other predicates).
func HasSubdirWith ¶
HasSubdirWith applies the HasEdge predicate on the "subdir" edge with a given conditions (other predicates).
func NameContains ¶
NameContains applies the Contains predicate on the "name" field.
func NameContainsFold ¶
NameContainsFold applies the ContainsFold predicate on the "name" field.
func NameEqualFold ¶
NameEqualFold applies the EqualFold predicate on the "name" field.
func NameHasPrefix ¶
NameHasPrefix applies the HasPrefix predicate on the "name" field.
func NameHasSuffix ¶
NameHasSuffix applies the HasSuffix predicate on the "name" field.
func UpdateTime ¶
UpdateTime applies equality check predicate on the "update_time" field. It's identical to UpdateTimeEQ.
func UpdateTimeEQ ¶
UpdateTimeEQ applies the EQ predicate on the "update_time" field.
func UpdateTimeGT ¶
UpdateTimeGT applies the GT predicate on the "update_time" field.
func UpdateTimeGTE ¶
UpdateTimeGTE applies the GTE predicate on the "update_time" field.
func UpdateTimeIn ¶
UpdateTimeIn applies the In predicate on the "update_time" field.
func UpdateTimeLT ¶
UpdateTimeLT applies the LT predicate on the "update_time" field.
func UpdateTimeLTE ¶
UpdateTimeLTE applies the LTE predicate on the "update_time" field.
func UpdateTimeNEQ ¶
UpdateTimeNEQ applies the NEQ predicate on the "update_time" field.
func UpdateTimeNotIn ¶
UpdateTimeNotIn applies the NotIn predicate on the "update_time" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the Dirs queries.
func ByCreateTime ¶
func ByCreateTime(opts ...sql.OrderTermOption) OrderOption
ByCreateTime orders the results by the create_time field.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByName ¶
func ByName(opts ...sql.OrderTermOption) OrderOption
ByName orders the results by the name field.
func ByOwnerField ¶
func ByOwnerField(field string, opts ...sql.OrderTermOption) OrderOption
ByOwnerField orders the results by owner field.
func ByPdir ¶
func ByPdir(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
ByPdir orders the results by pdir terms.
func ByPdirCount ¶
func ByPdirCount(opts ...sql.OrderTermOption) OrderOption
ByPdirCount orders the results by pdir count.
func BySaves ¶
func BySaves(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
BySaves orders the results by saves terms.
func BySavesCount ¶
func BySavesCount(opts ...sql.OrderTermOption) OrderOption
BySavesCount orders the results by saves count.
func BySubdir ¶
func BySubdir(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
BySubdir orders the results by subdir terms.
func BySubdirCount ¶
func BySubdirCount(opts ...sql.OrderTermOption) OrderOption
BySubdirCount orders the results by subdir count.
func ByUpdateTime ¶
func ByUpdateTime(opts ...sql.OrderTermOption) OrderOption
ByUpdateTime orders the results by the update_time field.