Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.ProjectContributor) predicate.ProjectContributor
- func HasProject() predicate.ProjectContributor
- func HasProjectWith(preds ...predicate.Project) predicate.ProjectContributor
- func HasUser() predicate.ProjectContributor
- func HasUserWith(preds ...predicate.User) predicate.ProjectContributor
- func ID(id int) predicate.ProjectContributor
- func IDEQ(id int) predicate.ProjectContributor
- func IDGT(id int) predicate.ProjectContributor
- func IDGTE(id int) predicate.ProjectContributor
- func IDIn(ids ...int) predicate.ProjectContributor
- func IDLT(id int) predicate.ProjectContributor
- func IDLTE(id int) predicate.ProjectContributor
- func IDNEQ(id int) predicate.ProjectContributor
- func IDNotIn(ids ...int) predicate.ProjectContributor
- func Not(p predicate.ProjectContributor) predicate.ProjectContributor
- func Or(predicates ...predicate.ProjectContributor) predicate.ProjectContributor
- func RoleEQ(v Role) predicate.ProjectContributor
- func RoleIn(vs ...Role) predicate.ProjectContributor
- func RoleNEQ(v Role) predicate.ProjectContributor
- func RoleNotIn(vs ...Role) predicate.ProjectContributor
- func RoleValidator(r Role) error
- func ValidColumn(column string) bool
- type Role
Constants ¶
const ( // Label holds the string label denoting the projectcontributor type in the database. Label = "project_contributor" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldRole holds the string denoting the role field in the database. FieldRole = "role" // EdgeProject holds the string denoting the project edge name in mutations. EdgeProject = "project" // EdgeUser holds the string denoting the user edge name in mutations. EdgeUser = "user" // Table holds the table name of the projectcontributor in the database. Table = "project_contributors" // ProjectTable is the table that holds the project relation/edge. ProjectTable = "project_contributors" // ProjectInverseTable is the table name for the Project entity. // It exists in this package in order to avoid circular dependency with the "project" package. ProjectInverseTable = "projects" // ProjectColumn is the table column denoting the project relation/edge. ProjectColumn = "project_contributors" // UserTable is the table that holds the user relation/edge. UserTable = "project_contributors" // 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_project_contributions" )
Variables ¶
var ( Hooks [1]ent.Hook Policy ent.Policy )
Note that the variables below are initialized by the runtime package on the initialization of the application. Therefore, it should be imported in the main as follows:
import _ "github.com/fogo-sh/grackdb/ent/runtime"
var Columns = []string{ FieldID, FieldRole, }
Columns holds all SQL columns for projectcontributor fields.
var ForeignKeys = []string{
"project_contributors",
"user_project_contributions",
}
ForeignKeys holds the SQL foreign-keys that are owned by the "project_contributors" table and are not defined as standalone fields in the schema.
Functions ¶
func And ¶
func And(predicates ...predicate.ProjectContributor) predicate.ProjectContributor
And groups predicates with the AND operator between them.
func HasProject ¶
func HasProject() predicate.ProjectContributor
HasProject applies the HasEdge predicate on the "project" edge.
func HasProjectWith ¶
func HasProjectWith(preds ...predicate.Project) predicate.ProjectContributor
HasProjectWith applies the HasEdge predicate on the "project" edge with a given conditions (other predicates).
func HasUser ¶
func HasUser() predicate.ProjectContributor
HasUser applies the HasEdge predicate on the "user" edge.
func HasUserWith ¶
func HasUserWith(preds ...predicate.User) predicate.ProjectContributor
HasUserWith applies the HasEdge predicate on the "user" edge with a given conditions (other predicates).
func IDEQ ¶
func IDEQ(id int) predicate.ProjectContributor
IDEQ applies the EQ predicate on the ID field.
func IDGT ¶
func IDGT(id int) predicate.ProjectContributor
IDGT applies the GT predicate on the ID field.
func IDGTE ¶
func IDGTE(id int) predicate.ProjectContributor
IDGTE applies the GTE predicate on the ID field.
func IDIn ¶
func IDIn(ids ...int) predicate.ProjectContributor
IDIn applies the In predicate on the ID field.
func IDLT ¶
func IDLT(id int) predicate.ProjectContributor
IDLT applies the LT predicate on the ID field.
func IDLTE ¶
func IDLTE(id int) predicate.ProjectContributor
IDLTE applies the LTE predicate on the ID field.
func IDNEQ ¶
func IDNEQ(id int) predicate.ProjectContributor
IDNEQ applies the NEQ predicate on the ID field.
func IDNotIn ¶
func IDNotIn(ids ...int) predicate.ProjectContributor
IDNotIn applies the NotIn predicate on the ID field.
func Not ¶
func Not(p predicate.ProjectContributor) predicate.ProjectContributor
Not applies the not operator on the given predicate.
func Or ¶
func Or(predicates ...predicate.ProjectContributor) predicate.ProjectContributor
Or groups predicates with the OR operator between them.
func RoleEQ ¶
func RoleEQ(v Role) predicate.ProjectContributor
RoleEQ applies the EQ predicate on the "role" field.
func RoleIn ¶
func RoleIn(vs ...Role) predicate.ProjectContributor
RoleIn applies the In predicate on the "role" field.
func RoleNEQ ¶
func RoleNEQ(v Role) predicate.ProjectContributor
RoleNEQ applies the NEQ predicate on the "role" field.
func RoleNotIn ¶
func RoleNotIn(vs ...Role) predicate.ProjectContributor
RoleNotIn applies the NotIn predicate on the "role" field.
func RoleValidator ¶
RoleValidator is a validator for the "role" field enum values. It is called by the builders before save.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
type Role ¶
type Role string
Role defines the type for the "role" enum field.
func (Role) MarshalGQL ¶
MarshalGQL implements graphql.Marshaler interface.
func (*Role) UnmarshalGQL ¶
UnmarshalGQL implements graphql.Unmarshaler interface.