chat

package
v0.0.0-...-52fa7fc Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2025 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the chat type in the database.
	Label = "chat"
	// 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"
	// FieldAuthorID holds the string denoting the author_id field in the database.
	FieldAuthorID = "author_id"
	// FieldMessage holds the string denoting the message field in the database.
	FieldMessage = "message"
	// FieldIsServer holds the string denoting the is_server field in the database.
	FieldIsServer = "is_server"
	// EdgeOperator holds the string denoting the operator edge name in mutations.
	EdgeOperator = "operator"
	// Table holds the table name of the chat in the database.
	Table = "chat"
	// OperatorTable is the table that holds the operator relation/edge.
	OperatorTable = "chat"
	// OperatorInverseTable is the table name for the Operator entity.
	// It exists in this package in order to avoid circular dependency with the "operator" package.
	OperatorInverseTable = "operator"
	// OperatorColumn is the table column denoting the operator relation/edge.
	OperatorColumn = "author_id"
)

Variables

View Source
var (
	// DefaultCreatedAt holds the default value on creation for the "created_at" field.
	DefaultCreatedAt func() time.Time
	// MessageValidator is a validator for the "message" field. It is called by the builders before save.
	MessageValidator func(string) error
	// DefaultIsServer holds the default value on creation for the "is_server" field.
	DefaultIsServer bool
)

Columns holds all SQL columns for chat fields.

Functions

func And

func And(predicates ...predicate.Chat) predicate.Chat

And groups predicates with the AND operator between them.

func AuthorID

func AuthorID(v int64) predicate.Chat

AuthorID applies equality check predicate on the "author_id" field. It's identical to AuthorIDEQ.

func AuthorIDEQ

func AuthorIDEQ(v int64) predicate.Chat

AuthorIDEQ applies the EQ predicate on the "author_id" field.

func AuthorIDIn

func AuthorIDIn(vs ...int64) predicate.Chat

AuthorIDIn applies the In predicate on the "author_id" field.

func AuthorIDIsNil

func AuthorIDIsNil() predicate.Chat

AuthorIDIsNil applies the IsNil predicate on the "author_id" field.

func AuthorIDNEQ

func AuthorIDNEQ(v int64) predicate.Chat

AuthorIDNEQ applies the NEQ predicate on the "author_id" field.

func AuthorIDNotIn

func AuthorIDNotIn(vs ...int64) predicate.Chat

AuthorIDNotIn applies the NotIn predicate on the "author_id" field.

func AuthorIDNotNil

func AuthorIDNotNil() predicate.Chat

AuthorIDNotNil applies the NotNil predicate on the "author_id" field.

func CreatedAt

func CreatedAt(v time.Time) predicate.Chat

CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.Chat

CreatedAtEQ applies the EQ predicate on the "created_at" field.

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.Chat

CreatedAtGT applies the GT predicate on the "created_at" field.

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.Chat

CreatedAtGTE applies the GTE predicate on the "created_at" field.

func CreatedAtIn

func CreatedAtIn(vs ...time.Time) predicate.Chat

CreatedAtIn applies the In predicate on the "created_at" field.

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.Chat

CreatedAtLT applies the LT predicate on the "created_at" field.

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.Chat

CreatedAtLTE applies the LTE predicate on the "created_at" field.

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.Chat

CreatedAtNEQ applies the NEQ predicate on the "created_at" field.

func CreatedAtNotIn

func CreatedAtNotIn(vs ...time.Time) predicate.Chat

CreatedAtNotIn applies the NotIn predicate on the "created_at" field.

func HasOperator

func HasOperator() predicate.Chat

HasOperator applies the HasEdge predicate on the "operator" edge.

func HasOperatorWith

func HasOperatorWith(preds ...predicate.Operator) predicate.Chat

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

func ID

func ID(id int) predicate.Chat

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Chat

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Chat

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Chat

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Chat

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Chat

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Chat

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func IsServer

func IsServer(v bool) predicate.Chat

IsServer applies equality check predicate on the "is_server" field. It's identical to IsServerEQ.

func IsServerEQ

func IsServerEQ(v bool) predicate.Chat

IsServerEQ applies the EQ predicate on the "is_server" field.

func IsServerNEQ

func IsServerNEQ(v bool) predicate.Chat

IsServerNEQ applies the NEQ predicate on the "is_server" field.

func Message

func Message(v string) predicate.Chat

Message applies equality check predicate on the "message" field. It's identical to MessageEQ.

func MessageContains

func MessageContains(v string) predicate.Chat

MessageContains applies the Contains predicate on the "message" field.

func MessageContainsFold

func MessageContainsFold(v string) predicate.Chat

MessageContainsFold applies the ContainsFold predicate on the "message" field.

func MessageEQ

func MessageEQ(v string) predicate.Chat

MessageEQ applies the EQ predicate on the "message" field.

func MessageEqualFold

func MessageEqualFold(v string) predicate.Chat

MessageEqualFold applies the EqualFold predicate on the "message" field.

func MessageGT

func MessageGT(v string) predicate.Chat

MessageGT applies the GT predicate on the "message" field.

func MessageGTE

func MessageGTE(v string) predicate.Chat

MessageGTE applies the GTE predicate on the "message" field.

func MessageHasPrefix

func MessageHasPrefix(v string) predicate.Chat

MessageHasPrefix applies the HasPrefix predicate on the "message" field.

func MessageHasSuffix

func MessageHasSuffix(v string) predicate.Chat

MessageHasSuffix applies the HasSuffix predicate on the "message" field.

func MessageIn

func MessageIn(vs ...string) predicate.Chat

MessageIn applies the In predicate on the "message" field.

func MessageLT

func MessageLT(v string) predicate.Chat

MessageLT applies the LT predicate on the "message" field.

func MessageLTE

func MessageLTE(v string) predicate.Chat

MessageLTE applies the LTE predicate on the "message" field.

func MessageNEQ

func MessageNEQ(v string) predicate.Chat

MessageNEQ applies the NEQ predicate on the "message" field.

func MessageNotIn

func MessageNotIn(vs ...string) predicate.Chat

MessageNotIn applies the NotIn predicate on the "message" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Chat) predicate.Chat

Or groups predicates with the OR operator between them.

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 Chat queries.

func ByAuthorID

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

ByAuthorID orders the results by the author_id field.

func ByCreatedAt

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

ByCreatedAt orders the results by the created_at field.

func ByID

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

ByID orders the results by the id field.

func ByIsServer

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

ByIsServer orders the results by the is_server field.

func ByMessage

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

ByMessage orders the results by the message field.

func ByOperatorField

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

ByOperatorField orders the results by operator field.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳