accessory

package
v0.0.0-...-20f649f Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2023 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the accessory type in the database.
	Label = "accessory"
	// 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"
	// FieldDescription holds the string denoting the description field in the database.
	FieldDescription = "description"
	// FieldPointsRequired holds the string denoting the points_required field in the database.
	FieldPointsRequired = "points_required"
	// EdgeRedemptions holds the string denoting the redemptions edge name in mutations.
	EdgeRedemptions = "redemptions"
	// EdgeInstitution holds the string denoting the institution edge name in mutations.
	EdgeInstitution = "institution"
	// Table holds the table name of the accessory in the database.
	Table = "accessories"
	// RedemptionsTable is the table that holds the redemptions relation/edge.
	RedemptionsTable = "redemptions"
	// RedemptionsInverseTable is the table name for the Redemption entity.
	// It exists in this package in order to avoid circular dependency with the "redemption" package.
	RedemptionsInverseTable = "redemptions"
	// RedemptionsColumn is the table column denoting the redemptions relation/edge.
	RedemptionsColumn = "accessory_redemptions"
	// InstitutionTable is the table that holds the institution relation/edge.
	InstitutionTable = "accessories"
	// InstitutionInverseTable is the table name for the Institution entity.
	// It exists in this package in order to avoid circular dependency with the "entinstitution" package.
	InstitutionInverseTable = "institutions"
	// InstitutionColumn is the table column denoting the institution relation/edge.
	InstitutionColumn = "institution_accessories"
)

Variables

View Source
var (
	// NameValidator is a validator for the "name" field. It is called by the builders before save.
	NameValidator func(string) error
	// PointsRequiredValidator is a validator for the "points_required" field. It is called by the builders before save.
	PointsRequiredValidator func(int) error
)

Columns holds all SQL columns for accessory fields.

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

ForeignKeys holds the SQL foreign-keys that are owned by the "accessories" table and are not defined as standalone fields in the schema.

Functions

func And

func And(predicates ...predicate.Accessory) predicate.Accessory

And groups predicates with the AND operator between them.

func Description

func Description(v string) predicate.Accessory

Description applies equality check predicate on the "description" field. It's identical to DescriptionEQ.

func DescriptionContains

func DescriptionContains(v string) predicate.Accessory

DescriptionContains applies the Contains predicate on the "description" field.

func DescriptionContainsFold

func DescriptionContainsFold(v string) predicate.Accessory

DescriptionContainsFold applies the ContainsFold predicate on the "description" field.

func DescriptionEQ

func DescriptionEQ(v string) predicate.Accessory

DescriptionEQ applies the EQ predicate on the "description" field.

func DescriptionEqualFold

func DescriptionEqualFold(v string) predicate.Accessory

DescriptionEqualFold applies the EqualFold predicate on the "description" field.

func DescriptionGT

func DescriptionGT(v string) predicate.Accessory

DescriptionGT applies the GT predicate on the "description" field.

func DescriptionGTE

func DescriptionGTE(v string) predicate.Accessory

DescriptionGTE applies the GTE predicate on the "description" field.

func DescriptionHasPrefix

func DescriptionHasPrefix(v string) predicate.Accessory

DescriptionHasPrefix applies the HasPrefix predicate on the "description" field.

func DescriptionHasSuffix

func DescriptionHasSuffix(v string) predicate.Accessory

DescriptionHasSuffix applies the HasSuffix predicate on the "description" field.

func DescriptionIn

func DescriptionIn(vs ...string) predicate.Accessory

DescriptionIn applies the In predicate on the "description" field.

func DescriptionLT

func DescriptionLT(v string) predicate.Accessory

DescriptionLT applies the LT predicate on the "description" field.

func DescriptionLTE

func DescriptionLTE(v string) predicate.Accessory

DescriptionLTE applies the LTE predicate on the "description" field.

func DescriptionNEQ

func DescriptionNEQ(v string) predicate.Accessory

DescriptionNEQ applies the NEQ predicate on the "description" field.

func DescriptionNotIn

func DescriptionNotIn(vs ...string) predicate.Accessory

DescriptionNotIn applies the NotIn predicate on the "description" field.

func HasInstitution

func HasInstitution() predicate.Accessory

HasInstitution applies the HasEdge predicate on the "institution" edge.

func HasInstitutionWith

func HasInstitutionWith(preds ...predicate.Institution) predicate.Accessory

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

func HasRedemptions

func HasRedemptions() predicate.Accessory

HasRedemptions applies the HasEdge predicate on the "redemptions" edge.

func HasRedemptionsWith

func HasRedemptionsWith(preds ...predicate.Redemption) predicate.Accessory

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

func ID

func ID(id int) predicate.Accessory

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Accessory

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Accessory

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Accessory

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...int) predicate.Accessory

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Accessory

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Accessory

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Accessory

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...int) predicate.Accessory

IDNotIn applies the NotIn predicate on the ID field.

func Name

func Name(v string) predicate.Accessory

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

func NameContains

func NameContains(v string) predicate.Accessory

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

func NameContainsFold

func NameContainsFold(v string) predicate.Accessory

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

func NameEQ

func NameEQ(v string) predicate.Accessory

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

func NameEqualFold

func NameEqualFold(v string) predicate.Accessory

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

func NameGT

func NameGT(v string) predicate.Accessory

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

func NameGTE

func NameGTE(v string) predicate.Accessory

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

func NameHasPrefix

func NameHasPrefix(v string) predicate.Accessory

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

func NameHasSuffix

func NameHasSuffix(v string) predicate.Accessory

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

func NameIn

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

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

func NameLT

func NameLT(v string) predicate.Accessory

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

func NameLTE

func NameLTE(v string) predicate.Accessory

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

func NameNEQ

func NameNEQ(v string) predicate.Accessory

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

func NameNotIn

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

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

Or groups predicates with the OR operator between them.

func PointsRequired

func PointsRequired(v int) predicate.Accessory

PointsRequired applies equality check predicate on the "points_required" field. It's identical to PointsRequiredEQ.

func PointsRequiredEQ

func PointsRequiredEQ(v int) predicate.Accessory

PointsRequiredEQ applies the EQ predicate on the "points_required" field.

func PointsRequiredGT

func PointsRequiredGT(v int) predicate.Accessory

PointsRequiredGT applies the GT predicate on the "points_required" field.

func PointsRequiredGTE

func PointsRequiredGTE(v int) predicate.Accessory

PointsRequiredGTE applies the GTE predicate on the "points_required" field.

func PointsRequiredIn

func PointsRequiredIn(vs ...int) predicate.Accessory

PointsRequiredIn applies the In predicate on the "points_required" field.

func PointsRequiredLT

func PointsRequiredLT(v int) predicate.Accessory

PointsRequiredLT applies the LT predicate on the "points_required" field.

func PointsRequiredLTE

func PointsRequiredLTE(v int) predicate.Accessory

PointsRequiredLTE applies the LTE predicate on the "points_required" field.

func PointsRequiredNEQ

func PointsRequiredNEQ(v int) predicate.Accessory

PointsRequiredNEQ applies the NEQ predicate on the "points_required" field.

func PointsRequiredNotIn

func PointsRequiredNotIn(vs ...int) predicate.Accessory

PointsRequiredNotIn applies the NotIn predicate on the "points_required" field.

func ValidColumn

func ValidColumn(column string) bool

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

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the Accessory queries.

func ByDescription

func ByDescription(opts ...sql.OrderTermOption) OrderOption

ByDescription orders the results by the description field.

func ByID

func ByID(opts ...sql.OrderTermOption) OrderOption

ByID orders the results by the id field.

func ByInstitutionField

func ByInstitutionField(field string, opts ...sql.OrderTermOption) OrderOption

ByInstitutionField orders the results by institution field.

func ByName

func ByName(opts ...sql.OrderTermOption) OrderOption

ByName orders the results by the name field.

func ByPointsRequired

func ByPointsRequired(opts ...sql.OrderTermOption) OrderOption

ByPointsRequired orders the results by the points_required field.

func ByRedemptions

func ByRedemptions(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByRedemptions orders the results by redemptions terms.

func ByRedemptionsCount

func ByRedemptionsCount(opts ...sql.OrderTermOption) OrderOption

ByRedemptionsCount orders the results by redemptions count.

Jump to

Keyboard shortcuts

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