Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.KVPair) predicate.KVPair
- func ID(id int) predicate.KVPair
- func IDEQ(id int) predicate.KVPair
- func IDGT(id int) predicate.KVPair
- func IDGTE(id int) predicate.KVPair
- func IDIn(ids ...int) predicate.KVPair
- func IDLT(id int) predicate.KVPair
- func IDLTE(id int) predicate.KVPair
- func IDNEQ(id int) predicate.KVPair
- func IDNotIn(ids ...int) predicate.KVPair
- func Key(v string) predicate.KVPair
- func KeyContains(v string) predicate.KVPair
- func KeyContainsFold(v string) predicate.KVPair
- func KeyEQ(v string) predicate.KVPair
- func KeyEqualFold(v string) predicate.KVPair
- func KeyGT(v string) predicate.KVPair
- func KeyGTE(v string) predicate.KVPair
- func KeyHasPrefix(v string) predicate.KVPair
- func KeyHasSuffix(v string) predicate.KVPair
- func KeyIn(vs ...string) predicate.KVPair
- func KeyLT(v string) predicate.KVPair
- func KeyLTE(v string) predicate.KVPair
- func KeyNEQ(v string) predicate.KVPair
- func KeyNotIn(vs ...string) predicate.KVPair
- func Not(p predicate.KVPair) predicate.KVPair
- func Or(predicates ...predicate.KVPair) predicate.KVPair
- func ValidColumn(column string) bool
- func Value(v string) predicate.KVPair
- func ValueContains(v string) predicate.KVPair
- func ValueContainsFold(v string) predicate.KVPair
- func ValueEQ(v string) predicate.KVPair
- func ValueEqualFold(v string) predicate.KVPair
- func ValueGT(v string) predicate.KVPair
- func ValueGTE(v string) predicate.KVPair
- func ValueHasPrefix(v string) predicate.KVPair
- func ValueHasSuffix(v string) predicate.KVPair
- func ValueIn(vs ...string) predicate.KVPair
- func ValueLT(v string) predicate.KVPair
- func ValueLTE(v string) predicate.KVPair
- func ValueNEQ(v string) predicate.KVPair
- func ValueNotIn(vs ...string) predicate.KVPair
- type OrderOption
Constants ¶
const ( // Label holds the string label denoting the kvpair type in the database. Label = "kv_pair" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldKey holds the string denoting the key field in the database. FieldKey = "key" // FieldValue holds the string denoting the value field in the database. FieldValue = "value" // Table holds the table name of the kvpair in the database. Table = "kv_pairs" )
Variables ¶
var Columns = []string{ FieldID, FieldKey, FieldValue, }
Columns holds all SQL columns for kvpair fields.
Functions ¶
func KeyContains ¶
KeyContains applies the Contains predicate on the "key" field.
func KeyContainsFold ¶
KeyContainsFold applies the ContainsFold predicate on the "key" field.
func KeyEqualFold ¶
KeyEqualFold applies the EqualFold predicate on the "key" field.
func KeyHasPrefix ¶
KeyHasPrefix applies the HasPrefix predicate on the "key" field.
func KeyHasSuffix ¶
KeyHasSuffix applies the HasSuffix predicate on the "key" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
func Value ¶
Value applies equality check predicate on the "value" field. It's identical to ValueEQ.
func ValueContains ¶
ValueContains applies the Contains predicate on the "value" field.
func ValueContainsFold ¶
ValueContainsFold applies the ContainsFold predicate on the "value" field.
func ValueEqualFold ¶
ValueEqualFold applies the EqualFold predicate on the "value" field.
func ValueHasPrefix ¶
ValueHasPrefix applies the HasPrefix predicate on the "value" field.
func ValueHasSuffix ¶
ValueHasSuffix applies the HasSuffix predicate on the "value" field.
func ValueNotIn ¶
ValueNotIn applies the NotIn predicate on the "value" field.
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the KVPair queries.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByKey ¶
func ByKey(opts ...sql.OrderTermOption) OrderOption
ByKey orders the results by the key field.
func ByValue ¶
func ByValue(opts ...sql.OrderTermOption) OrderOption
ByValue orders the results by the value field.