Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Vote) predicate.Vote
- func HasUser() predicate.Vote
- func HasUserWith(preds ...predicate.User) predicate.Vote
- func ID(id int) predicate.Vote
- func IDEQ(id int) predicate.Vote
- func IDGT(id int) predicate.Vote
- func IDGTE(id int) predicate.Vote
- func IDIn(ids ...int) predicate.Vote
- func IDLT(id int) predicate.Vote
- func IDLTE(id int) predicate.Vote
- func IDNEQ(id int) predicate.Vote
- func IDNotIn(ids ...int) predicate.Vote
- func Not(p predicate.Vote) predicate.Vote
- func Or(predicates ...predicate.Vote) predicate.Vote
- func Rank(v int) predicate.Vote
- func RankEQ(v int) predicate.Vote
- func RankGT(v int) predicate.Vote
- func RankGTE(v int) predicate.Vote
- func RankIn(vs ...int) predicate.Vote
- func RankLT(v int) predicate.Vote
- func RankLTE(v int) predicate.Vote
- func RankNEQ(v int) predicate.Vote
- func RankNotIn(vs ...int) predicate.Vote
- func Selection(v string) predicate.Vote
- func SelectionContains(v string) predicate.Vote
- func SelectionContainsFold(v string) predicate.Vote
- func SelectionEQ(v string) predicate.Vote
- func SelectionEqualFold(v string) predicate.Vote
- func SelectionGT(v string) predicate.Vote
- func SelectionGTE(v string) predicate.Vote
- func SelectionHasPrefix(v string) predicate.Vote
- func SelectionHasSuffix(v string) predicate.Vote
- func SelectionIn(vs ...string) predicate.Vote
- func SelectionLT(v string) predicate.Vote
- func SelectionLTE(v string) predicate.Vote
- func SelectionNEQ(v string) predicate.Vote
- func SelectionNotIn(vs ...string) predicate.Vote
- func ValidColumn(column string) bool
- func VoteID(v string) predicate.Vote
- func VoteIDContains(v string) predicate.Vote
- func VoteIDContainsFold(v string) predicate.Vote
- func VoteIDEQ(v string) predicate.Vote
- func VoteIDEqualFold(v string) predicate.Vote
- func VoteIDGT(v string) predicate.Vote
- func VoteIDGTE(v string) predicate.Vote
- func VoteIDHasPrefix(v string) predicate.Vote
- func VoteIDHasSuffix(v string) predicate.Vote
- func VoteIDIn(vs ...string) predicate.Vote
- func VoteIDLT(v string) predicate.Vote
- func VoteIDLTE(v string) predicate.Vote
- func VoteIDNEQ(v string) predicate.Vote
- func VoteIDNotIn(vs ...string) predicate.Vote
- type OrderOption
Constants ¶
const ( // Label holds the string label denoting the vote type in the database. Label = "vote" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldSelection holds the string denoting the selection field in the database. FieldSelection = "selection" // FieldRank holds the string denoting the rank field in the database. FieldRank = "rank" // FieldVoteID holds the string denoting the vote_id field in the database. FieldVoteID = "vote_id" // EdgeUser holds the string denoting the user edge name in mutations. EdgeUser = "user" // Table holds the table name of the vote in the database. Table = "votes" // UserTable is the table that holds the user relation/edge. UserTable = "votes" // UserInverseTable is the table name for the User entity. // It exists in this package in order to avoid circular dependency with the "user" package. UserInverseTable = "users" // UserColumn is the table column denoting the user relation/edge. UserColumn = "user_votes" )
Variables ¶
var ( // SelectionValidator is a validator for the "selection" field. It is called by the builders before save. SelectionValidator func(string) error // RankValidator is a validator for the "rank" field. It is called by the builders before save. RankValidator func(int) error // VoteIDValidator is a validator for the "vote_id" field. It is called by the builders before save. VoteIDValidator func(string) error )
var Columns = []string{ FieldID, FieldSelection, FieldRank, FieldVoteID, }
Columns holds all SQL columns for vote fields.
var ForeignKeys = []string{
"user_votes",
}
ForeignKeys holds the SQL foreign-keys that are owned by the "votes" table and are not defined as standalone fields in the schema.
Functions ¶
func HasUserWith ¶
HasUserWith applies the HasEdge predicate on the "user" edge with a given conditions (other predicates).
func Selection ¶
Selection applies equality check predicate on the "selection" field. It's identical to SelectionEQ.
func SelectionContains ¶
SelectionContains applies the Contains predicate on the "selection" field.
func SelectionContainsFold ¶
SelectionContainsFold applies the ContainsFold predicate on the "selection" field.
func SelectionEQ ¶
SelectionEQ applies the EQ predicate on the "selection" field.
func SelectionEqualFold ¶
SelectionEqualFold applies the EqualFold predicate on the "selection" field.
func SelectionGT ¶
SelectionGT applies the GT predicate on the "selection" field.
func SelectionGTE ¶
SelectionGTE applies the GTE predicate on the "selection" field.
func SelectionHasPrefix ¶
SelectionHasPrefix applies the HasPrefix predicate on the "selection" field.
func SelectionHasSuffix ¶
SelectionHasSuffix applies the HasSuffix predicate on the "selection" field.
func SelectionIn ¶
SelectionIn applies the In predicate on the "selection" field.
func SelectionLT ¶
SelectionLT applies the LT predicate on the "selection" field.
func SelectionLTE ¶
SelectionLTE applies the LTE predicate on the "selection" field.
func SelectionNEQ ¶
SelectionNEQ applies the NEQ predicate on the "selection" field.
func SelectionNotIn ¶
SelectionNotIn applies the NotIn predicate on the "selection" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
func VoteID ¶
VoteID applies equality check predicate on the "vote_id" field. It's identical to VoteIDEQ.
func VoteIDContains ¶
VoteIDContains applies the Contains predicate on the "vote_id" field.
func VoteIDContainsFold ¶
VoteIDContainsFold applies the ContainsFold predicate on the "vote_id" field.
func VoteIDEqualFold ¶
VoteIDEqualFold applies the EqualFold predicate on the "vote_id" field.
func VoteIDHasPrefix ¶
VoteIDHasPrefix applies the HasPrefix predicate on the "vote_id" field.
func VoteIDHasSuffix ¶
VoteIDHasSuffix applies the HasSuffix predicate on the "vote_id" field.
func VoteIDNotIn ¶
VoteIDNotIn applies the NotIn predicate on the "vote_id" field.
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the Vote queries.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByRank ¶
func ByRank(opts ...sql.OrderTermOption) OrderOption
ByRank orders the results by the rank field.
func BySelection ¶
func BySelection(opts ...sql.OrderTermOption) OrderOption
BySelection orders the results by the selection field.
func ByUserField ¶
func ByUserField(field string, opts ...sql.OrderTermOption) OrderOption
ByUserField orders the results by user field.
func ByVoteID ¶
func ByVoteID(opts ...sql.OrderTermOption) OrderOption
ByVoteID orders the results by the vote_id field.