location

package
v0.8.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 5, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
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

View Source
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
)

Columns holds all SQL columns for location fields.

Functions

func And

func And(predicates ...predicate.Location) predicate.Location

And groups predicates with the AND operator between them.

func ExternalID

func ExternalID(v int) predicate.Location

ExternalID applies equality check predicate on the "external_id" field. It's identical to ExternalIDEQ.

func ExternalIDEQ

func ExternalIDEQ(v int) predicate.Location

ExternalIDEQ applies the EQ predicate on the "external_id" field.

func ExternalIDGT

func ExternalIDGT(v int) predicate.Location

ExternalIDGT applies the GT predicate on the "external_id" field.

func ExternalIDGTE

func ExternalIDGTE(v int) predicate.Location

ExternalIDGTE applies the GTE predicate on the "external_id" field.

func ExternalIDIn

func ExternalIDIn(vs ...int) predicate.Location

ExternalIDIn applies the In predicate on the "external_id" field.

func ExternalIDLT

func ExternalIDLT(v int) predicate.Location

ExternalIDLT applies the LT predicate on the "external_id" field.

func ExternalIDLTE

func ExternalIDLTE(v int) predicate.Location

ExternalIDLTE applies the LTE predicate on the "external_id" field.

func ExternalIDNEQ

func ExternalIDNEQ(v int) predicate.Location

ExternalIDNEQ applies the NEQ predicate on the "external_id" field.

func ExternalIDNotIn

func ExternalIDNotIn(vs ...int) predicate.Location

ExternalIDNotIn applies the NotIn predicate on the "external_id" field.

func HasOccurrences

func HasOccurrences() predicate.Location

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 ID

func ID(id uuid.UUID) predicate.Location

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id uuid.UUID) predicate.Location

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id uuid.UUID) predicate.Location

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id uuid.UUID) predicate.Location

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...uuid.UUID) predicate.Location

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id uuid.UUID) predicate.Location

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id uuid.UUID) predicate.Location

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id uuid.UUID) predicate.Location

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...uuid.UUID) predicate.Location

IDNotIn applies the NotIn predicate on the ID field.

func Name

func Name(v string) predicate.Location

Name applies equality check predicate on the "name" field. It's identical to NameEQ.

func NameContains

func NameContains(v string) predicate.Location

NameContains applies the Contains predicate on the "name" field.

func NameContainsFold

func NameContainsFold(v string) predicate.Location

NameContainsFold applies the ContainsFold predicate on the "name" field.

func NameEQ

func NameEQ(v string) predicate.Location

NameEQ applies the EQ predicate on the "name" field.

func NameEqualFold

func NameEqualFold(v string) predicate.Location

NameEqualFold applies the EqualFold predicate on the "name" field.

func NameGT

func NameGT(v string) predicate.Location

NameGT applies the GT predicate on the "name" field.

func NameGTE

func NameGTE(v string) predicate.Location

NameGTE applies the GTE predicate on the "name" field.

func NameHasPrefix

func NameHasPrefix(v string) predicate.Location

NameHasPrefix applies the HasPrefix predicate on the "name" field.

func NameHasSuffix

func NameHasSuffix(v string) predicate.Location

NameHasSuffix applies the HasSuffix predicate on the "name" field.

func NameIn

func NameIn(vs ...string) predicate.Location

NameIn applies the In predicate on the "name" field.

func NameLT

func NameLT(v string) predicate.Location

NameLT applies the LT predicate on the "name" field.

func NameLTE

func NameLTE(v string) predicate.Location

NameLTE applies the LTE predicate on the "name" field.

func NameNEQ

func NameNEQ(v string) predicate.Location

NameNEQ applies the NEQ predicate on the "name" field.

func NameNotIn

func NameNotIn(vs ...string) predicate.Location

NameNotIn applies the NotIn predicate on the "name" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Location) predicate.Location

Or groups predicates with the OR operator between them.

func ValidColumn

func ValidColumn(column string) bool

ValidColumn reports if the column name is valid (part of the table columns).

func Visible

func Visible(v bool) predicate.Location

Visible applies equality check predicate on the "visible" field. It's identical to VisibleEQ.

func VisibleEQ

func VisibleEQ(v bool) predicate.Location

VisibleEQ applies the EQ predicate on the "visible" field.

func VisibleNEQ

func VisibleNEQ(v bool) predicate.Location

VisibleNEQ applies the NEQ predicate on the "visible" field.

Types

type OrderOption

type OrderOption func(*sql.Selector)

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL