deadline

package
v0.0.0-...-20f649f Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2023 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the deadline type in the database.
	Label = "deadline"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldName holds the string denoting the name field in the database.
	FieldName = "name"
	// FieldDueTime holds the string denoting the due_time field in the database.
	FieldDueTime = "due_time"
	// EdgeAuthor holds the string denoting the author edge name in mutations.
	EdgeAuthor = "author"
	// EdgeVotedUsers holds the string denoting the voted_users edge name in mutations.
	EdgeVotedUsers = "voted_users"
	// EdgeGroup holds the string denoting the group edge name in mutations.
	EdgeGroup = "group"
	// Table holds the table name of the deadline in the database.
	Table = "deadlines"
	// AuthorTable is the table that holds the author relation/edge.
	AuthorTable = "deadlines"
	// AuthorInverseTable is the table name for the User entity.
	// It exists in this package in order to avoid circular dependency with the "user" package.
	AuthorInverseTable = "users"
	// AuthorColumn is the table column denoting the author relation/edge.
	AuthorColumn = "deadline_author"
	// VotedUsersTable is the table that holds the voted_users relation/edge. The primary key declared below.
	VotedUsersTable = "deadline_voted_users"
	// VotedUsersInverseTable is the table name for the User entity.
	// It exists in this package in order to avoid circular dependency with the "user" package.
	VotedUsersInverseTable = "users"
	// GroupTable is the table that holds the group relation/edge.
	GroupTable = "deadlines"
	// GroupInverseTable is the table name for the Group entity.
	// It exists in this package in order to avoid circular dependency with the "entgroup" package.
	GroupInverseTable = "groups"
	// GroupColumn is the table column denoting the group relation/edge.
	GroupColumn = "group_deadlines"
)

Variables

Columns holds all SQL columns for deadline fields.

View Source
var ForeignKeys = []string{
	"deadline_author",
	"group_deadlines",
}

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

View Source
var (
	// NameValidator is a validator for the "name" field. It is called by the builders before save.
	NameValidator func(string) error
)
View Source
var (
	// VotedUsersPrimaryKey and VotedUsersColumn2 are the table columns denoting the
	// primary key for the voted_users relation (M2M).
	VotedUsersPrimaryKey = []string{"deadline_id", "user_id"}
)

Functions

func And

func And(predicates ...predicate.Deadline) predicate.Deadline

And groups predicates with the AND operator between them.

func DueTime

func DueTime(v time.Time) predicate.Deadline

DueTime applies equality check predicate on the "due_time" field. It's identical to DueTimeEQ.

func DueTimeEQ

func DueTimeEQ(v time.Time) predicate.Deadline

DueTimeEQ applies the EQ predicate on the "due_time" field.

func DueTimeGT

func DueTimeGT(v time.Time) predicate.Deadline

DueTimeGT applies the GT predicate on the "due_time" field.

func DueTimeGTE

func DueTimeGTE(v time.Time) predicate.Deadline

DueTimeGTE applies the GTE predicate on the "due_time" field.

func DueTimeIn

func DueTimeIn(vs ...time.Time) predicate.Deadline

DueTimeIn applies the In predicate on the "due_time" field.

func DueTimeIsNil

func DueTimeIsNil() predicate.Deadline

DueTimeIsNil applies the IsNil predicate on the "due_time" field.

func DueTimeLT

func DueTimeLT(v time.Time) predicate.Deadline

DueTimeLT applies the LT predicate on the "due_time" field.

func DueTimeLTE

func DueTimeLTE(v time.Time) predicate.Deadline

DueTimeLTE applies the LTE predicate on the "due_time" field.

func DueTimeNEQ

func DueTimeNEQ(v time.Time) predicate.Deadline

DueTimeNEQ applies the NEQ predicate on the "due_time" field.

func DueTimeNotIn

func DueTimeNotIn(vs ...time.Time) predicate.Deadline

DueTimeNotIn applies the NotIn predicate on the "due_time" field.

func DueTimeNotNil

func DueTimeNotNil() predicate.Deadline

DueTimeNotNil applies the NotNil predicate on the "due_time" field.

func HasAuthor

func HasAuthor() predicate.Deadline

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

func HasAuthorWith

func HasAuthorWith(preds ...predicate.User) predicate.Deadline

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

func HasGroup

func HasGroup() predicate.Deadline

HasGroup applies the HasEdge predicate on the "group" edge.

func HasGroupWith

func HasGroupWith(preds ...predicate.Group) predicate.Deadline

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

func HasVotedUsers

func HasVotedUsers() predicate.Deadline

HasVotedUsers applies the HasEdge predicate on the "voted_users" edge.

func HasVotedUsersWith

func HasVotedUsersWith(preds ...predicate.User) predicate.Deadline

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

func ID

func ID(id int) predicate.Deadline

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Deadline

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Deadline

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Deadline

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Deadline

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Deadline

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Deadline

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func Name

func Name(v string) predicate.Deadline

Name applies equality check predicate on the "name" field. It's identical to NameEQ.

func NameContains

func NameContains(v string) predicate.Deadline

NameContains applies the Contains predicate on the "name" field.

func NameContainsFold

func NameContainsFold(v string) predicate.Deadline

NameContainsFold applies the ContainsFold predicate on the "name" field.

func NameEQ

func NameEQ(v string) predicate.Deadline

NameEQ applies the EQ predicate on the "name" field.

func NameEqualFold

func NameEqualFold(v string) predicate.Deadline

NameEqualFold applies the EqualFold predicate on the "name" field.

func NameGT

func NameGT(v string) predicate.Deadline

NameGT applies the GT predicate on the "name" field.

func NameGTE

func NameGTE(v string) predicate.Deadline

NameGTE applies the GTE predicate on the "name" field.

func NameHasPrefix

func NameHasPrefix(v string) predicate.Deadline

NameHasPrefix applies the HasPrefix predicate on the "name" field.

func NameHasSuffix

func NameHasSuffix(v string) predicate.Deadline

NameHasSuffix applies the HasSuffix predicate on the "name" field.

func NameIn

func NameIn(vs ...string) predicate.Deadline

NameIn applies the In predicate on the "name" field.

func NameLT

func NameLT(v string) predicate.Deadline

NameLT applies the LT predicate on the "name" field.

func NameLTE

func NameLTE(v string) predicate.Deadline

NameLTE applies the LTE predicate on the "name" field.

func NameNEQ

func NameNEQ(v string) predicate.Deadline

NameNEQ applies the NEQ predicate on the "name" field.

func NameNotIn

func NameNotIn(vs ...string) predicate.Deadline

NameNotIn applies the NotIn predicate on the "name" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Deadline) predicate.Deadline

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

func ByAuthorField

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

ByAuthorField orders the results by author field.

func ByDueTime

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

ByDueTime orders the results by the due_time field.

func ByGroupField

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

ByGroupField orders the results by group field.

func ByID

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

ByID orders the results by the id field.

func ByName

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

ByName orders the results by the name field.

func ByVotedUsers

func ByVotedUsers(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByVotedUsers orders the results by voted_users terms.

func ByVotedUsersCount

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

ByVotedUsersCount orders the results by voted_users count.

Jump to

Keyboard shortcuts

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