Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Scale) predicate.Scale
- func Code(v string) predicate.Scale
- func CodeContains(v string) predicate.Scale
- func CodeContainsFold(v string) predicate.Scale
- func CodeEQ(v string) predicate.Scale
- func CodeEqualFold(v string) predicate.Scale
- func CodeGT(v string) predicate.Scale
- func CodeGTE(v string) predicate.Scale
- func CodeHasPrefix(v string) predicate.Scale
- func CodeHasSuffix(v string) predicate.Scale
- func CodeIn(vs ...string) predicate.Scale
- func CodeLT(v string) predicate.Scale
- func CodeLTE(v string) predicate.Scale
- func CodeNEQ(v string) predicate.Scale
- func CodeNotIn(vs ...string) predicate.Scale
- func CreateTime(v time.Time) predicate.Scale
- func CreateTimeEQ(v time.Time) predicate.Scale
- func CreateTimeGT(v time.Time) predicate.Scale
- func CreateTimeGTE(v time.Time) predicate.Scale
- func CreateTimeIn(vs ...time.Time) predicate.Scale
- func CreateTimeLT(v time.Time) predicate.Scale
- func CreateTimeLTE(v time.Time) predicate.Scale
- func CreateTimeNEQ(v time.Time) predicate.Scale
- func CreateTimeNotIn(vs ...time.Time) predicate.Scale
- func Global(v bool) predicate.Scale
- func GlobalEQ(v bool) predicate.Scale
- func GlobalNEQ(v bool) predicate.Scale
- func HasInterpretations() predicate.Scale
- func HasInterpretationsWith(preds ...predicate.Interpretation) predicate.Scale
- func HasItems() predicate.Scale
- func HasItemsWith(preds ...predicate.Item) predicate.Scale
- func HasNorms() predicate.Scale
- func HasNormsWith(preds ...predicate.Norm) predicate.Scale
- func HasResults() predicate.Scale
- func HasResultsWith(preds ...predicate.Result) predicate.Scale
- func HasScaleItem() predicate.Scale
- func HasScaleItemWith(preds ...predicate.ScaleItem) predicate.Scale
- func HasTest() predicate.Scale
- func HasTestWith(preds ...predicate.Test) predicate.Scale
- func HasTranslations() predicate.Scale
- func HasTranslationsWith(preds ...predicate.ScaleTranslation) predicate.Scale
- func ID(id uuid.UUID) predicate.Scale
- func IDEQ(id uuid.UUID) predicate.Scale
- func IDGT(id uuid.UUID) predicate.Scale
- func IDGTE(id uuid.UUID) predicate.Scale
- func IDIn(ids ...uuid.UUID) predicate.Scale
- func IDLT(id uuid.UUID) predicate.Scale
- func IDLTE(id uuid.UUID) predicate.Scale
- func IDNEQ(id uuid.UUID) predicate.Scale
- func IDNotIn(ids ...uuid.UUID) predicate.Scale
- func Not(p predicate.Scale) predicate.Scale
- func Or(predicates ...predicate.Scale) predicate.Scale
- func TypeEQ(v Type) predicate.Scale
- func TypeIn(vs ...Type) predicate.Scale
- func TypeNEQ(v Type) predicate.Scale
- func TypeNotIn(vs ...Type) predicate.Scale
- func TypeValidator(_type Type) error
- func UpdateTime(v time.Time) predicate.Scale
- func UpdateTimeEQ(v time.Time) predicate.Scale
- func UpdateTimeGT(v time.Time) predicate.Scale
- func UpdateTimeGTE(v time.Time) predicate.Scale
- func UpdateTimeIn(vs ...time.Time) predicate.Scale
- func UpdateTimeLT(v time.Time) predicate.Scale
- func UpdateTimeLTE(v time.Time) predicate.Scale
- func UpdateTimeNEQ(v time.Time) predicate.Scale
- func UpdateTimeNotIn(vs ...time.Time) predicate.Scale
- func ValidColumn(column string) bool
- type Type
Constants ¶
const ( // Label holds the string label denoting the scale type in the database. Label = "scale" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldCreateTime holds the string denoting the create_time field in the database. FieldCreateTime = "create_time" // FieldUpdateTime holds the string denoting the update_time field in the database. FieldUpdateTime = "update_time" // FieldCode holds the string denoting the code field in the database. FieldCode = "code" // FieldGlobal holds the string denoting the global field in the database. FieldGlobal = "global" // FieldType holds the string denoting the type field in the database. FieldType = "type" // EdgeItems holds the string denoting the items edge name in mutations. EdgeItems = "items" // EdgeInterpretations holds the string denoting the interpretations edge name in mutations. EdgeInterpretations = "interpretations" // EdgeTranslations holds the string denoting the translations edge name in mutations. EdgeTranslations = "translations" // EdgeNorms holds the string denoting the norms edge name in mutations. EdgeNorms = "norms" // EdgeResults holds the string denoting the results edge name in mutations. EdgeResults = "results" // EdgeTest holds the string denoting the test edge name in mutations. EdgeTest = "test" // EdgeScaleItem holds the string denoting the scale_item edge name in mutations. EdgeScaleItem = "scale_item" // Table holds the table name of the scale in the database. Table = "scales" // ItemsTable is the table that holds the items relation/edge. The primary key declared below. ItemsTable = "scale_items" // ItemsInverseTable is the table name for the Item entity. // It exists in this package in order to avoid circular dependency with the "item" package. ItemsInverseTable = "items" // InterpretationsTable is the table that holds the interpretations relation/edge. InterpretationsTable = "interpretations" // InterpretationsInverseTable is the table name for the Interpretation entity. // It exists in this package in order to avoid circular dependency with the "interpretation" package. InterpretationsInverseTable = "interpretations" // InterpretationsColumn is the table column denoting the interpretations relation/edge. InterpretationsColumn = "scale_interpretations" // TranslationsTable is the table that holds the translations relation/edge. TranslationsTable = "scale_translations" // TranslationsInverseTable is the table name for the ScaleTranslation entity. // It exists in this package in order to avoid circular dependency with the "scaletranslation" package. TranslationsInverseTable = "scale_translations" // TranslationsColumn is the table column denoting the translations relation/edge. TranslationsColumn = "scale_translations" // NormsTable is the table that holds the norms relation/edge. NormsTable = "norms" // NormsInverseTable is the table name for the Norm entity. // It exists in this package in order to avoid circular dependency with the "norm" package. NormsInverseTable = "norms" // NormsColumn is the table column denoting the norms relation/edge. NormsColumn = "scale_norms" // ResultsTable is the table that holds the results relation/edge. ResultsTable = "results" // ResultsInverseTable is the table name for the Result entity. // It exists in this package in order to avoid circular dependency with the "result" package. ResultsInverseTable = "results" // ResultsColumn is the table column denoting the results relation/edge. ResultsColumn = "scale_results" // TestTable is the table that holds the test relation/edge. The primary key declared below. TestTable = "test_scales" // TestInverseTable is the table name for the Test entity. // It exists in this package in order to avoid circular dependency with the "test" package. TestInverseTable = "tests" // ScaleItemTable is the table that holds the scale_item relation/edge. ScaleItemTable = "scale_items" // ScaleItemInverseTable is the table name for the ScaleItem entity. // It exists in this package in order to avoid circular dependency with the "scaleitem" package. ScaleItemInverseTable = "scale_items" // ScaleItemColumn is the table column denoting the scale_item relation/edge. ScaleItemColumn = "scale_id" )
const DefaultType = TypeSten
TypeSten is the default value of the Type enum.
Variables ¶
var ( // ItemsPrimaryKey and ItemsColumn2 are the table columns denoting the // primary key for the items relation (M2M). ItemsPrimaryKey = []string{"scale_id", "item_id"} // TestPrimaryKey and TestColumn2 are the table columns denoting the // primary key for the test relation (M2M). TestPrimaryKey = []string{"test_id", "scale_id"} )
var ( // DefaultCreateTime holds the default value on creation for the "create_time" field. DefaultCreateTime func() time.Time // DefaultUpdateTime holds the default value on creation for the "update_time" field. DefaultUpdateTime func() time.Time // UpdateDefaultUpdateTime holds the default value on update for the "update_time" field. UpdateDefaultUpdateTime func() time.Time // CodeValidator is a validator for the "code" field. It is called by the builders before save. CodeValidator func(string) error // DefaultGlobal holds the default value on creation for the "global" field. DefaultGlobal bool // DefaultID holds the default value on creation for the "id" field. DefaultID func() uuid.UUID )
var Columns = []string{ FieldID, FieldCreateTime, FieldUpdateTime, FieldCode, FieldGlobal, FieldType, }
Columns holds all SQL columns for scale fields.
Functions ¶
func CodeContains ¶
CodeContains applies the Contains predicate on the "code" field.
func CodeContainsFold ¶
CodeContainsFold applies the ContainsFold predicate on the "code" field.
func CodeEqualFold ¶
CodeEqualFold applies the EqualFold predicate on the "code" field.
func CodeHasPrefix ¶
CodeHasPrefix applies the HasPrefix predicate on the "code" field.
func CodeHasSuffix ¶
CodeHasSuffix applies the HasSuffix predicate on the "code" field.
func CreateTime ¶
CreateTime applies equality check predicate on the "create_time" field. It's identical to CreateTimeEQ.
func CreateTimeEQ ¶
CreateTimeEQ applies the EQ predicate on the "create_time" field.
func CreateTimeGT ¶
CreateTimeGT applies the GT predicate on the "create_time" field.
func CreateTimeGTE ¶
CreateTimeGTE applies the GTE predicate on the "create_time" field.
func CreateTimeIn ¶
CreateTimeIn applies the In predicate on the "create_time" field.
func CreateTimeLT ¶
CreateTimeLT applies the LT predicate on the "create_time" field.
func CreateTimeLTE ¶
CreateTimeLTE applies the LTE predicate on the "create_time" field.
func CreateTimeNEQ ¶
CreateTimeNEQ applies the NEQ predicate on the "create_time" field.
func CreateTimeNotIn ¶
CreateTimeNotIn applies the NotIn predicate on the "create_time" field.
func Global ¶
Global applies equality check predicate on the "global" field. It's identical to GlobalEQ.
func HasInterpretations ¶
HasInterpretations applies the HasEdge predicate on the "interpretations" edge.
func HasInterpretationsWith ¶
func HasInterpretationsWith(preds ...predicate.Interpretation) predicate.Scale
HasInterpretationsWith applies the HasEdge predicate on the "interpretations" edge with a given conditions (other predicates).
func HasItemsWith ¶
HasItemsWith applies the HasEdge predicate on the "items" edge with a given conditions (other predicates).
func HasNormsWith ¶
HasNormsWith applies the HasEdge predicate on the "norms" edge with a given conditions (other predicates).
func HasResults ¶
HasResults applies the HasEdge predicate on the "results" edge.
func HasResultsWith ¶
HasResultsWith applies the HasEdge predicate on the "results" edge with a given conditions (other predicates).
func HasScaleItem ¶
HasScaleItem applies the HasEdge predicate on the "scale_item" edge.
func HasScaleItemWith ¶
HasScaleItemWith applies the HasEdge predicate on the "scale_item" edge with a given conditions (other predicates).
func HasTestWith ¶
HasTestWith applies the HasEdge predicate on the "test" edge with a given conditions (other predicates).
func HasTranslations ¶
HasTranslations applies the HasEdge predicate on the "translations" edge.
func HasTranslationsWith ¶
func HasTranslationsWith(preds ...predicate.ScaleTranslation) predicate.Scale
HasTranslationsWith applies the HasEdge predicate on the "translations" edge with a given conditions (other predicates).
func TypeValidator ¶
TypeValidator is a validator for the "type" field enum values. It is called by the builders before save.
func UpdateTime ¶
UpdateTime applies equality check predicate on the "update_time" field. It's identical to UpdateTimeEQ.
func UpdateTimeEQ ¶
UpdateTimeEQ applies the EQ predicate on the "update_time" field.
func UpdateTimeGT ¶
UpdateTimeGT applies the GT predicate on the "update_time" field.
func UpdateTimeGTE ¶
UpdateTimeGTE applies the GTE predicate on the "update_time" field.
func UpdateTimeIn ¶
UpdateTimeIn applies the In predicate on the "update_time" field.
func UpdateTimeLT ¶
UpdateTimeLT applies the LT predicate on the "update_time" field.
func UpdateTimeLTE ¶
UpdateTimeLTE applies the LTE predicate on the "update_time" field.
func UpdateTimeNEQ ¶
UpdateTimeNEQ applies the NEQ predicate on the "update_time" field.
func UpdateTimeNotIn ¶
UpdateTimeNotIn applies the NotIn predicate on the "update_time" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).