moderator

package
v0.0.0-...-a746138 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the moderator type in the database.
	Label = "moderator"
	// FieldModeratorID holds the string denoting the moderator_id field in the database.
	FieldModeratorID = "moderator_id"
	// FieldTopicID holds the string denoting the topic_id field in the database.
	FieldTopicID = "topic_id"
	// EdgeModerator holds the string denoting the moderator edge name in mutations.
	EdgeModerator = "moderator"
	// EdgeTopic holds the string denoting the topic edge name in mutations.
	EdgeTopic = "topic"
	// UserFieldID holds the string denoting the ID field of the User.
	UserFieldID = "id"
	// TopicFieldID holds the string denoting the ID field of the Topic.
	TopicFieldID = "id"
	// Table holds the table name of the moderator in the database.
	Table = "moderators"
	// ModeratorTable is the table that holds the moderator relation/edge.
	ModeratorTable = "moderators"
	// ModeratorInverseTable is the table name for the User entity.
	// It exists in this package in order to avoid circular dependency with the "user" package.
	ModeratorInverseTable = "users"
	// ModeratorColumn is the table column denoting the moderator relation/edge.
	ModeratorColumn = "moderator_id"
	// TopicTable is the table that holds the topic relation/edge.
	TopicTable = "moderators"
	// TopicInverseTable is the table name for the Topic entity.
	// It exists in this package in order to avoid circular dependency with the "topic" package.
	TopicInverseTable = "topics"
	// TopicColumn is the table column denoting the topic relation/edge.
	TopicColumn = "topic_id"
)

Variables

Columns holds all SQL columns for moderator fields.

Functions

func And

func And(predicates ...predicate.Moderator) predicate.Moderator

And groups predicates with the AND operator between them.

func HasModerator

func HasModerator() predicate.Moderator

HasModerator applies the HasEdge predicate on the "moderator" edge.

func HasModeratorWith

func HasModeratorWith(preds ...predicate.User) predicate.Moderator

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

func HasTopic

func HasTopic() predicate.Moderator

HasTopic applies the HasEdge predicate on the "topic" edge.

func HasTopicWith

func HasTopicWith(preds ...predicate.Topic) predicate.Moderator

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

func ModeratorID

func ModeratorID(v uuid.UUID) predicate.Moderator

ModeratorID applies equality check predicate on the "moderator_id" field. It's identical to ModeratorIDEQ.

func ModeratorIDEQ

func ModeratorIDEQ(v uuid.UUID) predicate.Moderator

ModeratorIDEQ applies the EQ predicate on the "moderator_id" field.

func ModeratorIDIn

func ModeratorIDIn(vs ...uuid.UUID) predicate.Moderator

ModeratorIDIn applies the In predicate on the "moderator_id" field.

func ModeratorIDNEQ

func ModeratorIDNEQ(v uuid.UUID) predicate.Moderator

ModeratorIDNEQ applies the NEQ predicate on the "moderator_id" field.

func ModeratorIDNotIn

func ModeratorIDNotIn(vs ...uuid.UUID) predicate.Moderator

ModeratorIDNotIn applies the NotIn predicate on the "moderator_id" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Moderator) predicate.Moderator

Or groups predicates with the OR operator between them.

func TopicID

func TopicID(v int) predicate.Moderator

TopicID applies equality check predicate on the "topic_id" field. It's identical to TopicIDEQ.

func TopicIDEQ

func TopicIDEQ(v int) predicate.Moderator

TopicIDEQ applies the EQ predicate on the "topic_id" field.

func TopicIDIn

func TopicIDIn(vs ...int) predicate.Moderator

TopicIDIn applies the In predicate on the "topic_id" field.

func TopicIDNEQ

func TopicIDNEQ(v int) predicate.Moderator

TopicIDNEQ applies the NEQ predicate on the "topic_id" field.

func TopicIDNotIn

func TopicIDNotIn(vs ...int) predicate.Moderator

TopicIDNotIn applies the NotIn predicate on the "topic_id" field.

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

func ByModeratorField

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

ByModeratorField orders the results by moderator field.

func ByModeratorID

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

ByModeratorID orders the results by the moderator_id field.

func ByTopicField

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

ByTopicField orders the results by topic field.

func ByTopicID

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

ByTopicID orders the results by the topic_id field.

Jump to

Keyboard shortcuts

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