Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Message) predicate.Message
- func ChatID(v uuid.UUID) predicate.Message
- func ChatIDEQ(v uuid.UUID) predicate.Message
- func ChatIDIn(vs ...uuid.UUID) predicate.Message
- func ChatIDNEQ(v uuid.UUID) predicate.Message
- func ChatIDNotIn(vs ...uuid.UUID) predicate.Message
- func CreatedAt(v time.Time) predicate.Message
- func CreatedAtEQ(v time.Time) predicate.Message
- func CreatedAtGT(v time.Time) predicate.Message
- func CreatedAtGTE(v time.Time) predicate.Message
- func CreatedAtIn(vs ...time.Time) predicate.Message
- func CreatedAtLT(v time.Time) predicate.Message
- func CreatedAtLTE(v time.Time) predicate.Message
- func CreatedAtNEQ(v time.Time) predicate.Message
- func CreatedAtNotIn(vs ...time.Time) predicate.Message
- func FileID(v uuid.UUID) predicate.Message
- func FileIDEQ(v uuid.UUID) predicate.Message
- func FileIDIn(vs ...uuid.UUID) predicate.Message
- func FileIDIsNil() predicate.Message
- func FileIDNEQ(v uuid.UUID) predicate.Message
- func FileIDNotIn(vs ...uuid.UUID) predicate.Message
- func FileIDNotNil() predicate.Message
- func HasChat() predicate.Message
- func HasChatWith(preds ...predicate.Chat) predicate.Message
- func HasFile() predicate.Message
- func HasFileWith(preds ...predicate.File) predicate.Message
- func HasSender() predicate.Message
- func HasSenderWith(preds ...predicate.User) predicate.Message
- func ID(id uuid.UUID) predicate.Message
- func IDEQ(id uuid.UUID) predicate.Message
- func IDGT(id uuid.UUID) predicate.Message
- func IDGTE(id uuid.UUID) predicate.Message
- func IDIn(ids ...uuid.UUID) predicate.Message
- func IDLT(id uuid.UUID) predicate.Message
- func IDLTE(id uuid.UUID) predicate.Message
- func IDNEQ(id uuid.UUID) predicate.Message
- func IDNotIn(ids ...uuid.UUID) predicate.Message
- func Not(p predicate.Message) predicate.Message
- func Or(predicates ...predicate.Message) predicate.Message
- func SenderID(v uuid.UUID) predicate.Message
- func SenderIDEQ(v uuid.UUID) predicate.Message
- func SenderIDIn(vs ...uuid.UUID) predicate.Message
- func SenderIDNEQ(v uuid.UUID) predicate.Message
- func SenderIDNotIn(vs ...uuid.UUID) predicate.Message
- func Text(v string) predicate.Message
- func TextContains(v string) predicate.Message
- func TextContainsFold(v string) predicate.Message
- func TextEQ(v string) predicate.Message
- func TextEqualFold(v string) predicate.Message
- func TextGT(v string) predicate.Message
- func TextGTE(v string) predicate.Message
- func TextHasPrefix(v string) predicate.Message
- func TextHasSuffix(v string) predicate.Message
- func TextIn(vs ...string) predicate.Message
- func TextIsNil() predicate.Message
- func TextLT(v string) predicate.Message
- func TextLTE(v string) predicate.Message
- func TextNEQ(v string) predicate.Message
- func TextNotIn(vs ...string) predicate.Message
- func TextNotNil() predicate.Message
- func UpdatedAt(v time.Time) predicate.Message
- func UpdatedAtEQ(v time.Time) predicate.Message
- func UpdatedAtGT(v time.Time) predicate.Message
- func UpdatedAtGTE(v time.Time) predicate.Message
- func UpdatedAtIn(vs ...time.Time) predicate.Message
- func UpdatedAtLT(v time.Time) predicate.Message
- func UpdatedAtLTE(v time.Time) predicate.Message
- func UpdatedAtNEQ(v time.Time) predicate.Message
- func UpdatedAtNotIn(vs ...time.Time) predicate.Message
- func ValidColumn(column string) bool
- type OrderOption
- func ByChatField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByChatID(opts ...sql.OrderTermOption) OrderOption
- func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByFileField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByFileID(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func BySenderField(field string, opts ...sql.OrderTermOption) OrderOption
- func BySenderID(opts ...sql.OrderTermOption) OrderOption
- func ByText(opts ...sql.OrderTermOption) OrderOption
- func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the message type in the database. Label = "message" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldCreatedAt holds the string denoting the created_at field in the database. FieldCreatedAt = "created_at" // FieldUpdatedAt holds the string denoting the updated_at field in the database. FieldUpdatedAt = "updated_at" // FieldText holds the string denoting the text field in the database. FieldText = "text" // FieldSenderID holds the string denoting the sender_id field in the database. FieldSenderID = "sender_id" // FieldChatID holds the string denoting the chat_id field in the database. FieldChatID = "chat_id" // FieldFileID holds the string denoting the file_id field in the database. FieldFileID = "file_id" // EdgeSender holds the string denoting the sender edge name in mutations. EdgeSender = "sender" // EdgeChat holds the string denoting the chat edge name in mutations. EdgeChat = "chat" // EdgeFile holds the string denoting the file edge name in mutations. EdgeFile = "file" // Table holds the table name of the message in the database. Table = "messages" // SenderTable is the table that holds the sender relation/edge. SenderTable = "messages" // SenderInverseTable is the table name for the User entity. // It exists in this package in order to avoid circular dependency with the "user" package. SenderInverseTable = "users" // SenderColumn is the table column denoting the sender relation/edge. SenderColumn = "sender_id" // ChatTable is the table that holds the chat relation/edge. ChatTable = "messages" // ChatInverseTable is the table name for the Chat entity. // It exists in this package in order to avoid circular dependency with the "chat" package. ChatInverseTable = "chats" // ChatColumn is the table column denoting the chat relation/edge. ChatColumn = "chat_id" // FileTable is the table that holds the file relation/edge. FileTable = "messages" // FileInverseTable is the table name for the File entity. // It exists in this package in order to avoid circular dependency with the "file" package. FileInverseTable = "files" // FileColumn is the table column denoting the file relation/edge. FileColumn = "file_id" )
Variables ¶
var ( // DefaultCreatedAt holds the default value on creation for the "created_at" field. DefaultCreatedAt func() time.Time // DefaultUpdatedAt holds the default value on creation for the "updated_at" field. DefaultUpdatedAt func() time.Time // UpdateDefaultUpdatedAt holds the default value on update for the "updated_at" field. UpdateDefaultUpdatedAt func() time.Time // DefaultID holds the default value on creation for the "id" field. DefaultID func() uuid.UUID )
var Columns = []string{ FieldID, FieldCreatedAt, FieldUpdatedAt, FieldText, FieldSenderID, FieldChatID, FieldFileID, }
Columns holds all SQL columns for message fields.
Functions ¶
func ChatID ¶
ChatID applies equality check predicate on the "chat_id" field. It's identical to ChatIDEQ.
func ChatIDNotIn ¶
ChatIDNotIn applies the NotIn predicate on the "chat_id" field.
func CreatedAt ¶
CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAtEQ ¶
CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtGT ¶
CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGTE ¶
CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtIn ¶
CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtLT ¶
CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLTE ¶
CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtNEQ ¶
CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNotIn ¶
CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func FileID ¶
FileID applies equality check predicate on the "file_id" field. It's identical to FileIDEQ.
func FileIDIsNil ¶
FileIDIsNil applies the IsNil predicate on the "file_id" field.
func FileIDNotIn ¶
FileIDNotIn applies the NotIn predicate on the "file_id" field.
func FileIDNotNil ¶
FileIDNotNil applies the NotNil predicate on the "file_id" field.
func HasChatWith ¶
HasChatWith applies the HasEdge predicate on the "chat" edge with a given conditions (other predicates).
func HasFileWith ¶
HasFileWith applies the HasEdge predicate on the "file" edge with a given conditions (other predicates).
func HasSenderWith ¶
HasSenderWith applies the HasEdge predicate on the "sender" edge with a given conditions (other predicates).
func SenderID ¶
SenderID applies equality check predicate on the "sender_id" field. It's identical to SenderIDEQ.
func SenderIDEQ ¶
SenderIDEQ applies the EQ predicate on the "sender_id" field.
func SenderIDIn ¶
SenderIDIn applies the In predicate on the "sender_id" field.
func SenderIDNEQ ¶
SenderIDNEQ applies the NEQ predicate on the "sender_id" field.
func SenderIDNotIn ¶
SenderIDNotIn applies the NotIn predicate on the "sender_id" field.
func TextContains ¶
TextContains applies the Contains predicate on the "text" field.
func TextContainsFold ¶
TextContainsFold applies the ContainsFold predicate on the "text" field.
func TextEqualFold ¶
TextEqualFold applies the EqualFold predicate on the "text" field.
func TextHasPrefix ¶
TextHasPrefix applies the HasPrefix predicate on the "text" field.
func TextHasSuffix ¶
TextHasSuffix applies the HasSuffix predicate on the "text" field.
func TextNotNil ¶
TextNotNil applies the NotNil predicate on the "text" field.
func UpdatedAt ¶
UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
func UpdatedAtEQ ¶
UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtGT ¶
UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGTE ¶
UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtIn ¶
UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtLT ¶
UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLTE ¶
UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtNEQ ¶
UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNotIn ¶
UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the Message queries.
func ByChatField ¶
func ByChatField(field string, opts ...sql.OrderTermOption) OrderOption
ByChatField orders the results by chat field.
func ByChatID ¶
func ByChatID(opts ...sql.OrderTermOption) OrderOption
ByChatID orders the results by the chat_id field.
func ByCreatedAt ¶
func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
ByCreatedAt orders the results by the created_at field.
func ByFileField ¶
func ByFileField(field string, opts ...sql.OrderTermOption) OrderOption
ByFileField orders the results by file field.
func ByFileID ¶
func ByFileID(opts ...sql.OrderTermOption) OrderOption
ByFileID orders the results by the file_id field.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func BySenderField ¶
func BySenderField(field string, opts ...sql.OrderTermOption) OrderOption
BySenderField orders the results by sender field.
func BySenderID ¶
func BySenderID(opts ...sql.OrderTermOption) OrderOption
BySenderID orders the results by the sender_id field.
func ByText ¶
func ByText(opts ...sql.OrderTermOption) OrderOption
ByText orders the results by the text field.
func ByUpdatedAt ¶
func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
ByUpdatedAt orders the results by the updated_at field.