comment

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the comment type in the database.
	Label = "comment"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldState holds the string denoting the state field in the database.
	FieldState = "state"
	// FieldContent holds the string denoting the content field in the database.
	FieldContent = "content"
	// FieldKind holds the string denoting the kind field in the database.
	FieldKind = "kind"
	// FieldIsWrittenByArticleAuthor holds the string denoting the is_written_by_article_author field in the database.
	FieldIsWrittenByArticleAuthor = "is_written_by_article_author"
	// FieldCreatedAt holds the string denoting the created_at field in the database.
	FieldCreatedAt = "created_at"
	// EdgeAuthor holds the string denoting the author edge name in mutations.
	EdgeAuthor = "author"
	// EdgeArticle holds the string denoting the article edge name in mutations.
	EdgeArticle = "article"
	// EdgeStudyArticle holds the string denoting the studyarticle edge name in mutations.
	EdgeStudyArticle = "studyArticle"
	// EdgeParent holds the string denoting the parent edge name in mutations.
	EdgeParent = "parent"
	// EdgeChildren holds the string denoting the children edge name in mutations.
	EdgeChildren = "children"
	// EdgeLike holds the string denoting the like edge name in mutations.
	EdgeLike = "like"
	// KhumuUserFieldID holds the string denoting the ID field of the KhumuUser.
	KhumuUserFieldID = "username"
	// Table holds the table name of the comment in the database.
	Table = "comment_comment"
	// AuthorTable is the table the holds the author relation/edge.
	AuthorTable = "comment_comment"
	// AuthorInverseTable is the table name for the KhumuUser entity.
	// It exists in this package in order to avoid circular dependency with the "khumuuser" package.
	AuthorInverseTable = "user_khumuuser"
	// AuthorColumn is the table column denoting the author relation/edge.
	AuthorColumn = "author_id"
	// ArticleTable is the table the holds the article relation/edge.
	ArticleTable = "comment_comment"
	// ArticleInverseTable is the table name for the Article entity.
	// It exists in this package in order to avoid circular dependency with the "article" package.
	ArticleInverseTable = "article_article"
	// ArticleColumn is the table column denoting the article relation/edge.
	ArticleColumn = "article_id"
	// StudyArticleTable is the table the holds the studyArticle relation/edge.
	StudyArticleTable = "comment_comment"
	// StudyArticleInverseTable is the table name for the StudyArticle entity.
	// It exists in this package in order to avoid circular dependency with the "studyarticle" package.
	StudyArticleInverseTable = "article_studyarticle"
	// StudyArticleColumn is the table column denoting the studyArticle relation/edge.
	StudyArticleColumn = "study_article_id"
	// ParentTable is the table the holds the parent relation/edge.
	ParentTable = "comment_comment"
	// ParentColumn is the table column denoting the parent relation/edge.
	ParentColumn = "parent_id"
	// ChildrenTable is the table the holds the children relation/edge.
	ChildrenTable = "comment_comment"
	// ChildrenColumn is the table column denoting the children relation/edge.
	ChildrenColumn = "parent_id"
	// LikeTable is the table the holds the like relation/edge.
	LikeTable = "comment_likecomment"
	// LikeInverseTable is the table name for the LikeComment entity.
	// It exists in this package in order to avoid circular dependency with the "likecomment" package.
	LikeInverseTable = "comment_likecomment"
	// LikeColumn is the table column denoting the like relation/edge.
	LikeColumn = "comment_id"
)

Variables

View Source
var (
	// DefaultState holds the default value on creation for the "state" field.
	DefaultState string
	// DefaultKind holds the default value on creation for the "kind" field.
	DefaultKind string
	// DefaultIsWrittenByArticleAuthor holds the default value on creation for the "is_written_by_article_author" field.
	DefaultIsWrittenByArticleAuthor bool
	// DefaultCreatedAt holds the default value on creation for the "created_at" field.
	DefaultCreatedAt func() time.Time
)

Columns holds all SQL columns for comment fields.

View Source
var ForeignKeys = []string{
	"article_id",
	"parent_id",
	"author_id",
	"study_article_id",
}

ForeignKeys holds the SQL foreign-keys that are owned by the "comment_comment" table and are not defined as standalone fields in the schema.

Functions

func And

func And(predicates ...predicate.Comment) predicate.Comment

And groups predicates with the AND operator between them.

func Content

func Content(v string) predicate.Comment

Content applies equality check predicate on the "content" field. It's identical to ContentEQ.

func ContentContains

func ContentContains(v string) predicate.Comment

ContentContains applies the Contains predicate on the "content" field.

func ContentContainsFold

func ContentContainsFold(v string) predicate.Comment

ContentContainsFold applies the ContainsFold predicate on the "content" field.

func ContentEQ

func ContentEQ(v string) predicate.Comment

ContentEQ applies the EQ predicate on the "content" field.

func ContentEqualFold

func ContentEqualFold(v string) predicate.Comment

ContentEqualFold applies the EqualFold predicate on the "content" field.

func ContentGT

func ContentGT(v string) predicate.Comment

ContentGT applies the GT predicate on the "content" field.

func ContentGTE

func ContentGTE(v string) predicate.Comment

ContentGTE applies the GTE predicate on the "content" field.

func ContentHasPrefix

func ContentHasPrefix(v string) predicate.Comment

ContentHasPrefix applies the HasPrefix predicate on the "content" field.

func ContentHasSuffix

func ContentHasSuffix(v string) predicate.Comment

ContentHasSuffix applies the HasSuffix predicate on the "content" field.

func ContentIn

func ContentIn(vs ...string) predicate.Comment

ContentIn applies the In predicate on the "content" field.

func ContentLT

func ContentLT(v string) predicate.Comment

ContentLT applies the LT predicate on the "content" field.

func ContentLTE

func ContentLTE(v string) predicate.Comment

ContentLTE applies the LTE predicate on the "content" field.

func ContentNEQ

func ContentNEQ(v string) predicate.Comment

ContentNEQ applies the NEQ predicate on the "content" field.

func ContentNotIn

func ContentNotIn(vs ...string) predicate.Comment

ContentNotIn applies the NotIn predicate on the "content" field.

func CreatedAt

func CreatedAt(v time.Time) predicate.Comment

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

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.Comment

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

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.Comment

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

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.Comment

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

func CreatedAtIn

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

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

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.Comment

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

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.Comment

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

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.Comment

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

func CreatedAtNotIn

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

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

func HasArticle

func HasArticle() predicate.Comment

HasArticle applies the HasEdge predicate on the "article" edge.

func HasArticleWith

func HasArticleWith(preds ...predicate.Article) predicate.Comment

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

func HasAuthor

func HasAuthor() predicate.Comment

HasAuthor applies the HasEdge predicate on the "author" edge.

func HasAuthorWith

func HasAuthorWith(preds ...predicate.KhumuUser) predicate.Comment

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

func HasChildren

func HasChildren() predicate.Comment

HasChildren applies the HasEdge predicate on the "children" edge.

func HasChildrenWith

func HasChildrenWith(preds ...predicate.Comment) predicate.Comment

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

func HasLike

func HasLike() predicate.Comment

HasLike applies the HasEdge predicate on the "like" edge.

func HasLikeWith

func HasLikeWith(preds ...predicate.LikeComment) predicate.Comment

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

func HasParent

func HasParent() predicate.Comment

HasParent applies the HasEdge predicate on the "parent" edge.

func HasParentWith

func HasParentWith(preds ...predicate.Comment) predicate.Comment

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

func HasStudyArticle

func HasStudyArticle() predicate.Comment

HasStudyArticle applies the HasEdge predicate on the "studyArticle" edge.

func HasStudyArticleWith

func HasStudyArticleWith(preds ...predicate.StudyArticle) predicate.Comment

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

func ID

func ID(id int) predicate.Comment

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Comment

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Comment

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Comment

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Comment

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Comment

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Comment

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func IsWrittenByArticleAuthor

func IsWrittenByArticleAuthor(v bool) predicate.Comment

IsWrittenByArticleAuthor applies equality check predicate on the "is_written_by_article_author" field. It's identical to IsWrittenByArticleAuthorEQ.

func IsWrittenByArticleAuthorEQ

func IsWrittenByArticleAuthorEQ(v bool) predicate.Comment

IsWrittenByArticleAuthorEQ applies the EQ predicate on the "is_written_by_article_author" field.

func IsWrittenByArticleAuthorNEQ

func IsWrittenByArticleAuthorNEQ(v bool) predicate.Comment

IsWrittenByArticleAuthorNEQ applies the NEQ predicate on the "is_written_by_article_author" field.

func Kind

func Kind(v string) predicate.Comment

Kind applies equality check predicate on the "kind" field. It's identical to KindEQ.

func KindContains

func KindContains(v string) predicate.Comment

KindContains applies the Contains predicate on the "kind" field.

func KindContainsFold

func KindContainsFold(v string) predicate.Comment

KindContainsFold applies the ContainsFold predicate on the "kind" field.

func KindEQ

func KindEQ(v string) predicate.Comment

KindEQ applies the EQ predicate on the "kind" field.

func KindEqualFold

func KindEqualFold(v string) predicate.Comment

KindEqualFold applies the EqualFold predicate on the "kind" field.

func KindGT

func KindGT(v string) predicate.Comment

KindGT applies the GT predicate on the "kind" field.

func KindGTE

func KindGTE(v string) predicate.Comment

KindGTE applies the GTE predicate on the "kind" field.

func KindHasPrefix

func KindHasPrefix(v string) predicate.Comment

KindHasPrefix applies the HasPrefix predicate on the "kind" field.

func KindHasSuffix

func KindHasSuffix(v string) predicate.Comment

KindHasSuffix applies the HasSuffix predicate on the "kind" field.

func KindIn

func KindIn(vs ...string) predicate.Comment

KindIn applies the In predicate on the "kind" field.

func KindLT

func KindLT(v string) predicate.Comment

KindLT applies the LT predicate on the "kind" field.

func KindLTE

func KindLTE(v string) predicate.Comment

KindLTE applies the LTE predicate on the "kind" field.

func KindNEQ

func KindNEQ(v string) predicate.Comment

KindNEQ applies the NEQ predicate on the "kind" field.

func KindNotIn

func KindNotIn(vs ...string) predicate.Comment

KindNotIn applies the NotIn predicate on the "kind" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Comment) predicate.Comment

Or groups predicates with the OR operator between them.

func State

func State(v string) predicate.Comment

State applies equality check predicate on the "state" field. It's identical to StateEQ.

func StateContains

func StateContains(v string) predicate.Comment

StateContains applies the Contains predicate on the "state" field.

func StateContainsFold

func StateContainsFold(v string) predicate.Comment

StateContainsFold applies the ContainsFold predicate on the "state" field.

func StateEQ

func StateEQ(v string) predicate.Comment

StateEQ applies the EQ predicate on the "state" field.

func StateEqualFold

func StateEqualFold(v string) predicate.Comment

StateEqualFold applies the EqualFold predicate on the "state" field.

func StateGT

func StateGT(v string) predicate.Comment

StateGT applies the GT predicate on the "state" field.

func StateGTE

func StateGTE(v string) predicate.Comment

StateGTE applies the GTE predicate on the "state" field.

func StateHasPrefix

func StateHasPrefix(v string) predicate.Comment

StateHasPrefix applies the HasPrefix predicate on the "state" field.

func StateHasSuffix

func StateHasSuffix(v string) predicate.Comment

StateHasSuffix applies the HasSuffix predicate on the "state" field.

func StateIn

func StateIn(vs ...string) predicate.Comment

StateIn applies the In predicate on the "state" field.

func StateLT

func StateLT(v string) predicate.Comment

StateLT applies the LT predicate on the "state" field.

func StateLTE

func StateLTE(v string) predicate.Comment

StateLTE applies the LTE predicate on the "state" field.

func StateNEQ

func StateNEQ(v string) predicate.Comment

StateNEQ applies the NEQ predicate on the "state" field.

func StateNotIn

func StateNotIn(vs ...string) predicate.Comment

StateNotIn applies the NotIn predicate on the "state" field.

func ValidColumn

func ValidColumn(column string) bool

ValidColumn reports if the column name is valid (part of the table columns).

Types

This section is empty.

Jump to

Keyboard shortcuts

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