Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Reaction) predicate.Reaction
- func CommentID(v uuid.UUID) predicate.Reaction
- func CommentIDEQ(v uuid.UUID) predicate.Reaction
- func CommentIDIn(vs ...uuid.UUID) predicate.Reaction
- func CommentIDIsNil() predicate.Reaction
- func CommentIDNEQ(v uuid.UUID) predicate.Reaction
- func CommentIDNotIn(vs ...uuid.UUID) predicate.Reaction
- func CommentIDNotNil() predicate.Reaction
- func CreatedAt(v time.Time) predicate.Reaction
- func CreatedAtEQ(v time.Time) predicate.Reaction
- func CreatedAtGT(v time.Time) predicate.Reaction
- func CreatedAtGTE(v time.Time) predicate.Reaction
- func CreatedAtIn(vs ...time.Time) predicate.Reaction
- func CreatedAtLT(v time.Time) predicate.Reaction
- func CreatedAtLTE(v time.Time) predicate.Reaction
- func CreatedAtNEQ(v time.Time) predicate.Reaction
- func CreatedAtNotIn(vs ...time.Time) predicate.Reaction
- func HasComment() predicate.Reaction
- func HasCommentWith(preds ...predicate.Comment) predicate.Reaction
- func HasPost() predicate.Reaction
- func HasPostWith(preds ...predicate.Post) predicate.Reaction
- func HasReply() predicate.Reaction
- func HasReplyWith(preds ...predicate.Reply) predicate.Reaction
- func HasUser() predicate.Reaction
- func HasUserWith(preds ...predicate.User) predicate.Reaction
- func ID(id uuid.UUID) predicate.Reaction
- func IDEQ(id uuid.UUID) predicate.Reaction
- func IDGT(id uuid.UUID) predicate.Reaction
- func IDGTE(id uuid.UUID) predicate.Reaction
- func IDIn(ids ...uuid.UUID) predicate.Reaction
- func IDLT(id uuid.UUID) predicate.Reaction
- func IDLTE(id uuid.UUID) predicate.Reaction
- func IDNEQ(id uuid.UUID) predicate.Reaction
- func IDNotIn(ids ...uuid.UUID) predicate.Reaction
- func Not(p predicate.Reaction) predicate.Reaction
- func Or(predicates ...predicate.Reaction) predicate.Reaction
- func PostID(v uuid.UUID) predicate.Reaction
- func PostIDEQ(v uuid.UUID) predicate.Reaction
- func PostIDIn(vs ...uuid.UUID) predicate.Reaction
- func PostIDIsNil() predicate.Reaction
- func PostIDNEQ(v uuid.UUID) predicate.Reaction
- func PostIDNotIn(vs ...uuid.UUID) predicate.Reaction
- func PostIDNotNil() predicate.Reaction
- func ReplyID(v uuid.UUID) predicate.Reaction
- func ReplyIDEQ(v uuid.UUID) predicate.Reaction
- func ReplyIDIn(vs ...uuid.UUID) predicate.Reaction
- func ReplyIDIsNil() predicate.Reaction
- func ReplyIDNEQ(v uuid.UUID) predicate.Reaction
- func ReplyIDNotIn(vs ...uuid.UUID) predicate.Reaction
- func ReplyIDNotNil() predicate.Reaction
- func RtypeEQ(v Rtype) predicate.Reaction
- func RtypeIn(vs ...Rtype) predicate.Reaction
- func RtypeNEQ(v Rtype) predicate.Reaction
- func RtypeNotIn(vs ...Rtype) predicate.Reaction
- func RtypeValidator(r Rtype) error
- func UpdatedAt(v time.Time) predicate.Reaction
- func UpdatedAtEQ(v time.Time) predicate.Reaction
- func UpdatedAtGT(v time.Time) predicate.Reaction
- func UpdatedAtGTE(v time.Time) predicate.Reaction
- func UpdatedAtIn(vs ...time.Time) predicate.Reaction
- func UpdatedAtLT(v time.Time) predicate.Reaction
- func UpdatedAtLTE(v time.Time) predicate.Reaction
- func UpdatedAtNEQ(v time.Time) predicate.Reaction
- func UpdatedAtNotIn(vs ...time.Time) predicate.Reaction
- func UserID(v uuid.UUID) predicate.Reaction
- func UserIDEQ(v uuid.UUID) predicate.Reaction
- func UserIDIn(vs ...uuid.UUID) predicate.Reaction
- func UserIDNEQ(v uuid.UUID) predicate.Reaction
- func UserIDNotIn(vs ...uuid.UUID) predicate.Reaction
- func ValidColumn(column string) bool
- type OrderOption
- func ByCommentField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByCommentID(opts ...sql.OrderTermOption) OrderOption
- func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByPostField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByPostID(opts ...sql.OrderTermOption) OrderOption
- func ByReplyField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByReplyID(opts ...sql.OrderTermOption) OrderOption
- func ByRtype(opts ...sql.OrderTermOption) OrderOption
- func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByUserField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByUserID(opts ...sql.OrderTermOption) OrderOption
- type Rtype
Constants ¶
const ( // Label holds the string label denoting the reaction type in the database. Label = "reaction" // 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" // FieldUserID holds the string denoting the user_id field in the database. FieldUserID = "user_id" // FieldRtype holds the string denoting the rtype field in the database. FieldRtype = "rtype" // FieldPostID holds the string denoting the post_id field in the database. FieldPostID = "post_id" // FieldCommentID holds the string denoting the comment_id field in the database. FieldCommentID = "comment_id" // FieldReplyID holds the string denoting the reply_id field in the database. FieldReplyID = "reply_id" // EdgeUser holds the string denoting the user edge name in mutations. EdgeUser = "user" // EdgePost holds the string denoting the post edge name in mutations. EdgePost = "post" // EdgeComment holds the string denoting the comment edge name in mutations. EdgeComment = "comment" // EdgeReply holds the string denoting the reply edge name in mutations. EdgeReply = "reply" // Table holds the table name of the reaction in the database. Table = "reactions" // UserTable is the table that holds the user relation/edge. UserTable = "reactions" // UserInverseTable is the table name for the User entity. // It exists in this package in order to avoid circular dependency with the "user" package. UserInverseTable = "users" // UserColumn is the table column denoting the user relation/edge. UserColumn = "user_id" // PostTable is the table that holds the post relation/edge. PostTable = "reactions" // PostInverseTable is the table name for the Post entity. // It exists in this package in order to avoid circular dependency with the "post" package. PostInverseTable = "posts" // PostColumn is the table column denoting the post relation/edge. PostColumn = "post_id" // CommentTable is the table that holds the comment relation/edge. CommentTable = "reactions" // CommentInverseTable is the table name for the Comment entity. // It exists in this package in order to avoid circular dependency with the "comment" package. CommentInverseTable = "comments" // CommentColumn is the table column denoting the comment relation/edge. CommentColumn = "comment_id" // ReplyTable is the table that holds the reply relation/edge. ReplyTable = "reactions" // ReplyInverseTable is the table name for the Reply entity. // It exists in this package in order to avoid circular dependency with the "reply" package. ReplyInverseTable = "replies" // ReplyColumn is the table column denoting the reply relation/edge. ReplyColumn = "reply_id" )
const DefaultRtype = RtypeLIKE
RtypeLIKE is the default value of the Rtype enum.
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, FieldUserID, FieldRtype, FieldPostID, FieldCommentID, FieldReplyID, }
Columns holds all SQL columns for reaction fields.
Functions ¶
func CommentID ¶
CommentID applies equality check predicate on the "comment_id" field. It's identical to CommentIDEQ.
func CommentIDEQ ¶
CommentIDEQ applies the EQ predicate on the "comment_id" field.
func CommentIDIn ¶
CommentIDIn applies the In predicate on the "comment_id" field.
func CommentIDIsNil ¶
CommentIDIsNil applies the IsNil predicate on the "comment_id" field.
func CommentIDNEQ ¶
CommentIDNEQ applies the NEQ predicate on the "comment_id" field.
func CommentIDNotIn ¶
CommentIDNotIn applies the NotIn predicate on the "comment_id" field.
func CommentIDNotNil ¶
CommentIDNotNil applies the NotNil predicate on the "comment_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 HasComment ¶
HasComment applies the HasEdge predicate on the "comment" edge.
func HasCommentWith ¶
HasCommentWith applies the HasEdge predicate on the "comment" edge with a given conditions (other predicates).
func HasPostWith ¶
HasPostWith applies the HasEdge predicate on the "post" edge with a given conditions (other predicates).
func HasReplyWith ¶
HasReplyWith applies the HasEdge predicate on the "reply" edge with a given conditions (other predicates).
func HasUserWith ¶
HasUserWith applies the HasEdge predicate on the "user" edge with a given conditions (other predicates).
func PostID ¶
PostID applies equality check predicate on the "post_id" field. It's identical to PostIDEQ.
func PostIDIsNil ¶
PostIDIsNil applies the IsNil predicate on the "post_id" field.
func PostIDNotIn ¶
PostIDNotIn applies the NotIn predicate on the "post_id" field.
func PostIDNotNil ¶
PostIDNotNil applies the NotNil predicate on the "post_id" field.
func ReplyID ¶
ReplyID applies equality check predicate on the "reply_id" field. It's identical to ReplyIDEQ.
func ReplyIDIsNil ¶
ReplyIDIsNil applies the IsNil predicate on the "reply_id" field.
func ReplyIDNEQ ¶
ReplyIDNEQ applies the NEQ predicate on the "reply_id" field.
func ReplyIDNotIn ¶
ReplyIDNotIn applies the NotIn predicate on the "reply_id" field.
func ReplyIDNotNil ¶
ReplyIDNotNil applies the NotNil predicate on the "reply_id" field.
func RtypeNotIn ¶
RtypeNotIn applies the NotIn predicate on the "rtype" field.
func RtypeValidator ¶
RtypeValidator is a validator for the "rtype" field enum values. It is called by the builders before save.
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 UserID ¶
UserID applies equality check predicate on the "user_id" field. It's identical to UserIDEQ.
func UserIDNotIn ¶
UserIDNotIn applies the NotIn predicate on the "user_id" 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 Reaction queries.
func ByCommentField ¶
func ByCommentField(field string, opts ...sql.OrderTermOption) OrderOption
ByCommentField orders the results by comment field.
func ByCommentID ¶
func ByCommentID(opts ...sql.OrderTermOption) OrderOption
ByCommentID orders the results by the comment_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 ByPostField ¶
func ByPostField(field string, opts ...sql.OrderTermOption) OrderOption
ByPostField orders the results by post field.
func ByPostID ¶
func ByPostID(opts ...sql.OrderTermOption) OrderOption
ByPostID orders the results by the post_id field.
func ByReplyField ¶
func ByReplyField(field string, opts ...sql.OrderTermOption) OrderOption
ByReplyField orders the results by reply field.
func ByReplyID ¶
func ByReplyID(opts ...sql.OrderTermOption) OrderOption
ByReplyID orders the results by the reply_id field.
func ByRtype ¶
func ByRtype(opts ...sql.OrderTermOption) OrderOption
ByRtype orders the results by the rtype field.
func ByUpdatedAt ¶
func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
ByUpdatedAt orders the results by the updated_at field.
func ByUserField ¶
func ByUserField(field string, opts ...sql.OrderTermOption) OrderOption
ByUserField orders the results by user field.
func ByUserID ¶
func ByUserID(opts ...sql.OrderTermOption) OrderOption
ByUserID orders the results by the user_id field.