model

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the model type in the database.
	Label = "model"
	// 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"
	// FieldTitle holds the string denoting the title field in the database.
	FieldTitle = "title"
	// FieldFax holds the string denoting the fax field in the database.
	FieldFax = "fax"
	// FieldWeb holds the string denoting the web field in the database.
	FieldWeb = "web"
	// FieldAge holds the string denoting the age field in the database.
	FieldAge = "age"
	// FieldRight holds the string denoting the right field in the database.
	FieldRight = "right"
	// FieldCounter holds the string denoting the counter field in the database.
	FieldCounter = "counter"
	// Table holds the table name of the model in the database.
	Table = "models"
)

Variables

Columns holds all SQL columns for model fields.

Functions

func Age

func Age(v int) predicate.Model

Age applies equality check predicate on the "age" field. It's identical to AgeEQ.

func AgeEQ

func AgeEQ(v int) predicate.Model

AgeEQ applies the EQ predicate on the "age" field.

func AgeGT

func AgeGT(v int) predicate.Model

AgeGT applies the GT predicate on the "age" field.

func AgeGTE

func AgeGTE(v int) predicate.Model

AgeGTE applies the GTE predicate on the "age" field.

func AgeIn

func AgeIn(vs ...int) predicate.Model

AgeIn applies the In predicate on the "age" field.

func AgeLT

func AgeLT(v int) predicate.Model

AgeLT applies the LT predicate on the "age" field.

func AgeLTE

func AgeLTE(v int) predicate.Model

AgeLTE applies the LTE predicate on the "age" field.

func AgeNEQ

func AgeNEQ(v int) predicate.Model

AgeNEQ applies the NEQ predicate on the "age" field.

func AgeNotIn

func AgeNotIn(vs ...int) predicate.Model

AgeNotIn applies the NotIn predicate on the "age" field.

func And

func And(predicates ...predicate.Model) predicate.Model

And groups predicates with the AND operator between them.

func Counter

func Counter(v int64) predicate.Model

Counter applies equality check predicate on the "counter" field. It's identical to CounterEQ.

func CounterEQ

func CounterEQ(v int64) predicate.Model

CounterEQ applies the EQ predicate on the "counter" field.

func CounterGT

func CounterGT(v int64) predicate.Model

CounterGT applies the GT predicate on the "counter" field.

func CounterGTE

func CounterGTE(v int64) predicate.Model

CounterGTE applies the GTE predicate on the "counter" field.

func CounterIn

func CounterIn(vs ...int64) predicate.Model

CounterIn applies the In predicate on the "counter" field.

func CounterLT

func CounterLT(v int64) predicate.Model

CounterLT applies the LT predicate on the "counter" field.

func CounterLTE

func CounterLTE(v int64) predicate.Model

CounterLTE applies the LTE predicate on the "counter" field.

func CounterNEQ

func CounterNEQ(v int64) predicate.Model

CounterNEQ applies the NEQ predicate on the "counter" field.

func CounterNotIn

func CounterNotIn(vs ...int64) predicate.Model

CounterNotIn applies the NotIn predicate on the "counter" field.

func Fax

func Fax(v string) predicate.Model

Fax applies equality check predicate on the "fax" field. It's identical to FaxEQ.

func FaxContains

func FaxContains(v string) predicate.Model

FaxContains applies the Contains predicate on the "fax" field.

func FaxContainsFold

func FaxContainsFold(v string) predicate.Model

FaxContainsFold applies the ContainsFold predicate on the "fax" field.

func FaxEQ

func FaxEQ(v string) predicate.Model

FaxEQ applies the EQ predicate on the "fax" field.

func FaxEqualFold

func FaxEqualFold(v string) predicate.Model

FaxEqualFold applies the EqualFold predicate on the "fax" field.

func FaxGT

func FaxGT(v string) predicate.Model

FaxGT applies the GT predicate on the "fax" field.

func FaxGTE

func FaxGTE(v string) predicate.Model

FaxGTE applies the GTE predicate on the "fax" field.

func FaxHasPrefix

func FaxHasPrefix(v string) predicate.Model

FaxHasPrefix applies the HasPrefix predicate on the "fax" field.

func FaxHasSuffix

func FaxHasSuffix(v string) predicate.Model

FaxHasSuffix applies the HasSuffix predicate on the "fax" field.

func FaxIn

func FaxIn(vs ...string) predicate.Model

FaxIn applies the In predicate on the "fax" field.

func FaxLT

func FaxLT(v string) predicate.Model

FaxLT applies the LT predicate on the "fax" field.

func FaxLTE

func FaxLTE(v string) predicate.Model

FaxLTE applies the LTE predicate on the "fax" field.

func FaxNEQ

func FaxNEQ(v string) predicate.Model

FaxNEQ applies the NEQ predicate on the "fax" field.

func FaxNotIn

func FaxNotIn(vs ...string) predicate.Model

FaxNotIn applies the NotIn predicate on the "fax" field.

func ID

func ID(id int) predicate.Model

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Model

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Model

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Model

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Model

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Model

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Model

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func Name

func Name(v string) predicate.Model

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

func NameContains

func NameContains(v string) predicate.Model

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

func NameContainsFold

func NameContainsFold(v string) predicate.Model

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

func NameEQ

func NameEQ(v string) predicate.Model

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

func NameEqualFold

func NameEqualFold(v string) predicate.Model

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

func NameGT

func NameGT(v string) predicate.Model

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

func NameGTE

func NameGTE(v string) predicate.Model

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

func NameHasPrefix

func NameHasPrefix(v string) predicate.Model

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

func NameHasSuffix

func NameHasSuffix(v string) predicate.Model

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

func NameIn

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

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

func NameLT

func NameLT(v string) predicate.Model

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

func NameLTE

func NameLTE(v string) predicate.Model

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

func NameNEQ

func NameNEQ(v string) predicate.Model

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

func NameNotIn

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

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

Or groups predicates with the OR operator between them.

func Right(v bool) predicate.Model

Right applies equality check predicate on the "right" field. It's identical to RightEQ.

func RightEQ

func RightEQ(v bool) predicate.Model

RightEQ applies the EQ predicate on the "right" field.

func RightNEQ

func RightNEQ(v bool) predicate.Model

RightNEQ applies the NEQ predicate on the "right" field.

func Title

func Title(v string) predicate.Model

Title applies equality check predicate on the "title" field. It's identical to TitleEQ.

func TitleContains

func TitleContains(v string) predicate.Model

TitleContains applies the Contains predicate on the "title" field.

func TitleContainsFold

func TitleContainsFold(v string) predicate.Model

TitleContainsFold applies the ContainsFold predicate on the "title" field.

func TitleEQ

func TitleEQ(v string) predicate.Model

TitleEQ applies the EQ predicate on the "title" field.

func TitleEqualFold

func TitleEqualFold(v string) predicate.Model

TitleEqualFold applies the EqualFold predicate on the "title" field.

func TitleGT

func TitleGT(v string) predicate.Model

TitleGT applies the GT predicate on the "title" field.

func TitleGTE

func TitleGTE(v string) predicate.Model

TitleGTE applies the GTE predicate on the "title" field.

func TitleHasPrefix

func TitleHasPrefix(v string) predicate.Model

TitleHasPrefix applies the HasPrefix predicate on the "title" field.

func TitleHasSuffix

func TitleHasSuffix(v string) predicate.Model

TitleHasSuffix applies the HasSuffix predicate on the "title" field.

func TitleIn

func TitleIn(vs ...string) predicate.Model

TitleIn applies the In predicate on the "title" field.

func TitleLT

func TitleLT(v string) predicate.Model

TitleLT applies the LT predicate on the "title" field.

func TitleLTE

func TitleLTE(v string) predicate.Model

TitleLTE applies the LTE predicate on the "title" field.

func TitleNEQ

func TitleNEQ(v string) predicate.Model

TitleNEQ applies the NEQ predicate on the "title" field.

func TitleNotIn

func TitleNotIn(vs ...string) predicate.Model

TitleNotIn applies the NotIn predicate on the "title" field.

func ValidColumn

func ValidColumn(column string) bool

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

func Web

func Web(v string) predicate.Model

Web applies equality check predicate on the "web" field. It's identical to WebEQ.

func WebContains

func WebContains(v string) predicate.Model

WebContains applies the Contains predicate on the "web" field.

func WebContainsFold

func WebContainsFold(v string) predicate.Model

WebContainsFold applies the ContainsFold predicate on the "web" field.

func WebEQ

func WebEQ(v string) predicate.Model

WebEQ applies the EQ predicate on the "web" field.

func WebEqualFold

func WebEqualFold(v string) predicate.Model

WebEqualFold applies the EqualFold predicate on the "web" field.

func WebGT

func WebGT(v string) predicate.Model

WebGT applies the GT predicate on the "web" field.

func WebGTE

func WebGTE(v string) predicate.Model

WebGTE applies the GTE predicate on the "web" field.

func WebHasPrefix

func WebHasPrefix(v string) predicate.Model

WebHasPrefix applies the HasPrefix predicate on the "web" field.

func WebHasSuffix

func WebHasSuffix(v string) predicate.Model

WebHasSuffix applies the HasSuffix predicate on the "web" field.

func WebIn

func WebIn(vs ...string) predicate.Model

WebIn applies the In predicate on the "web" field.

func WebLT

func WebLT(v string) predicate.Model

WebLT applies the LT predicate on the "web" field.

func WebLTE

func WebLTE(v string) predicate.Model

WebLTE applies the LTE predicate on the "web" field.

func WebNEQ

func WebNEQ(v string) predicate.Model

WebNEQ applies the NEQ predicate on the "web" field.

func WebNotIn

func WebNotIn(vs ...string) predicate.Model

WebNotIn applies the NotIn predicate on the "web" field.

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the Model queries.

func ByAge

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

ByAge orders the results by the age field.

func ByCounter

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

ByCounter orders the results by the counter field.

func ByFax

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

ByFax orders the results by the fax 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 ByRight

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

ByRight orders the results by the right field.

func ByTitle

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

ByTitle orders the results by the title field.

func ByWeb

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

ByWeb orders the results by the web field.

Jump to

Keyboard shortcuts

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