Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Location) predicate.Location
- func ExternalID(v int) predicate.Location
- func ExternalIDEQ(v int) predicate.Location
- func ExternalIDGT(v int) predicate.Location
- func ExternalIDGTE(v int) predicate.Location
- func ExternalIDIn(vs ...int) predicate.Location
- func ExternalIDLT(v int) predicate.Location
- func ExternalIDLTE(v int) predicate.Location
- func ExternalIDNEQ(v int) predicate.Location
- func ExternalIDNotIn(vs ...int) predicate.Location
- func HasOccurrences() predicate.Location
- func HasOccurrencesWith(preds ...predicate.Occurrence) predicate.Location
- func ID(id uuid.UUID) predicate.Location
- func IDEQ(id uuid.UUID) predicate.Location
- func IDGT(id uuid.UUID) predicate.Location
- func IDGTE(id uuid.UUID) predicate.Location
- func IDIn(ids ...uuid.UUID) predicate.Location
- func IDLT(id uuid.UUID) predicate.Location
- func IDLTE(id uuid.UUID) predicate.Location
- func IDNEQ(id uuid.UUID) predicate.Location
- func IDNotIn(ids ...uuid.UUID) predicate.Location
- func Name(v string) predicate.Location
- func NameContains(v string) predicate.Location
- func NameContainsFold(v string) predicate.Location
- func NameEQ(v string) predicate.Location
- func NameEqualFold(v string) predicate.Location
- func NameGT(v string) predicate.Location
- func NameGTE(v string) predicate.Location
- func NameHasPrefix(v string) predicate.Location
- func NameHasSuffix(v string) predicate.Location
- func NameIn(vs ...string) predicate.Location
- func NameLT(v string) predicate.Location
- func NameLTE(v string) predicate.Location
- func NameNEQ(v string) predicate.Location
- func NameNotIn(vs ...string) predicate.Location
- func Not(p predicate.Location) predicate.Location
- func Or(predicates ...predicate.Location) predicate.Location
- func ValidColumn(column string) bool
- func Visible(v bool) predicate.Location
- func VisibleEQ(v bool) predicate.Location
- func VisibleNEQ(v bool) predicate.Location
- type OrderOption
- func ByExternalID(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByName(opts ...sql.OrderTermOption) OrderOption
- func ByOccurrences(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func ByOccurrencesCount(opts ...sql.OrderTermOption) OrderOption
- func ByVisible(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the location type in the database. Label = "location" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldExternalID holds the string denoting the external_id field in the database. FieldExternalID = "external_id" // FieldName holds the string denoting the name field in the database. FieldName = "name" // FieldVisible holds the string denoting the visible field in the database. FieldVisible = "visible" // EdgeOccurrences holds the string denoting the occurrences edge name in mutations. EdgeOccurrences = "occurrences" // Table holds the table name of the location in the database. Table = "location" // OccurrencesTable is the table that holds the occurrences relation/edge. OccurrencesTable = "occurrence" // OccurrencesInverseTable is the table name for the Occurrence entity. // It exists in this package in order to avoid circular dependency with the "occurrence" package. OccurrencesInverseTable = "occurrence" // OccurrencesColumn is the table column denoting the occurrences relation/edge. OccurrencesColumn = "location" )
Variables ¶
var ( // NameValidator is a validator for the "name" field. It is called by the builders before save. NameValidator func(string) error // DefaultVisible holds the default value on creation for the "visible" field. DefaultVisible bool // DefaultID holds the default value on creation for the "id" field. DefaultID func() uuid.UUID )
var Columns = []string{ FieldID, FieldExternalID, FieldName, FieldVisible, }
Columns holds all SQL columns for location fields.
Functions ¶
func ExternalID ¶
ExternalID applies equality check predicate on the "external_id" field. It's identical to ExternalIDEQ.
func ExternalIDEQ ¶
ExternalIDEQ applies the EQ predicate on the "external_id" field.
func ExternalIDGT ¶
ExternalIDGT applies the GT predicate on the "external_id" field.
func ExternalIDGTE ¶
ExternalIDGTE applies the GTE predicate on the "external_id" field.
func ExternalIDIn ¶
ExternalIDIn applies the In predicate on the "external_id" field.
func ExternalIDLT ¶
ExternalIDLT applies the LT predicate on the "external_id" field.
func ExternalIDLTE ¶
ExternalIDLTE applies the LTE predicate on the "external_id" field.
func ExternalIDNEQ ¶
ExternalIDNEQ applies the NEQ predicate on the "external_id" field.
func ExternalIDNotIn ¶
ExternalIDNotIn applies the NotIn predicate on the "external_id" field.
func HasOccurrences ¶
HasOccurrences applies the HasEdge predicate on the "occurrences" edge.
func HasOccurrencesWith ¶
func HasOccurrencesWith(preds ...predicate.Occurrence) predicate.Location
HasOccurrencesWith applies the HasEdge predicate on the "occurrences" 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).
func Visible ¶
Visible applies equality check predicate on the "visible" field. It's identical to VisibleEQ.
func VisibleNEQ ¶
VisibleNEQ applies the NEQ predicate on the "visible" field.
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the Location queries.
func ByExternalID ¶
func ByExternalID(opts ...sql.OrderTermOption) OrderOption
ByExternalID orders the results by the external_id 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 ByOccurrences ¶
func ByOccurrences(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
ByOccurrences orders the results by occurrences terms.
func ByOccurrencesCount ¶
func ByOccurrencesCount(opts ...sql.OrderTermOption) OrderOption
ByOccurrencesCount orders the results by occurrences count.
func ByVisible ¶
func ByVisible(opts ...sql.OrderTermOption) OrderOption
ByVisible orders the results by the visible field.