variant

package
v1.6.1 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the variant type in the database.
	Label = "variant"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldCode holds the string denoting the code field in the database.
	FieldCode = "code"
	// FieldName holds the string denoting the name field in the database.
	FieldName = "name"
	// FieldPrice holds the string denoting the price field in the database.
	FieldPrice = "price"

	// EdgeProduct holds the string denoting the product edge name in mutations.
	EdgeProduct = "product"

	// Table holds the table name of the variant in the database.
	Table = "variants"
	// ProductTable is the table the holds the product relation/edge.
	ProductTable = "variants"
	// ProductInverseTable is the table name for the Product entity.
	// It exists in this package in order to avoid circular dependency with the "product" package.
	ProductInverseTable = "products"
	// ProductColumn is the table column denoting the product relation/edge.
	ProductColumn = "product_variants"
)

Variables

Columns holds all SQL columns for variant fields.

View Source
var ForeignKeys = []string{
	"product_variants",
}

ForeignKeys holds the SQL foreign-keys that are owned by the Variant type.

Functions

func And

func And(predicates ...predicate.Variant) predicate.Variant

And groups predicates with the AND operator between them.

func Code

func Code(v string) predicate.Variant

Code applies equality check predicate on the "code" field. It's identical to CodeEQ.

func CodeContains

func CodeContains(v string) predicate.Variant

CodeContains applies the Contains predicate on the "code" field.

func CodeContainsFold

func CodeContainsFold(v string) predicate.Variant

CodeContainsFold applies the ContainsFold predicate on the "code" field.

func CodeEQ

func CodeEQ(v string) predicate.Variant

CodeEQ applies the EQ predicate on the "code" field.

func CodeEqualFold

func CodeEqualFold(v string) predicate.Variant

CodeEqualFold applies the EqualFold predicate on the "code" field.

func CodeGT

func CodeGT(v string) predicate.Variant

CodeGT applies the GT predicate on the "code" field.

func CodeGTE

func CodeGTE(v string) predicate.Variant

CodeGTE applies the GTE predicate on the "code" field.

func CodeHasPrefix

func CodeHasPrefix(v string) predicate.Variant

CodeHasPrefix applies the HasPrefix predicate on the "code" field.

func CodeHasSuffix

func CodeHasSuffix(v string) predicate.Variant

CodeHasSuffix applies the HasSuffix predicate on the "code" field.

func CodeIn

func CodeIn(vs ...string) predicate.Variant

CodeIn applies the In predicate on the "code" field.

func CodeLT

func CodeLT(v string) predicate.Variant

CodeLT applies the LT predicate on the "code" field.

func CodeLTE

func CodeLTE(v string) predicate.Variant

CodeLTE applies the LTE predicate on the "code" field.

func CodeNEQ

func CodeNEQ(v string) predicate.Variant

CodeNEQ applies the NEQ predicate on the "code" field.

func CodeNotIn

func CodeNotIn(vs ...string) predicate.Variant

CodeNotIn applies the NotIn predicate on the "code" field.

func HasProduct

func HasProduct() predicate.Variant

HasProduct applies the HasEdge predicate on the "product" edge.

func HasProductWith

func HasProductWith(preds ...predicate.Product) predicate.Variant

HasProductWith applies the HasEdge predicate on the "product" edge with a given conditions (other predicates).

func ID

func ID(id uuid.UUID) predicate.Variant

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id uuid.UUID) predicate.Variant

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id uuid.UUID) predicate.Variant

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id uuid.UUID) predicate.Variant

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id uuid.UUID) predicate.Variant

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id uuid.UUID) predicate.Variant

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id uuid.UUID) predicate.Variant

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func Name

func Name(v string) predicate.Variant

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

func NameContains

func NameContains(v string) predicate.Variant

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

func NameContainsFold

func NameContainsFold(v string) predicate.Variant

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

func NameEQ

func NameEQ(v string) predicate.Variant

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

func NameEqualFold

func NameEqualFold(v string) predicate.Variant

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

func NameGT

func NameGT(v string) predicate.Variant

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

func NameGTE

func NameGTE(v string) predicate.Variant

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

func NameHasPrefix

func NameHasPrefix(v string) predicate.Variant

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

func NameHasSuffix

func NameHasSuffix(v string) predicate.Variant

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

func NameIn

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

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

func NameLT

func NameLT(v string) predicate.Variant

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

func NameLTE

func NameLTE(v string) predicate.Variant

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

func NameNEQ

func NameNEQ(v string) predicate.Variant

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

func NameNotIn

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

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.Variant) predicate.Variant

Or groups predicates with the OR operator between them.

func Price

func Price(v float64) predicate.Variant

Price applies equality check predicate on the "price" field. It's identical to PriceEQ.

func PriceEQ

func PriceEQ(v float64) predicate.Variant

PriceEQ applies the EQ predicate on the "price" field.

func PriceGT

func PriceGT(v float64) predicate.Variant

PriceGT applies the GT predicate on the "price" field.

func PriceGTE

func PriceGTE(v float64) predicate.Variant

PriceGTE applies the GTE predicate on the "price" field.

func PriceIn

func PriceIn(vs ...float64) predicate.Variant

PriceIn applies the In predicate on the "price" field.

func PriceLT

func PriceLT(v float64) predicate.Variant

PriceLT applies the LT predicate on the "price" field.

func PriceLTE

func PriceLTE(v float64) predicate.Variant

PriceLTE applies the LTE predicate on the "price" field.

func PriceNEQ

func PriceNEQ(v float64) predicate.Variant

PriceNEQ applies the NEQ predicate on the "price" field.

func PriceNotIn

func PriceNotIn(vs ...float64) predicate.Variant

PriceNotIn applies the NotIn predicate on the "price" field.

func ValidColumn

func ValidColumn(column string) bool

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

Types

This section is empty.

Jump to

Keyboard shortcuts

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