Documentation ¶
Index ¶
- Constants
- Variables
- func IsConstraintError(err error) bool
- func IsNotFound(err error) bool
- func IsNotLoaded(err error) bool
- func IsNotSingular(err error) bool
- func IsValidationError(err error) bool
- func MaskNotFound(err error) error
- func NewContext(parent context.Context, c *Client) context.Context
- func NewTxContext(parent context.Context, tx *Tx) context.Context
- func OpenTxFromContext(ctx context.Context) (context.Context, driver.Tx, error)
- type AggregateFunc
- type Client
- func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)
- func (c *Client) Close() error
- func (c *Client) Debug() *Client
- func (c *Client) Intercept(interceptors ...Interceptor)
- func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)
- func (c *Client) Node(ctx context.Context, id int) (*Node, error)
- func (c *Client) Noder(ctx context.Context, id int, opts ...NodeOption) (_ Noder, err error)
- func (c *Client) Noders(ctx context.Context, ids []int, opts ...NodeOption) ([]Noder, error)
- func (c *Client) OpenTx(ctx context.Context) (context.Context, driver.Tx, error)
- func (c *Client) Tx(ctx context.Context) (*Tx, error)
- func (c *Client) Use(hooks ...Hook)
- type Comment
- func (c *Comment) Epics(ctx context.Context) (result []*Epic, err error)
- func (c *Comment) NamedEpics(name string) ([]*Epic, error)
- func (c *Comment) NamedProjects(name string) ([]*Project, error)
- func (c *Comment) NamedUsers(name string) ([]*User, error)
- func (c *Comment) Node(ctx context.Context) (node *Node, err error)
- func (c *Comment) Projects(ctx context.Context) (result []*Project, err error)
- func (c *Comment) QueryEpics() *EpicQuery
- func (c *Comment) QueryProjects() *ProjectQuery
- func (c *Comment) QueryUsers() *UserQuery
- func (c *Comment) String() string
- func (c *Comment) ToEdge(order *CommentOrder) *CommentEdge
- func (c *Comment) Unwrap() *Comment
- func (c *Comment) Update() *CommentUpdateOne
- func (c *Comment) Users(ctx context.Context) (result []*User, err error)
- type CommentClient
- func (c *CommentClient) Create() *CommentCreate
- func (c *CommentClient) CreateBulk(builders ...*CommentCreate) *CommentCreateBulk
- func (c *CommentClient) Delete() *CommentDelete
- func (c *CommentClient) DeleteOne(co *Comment) *CommentDeleteOne
- func (c *CommentClient) DeleteOneID(id int) *CommentDeleteOne
- func (c *CommentClient) Get(ctx context.Context, id int) (*Comment, error)
- func (c *CommentClient) GetX(ctx context.Context, id int) *Comment
- func (c *CommentClient) Hooks() []Hook
- func (c *CommentClient) Intercept(interceptors ...Interceptor)
- func (c *CommentClient) Interceptors() []Interceptor
- func (c *CommentClient) Query() *CommentQuery
- func (c *CommentClient) QueryEpics(co *Comment) *EpicQuery
- func (c *CommentClient) QueryProjects(co *Comment) *ProjectQuery
- func (c *CommentClient) QueryUsers(co *Comment) *UserQuery
- func (c *CommentClient) Update() *CommentUpdate
- func (c *CommentClient) UpdateOne(co *Comment) *CommentUpdateOne
- func (c *CommentClient) UpdateOneID(id int) *CommentUpdateOne
- func (c *CommentClient) Use(hooks ...Hook)
- type CommentConnection
- type CommentCreate
- func (cc *CommentCreate) AddEpicIDs(ids ...int) *CommentCreate
- func (cc *CommentCreate) AddEpics(e ...*Epic) *CommentCreate
- func (cc *CommentCreate) AddProjectIDs(ids ...int) *CommentCreate
- func (cc *CommentCreate) AddProjects(p ...*Project) *CommentCreate
- func (cc *CommentCreate) AddUserIDs(ids ...int) *CommentCreate
- func (cc *CommentCreate) AddUsers(u ...*User) *CommentCreate
- func (cc *CommentCreate) Exec(ctx context.Context) error
- func (cc *CommentCreate) ExecX(ctx context.Context)
- func (cc *CommentCreate) Mutation() *CommentMutation
- func (cc *CommentCreate) Save(ctx context.Context) (*Comment, error)
- func (cc *CommentCreate) SaveX(ctx context.Context) *Comment
- func (c *CommentCreate) SetInput(i CreateCommentInput) *CommentCreate
- func (cc *CommentCreate) SetText(s string) *CommentCreate
- type CommentCreateBulk
- type CommentDelete
- type CommentDeleteOne
- type CommentEdge
- type CommentEdges
- type CommentGroupBy
- func (cgb *CommentGroupBy) Aggregate(fns ...AggregateFunc) *CommentGroupBy
- func (s *CommentGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *CommentGroupBy) BoolX(ctx context.Context) bool
- func (s *CommentGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *CommentGroupBy) BoolsX(ctx context.Context) []bool
- func (s *CommentGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *CommentGroupBy) Float64X(ctx context.Context) float64
- func (s *CommentGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *CommentGroupBy) Float64sX(ctx context.Context) []float64
- func (s *CommentGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *CommentGroupBy) IntX(ctx context.Context) int
- func (s *CommentGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *CommentGroupBy) IntsX(ctx context.Context) []int
- func (cgb *CommentGroupBy) Scan(ctx context.Context, v any) error
- func (s *CommentGroupBy) ScanX(ctx context.Context, v any)
- func (s *CommentGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *CommentGroupBy) StringX(ctx context.Context) string
- func (s *CommentGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *CommentGroupBy) StringsX(ctx context.Context) []string
- type CommentMutation
- func (m *CommentMutation) AddEpicIDs(ids ...int)
- func (m *CommentMutation) AddField(name string, value ent.Value) error
- func (m *CommentMutation) AddProjectIDs(ids ...int)
- func (m *CommentMutation) AddUserIDs(ids ...int)
- func (m *CommentMutation) AddedEdges() []string
- func (m *CommentMutation) AddedField(name string) (ent.Value, bool)
- func (m *CommentMutation) AddedFields() []string
- func (m *CommentMutation) AddedIDs(name string) []ent.Value
- func (m *CommentMutation) ClearEdge(name string) error
- func (m *CommentMutation) ClearEpics()
- func (m *CommentMutation) ClearField(name string) error
- func (m *CommentMutation) ClearProjects()
- func (m *CommentMutation) ClearUsers()
- func (m *CommentMutation) ClearedEdges() []string
- func (m *CommentMutation) ClearedFields() []string
- func (m CommentMutation) Client() *Client
- func (m *CommentMutation) EdgeCleared(name string) bool
- func (m *CommentMutation) EpicsCleared() bool
- func (m *CommentMutation) EpicsIDs() (ids []int)
- func (m *CommentMutation) Field(name string) (ent.Value, bool)
- func (m *CommentMutation) FieldCleared(name string) bool
- func (m *CommentMutation) Fields() []string
- func (m *CommentMutation) ID() (id int, exists bool)
- func (m *CommentMutation) IDs(ctx context.Context) ([]int, error)
- func (m *CommentMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *CommentMutation) OldText(ctx context.Context) (v string, err error)
- func (m *CommentMutation) Op() Op
- func (m *CommentMutation) ProjectsCleared() bool
- func (m *CommentMutation) ProjectsIDs() (ids []int)
- func (m *CommentMutation) RemoveEpicIDs(ids ...int)
- func (m *CommentMutation) RemoveProjectIDs(ids ...int)
- func (m *CommentMutation) RemoveUserIDs(ids ...int)
- func (m *CommentMutation) RemovedEdges() []string
- func (m *CommentMutation) RemovedEpicsIDs() (ids []int)
- func (m *CommentMutation) RemovedIDs(name string) []ent.Value
- func (m *CommentMutation) RemovedProjectsIDs() (ids []int)
- func (m *CommentMutation) RemovedUsersIDs() (ids []int)
- func (m *CommentMutation) ResetEdge(name string) error
- func (m *CommentMutation) ResetEpics()
- func (m *CommentMutation) ResetField(name string) error
- func (m *CommentMutation) ResetProjects()
- func (m *CommentMutation) ResetText()
- func (m *CommentMutation) ResetUsers()
- func (m *CommentMutation) SetField(name string, value ent.Value) error
- func (m *CommentMutation) SetOp(op Op)
- func (m *CommentMutation) SetText(s string)
- func (m *CommentMutation) Text() (r string, exists bool)
- func (m CommentMutation) Tx() (*Tx, error)
- func (m *CommentMutation) Type() string
- func (m *CommentMutation) UsersCleared() bool
- func (m *CommentMutation) UsersIDs() (ids []int)
- func (m *CommentMutation) Where(ps ...predicate.Comment)
- func (m *CommentMutation) WhereP(ps ...func(*sql.Selector))
- type CommentOrder
- type CommentOrderField
- type CommentPaginateOption
- type CommentQuery
- func (cq *CommentQuery) Aggregate(fns ...AggregateFunc) *CommentSelect
- func (cq *CommentQuery) All(ctx context.Context) ([]*Comment, error)
- func (cq *CommentQuery) AllX(ctx context.Context) []*Comment
- func (cq *CommentQuery) Clone() *CommentQuery
- func (c *CommentQuery) CollectFields(ctx context.Context, satisfies ...string) (*CommentQuery, error)
- func (cq *CommentQuery) Count(ctx context.Context) (int, error)
- func (cq *CommentQuery) CountX(ctx context.Context) int
- func (cq *CommentQuery) Exist(ctx context.Context) (bool, error)
- func (cq *CommentQuery) ExistX(ctx context.Context) bool
- func (cq *CommentQuery) First(ctx context.Context) (*Comment, error)
- func (cq *CommentQuery) FirstID(ctx context.Context) (id int, err error)
- func (cq *CommentQuery) FirstIDX(ctx context.Context) int
- func (cq *CommentQuery) FirstX(ctx context.Context) *Comment
- func (cq *CommentQuery) GroupBy(field string, fields ...string) *CommentGroupBy
- func (cq *CommentQuery) IDs(ctx context.Context) ([]int, error)
- func (cq *CommentQuery) IDsX(ctx context.Context) []int
- func (cq *CommentQuery) Limit(limit int) *CommentQuery
- func (cq *CommentQuery) Offset(offset int) *CommentQuery
- func (cq *CommentQuery) Only(ctx context.Context) (*Comment, error)
- func (cq *CommentQuery) OnlyID(ctx context.Context) (id int, err error)
- func (cq *CommentQuery) OnlyIDX(ctx context.Context) int
- func (cq *CommentQuery) OnlyX(ctx context.Context) *Comment
- func (cq *CommentQuery) Order(o ...OrderFunc) *CommentQuery
- func (c *CommentQuery) Paginate(ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, ...) (*CommentConnection, error)
- func (cq *CommentQuery) QueryEpics() *EpicQuery
- func (cq *CommentQuery) QueryProjects() *ProjectQuery
- func (cq *CommentQuery) QueryUsers() *UserQuery
- func (cq *CommentQuery) Select(fields ...string) *CommentSelect
- func (cq *CommentQuery) Unique(unique bool) *CommentQuery
- func (cq *CommentQuery) Where(ps ...predicate.Comment) *CommentQuery
- func (cq *CommentQuery) WithEpics(opts ...func(*EpicQuery)) *CommentQuery
- func (cq *CommentQuery) WithNamedEpics(name string, opts ...func(*EpicQuery)) *CommentQuery
- func (cq *CommentQuery) WithNamedProjects(name string, opts ...func(*ProjectQuery)) *CommentQuery
- func (cq *CommentQuery) WithNamedUsers(name string, opts ...func(*UserQuery)) *CommentQuery
- func (cq *CommentQuery) WithProjects(opts ...func(*ProjectQuery)) *CommentQuery
- func (cq *CommentQuery) WithUsers(opts ...func(*UserQuery)) *CommentQuery
- type CommentSelect
- func (cs *CommentSelect) Aggregate(fns ...AggregateFunc) *CommentSelect
- func (s *CommentSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *CommentSelect) BoolX(ctx context.Context) bool
- func (s *CommentSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *CommentSelect) BoolsX(ctx context.Context) []bool
- func (s *CommentSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *CommentSelect) Float64X(ctx context.Context) float64
- func (s *CommentSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *CommentSelect) Float64sX(ctx context.Context) []float64
- func (s *CommentSelect) Int(ctx context.Context) (_ int, err error)
- func (s *CommentSelect) IntX(ctx context.Context) int
- func (s *CommentSelect) Ints(ctx context.Context) ([]int, error)
- func (s *CommentSelect) IntsX(ctx context.Context) []int
- func (cs *CommentSelect) Scan(ctx context.Context, v any) error
- func (s *CommentSelect) ScanX(ctx context.Context, v any)
- func (s *CommentSelect) String(ctx context.Context) (_ string, err error)
- func (s *CommentSelect) StringX(ctx context.Context) string
- func (s *CommentSelect) Strings(ctx context.Context) ([]string, error)
- func (s *CommentSelect) StringsX(ctx context.Context) []string
- type CommentUpdate
- func (cu *CommentUpdate) AddEpicIDs(ids ...int) *CommentUpdate
- func (cu *CommentUpdate) AddEpics(e ...*Epic) *CommentUpdate
- func (cu *CommentUpdate) AddProjectIDs(ids ...int) *CommentUpdate
- func (cu *CommentUpdate) AddProjects(p ...*Project) *CommentUpdate
- func (cu *CommentUpdate) AddUserIDs(ids ...int) *CommentUpdate
- func (cu *CommentUpdate) AddUsers(u ...*User) *CommentUpdate
- func (cu *CommentUpdate) ClearEpics() *CommentUpdate
- func (cu *CommentUpdate) ClearProjects() *CommentUpdate
- func (cu *CommentUpdate) ClearUsers() *CommentUpdate
- func (cu *CommentUpdate) Exec(ctx context.Context) error
- func (cu *CommentUpdate) ExecX(ctx context.Context)
- func (cu *CommentUpdate) Mutation() *CommentMutation
- func (cu *CommentUpdate) RemoveEpicIDs(ids ...int) *CommentUpdate
- func (cu *CommentUpdate) RemoveEpics(e ...*Epic) *CommentUpdate
- func (cu *CommentUpdate) RemoveProjectIDs(ids ...int) *CommentUpdate
- func (cu *CommentUpdate) RemoveProjects(p ...*Project) *CommentUpdate
- func (cu *CommentUpdate) RemoveUserIDs(ids ...int) *CommentUpdate
- func (cu *CommentUpdate) RemoveUsers(u ...*User) *CommentUpdate
- func (cu *CommentUpdate) Save(ctx context.Context) (int, error)
- func (cu *CommentUpdate) SaveX(ctx context.Context) int
- func (c *CommentUpdate) SetInput(i UpdateCommentInput) *CommentUpdate
- func (cu *CommentUpdate) SetText(s string) *CommentUpdate
- func (cu *CommentUpdate) Where(ps ...predicate.Comment) *CommentUpdate
- type CommentUpdateOne
- func (cuo *CommentUpdateOne) AddEpicIDs(ids ...int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddEpics(e ...*Epic) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddProjectIDs(ids ...int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddProjects(p ...*Project) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddUserIDs(ids ...int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddUsers(u ...*User) *CommentUpdateOne
- func (cuo *CommentUpdateOne) ClearEpics() *CommentUpdateOne
- func (cuo *CommentUpdateOne) ClearProjects() *CommentUpdateOne
- func (cuo *CommentUpdateOne) ClearUsers() *CommentUpdateOne
- func (cuo *CommentUpdateOne) Exec(ctx context.Context) error
- func (cuo *CommentUpdateOne) ExecX(ctx context.Context)
- func (cuo *CommentUpdateOne) Mutation() *CommentMutation
- func (cuo *CommentUpdateOne) RemoveEpicIDs(ids ...int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) RemoveEpics(e ...*Epic) *CommentUpdateOne
- func (cuo *CommentUpdateOne) RemoveProjectIDs(ids ...int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) RemoveProjects(p ...*Project) *CommentUpdateOne
- func (cuo *CommentUpdateOne) RemoveUserIDs(ids ...int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) RemoveUsers(u ...*User) *CommentUpdateOne
- func (cuo *CommentUpdateOne) Save(ctx context.Context) (*Comment, error)
- func (cuo *CommentUpdateOne) SaveX(ctx context.Context) *Comment
- func (cuo *CommentUpdateOne) Select(field string, fields ...string) *CommentUpdateOne
- func (c *CommentUpdateOne) SetInput(i UpdateCommentInput) *CommentUpdateOne
- func (cuo *CommentUpdateOne) SetText(s string) *CommentUpdateOne
- type CommentWhereInput
- type Comments
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type CreateCommentInput
- type CreateEpicInput
- type CreateProjectInput
- type CreateUserInput
- type Cursor
- type Edge
- type Epic
- func (e *Epic) Assignee(ctx context.Context) (*User, error)
- func (e *Epic) Comments(ctx context.Context) (result []*Comment, err error)
- func (e *Epic) NamedComments(name string) ([]*Comment, error)
- func (e *Epic) Node(ctx context.Context) (node *Node, err error)
- func (e *Epic) Project(ctx context.Context) (*Project, error)
- func (e *Epic) QueryAssignee() *UserQuery
- func (e *Epic) QueryComments() *CommentQuery
- func (e *Epic) QueryProject() *ProjectQuery
- func (e *Epic) QueryReporter() *UserQuery
- func (e *Epic) Reporter(ctx context.Context) (*User, error)
- func (e *Epic) String() string
- func (e *Epic) ToEdge(order *EpicOrder) *EpicEdge
- func (e *Epic) Unwrap() *Epic
- func (e *Epic) Update() *EpicUpdateOne
- type EpicClient
- func (c *EpicClient) Create() *EpicCreate
- func (c *EpicClient) CreateBulk(builders ...*EpicCreate) *EpicCreateBulk
- func (c *EpicClient) Delete() *EpicDelete
- func (c *EpicClient) DeleteOne(e *Epic) *EpicDeleteOne
- func (c *EpicClient) DeleteOneID(id int) *EpicDeleteOne
- func (c *EpicClient) Get(ctx context.Context, id int) (*Epic, error)
- func (c *EpicClient) GetX(ctx context.Context, id int) *Epic
- func (c *EpicClient) Hooks() []Hook
- func (c *EpicClient) Intercept(interceptors ...Interceptor)
- func (c *EpicClient) Interceptors() []Interceptor
- func (c *EpicClient) Query() *EpicQuery
- func (c *EpicClient) QueryAssignee(e *Epic) *UserQuery
- func (c *EpicClient) QueryComments(e *Epic) *CommentQuery
- func (c *EpicClient) QueryProject(e *Epic) *ProjectQuery
- func (c *EpicClient) QueryReporter(e *Epic) *UserQuery
- func (c *EpicClient) Update() *EpicUpdate
- func (c *EpicClient) UpdateOne(e *Epic) *EpicUpdateOne
- func (c *EpicClient) UpdateOneID(id int) *EpicUpdateOne
- func (c *EpicClient) Use(hooks ...Hook)
- type EpicConnection
- type EpicCreate
- func (ec *EpicCreate) AddCommentIDs(ids ...int) *EpicCreate
- func (ec *EpicCreate) AddComments(c ...*Comment) *EpicCreate
- func (ec *EpicCreate) Exec(ctx context.Context) error
- func (ec *EpicCreate) ExecX(ctx context.Context)
- func (ec *EpicCreate) Mutation() *EpicMutation
- func (ec *EpicCreate) Save(ctx context.Context) (*Epic, error)
- func (ec *EpicCreate) SaveX(ctx context.Context) *Epic
- func (ec *EpicCreate) SetAssignee(u *User) *EpicCreate
- func (ec *EpicCreate) SetAssigneeID(id int) *EpicCreate
- func (ec *EpicCreate) SetDescription(s string) *EpicCreate
- func (c *EpicCreate) SetInput(i CreateEpicInput) *EpicCreate
- func (ec *EpicCreate) SetName(s string) *EpicCreate
- func (ec *EpicCreate) SetNillableAssigneeID(id *int) *EpicCreate
- func (ec *EpicCreate) SetNillableProjectID(id *int) *EpicCreate
- func (ec *EpicCreate) SetNillableReporterID(id *int) *EpicCreate
- func (ec *EpicCreate) SetProject(p *Project) *EpicCreate
- func (ec *EpicCreate) SetProjectID(id int) *EpicCreate
- func (ec *EpicCreate) SetReporter(u *User) *EpicCreate
- func (ec *EpicCreate) SetReporterID(id int) *EpicCreate
- type EpicCreateBulk
- type EpicDelete
- type EpicDeleteOne
- type EpicEdge
- type EpicEdges
- type EpicGroupBy
- func (egb *EpicGroupBy) Aggregate(fns ...AggregateFunc) *EpicGroupBy
- func (s *EpicGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *EpicGroupBy) BoolX(ctx context.Context) bool
- func (s *EpicGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *EpicGroupBy) BoolsX(ctx context.Context) []bool
- func (s *EpicGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *EpicGroupBy) Float64X(ctx context.Context) float64
- func (s *EpicGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *EpicGroupBy) Float64sX(ctx context.Context) []float64
- func (s *EpicGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *EpicGroupBy) IntX(ctx context.Context) int
- func (s *EpicGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *EpicGroupBy) IntsX(ctx context.Context) []int
- func (egb *EpicGroupBy) Scan(ctx context.Context, v any) error
- func (s *EpicGroupBy) ScanX(ctx context.Context, v any)
- func (s *EpicGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *EpicGroupBy) StringX(ctx context.Context) string
- func (s *EpicGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *EpicGroupBy) StringsX(ctx context.Context) []string
- type EpicMutation
- func (m *EpicMutation) AddCommentIDs(ids ...int)
- func (m *EpicMutation) AddField(name string, value ent.Value) error
- func (m *EpicMutation) AddedEdges() []string
- func (m *EpicMutation) AddedField(name string) (ent.Value, bool)
- func (m *EpicMutation) AddedFields() []string
- func (m *EpicMutation) AddedIDs(name string) []ent.Value
- func (m *EpicMutation) AssigneeCleared() bool
- func (m *EpicMutation) AssigneeID() (id int, exists bool)
- func (m *EpicMutation) AssigneeIDs() (ids []int)
- func (m *EpicMutation) ClearAssignee()
- func (m *EpicMutation) ClearComments()
- func (m *EpicMutation) ClearEdge(name string) error
- func (m *EpicMutation) ClearField(name string) error
- func (m *EpicMutation) ClearProject()
- func (m *EpicMutation) ClearReporter()
- func (m *EpicMutation) ClearedEdges() []string
- func (m *EpicMutation) ClearedFields() []string
- func (m EpicMutation) Client() *Client
- func (m *EpicMutation) CommentsCleared() bool
- func (m *EpicMutation) CommentsIDs() (ids []int)
- func (m *EpicMutation) Description() (r string, exists bool)
- func (m *EpicMutation) EdgeCleared(name string) bool
- func (m *EpicMutation) Field(name string) (ent.Value, bool)
- func (m *EpicMutation) FieldCleared(name string) bool
- func (m *EpicMutation) Fields() []string
- func (m *EpicMutation) ID() (id int, exists bool)
- func (m *EpicMutation) IDs(ctx context.Context) ([]int, error)
- func (m *EpicMutation) Name() (r string, exists bool)
- func (m *EpicMutation) OldDescription(ctx context.Context) (v string, err error)
- func (m *EpicMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *EpicMutation) OldName(ctx context.Context) (v string, err error)
- func (m *EpicMutation) Op() Op
- func (m *EpicMutation) ProjectCleared() bool
- func (m *EpicMutation) ProjectID() (id int, exists bool)
- func (m *EpicMutation) ProjectIDs() (ids []int)
- func (m *EpicMutation) RemoveCommentIDs(ids ...int)
- func (m *EpicMutation) RemovedCommentsIDs() (ids []int)
- func (m *EpicMutation) RemovedEdges() []string
- func (m *EpicMutation) RemovedIDs(name string) []ent.Value
- func (m *EpicMutation) ReporterCleared() bool
- func (m *EpicMutation) ReporterID() (id int, exists bool)
- func (m *EpicMutation) ReporterIDs() (ids []int)
- func (m *EpicMutation) ResetAssignee()
- func (m *EpicMutation) ResetComments()
- func (m *EpicMutation) ResetDescription()
- func (m *EpicMutation) ResetEdge(name string) error
- func (m *EpicMutation) ResetField(name string) error
- func (m *EpicMutation) ResetName()
- func (m *EpicMutation) ResetProject()
- func (m *EpicMutation) ResetReporter()
- func (m *EpicMutation) SetAssigneeID(id int)
- func (m *EpicMutation) SetDescription(s string)
- func (m *EpicMutation) SetField(name string, value ent.Value) error
- func (m *EpicMutation) SetName(s string)
- func (m *EpicMutation) SetOp(op Op)
- func (m *EpicMutation) SetProjectID(id int)
- func (m *EpicMutation) SetReporterID(id int)
- func (m EpicMutation) Tx() (*Tx, error)
- func (m *EpicMutation) Type() string
- func (m *EpicMutation) Where(ps ...predicate.Epic)
- func (m *EpicMutation) WhereP(ps ...func(*sql.Selector))
- type EpicOrder
- type EpicOrderField
- type EpicPaginateOption
- type EpicQuery
- func (eq *EpicQuery) Aggregate(fns ...AggregateFunc) *EpicSelect
- func (eq *EpicQuery) All(ctx context.Context) ([]*Epic, error)
- func (eq *EpicQuery) AllX(ctx context.Context) []*Epic
- func (eq *EpicQuery) Clone() *EpicQuery
- func (e *EpicQuery) CollectFields(ctx context.Context, satisfies ...string) (*EpicQuery, error)
- func (eq *EpicQuery) Count(ctx context.Context) (int, error)
- func (eq *EpicQuery) CountX(ctx context.Context) int
- func (eq *EpicQuery) Exist(ctx context.Context) (bool, error)
- func (eq *EpicQuery) ExistX(ctx context.Context) bool
- func (eq *EpicQuery) First(ctx context.Context) (*Epic, error)
- func (eq *EpicQuery) FirstID(ctx context.Context) (id int, err error)
- func (eq *EpicQuery) FirstIDX(ctx context.Context) int
- func (eq *EpicQuery) FirstX(ctx context.Context) *Epic
- func (eq *EpicQuery) GroupBy(field string, fields ...string) *EpicGroupBy
- func (eq *EpicQuery) IDs(ctx context.Context) ([]int, error)
- func (eq *EpicQuery) IDsX(ctx context.Context) []int
- func (eq *EpicQuery) Limit(limit int) *EpicQuery
- func (eq *EpicQuery) Offset(offset int) *EpicQuery
- func (eq *EpicQuery) Only(ctx context.Context) (*Epic, error)
- func (eq *EpicQuery) OnlyID(ctx context.Context) (id int, err error)
- func (eq *EpicQuery) OnlyIDX(ctx context.Context) int
- func (eq *EpicQuery) OnlyX(ctx context.Context) *Epic
- func (eq *EpicQuery) Order(o ...OrderFunc) *EpicQuery
- func (e *EpicQuery) Paginate(ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, ...) (*EpicConnection, error)
- func (eq *EpicQuery) QueryAssignee() *UserQuery
- func (eq *EpicQuery) QueryComments() *CommentQuery
- func (eq *EpicQuery) QueryProject() *ProjectQuery
- func (eq *EpicQuery) QueryReporter() *UserQuery
- func (eq *EpicQuery) Select(fields ...string) *EpicSelect
- func (eq *EpicQuery) Unique(unique bool) *EpicQuery
- func (eq *EpicQuery) Where(ps ...predicate.Epic) *EpicQuery
- func (eq *EpicQuery) WithAssignee(opts ...func(*UserQuery)) *EpicQuery
- func (eq *EpicQuery) WithComments(opts ...func(*CommentQuery)) *EpicQuery
- func (eq *EpicQuery) WithNamedComments(name string, opts ...func(*CommentQuery)) *EpicQuery
- func (eq *EpicQuery) WithProject(opts ...func(*ProjectQuery)) *EpicQuery
- func (eq *EpicQuery) WithReporter(opts ...func(*UserQuery)) *EpicQuery
- type EpicSelect
- func (es *EpicSelect) Aggregate(fns ...AggregateFunc) *EpicSelect
- func (s *EpicSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *EpicSelect) BoolX(ctx context.Context) bool
- func (s *EpicSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *EpicSelect) BoolsX(ctx context.Context) []bool
- func (s *EpicSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *EpicSelect) Float64X(ctx context.Context) float64
- func (s *EpicSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *EpicSelect) Float64sX(ctx context.Context) []float64
- func (s *EpicSelect) Int(ctx context.Context) (_ int, err error)
- func (s *EpicSelect) IntX(ctx context.Context) int
- func (s *EpicSelect) Ints(ctx context.Context) ([]int, error)
- func (s *EpicSelect) IntsX(ctx context.Context) []int
- func (es *EpicSelect) Scan(ctx context.Context, v any) error
- func (s *EpicSelect) ScanX(ctx context.Context, v any)
- func (s *EpicSelect) String(ctx context.Context) (_ string, err error)
- func (s *EpicSelect) StringX(ctx context.Context) string
- func (s *EpicSelect) Strings(ctx context.Context) ([]string, error)
- func (s *EpicSelect) StringsX(ctx context.Context) []string
- type EpicUpdate
- func (eu *EpicUpdate) AddCommentIDs(ids ...int) *EpicUpdate
- func (eu *EpicUpdate) AddComments(c ...*Comment) *EpicUpdate
- func (eu *EpicUpdate) ClearAssignee() *EpicUpdate
- func (eu *EpicUpdate) ClearComments() *EpicUpdate
- func (eu *EpicUpdate) ClearProject() *EpicUpdate
- func (eu *EpicUpdate) ClearReporter() *EpicUpdate
- func (eu *EpicUpdate) Exec(ctx context.Context) error
- func (eu *EpicUpdate) ExecX(ctx context.Context)
- func (eu *EpicUpdate) Mutation() *EpicMutation
- func (eu *EpicUpdate) RemoveCommentIDs(ids ...int) *EpicUpdate
- func (eu *EpicUpdate) RemoveComments(c ...*Comment) *EpicUpdate
- func (eu *EpicUpdate) Save(ctx context.Context) (int, error)
- func (eu *EpicUpdate) SaveX(ctx context.Context) int
- func (eu *EpicUpdate) SetAssignee(u *User) *EpicUpdate
- func (eu *EpicUpdate) SetAssigneeID(id int) *EpicUpdate
- func (eu *EpicUpdate) SetDescription(s string) *EpicUpdate
- func (c *EpicUpdate) SetInput(i UpdateEpicInput) *EpicUpdate
- func (eu *EpicUpdate) SetName(s string) *EpicUpdate
- func (eu *EpicUpdate) SetNillableAssigneeID(id *int) *EpicUpdate
- func (eu *EpicUpdate) SetNillableProjectID(id *int) *EpicUpdate
- func (eu *EpicUpdate) SetNillableReporterID(id *int) *EpicUpdate
- func (eu *EpicUpdate) SetProject(p *Project) *EpicUpdate
- func (eu *EpicUpdate) SetProjectID(id int) *EpicUpdate
- func (eu *EpicUpdate) SetReporter(u *User) *EpicUpdate
- func (eu *EpicUpdate) SetReporterID(id int) *EpicUpdate
- func (eu *EpicUpdate) Where(ps ...predicate.Epic) *EpicUpdate
- type EpicUpdateOne
- func (euo *EpicUpdateOne) AddCommentIDs(ids ...int) *EpicUpdateOne
- func (euo *EpicUpdateOne) AddComments(c ...*Comment) *EpicUpdateOne
- func (euo *EpicUpdateOne) ClearAssignee() *EpicUpdateOne
- func (euo *EpicUpdateOne) ClearComments() *EpicUpdateOne
- func (euo *EpicUpdateOne) ClearProject() *EpicUpdateOne
- func (euo *EpicUpdateOne) ClearReporter() *EpicUpdateOne
- func (euo *EpicUpdateOne) Exec(ctx context.Context) error
- func (euo *EpicUpdateOne) ExecX(ctx context.Context)
- func (euo *EpicUpdateOne) Mutation() *EpicMutation
- func (euo *EpicUpdateOne) RemoveCommentIDs(ids ...int) *EpicUpdateOne
- func (euo *EpicUpdateOne) RemoveComments(c ...*Comment) *EpicUpdateOne
- func (euo *EpicUpdateOne) Save(ctx context.Context) (*Epic, error)
- func (euo *EpicUpdateOne) SaveX(ctx context.Context) *Epic
- func (euo *EpicUpdateOne) Select(field string, fields ...string) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetAssignee(u *User) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetAssigneeID(id int) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetDescription(s string) *EpicUpdateOne
- func (c *EpicUpdateOne) SetInput(i UpdateEpicInput) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetName(s string) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetNillableAssigneeID(id *int) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetNillableProjectID(id *int) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetNillableReporterID(id *int) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetProject(p *Project) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetProjectID(id int) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetReporter(u *User) *EpicUpdateOne
- func (euo *EpicUpdateOne) SetReporterID(id int) *EpicUpdateOne
- type EpicWhereInput
- type Epics
- type Field
- type Hook
- type InterceptFunc
- type Interceptor
- type MutateFunc
- type Mutation
- type Mutator
- type Node
- type NodeOption
- type Noder
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Op
- type Option
- type OrderDirection
- type OrderFunc
- type PageInfo
- type Policy
- type Project
- func (pr *Project) Comments(ctx context.Context) (result []*Comment, err error)
- func (pr *Project) Epics(ctx context.Context) (result []*Epic, err error)
- func (pr *Project) NamedComments(name string) ([]*Comment, error)
- func (pr *Project) NamedEpics(name string) ([]*Epic, error)
- func (pr *Project) Node(ctx context.Context) (node *Node, err error)
- func (pr *Project) Owner(ctx context.Context) (*User, error)
- func (pr *Project) QueryComments() *CommentQuery
- func (pr *Project) QueryEpics() *EpicQuery
- func (pr *Project) QueryOwner() *UserQuery
- func (pr *Project) String() string
- func (pr *Project) ToEdge(order *ProjectOrder) *ProjectEdge
- func (pr *Project) Unwrap() *Project
- func (pr *Project) Update() *ProjectUpdateOne
- type ProjectClient
- func (c *ProjectClient) Create() *ProjectCreate
- func (c *ProjectClient) CreateBulk(builders ...*ProjectCreate) *ProjectCreateBulk
- func (c *ProjectClient) Delete() *ProjectDelete
- func (c *ProjectClient) DeleteOne(pr *Project) *ProjectDeleteOne
- func (c *ProjectClient) DeleteOneID(id int) *ProjectDeleteOne
- func (c *ProjectClient) Get(ctx context.Context, id int) (*Project, error)
- func (c *ProjectClient) GetX(ctx context.Context, id int) *Project
- func (c *ProjectClient) Hooks() []Hook
- func (c *ProjectClient) Intercept(interceptors ...Interceptor)
- func (c *ProjectClient) Interceptors() []Interceptor
- func (c *ProjectClient) Query() *ProjectQuery
- func (c *ProjectClient) QueryComments(pr *Project) *CommentQuery
- func (c *ProjectClient) QueryEpics(pr *Project) *EpicQuery
- func (c *ProjectClient) QueryOwner(pr *Project) *UserQuery
- func (c *ProjectClient) Update() *ProjectUpdate
- func (c *ProjectClient) UpdateOne(pr *Project) *ProjectUpdateOne
- func (c *ProjectClient) UpdateOneID(id int) *ProjectUpdateOne
- func (c *ProjectClient) Use(hooks ...Hook)
- type ProjectConnection
- type ProjectCreate
- func (pc *ProjectCreate) AddCommentIDs(ids ...int) *ProjectCreate
- func (pc *ProjectCreate) AddComments(c ...*Comment) *ProjectCreate
- func (pc *ProjectCreate) AddEpicIDs(ids ...int) *ProjectCreate
- func (pc *ProjectCreate) AddEpics(e ...*Epic) *ProjectCreate
- func (pc *ProjectCreate) Exec(ctx context.Context) error
- func (pc *ProjectCreate) ExecX(ctx context.Context)
- func (pc *ProjectCreate) Mutation() *ProjectMutation
- func (pc *ProjectCreate) Save(ctx context.Context) (*Project, error)
- func (pc *ProjectCreate) SaveX(ctx context.Context) *Project
- func (pc *ProjectCreate) SetDescription(s string) *ProjectCreate
- func (c *ProjectCreate) SetInput(i CreateProjectInput) *ProjectCreate
- func (pc *ProjectCreate) SetName(s string) *ProjectCreate
- func (pc *ProjectCreate) SetNillableDescription(s *string) *ProjectCreate
- func (pc *ProjectCreate) SetNillableOwnerID(id *int) *ProjectCreate
- func (pc *ProjectCreate) SetOwner(u *User) *ProjectCreate
- func (pc *ProjectCreate) SetOwnerID(id int) *ProjectCreate
- type ProjectCreateBulk
- type ProjectDelete
- type ProjectDeleteOne
- type ProjectEdge
- type ProjectEdges
- type ProjectGroupBy
- func (pgb *ProjectGroupBy) Aggregate(fns ...AggregateFunc) *ProjectGroupBy
- func (s *ProjectGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *ProjectGroupBy) BoolX(ctx context.Context) bool
- func (s *ProjectGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *ProjectGroupBy) BoolsX(ctx context.Context) []bool
- func (s *ProjectGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *ProjectGroupBy) Float64X(ctx context.Context) float64
- func (s *ProjectGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *ProjectGroupBy) Float64sX(ctx context.Context) []float64
- func (s *ProjectGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *ProjectGroupBy) IntX(ctx context.Context) int
- func (s *ProjectGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *ProjectGroupBy) IntsX(ctx context.Context) []int
- func (pgb *ProjectGroupBy) Scan(ctx context.Context, v any) error
- func (s *ProjectGroupBy) ScanX(ctx context.Context, v any)
- func (s *ProjectGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *ProjectGroupBy) StringX(ctx context.Context) string
- func (s *ProjectGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *ProjectGroupBy) StringsX(ctx context.Context) []string
- type ProjectMutation
- func (m *ProjectMutation) AddCommentIDs(ids ...int)
- func (m *ProjectMutation) AddEpicIDs(ids ...int)
- func (m *ProjectMutation) AddField(name string, value ent.Value) error
- func (m *ProjectMutation) AddedEdges() []string
- func (m *ProjectMutation) AddedField(name string) (ent.Value, bool)
- func (m *ProjectMutation) AddedFields() []string
- func (m *ProjectMutation) AddedIDs(name string) []ent.Value
- func (m *ProjectMutation) ClearComments()
- func (m *ProjectMutation) ClearDescription()
- func (m *ProjectMutation) ClearEdge(name string) error
- func (m *ProjectMutation) ClearEpics()
- func (m *ProjectMutation) ClearField(name string) error
- func (m *ProjectMutation) ClearOwner()
- func (m *ProjectMutation) ClearedEdges() []string
- func (m *ProjectMutation) ClearedFields() []string
- func (m ProjectMutation) Client() *Client
- func (m *ProjectMutation) CommentsCleared() bool
- func (m *ProjectMutation) CommentsIDs() (ids []int)
- func (m *ProjectMutation) Description() (r string, exists bool)
- func (m *ProjectMutation) DescriptionCleared() bool
- func (m *ProjectMutation) EdgeCleared(name string) bool
- func (m *ProjectMutation) EpicsCleared() bool
- func (m *ProjectMutation) EpicsIDs() (ids []int)
- func (m *ProjectMutation) Field(name string) (ent.Value, bool)
- func (m *ProjectMutation) FieldCleared(name string) bool
- func (m *ProjectMutation) Fields() []string
- func (m *ProjectMutation) ID() (id int, exists bool)
- func (m *ProjectMutation) IDs(ctx context.Context) ([]int, error)
- func (m *ProjectMutation) Name() (r string, exists bool)
- func (m *ProjectMutation) OldDescription(ctx context.Context) (v string, err error)
- func (m *ProjectMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ProjectMutation) OldName(ctx context.Context) (v string, err error)
- func (m *ProjectMutation) Op() Op
- func (m *ProjectMutation) OwnerCleared() bool
- func (m *ProjectMutation) OwnerID() (id int, exists bool)
- func (m *ProjectMutation) OwnerIDs() (ids []int)
- func (m *ProjectMutation) RemoveCommentIDs(ids ...int)
- func (m *ProjectMutation) RemoveEpicIDs(ids ...int)
- func (m *ProjectMutation) RemovedCommentsIDs() (ids []int)
- func (m *ProjectMutation) RemovedEdges() []string
- func (m *ProjectMutation) RemovedEpicsIDs() (ids []int)
- func (m *ProjectMutation) RemovedIDs(name string) []ent.Value
- func (m *ProjectMutation) ResetComments()
- func (m *ProjectMutation) ResetDescription()
- func (m *ProjectMutation) ResetEdge(name string) error
- func (m *ProjectMutation) ResetEpics()
- func (m *ProjectMutation) ResetField(name string) error
- func (m *ProjectMutation) ResetName()
- func (m *ProjectMutation) ResetOwner()
- func (m *ProjectMutation) SetDescription(s string)
- func (m *ProjectMutation) SetField(name string, value ent.Value) error
- func (m *ProjectMutation) SetName(s string)
- func (m *ProjectMutation) SetOp(op Op)
- func (m *ProjectMutation) SetOwnerID(id int)
- func (m ProjectMutation) Tx() (*Tx, error)
- func (m *ProjectMutation) Type() string
- func (m *ProjectMutation) Where(ps ...predicate.Project)
- func (m *ProjectMutation) WhereP(ps ...func(*sql.Selector))
- type ProjectOrder
- type ProjectOrderField
- type ProjectPaginateOption
- type ProjectQuery
- func (pq *ProjectQuery) Aggregate(fns ...AggregateFunc) *ProjectSelect
- func (pq *ProjectQuery) All(ctx context.Context) ([]*Project, error)
- func (pq *ProjectQuery) AllX(ctx context.Context) []*Project
- func (pq *ProjectQuery) Clone() *ProjectQuery
- func (pr *ProjectQuery) CollectFields(ctx context.Context, satisfies ...string) (*ProjectQuery, error)
- func (pq *ProjectQuery) Count(ctx context.Context) (int, error)
- func (pq *ProjectQuery) CountX(ctx context.Context) int
- func (pq *ProjectQuery) Exist(ctx context.Context) (bool, error)
- func (pq *ProjectQuery) ExistX(ctx context.Context) bool
- func (pq *ProjectQuery) First(ctx context.Context) (*Project, error)
- func (pq *ProjectQuery) FirstID(ctx context.Context) (id int, err error)
- func (pq *ProjectQuery) FirstIDX(ctx context.Context) int
- func (pq *ProjectQuery) FirstX(ctx context.Context) *Project
- func (pq *ProjectQuery) GroupBy(field string, fields ...string) *ProjectGroupBy
- func (pq *ProjectQuery) IDs(ctx context.Context) ([]int, error)
- func (pq *ProjectQuery) IDsX(ctx context.Context) []int
- func (pq *ProjectQuery) Limit(limit int) *ProjectQuery
- func (pq *ProjectQuery) Offset(offset int) *ProjectQuery
- func (pq *ProjectQuery) Only(ctx context.Context) (*Project, error)
- func (pq *ProjectQuery) OnlyID(ctx context.Context) (id int, err error)
- func (pq *ProjectQuery) OnlyIDX(ctx context.Context) int
- func (pq *ProjectQuery) OnlyX(ctx context.Context) *Project
- func (pq *ProjectQuery) Order(o ...OrderFunc) *ProjectQuery
- func (pr *ProjectQuery) Paginate(ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, ...) (*ProjectConnection, error)
- func (pq *ProjectQuery) QueryComments() *CommentQuery
- func (pq *ProjectQuery) QueryEpics() *EpicQuery
- func (pq *ProjectQuery) QueryOwner() *UserQuery
- func (pq *ProjectQuery) Select(fields ...string) *ProjectSelect
- func (pq *ProjectQuery) Unique(unique bool) *ProjectQuery
- func (pq *ProjectQuery) Where(ps ...predicate.Project) *ProjectQuery
- func (pq *ProjectQuery) WithComments(opts ...func(*CommentQuery)) *ProjectQuery
- func (pq *ProjectQuery) WithEpics(opts ...func(*EpicQuery)) *ProjectQuery
- func (pq *ProjectQuery) WithNamedComments(name string, opts ...func(*CommentQuery)) *ProjectQuery
- func (pq *ProjectQuery) WithNamedEpics(name string, opts ...func(*EpicQuery)) *ProjectQuery
- func (pq *ProjectQuery) WithOwner(opts ...func(*UserQuery)) *ProjectQuery
- type ProjectSelect
- func (ps *ProjectSelect) Aggregate(fns ...AggregateFunc) *ProjectSelect
- func (s *ProjectSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *ProjectSelect) BoolX(ctx context.Context) bool
- func (s *ProjectSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *ProjectSelect) BoolsX(ctx context.Context) []bool
- func (s *ProjectSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *ProjectSelect) Float64X(ctx context.Context) float64
- func (s *ProjectSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *ProjectSelect) Float64sX(ctx context.Context) []float64
- func (s *ProjectSelect) Int(ctx context.Context) (_ int, err error)
- func (s *ProjectSelect) IntX(ctx context.Context) int
- func (s *ProjectSelect) Ints(ctx context.Context) ([]int, error)
- func (s *ProjectSelect) IntsX(ctx context.Context) []int
- func (ps *ProjectSelect) Scan(ctx context.Context, v any) error
- func (s *ProjectSelect) ScanX(ctx context.Context, v any)
- func (s *ProjectSelect) String(ctx context.Context) (_ string, err error)
- func (s *ProjectSelect) StringX(ctx context.Context) string
- func (s *ProjectSelect) Strings(ctx context.Context) ([]string, error)
- func (s *ProjectSelect) StringsX(ctx context.Context) []string
- type ProjectUpdate
- func (pu *ProjectUpdate) AddCommentIDs(ids ...int) *ProjectUpdate
- func (pu *ProjectUpdate) AddComments(c ...*Comment) *ProjectUpdate
- func (pu *ProjectUpdate) AddEpicIDs(ids ...int) *ProjectUpdate
- func (pu *ProjectUpdate) AddEpics(e ...*Epic) *ProjectUpdate
- func (pu *ProjectUpdate) ClearComments() *ProjectUpdate
- func (pu *ProjectUpdate) ClearDescription() *ProjectUpdate
- func (pu *ProjectUpdate) ClearEpics() *ProjectUpdate
- func (pu *ProjectUpdate) ClearOwner() *ProjectUpdate
- func (pu *ProjectUpdate) Exec(ctx context.Context) error
- func (pu *ProjectUpdate) ExecX(ctx context.Context)
- func (pu *ProjectUpdate) Mutation() *ProjectMutation
- func (pu *ProjectUpdate) RemoveCommentIDs(ids ...int) *ProjectUpdate
- func (pu *ProjectUpdate) RemoveComments(c ...*Comment) *ProjectUpdate
- func (pu *ProjectUpdate) RemoveEpicIDs(ids ...int) *ProjectUpdate
- func (pu *ProjectUpdate) RemoveEpics(e ...*Epic) *ProjectUpdate
- func (pu *ProjectUpdate) Save(ctx context.Context) (int, error)
- func (pu *ProjectUpdate) SaveX(ctx context.Context) int
- func (pu *ProjectUpdate) SetDescription(s string) *ProjectUpdate
- func (c *ProjectUpdate) SetInput(i UpdateProjectInput) *ProjectUpdate
- func (pu *ProjectUpdate) SetName(s string) *ProjectUpdate
- func (pu *ProjectUpdate) SetNillableDescription(s *string) *ProjectUpdate
- func (pu *ProjectUpdate) SetNillableOwnerID(id *int) *ProjectUpdate
- func (pu *ProjectUpdate) SetOwner(u *User) *ProjectUpdate
- func (pu *ProjectUpdate) SetOwnerID(id int) *ProjectUpdate
- func (pu *ProjectUpdate) Where(ps ...predicate.Project) *ProjectUpdate
- type ProjectUpdateOne
- func (puo *ProjectUpdateOne) AddCommentIDs(ids ...int) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) AddComments(c ...*Comment) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) AddEpicIDs(ids ...int) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) AddEpics(e ...*Epic) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) ClearComments() *ProjectUpdateOne
- func (puo *ProjectUpdateOne) ClearDescription() *ProjectUpdateOne
- func (puo *ProjectUpdateOne) ClearEpics() *ProjectUpdateOne
- func (puo *ProjectUpdateOne) ClearOwner() *ProjectUpdateOne
- func (puo *ProjectUpdateOne) Exec(ctx context.Context) error
- func (puo *ProjectUpdateOne) ExecX(ctx context.Context)
- func (puo *ProjectUpdateOne) Mutation() *ProjectMutation
- func (puo *ProjectUpdateOne) RemoveCommentIDs(ids ...int) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) RemoveComments(c ...*Comment) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) RemoveEpicIDs(ids ...int) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) RemoveEpics(e ...*Epic) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) Save(ctx context.Context) (*Project, error)
- func (puo *ProjectUpdateOne) SaveX(ctx context.Context) *Project
- func (puo *ProjectUpdateOne) Select(field string, fields ...string) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) SetDescription(s string) *ProjectUpdateOne
- func (c *ProjectUpdateOne) SetInput(i UpdateProjectInput) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) SetName(s string) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) SetNillableDescription(s *string) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) SetNillableOwnerID(id *int) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) SetOwner(u *User) *ProjectUpdateOne
- func (puo *ProjectUpdateOne) SetOwnerID(id int) *ProjectUpdateOne
- type ProjectWhereInput
- type Projects
- type Querier
- type QuerierFunc
- type Query
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type TraverseFunc
- type Traverser
- type Tx
- type UpdateCommentInput
- type UpdateEpicInput
- type UpdateProjectInput
- type UpdateUserInput
- type User
- func (u *User) Assignee(ctx context.Context) (result []*Epic, err error)
- func (u *User) Comments(ctx context.Context) (result []*Comment, err error)
- func (u *User) NamedAssignee(name string) ([]*Epic, error)
- func (u *User) NamedComments(name string) ([]*Comment, error)
- func (u *User) NamedOwns(name string) ([]*Project, error)
- func (u *User) NamedReporter(name string) ([]*Epic, error)
- func (u *User) Node(ctx context.Context) (node *Node, err error)
- func (u *User) Owns(ctx context.Context) (result []*Project, err error)
- func (u *User) QueryAssignee() *EpicQuery
- func (u *User) QueryComments() *CommentQuery
- func (u *User) QueryOwns() *ProjectQuery
- func (u *User) QueryReporter() *EpicQuery
- func (u *User) Reporter(ctx context.Context) (result []*Epic, err error)
- func (u *User) String() string
- func (u *User) ToEdge(order *UserOrder) *UserEdge
- func (u *User) Unwrap() *User
- func (u *User) Update() *UserUpdateOne
- type UserClient
- func (c *UserClient) Create() *UserCreate
- func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
- func (c *UserClient) Delete() *UserDelete
- func (c *UserClient) DeleteOne(u *User) *UserDeleteOne
- func (c *UserClient) DeleteOneID(id int) *UserDeleteOne
- func (c *UserClient) Get(ctx context.Context, id int) (*User, error)
- func (c *UserClient) GetX(ctx context.Context, id int) *User
- func (c *UserClient) Hooks() []Hook
- func (c *UserClient) Intercept(interceptors ...Interceptor)
- func (c *UserClient) Interceptors() []Interceptor
- func (c *UserClient) Query() *UserQuery
- func (c *UserClient) QueryAssignee(u *User) *EpicQuery
- func (c *UserClient) QueryComments(u *User) *CommentQuery
- func (c *UserClient) QueryOwns(u *User) *ProjectQuery
- func (c *UserClient) QueryReporter(u *User) *EpicQuery
- func (c *UserClient) Update() *UserUpdate
- func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
- func (c *UserClient) UpdateOneID(id int) *UserUpdateOne
- func (c *UserClient) Use(hooks ...Hook)
- type UserConnection
- type UserCreate
- func (uc *UserCreate) AddAssignee(e ...*Epic) *UserCreate
- func (uc *UserCreate) AddAssigneeIDs(ids ...int) *UserCreate
- func (uc *UserCreate) AddCommentIDs(ids ...int) *UserCreate
- func (uc *UserCreate) AddComments(c ...*Comment) *UserCreate
- func (uc *UserCreate) AddOwnIDs(ids ...int) *UserCreate
- func (uc *UserCreate) AddOwns(p ...*Project) *UserCreate
- func (uc *UserCreate) AddReporter(e ...*Epic) *UserCreate
- func (uc *UserCreate) AddReporterIDs(ids ...int) *UserCreate
- func (uc *UserCreate) Exec(ctx context.Context) error
- func (uc *UserCreate) ExecX(ctx context.Context)
- func (uc *UserCreate) Mutation() *UserMutation
- func (uc *UserCreate) Save(ctx context.Context) (*User, error)
- func (uc *UserCreate) SaveX(ctx context.Context) *User
- func (uc *UserCreate) SetEmail(s string) *UserCreate
- func (c *UserCreate) SetInput(i CreateUserInput) *UserCreate
- func (uc *UserCreate) SetName(s string) *UserCreate
- func (uc *UserCreate) SetSurname(s string) *UserCreate
- func (uc *UserCreate) SetUsername(s string) *UserCreate
- type UserCreateBulk
- type UserDelete
- type UserDeleteOne
- type UserEdge
- type UserEdges
- type UserGroupBy
- func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
- func (s *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *UserGroupBy) BoolX(ctx context.Context) bool
- func (s *UserGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *UserGroupBy) BoolsX(ctx context.Context) []bool
- func (s *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *UserGroupBy) Float64X(ctx context.Context) float64
- func (s *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *UserGroupBy) Float64sX(ctx context.Context) []float64
- func (s *UserGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *UserGroupBy) IntX(ctx context.Context) int
- func (s *UserGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *UserGroupBy) IntsX(ctx context.Context) []int
- func (ugb *UserGroupBy) Scan(ctx context.Context, v any) error
- func (s *UserGroupBy) ScanX(ctx context.Context, v any)
- func (s *UserGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *UserGroupBy) StringX(ctx context.Context) string
- func (s *UserGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *UserGroupBy) StringsX(ctx context.Context) []string
- type UserMutation
- func (m *UserMutation) AddAssigneeIDs(ids ...int)
- func (m *UserMutation) AddCommentIDs(ids ...int)
- func (m *UserMutation) AddField(name string, value ent.Value) error
- func (m *UserMutation) AddOwnIDs(ids ...int)
- func (m *UserMutation) AddReporterIDs(ids ...int)
- func (m *UserMutation) AddedEdges() []string
- func (m *UserMutation) AddedField(name string) (ent.Value, bool)
- func (m *UserMutation) AddedFields() []string
- func (m *UserMutation) AddedIDs(name string) []ent.Value
- func (m *UserMutation) AssigneeCleared() bool
- func (m *UserMutation) AssigneeIDs() (ids []int)
- func (m *UserMutation) ClearAssignee()
- func (m *UserMutation) ClearComments()
- func (m *UserMutation) ClearEdge(name string) error
- func (m *UserMutation) ClearField(name string) error
- func (m *UserMutation) ClearOwns()
- func (m *UserMutation) ClearReporter()
- func (m *UserMutation) ClearedEdges() []string
- func (m *UserMutation) ClearedFields() []string
- func (m UserMutation) Client() *Client
- func (m *UserMutation) CommentsCleared() bool
- func (m *UserMutation) CommentsIDs() (ids []int)
- func (m *UserMutation) EdgeCleared(name string) bool
- func (m *UserMutation) Email() (r string, exists bool)
- func (m *UserMutation) Field(name string) (ent.Value, bool)
- func (m *UserMutation) FieldCleared(name string) bool
- func (m *UserMutation) Fields() []string
- func (m *UserMutation) ID() (id int, exists bool)
- func (m *UserMutation) IDs(ctx context.Context) ([]int, error)
- func (m *UserMutation) Name() (r string, exists bool)
- func (m *UserMutation) OldEmail(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *UserMutation) OldName(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldSurname(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldUsername(ctx context.Context) (v string, err error)
- func (m *UserMutation) Op() Op
- func (m *UserMutation) OwnsCleared() bool
- func (m *UserMutation) OwnsIDs() (ids []int)
- func (m *UserMutation) RemoveAssigneeIDs(ids ...int)
- func (m *UserMutation) RemoveCommentIDs(ids ...int)
- func (m *UserMutation) RemoveOwnIDs(ids ...int)
- func (m *UserMutation) RemoveReporterIDs(ids ...int)
- func (m *UserMutation) RemovedAssigneeIDs() (ids []int)
- func (m *UserMutation) RemovedCommentsIDs() (ids []int)
- func (m *UserMutation) RemovedEdges() []string
- func (m *UserMutation) RemovedIDs(name string) []ent.Value
- func (m *UserMutation) RemovedOwnsIDs() (ids []int)
- func (m *UserMutation) RemovedReporterIDs() (ids []int)
- func (m *UserMutation) ReporterCleared() bool
- func (m *UserMutation) ReporterIDs() (ids []int)
- func (m *UserMutation) ResetAssignee()
- func (m *UserMutation) ResetComments()
- func (m *UserMutation) ResetEdge(name string) error
- func (m *UserMutation) ResetEmail()
- func (m *UserMutation) ResetField(name string) error
- func (m *UserMutation) ResetName()
- func (m *UserMutation) ResetOwns()
- func (m *UserMutation) ResetReporter()
- func (m *UserMutation) ResetSurname()
- func (m *UserMutation) ResetUsername()
- func (m *UserMutation) SetEmail(s string)
- func (m *UserMutation) SetField(name string, value ent.Value) error
- func (m *UserMutation) SetName(s string)
- func (m *UserMutation) SetOp(op Op)
- func (m *UserMutation) SetSurname(s string)
- func (m *UserMutation) SetUsername(s string)
- func (m *UserMutation) Surname() (r string, exists bool)
- func (m UserMutation) Tx() (*Tx, error)
- func (m *UserMutation) Type() string
- func (m *UserMutation) Username() (r string, exists bool)
- func (m *UserMutation) Where(ps ...predicate.User)
- func (m *UserMutation) WhereP(ps ...func(*sql.Selector))
- type UserOrder
- type UserOrderField
- type UserPaginateOption
- type UserQuery
- func (uq *UserQuery) Aggregate(fns ...AggregateFunc) *UserSelect
- func (uq *UserQuery) All(ctx context.Context) ([]*User, error)
- func (uq *UserQuery) AllX(ctx context.Context) []*User
- func (uq *UserQuery) Clone() *UserQuery
- func (u *UserQuery) CollectFields(ctx context.Context, satisfies ...string) (*UserQuery, error)
- func (uq *UserQuery) Count(ctx context.Context) (int, error)
- func (uq *UserQuery) CountX(ctx context.Context) int
- func (uq *UserQuery) Exist(ctx context.Context) (bool, error)
- func (uq *UserQuery) ExistX(ctx context.Context) bool
- func (uq *UserQuery) First(ctx context.Context) (*User, error)
- func (uq *UserQuery) FirstID(ctx context.Context) (id int, err error)
- func (uq *UserQuery) FirstIDX(ctx context.Context) int
- func (uq *UserQuery) FirstX(ctx context.Context) *User
- func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
- func (uq *UserQuery) IDs(ctx context.Context) ([]int, error)
- func (uq *UserQuery) IDsX(ctx context.Context) []int
- func (uq *UserQuery) Limit(limit int) *UserQuery
- func (uq *UserQuery) Offset(offset int) *UserQuery
- func (uq *UserQuery) Only(ctx context.Context) (*User, error)
- func (uq *UserQuery) OnlyID(ctx context.Context) (id int, err error)
- func (uq *UserQuery) OnlyIDX(ctx context.Context) int
- func (uq *UserQuery) OnlyX(ctx context.Context) *User
- func (uq *UserQuery) Order(o ...OrderFunc) *UserQuery
- func (u *UserQuery) Paginate(ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, ...) (*UserConnection, error)
- func (uq *UserQuery) QueryAssignee() *EpicQuery
- func (uq *UserQuery) QueryComments() *CommentQuery
- func (uq *UserQuery) QueryOwns() *ProjectQuery
- func (uq *UserQuery) QueryReporter() *EpicQuery
- func (uq *UserQuery) Select(fields ...string) *UserSelect
- func (uq *UserQuery) Unique(unique bool) *UserQuery
- func (uq *UserQuery) Where(ps ...predicate.User) *UserQuery
- func (uq *UserQuery) WithAssignee(opts ...func(*EpicQuery)) *UserQuery
- func (uq *UserQuery) WithComments(opts ...func(*CommentQuery)) *UserQuery
- func (uq *UserQuery) WithNamedAssignee(name string, opts ...func(*EpicQuery)) *UserQuery
- func (uq *UserQuery) WithNamedComments(name string, opts ...func(*CommentQuery)) *UserQuery
- func (uq *UserQuery) WithNamedOwns(name string, opts ...func(*ProjectQuery)) *UserQuery
- func (uq *UserQuery) WithNamedReporter(name string, opts ...func(*EpicQuery)) *UserQuery
- func (uq *UserQuery) WithOwns(opts ...func(*ProjectQuery)) *UserQuery
- func (uq *UserQuery) WithReporter(opts ...func(*EpicQuery)) *UserQuery
- type UserSelect
- func (us *UserSelect) Aggregate(fns ...AggregateFunc) *UserSelect
- func (s *UserSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *UserSelect) BoolX(ctx context.Context) bool
- func (s *UserSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *UserSelect) BoolsX(ctx context.Context) []bool
- func (s *UserSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *UserSelect) Float64X(ctx context.Context) float64
- func (s *UserSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *UserSelect) Float64sX(ctx context.Context) []float64
- func (s *UserSelect) Int(ctx context.Context) (_ int, err error)
- func (s *UserSelect) IntX(ctx context.Context) int
- func (s *UserSelect) Ints(ctx context.Context) ([]int, error)
- func (s *UserSelect) IntsX(ctx context.Context) []int
- func (us *UserSelect) Scan(ctx context.Context, v any) error
- func (s *UserSelect) ScanX(ctx context.Context, v any)
- func (s *UserSelect) String(ctx context.Context) (_ string, err error)
- func (s *UserSelect) StringX(ctx context.Context) string
- func (s *UserSelect) Strings(ctx context.Context) ([]string, error)
- func (s *UserSelect) StringsX(ctx context.Context) []string
- type UserUpdate
- func (uu *UserUpdate) AddAssignee(e ...*Epic) *UserUpdate
- func (uu *UserUpdate) AddAssigneeIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) AddCommentIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) AddComments(c ...*Comment) *UserUpdate
- func (uu *UserUpdate) AddOwnIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) AddOwns(p ...*Project) *UserUpdate
- func (uu *UserUpdate) AddReporter(e ...*Epic) *UserUpdate
- func (uu *UserUpdate) AddReporterIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) ClearAssignee() *UserUpdate
- func (uu *UserUpdate) ClearComments() *UserUpdate
- func (uu *UserUpdate) ClearOwns() *UserUpdate
- func (uu *UserUpdate) ClearReporter() *UserUpdate
- func (uu *UserUpdate) Exec(ctx context.Context) error
- func (uu *UserUpdate) ExecX(ctx context.Context)
- func (uu *UserUpdate) Mutation() *UserMutation
- func (uu *UserUpdate) RemoveAssignee(e ...*Epic) *UserUpdate
- func (uu *UserUpdate) RemoveAssigneeIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) RemoveCommentIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) RemoveComments(c ...*Comment) *UserUpdate
- func (uu *UserUpdate) RemoveOwnIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) RemoveOwns(p ...*Project) *UserUpdate
- func (uu *UserUpdate) RemoveReporter(e ...*Epic) *UserUpdate
- func (uu *UserUpdate) RemoveReporterIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) Save(ctx context.Context) (int, error)
- func (uu *UserUpdate) SaveX(ctx context.Context) int
- func (uu *UserUpdate) SetEmail(s string) *UserUpdate
- func (c *UserUpdate) SetInput(i UpdateUserInput) *UserUpdate
- func (uu *UserUpdate) SetName(s string) *UserUpdate
- func (uu *UserUpdate) SetSurname(s string) *UserUpdate
- func (uu *UserUpdate) SetUsername(s string) *UserUpdate
- func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
- type UserUpdateOne
- func (uuo *UserUpdateOne) AddAssignee(e ...*Epic) *UserUpdateOne
- func (uuo *UserUpdateOne) AddAssigneeIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) AddCommentIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) AddComments(c ...*Comment) *UserUpdateOne
- func (uuo *UserUpdateOne) AddOwnIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) AddOwns(p ...*Project) *UserUpdateOne
- func (uuo *UserUpdateOne) AddReporter(e ...*Epic) *UserUpdateOne
- func (uuo *UserUpdateOne) AddReporterIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) ClearAssignee() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearComments() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearOwns() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearReporter() *UserUpdateOne
- func (uuo *UserUpdateOne) Exec(ctx context.Context) error
- func (uuo *UserUpdateOne) ExecX(ctx context.Context)
- func (uuo *UserUpdateOne) Mutation() *UserMutation
- func (uuo *UserUpdateOne) RemoveAssignee(e ...*Epic) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveAssigneeIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveCommentIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveComments(c ...*Comment) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveOwnIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveOwns(p ...*Project) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveReporter(e ...*Epic) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveReporterIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
- func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
- func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetEmail(s string) *UserUpdateOne
- func (c *UserUpdateOne) SetInput(i UpdateUserInput) *UserUpdateOne
- func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetSurname(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetUsername(s string) *UserUpdateOne
- type UserWhereInput
- type Users
- type ValidationError
- type Value
Constants ¶
const ( // Operation types. OpCreate = ent.OpCreate OpDelete = ent.OpDelete OpDeleteOne = ent.OpDeleteOne OpUpdate = ent.OpUpdate OpUpdateOne = ent.OpUpdateOne // Node types. TypeComment = "Comment" TypeEpic = "Epic" TypeProject = "Project" TypeUser = "User" )
Variables ¶
var DefaultCommentOrder = &CommentOrder{ Direction: OrderDirectionAsc, Field: &CommentOrderField{ field: comment.FieldID, toCursor: func(c *Comment) Cursor { return Cursor{ID: c.ID} }, }, }
DefaultCommentOrder is the default ordering of Comment.
var DefaultEpicOrder = &EpicOrder{ Direction: OrderDirectionAsc, Field: &EpicOrderField{ field: epic.FieldID, toCursor: func(e *Epic) Cursor { return Cursor{ID: e.ID} }, }, }
DefaultEpicOrder is the default ordering of Epic.
var DefaultProjectOrder = &ProjectOrder{ Direction: OrderDirectionAsc, Field: &ProjectOrderField{ field: project.FieldID, toCursor: func(pr *Project) Cursor { return Cursor{ID: pr.ID} }, }, }
DefaultProjectOrder is the default ordering of Project.
var DefaultUserOrder = &UserOrder{ Direction: OrderDirectionAsc, Field: &UserOrderField{ field: user.FieldID, toCursor: func(u *User) Cursor { return Cursor{ID: u.ID} }, }, }
DefaultUserOrder is the default ordering of User.
var ErrEmptyCommentWhereInput = errors.New("ent: empty predicate CommentWhereInput")
ErrEmptyCommentWhereInput is returned in case the CommentWhereInput is empty.
var ErrEmptyEpicWhereInput = errors.New("ent: empty predicate EpicWhereInput")
ErrEmptyEpicWhereInput is returned in case the EpicWhereInput is empty.
var ErrEmptyProjectWhereInput = errors.New("ent: empty predicate ProjectWhereInput")
ErrEmptyProjectWhereInput is returned in case the ProjectWhereInput is empty.
var ErrEmptyUserWhereInput = errors.New("ent: empty predicate UserWhereInput")
ErrEmptyUserWhereInput is returned in case the UserWhereInput is empty.
Functions ¶
func IsConstraintError ¶
IsConstraintError returns a boolean indicating whether the error is a constraint failure.
func IsNotFound ¶
IsNotFound returns a boolean indicating whether the error is a not found error.
func IsNotLoaded ¶
IsNotLoaded returns a boolean indicating whether the error is a not loaded error.
func IsNotSingular ¶
IsNotSingular returns a boolean indicating whether the error is a not singular error.
func IsValidationError ¶
IsValidationError returns a boolean indicating whether the error is a validation error.
func NewContext ¶
NewContext returns a new context with the given Client attached.
func NewTxContext ¶
NewTxContext returns a new context with the given Tx attached.
Types ¶
type AggregateFunc ¶
AggregateFunc applies an aggregation step on the group-by traversal/selector.
func As ¶
func As(fn AggregateFunc, end string) AggregateFunc
As is a pseudo aggregation function for renaming another other functions with custom names. For example:
GroupBy(field1, field2). Aggregate(ent.As(ent.Sum(field1), "sum_field1"), (ent.As(ent.Sum(field2), "sum_field2")). Scan(ctx, &v)
func Count ¶
func Count() AggregateFunc
Count applies the "count" aggregation function on each group.
func Max ¶
func Max(field string) AggregateFunc
Max applies the "max" aggregation function on the given field of each group.
func Mean ¶
func Mean(field string) AggregateFunc
Mean applies the "mean" aggregation function on the given field of each group.
func Min ¶
func Min(field string) AggregateFunc
Min applies the "min" aggregation function on the given field of each group.
func Sum ¶
func Sum(field string) AggregateFunc
Sum applies the "sum" aggregation function on the given field of each group.
type Client ¶
type Client struct { // Schema is the client for creating, migrating and dropping schema. Schema *migrate.Schema // Comment is the client for interacting with the Comment builders. Comment *CommentClient // Epic is the client for interacting with the Epic builders. Epic *EpicClient // Project is the client for interacting with the Project builders. Project *ProjectClient // User is the client for interacting with the User builders. User *UserClient // contains filtered or unexported fields }
Client is the client that holds all ent builders.
func FromContext ¶
FromContext returns a Client stored inside a context, or nil if there isn't one.
func Open ¶
Open opens a database/sql.DB specified by the driver name and the data source name, and returns a new client attached to it. Optional parameters can be added for configuring the client.
func (*Client) Debug ¶
Debug returns a new debug-client. It's used to get verbose logging on specific operations.
client.Debug(). Comment. Query(). Count(ctx)
func (*Client) Intercept ¶
func (c *Client) Intercept(interceptors ...Interceptor)
Intercept adds the query interceptors to all the entity clients. In order to add interceptors to a specific client, call: `client.Node.Intercept(...)`.
func (*Client) Noder ¶
Noder returns a Node by its id. If the NodeType was not provided, it will be derived from the id value according to the universal-id configuration.
c.Noder(ctx, id) c.Noder(ctx, id, ent.WithNodeType(typeResolver))
func (*Client) OpenTx ¶
OpenTx opens a transaction and returns a transactional context along with the created transaction.
type Comment ¶
type Comment struct { // ID of the ent. ID int `json:"id,omitempty"` // Text holds the value of the "text" field. Text string `json:"text,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the CommentQuery when eager-loading is set. Edges CommentEdges `json:"edges"` // contains filtered or unexported fields }
Comment is the model entity for the Comment schema.
func (*Comment) NamedEpics ¶
NamedEpics returns the Epics named value or an error if the edge was not loaded in eager-loading with this name.
func (*Comment) NamedProjects ¶
NamedProjects returns the Projects named value or an error if the edge was not loaded in eager-loading with this name.
func (*Comment) NamedUsers ¶
NamedUsers returns the Users named value or an error if the edge was not loaded in eager-loading with this name.
func (*Comment) QueryEpics ¶
QueryEpics queries the "epics" edge of the Comment entity.
func (*Comment) QueryProjects ¶
func (c *Comment) QueryProjects() *ProjectQuery
QueryProjects queries the "projects" edge of the Comment entity.
func (*Comment) QueryUsers ¶
QueryUsers queries the "users" edge of the Comment entity.
func (*Comment) ToEdge ¶
func (c *Comment) ToEdge(order *CommentOrder) *CommentEdge
ToEdge converts Comment into CommentEdge.
func (*Comment) Unwrap ¶
Unwrap unwraps the Comment entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*Comment) Update ¶
func (c *Comment) Update() *CommentUpdateOne
Update returns a builder for updating this Comment. Note that you need to call Comment.Unwrap() before calling this method if this Comment was returned from a transaction, and the transaction was committed or rolled back.
type CommentClient ¶
type CommentClient struct {
// contains filtered or unexported fields
}
CommentClient is a client for the Comment schema.
func NewCommentClient ¶
func NewCommentClient(c config) *CommentClient
NewCommentClient returns a client for the Comment from the given config.
func (*CommentClient) Create ¶
func (c *CommentClient) Create() *CommentCreate
Create returns a builder for creating a Comment entity.
func (*CommentClient) CreateBulk ¶
func (c *CommentClient) CreateBulk(builders ...*CommentCreate) *CommentCreateBulk
CreateBulk returns a builder for creating a bulk of Comment entities.
func (*CommentClient) Delete ¶
func (c *CommentClient) Delete() *CommentDelete
Delete returns a delete builder for Comment.
func (*CommentClient) DeleteOne ¶
func (c *CommentClient) DeleteOne(co *Comment) *CommentDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*CommentClient) DeleteOneID ¶
func (c *CommentClient) DeleteOneID(id int) *CommentDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*CommentClient) GetX ¶
func (c *CommentClient) GetX(ctx context.Context, id int) *Comment
GetX is like Get, but panics if an error occurs.
func (*CommentClient) Hooks ¶
func (c *CommentClient) Hooks() []Hook
Hooks returns the client hooks.
func (*CommentClient) Intercept ¶
func (c *CommentClient) Intercept(interceptors ...Interceptor)
Use adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `comment.Intercept(f(g(h())))`.
func (*CommentClient) Interceptors ¶
func (c *CommentClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*CommentClient) Query ¶
func (c *CommentClient) Query() *CommentQuery
Query returns a query builder for Comment.
func (*CommentClient) QueryEpics ¶
func (c *CommentClient) QueryEpics(co *Comment) *EpicQuery
QueryEpics queries the epics edge of a Comment.
func (*CommentClient) QueryProjects ¶
func (c *CommentClient) QueryProjects(co *Comment) *ProjectQuery
QueryProjects queries the projects edge of a Comment.
func (*CommentClient) QueryUsers ¶
func (c *CommentClient) QueryUsers(co *Comment) *UserQuery
QueryUsers queries the users edge of a Comment.
func (*CommentClient) Update ¶
func (c *CommentClient) Update() *CommentUpdate
Update returns an update builder for Comment.
func (*CommentClient) UpdateOne ¶
func (c *CommentClient) UpdateOne(co *Comment) *CommentUpdateOne
UpdateOne returns an update builder for the given entity.
func (*CommentClient) UpdateOneID ¶
func (c *CommentClient) UpdateOneID(id int) *CommentUpdateOne
UpdateOneID returns an update builder for the given id.
func (*CommentClient) Use ¶
func (c *CommentClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `comment.Hooks(f(g(h())))`.
type CommentConnection ¶
type CommentConnection struct { Edges []*CommentEdge `json:"edges"` PageInfo PageInfo `json:"pageInfo"` TotalCount int `json:"totalCount"` }
CommentConnection is the connection containing edges to Comment.
type CommentCreate ¶
type CommentCreate struct {
// contains filtered or unexported fields
}
CommentCreate is the builder for creating a Comment entity.
func (*CommentCreate) AddEpicIDs ¶
func (cc *CommentCreate) AddEpicIDs(ids ...int) *CommentCreate
AddEpicIDs adds the "epics" edge to the Epic entity by IDs.
func (*CommentCreate) AddEpics ¶
func (cc *CommentCreate) AddEpics(e ...*Epic) *CommentCreate
AddEpics adds the "epics" edges to the Epic entity.
func (*CommentCreate) AddProjectIDs ¶
func (cc *CommentCreate) AddProjectIDs(ids ...int) *CommentCreate
AddProjectIDs adds the "projects" edge to the Project entity by IDs.
func (*CommentCreate) AddProjects ¶
func (cc *CommentCreate) AddProjects(p ...*Project) *CommentCreate
AddProjects adds the "projects" edges to the Project entity.
func (*CommentCreate) AddUserIDs ¶
func (cc *CommentCreate) AddUserIDs(ids ...int) *CommentCreate
AddUserIDs adds the "users" edge to the User entity by IDs.
func (*CommentCreate) AddUsers ¶
func (cc *CommentCreate) AddUsers(u ...*User) *CommentCreate
AddUsers adds the "users" edges to the User entity.
func (*CommentCreate) Exec ¶
func (cc *CommentCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*CommentCreate) ExecX ¶
func (cc *CommentCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*CommentCreate) Mutation ¶
func (cc *CommentCreate) Mutation() *CommentMutation
Mutation returns the CommentMutation object of the builder.
func (*CommentCreate) Save ¶
func (cc *CommentCreate) Save(ctx context.Context) (*Comment, error)
Save creates the Comment in the database.
func (*CommentCreate) SaveX ¶
func (cc *CommentCreate) SaveX(ctx context.Context) *Comment
SaveX calls Save and panics if Save returns an error.
func (*CommentCreate) SetInput ¶
func (c *CommentCreate) SetInput(i CreateCommentInput) *CommentCreate
SetInput applies the change-set in the CreateCommentInput on the CommentCreate builder.
func (*CommentCreate) SetText ¶
func (cc *CommentCreate) SetText(s string) *CommentCreate
SetText sets the "text" field.
type CommentCreateBulk ¶
type CommentCreateBulk struct {
// contains filtered or unexported fields
}
CommentCreateBulk is the builder for creating many Comment entities in bulk.
func (*CommentCreateBulk) Exec ¶
func (ccb *CommentCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*CommentCreateBulk) ExecX ¶
func (ccb *CommentCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type CommentDelete ¶
type CommentDelete struct {
// contains filtered or unexported fields
}
CommentDelete is the builder for deleting a Comment entity.
func (*CommentDelete) Exec ¶
func (cd *CommentDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*CommentDelete) ExecX ¶
func (cd *CommentDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*CommentDelete) Where ¶
func (cd *CommentDelete) Where(ps ...predicate.Comment) *CommentDelete
Where appends a list predicates to the CommentDelete builder.
type CommentDeleteOne ¶
type CommentDeleteOne struct {
// contains filtered or unexported fields
}
CommentDeleteOne is the builder for deleting a single Comment entity.
func (*CommentDeleteOne) Exec ¶
func (cdo *CommentDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*CommentDeleteOne) ExecX ¶
func (cdo *CommentDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type CommentEdge ¶
CommentEdge is the edge representation of Comment.
type CommentEdges ¶
type CommentEdges struct { // Epics holds the value of the epics edge. Epics []*Epic `json:"epics,omitempty"` // Projects holds the value of the projects edge. Projects []*Project `json:"projects,omitempty"` // Users holds the value of the users edge. Users []*User `json:"users,omitempty"` // contains filtered or unexported fields }
CommentEdges holds the relations/edges for other nodes in the graph.
func (CommentEdges) EpicsOrErr ¶
func (e CommentEdges) EpicsOrErr() ([]*Epic, error)
EpicsOrErr returns the Epics value or an error if the edge was not loaded in eager-loading.
func (CommentEdges) ProjectsOrErr ¶
func (e CommentEdges) ProjectsOrErr() ([]*Project, error)
ProjectsOrErr returns the Projects value or an error if the edge was not loaded in eager-loading.
func (CommentEdges) UsersOrErr ¶
func (e CommentEdges) UsersOrErr() ([]*User, error)
UsersOrErr returns the Users value or an error if the edge was not loaded in eager-loading.
type CommentGroupBy ¶
type CommentGroupBy struct {
// contains filtered or unexported fields
}
CommentGroupBy is the group-by builder for Comment entities.
func (*CommentGroupBy) Aggregate ¶
func (cgb *CommentGroupBy) Aggregate(fns ...AggregateFunc) *CommentGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*CommentGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*CommentGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*CommentGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*CommentGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*CommentGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*CommentGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*CommentGroupBy) Scan ¶
func (cgb *CommentGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*CommentGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type CommentMutation ¶
type CommentMutation struct {
// contains filtered or unexported fields
}
CommentMutation represents an operation that mutates the Comment nodes in the graph.
func (*CommentMutation) AddEpicIDs ¶
func (m *CommentMutation) AddEpicIDs(ids ...int)
AddEpicIDs adds the "epics" edge to the Epic entity by ids.
func (*CommentMutation) AddField ¶
func (m *CommentMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*CommentMutation) AddProjectIDs ¶
func (m *CommentMutation) AddProjectIDs(ids ...int)
AddProjectIDs adds the "projects" edge to the Project entity by ids.
func (*CommentMutation) AddUserIDs ¶
func (m *CommentMutation) AddUserIDs(ids ...int)
AddUserIDs adds the "users" edge to the User entity by ids.
func (*CommentMutation) AddedEdges ¶
func (m *CommentMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*CommentMutation) AddedField ¶
func (m *CommentMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*CommentMutation) AddedFields ¶
func (m *CommentMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*CommentMutation) AddedIDs ¶
func (m *CommentMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*CommentMutation) ClearEdge ¶
func (m *CommentMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*CommentMutation) ClearEpics ¶
func (m *CommentMutation) ClearEpics()
ClearEpics clears the "epics" edge to the Epic entity.
func (*CommentMutation) ClearField ¶
func (m *CommentMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*CommentMutation) ClearProjects ¶
func (m *CommentMutation) ClearProjects()
ClearProjects clears the "projects" edge to the Project entity.
func (*CommentMutation) ClearUsers ¶
func (m *CommentMutation) ClearUsers()
ClearUsers clears the "users" edge to the User entity.
func (*CommentMutation) ClearedEdges ¶
func (m *CommentMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*CommentMutation) ClearedFields ¶
func (m *CommentMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (CommentMutation) Client ¶
func (m CommentMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*CommentMutation) EdgeCleared ¶
func (m *CommentMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*CommentMutation) EpicsCleared ¶
func (m *CommentMutation) EpicsCleared() bool
EpicsCleared reports if the "epics" edge to the Epic entity was cleared.
func (*CommentMutation) EpicsIDs ¶
func (m *CommentMutation) EpicsIDs() (ids []int)
EpicsIDs returns the "epics" edge IDs in the mutation.
func (*CommentMutation) Field ¶
func (m *CommentMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*CommentMutation) FieldCleared ¶
func (m *CommentMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*CommentMutation) Fields ¶
func (m *CommentMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*CommentMutation) ID ¶
func (m *CommentMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*CommentMutation) IDs ¶
func (m *CommentMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*CommentMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*CommentMutation) OldText ¶
func (m *CommentMutation) OldText(ctx context.Context) (v string, err error)
OldText returns the old "text" field's value of the Comment entity. If the Comment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*CommentMutation) ProjectsCleared ¶
func (m *CommentMutation) ProjectsCleared() bool
ProjectsCleared reports if the "projects" edge to the Project entity was cleared.
func (*CommentMutation) ProjectsIDs ¶
func (m *CommentMutation) ProjectsIDs() (ids []int)
ProjectsIDs returns the "projects" edge IDs in the mutation.
func (*CommentMutation) RemoveEpicIDs ¶
func (m *CommentMutation) RemoveEpicIDs(ids ...int)
RemoveEpicIDs removes the "epics" edge to the Epic entity by IDs.
func (*CommentMutation) RemoveProjectIDs ¶
func (m *CommentMutation) RemoveProjectIDs(ids ...int)
RemoveProjectIDs removes the "projects" edge to the Project entity by IDs.
func (*CommentMutation) RemoveUserIDs ¶
func (m *CommentMutation) RemoveUserIDs(ids ...int)
RemoveUserIDs removes the "users" edge to the User entity by IDs.
func (*CommentMutation) RemovedEdges ¶
func (m *CommentMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*CommentMutation) RemovedEpicsIDs ¶
func (m *CommentMutation) RemovedEpicsIDs() (ids []int)
RemovedEpics returns the removed IDs of the "epics" edge to the Epic entity.
func (*CommentMutation) RemovedIDs ¶
func (m *CommentMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*CommentMutation) RemovedProjectsIDs ¶
func (m *CommentMutation) RemovedProjectsIDs() (ids []int)
RemovedProjects returns the removed IDs of the "projects" edge to the Project entity.
func (*CommentMutation) RemovedUsersIDs ¶
func (m *CommentMutation) RemovedUsersIDs() (ids []int)
RemovedUsers returns the removed IDs of the "users" edge to the User entity.
func (*CommentMutation) ResetEdge ¶
func (m *CommentMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*CommentMutation) ResetEpics ¶
func (m *CommentMutation) ResetEpics()
ResetEpics resets all changes to the "epics" edge.
func (*CommentMutation) ResetField ¶
func (m *CommentMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*CommentMutation) ResetProjects ¶
func (m *CommentMutation) ResetProjects()
ResetProjects resets all changes to the "projects" edge.
func (*CommentMutation) ResetText ¶
func (m *CommentMutation) ResetText()
ResetText resets all changes to the "text" field.
func (*CommentMutation) ResetUsers ¶
func (m *CommentMutation) ResetUsers()
ResetUsers resets all changes to the "users" edge.
func (*CommentMutation) SetField ¶
func (m *CommentMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*CommentMutation) SetOp ¶
func (m *CommentMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*CommentMutation) SetText ¶
func (m *CommentMutation) SetText(s string)
SetText sets the "text" field.
func (*CommentMutation) Text ¶
func (m *CommentMutation) Text() (r string, exists bool)
Text returns the value of the "text" field in the mutation.
func (CommentMutation) Tx ¶
func (m CommentMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*CommentMutation) Type ¶
func (m *CommentMutation) Type() string
Type returns the node type of this mutation (Comment).
func (*CommentMutation) UsersCleared ¶
func (m *CommentMutation) UsersCleared() bool
UsersCleared reports if the "users" edge to the User entity was cleared.
func (*CommentMutation) UsersIDs ¶
func (m *CommentMutation) UsersIDs() (ids []int)
UsersIDs returns the "users" edge IDs in the mutation.
func (*CommentMutation) Where ¶
func (m *CommentMutation) Where(ps ...predicate.Comment)
Where appends a list predicates to the CommentMutation builder.
func (*CommentMutation) WhereP ¶
func (m *CommentMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the CommentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type CommentOrder ¶
type CommentOrder struct { Direction OrderDirection `json:"direction"` Field *CommentOrderField `json:"field"` }
CommentOrder defines the ordering of Comment.
type CommentOrderField ¶
type CommentOrderField struct {
// contains filtered or unexported fields
}
CommentOrderField defines the ordering field of Comment.
type CommentPaginateOption ¶
type CommentPaginateOption func(*commentPager) error
CommentPaginateOption enables pagination customization.
func WithCommentFilter ¶
func WithCommentFilter(filter func(*CommentQuery) (*CommentQuery, error)) CommentPaginateOption
WithCommentFilter configures pagination filter.
func WithCommentOrder ¶
func WithCommentOrder(order *CommentOrder) CommentPaginateOption
WithCommentOrder configures pagination ordering.
type CommentQuery ¶
type CommentQuery struct {
// contains filtered or unexported fields
}
CommentQuery is the builder for querying Comment entities.
func (*CommentQuery) Aggregate ¶
func (cq *CommentQuery) Aggregate(fns ...AggregateFunc) *CommentSelect
Aggregate returns a CommentSelect configured with the given aggregations.
func (*CommentQuery) All ¶
func (cq *CommentQuery) All(ctx context.Context) ([]*Comment, error)
All executes the query and returns a list of Comments.
func (*CommentQuery) AllX ¶
func (cq *CommentQuery) AllX(ctx context.Context) []*Comment
AllX is like All, but panics if an error occurs.
func (*CommentQuery) Clone ¶
func (cq *CommentQuery) Clone() *CommentQuery
Clone returns a duplicate of the CommentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*CommentQuery) CollectFields ¶
func (c *CommentQuery) CollectFields(ctx context.Context, satisfies ...string) (*CommentQuery, error)
CollectFields tells the query-builder to eagerly load connected nodes by resolver context.
func (*CommentQuery) Count ¶
func (cq *CommentQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*CommentQuery) CountX ¶
func (cq *CommentQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*CommentQuery) Exist ¶
func (cq *CommentQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*CommentQuery) ExistX ¶
func (cq *CommentQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*CommentQuery) First ¶
func (cq *CommentQuery) First(ctx context.Context) (*Comment, error)
First returns the first Comment entity from the query. Returns a *NotFoundError when no Comment was found.
func (*CommentQuery) FirstID ¶
func (cq *CommentQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Comment ID from the query. Returns a *NotFoundError when no Comment ID was found.
func (*CommentQuery) FirstIDX ¶
func (cq *CommentQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*CommentQuery) FirstX ¶
func (cq *CommentQuery) FirstX(ctx context.Context) *Comment
FirstX is like First, but panics if an error occurs.
func (*CommentQuery) GroupBy ¶
func (cq *CommentQuery) GroupBy(field string, fields ...string) *CommentGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Text string `json:"text,omitempty"` Count int `json:"count,omitempty"` } client.Comment.Query(). GroupBy(comment.FieldText). Aggregate(ent.Count()). Scan(ctx, &v)
func (*CommentQuery) IDs ¶
func (cq *CommentQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of Comment IDs.
func (*CommentQuery) IDsX ¶
func (cq *CommentQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*CommentQuery) Limit ¶
func (cq *CommentQuery) Limit(limit int) *CommentQuery
Limit the number of records to be returned by this query.
func (*CommentQuery) Offset ¶
func (cq *CommentQuery) Offset(offset int) *CommentQuery
Offset to start from.
func (*CommentQuery) Only ¶
func (cq *CommentQuery) Only(ctx context.Context) (*Comment, error)
Only returns a single Comment entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Comment entity is found. Returns a *NotFoundError when no Comment entities are found.
func (*CommentQuery) OnlyID ¶
func (cq *CommentQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Comment ID in the query. Returns a *NotSingularError when more than one Comment ID is found. Returns a *NotFoundError when no entities are found.
func (*CommentQuery) OnlyIDX ¶
func (cq *CommentQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*CommentQuery) OnlyX ¶
func (cq *CommentQuery) OnlyX(ctx context.Context) *Comment
OnlyX is like Only, but panics if an error occurs.
func (*CommentQuery) Order ¶
func (cq *CommentQuery) Order(o ...OrderFunc) *CommentQuery
Order specifies how the records should be ordered.
func (*CommentQuery) Paginate ¶
func (c *CommentQuery) Paginate( ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, opts ...CommentPaginateOption, ) (*CommentConnection, error)
Paginate executes the query and returns a relay based cursor connection to Comment.
func (*CommentQuery) QueryEpics ¶
func (cq *CommentQuery) QueryEpics() *EpicQuery
QueryEpics chains the current query on the "epics" edge.
func (*CommentQuery) QueryProjects ¶
func (cq *CommentQuery) QueryProjects() *ProjectQuery
QueryProjects chains the current query on the "projects" edge.
func (*CommentQuery) QueryUsers ¶
func (cq *CommentQuery) QueryUsers() *UserQuery
QueryUsers chains the current query on the "users" edge.
func (*CommentQuery) Select ¶
func (cq *CommentQuery) Select(fields ...string) *CommentSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Text string `json:"text,omitempty"` } client.Comment.Query(). Select(comment.FieldText). Scan(ctx, &v)
func (*CommentQuery) Unique ¶
func (cq *CommentQuery) Unique(unique bool) *CommentQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*CommentQuery) Where ¶
func (cq *CommentQuery) Where(ps ...predicate.Comment) *CommentQuery
Where adds a new predicate for the CommentQuery builder.
func (*CommentQuery) WithEpics ¶
func (cq *CommentQuery) WithEpics(opts ...func(*EpicQuery)) *CommentQuery
WithEpics tells the query-builder to eager-load the nodes that are connected to the "epics" edge. The optional arguments are used to configure the query builder of the edge.
func (*CommentQuery) WithNamedEpics ¶
func (cq *CommentQuery) WithNamedEpics(name string, opts ...func(*EpicQuery)) *CommentQuery
WithNamedEpics tells the query-builder to eager-load the nodes that are connected to the "epics" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*CommentQuery) WithNamedProjects ¶
func (cq *CommentQuery) WithNamedProjects(name string, opts ...func(*ProjectQuery)) *CommentQuery
WithNamedProjects tells the query-builder to eager-load the nodes that are connected to the "projects" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*CommentQuery) WithNamedUsers ¶
func (cq *CommentQuery) WithNamedUsers(name string, opts ...func(*UserQuery)) *CommentQuery
WithNamedUsers tells the query-builder to eager-load the nodes that are connected to the "users" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*CommentQuery) WithProjects ¶
func (cq *CommentQuery) WithProjects(opts ...func(*ProjectQuery)) *CommentQuery
WithProjects tells the query-builder to eager-load the nodes that are connected to the "projects" edge. The optional arguments are used to configure the query builder of the edge.
func (*CommentQuery) WithUsers ¶
func (cq *CommentQuery) WithUsers(opts ...func(*UserQuery)) *CommentQuery
WithUsers tells the query-builder to eager-load the nodes that are connected to the "users" edge. The optional arguments are used to configure the query builder of the edge.
type CommentSelect ¶
type CommentSelect struct { *CommentQuery // contains filtered or unexported fields }
CommentSelect is the builder for selecting fields of Comment entities.
func (*CommentSelect) Aggregate ¶
func (cs *CommentSelect) Aggregate(fns ...AggregateFunc) *CommentSelect
Aggregate adds the given aggregation functions to the selector query.
func (*CommentSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*CommentSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*CommentSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*CommentSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*CommentSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*CommentSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*CommentSelect) Scan ¶
func (cs *CommentSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*CommentSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type CommentUpdate ¶
type CommentUpdate struct {
// contains filtered or unexported fields
}
CommentUpdate is the builder for updating Comment entities.
func (*CommentUpdate) AddEpicIDs ¶
func (cu *CommentUpdate) AddEpicIDs(ids ...int) *CommentUpdate
AddEpicIDs adds the "epics" edge to the Epic entity by IDs.
func (*CommentUpdate) AddEpics ¶
func (cu *CommentUpdate) AddEpics(e ...*Epic) *CommentUpdate
AddEpics adds the "epics" edges to the Epic entity.
func (*CommentUpdate) AddProjectIDs ¶
func (cu *CommentUpdate) AddProjectIDs(ids ...int) *CommentUpdate
AddProjectIDs adds the "projects" edge to the Project entity by IDs.
func (*CommentUpdate) AddProjects ¶
func (cu *CommentUpdate) AddProjects(p ...*Project) *CommentUpdate
AddProjects adds the "projects" edges to the Project entity.
func (*CommentUpdate) AddUserIDs ¶
func (cu *CommentUpdate) AddUserIDs(ids ...int) *CommentUpdate
AddUserIDs adds the "users" edge to the User entity by IDs.
func (*CommentUpdate) AddUsers ¶
func (cu *CommentUpdate) AddUsers(u ...*User) *CommentUpdate
AddUsers adds the "users" edges to the User entity.
func (*CommentUpdate) ClearEpics ¶
func (cu *CommentUpdate) ClearEpics() *CommentUpdate
ClearEpics clears all "epics" edges to the Epic entity.
func (*CommentUpdate) ClearProjects ¶
func (cu *CommentUpdate) ClearProjects() *CommentUpdate
ClearProjects clears all "projects" edges to the Project entity.
func (*CommentUpdate) ClearUsers ¶
func (cu *CommentUpdate) ClearUsers() *CommentUpdate
ClearUsers clears all "users" edges to the User entity.
func (*CommentUpdate) Exec ¶
func (cu *CommentUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*CommentUpdate) ExecX ¶
func (cu *CommentUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*CommentUpdate) Mutation ¶
func (cu *CommentUpdate) Mutation() *CommentMutation
Mutation returns the CommentMutation object of the builder.
func (*CommentUpdate) RemoveEpicIDs ¶
func (cu *CommentUpdate) RemoveEpicIDs(ids ...int) *CommentUpdate
RemoveEpicIDs removes the "epics" edge to Epic entities by IDs.
func (*CommentUpdate) RemoveEpics ¶
func (cu *CommentUpdate) RemoveEpics(e ...*Epic) *CommentUpdate
RemoveEpics removes "epics" edges to Epic entities.
func (*CommentUpdate) RemoveProjectIDs ¶
func (cu *CommentUpdate) RemoveProjectIDs(ids ...int) *CommentUpdate
RemoveProjectIDs removes the "projects" edge to Project entities by IDs.
func (*CommentUpdate) RemoveProjects ¶
func (cu *CommentUpdate) RemoveProjects(p ...*Project) *CommentUpdate
RemoveProjects removes "projects" edges to Project entities.
func (*CommentUpdate) RemoveUserIDs ¶
func (cu *CommentUpdate) RemoveUserIDs(ids ...int) *CommentUpdate
RemoveUserIDs removes the "users" edge to User entities by IDs.
func (*CommentUpdate) RemoveUsers ¶
func (cu *CommentUpdate) RemoveUsers(u ...*User) *CommentUpdate
RemoveUsers removes "users" edges to User entities.
func (*CommentUpdate) Save ¶
func (cu *CommentUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*CommentUpdate) SaveX ¶
func (cu *CommentUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*CommentUpdate) SetInput ¶
func (c *CommentUpdate) SetInput(i UpdateCommentInput) *CommentUpdate
SetInput applies the change-set in the UpdateCommentInput on the CommentUpdate builder.
func (*CommentUpdate) SetText ¶
func (cu *CommentUpdate) SetText(s string) *CommentUpdate
SetText sets the "text" field.
func (*CommentUpdate) Where ¶
func (cu *CommentUpdate) Where(ps ...predicate.Comment) *CommentUpdate
Where appends a list predicates to the CommentUpdate builder.
type CommentUpdateOne ¶
type CommentUpdateOne struct {
// contains filtered or unexported fields
}
CommentUpdateOne is the builder for updating a single Comment entity.
func (*CommentUpdateOne) AddEpicIDs ¶
func (cuo *CommentUpdateOne) AddEpicIDs(ids ...int) *CommentUpdateOne
AddEpicIDs adds the "epics" edge to the Epic entity by IDs.
func (*CommentUpdateOne) AddEpics ¶
func (cuo *CommentUpdateOne) AddEpics(e ...*Epic) *CommentUpdateOne
AddEpics adds the "epics" edges to the Epic entity.
func (*CommentUpdateOne) AddProjectIDs ¶
func (cuo *CommentUpdateOne) AddProjectIDs(ids ...int) *CommentUpdateOne
AddProjectIDs adds the "projects" edge to the Project entity by IDs.
func (*CommentUpdateOne) AddProjects ¶
func (cuo *CommentUpdateOne) AddProjects(p ...*Project) *CommentUpdateOne
AddProjects adds the "projects" edges to the Project entity.
func (*CommentUpdateOne) AddUserIDs ¶
func (cuo *CommentUpdateOne) AddUserIDs(ids ...int) *CommentUpdateOne
AddUserIDs adds the "users" edge to the User entity by IDs.
func (*CommentUpdateOne) AddUsers ¶
func (cuo *CommentUpdateOne) AddUsers(u ...*User) *CommentUpdateOne
AddUsers adds the "users" edges to the User entity.
func (*CommentUpdateOne) ClearEpics ¶
func (cuo *CommentUpdateOne) ClearEpics() *CommentUpdateOne
ClearEpics clears all "epics" edges to the Epic entity.
func (*CommentUpdateOne) ClearProjects ¶
func (cuo *CommentUpdateOne) ClearProjects() *CommentUpdateOne
ClearProjects clears all "projects" edges to the Project entity.
func (*CommentUpdateOne) ClearUsers ¶
func (cuo *CommentUpdateOne) ClearUsers() *CommentUpdateOne
ClearUsers clears all "users" edges to the User entity.
func (*CommentUpdateOne) Exec ¶
func (cuo *CommentUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*CommentUpdateOne) ExecX ¶
func (cuo *CommentUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*CommentUpdateOne) Mutation ¶
func (cuo *CommentUpdateOne) Mutation() *CommentMutation
Mutation returns the CommentMutation object of the builder.
func (*CommentUpdateOne) RemoveEpicIDs ¶
func (cuo *CommentUpdateOne) RemoveEpicIDs(ids ...int) *CommentUpdateOne
RemoveEpicIDs removes the "epics" edge to Epic entities by IDs.
func (*CommentUpdateOne) RemoveEpics ¶
func (cuo *CommentUpdateOne) RemoveEpics(e ...*Epic) *CommentUpdateOne
RemoveEpics removes "epics" edges to Epic entities.
func (*CommentUpdateOne) RemoveProjectIDs ¶
func (cuo *CommentUpdateOne) RemoveProjectIDs(ids ...int) *CommentUpdateOne
RemoveProjectIDs removes the "projects" edge to Project entities by IDs.
func (*CommentUpdateOne) RemoveProjects ¶
func (cuo *CommentUpdateOne) RemoveProjects(p ...*Project) *CommentUpdateOne
RemoveProjects removes "projects" edges to Project entities.
func (*CommentUpdateOne) RemoveUserIDs ¶
func (cuo *CommentUpdateOne) RemoveUserIDs(ids ...int) *CommentUpdateOne
RemoveUserIDs removes the "users" edge to User entities by IDs.
func (*CommentUpdateOne) RemoveUsers ¶
func (cuo *CommentUpdateOne) RemoveUsers(u ...*User) *CommentUpdateOne
RemoveUsers removes "users" edges to User entities.
func (*CommentUpdateOne) Save ¶
func (cuo *CommentUpdateOne) Save(ctx context.Context) (*Comment, error)
Save executes the query and returns the updated Comment entity.
func (*CommentUpdateOne) SaveX ¶
func (cuo *CommentUpdateOne) SaveX(ctx context.Context) *Comment
SaveX is like Save, but panics if an error occurs.
func (*CommentUpdateOne) Select ¶
func (cuo *CommentUpdateOne) Select(field string, fields ...string) *CommentUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*CommentUpdateOne) SetInput ¶
func (c *CommentUpdateOne) SetInput(i UpdateCommentInput) *CommentUpdateOne
SetInput applies the change-set in the UpdateCommentInput on the CommentUpdateOne builder.
func (*CommentUpdateOne) SetText ¶
func (cuo *CommentUpdateOne) SetText(s string) *CommentUpdateOne
SetText sets the "text" field.
type CommentWhereInput ¶
type CommentWhereInput struct { Predicates []predicate.Comment `json:"-"` Not *CommentWhereInput `json:"not,omitempty"` Or []*CommentWhereInput `json:"or,omitempty"` And []*CommentWhereInput `json:"and,omitempty"` // "id" field predicates. ID *int `json:"id,omitempty"` IDNEQ *int `json:"idNEQ,omitempty"` IDIn []int `json:"idIn,omitempty"` IDNotIn []int `json:"idNotIn,omitempty"` IDGT *int `json:"idGT,omitempty"` IDGTE *int `json:"idGTE,omitempty"` IDLT *int `json:"idLT,omitempty"` IDLTE *int `json:"idLTE,omitempty"` // "text" field predicates. Text *string `json:"text,omitempty"` TextNEQ *string `json:"textNEQ,omitempty"` TextIn []string `json:"textIn,omitempty"` TextNotIn []string `json:"textNotIn,omitempty"` TextGT *string `json:"textGT,omitempty"` TextGTE *string `json:"textGTE,omitempty"` TextLT *string `json:"textLT,omitempty"` TextLTE *string `json:"textLTE,omitempty"` TextContains *string `json:"textContains,omitempty"` TextHasPrefix *string `json:"textHasPrefix,omitempty"` TextHasSuffix *string `json:"textHasSuffix,omitempty"` TextEqualFold *string `json:"textEqualFold,omitempty"` TextContainsFold *string `json:"textContainsFold,omitempty"` // "epics" edge predicates. HasEpics *bool `json:"hasEpics,omitempty"` HasEpicsWith []*EpicWhereInput `json:"hasEpicsWith,omitempty"` // "projects" edge predicates. HasProjects *bool `json:"hasProjects,omitempty"` HasProjectsWith []*ProjectWhereInput `json:"hasProjectsWith,omitempty"` // "users" edge predicates. HasUsers *bool `json:"hasUsers,omitempty"` HasUsersWith []*UserWhereInput `json:"hasUsersWith,omitempty"` }
CommentWhereInput represents a where input for filtering Comment queries.
func (*CommentWhereInput) AddPredicates ¶
func (i *CommentWhereInput) AddPredicates(predicates ...predicate.Comment)
AddPredicates adds custom predicates to the where input to be used during the filtering phase.
func (*CommentWhereInput) Filter ¶
func (i *CommentWhereInput) Filter(q *CommentQuery) (*CommentQuery, error)
Filter applies the CommentWhereInput filter on the CommentQuery builder.
type CommitFunc ¶
The CommitFunc type is an adapter to allow the use of ordinary function as a Committer. If f is a function with the appropriate signature, CommitFunc(f) is a Committer that calls f.
type CommitHook ¶
CommitHook defines the "commit middleware". A function that gets a Committer and returns a Committer. For example:
hook := func(next ent.Committer) ent.Committer { return ent.CommitFunc(func(ctx context.Context, tx *ent.Tx) error { // Do some stuff before. if err := next.Commit(ctx, tx); err != nil { return err } // Do some stuff after. return nil }) }
type ConstraintError ¶
type ConstraintError struct {
// contains filtered or unexported fields
}
ConstraintError returns when trying to create/update one or more entities and one or more of their constraints failed. For example, violation of edge or field uniqueness.
func (ConstraintError) Error ¶
func (e ConstraintError) Error() string
Error implements the error interface.
func (*ConstraintError) Unwrap ¶
func (e *ConstraintError) Unwrap() error
Unwrap implements the errors.Wrapper interface.
type CreateCommentInput ¶
CreateCommentInput represents a mutation input for creating comments.
func (*CreateCommentInput) Mutate ¶
func (i *CreateCommentInput) Mutate(m *CommentMutation)
Mutate applies the CreateCommentInput on the CommentMutation builder.
type CreateEpicInput ¶
type CreateEpicInput struct { Name string Description string ProjectID *int ReporterID *int AssigneeID *int CommentIDs []int }
CreateEpicInput represents a mutation input for creating epics.
func (*CreateEpicInput) Mutate ¶
func (i *CreateEpicInput) Mutate(m *EpicMutation)
Mutate applies the CreateEpicInput on the EpicMutation builder.
type CreateProjectInput ¶
type CreateProjectInput struct { Name string Description *string EpicIDs []int OwnerID *int CommentIDs []int }
CreateProjectInput represents a mutation input for creating projects.
func (*CreateProjectInput) Mutate ¶
func (i *CreateProjectInput) Mutate(m *ProjectMutation)
Mutate applies the CreateProjectInput on the ProjectMutation builder.
type CreateUserInput ¶
type CreateUserInput struct { Name string Surname string Username string Email string OwnIDs []int ReporterIDs []int AssigneeIDs []int CommentIDs []int }
CreateUserInput represents a mutation input for creating users.
func (*CreateUserInput) Mutate ¶
func (i *CreateUserInput) Mutate(m *UserMutation)
Mutate applies the CreateUserInput on the UserMutation builder.
type Cursor ¶
Cursor of an edge type.
func (Cursor) MarshalGQL ¶
MarshalGQL implements graphql.Marshaler interface.
func (*Cursor) UnmarshalGQL ¶
UnmarshalGQL implements graphql.Unmarshaler interface.
type Edge ¶
type Edge struct { Type string `json:"type,omitempty"` // edge type. Name string `json:"name,omitempty"` // edge name. IDs []int `json:"ids,omitempty"` // node ids (where this edge point to). }
Edges between two nodes.
type Epic ¶
type Epic struct { // ID of the ent. ID int `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Description holds the value of the "description" field. Description string `json:"description,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the EpicQuery when eager-loading is set. Edges EpicEdges `json:"edges"` // contains filtered or unexported fields }
Epic is the model entity for the Epic schema.
func (*Epic) NamedComments ¶
NamedComments returns the Comments named value or an error if the edge was not loaded in eager-loading with this name.
func (*Epic) QueryAssignee ¶
QueryAssignee queries the "assignee" edge of the Epic entity.
func (*Epic) QueryComments ¶
func (e *Epic) QueryComments() *CommentQuery
QueryComments queries the "comments" edge of the Epic entity.
func (*Epic) QueryProject ¶
func (e *Epic) QueryProject() *ProjectQuery
QueryProject queries the "project" edge of the Epic entity.
func (*Epic) QueryReporter ¶
QueryReporter queries the "reporter" edge of the Epic entity.
func (*Epic) Unwrap ¶
Unwrap unwraps the Epic entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*Epic) Update ¶
func (e *Epic) Update() *EpicUpdateOne
Update returns a builder for updating this Epic. Note that you need to call Epic.Unwrap() before calling this method if this Epic was returned from a transaction, and the transaction was committed or rolled back.
type EpicClient ¶
type EpicClient struct {
// contains filtered or unexported fields
}
EpicClient is a client for the Epic schema.
func NewEpicClient ¶
func NewEpicClient(c config) *EpicClient
NewEpicClient returns a client for the Epic from the given config.
func (*EpicClient) Create ¶
func (c *EpicClient) Create() *EpicCreate
Create returns a builder for creating a Epic entity.
func (*EpicClient) CreateBulk ¶
func (c *EpicClient) CreateBulk(builders ...*EpicCreate) *EpicCreateBulk
CreateBulk returns a builder for creating a bulk of Epic entities.
func (*EpicClient) Delete ¶
func (c *EpicClient) Delete() *EpicDelete
Delete returns a delete builder for Epic.
func (*EpicClient) DeleteOne ¶
func (c *EpicClient) DeleteOne(e *Epic) *EpicDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*EpicClient) DeleteOneID ¶
func (c *EpicClient) DeleteOneID(id int) *EpicDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*EpicClient) GetX ¶
func (c *EpicClient) GetX(ctx context.Context, id int) *Epic
GetX is like Get, but panics if an error occurs.
func (*EpicClient) Intercept ¶
func (c *EpicClient) Intercept(interceptors ...Interceptor)
Use adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `epic.Intercept(f(g(h())))`.
func (*EpicClient) Interceptors ¶
func (c *EpicClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*EpicClient) Query ¶
func (c *EpicClient) Query() *EpicQuery
Query returns a query builder for Epic.
func (*EpicClient) QueryAssignee ¶
func (c *EpicClient) QueryAssignee(e *Epic) *UserQuery
QueryAssignee queries the assignee edge of a Epic.
func (*EpicClient) QueryComments ¶
func (c *EpicClient) QueryComments(e *Epic) *CommentQuery
QueryComments queries the comments edge of a Epic.
func (*EpicClient) QueryProject ¶
func (c *EpicClient) QueryProject(e *Epic) *ProjectQuery
QueryProject queries the project edge of a Epic.
func (*EpicClient) QueryReporter ¶
func (c *EpicClient) QueryReporter(e *Epic) *UserQuery
QueryReporter queries the reporter edge of a Epic.
func (*EpicClient) Update ¶
func (c *EpicClient) Update() *EpicUpdate
Update returns an update builder for Epic.
func (*EpicClient) UpdateOne ¶
func (c *EpicClient) UpdateOne(e *Epic) *EpicUpdateOne
UpdateOne returns an update builder for the given entity.
func (*EpicClient) UpdateOneID ¶
func (c *EpicClient) UpdateOneID(id int) *EpicUpdateOne
UpdateOneID returns an update builder for the given id.
func (*EpicClient) Use ¶
func (c *EpicClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `epic.Hooks(f(g(h())))`.
type EpicConnection ¶
type EpicConnection struct { Edges []*EpicEdge `json:"edges"` PageInfo PageInfo `json:"pageInfo"` TotalCount int `json:"totalCount"` }
EpicConnection is the connection containing edges to Epic.
type EpicCreate ¶
type EpicCreate struct {
// contains filtered or unexported fields
}
EpicCreate is the builder for creating a Epic entity.
func (*EpicCreate) AddCommentIDs ¶
func (ec *EpicCreate) AddCommentIDs(ids ...int) *EpicCreate
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*EpicCreate) AddComments ¶
func (ec *EpicCreate) AddComments(c ...*Comment) *EpicCreate
AddComments adds the "comments" edges to the Comment entity.
func (*EpicCreate) Exec ¶
func (ec *EpicCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*EpicCreate) ExecX ¶
func (ec *EpicCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EpicCreate) Mutation ¶
func (ec *EpicCreate) Mutation() *EpicMutation
Mutation returns the EpicMutation object of the builder.
func (*EpicCreate) Save ¶
func (ec *EpicCreate) Save(ctx context.Context) (*Epic, error)
Save creates the Epic in the database.
func (*EpicCreate) SaveX ¶
func (ec *EpicCreate) SaveX(ctx context.Context) *Epic
SaveX calls Save and panics if Save returns an error.
func (*EpicCreate) SetAssignee ¶
func (ec *EpicCreate) SetAssignee(u *User) *EpicCreate
SetAssignee sets the "assignee" edge to the User entity.
func (*EpicCreate) SetAssigneeID ¶
func (ec *EpicCreate) SetAssigneeID(id int) *EpicCreate
SetAssigneeID sets the "assignee" edge to the User entity by ID.
func (*EpicCreate) SetDescription ¶
func (ec *EpicCreate) SetDescription(s string) *EpicCreate
SetDescription sets the "description" field.
func (*EpicCreate) SetInput ¶
func (c *EpicCreate) SetInput(i CreateEpicInput) *EpicCreate
SetInput applies the change-set in the CreateEpicInput on the EpicCreate builder.
func (*EpicCreate) SetName ¶
func (ec *EpicCreate) SetName(s string) *EpicCreate
SetName sets the "name" field.
func (*EpicCreate) SetNillableAssigneeID ¶
func (ec *EpicCreate) SetNillableAssigneeID(id *int) *EpicCreate
SetNillableAssigneeID sets the "assignee" edge to the User entity by ID if the given value is not nil.
func (*EpicCreate) SetNillableProjectID ¶
func (ec *EpicCreate) SetNillableProjectID(id *int) *EpicCreate
SetNillableProjectID sets the "project" edge to the Project entity by ID if the given value is not nil.
func (*EpicCreate) SetNillableReporterID ¶
func (ec *EpicCreate) SetNillableReporterID(id *int) *EpicCreate
SetNillableReporterID sets the "reporter" edge to the User entity by ID if the given value is not nil.
func (*EpicCreate) SetProject ¶
func (ec *EpicCreate) SetProject(p *Project) *EpicCreate
SetProject sets the "project" edge to the Project entity.
func (*EpicCreate) SetProjectID ¶
func (ec *EpicCreate) SetProjectID(id int) *EpicCreate
SetProjectID sets the "project" edge to the Project entity by ID.
func (*EpicCreate) SetReporter ¶
func (ec *EpicCreate) SetReporter(u *User) *EpicCreate
SetReporter sets the "reporter" edge to the User entity.
func (*EpicCreate) SetReporterID ¶
func (ec *EpicCreate) SetReporterID(id int) *EpicCreate
SetReporterID sets the "reporter" edge to the User entity by ID.
type EpicCreateBulk ¶
type EpicCreateBulk struct {
// contains filtered or unexported fields
}
EpicCreateBulk is the builder for creating many Epic entities in bulk.
func (*EpicCreateBulk) Exec ¶
func (ecb *EpicCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*EpicCreateBulk) ExecX ¶
func (ecb *EpicCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type EpicDelete ¶
type EpicDelete struct {
// contains filtered or unexported fields
}
EpicDelete is the builder for deleting a Epic entity.
func (*EpicDelete) Exec ¶
func (ed *EpicDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*EpicDelete) ExecX ¶
func (ed *EpicDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*EpicDelete) Where ¶
func (ed *EpicDelete) Where(ps ...predicate.Epic) *EpicDelete
Where appends a list predicates to the EpicDelete builder.
type EpicDeleteOne ¶
type EpicDeleteOne struct {
// contains filtered or unexported fields
}
EpicDeleteOne is the builder for deleting a single Epic entity.
func (*EpicDeleteOne) Exec ¶
func (edo *EpicDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*EpicDeleteOne) ExecX ¶
func (edo *EpicDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type EpicEdges ¶
type EpicEdges struct { // Project holds the value of the project edge. Project *Project `json:"project,omitempty"` // Reporter holds the value of the reporter edge. Reporter *User `json:"reporter,omitempty"` // Assignee holds the value of the assignee edge. Assignee *User `json:"assignee,omitempty"` // Comments holds the value of the comments edge. Comments []*Comment `json:"comments,omitempty"` // contains filtered or unexported fields }
EpicEdges holds the relations/edges for other nodes in the graph.
func (EpicEdges) AssigneeOrErr ¶
AssigneeOrErr returns the Assignee value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (EpicEdges) CommentsOrErr ¶
CommentsOrErr returns the Comments value or an error if the edge was not loaded in eager-loading.
func (EpicEdges) ProjectOrErr ¶
ProjectOrErr returns the Project value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (EpicEdges) ReporterOrErr ¶
ReporterOrErr returns the Reporter value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type EpicGroupBy ¶
type EpicGroupBy struct {
// contains filtered or unexported fields
}
EpicGroupBy is the group-by builder for Epic entities.
func (*EpicGroupBy) Aggregate ¶
func (egb *EpicGroupBy) Aggregate(fns ...AggregateFunc) *EpicGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*EpicGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*EpicGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*EpicGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*EpicGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*EpicGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*EpicGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*EpicGroupBy) Scan ¶
func (egb *EpicGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*EpicGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type EpicMutation ¶
type EpicMutation struct {
// contains filtered or unexported fields
}
EpicMutation represents an operation that mutates the Epic nodes in the graph.
func (*EpicMutation) AddCommentIDs ¶
func (m *EpicMutation) AddCommentIDs(ids ...int)
AddCommentIDs adds the "comments" edge to the Comment entity by ids.
func (*EpicMutation) AddField ¶
func (m *EpicMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*EpicMutation) AddedEdges ¶
func (m *EpicMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*EpicMutation) AddedField ¶
func (m *EpicMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*EpicMutation) AddedFields ¶
func (m *EpicMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*EpicMutation) AddedIDs ¶
func (m *EpicMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*EpicMutation) AssigneeCleared ¶
func (m *EpicMutation) AssigneeCleared() bool
AssigneeCleared reports if the "assignee" edge to the User entity was cleared.
func (*EpicMutation) AssigneeID ¶
func (m *EpicMutation) AssigneeID() (id int, exists bool)
AssigneeID returns the "assignee" edge ID in the mutation.
func (*EpicMutation) AssigneeIDs ¶
func (m *EpicMutation) AssigneeIDs() (ids []int)
AssigneeIDs returns the "assignee" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AssigneeID instead. It exists only for internal usage by the builders.
func (*EpicMutation) ClearAssignee ¶
func (m *EpicMutation) ClearAssignee()
ClearAssignee clears the "assignee" edge to the User entity.
func (*EpicMutation) ClearComments ¶
func (m *EpicMutation) ClearComments()
ClearComments clears the "comments" edge to the Comment entity.
func (*EpicMutation) ClearEdge ¶
func (m *EpicMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*EpicMutation) ClearField ¶
func (m *EpicMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*EpicMutation) ClearProject ¶
func (m *EpicMutation) ClearProject()
ClearProject clears the "project" edge to the Project entity.
func (*EpicMutation) ClearReporter ¶
func (m *EpicMutation) ClearReporter()
ClearReporter clears the "reporter" edge to the User entity.
func (*EpicMutation) ClearedEdges ¶
func (m *EpicMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*EpicMutation) ClearedFields ¶
func (m *EpicMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (EpicMutation) Client ¶
func (m EpicMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*EpicMutation) CommentsCleared ¶
func (m *EpicMutation) CommentsCleared() bool
CommentsCleared reports if the "comments" edge to the Comment entity was cleared.
func (*EpicMutation) CommentsIDs ¶
func (m *EpicMutation) CommentsIDs() (ids []int)
CommentsIDs returns the "comments" edge IDs in the mutation.
func (*EpicMutation) Description ¶
func (m *EpicMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*EpicMutation) EdgeCleared ¶
func (m *EpicMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*EpicMutation) Field ¶
func (m *EpicMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*EpicMutation) FieldCleared ¶
func (m *EpicMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*EpicMutation) Fields ¶
func (m *EpicMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*EpicMutation) ID ¶
func (m *EpicMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*EpicMutation) IDs ¶
func (m *EpicMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*EpicMutation) Name ¶
func (m *EpicMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*EpicMutation) OldDescription ¶
func (m *EpicMutation) OldDescription(ctx context.Context) (v string, err error)
OldDescription returns the old "description" field's value of the Epic entity. If the Epic object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*EpicMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*EpicMutation) OldName ¶
func (m *EpicMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Epic entity. If the Epic object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*EpicMutation) ProjectCleared ¶
func (m *EpicMutation) ProjectCleared() bool
ProjectCleared reports if the "project" edge to the Project entity was cleared.
func (*EpicMutation) ProjectID ¶
func (m *EpicMutation) ProjectID() (id int, exists bool)
ProjectID returns the "project" edge ID in the mutation.
func (*EpicMutation) ProjectIDs ¶
func (m *EpicMutation) ProjectIDs() (ids []int)
ProjectIDs returns the "project" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ProjectID instead. It exists only for internal usage by the builders.
func (*EpicMutation) RemoveCommentIDs ¶
func (m *EpicMutation) RemoveCommentIDs(ids ...int)
RemoveCommentIDs removes the "comments" edge to the Comment entity by IDs.
func (*EpicMutation) RemovedCommentsIDs ¶
func (m *EpicMutation) RemovedCommentsIDs() (ids []int)
RemovedComments returns the removed IDs of the "comments" edge to the Comment entity.
func (*EpicMutation) RemovedEdges ¶
func (m *EpicMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*EpicMutation) RemovedIDs ¶
func (m *EpicMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*EpicMutation) ReporterCleared ¶
func (m *EpicMutation) ReporterCleared() bool
ReporterCleared reports if the "reporter" edge to the User entity was cleared.
func (*EpicMutation) ReporterID ¶
func (m *EpicMutation) ReporterID() (id int, exists bool)
ReporterID returns the "reporter" edge ID in the mutation.
func (*EpicMutation) ReporterIDs ¶
func (m *EpicMutation) ReporterIDs() (ids []int)
ReporterIDs returns the "reporter" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ReporterID instead. It exists only for internal usage by the builders.
func (*EpicMutation) ResetAssignee ¶
func (m *EpicMutation) ResetAssignee()
ResetAssignee resets all changes to the "assignee" edge.
func (*EpicMutation) ResetComments ¶
func (m *EpicMutation) ResetComments()
ResetComments resets all changes to the "comments" edge.
func (*EpicMutation) ResetDescription ¶
func (m *EpicMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*EpicMutation) ResetEdge ¶
func (m *EpicMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*EpicMutation) ResetField ¶
func (m *EpicMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*EpicMutation) ResetName ¶
func (m *EpicMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*EpicMutation) ResetProject ¶
func (m *EpicMutation) ResetProject()
ResetProject resets all changes to the "project" edge.
func (*EpicMutation) ResetReporter ¶
func (m *EpicMutation) ResetReporter()
ResetReporter resets all changes to the "reporter" edge.
func (*EpicMutation) SetAssigneeID ¶
func (m *EpicMutation) SetAssigneeID(id int)
SetAssigneeID sets the "assignee" edge to the User entity by id.
func (*EpicMutation) SetDescription ¶
func (m *EpicMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*EpicMutation) SetField ¶
func (m *EpicMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*EpicMutation) SetName ¶
func (m *EpicMutation) SetName(s string)
SetName sets the "name" field.
func (*EpicMutation) SetOp ¶
func (m *EpicMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*EpicMutation) SetProjectID ¶
func (m *EpicMutation) SetProjectID(id int)
SetProjectID sets the "project" edge to the Project entity by id.
func (*EpicMutation) SetReporterID ¶
func (m *EpicMutation) SetReporterID(id int)
SetReporterID sets the "reporter" edge to the User entity by id.
func (EpicMutation) Tx ¶
func (m EpicMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*EpicMutation) Type ¶
func (m *EpicMutation) Type() string
Type returns the node type of this mutation (Epic).
func (*EpicMutation) Where ¶
func (m *EpicMutation) Where(ps ...predicate.Epic)
Where appends a list predicates to the EpicMutation builder.
func (*EpicMutation) WhereP ¶
func (m *EpicMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the EpicMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type EpicOrder ¶
type EpicOrder struct { Direction OrderDirection `json:"direction"` Field *EpicOrderField `json:"field"` }
EpicOrder defines the ordering of Epic.
type EpicOrderField ¶
type EpicOrderField struct {
// contains filtered or unexported fields
}
EpicOrderField defines the ordering field of Epic.
type EpicPaginateOption ¶
type EpicPaginateOption func(*epicPager) error
EpicPaginateOption enables pagination customization.
func WithEpicFilter ¶
func WithEpicFilter(filter func(*EpicQuery) (*EpicQuery, error)) EpicPaginateOption
WithEpicFilter configures pagination filter.
func WithEpicOrder ¶
func WithEpicOrder(order *EpicOrder) EpicPaginateOption
WithEpicOrder configures pagination ordering.
type EpicQuery ¶
type EpicQuery struct {
// contains filtered or unexported fields
}
EpicQuery is the builder for querying Epic entities.
func (*EpicQuery) Aggregate ¶
func (eq *EpicQuery) Aggregate(fns ...AggregateFunc) *EpicSelect
Aggregate returns a EpicSelect configured with the given aggregations.
func (*EpicQuery) Clone ¶
Clone returns a duplicate of the EpicQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*EpicQuery) CollectFields ¶
CollectFields tells the query-builder to eagerly load connected nodes by resolver context.
func (*EpicQuery) First ¶
First returns the first Epic entity from the query. Returns a *NotFoundError when no Epic was found.
func (*EpicQuery) FirstID ¶
FirstID returns the first Epic ID from the query. Returns a *NotFoundError when no Epic ID was found.
func (*EpicQuery) GroupBy ¶
func (eq *EpicQuery) GroupBy(field string, fields ...string) *EpicGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Name string `json:"name,omitempty"` Count int `json:"count,omitempty"` } client.Epic.Query(). GroupBy(epic.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*EpicQuery) Only ¶
Only returns a single Epic entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Epic entity is found. Returns a *NotFoundError when no Epic entities are found.
func (*EpicQuery) OnlyID ¶
OnlyID is like Only, but returns the only Epic ID in the query. Returns a *NotSingularError when more than one Epic ID is found. Returns a *NotFoundError when no entities are found.
func (*EpicQuery) Paginate ¶
func (e *EpicQuery) Paginate( ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, opts ...EpicPaginateOption, ) (*EpicConnection, error)
Paginate executes the query and returns a relay based cursor connection to Epic.
func (*EpicQuery) QueryAssignee ¶
QueryAssignee chains the current query on the "assignee" edge.
func (*EpicQuery) QueryComments ¶
func (eq *EpicQuery) QueryComments() *CommentQuery
QueryComments chains the current query on the "comments" edge.
func (*EpicQuery) QueryProject ¶
func (eq *EpicQuery) QueryProject() *ProjectQuery
QueryProject chains the current query on the "project" edge.
func (*EpicQuery) QueryReporter ¶
QueryReporter chains the current query on the "reporter" edge.
func (*EpicQuery) Select ¶
func (eq *EpicQuery) Select(fields ...string) *EpicSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.Epic.Query(). Select(epic.FieldName). Scan(ctx, &v)
func (*EpicQuery) Unique ¶
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*EpicQuery) WithAssignee ¶
WithAssignee tells the query-builder to eager-load the nodes that are connected to the "assignee" edge. The optional arguments are used to configure the query builder of the edge.
func (*EpicQuery) WithComments ¶
func (eq *EpicQuery) WithComments(opts ...func(*CommentQuery)) *EpicQuery
WithComments tells the query-builder to eager-load the nodes that are connected to the "comments" edge. The optional arguments are used to configure the query builder of the edge.
func (*EpicQuery) WithNamedComments ¶
func (eq *EpicQuery) WithNamedComments(name string, opts ...func(*CommentQuery)) *EpicQuery
WithNamedComments tells the query-builder to eager-load the nodes that are connected to the "comments" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*EpicQuery) WithProject ¶
func (eq *EpicQuery) WithProject(opts ...func(*ProjectQuery)) *EpicQuery
WithProject tells the query-builder to eager-load the nodes that are connected to the "project" edge. The optional arguments are used to configure the query builder of the edge.
func (*EpicQuery) WithReporter ¶
WithReporter tells the query-builder to eager-load the nodes that are connected to the "reporter" edge. The optional arguments are used to configure the query builder of the edge.
type EpicSelect ¶
type EpicSelect struct { *EpicQuery // contains filtered or unexported fields }
EpicSelect is the builder for selecting fields of Epic entities.
func (*EpicSelect) Aggregate ¶
func (es *EpicSelect) Aggregate(fns ...AggregateFunc) *EpicSelect
Aggregate adds the given aggregation functions to the selector query.
func (*EpicSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*EpicSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*EpicSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*EpicSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*EpicSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*EpicSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*EpicSelect) Scan ¶
func (es *EpicSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*EpicSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type EpicUpdate ¶
type EpicUpdate struct {
// contains filtered or unexported fields
}
EpicUpdate is the builder for updating Epic entities.
func (*EpicUpdate) AddCommentIDs ¶
func (eu *EpicUpdate) AddCommentIDs(ids ...int) *EpicUpdate
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*EpicUpdate) AddComments ¶
func (eu *EpicUpdate) AddComments(c ...*Comment) *EpicUpdate
AddComments adds the "comments" edges to the Comment entity.
func (*EpicUpdate) ClearAssignee ¶
func (eu *EpicUpdate) ClearAssignee() *EpicUpdate
ClearAssignee clears the "assignee" edge to the User entity.
func (*EpicUpdate) ClearComments ¶
func (eu *EpicUpdate) ClearComments() *EpicUpdate
ClearComments clears all "comments" edges to the Comment entity.
func (*EpicUpdate) ClearProject ¶
func (eu *EpicUpdate) ClearProject() *EpicUpdate
ClearProject clears the "project" edge to the Project entity.
func (*EpicUpdate) ClearReporter ¶
func (eu *EpicUpdate) ClearReporter() *EpicUpdate
ClearReporter clears the "reporter" edge to the User entity.
func (*EpicUpdate) Exec ¶
func (eu *EpicUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*EpicUpdate) ExecX ¶
func (eu *EpicUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EpicUpdate) Mutation ¶
func (eu *EpicUpdate) Mutation() *EpicMutation
Mutation returns the EpicMutation object of the builder.
func (*EpicUpdate) RemoveCommentIDs ¶
func (eu *EpicUpdate) RemoveCommentIDs(ids ...int) *EpicUpdate
RemoveCommentIDs removes the "comments" edge to Comment entities by IDs.
func (*EpicUpdate) RemoveComments ¶
func (eu *EpicUpdate) RemoveComments(c ...*Comment) *EpicUpdate
RemoveComments removes "comments" edges to Comment entities.
func (*EpicUpdate) Save ¶
func (eu *EpicUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*EpicUpdate) SaveX ¶
func (eu *EpicUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*EpicUpdate) SetAssignee ¶
func (eu *EpicUpdate) SetAssignee(u *User) *EpicUpdate
SetAssignee sets the "assignee" edge to the User entity.
func (*EpicUpdate) SetAssigneeID ¶
func (eu *EpicUpdate) SetAssigneeID(id int) *EpicUpdate
SetAssigneeID sets the "assignee" edge to the User entity by ID.
func (*EpicUpdate) SetDescription ¶
func (eu *EpicUpdate) SetDescription(s string) *EpicUpdate
SetDescription sets the "description" field.
func (*EpicUpdate) SetInput ¶
func (c *EpicUpdate) SetInput(i UpdateEpicInput) *EpicUpdate
SetInput applies the change-set in the UpdateEpicInput on the EpicUpdate builder.
func (*EpicUpdate) SetName ¶
func (eu *EpicUpdate) SetName(s string) *EpicUpdate
SetName sets the "name" field.
func (*EpicUpdate) SetNillableAssigneeID ¶
func (eu *EpicUpdate) SetNillableAssigneeID(id *int) *EpicUpdate
SetNillableAssigneeID sets the "assignee" edge to the User entity by ID if the given value is not nil.
func (*EpicUpdate) SetNillableProjectID ¶
func (eu *EpicUpdate) SetNillableProjectID(id *int) *EpicUpdate
SetNillableProjectID sets the "project" edge to the Project entity by ID if the given value is not nil.
func (*EpicUpdate) SetNillableReporterID ¶
func (eu *EpicUpdate) SetNillableReporterID(id *int) *EpicUpdate
SetNillableReporterID sets the "reporter" edge to the User entity by ID if the given value is not nil.
func (*EpicUpdate) SetProject ¶
func (eu *EpicUpdate) SetProject(p *Project) *EpicUpdate
SetProject sets the "project" edge to the Project entity.
func (*EpicUpdate) SetProjectID ¶
func (eu *EpicUpdate) SetProjectID(id int) *EpicUpdate
SetProjectID sets the "project" edge to the Project entity by ID.
func (*EpicUpdate) SetReporter ¶
func (eu *EpicUpdate) SetReporter(u *User) *EpicUpdate
SetReporter sets the "reporter" edge to the User entity.
func (*EpicUpdate) SetReporterID ¶
func (eu *EpicUpdate) SetReporterID(id int) *EpicUpdate
SetReporterID sets the "reporter" edge to the User entity by ID.
func (*EpicUpdate) Where ¶
func (eu *EpicUpdate) Where(ps ...predicate.Epic) *EpicUpdate
Where appends a list predicates to the EpicUpdate builder.
type EpicUpdateOne ¶
type EpicUpdateOne struct {
// contains filtered or unexported fields
}
EpicUpdateOne is the builder for updating a single Epic entity.
func (*EpicUpdateOne) AddCommentIDs ¶
func (euo *EpicUpdateOne) AddCommentIDs(ids ...int) *EpicUpdateOne
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*EpicUpdateOne) AddComments ¶
func (euo *EpicUpdateOne) AddComments(c ...*Comment) *EpicUpdateOne
AddComments adds the "comments" edges to the Comment entity.
func (*EpicUpdateOne) ClearAssignee ¶
func (euo *EpicUpdateOne) ClearAssignee() *EpicUpdateOne
ClearAssignee clears the "assignee" edge to the User entity.
func (*EpicUpdateOne) ClearComments ¶
func (euo *EpicUpdateOne) ClearComments() *EpicUpdateOne
ClearComments clears all "comments" edges to the Comment entity.
func (*EpicUpdateOne) ClearProject ¶
func (euo *EpicUpdateOne) ClearProject() *EpicUpdateOne
ClearProject clears the "project" edge to the Project entity.
func (*EpicUpdateOne) ClearReporter ¶
func (euo *EpicUpdateOne) ClearReporter() *EpicUpdateOne
ClearReporter clears the "reporter" edge to the User entity.
func (*EpicUpdateOne) Exec ¶
func (euo *EpicUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*EpicUpdateOne) ExecX ¶
func (euo *EpicUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EpicUpdateOne) Mutation ¶
func (euo *EpicUpdateOne) Mutation() *EpicMutation
Mutation returns the EpicMutation object of the builder.
func (*EpicUpdateOne) RemoveCommentIDs ¶
func (euo *EpicUpdateOne) RemoveCommentIDs(ids ...int) *EpicUpdateOne
RemoveCommentIDs removes the "comments" edge to Comment entities by IDs.
func (*EpicUpdateOne) RemoveComments ¶
func (euo *EpicUpdateOne) RemoveComments(c ...*Comment) *EpicUpdateOne
RemoveComments removes "comments" edges to Comment entities.
func (*EpicUpdateOne) Save ¶
func (euo *EpicUpdateOne) Save(ctx context.Context) (*Epic, error)
Save executes the query and returns the updated Epic entity.
func (*EpicUpdateOne) SaveX ¶
func (euo *EpicUpdateOne) SaveX(ctx context.Context) *Epic
SaveX is like Save, but panics if an error occurs.
func (*EpicUpdateOne) Select ¶
func (euo *EpicUpdateOne) Select(field string, fields ...string) *EpicUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*EpicUpdateOne) SetAssignee ¶
func (euo *EpicUpdateOne) SetAssignee(u *User) *EpicUpdateOne
SetAssignee sets the "assignee" edge to the User entity.
func (*EpicUpdateOne) SetAssigneeID ¶
func (euo *EpicUpdateOne) SetAssigneeID(id int) *EpicUpdateOne
SetAssigneeID sets the "assignee" edge to the User entity by ID.
func (*EpicUpdateOne) SetDescription ¶
func (euo *EpicUpdateOne) SetDescription(s string) *EpicUpdateOne
SetDescription sets the "description" field.
func (*EpicUpdateOne) SetInput ¶
func (c *EpicUpdateOne) SetInput(i UpdateEpicInput) *EpicUpdateOne
SetInput applies the change-set in the UpdateEpicInput on the EpicUpdateOne builder.
func (*EpicUpdateOne) SetName ¶
func (euo *EpicUpdateOne) SetName(s string) *EpicUpdateOne
SetName sets the "name" field.
func (*EpicUpdateOne) SetNillableAssigneeID ¶
func (euo *EpicUpdateOne) SetNillableAssigneeID(id *int) *EpicUpdateOne
SetNillableAssigneeID sets the "assignee" edge to the User entity by ID if the given value is not nil.
func (*EpicUpdateOne) SetNillableProjectID ¶
func (euo *EpicUpdateOne) SetNillableProjectID(id *int) *EpicUpdateOne
SetNillableProjectID sets the "project" edge to the Project entity by ID if the given value is not nil.
func (*EpicUpdateOne) SetNillableReporterID ¶
func (euo *EpicUpdateOne) SetNillableReporterID(id *int) *EpicUpdateOne
SetNillableReporterID sets the "reporter" edge to the User entity by ID if the given value is not nil.
func (*EpicUpdateOne) SetProject ¶
func (euo *EpicUpdateOne) SetProject(p *Project) *EpicUpdateOne
SetProject sets the "project" edge to the Project entity.
func (*EpicUpdateOne) SetProjectID ¶
func (euo *EpicUpdateOne) SetProjectID(id int) *EpicUpdateOne
SetProjectID sets the "project" edge to the Project entity by ID.
func (*EpicUpdateOne) SetReporter ¶
func (euo *EpicUpdateOne) SetReporter(u *User) *EpicUpdateOne
SetReporter sets the "reporter" edge to the User entity.
func (*EpicUpdateOne) SetReporterID ¶
func (euo *EpicUpdateOne) SetReporterID(id int) *EpicUpdateOne
SetReporterID sets the "reporter" edge to the User entity by ID.
type EpicWhereInput ¶
type EpicWhereInput struct { Predicates []predicate.Epic `json:"-"` Not *EpicWhereInput `json:"not,omitempty"` Or []*EpicWhereInput `json:"or,omitempty"` And []*EpicWhereInput `json:"and,omitempty"` // "id" field predicates. ID *int `json:"id,omitempty"` IDNEQ *int `json:"idNEQ,omitempty"` IDIn []int `json:"idIn,omitempty"` IDNotIn []int `json:"idNotIn,omitempty"` IDGT *int `json:"idGT,omitempty"` IDGTE *int `json:"idGTE,omitempty"` IDLT *int `json:"idLT,omitempty"` IDLTE *int `json:"idLTE,omitempty"` // "name" field predicates. Name *string `json:"name,omitempty"` NameNEQ *string `json:"nameNEQ,omitempty"` NameIn []string `json:"nameIn,omitempty"` NameNotIn []string `json:"nameNotIn,omitempty"` NameGT *string `json:"nameGT,omitempty"` NameGTE *string `json:"nameGTE,omitempty"` NameLT *string `json:"nameLT,omitempty"` NameLTE *string `json:"nameLTE,omitempty"` NameContains *string `json:"nameContains,omitempty"` NameHasPrefix *string `json:"nameHasPrefix,omitempty"` NameHasSuffix *string `json:"nameHasSuffix,omitempty"` NameEqualFold *string `json:"nameEqualFold,omitempty"` NameContainsFold *string `json:"nameContainsFold,omitempty"` // "description" field predicates. Description *string `json:"description,omitempty"` DescriptionNEQ *string `json:"descriptionNEQ,omitempty"` DescriptionIn []string `json:"descriptionIn,omitempty"` DescriptionNotIn []string `json:"descriptionNotIn,omitempty"` DescriptionGT *string `json:"descriptionGT,omitempty"` DescriptionGTE *string `json:"descriptionGTE,omitempty"` DescriptionLT *string `json:"descriptionLT,omitempty"` DescriptionLTE *string `json:"descriptionLTE,omitempty"` DescriptionContains *string `json:"descriptionContains,omitempty"` DescriptionHasPrefix *string `json:"descriptionHasPrefix,omitempty"` DescriptionHasSuffix *string `json:"descriptionHasSuffix,omitempty"` DescriptionEqualFold *string `json:"descriptionEqualFold,omitempty"` DescriptionContainsFold *string `json:"descriptionContainsFold,omitempty"` // "project" edge predicates. HasProject *bool `json:"hasProject,omitempty"` HasProjectWith []*ProjectWhereInput `json:"hasProjectWith,omitempty"` // "reporter" edge predicates. HasReporter *bool `json:"hasReporter,omitempty"` HasReporterWith []*UserWhereInput `json:"hasReporterWith,omitempty"` // "assignee" edge predicates. HasAssignee *bool `json:"hasAssignee,omitempty"` HasAssigneeWith []*UserWhereInput `json:"hasAssigneeWith,omitempty"` // "comments" edge predicates. HasComments *bool `json:"hasComments,omitempty"` HasCommentsWith []*CommentWhereInput `json:"hasCommentsWith,omitempty"` }
EpicWhereInput represents a where input for filtering Epic queries.
func (*EpicWhereInput) AddPredicates ¶
func (i *EpicWhereInput) AddPredicates(predicates ...predicate.Epic)
AddPredicates adds custom predicates to the where input to be used during the filtering phase.
type Field ¶
type Field struct { Type string `json:"type,omitempty"` // field type. Name string `json:"name,omitempty"` // field name (as in struct). Value string `json:"value,omitempty"` // stringified value. }
Field of a node.
type InterceptFunc ¶
type InterceptFunc = ent.InterceptFunc
ent aliases to avoid import conflicts in user's code.
type Interceptor ¶
type Interceptor = ent.Interceptor
ent aliases to avoid import conflicts in user's code.
type MutateFunc ¶
type MutateFunc = ent.MutateFunc
ent aliases to avoid import conflicts in user's code.
type Node ¶
type Node struct { ID int `json:"id,omitempty"` // node id. Type string `json:"type,omitempty"` // node type. Fields []*Field `json:"fields,omitempty"` // node fields. Edges []*Edge `json:"edges,omitempty"` // node edges. }
Node in the graph.
type NodeOption ¶
type NodeOption func(*nodeOptions)
NodeOption allows configuring the Noder execution using functional options.
func WithFixedNodeType ¶
func WithFixedNodeType(t string) NodeOption
WithFixedNodeType sets the Type of the node to a fixed value.
func WithNodeType ¶
WithNodeType sets the node Type resolver function (i.e. the table to query). If was not provided, the table will be derived from the universal-id configuration as described in: https://entgo.io/docs/migrate/#universal-ids.
type NotFoundError ¶
type NotFoundError struct {
// contains filtered or unexported fields
}
NotFoundError returns when trying to fetch a specific entity and it was not found in the database.
func (*NotFoundError) Error ¶
func (e *NotFoundError) Error() string
Error implements the error interface.
type NotLoadedError ¶
type NotLoadedError struct {
// contains filtered or unexported fields
}
NotLoadedError returns when trying to get a node that was not loaded by the query.
func (*NotLoadedError) Error ¶
func (e *NotLoadedError) Error() string
Error implements the error interface.
type NotSingularError ¶
type NotSingularError struct {
// contains filtered or unexported fields
}
NotSingularError returns when trying to fetch a singular entity and more then one was found in the database.
func (*NotSingularError) Error ¶
func (e *NotSingularError) Error() string
Error implements the error interface.
type OrderDirection ¶
type OrderDirection string
OrderDirection defines the directions in which to order a list of items.
const ( // OrderDirectionAsc specifies an ascending order. OrderDirectionAsc OrderDirection = "ASC" // OrderDirectionDesc specifies a descending order. OrderDirectionDesc OrderDirection = "DESC" )
func (OrderDirection) MarshalGQL ¶
func (o OrderDirection) MarshalGQL(w io.Writer)
MarshalGQL implements graphql.Marshaler interface.
func (OrderDirection) String ¶
func (o OrderDirection) String() string
String implements fmt.Stringer interface.
func (*OrderDirection) UnmarshalGQL ¶
func (o *OrderDirection) UnmarshalGQL(val interface{}) error
UnmarshalGQL implements graphql.Unmarshaler interface.
func (OrderDirection) Validate ¶
func (o OrderDirection) Validate() error
Validate the order direction value.
type PageInfo ¶
type PageInfo struct { HasNextPage bool `json:"hasNextPage"` HasPreviousPage bool `json:"hasPreviousPage"` StartCursor *Cursor `json:"startCursor"` EndCursor *Cursor `json:"endCursor"` }
PageInfo of a connection type.
type Project ¶
type Project struct { // ID of the ent. ID int `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Description holds the value of the "description" field. Description string `json:"description,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the ProjectQuery when eager-loading is set. Edges ProjectEdges `json:"edges"` // contains filtered or unexported fields }
Project is the model entity for the Project schema.
func (*Project) NamedComments ¶
NamedComments returns the Comments named value or an error if the edge was not loaded in eager-loading with this name.
func (*Project) NamedEpics ¶
NamedEpics returns the Epics named value or an error if the edge was not loaded in eager-loading with this name.
func (*Project) QueryComments ¶
func (pr *Project) QueryComments() *CommentQuery
QueryComments queries the "comments" edge of the Project entity.
func (*Project) QueryEpics ¶
QueryEpics queries the "epics" edge of the Project entity.
func (*Project) QueryOwner ¶
QueryOwner queries the "owner" edge of the Project entity.
func (*Project) ToEdge ¶
func (pr *Project) ToEdge(order *ProjectOrder) *ProjectEdge
ToEdge converts Project into ProjectEdge.
func (*Project) Unwrap ¶
Unwrap unwraps the Project entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*Project) Update ¶
func (pr *Project) Update() *ProjectUpdateOne
Update returns a builder for updating this Project. Note that you need to call Project.Unwrap() before calling this method if this Project was returned from a transaction, and the transaction was committed or rolled back.
type ProjectClient ¶
type ProjectClient struct {
// contains filtered or unexported fields
}
ProjectClient is a client for the Project schema.
func NewProjectClient ¶
func NewProjectClient(c config) *ProjectClient
NewProjectClient returns a client for the Project from the given config.
func (*ProjectClient) Create ¶
func (c *ProjectClient) Create() *ProjectCreate
Create returns a builder for creating a Project entity.
func (*ProjectClient) CreateBulk ¶
func (c *ProjectClient) CreateBulk(builders ...*ProjectCreate) *ProjectCreateBulk
CreateBulk returns a builder for creating a bulk of Project entities.
func (*ProjectClient) Delete ¶
func (c *ProjectClient) Delete() *ProjectDelete
Delete returns a delete builder for Project.
func (*ProjectClient) DeleteOne ¶
func (c *ProjectClient) DeleteOne(pr *Project) *ProjectDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*ProjectClient) DeleteOneID ¶
func (c *ProjectClient) DeleteOneID(id int) *ProjectDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*ProjectClient) GetX ¶
func (c *ProjectClient) GetX(ctx context.Context, id int) *Project
GetX is like Get, but panics if an error occurs.
func (*ProjectClient) Hooks ¶
func (c *ProjectClient) Hooks() []Hook
Hooks returns the client hooks.
func (*ProjectClient) Intercept ¶
func (c *ProjectClient) Intercept(interceptors ...Interceptor)
Use adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `project.Intercept(f(g(h())))`.
func (*ProjectClient) Interceptors ¶
func (c *ProjectClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*ProjectClient) Query ¶
func (c *ProjectClient) Query() *ProjectQuery
Query returns a query builder for Project.
func (*ProjectClient) QueryComments ¶
func (c *ProjectClient) QueryComments(pr *Project) *CommentQuery
QueryComments queries the comments edge of a Project.
func (*ProjectClient) QueryEpics ¶
func (c *ProjectClient) QueryEpics(pr *Project) *EpicQuery
QueryEpics queries the epics edge of a Project.
func (*ProjectClient) QueryOwner ¶
func (c *ProjectClient) QueryOwner(pr *Project) *UserQuery
QueryOwner queries the owner edge of a Project.
func (*ProjectClient) Update ¶
func (c *ProjectClient) Update() *ProjectUpdate
Update returns an update builder for Project.
func (*ProjectClient) UpdateOne ¶
func (c *ProjectClient) UpdateOne(pr *Project) *ProjectUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ProjectClient) UpdateOneID ¶
func (c *ProjectClient) UpdateOneID(id int) *ProjectUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ProjectClient) Use ¶
func (c *ProjectClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `project.Hooks(f(g(h())))`.
type ProjectConnection ¶
type ProjectConnection struct { Edges []*ProjectEdge `json:"edges"` PageInfo PageInfo `json:"pageInfo"` TotalCount int `json:"totalCount"` }
ProjectConnection is the connection containing edges to Project.
type ProjectCreate ¶
type ProjectCreate struct {
// contains filtered or unexported fields
}
ProjectCreate is the builder for creating a Project entity.
func (*ProjectCreate) AddCommentIDs ¶
func (pc *ProjectCreate) AddCommentIDs(ids ...int) *ProjectCreate
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*ProjectCreate) AddComments ¶
func (pc *ProjectCreate) AddComments(c ...*Comment) *ProjectCreate
AddComments adds the "comments" edges to the Comment entity.
func (*ProjectCreate) AddEpicIDs ¶
func (pc *ProjectCreate) AddEpicIDs(ids ...int) *ProjectCreate
AddEpicIDs adds the "epics" edge to the Epic entity by IDs.
func (*ProjectCreate) AddEpics ¶
func (pc *ProjectCreate) AddEpics(e ...*Epic) *ProjectCreate
AddEpics adds the "epics" edges to the Epic entity.
func (*ProjectCreate) Exec ¶
func (pc *ProjectCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ProjectCreate) ExecX ¶
func (pc *ProjectCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ProjectCreate) Mutation ¶
func (pc *ProjectCreate) Mutation() *ProjectMutation
Mutation returns the ProjectMutation object of the builder.
func (*ProjectCreate) Save ¶
func (pc *ProjectCreate) Save(ctx context.Context) (*Project, error)
Save creates the Project in the database.
func (*ProjectCreate) SaveX ¶
func (pc *ProjectCreate) SaveX(ctx context.Context) *Project
SaveX calls Save and panics if Save returns an error.
func (*ProjectCreate) SetDescription ¶
func (pc *ProjectCreate) SetDescription(s string) *ProjectCreate
SetDescription sets the "description" field.
func (*ProjectCreate) SetInput ¶
func (c *ProjectCreate) SetInput(i CreateProjectInput) *ProjectCreate
SetInput applies the change-set in the CreateProjectInput on the ProjectCreate builder.
func (*ProjectCreate) SetName ¶
func (pc *ProjectCreate) SetName(s string) *ProjectCreate
SetName sets the "name" field.
func (*ProjectCreate) SetNillableDescription ¶
func (pc *ProjectCreate) SetNillableDescription(s *string) *ProjectCreate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*ProjectCreate) SetNillableOwnerID ¶
func (pc *ProjectCreate) SetNillableOwnerID(id *int) *ProjectCreate
SetNillableOwnerID sets the "owner" edge to the User entity by ID if the given value is not nil.
func (*ProjectCreate) SetOwner ¶
func (pc *ProjectCreate) SetOwner(u *User) *ProjectCreate
SetOwner sets the "owner" edge to the User entity.
func (*ProjectCreate) SetOwnerID ¶
func (pc *ProjectCreate) SetOwnerID(id int) *ProjectCreate
SetOwnerID sets the "owner" edge to the User entity by ID.
type ProjectCreateBulk ¶
type ProjectCreateBulk struct {
// contains filtered or unexported fields
}
ProjectCreateBulk is the builder for creating many Project entities in bulk.
func (*ProjectCreateBulk) Exec ¶
func (pcb *ProjectCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ProjectCreateBulk) ExecX ¶
func (pcb *ProjectCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type ProjectDelete ¶
type ProjectDelete struct {
// contains filtered or unexported fields
}
ProjectDelete is the builder for deleting a Project entity.
func (*ProjectDelete) Exec ¶
func (pd *ProjectDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ProjectDelete) ExecX ¶
func (pd *ProjectDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ProjectDelete) Where ¶
func (pd *ProjectDelete) Where(ps ...predicate.Project) *ProjectDelete
Where appends a list predicates to the ProjectDelete builder.
type ProjectDeleteOne ¶
type ProjectDeleteOne struct {
// contains filtered or unexported fields
}
ProjectDeleteOne is the builder for deleting a single Project entity.
func (*ProjectDeleteOne) Exec ¶
func (pdo *ProjectDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ProjectDeleteOne) ExecX ¶
func (pdo *ProjectDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type ProjectEdge ¶
ProjectEdge is the edge representation of Project.
type ProjectEdges ¶
type ProjectEdges struct { // Epics holds the value of the epics edge. Epics []*Epic `json:"epics,omitempty"` // Owner holds the value of the owner edge. Owner *User `json:"owner,omitempty"` // Comments holds the value of the comments edge. Comments []*Comment `json:"comments,omitempty"` // contains filtered or unexported fields }
ProjectEdges holds the relations/edges for other nodes in the graph.
func (ProjectEdges) CommentsOrErr ¶
func (e ProjectEdges) CommentsOrErr() ([]*Comment, error)
CommentsOrErr returns the Comments value or an error if the edge was not loaded in eager-loading.
func (ProjectEdges) EpicsOrErr ¶
func (e ProjectEdges) EpicsOrErr() ([]*Epic, error)
EpicsOrErr returns the Epics value or an error if the edge was not loaded in eager-loading.
func (ProjectEdges) OwnerOrErr ¶
func (e ProjectEdges) OwnerOrErr() (*User, error)
OwnerOrErr returns the Owner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type ProjectGroupBy ¶
type ProjectGroupBy struct {
// contains filtered or unexported fields
}
ProjectGroupBy is the group-by builder for Project entities.
func (*ProjectGroupBy) Aggregate ¶
func (pgb *ProjectGroupBy) Aggregate(fns ...AggregateFunc) *ProjectGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ProjectGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ProjectGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ProjectGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ProjectGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ProjectGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ProjectGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ProjectGroupBy) Scan ¶
func (pgb *ProjectGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ProjectGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ProjectMutation ¶
type ProjectMutation struct {
// contains filtered or unexported fields
}
ProjectMutation represents an operation that mutates the Project nodes in the graph.
func (*ProjectMutation) AddCommentIDs ¶
func (m *ProjectMutation) AddCommentIDs(ids ...int)
AddCommentIDs adds the "comments" edge to the Comment entity by ids.
func (*ProjectMutation) AddEpicIDs ¶
func (m *ProjectMutation) AddEpicIDs(ids ...int)
AddEpicIDs adds the "epics" edge to the Epic entity by ids.
func (*ProjectMutation) AddField ¶
func (m *ProjectMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*ProjectMutation) AddedEdges ¶
func (m *ProjectMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ProjectMutation) AddedField ¶
func (m *ProjectMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*ProjectMutation) AddedFields ¶
func (m *ProjectMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ProjectMutation) AddedIDs ¶
func (m *ProjectMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ProjectMutation) ClearComments ¶
func (m *ProjectMutation) ClearComments()
ClearComments clears the "comments" edge to the Comment entity.
func (*ProjectMutation) ClearDescription ¶
func (m *ProjectMutation) ClearDescription()
ClearDescription clears the value of the "description" field.
func (*ProjectMutation) ClearEdge ¶
func (m *ProjectMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*ProjectMutation) ClearEpics ¶
func (m *ProjectMutation) ClearEpics()
ClearEpics clears the "epics" edge to the Epic entity.
func (*ProjectMutation) ClearField ¶
func (m *ProjectMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*ProjectMutation) ClearOwner ¶
func (m *ProjectMutation) ClearOwner()
ClearOwner clears the "owner" edge to the User entity.
func (*ProjectMutation) ClearedEdges ¶
func (m *ProjectMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ProjectMutation) ClearedFields ¶
func (m *ProjectMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ProjectMutation) Client ¶
func (m ProjectMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*ProjectMutation) CommentsCleared ¶
func (m *ProjectMutation) CommentsCleared() bool
CommentsCleared reports if the "comments" edge to the Comment entity was cleared.
func (*ProjectMutation) CommentsIDs ¶
func (m *ProjectMutation) CommentsIDs() (ids []int)
CommentsIDs returns the "comments" edge IDs in the mutation.
func (*ProjectMutation) Description ¶
func (m *ProjectMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*ProjectMutation) DescriptionCleared ¶
func (m *ProjectMutation) DescriptionCleared() bool
DescriptionCleared returns if the "description" field was cleared in this mutation.
func (*ProjectMutation) EdgeCleared ¶
func (m *ProjectMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ProjectMutation) EpicsCleared ¶
func (m *ProjectMutation) EpicsCleared() bool
EpicsCleared reports if the "epics" edge to the Epic entity was cleared.
func (*ProjectMutation) EpicsIDs ¶
func (m *ProjectMutation) EpicsIDs() (ids []int)
EpicsIDs returns the "epics" edge IDs in the mutation.
func (*ProjectMutation) Field ¶
func (m *ProjectMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*ProjectMutation) FieldCleared ¶
func (m *ProjectMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ProjectMutation) Fields ¶
func (m *ProjectMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*ProjectMutation) ID ¶
func (m *ProjectMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*ProjectMutation) IDs ¶
func (m *ProjectMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*ProjectMutation) Name ¶
func (m *ProjectMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*ProjectMutation) OldDescription ¶
func (m *ProjectMutation) OldDescription(ctx context.Context) (v string, err error)
OldDescription returns the old "description" field's value of the Project entity. If the Project object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*ProjectMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*ProjectMutation) OldName ¶
func (m *ProjectMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Project entity. If the Project object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*ProjectMutation) OwnerCleared ¶
func (m *ProjectMutation) OwnerCleared() bool
OwnerCleared reports if the "owner" edge to the User entity was cleared.
func (*ProjectMutation) OwnerID ¶
func (m *ProjectMutation) OwnerID() (id int, exists bool)
OwnerID returns the "owner" edge ID in the mutation.
func (*ProjectMutation) OwnerIDs ¶
func (m *ProjectMutation) OwnerIDs() (ids []int)
OwnerIDs returns the "owner" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use OwnerID instead. It exists only for internal usage by the builders.
func (*ProjectMutation) RemoveCommentIDs ¶
func (m *ProjectMutation) RemoveCommentIDs(ids ...int)
RemoveCommentIDs removes the "comments" edge to the Comment entity by IDs.
func (*ProjectMutation) RemoveEpicIDs ¶
func (m *ProjectMutation) RemoveEpicIDs(ids ...int)
RemoveEpicIDs removes the "epics" edge to the Epic entity by IDs.
func (*ProjectMutation) RemovedCommentsIDs ¶
func (m *ProjectMutation) RemovedCommentsIDs() (ids []int)
RemovedComments returns the removed IDs of the "comments" edge to the Comment entity.
func (*ProjectMutation) RemovedEdges ¶
func (m *ProjectMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ProjectMutation) RemovedEpicsIDs ¶
func (m *ProjectMutation) RemovedEpicsIDs() (ids []int)
RemovedEpics returns the removed IDs of the "epics" edge to the Epic entity.
func (*ProjectMutation) RemovedIDs ¶
func (m *ProjectMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*ProjectMutation) ResetComments ¶
func (m *ProjectMutation) ResetComments()
ResetComments resets all changes to the "comments" edge.
func (*ProjectMutation) ResetDescription ¶
func (m *ProjectMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*ProjectMutation) ResetEdge ¶
func (m *ProjectMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*ProjectMutation) ResetEpics ¶
func (m *ProjectMutation) ResetEpics()
ResetEpics resets all changes to the "epics" edge.
func (*ProjectMutation) ResetField ¶
func (m *ProjectMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*ProjectMutation) ResetName ¶
func (m *ProjectMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*ProjectMutation) ResetOwner ¶
func (m *ProjectMutation) ResetOwner()
ResetOwner resets all changes to the "owner" edge.
func (*ProjectMutation) SetDescription ¶
func (m *ProjectMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*ProjectMutation) SetField ¶
func (m *ProjectMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*ProjectMutation) SetName ¶
func (m *ProjectMutation) SetName(s string)
SetName sets the "name" field.
func (*ProjectMutation) SetOp ¶
func (m *ProjectMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*ProjectMutation) SetOwnerID ¶
func (m *ProjectMutation) SetOwnerID(id int)
SetOwnerID sets the "owner" edge to the User entity by id.
func (ProjectMutation) Tx ¶
func (m ProjectMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ProjectMutation) Type ¶
func (m *ProjectMutation) Type() string
Type returns the node type of this mutation (Project).
func (*ProjectMutation) Where ¶
func (m *ProjectMutation) Where(ps ...predicate.Project)
Where appends a list predicates to the ProjectMutation builder.
func (*ProjectMutation) WhereP ¶
func (m *ProjectMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the ProjectMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type ProjectOrder ¶
type ProjectOrder struct { Direction OrderDirection `json:"direction"` Field *ProjectOrderField `json:"field"` }
ProjectOrder defines the ordering of Project.
type ProjectOrderField ¶
type ProjectOrderField struct {
// contains filtered or unexported fields
}
ProjectOrderField defines the ordering field of Project.
type ProjectPaginateOption ¶
type ProjectPaginateOption func(*projectPager) error
ProjectPaginateOption enables pagination customization.
func WithProjectFilter ¶
func WithProjectFilter(filter func(*ProjectQuery) (*ProjectQuery, error)) ProjectPaginateOption
WithProjectFilter configures pagination filter.
func WithProjectOrder ¶
func WithProjectOrder(order *ProjectOrder) ProjectPaginateOption
WithProjectOrder configures pagination ordering.
type ProjectQuery ¶
type ProjectQuery struct {
// contains filtered or unexported fields
}
ProjectQuery is the builder for querying Project entities.
func (*ProjectQuery) Aggregate ¶
func (pq *ProjectQuery) Aggregate(fns ...AggregateFunc) *ProjectSelect
Aggregate returns a ProjectSelect configured with the given aggregations.
func (*ProjectQuery) All ¶
func (pq *ProjectQuery) All(ctx context.Context) ([]*Project, error)
All executes the query and returns a list of Projects.
func (*ProjectQuery) AllX ¶
func (pq *ProjectQuery) AllX(ctx context.Context) []*Project
AllX is like All, but panics if an error occurs.
func (*ProjectQuery) Clone ¶
func (pq *ProjectQuery) Clone() *ProjectQuery
Clone returns a duplicate of the ProjectQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ProjectQuery) CollectFields ¶
func (pr *ProjectQuery) CollectFields(ctx context.Context, satisfies ...string) (*ProjectQuery, error)
CollectFields tells the query-builder to eagerly load connected nodes by resolver context.
func (*ProjectQuery) Count ¶
func (pq *ProjectQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*ProjectQuery) CountX ¶
func (pq *ProjectQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*ProjectQuery) Exist ¶
func (pq *ProjectQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*ProjectQuery) ExistX ¶
func (pq *ProjectQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*ProjectQuery) First ¶
func (pq *ProjectQuery) First(ctx context.Context) (*Project, error)
First returns the first Project entity from the query. Returns a *NotFoundError when no Project was found.
func (*ProjectQuery) FirstID ¶
func (pq *ProjectQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Project ID from the query. Returns a *NotFoundError when no Project ID was found.
func (*ProjectQuery) FirstIDX ¶
func (pq *ProjectQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*ProjectQuery) FirstX ¶
func (pq *ProjectQuery) FirstX(ctx context.Context) *Project
FirstX is like First, but panics if an error occurs.
func (*ProjectQuery) GroupBy ¶
func (pq *ProjectQuery) GroupBy(field string, fields ...string) *ProjectGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Name string `json:"name,omitempty"` Count int `json:"count,omitempty"` } client.Project.Query(). GroupBy(project.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*ProjectQuery) IDs ¶
func (pq *ProjectQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of Project IDs.
func (*ProjectQuery) IDsX ¶
func (pq *ProjectQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*ProjectQuery) Limit ¶
func (pq *ProjectQuery) Limit(limit int) *ProjectQuery
Limit the number of records to be returned by this query.
func (*ProjectQuery) Offset ¶
func (pq *ProjectQuery) Offset(offset int) *ProjectQuery
Offset to start from.
func (*ProjectQuery) Only ¶
func (pq *ProjectQuery) Only(ctx context.Context) (*Project, error)
Only returns a single Project entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Project entity is found. Returns a *NotFoundError when no Project entities are found.
func (*ProjectQuery) OnlyID ¶
func (pq *ProjectQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Project ID in the query. Returns a *NotSingularError when more than one Project ID is found. Returns a *NotFoundError when no entities are found.
func (*ProjectQuery) OnlyIDX ¶
func (pq *ProjectQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*ProjectQuery) OnlyX ¶
func (pq *ProjectQuery) OnlyX(ctx context.Context) *Project
OnlyX is like Only, but panics if an error occurs.
func (*ProjectQuery) Order ¶
func (pq *ProjectQuery) Order(o ...OrderFunc) *ProjectQuery
Order specifies how the records should be ordered.
func (*ProjectQuery) Paginate ¶
func (pr *ProjectQuery) Paginate( ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, opts ...ProjectPaginateOption, ) (*ProjectConnection, error)
Paginate executes the query and returns a relay based cursor connection to Project.
func (*ProjectQuery) QueryComments ¶
func (pq *ProjectQuery) QueryComments() *CommentQuery
QueryComments chains the current query on the "comments" edge.
func (*ProjectQuery) QueryEpics ¶
func (pq *ProjectQuery) QueryEpics() *EpicQuery
QueryEpics chains the current query on the "epics" edge.
func (*ProjectQuery) QueryOwner ¶
func (pq *ProjectQuery) QueryOwner() *UserQuery
QueryOwner chains the current query on the "owner" edge.
func (*ProjectQuery) Select ¶
func (pq *ProjectQuery) Select(fields ...string) *ProjectSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.Project.Query(). Select(project.FieldName). Scan(ctx, &v)
func (*ProjectQuery) Unique ¶
func (pq *ProjectQuery) Unique(unique bool) *ProjectQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*ProjectQuery) Where ¶
func (pq *ProjectQuery) Where(ps ...predicate.Project) *ProjectQuery
Where adds a new predicate for the ProjectQuery builder.
func (*ProjectQuery) WithComments ¶
func (pq *ProjectQuery) WithComments(opts ...func(*CommentQuery)) *ProjectQuery
WithComments tells the query-builder to eager-load the nodes that are connected to the "comments" edge. The optional arguments are used to configure the query builder of the edge.
func (*ProjectQuery) WithEpics ¶
func (pq *ProjectQuery) WithEpics(opts ...func(*EpicQuery)) *ProjectQuery
WithEpics tells the query-builder to eager-load the nodes that are connected to the "epics" edge. The optional arguments are used to configure the query builder of the edge.
func (*ProjectQuery) WithNamedComments ¶
func (pq *ProjectQuery) WithNamedComments(name string, opts ...func(*CommentQuery)) *ProjectQuery
WithNamedComments tells the query-builder to eager-load the nodes that are connected to the "comments" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*ProjectQuery) WithNamedEpics ¶
func (pq *ProjectQuery) WithNamedEpics(name string, opts ...func(*EpicQuery)) *ProjectQuery
WithNamedEpics tells the query-builder to eager-load the nodes that are connected to the "epics" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*ProjectQuery) WithOwner ¶
func (pq *ProjectQuery) WithOwner(opts ...func(*UserQuery)) *ProjectQuery
WithOwner tells the query-builder to eager-load the nodes that are connected to the "owner" edge. The optional arguments are used to configure the query builder of the edge.
type ProjectSelect ¶
type ProjectSelect struct { *ProjectQuery // contains filtered or unexported fields }
ProjectSelect is the builder for selecting fields of Project entities.
func (*ProjectSelect) Aggregate ¶
func (ps *ProjectSelect) Aggregate(fns ...AggregateFunc) *ProjectSelect
Aggregate adds the given aggregation functions to the selector query.
func (*ProjectSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ProjectSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ProjectSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ProjectSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ProjectSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ProjectSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ProjectSelect) Scan ¶
func (ps *ProjectSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ProjectSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ProjectUpdate ¶
type ProjectUpdate struct {
// contains filtered or unexported fields
}
ProjectUpdate is the builder for updating Project entities.
func (*ProjectUpdate) AddCommentIDs ¶
func (pu *ProjectUpdate) AddCommentIDs(ids ...int) *ProjectUpdate
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*ProjectUpdate) AddComments ¶
func (pu *ProjectUpdate) AddComments(c ...*Comment) *ProjectUpdate
AddComments adds the "comments" edges to the Comment entity.
func (*ProjectUpdate) AddEpicIDs ¶
func (pu *ProjectUpdate) AddEpicIDs(ids ...int) *ProjectUpdate
AddEpicIDs adds the "epics" edge to the Epic entity by IDs.
func (*ProjectUpdate) AddEpics ¶
func (pu *ProjectUpdate) AddEpics(e ...*Epic) *ProjectUpdate
AddEpics adds the "epics" edges to the Epic entity.
func (*ProjectUpdate) ClearComments ¶
func (pu *ProjectUpdate) ClearComments() *ProjectUpdate
ClearComments clears all "comments" edges to the Comment entity.
func (*ProjectUpdate) ClearDescription ¶
func (pu *ProjectUpdate) ClearDescription() *ProjectUpdate
ClearDescription clears the value of the "description" field.
func (*ProjectUpdate) ClearEpics ¶
func (pu *ProjectUpdate) ClearEpics() *ProjectUpdate
ClearEpics clears all "epics" edges to the Epic entity.
func (*ProjectUpdate) ClearOwner ¶
func (pu *ProjectUpdate) ClearOwner() *ProjectUpdate
ClearOwner clears the "owner" edge to the User entity.
func (*ProjectUpdate) Exec ¶
func (pu *ProjectUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ProjectUpdate) ExecX ¶
func (pu *ProjectUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ProjectUpdate) Mutation ¶
func (pu *ProjectUpdate) Mutation() *ProjectMutation
Mutation returns the ProjectMutation object of the builder.
func (*ProjectUpdate) RemoveCommentIDs ¶
func (pu *ProjectUpdate) RemoveCommentIDs(ids ...int) *ProjectUpdate
RemoveCommentIDs removes the "comments" edge to Comment entities by IDs.
func (*ProjectUpdate) RemoveComments ¶
func (pu *ProjectUpdate) RemoveComments(c ...*Comment) *ProjectUpdate
RemoveComments removes "comments" edges to Comment entities.
func (*ProjectUpdate) RemoveEpicIDs ¶
func (pu *ProjectUpdate) RemoveEpicIDs(ids ...int) *ProjectUpdate
RemoveEpicIDs removes the "epics" edge to Epic entities by IDs.
func (*ProjectUpdate) RemoveEpics ¶
func (pu *ProjectUpdate) RemoveEpics(e ...*Epic) *ProjectUpdate
RemoveEpics removes "epics" edges to Epic entities.
func (*ProjectUpdate) Save ¶
func (pu *ProjectUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ProjectUpdate) SaveX ¶
func (pu *ProjectUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ProjectUpdate) SetDescription ¶
func (pu *ProjectUpdate) SetDescription(s string) *ProjectUpdate
SetDescription sets the "description" field.
func (*ProjectUpdate) SetInput ¶
func (c *ProjectUpdate) SetInput(i UpdateProjectInput) *ProjectUpdate
SetInput applies the change-set in the UpdateProjectInput on the ProjectUpdate builder.
func (*ProjectUpdate) SetName ¶
func (pu *ProjectUpdate) SetName(s string) *ProjectUpdate
SetName sets the "name" field.
func (*ProjectUpdate) SetNillableDescription ¶
func (pu *ProjectUpdate) SetNillableDescription(s *string) *ProjectUpdate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*ProjectUpdate) SetNillableOwnerID ¶
func (pu *ProjectUpdate) SetNillableOwnerID(id *int) *ProjectUpdate
SetNillableOwnerID sets the "owner" edge to the User entity by ID if the given value is not nil.
func (*ProjectUpdate) SetOwner ¶
func (pu *ProjectUpdate) SetOwner(u *User) *ProjectUpdate
SetOwner sets the "owner" edge to the User entity.
func (*ProjectUpdate) SetOwnerID ¶
func (pu *ProjectUpdate) SetOwnerID(id int) *ProjectUpdate
SetOwnerID sets the "owner" edge to the User entity by ID.
func (*ProjectUpdate) Where ¶
func (pu *ProjectUpdate) Where(ps ...predicate.Project) *ProjectUpdate
Where appends a list predicates to the ProjectUpdate builder.
type ProjectUpdateOne ¶
type ProjectUpdateOne struct {
// contains filtered or unexported fields
}
ProjectUpdateOne is the builder for updating a single Project entity.
func (*ProjectUpdateOne) AddCommentIDs ¶
func (puo *ProjectUpdateOne) AddCommentIDs(ids ...int) *ProjectUpdateOne
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*ProjectUpdateOne) AddComments ¶
func (puo *ProjectUpdateOne) AddComments(c ...*Comment) *ProjectUpdateOne
AddComments adds the "comments" edges to the Comment entity.
func (*ProjectUpdateOne) AddEpicIDs ¶
func (puo *ProjectUpdateOne) AddEpicIDs(ids ...int) *ProjectUpdateOne
AddEpicIDs adds the "epics" edge to the Epic entity by IDs.
func (*ProjectUpdateOne) AddEpics ¶
func (puo *ProjectUpdateOne) AddEpics(e ...*Epic) *ProjectUpdateOne
AddEpics adds the "epics" edges to the Epic entity.
func (*ProjectUpdateOne) ClearComments ¶
func (puo *ProjectUpdateOne) ClearComments() *ProjectUpdateOne
ClearComments clears all "comments" edges to the Comment entity.
func (*ProjectUpdateOne) ClearDescription ¶
func (puo *ProjectUpdateOne) ClearDescription() *ProjectUpdateOne
ClearDescription clears the value of the "description" field.
func (*ProjectUpdateOne) ClearEpics ¶
func (puo *ProjectUpdateOne) ClearEpics() *ProjectUpdateOne
ClearEpics clears all "epics" edges to the Epic entity.
func (*ProjectUpdateOne) ClearOwner ¶
func (puo *ProjectUpdateOne) ClearOwner() *ProjectUpdateOne
ClearOwner clears the "owner" edge to the User entity.
func (*ProjectUpdateOne) Exec ¶
func (puo *ProjectUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ProjectUpdateOne) ExecX ¶
func (puo *ProjectUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ProjectUpdateOne) Mutation ¶
func (puo *ProjectUpdateOne) Mutation() *ProjectMutation
Mutation returns the ProjectMutation object of the builder.
func (*ProjectUpdateOne) RemoveCommentIDs ¶
func (puo *ProjectUpdateOne) RemoveCommentIDs(ids ...int) *ProjectUpdateOne
RemoveCommentIDs removes the "comments" edge to Comment entities by IDs.
func (*ProjectUpdateOne) RemoveComments ¶
func (puo *ProjectUpdateOne) RemoveComments(c ...*Comment) *ProjectUpdateOne
RemoveComments removes "comments" edges to Comment entities.
func (*ProjectUpdateOne) RemoveEpicIDs ¶
func (puo *ProjectUpdateOne) RemoveEpicIDs(ids ...int) *ProjectUpdateOne
RemoveEpicIDs removes the "epics" edge to Epic entities by IDs.
func (*ProjectUpdateOne) RemoveEpics ¶
func (puo *ProjectUpdateOne) RemoveEpics(e ...*Epic) *ProjectUpdateOne
RemoveEpics removes "epics" edges to Epic entities.
func (*ProjectUpdateOne) Save ¶
func (puo *ProjectUpdateOne) Save(ctx context.Context) (*Project, error)
Save executes the query and returns the updated Project entity.
func (*ProjectUpdateOne) SaveX ¶
func (puo *ProjectUpdateOne) SaveX(ctx context.Context) *Project
SaveX is like Save, but panics if an error occurs.
func (*ProjectUpdateOne) Select ¶
func (puo *ProjectUpdateOne) Select(field string, fields ...string) *ProjectUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ProjectUpdateOne) SetDescription ¶
func (puo *ProjectUpdateOne) SetDescription(s string) *ProjectUpdateOne
SetDescription sets the "description" field.
func (*ProjectUpdateOne) SetInput ¶
func (c *ProjectUpdateOne) SetInput(i UpdateProjectInput) *ProjectUpdateOne
SetInput applies the change-set in the UpdateProjectInput on the ProjectUpdateOne builder.
func (*ProjectUpdateOne) SetName ¶
func (puo *ProjectUpdateOne) SetName(s string) *ProjectUpdateOne
SetName sets the "name" field.
func (*ProjectUpdateOne) SetNillableDescription ¶
func (puo *ProjectUpdateOne) SetNillableDescription(s *string) *ProjectUpdateOne
SetNillableDescription sets the "description" field if the given value is not nil.
func (*ProjectUpdateOne) SetNillableOwnerID ¶
func (puo *ProjectUpdateOne) SetNillableOwnerID(id *int) *ProjectUpdateOne
SetNillableOwnerID sets the "owner" edge to the User entity by ID if the given value is not nil.
func (*ProjectUpdateOne) SetOwner ¶
func (puo *ProjectUpdateOne) SetOwner(u *User) *ProjectUpdateOne
SetOwner sets the "owner" edge to the User entity.
func (*ProjectUpdateOne) SetOwnerID ¶
func (puo *ProjectUpdateOne) SetOwnerID(id int) *ProjectUpdateOne
SetOwnerID sets the "owner" edge to the User entity by ID.
type ProjectWhereInput ¶
type ProjectWhereInput struct { Predicates []predicate.Project `json:"-"` Not *ProjectWhereInput `json:"not,omitempty"` Or []*ProjectWhereInput `json:"or,omitempty"` And []*ProjectWhereInput `json:"and,omitempty"` // "id" field predicates. ID *int `json:"id,omitempty"` IDNEQ *int `json:"idNEQ,omitempty"` IDIn []int `json:"idIn,omitempty"` IDNotIn []int `json:"idNotIn,omitempty"` IDGT *int `json:"idGT,omitempty"` IDGTE *int `json:"idGTE,omitempty"` IDLT *int `json:"idLT,omitempty"` IDLTE *int `json:"idLTE,omitempty"` // "name" field predicates. Name *string `json:"name,omitempty"` NameNEQ *string `json:"nameNEQ,omitempty"` NameIn []string `json:"nameIn,omitempty"` NameNotIn []string `json:"nameNotIn,omitempty"` NameGT *string `json:"nameGT,omitempty"` NameGTE *string `json:"nameGTE,omitempty"` NameLT *string `json:"nameLT,omitempty"` NameLTE *string `json:"nameLTE,omitempty"` NameContains *string `json:"nameContains,omitempty"` NameHasPrefix *string `json:"nameHasPrefix,omitempty"` NameHasSuffix *string `json:"nameHasSuffix,omitempty"` NameEqualFold *string `json:"nameEqualFold,omitempty"` NameContainsFold *string `json:"nameContainsFold,omitempty"` // "description" field predicates. Description *string `json:"description,omitempty"` DescriptionNEQ *string `json:"descriptionNEQ,omitempty"` DescriptionIn []string `json:"descriptionIn,omitempty"` DescriptionNotIn []string `json:"descriptionNotIn,omitempty"` DescriptionGT *string `json:"descriptionGT,omitempty"` DescriptionGTE *string `json:"descriptionGTE,omitempty"` DescriptionLT *string `json:"descriptionLT,omitempty"` DescriptionLTE *string `json:"descriptionLTE,omitempty"` DescriptionContains *string `json:"descriptionContains,omitempty"` DescriptionHasPrefix *string `json:"descriptionHasPrefix,omitempty"` DescriptionHasSuffix *string `json:"descriptionHasSuffix,omitempty"` DescriptionIsNil bool `json:"descriptionIsNil,omitempty"` DescriptionNotNil bool `json:"descriptionNotNil,omitempty"` DescriptionEqualFold *string `json:"descriptionEqualFold,omitempty"` DescriptionContainsFold *string `json:"descriptionContainsFold,omitempty"` // "epics" edge predicates. HasEpics *bool `json:"hasEpics,omitempty"` HasEpicsWith []*EpicWhereInput `json:"hasEpicsWith,omitempty"` // "owner" edge predicates. HasOwner *bool `json:"hasOwner,omitempty"` HasOwnerWith []*UserWhereInput `json:"hasOwnerWith,omitempty"` // "comments" edge predicates. HasComments *bool `json:"hasComments,omitempty"` HasCommentsWith []*CommentWhereInput `json:"hasCommentsWith,omitempty"` }
ProjectWhereInput represents a where input for filtering Project queries.
func (*ProjectWhereInput) AddPredicates ¶
func (i *ProjectWhereInput) AddPredicates(predicates ...predicate.Project)
AddPredicates adds custom predicates to the where input to be used during the filtering phase.
func (*ProjectWhereInput) Filter ¶
func (i *ProjectWhereInput) Filter(q *ProjectQuery) (*ProjectQuery, error)
Filter applies the ProjectWhereInput filter on the ProjectQuery builder.
type QuerierFunc ¶
type QuerierFunc = ent.QuerierFunc
ent aliases to avoid import conflicts in user's code.
type RollbackFunc ¶
The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.
type RollbackHook ¶
type RollbackHook func(Rollbacker) Rollbacker
RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:
hook := func(next ent.Rollbacker) ent.Rollbacker { return ent.RollbackFunc(func(ctx context.Context, tx *ent.Tx) error { // Do some stuff before. if err := next.Rollback(ctx, tx); err != nil { return err } // Do some stuff after. return nil }) }
type Rollbacker ¶
Rollbacker is the interface that wraps the Rollback method.
type TraverseFunc ¶
type TraverseFunc = ent.TraverseFunc
ent aliases to avoid import conflicts in user's code.
type Tx ¶
type Tx struct { // Comment is the client for interacting with the Comment builders. Comment *CommentClient // Epic is the client for interacting with the Epic builders. Epic *EpicClient // Project is the client for interacting with the Project builders. Project *ProjectClient // User is the client for interacting with the User builders. User *UserClient // contains filtered or unexported fields }
Tx is a transactional client that is created by calling Client.Tx().
func TxFromContext ¶
TxFromContext returns a Tx stored inside a context, or nil if there isn't one.
func (*Tx) OnRollback ¶
func (tx *Tx) OnRollback(f RollbackHook)
OnRollback adds a hook to call on rollback.
type UpdateCommentInput ¶
type UpdateCommentInput struct { Text *string AddEpicIDs []int RemoveEpicIDs []int AddProjectIDs []int RemoveProjectIDs []int AddUserIDs []int RemoveUserIDs []int }
UpdateCommentInput represents a mutation input for updating comments.
func (*UpdateCommentInput) Mutate ¶
func (i *UpdateCommentInput) Mutate(m *CommentMutation)
Mutate applies the UpdateCommentInput on the CommentMutation builder.
type UpdateEpicInput ¶
type UpdateEpicInput struct { Name *string Description *string ClearProject bool ProjectID *int ClearReporter bool ReporterID *int ClearAssignee bool AssigneeID *int AddCommentIDs []int RemoveCommentIDs []int }
UpdateEpicInput represents a mutation input for updating epics.
func (*UpdateEpicInput) Mutate ¶
func (i *UpdateEpicInput) Mutate(m *EpicMutation)
Mutate applies the UpdateEpicInput on the EpicMutation builder.
type UpdateProjectInput ¶
type UpdateProjectInput struct { Name *string ClearDescription bool Description *string AddEpicIDs []int RemoveEpicIDs []int ClearOwner bool OwnerID *int AddCommentIDs []int RemoveCommentIDs []int }
UpdateProjectInput represents a mutation input for updating projects.
func (*UpdateProjectInput) Mutate ¶
func (i *UpdateProjectInput) Mutate(m *ProjectMutation)
Mutate applies the UpdateProjectInput on the ProjectMutation builder.
type UpdateUserInput ¶
type UpdateUserInput struct { Name *string Surname *string Username *string Email *string AddOwnIDs []int RemoveOwnIDs []int AddReporterIDs []int RemoveReporterIDs []int AddAssigneeIDs []int RemoveAssigneeIDs []int AddCommentIDs []int RemoveCommentIDs []int }
UpdateUserInput represents a mutation input for updating users.
func (*UpdateUserInput) Mutate ¶
func (i *UpdateUserInput) Mutate(m *UserMutation)
Mutate applies the UpdateUserInput on the UserMutation builder.
type User ¶
type User struct { // ID of the ent. ID int `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Surname holds the value of the "surname" field. Surname string `json:"surname,omitempty"` // Username holds the value of the "username" field. Username string `json:"username,omitempty"` // Email holds the value of the "email" field. Email string `json:"email,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the UserQuery when eager-loading is set. Edges UserEdges `json:"edges"` // contains filtered or unexported fields }
User is the model entity for the User schema.
func (*User) NamedAssignee ¶
NamedAssignee returns the Assignee named value or an error if the edge was not loaded in eager-loading with this name.
func (*User) NamedComments ¶
NamedComments returns the Comments named value or an error if the edge was not loaded in eager-loading with this name.
func (*User) NamedOwns ¶
NamedOwns returns the Owns named value or an error if the edge was not loaded in eager-loading with this name.
func (*User) NamedReporter ¶
NamedReporter returns the Reporter named value or an error if the edge was not loaded in eager-loading with this name.
func (*User) QueryAssignee ¶
QueryAssignee queries the "assignee" edge of the User entity.
func (*User) QueryComments ¶
func (u *User) QueryComments() *CommentQuery
QueryComments queries the "comments" edge of the User entity.
func (*User) QueryOwns ¶
func (u *User) QueryOwns() *ProjectQuery
QueryOwns queries the "owns" edge of the User entity.
func (*User) QueryReporter ¶
QueryReporter queries the "reporter" edge of the User entity.
func (*User) Unwrap ¶
Unwrap unwraps the User entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*User) Update ¶
func (u *User) Update() *UserUpdateOne
Update returns a builder for updating this User. Note that you need to call User.Unwrap() before calling this method if this User was returned from a transaction, and the transaction was committed or rolled back.
type UserClient ¶
type UserClient struct {
// contains filtered or unexported fields
}
UserClient is a client for the User schema.
func NewUserClient ¶
func NewUserClient(c config) *UserClient
NewUserClient returns a client for the User from the given config.
func (*UserClient) Create ¶
func (c *UserClient) Create() *UserCreate
Create returns a builder for creating a User entity.
func (*UserClient) CreateBulk ¶
func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
CreateBulk returns a builder for creating a bulk of User entities.
func (*UserClient) Delete ¶
func (c *UserClient) Delete() *UserDelete
Delete returns a delete builder for User.
func (*UserClient) DeleteOne ¶
func (c *UserClient) DeleteOne(u *User) *UserDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*UserClient) DeleteOneID ¶
func (c *UserClient) DeleteOneID(id int) *UserDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*UserClient) GetX ¶
func (c *UserClient) GetX(ctx context.Context, id int) *User
GetX is like Get, but panics if an error occurs.
func (*UserClient) Intercept ¶
func (c *UserClient) Intercept(interceptors ...Interceptor)
Use adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `user.Intercept(f(g(h())))`.
func (*UserClient) Interceptors ¶
func (c *UserClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*UserClient) Query ¶
func (c *UserClient) Query() *UserQuery
Query returns a query builder for User.
func (*UserClient) QueryAssignee ¶
func (c *UserClient) QueryAssignee(u *User) *EpicQuery
QueryAssignee queries the assignee edge of a User.
func (*UserClient) QueryComments ¶
func (c *UserClient) QueryComments(u *User) *CommentQuery
QueryComments queries the comments edge of a User.
func (*UserClient) QueryOwns ¶
func (c *UserClient) QueryOwns(u *User) *ProjectQuery
QueryOwns queries the owns edge of a User.
func (*UserClient) QueryReporter ¶
func (c *UserClient) QueryReporter(u *User) *EpicQuery
QueryReporter queries the reporter edge of a User.
func (*UserClient) Update ¶
func (c *UserClient) Update() *UserUpdate
Update returns an update builder for User.
func (*UserClient) UpdateOne ¶
func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
UpdateOne returns an update builder for the given entity.
func (*UserClient) UpdateOneID ¶
func (c *UserClient) UpdateOneID(id int) *UserUpdateOne
UpdateOneID returns an update builder for the given id.
func (*UserClient) Use ¶
func (c *UserClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `user.Hooks(f(g(h())))`.
type UserConnection ¶
type UserConnection struct { Edges []*UserEdge `json:"edges"` PageInfo PageInfo `json:"pageInfo"` TotalCount int `json:"totalCount"` }
UserConnection is the connection containing edges to User.
type UserCreate ¶
type UserCreate struct {
// contains filtered or unexported fields
}
UserCreate is the builder for creating a User entity.
func (*UserCreate) AddAssignee ¶
func (uc *UserCreate) AddAssignee(e ...*Epic) *UserCreate
AddAssignee adds the "assignee" edges to the Epic entity.
func (*UserCreate) AddAssigneeIDs ¶
func (uc *UserCreate) AddAssigneeIDs(ids ...int) *UserCreate
AddAssigneeIDs adds the "assignee" edge to the Epic entity by IDs.
func (*UserCreate) AddCommentIDs ¶
func (uc *UserCreate) AddCommentIDs(ids ...int) *UserCreate
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*UserCreate) AddComments ¶
func (uc *UserCreate) AddComments(c ...*Comment) *UserCreate
AddComments adds the "comments" edges to the Comment entity.
func (*UserCreate) AddOwnIDs ¶
func (uc *UserCreate) AddOwnIDs(ids ...int) *UserCreate
AddOwnIDs adds the "owns" edge to the Project entity by IDs.
func (*UserCreate) AddOwns ¶
func (uc *UserCreate) AddOwns(p ...*Project) *UserCreate
AddOwns adds the "owns" edges to the Project entity.
func (*UserCreate) AddReporter ¶
func (uc *UserCreate) AddReporter(e ...*Epic) *UserCreate
AddReporter adds the "reporter" edges to the Epic entity.
func (*UserCreate) AddReporterIDs ¶
func (uc *UserCreate) AddReporterIDs(ids ...int) *UserCreate
AddReporterIDs adds the "reporter" edge to the Epic entity by IDs.
func (*UserCreate) Exec ¶
func (uc *UserCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*UserCreate) ExecX ¶
func (uc *UserCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserCreate) Mutation ¶
func (uc *UserCreate) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserCreate) Save ¶
func (uc *UserCreate) Save(ctx context.Context) (*User, error)
Save creates the User in the database.
func (*UserCreate) SaveX ¶
func (uc *UserCreate) SaveX(ctx context.Context) *User
SaveX calls Save and panics if Save returns an error.
func (*UserCreate) SetEmail ¶
func (uc *UserCreate) SetEmail(s string) *UserCreate
SetEmail sets the "email" field.
func (*UserCreate) SetInput ¶
func (c *UserCreate) SetInput(i CreateUserInput) *UserCreate
SetInput applies the change-set in the CreateUserInput on the UserCreate builder.
func (*UserCreate) SetName ¶
func (uc *UserCreate) SetName(s string) *UserCreate
SetName sets the "name" field.
func (*UserCreate) SetSurname ¶
func (uc *UserCreate) SetSurname(s string) *UserCreate
SetSurname sets the "surname" field.
func (*UserCreate) SetUsername ¶
func (uc *UserCreate) SetUsername(s string) *UserCreate
SetUsername sets the "username" field.
type UserCreateBulk ¶
type UserCreateBulk struct {
// contains filtered or unexported fields
}
UserCreateBulk is the builder for creating many User entities in bulk.
func (*UserCreateBulk) Exec ¶
func (ucb *UserCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*UserCreateBulk) ExecX ¶
func (ucb *UserCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type UserDelete ¶
type UserDelete struct {
// contains filtered or unexported fields
}
UserDelete is the builder for deleting a User entity.
func (*UserDelete) Exec ¶
func (ud *UserDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*UserDelete) ExecX ¶
func (ud *UserDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*UserDelete) Where ¶
func (ud *UserDelete) Where(ps ...predicate.User) *UserDelete
Where appends a list predicates to the UserDelete builder.
type UserDeleteOne ¶
type UserDeleteOne struct {
// contains filtered or unexported fields
}
UserDeleteOne is the builder for deleting a single User entity.
func (*UserDeleteOne) Exec ¶
func (udo *UserDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*UserDeleteOne) ExecX ¶
func (udo *UserDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type UserEdges ¶
type UserEdges struct { // Owns holds the value of the owns edge. Owns []*Project `json:"owns,omitempty"` // Reporter holds the value of the reporter edge. Reporter []*Epic `json:"reporter,omitempty"` // Assignee holds the value of the assignee edge. Assignee []*Epic `json:"assignee,omitempty"` // Comments holds the value of the comments edge. Comments []*Comment `json:"comments,omitempty"` // contains filtered or unexported fields }
UserEdges holds the relations/edges for other nodes in the graph.
func (UserEdges) AssigneeOrErr ¶
AssigneeOrErr returns the Assignee value or an error if the edge was not loaded in eager-loading.
func (UserEdges) CommentsOrErr ¶
CommentsOrErr returns the Comments value or an error if the edge was not loaded in eager-loading.
func (UserEdges) OwnsOrErr ¶
OwnsOrErr returns the Owns value or an error if the edge was not loaded in eager-loading.
func (UserEdges) ReporterOrErr ¶
ReporterOrErr returns the Reporter value or an error if the edge was not loaded in eager-loading.
type UserGroupBy ¶
type UserGroupBy struct {
// contains filtered or unexported fields
}
UserGroupBy is the group-by builder for User entities.
func (*UserGroupBy) Aggregate ¶
func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*UserGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Scan ¶
func (ugb *UserGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*UserGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type UserMutation ¶
type UserMutation struct {
// contains filtered or unexported fields
}
UserMutation represents an operation that mutates the User nodes in the graph.
func (*UserMutation) AddAssigneeIDs ¶
func (m *UserMutation) AddAssigneeIDs(ids ...int)
AddAssigneeIDs adds the "assignee" edge to the Epic entity by ids.
func (*UserMutation) AddCommentIDs ¶
func (m *UserMutation) AddCommentIDs(ids ...int)
AddCommentIDs adds the "comments" edge to the Comment entity by ids.
func (*UserMutation) AddField ¶
func (m *UserMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UserMutation) AddOwnIDs ¶
func (m *UserMutation) AddOwnIDs(ids ...int)
AddOwnIDs adds the "owns" edge to the Project entity by ids.
func (*UserMutation) AddReporterIDs ¶
func (m *UserMutation) AddReporterIDs(ids ...int)
AddReporterIDs adds the "reporter" edge to the Epic entity by ids.
func (*UserMutation) AddedEdges ¶
func (m *UserMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*UserMutation) AddedField ¶
func (m *UserMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UserMutation) AddedFields ¶
func (m *UserMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*UserMutation) AddedIDs ¶
func (m *UserMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*UserMutation) AssigneeCleared ¶
func (m *UserMutation) AssigneeCleared() bool
AssigneeCleared reports if the "assignee" edge to the Epic entity was cleared.
func (*UserMutation) AssigneeIDs ¶
func (m *UserMutation) AssigneeIDs() (ids []int)
AssigneeIDs returns the "assignee" edge IDs in the mutation.
func (*UserMutation) ClearAssignee ¶
func (m *UserMutation) ClearAssignee()
ClearAssignee clears the "assignee" edge to the Epic entity.
func (*UserMutation) ClearComments ¶
func (m *UserMutation) ClearComments()
ClearComments clears the "comments" edge to the Comment entity.
func (*UserMutation) ClearEdge ¶
func (m *UserMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*UserMutation) ClearField ¶
func (m *UserMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ClearOwns ¶
func (m *UserMutation) ClearOwns()
ClearOwns clears the "owns" edge to the Project entity.
func (*UserMutation) ClearReporter ¶
func (m *UserMutation) ClearReporter()
ClearReporter clears the "reporter" edge to the Epic entity.
func (*UserMutation) ClearedEdges ¶
func (m *UserMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*UserMutation) ClearedFields ¶
func (m *UserMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (UserMutation) Client ¶
func (m UserMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*UserMutation) CommentsCleared ¶
func (m *UserMutation) CommentsCleared() bool
CommentsCleared reports if the "comments" edge to the Comment entity was cleared.
func (*UserMutation) CommentsIDs ¶
func (m *UserMutation) CommentsIDs() (ids []int)
CommentsIDs returns the "comments" edge IDs in the mutation.
func (*UserMutation) EdgeCleared ¶
func (m *UserMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*UserMutation) Email ¶
func (m *UserMutation) Email() (r string, exists bool)
Email returns the value of the "email" field in the mutation.
func (*UserMutation) Field ¶
func (m *UserMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UserMutation) FieldCleared ¶
func (m *UserMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*UserMutation) Fields ¶
func (m *UserMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*UserMutation) ID ¶
func (m *UserMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*UserMutation) IDs ¶
func (m *UserMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*UserMutation) Name ¶
func (m *UserMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*UserMutation) OldEmail ¶
func (m *UserMutation) OldEmail(ctx context.Context) (v string, err error)
OldEmail returns the old "email" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*UserMutation) OldName ¶
func (m *UserMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldSurname ¶
func (m *UserMutation) OldSurname(ctx context.Context) (v string, err error)
OldSurname returns the old "surname" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldUsername ¶
func (m *UserMutation) OldUsername(ctx context.Context) (v string, err error)
OldUsername returns the old "username" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OwnsCleared ¶
func (m *UserMutation) OwnsCleared() bool
OwnsCleared reports if the "owns" edge to the Project entity was cleared.
func (*UserMutation) OwnsIDs ¶
func (m *UserMutation) OwnsIDs() (ids []int)
OwnsIDs returns the "owns" edge IDs in the mutation.
func (*UserMutation) RemoveAssigneeIDs ¶
func (m *UserMutation) RemoveAssigneeIDs(ids ...int)
RemoveAssigneeIDs removes the "assignee" edge to the Epic entity by IDs.
func (*UserMutation) RemoveCommentIDs ¶
func (m *UserMutation) RemoveCommentIDs(ids ...int)
RemoveCommentIDs removes the "comments" edge to the Comment entity by IDs.
func (*UserMutation) RemoveOwnIDs ¶
func (m *UserMutation) RemoveOwnIDs(ids ...int)
RemoveOwnIDs removes the "owns" edge to the Project entity by IDs.
func (*UserMutation) RemoveReporterIDs ¶
func (m *UserMutation) RemoveReporterIDs(ids ...int)
RemoveReporterIDs removes the "reporter" edge to the Epic entity by IDs.
func (*UserMutation) RemovedAssigneeIDs ¶
func (m *UserMutation) RemovedAssigneeIDs() (ids []int)
RemovedAssignee returns the removed IDs of the "assignee" edge to the Epic entity.
func (*UserMutation) RemovedCommentsIDs ¶
func (m *UserMutation) RemovedCommentsIDs() (ids []int)
RemovedComments returns the removed IDs of the "comments" edge to the Comment entity.
func (*UserMutation) RemovedEdges ¶
func (m *UserMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*UserMutation) RemovedIDs ¶
func (m *UserMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*UserMutation) RemovedOwnsIDs ¶
func (m *UserMutation) RemovedOwnsIDs() (ids []int)
RemovedOwns returns the removed IDs of the "owns" edge to the Project entity.
func (*UserMutation) RemovedReporterIDs ¶
func (m *UserMutation) RemovedReporterIDs() (ids []int)
RemovedReporter returns the removed IDs of the "reporter" edge to the Epic entity.
func (*UserMutation) ReporterCleared ¶
func (m *UserMutation) ReporterCleared() bool
ReporterCleared reports if the "reporter" edge to the Epic entity was cleared.
func (*UserMutation) ReporterIDs ¶
func (m *UserMutation) ReporterIDs() (ids []int)
ReporterIDs returns the "reporter" edge IDs in the mutation.
func (*UserMutation) ResetAssignee ¶
func (m *UserMutation) ResetAssignee()
ResetAssignee resets all changes to the "assignee" edge.
func (*UserMutation) ResetComments ¶
func (m *UserMutation) ResetComments()
ResetComments resets all changes to the "comments" edge.
func (*UserMutation) ResetEdge ¶
func (m *UserMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*UserMutation) ResetEmail ¶
func (m *UserMutation) ResetEmail()
ResetEmail resets all changes to the "email" field.
func (*UserMutation) ResetField ¶
func (m *UserMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ResetName ¶
func (m *UserMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*UserMutation) ResetOwns ¶
func (m *UserMutation) ResetOwns()
ResetOwns resets all changes to the "owns" edge.
func (*UserMutation) ResetReporter ¶
func (m *UserMutation) ResetReporter()
ResetReporter resets all changes to the "reporter" edge.
func (*UserMutation) ResetSurname ¶
func (m *UserMutation) ResetSurname()
ResetSurname resets all changes to the "surname" field.
func (*UserMutation) ResetUsername ¶
func (m *UserMutation) ResetUsername()
ResetUsername resets all changes to the "username" field.
func (*UserMutation) SetEmail ¶
func (m *UserMutation) SetEmail(s string)
SetEmail sets the "email" field.
func (*UserMutation) SetField ¶
func (m *UserMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UserMutation) SetName ¶
func (m *UserMutation) SetName(s string)
SetName sets the "name" field.
func (*UserMutation) SetOp ¶
func (m *UserMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*UserMutation) SetSurname ¶
func (m *UserMutation) SetSurname(s string)
SetSurname sets the "surname" field.
func (*UserMutation) SetUsername ¶
func (m *UserMutation) SetUsername(s string)
SetUsername sets the "username" field.
func (*UserMutation) Surname ¶
func (m *UserMutation) Surname() (r string, exists bool)
Surname returns the value of the "surname" field in the mutation.
func (UserMutation) Tx ¶
func (m UserMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*UserMutation) Type ¶
func (m *UserMutation) Type() string
Type returns the node type of this mutation (User).
func (*UserMutation) Username ¶
func (m *UserMutation) Username() (r string, exists bool)
Username returns the value of the "username" field in the mutation.
func (*UserMutation) Where ¶
func (m *UserMutation) Where(ps ...predicate.User)
Where appends a list predicates to the UserMutation builder.
func (*UserMutation) WhereP ¶
func (m *UserMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the UserMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type UserOrder ¶
type UserOrder struct { Direction OrderDirection `json:"direction"` Field *UserOrderField `json:"field"` }
UserOrder defines the ordering of User.
type UserOrderField ¶
type UserOrderField struct {
// contains filtered or unexported fields
}
UserOrderField defines the ordering field of User.
type UserPaginateOption ¶
type UserPaginateOption func(*userPager) error
UserPaginateOption enables pagination customization.
func WithUserFilter ¶
func WithUserFilter(filter func(*UserQuery) (*UserQuery, error)) UserPaginateOption
WithUserFilter configures pagination filter.
func WithUserOrder ¶
func WithUserOrder(order *UserOrder) UserPaginateOption
WithUserOrder configures pagination ordering.
type UserQuery ¶
type UserQuery struct {
// contains filtered or unexported fields
}
UserQuery is the builder for querying User entities.
func (*UserQuery) Aggregate ¶
func (uq *UserQuery) Aggregate(fns ...AggregateFunc) *UserSelect
Aggregate returns a UserSelect configured with the given aggregations.
func (*UserQuery) Clone ¶
Clone returns a duplicate of the UserQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*UserQuery) CollectFields ¶
CollectFields tells the query-builder to eagerly load connected nodes by resolver context.
func (*UserQuery) First ¶
First returns the first User entity from the query. Returns a *NotFoundError when no User was found.
func (*UserQuery) FirstID ¶
FirstID returns the first User ID from the query. Returns a *NotFoundError when no User ID was found.
func (*UserQuery) GroupBy ¶
func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Name string `json:"name,omitempty"` Count int `json:"count,omitempty"` } client.User.Query(). GroupBy(user.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*UserQuery) Only ¶
Only returns a single User entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one User entity is found. Returns a *NotFoundError when no User entities are found.
func (*UserQuery) OnlyID ¶
OnlyID is like Only, but returns the only User ID in the query. Returns a *NotSingularError when more than one User ID is found. Returns a *NotFoundError when no entities are found.
func (*UserQuery) Paginate ¶
func (u *UserQuery) Paginate( ctx context.Context, after *Cursor, first *int, before *Cursor, last *int, opts ...UserPaginateOption, ) (*UserConnection, error)
Paginate executes the query and returns a relay based cursor connection to User.
func (*UserQuery) QueryAssignee ¶
QueryAssignee chains the current query on the "assignee" edge.
func (*UserQuery) QueryComments ¶
func (uq *UserQuery) QueryComments() *CommentQuery
QueryComments chains the current query on the "comments" edge.
func (*UserQuery) QueryOwns ¶
func (uq *UserQuery) QueryOwns() *ProjectQuery
QueryOwns chains the current query on the "owns" edge.
func (*UserQuery) QueryReporter ¶
QueryReporter chains the current query on the "reporter" edge.
func (*UserQuery) Select ¶
func (uq *UserQuery) Select(fields ...string) *UserSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.User.Query(). Select(user.FieldName). Scan(ctx, &v)
func (*UserQuery) Unique ¶
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*UserQuery) WithAssignee ¶
WithAssignee tells the query-builder to eager-load the nodes that are connected to the "assignee" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithComments ¶
func (uq *UserQuery) WithComments(opts ...func(*CommentQuery)) *UserQuery
WithComments tells the query-builder to eager-load the nodes that are connected to the "comments" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithNamedAssignee ¶
WithNamedAssignee tells the query-builder to eager-load the nodes that are connected to the "assignee" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithNamedComments ¶
func (uq *UserQuery) WithNamedComments(name string, opts ...func(*CommentQuery)) *UserQuery
WithNamedComments tells the query-builder to eager-load the nodes that are connected to the "comments" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithNamedOwns ¶
func (uq *UserQuery) WithNamedOwns(name string, opts ...func(*ProjectQuery)) *UserQuery
WithNamedOwns tells the query-builder to eager-load the nodes that are connected to the "owns" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithNamedReporter ¶
WithNamedReporter tells the query-builder to eager-load the nodes that are connected to the "reporter" edge with the given name. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithOwns ¶
func (uq *UserQuery) WithOwns(opts ...func(*ProjectQuery)) *UserQuery
WithOwns tells the query-builder to eager-load the nodes that are connected to the "owns" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithReporter ¶
WithReporter tells the query-builder to eager-load the nodes that are connected to the "reporter" edge. The optional arguments are used to configure the query builder of the edge.
type UserSelect ¶
type UserSelect struct { *UserQuery // contains filtered or unexported fields }
UserSelect is the builder for selecting fields of User entities.
func (*UserSelect) Aggregate ¶
func (us *UserSelect) Aggregate(fns ...AggregateFunc) *UserSelect
Aggregate adds the given aggregation functions to the selector query.
func (*UserSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*UserSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*UserSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*UserSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*UserSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*UserSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*UserSelect) Scan ¶
func (us *UserSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*UserSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type UserUpdate ¶
type UserUpdate struct {
// contains filtered or unexported fields
}
UserUpdate is the builder for updating User entities.
func (*UserUpdate) AddAssignee ¶
func (uu *UserUpdate) AddAssignee(e ...*Epic) *UserUpdate
AddAssignee adds the "assignee" edges to the Epic entity.
func (*UserUpdate) AddAssigneeIDs ¶
func (uu *UserUpdate) AddAssigneeIDs(ids ...int) *UserUpdate
AddAssigneeIDs adds the "assignee" edge to the Epic entity by IDs.
func (*UserUpdate) AddCommentIDs ¶
func (uu *UserUpdate) AddCommentIDs(ids ...int) *UserUpdate
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*UserUpdate) AddComments ¶
func (uu *UserUpdate) AddComments(c ...*Comment) *UserUpdate
AddComments adds the "comments" edges to the Comment entity.
func (*UserUpdate) AddOwnIDs ¶
func (uu *UserUpdate) AddOwnIDs(ids ...int) *UserUpdate
AddOwnIDs adds the "owns" edge to the Project entity by IDs.
func (*UserUpdate) AddOwns ¶
func (uu *UserUpdate) AddOwns(p ...*Project) *UserUpdate
AddOwns adds the "owns" edges to the Project entity.
func (*UserUpdate) AddReporter ¶
func (uu *UserUpdate) AddReporter(e ...*Epic) *UserUpdate
AddReporter adds the "reporter" edges to the Epic entity.
func (*UserUpdate) AddReporterIDs ¶
func (uu *UserUpdate) AddReporterIDs(ids ...int) *UserUpdate
AddReporterIDs adds the "reporter" edge to the Epic entity by IDs.
func (*UserUpdate) ClearAssignee ¶
func (uu *UserUpdate) ClearAssignee() *UserUpdate
ClearAssignee clears all "assignee" edges to the Epic entity.
func (*UserUpdate) ClearComments ¶
func (uu *UserUpdate) ClearComments() *UserUpdate
ClearComments clears all "comments" edges to the Comment entity.
func (*UserUpdate) ClearOwns ¶
func (uu *UserUpdate) ClearOwns() *UserUpdate
ClearOwns clears all "owns" edges to the Project entity.
func (*UserUpdate) ClearReporter ¶
func (uu *UserUpdate) ClearReporter() *UserUpdate
ClearReporter clears all "reporter" edges to the Epic entity.
func (*UserUpdate) Exec ¶
func (uu *UserUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpdate) ExecX ¶
func (uu *UserUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpdate) Mutation ¶
func (uu *UserUpdate) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserUpdate) RemoveAssignee ¶
func (uu *UserUpdate) RemoveAssignee(e ...*Epic) *UserUpdate
RemoveAssignee removes "assignee" edges to Epic entities.
func (*UserUpdate) RemoveAssigneeIDs ¶
func (uu *UserUpdate) RemoveAssigneeIDs(ids ...int) *UserUpdate
RemoveAssigneeIDs removes the "assignee" edge to Epic entities by IDs.
func (*UserUpdate) RemoveCommentIDs ¶
func (uu *UserUpdate) RemoveCommentIDs(ids ...int) *UserUpdate
RemoveCommentIDs removes the "comments" edge to Comment entities by IDs.
func (*UserUpdate) RemoveComments ¶
func (uu *UserUpdate) RemoveComments(c ...*Comment) *UserUpdate
RemoveComments removes "comments" edges to Comment entities.
func (*UserUpdate) RemoveOwnIDs ¶
func (uu *UserUpdate) RemoveOwnIDs(ids ...int) *UserUpdate
RemoveOwnIDs removes the "owns" edge to Project entities by IDs.
func (*UserUpdate) RemoveOwns ¶
func (uu *UserUpdate) RemoveOwns(p ...*Project) *UserUpdate
RemoveOwns removes "owns" edges to Project entities.
func (*UserUpdate) RemoveReporter ¶
func (uu *UserUpdate) RemoveReporter(e ...*Epic) *UserUpdate
RemoveReporter removes "reporter" edges to Epic entities.
func (*UserUpdate) RemoveReporterIDs ¶
func (uu *UserUpdate) RemoveReporterIDs(ids ...int) *UserUpdate
RemoveReporterIDs removes the "reporter" edge to Epic entities by IDs.
func (*UserUpdate) Save ¶
func (uu *UserUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*UserUpdate) SaveX ¶
func (uu *UserUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*UserUpdate) SetEmail ¶
func (uu *UserUpdate) SetEmail(s string) *UserUpdate
SetEmail sets the "email" field.
func (*UserUpdate) SetInput ¶
func (c *UserUpdate) SetInput(i UpdateUserInput) *UserUpdate
SetInput applies the change-set in the UpdateUserInput on the UserUpdate builder.
func (*UserUpdate) SetName ¶
func (uu *UserUpdate) SetName(s string) *UserUpdate
SetName sets the "name" field.
func (*UserUpdate) SetSurname ¶
func (uu *UserUpdate) SetSurname(s string) *UserUpdate
SetSurname sets the "surname" field.
func (*UserUpdate) SetUsername ¶
func (uu *UserUpdate) SetUsername(s string) *UserUpdate
SetUsername sets the "username" field.
func (*UserUpdate) Where ¶
func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
Where appends a list predicates to the UserUpdate builder.
type UserUpdateOne ¶
type UserUpdateOne struct {
// contains filtered or unexported fields
}
UserUpdateOne is the builder for updating a single User entity.
func (*UserUpdateOne) AddAssignee ¶
func (uuo *UserUpdateOne) AddAssignee(e ...*Epic) *UserUpdateOne
AddAssignee adds the "assignee" edges to the Epic entity.
func (*UserUpdateOne) AddAssigneeIDs ¶
func (uuo *UserUpdateOne) AddAssigneeIDs(ids ...int) *UserUpdateOne
AddAssigneeIDs adds the "assignee" edge to the Epic entity by IDs.
func (*UserUpdateOne) AddCommentIDs ¶
func (uuo *UserUpdateOne) AddCommentIDs(ids ...int) *UserUpdateOne
AddCommentIDs adds the "comments" edge to the Comment entity by IDs.
func (*UserUpdateOne) AddComments ¶
func (uuo *UserUpdateOne) AddComments(c ...*Comment) *UserUpdateOne
AddComments adds the "comments" edges to the Comment entity.
func (*UserUpdateOne) AddOwnIDs ¶
func (uuo *UserUpdateOne) AddOwnIDs(ids ...int) *UserUpdateOne
AddOwnIDs adds the "owns" edge to the Project entity by IDs.
func (*UserUpdateOne) AddOwns ¶
func (uuo *UserUpdateOne) AddOwns(p ...*Project) *UserUpdateOne
AddOwns adds the "owns" edges to the Project entity.
func (*UserUpdateOne) AddReporter ¶
func (uuo *UserUpdateOne) AddReporter(e ...*Epic) *UserUpdateOne
AddReporter adds the "reporter" edges to the Epic entity.
func (*UserUpdateOne) AddReporterIDs ¶
func (uuo *UserUpdateOne) AddReporterIDs(ids ...int) *UserUpdateOne
AddReporterIDs adds the "reporter" edge to the Epic entity by IDs.
func (*UserUpdateOne) ClearAssignee ¶
func (uuo *UserUpdateOne) ClearAssignee() *UserUpdateOne
ClearAssignee clears all "assignee" edges to the Epic entity.
func (*UserUpdateOne) ClearComments ¶
func (uuo *UserUpdateOne) ClearComments() *UserUpdateOne
ClearComments clears all "comments" edges to the Comment entity.
func (*UserUpdateOne) ClearOwns ¶
func (uuo *UserUpdateOne) ClearOwns() *UserUpdateOne
ClearOwns clears all "owns" edges to the Project entity.
func (*UserUpdateOne) ClearReporter ¶
func (uuo *UserUpdateOne) ClearReporter() *UserUpdateOne
ClearReporter clears all "reporter" edges to the Epic entity.
func (*UserUpdateOne) Exec ¶
func (uuo *UserUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*UserUpdateOne) ExecX ¶
func (uuo *UserUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpdateOne) Mutation ¶
func (uuo *UserUpdateOne) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserUpdateOne) RemoveAssignee ¶
func (uuo *UserUpdateOne) RemoveAssignee(e ...*Epic) *UserUpdateOne
RemoveAssignee removes "assignee" edges to Epic entities.
func (*UserUpdateOne) RemoveAssigneeIDs ¶
func (uuo *UserUpdateOne) RemoveAssigneeIDs(ids ...int) *UserUpdateOne
RemoveAssigneeIDs removes the "assignee" edge to Epic entities by IDs.
func (*UserUpdateOne) RemoveCommentIDs ¶
func (uuo *UserUpdateOne) RemoveCommentIDs(ids ...int) *UserUpdateOne
RemoveCommentIDs removes the "comments" edge to Comment entities by IDs.
func (*UserUpdateOne) RemoveComments ¶
func (uuo *UserUpdateOne) RemoveComments(c ...*Comment) *UserUpdateOne
RemoveComments removes "comments" edges to Comment entities.
func (*UserUpdateOne) RemoveOwnIDs ¶
func (uuo *UserUpdateOne) RemoveOwnIDs(ids ...int) *UserUpdateOne
RemoveOwnIDs removes the "owns" edge to Project entities by IDs.
func (*UserUpdateOne) RemoveOwns ¶
func (uuo *UserUpdateOne) RemoveOwns(p ...*Project) *UserUpdateOne
RemoveOwns removes "owns" edges to Project entities.
func (*UserUpdateOne) RemoveReporter ¶
func (uuo *UserUpdateOne) RemoveReporter(e ...*Epic) *UserUpdateOne
RemoveReporter removes "reporter" edges to Epic entities.
func (*UserUpdateOne) RemoveReporterIDs ¶
func (uuo *UserUpdateOne) RemoveReporterIDs(ids ...int) *UserUpdateOne
RemoveReporterIDs removes the "reporter" edge to Epic entities by IDs.
func (*UserUpdateOne) Save ¶
func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
Save executes the query and returns the updated User entity.
func (*UserUpdateOne) SaveX ¶
func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
SaveX is like Save, but panics if an error occurs.
func (*UserUpdateOne) Select ¶
func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*UserUpdateOne) SetEmail ¶
func (uuo *UserUpdateOne) SetEmail(s string) *UserUpdateOne
SetEmail sets the "email" field.
func (*UserUpdateOne) SetInput ¶
func (c *UserUpdateOne) SetInput(i UpdateUserInput) *UserUpdateOne
SetInput applies the change-set in the UpdateUserInput on the UserUpdateOne builder.
func (*UserUpdateOne) SetName ¶
func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne
SetName sets the "name" field.
func (*UserUpdateOne) SetSurname ¶
func (uuo *UserUpdateOne) SetSurname(s string) *UserUpdateOne
SetSurname sets the "surname" field.
func (*UserUpdateOne) SetUsername ¶
func (uuo *UserUpdateOne) SetUsername(s string) *UserUpdateOne
SetUsername sets the "username" field.
type UserWhereInput ¶
type UserWhereInput struct { Predicates []predicate.User `json:"-"` Not *UserWhereInput `json:"not,omitempty"` Or []*UserWhereInput `json:"or,omitempty"` And []*UserWhereInput `json:"and,omitempty"` // "id" field predicates. ID *int `json:"id,omitempty"` IDNEQ *int `json:"idNEQ,omitempty"` IDIn []int `json:"idIn,omitempty"` IDNotIn []int `json:"idNotIn,omitempty"` IDGT *int `json:"idGT,omitempty"` IDGTE *int `json:"idGTE,omitempty"` IDLT *int `json:"idLT,omitempty"` IDLTE *int `json:"idLTE,omitempty"` // "name" field predicates. Name *string `json:"name,omitempty"` NameNEQ *string `json:"nameNEQ,omitempty"` NameIn []string `json:"nameIn,omitempty"` NameNotIn []string `json:"nameNotIn,omitempty"` NameGT *string `json:"nameGT,omitempty"` NameGTE *string `json:"nameGTE,omitempty"` NameLT *string `json:"nameLT,omitempty"` NameLTE *string `json:"nameLTE,omitempty"` NameContains *string `json:"nameContains,omitempty"` NameHasPrefix *string `json:"nameHasPrefix,omitempty"` NameHasSuffix *string `json:"nameHasSuffix,omitempty"` NameEqualFold *string `json:"nameEqualFold,omitempty"` NameContainsFold *string `json:"nameContainsFold,omitempty"` // "surname" field predicates. Surname *string `json:"surname,omitempty"` SurnameNEQ *string `json:"surnameNEQ,omitempty"` SurnameIn []string `json:"surnameIn,omitempty"` SurnameNotIn []string `json:"surnameNotIn,omitempty"` SurnameGT *string `json:"surnameGT,omitempty"` SurnameGTE *string `json:"surnameGTE,omitempty"` SurnameLT *string `json:"surnameLT,omitempty"` SurnameLTE *string `json:"surnameLTE,omitempty"` SurnameContains *string `json:"surnameContains,omitempty"` SurnameHasPrefix *string `json:"surnameHasPrefix,omitempty"` SurnameHasSuffix *string `json:"surnameHasSuffix,omitempty"` SurnameEqualFold *string `json:"surnameEqualFold,omitempty"` SurnameContainsFold *string `json:"surnameContainsFold,omitempty"` // "username" field predicates. Username *string `json:"username,omitempty"` UsernameNEQ *string `json:"usernameNEQ,omitempty"` UsernameIn []string `json:"usernameIn,omitempty"` UsernameNotIn []string `json:"usernameNotIn,omitempty"` UsernameGT *string `json:"usernameGT,omitempty"` UsernameGTE *string `json:"usernameGTE,omitempty"` UsernameLT *string `json:"usernameLT,omitempty"` UsernameLTE *string `json:"usernameLTE,omitempty"` UsernameContains *string `json:"usernameContains,omitempty"` UsernameHasPrefix *string `json:"usernameHasPrefix,omitempty"` UsernameHasSuffix *string `json:"usernameHasSuffix,omitempty"` UsernameEqualFold *string `json:"usernameEqualFold,omitempty"` UsernameContainsFold *string `json:"usernameContainsFold,omitempty"` // "email" field predicates. Email *string `json:"email,omitempty"` EmailNEQ *string `json:"emailNEQ,omitempty"` EmailIn []string `json:"emailIn,omitempty"` EmailNotIn []string `json:"emailNotIn,omitempty"` EmailGT *string `json:"emailGT,omitempty"` EmailGTE *string `json:"emailGTE,omitempty"` EmailLT *string `json:"emailLT,omitempty"` EmailLTE *string `json:"emailLTE,omitempty"` EmailContains *string `json:"emailContains,omitempty"` EmailHasPrefix *string `json:"emailHasPrefix,omitempty"` EmailHasSuffix *string `json:"emailHasSuffix,omitempty"` EmailEqualFold *string `json:"emailEqualFold,omitempty"` EmailContainsFold *string `json:"emailContainsFold,omitempty"` // "owns" edge predicates. HasOwns *bool `json:"hasOwns,omitempty"` HasOwnsWith []*ProjectWhereInput `json:"hasOwnsWith,omitempty"` // "reporter" edge predicates. HasReporter *bool `json:"hasReporter,omitempty"` HasReporterWith []*EpicWhereInput `json:"hasReporterWith,omitempty"` // "assignee" edge predicates. HasAssignee *bool `json:"hasAssignee,omitempty"` HasAssigneeWith []*EpicWhereInput `json:"hasAssigneeWith,omitempty"` // "comments" edge predicates. HasComments *bool `json:"hasComments,omitempty"` HasCommentsWith []*CommentWhereInput `json:"hasCommentsWith,omitempty"` }
UserWhereInput represents a where input for filtering User queries.
func (*UserWhereInput) AddPredicates ¶
func (i *UserWhereInput) AddPredicates(predicates ...predicate.User)
AddPredicates adds custom predicates to the where input to be used during the filtering phase.
type ValidationError ¶
type ValidationError struct { Name string // Field or edge name. // contains filtered or unexported fields }
ValidationError returns when validating a field or edge fails.
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
Error implements the error interface.
func (*ValidationError) Unwrap ¶
func (e *ValidationError) Unwrap() error
Unwrap implements the errors.Wrapper interface.
Source Files ¶
- client.go
- comment.go
- comment_create.go
- comment_delete.go
- comment_query.go
- comment_update.go
- config.go
- context.go
- ent.go
- epic.go
- epic_create.go
- epic_delete.go
- epic_query.go
- epic_update.go
- gql_collection.go
- gql_edge.go
- gql_mutation_input.go
- gql_node.go
- gql_pagination.go
- gql_transaction.go
- gql_where_input.go
- mutation.go
- project.go
- project_create.go
- project_delete.go
- project_query.go
- project_update.go
- runtime.go
- tx.go
- user.go
- user_create.go
- user_delete.go
- user_query.go
- user_update.go