Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Site) predicate.Site
- func HasProject() predicate.Site
- func HasProjectWith(preds ...predicate.Project) predicate.Site
- func HasRepository() predicate.Site
- func HasRepositoryWith(preds ...predicate.Repository) predicate.Site
- func ID(id int) predicate.Site
- func IDEQ(id int) predicate.Site
- func IDGT(id int) predicate.Site
- func IDGTE(id int) predicate.Site
- func IDIn(ids ...int) predicate.Site
- func IDLT(id int) predicate.Site
- func IDLTE(id int) predicate.Site
- func IDNEQ(id int) predicate.Site
- func IDNotIn(ids ...int) predicate.Site
- func Not(p predicate.Site) predicate.Site
- func Or(predicates ...predicate.Site) predicate.Site
- func URL(v string) predicate.Site
- func URLContains(v string) predicate.Site
- func URLContainsFold(v string) predicate.Site
- func URLEQ(v string) predicate.Site
- func URLEqualFold(v string) predicate.Site
- func URLGT(v string) predicate.Site
- func URLGTE(v string) predicate.Site
- func URLHasPrefix(v string) predicate.Site
- func URLHasSuffix(v string) predicate.Site
- func URLIn(vs ...string) predicate.Site
- func URLLT(v string) predicate.Site
- func URLLTE(v string) predicate.Site
- func URLNEQ(v string) predicate.Site
- func URLNotIn(vs ...string) predicate.Site
- func ValidColumn(column string) bool
Constants ¶
const ( // Label holds the string label denoting the site type in the database. Label = "site" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldURL holds the string denoting the url field in the database. FieldURL = "url" // EdgeProject holds the string denoting the project edge name in mutations. EdgeProject = "project" // EdgeRepository holds the string denoting the repository edge name in mutations. EdgeRepository = "repository" // Table holds the table name of the site in the database. Table = "sites" // ProjectTable is the table that holds the project relation/edge. ProjectTable = "sites" // 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_sites" // RepositoryTable is the table that holds the repository relation/edge. RepositoryTable = "sites" // RepositoryInverseTable is the table name for the Repository entity. // It exists in this package in order to avoid circular dependency with the "repository" package. RepositoryInverseTable = "repositories" // RepositoryColumn is the table column denoting the repository relation/edge. RepositoryColumn = "repository_sites" )
Variables ¶
var ( Hooks [1]ent.Hook Policy ent.Policy // URLValidator is a validator for the "url" field. It is called by the builders before save. URLValidator func(string) error )
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, FieldURL, }
Columns holds all SQL columns for site fields.
var ForeignKeys = []string{
"project_sites",
"repository_sites",
}
ForeignKeys holds the SQL foreign-keys that are owned by the "sites" table and are not defined as standalone fields in the schema.
Functions ¶
func HasProject ¶
HasProject applies the HasEdge predicate on the "project" edge.
func HasProjectWith ¶
HasProjectWith applies the HasEdge predicate on the "project" edge with a given conditions (other predicates).
func HasRepository ¶
HasRepository applies the HasEdge predicate on the "repository" edge.
func HasRepositoryWith ¶
func HasRepositoryWith(preds ...predicate.Repository) predicate.Site
HasRepositoryWith applies the HasEdge predicate on the "repository" edge with a given conditions (other predicates).
func URLContains ¶
URLContains applies the Contains predicate on the "url" field.
func URLContainsFold ¶
URLContainsFold applies the ContainsFold predicate on the "url" field.
func URLEqualFold ¶
URLEqualFold applies the EqualFold predicate on the "url" field.
func URLHasPrefix ¶
URLHasPrefix applies the HasPrefix predicate on the "url" field.
func URLHasSuffix ¶
URLHasSuffix applies the HasSuffix predicate on the "url" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
This section is empty.