Documentation
¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Artists) predicate.Artists
- func HasAlbums() predicate.Artists
- func HasAlbumsWith(preds ...predicate.Albums) predicate.Artists
- func HasMusics() predicate.Artists
- func HasMusicsWith(preds ...predicate.Musics) predicate.Artists
- func ID(id uint64) predicate.Artists
- func IDEQ(id uint64) predicate.Artists
- func IDGT(id uint64) predicate.Artists
- func IDGTE(id uint64) predicate.Artists
- func IDIn(ids ...uint64) predicate.Artists
- func IDLT(id uint64) predicate.Artists
- func IDLTE(id uint64) predicate.Artists
- func IDNEQ(id uint64) predicate.Artists
- func IDNotIn(ids ...uint64) predicate.Artists
- func Name(v string) predicate.Artists
- func NameContains(v string) predicate.Artists
- func NameContainsFold(v string) predicate.Artists
- func NameEQ(v string) predicate.Artists
- func NameEqualFold(v string) predicate.Artists
- func NameGT(v string) predicate.Artists
- func NameGTE(v string) predicate.Artists
- func NameHasPrefix(v string) predicate.Artists
- func NameHasSuffix(v string) predicate.Artists
- func NameIn(vs ...string) predicate.Artists
- func NameLT(v string) predicate.Artists
- func NameLTE(v string) predicate.Artists
- func NameNEQ(v string) predicate.Artists
- func NameNotIn(vs ...string) predicate.Artists
- func Not(p predicate.Artists) predicate.Artists
- func Or(predicates ...predicate.Artists) predicate.Artists
- func ValidColumn(column string) bool
- type OrderOption
- func ByAlbums(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func ByAlbumsCount(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByMusics(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func ByMusicsCount(opts ...sql.OrderTermOption) OrderOption
- func ByName(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the artists type in the database. Label = "artists" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldName holds the string denoting the name field in the database. FieldName = "name" // EdgeMusics holds the string denoting the musics edge name in mutations. EdgeMusics = "musics" // EdgeAlbums holds the string denoting the albums edge name in mutations. EdgeAlbums = "albums" // Table holds the table name of the artists in the database. Table = "artists" // MusicsTable is the table that holds the musics relation/edge. The primary key declared below. MusicsTable = "artists_musics" // MusicsInverseTable is the table name for the Musics entity. // It exists in this package in order to avoid circular dependency with the "musics" package. MusicsInverseTable = "musics" // AlbumsTable is the table that holds the albums relation/edge. The primary key declared below. AlbumsTable = "artists_albums" // AlbumsInverseTable is the table name for the Albums entity. // It exists in this package in order to avoid circular dependency with the "albums" package. AlbumsInverseTable = "albums" )
Variables ¶
var ( // MusicsPrimaryKey and MusicsColumn2 are the table columns denoting the // primary key for the musics relation (M2M). MusicsPrimaryKey = []string{"artists_id", "musics_id"} // AlbumsPrimaryKey and AlbumsColumn2 are the table columns denoting the // primary key for the albums relation (M2M). AlbumsPrimaryKey = []string{"artists_id", "albums_id"} )
var Columns = []string{ FieldID, FieldName, }
Columns holds all SQL columns for artists fields.
var ( // NameValidator is a validator for the "name" field. It is called by the builders before save. NameValidator func(string) error )
Functions ¶
func HasAlbumsWith ¶
HasAlbumsWith applies the HasEdge predicate on the "albums" edge with a given conditions (other predicates).
func HasMusicsWith ¶
HasMusicsWith applies the HasEdge predicate on the "musics" 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 ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the Artists queries.
func ByAlbums ¶
func ByAlbums(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
ByAlbums orders the results by albums terms.
func ByAlbumsCount ¶
func ByAlbumsCount(opts ...sql.OrderTermOption) OrderOption
ByAlbumsCount orders the results by albums count.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByMusics ¶
func ByMusics(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
ByMusics orders the results by musics terms.
func ByMusicsCount ¶
func ByMusicsCount(opts ...sql.OrderTermOption) OrderOption
ByMusicsCount orders the results by musics count.
func ByName ¶
func ByName(opts ...sql.OrderTermOption) OrderOption
ByName orders the results by the name field.