Documentation ¶
Index ¶
- Constants
- 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
- type AggregateFunc
- type Card
- type CardClient
- func (c *CardClient) Create() *CardCreate
- func (c *CardClient) CreateBulk(builders ...*CardCreate) *CardCreateBulk
- func (c *CardClient) Delete() *CardDelete
- func (c *CardClient) DeleteOne(ca *Card) *CardDeleteOne
- func (c *CardClient) DeleteOneID(id string) *CardDeleteOne
- func (c *CardClient) Get(ctx context.Context, id string) (*Card, error)
- func (c *CardClient) GetX(ctx context.Context, id string) *Card
- func (c *CardClient) Hooks() []Hook
- func (c *CardClient) Query() *CardQuery
- func (c *CardClient) QueryOwner(ca *Card) *UserQuery
- func (c *CardClient) QuerySpec(ca *Card) *SpecQuery
- func (c *CardClient) Update() *CardUpdate
- func (c *CardClient) UpdateOne(ca *Card) *CardUpdateOne
- func (c *CardClient) UpdateOneID(id string) *CardUpdateOne
- func (c *CardClient) Use(hooks ...Hook)
- type CardCreate
- func (cc *CardCreate) AddSpec(s ...*Spec) *CardCreate
- func (cc *CardCreate) AddSpecIDs(ids ...string) *CardCreate
- func (cc *CardCreate) Mutation() *CardMutation
- func (cc *CardCreate) Save(ctx context.Context) (*Card, error)
- func (cc *CardCreate) SaveX(ctx context.Context) *Card
- func (cc *CardCreate) SetCreateTime(t time.Time) *CardCreate
- func (cc *CardCreate) SetName(s string) *CardCreate
- func (cc *CardCreate) SetNillableCreateTime(t *time.Time) *CardCreate
- func (cc *CardCreate) SetNillableName(s *string) *CardCreate
- func (cc *CardCreate) SetNillableOwnerID(id *string) *CardCreate
- func (cc *CardCreate) SetNillableUpdateTime(t *time.Time) *CardCreate
- func (cc *CardCreate) SetNumber(s string) *CardCreate
- func (cc *CardCreate) SetOwner(u *User) *CardCreate
- func (cc *CardCreate) SetOwnerID(id string) *CardCreate
- func (cc *CardCreate) SetUpdateTime(t time.Time) *CardCreate
- type CardCreateBulk
- type CardDelete
- type CardDeleteOne
- type CardEdges
- type CardExtension
- type CardGroupBy
- func (cgb *CardGroupBy) Aggregate(fns ...AggregateFunc) *CardGroupBy
- func (cgb *CardGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (cgb *CardGroupBy) BoolX(ctx context.Context) bool
- func (cgb *CardGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (cgb *CardGroupBy) BoolsX(ctx context.Context) []bool
- func (cgb *CardGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (cgb *CardGroupBy) Float64X(ctx context.Context) float64
- func (cgb *CardGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (cgb *CardGroupBy) Float64sX(ctx context.Context) []float64
- func (cgb *CardGroupBy) Int(ctx context.Context) (_ int, err error)
- func (cgb *CardGroupBy) IntX(ctx context.Context) int
- func (cgb *CardGroupBy) Ints(ctx context.Context) ([]int, error)
- func (cgb *CardGroupBy) IntsX(ctx context.Context) []int
- func (cgb *CardGroupBy) Scan(ctx context.Context, v interface{}) error
- func (cgb *CardGroupBy) ScanX(ctx context.Context, v interface{})
- func (cgb *CardGroupBy) String(ctx context.Context) (_ string, err error)
- func (cgb *CardGroupBy) StringX(ctx context.Context) string
- func (cgb *CardGroupBy) Strings(ctx context.Context) ([]string, error)
- func (cgb *CardGroupBy) StringsX(ctx context.Context) []string
- type CardMutation
- func (m *CardMutation) AddField(name string, value ent.Value) error
- func (m *CardMutation) AddSpecIDs(ids ...string)
- func (m *CardMutation) AddedEdges() []string
- func (m *CardMutation) AddedField(name string) (ent.Value, bool)
- func (m *CardMutation) AddedFields() []string
- func (m *CardMutation) AddedIDs(name string) []ent.Value
- func (m *CardMutation) ClearEdge(name string) error
- func (m *CardMutation) ClearField(name string) error
- func (m *CardMutation) ClearName()
- func (m *CardMutation) ClearOwner()
- func (m *CardMutation) ClearSpec()
- func (m *CardMutation) ClearedEdges() []string
- func (m *CardMutation) ClearedFields() []string
- func (m CardMutation) Client() *Client
- func (m *CardMutation) CreateTime() (r time.Time, exists bool)
- func (m *CardMutation) EdgeCleared(name string) bool
- func (m *CardMutation) Field(name string) (ent.Value, bool)
- func (m *CardMutation) FieldCleared(name string) bool
- func (m *CardMutation) Fields() []string
- func (m *CardMutation) ID() (id string, exists bool)
- func (m *CardMutation) Name() (r string, exists bool)
- func (m *CardMutation) NameCleared() bool
- func (m *CardMutation) Number() (r string, exists bool)
- func (m *CardMutation) OldCreateTime(ctx context.Context) (v time.Time, err error)
- func (m *CardMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *CardMutation) OldName(ctx context.Context) (v string, err error)
- func (m *CardMutation) OldNumber(ctx context.Context) (v string, err error)
- func (m *CardMutation) OldUpdateTime(ctx context.Context) (v time.Time, err error)
- func (m *CardMutation) Op() Op
- func (m *CardMutation) OwnerCleared() bool
- func (m *CardMutation) OwnerID() (id string, exists bool)
- func (m *CardMutation) OwnerIDs() (ids []string)
- func (m *CardMutation) RemoveSpecIDs(ids ...string)
- func (m *CardMutation) RemovedEdges() []string
- func (m *CardMutation) RemovedIDs(name string) []ent.Value
- func (m *CardMutation) RemovedSpecIDs() (ids []string)
- func (m *CardMutation) ResetCreateTime()
- func (m *CardMutation) ResetEdge(name string) error
- func (m *CardMutation) ResetField(name string) error
- func (m *CardMutation) ResetName()
- func (m *CardMutation) ResetNumber()
- func (m *CardMutation) ResetOwner()
- func (m *CardMutation) ResetSpec()
- func (m *CardMutation) ResetUpdateTime()
- func (m *CardMutation) SetCreateTime(t time.Time)
- func (m *CardMutation) SetField(name string, value ent.Value) error
- func (m *CardMutation) SetName(s string)
- func (m *CardMutation) SetNumber(s string)
- func (m *CardMutation) SetOwnerID(id string)
- func (m *CardMutation) SetUpdateTime(t time.Time)
- func (m *CardMutation) SpecCleared() bool
- func (m *CardMutation) SpecIDs() (ids []string)
- func (m CardMutation) Tx() (*Tx, error)
- func (m *CardMutation) Type() string
- func (m *CardMutation) UpdateTime() (r time.Time, exists bool)
- type CardQuery
- func (cq *CardQuery) All(ctx context.Context) ([]*Card, error)
- func (cq *CardQuery) AllX(ctx context.Context) []*Card
- func (cq *CardQuery) Clone() *CardQuery
- func (cq *CardQuery) Count(ctx context.Context) (int, error)
- func (cq *CardQuery) CountX(ctx context.Context) int
- func (cq *CardQuery) Exist(ctx context.Context) (bool, error)
- func (cq *CardQuery) ExistX(ctx context.Context) bool
- func (cq *CardQuery) First(ctx context.Context) (*Card, error)
- func (cq *CardQuery) FirstID(ctx context.Context) (id string, err error)
- func (cq *CardQuery) FirstIDX(ctx context.Context) string
- func (cq *CardQuery) FirstX(ctx context.Context) *Card
- func (cq *CardQuery) GroupBy(field string, fields ...string) *CardGroupBy
- func (cq *CardQuery) IDs(ctx context.Context) ([]string, error)
- func (cq *CardQuery) IDsX(ctx context.Context) []string
- func (cq *CardQuery) Limit(limit int) *CardQuery
- func (cq *CardQuery) Offset(offset int) *CardQuery
- func (cq *CardQuery) Only(ctx context.Context) (*Card, error)
- func (cq *CardQuery) OnlyID(ctx context.Context) (id string, err error)
- func (cq *CardQuery) OnlyIDX(ctx context.Context) string
- func (cq *CardQuery) OnlyX(ctx context.Context) *Card
- func (cq *CardQuery) Order(o ...OrderFunc) *CardQuery
- func (cq *CardQuery) QueryOwner() *UserQuery
- func (cq *CardQuery) QuerySpec() *SpecQuery
- func (cq *CardQuery) Select(field string, fields ...string) *CardSelect
- func (cq *CardQuery) Where(ps ...predicate.Card) *CardQuery
- func (cq *CardQuery) WithOwner(opts ...func(*UserQuery)) *CardQuery
- func (cq *CardQuery) WithSpec(opts ...func(*SpecQuery)) *CardQuery
- type CardSelect
- func (cs *CardSelect) Bool(ctx context.Context) (_ bool, err error)
- func (cs *CardSelect) BoolX(ctx context.Context) bool
- func (cs *CardSelect) Bools(ctx context.Context) ([]bool, error)
- func (cs *CardSelect) BoolsX(ctx context.Context) []bool
- func (cs *CardSelect) Float64(ctx context.Context) (_ float64, err error)
- func (cs *CardSelect) Float64X(ctx context.Context) float64
- func (cs *CardSelect) Float64s(ctx context.Context) ([]float64, error)
- func (cs *CardSelect) Float64sX(ctx context.Context) []float64
- func (cs *CardSelect) Int(ctx context.Context) (_ int, err error)
- func (cs *CardSelect) IntX(ctx context.Context) int
- func (cs *CardSelect) Ints(ctx context.Context) ([]int, error)
- func (cs *CardSelect) IntsX(ctx context.Context) []int
- func (cs *CardSelect) Scan(ctx context.Context, v interface{}) error
- func (cs *CardSelect) ScanX(ctx context.Context, v interface{})
- func (cs *CardSelect) String(ctx context.Context) (_ string, err error)
- func (cs *CardSelect) StringX(ctx context.Context) string
- func (cs *CardSelect) Strings(ctx context.Context) ([]string, error)
- func (cs *CardSelect) StringsX(ctx context.Context) []string
- type CardUpdate
- func (cu *CardUpdate) AddSpec(s ...*Spec) *CardUpdate
- func (cu *CardUpdate) AddSpecIDs(ids ...string) *CardUpdate
- func (cu *CardUpdate) ClearName() *CardUpdate
- func (cu *CardUpdate) ClearOwner() *CardUpdate
- func (cu *CardUpdate) ClearSpec() *CardUpdate
- func (cu *CardUpdate) Exec(ctx context.Context) error
- func (cu *CardUpdate) ExecX(ctx context.Context)
- func (cu *CardUpdate) Mutation() *CardMutation
- func (cu *CardUpdate) RemoveSpec(s ...*Spec) *CardUpdate
- func (cu *CardUpdate) RemoveSpecIDs(ids ...string) *CardUpdate
- func (cu *CardUpdate) Save(ctx context.Context) (int, error)
- func (cu *CardUpdate) SaveX(ctx context.Context) int
- func (cu *CardUpdate) SetName(s string) *CardUpdate
- func (cu *CardUpdate) SetNillableName(s *string) *CardUpdate
- func (cu *CardUpdate) SetNillableOwnerID(id *string) *CardUpdate
- func (cu *CardUpdate) SetOwner(u *User) *CardUpdate
- func (cu *CardUpdate) SetOwnerID(id string) *CardUpdate
- func (cu *CardUpdate) Where(ps ...predicate.Card) *CardUpdate
- type CardUpdateOne
- func (cuo *CardUpdateOne) AddSpec(s ...*Spec) *CardUpdateOne
- func (cuo *CardUpdateOne) AddSpecIDs(ids ...string) *CardUpdateOne
- func (cuo *CardUpdateOne) ClearName() *CardUpdateOne
- func (cuo *CardUpdateOne) ClearOwner() *CardUpdateOne
- func (cuo *CardUpdateOne) ClearSpec() *CardUpdateOne
- func (cuo *CardUpdateOne) Exec(ctx context.Context) error
- func (cuo *CardUpdateOne) ExecX(ctx context.Context)
- func (cuo *CardUpdateOne) Mutation() *CardMutation
- func (cuo *CardUpdateOne) RemoveSpec(s ...*Spec) *CardUpdateOne
- func (cuo *CardUpdateOne) RemoveSpecIDs(ids ...string) *CardUpdateOne
- func (cuo *CardUpdateOne) Save(ctx context.Context) (*Card, error)
- func (cuo *CardUpdateOne) SaveX(ctx context.Context) *Card
- func (cuo *CardUpdateOne) SetName(s string) *CardUpdateOne
- func (cuo *CardUpdateOne) SetNillableName(s *string) *CardUpdateOne
- func (cuo *CardUpdateOne) SetNillableOwnerID(id *string) *CardUpdateOne
- func (cuo *CardUpdateOne) SetOwner(u *User) *CardUpdateOne
- func (cuo *CardUpdateOne) SetOwnerID(id string) *CardUpdateOne
- type Cards
- type Client
- type Comment
- 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 string) *CommentDeleteOne
- func (c *CommentClient) Get(ctx context.Context, id string) (*Comment, error)
- func (c *CommentClient) GetX(ctx context.Context, id string) *Comment
- func (c *CommentClient) Hooks() []Hook
- func (c *CommentClient) Query() *CommentQuery
- func (c *CommentClient) Update() *CommentUpdate
- func (c *CommentClient) UpdateOne(co *Comment) *CommentUpdateOne
- func (c *CommentClient) UpdateOneID(id string) *CommentUpdateOne
- func (c *CommentClient) Use(hooks ...Hook)
- type CommentCreate
- func (cc *CommentCreate) Mutation() *CommentMutation
- func (cc *CommentCreate) Save(ctx context.Context) (*Comment, error)
- func (cc *CommentCreate) SaveX(ctx context.Context) *Comment
- func (cc *CommentCreate) SetNillableInt(i int) *CommentCreate
- func (cc *CommentCreate) SetNillableNillableInt(i *int) *CommentCreate
- func (cc *CommentCreate) SetUniqueFloat(f float64) *CommentCreate
- func (cc *CommentCreate) SetUniqueInt(i int) *CommentCreate
- type CommentCreateBulk
- type CommentDelete
- type CommentDeleteOne
- type CommentGroupBy
- func (cgb *CommentGroupBy) Aggregate(fns ...AggregateFunc) *CommentGroupBy
- func (cgb *CommentGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (cgb *CommentGroupBy) BoolX(ctx context.Context) bool
- func (cgb *CommentGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (cgb *CommentGroupBy) BoolsX(ctx context.Context) []bool
- func (cgb *CommentGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (cgb *CommentGroupBy) Float64X(ctx context.Context) float64
- func (cgb *CommentGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (cgb *CommentGroupBy) Float64sX(ctx context.Context) []float64
- func (cgb *CommentGroupBy) Int(ctx context.Context) (_ int, err error)
- func (cgb *CommentGroupBy) IntX(ctx context.Context) int
- func (cgb *CommentGroupBy) Ints(ctx context.Context) ([]int, error)
- func (cgb *CommentGroupBy) IntsX(ctx context.Context) []int
- func (cgb *CommentGroupBy) Scan(ctx context.Context, v interface{}) error
- func (cgb *CommentGroupBy) ScanX(ctx context.Context, v interface{})
- func (cgb *CommentGroupBy) String(ctx context.Context) (_ string, err error)
- func (cgb *CommentGroupBy) StringX(ctx context.Context) string
- func (cgb *CommentGroupBy) Strings(ctx context.Context) ([]string, error)
- func (cgb *CommentGroupBy) StringsX(ctx context.Context) []string
- type CommentMutation
- func (m *CommentMutation) AddField(name string, value ent.Value) error
- func (m *CommentMutation) AddNillableInt(i int)
- func (m *CommentMutation) AddUniqueFloat(f float64)
- func (m *CommentMutation) AddUniqueInt(i 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) AddedNillableInt() (r int, exists bool)
- func (m *CommentMutation) AddedUniqueFloat() (r float64, exists bool)
- func (m *CommentMutation) AddedUniqueInt() (r int, exists bool)
- func (m *CommentMutation) ClearEdge(name string) error
- func (m *CommentMutation) ClearField(name string) error
- func (m *CommentMutation) ClearNillableInt()
- 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) Field(name string) (ent.Value, bool)
- func (m *CommentMutation) FieldCleared(name string) bool
- func (m *CommentMutation) Fields() []string
- func (m *CommentMutation) ID() (id string, exists bool)
- func (m *CommentMutation) NillableInt() (r int, exists bool)
- func (m *CommentMutation) NillableIntCleared() bool
- func (m *CommentMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *CommentMutation) OldNillableInt(ctx context.Context) (v *int, err error)
- func (m *CommentMutation) OldUniqueFloat(ctx context.Context) (v float64, err error)
- func (m *CommentMutation) OldUniqueInt(ctx context.Context) (v int, err error)
- func (m *CommentMutation) Op() Op
- func (m *CommentMutation) RemovedEdges() []string
- func (m *CommentMutation) RemovedIDs(name string) []ent.Value
- func (m *CommentMutation) ResetEdge(name string) error
- func (m *CommentMutation) ResetField(name string) error
- func (m *CommentMutation) ResetNillableInt()
- func (m *CommentMutation) ResetUniqueFloat()
- func (m *CommentMutation) ResetUniqueInt()
- func (m *CommentMutation) SetField(name string, value ent.Value) error
- func (m *CommentMutation) SetNillableInt(i int)
- func (m *CommentMutation) SetUniqueFloat(f float64)
- func (m *CommentMutation) SetUniqueInt(i int)
- func (m CommentMutation) Tx() (*Tx, error)
- func (m *CommentMutation) Type() string
- func (m *CommentMutation) UniqueFloat() (r float64, exists bool)
- func (m *CommentMutation) UniqueInt() (r int, exists bool)
- type CommentQuery
- func (cq *CommentQuery) All(ctx context.Context) ([]*Comment, error)
- func (cq *CommentQuery) AllX(ctx context.Context) []*Comment
- func (cq *CommentQuery) Clone() *CommentQuery
- 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 string, err error)
- func (cq *CommentQuery) FirstIDX(ctx context.Context) string
- func (cq *CommentQuery) FirstX(ctx context.Context) *Comment
- func (cq *CommentQuery) GroupBy(field string, fields ...string) *CommentGroupBy
- func (cq *CommentQuery) IDs(ctx context.Context) ([]string, error)
- func (cq *CommentQuery) IDsX(ctx context.Context) []string
- 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 string, err error)
- func (cq *CommentQuery) OnlyIDX(ctx context.Context) string
- func (cq *CommentQuery) OnlyX(ctx context.Context) *Comment
- func (cq *CommentQuery) Order(o ...OrderFunc) *CommentQuery
- func (cq *CommentQuery) Select(field string, fields ...string) *CommentSelect
- func (cq *CommentQuery) Where(ps ...predicate.Comment) *CommentQuery
- type CommentSelect
- func (cs *CommentSelect) Bool(ctx context.Context) (_ bool, err error)
- func (cs *CommentSelect) BoolX(ctx context.Context) bool
- func (cs *CommentSelect) Bools(ctx context.Context) ([]bool, error)
- func (cs *CommentSelect) BoolsX(ctx context.Context) []bool
- func (cs *CommentSelect) Float64(ctx context.Context) (_ float64, err error)
- func (cs *CommentSelect) Float64X(ctx context.Context) float64
- func (cs *CommentSelect) Float64s(ctx context.Context) ([]float64, error)
- func (cs *CommentSelect) Float64sX(ctx context.Context) []float64
- func (cs *CommentSelect) Int(ctx context.Context) (_ int, err error)
- func (cs *CommentSelect) IntX(ctx context.Context) int
- func (cs *CommentSelect) Ints(ctx context.Context) ([]int, error)
- func (cs *CommentSelect) IntsX(ctx context.Context) []int
- func (cs *CommentSelect) Scan(ctx context.Context, v interface{}) error
- func (cs *CommentSelect) ScanX(ctx context.Context, v interface{})
- func (cs *CommentSelect) String(ctx context.Context) (_ string, err error)
- func (cs *CommentSelect) StringX(ctx context.Context) string
- func (cs *CommentSelect) Strings(ctx context.Context) ([]string, error)
- func (cs *CommentSelect) StringsX(ctx context.Context) []string
- type CommentUpdate
- func (cu *CommentUpdate) AddNillableInt(i int) *CommentUpdate
- func (cu *CommentUpdate) AddUniqueFloat(f float64) *CommentUpdate
- func (cu *CommentUpdate) AddUniqueInt(i int) *CommentUpdate
- func (cu *CommentUpdate) ClearNillableInt() *CommentUpdate
- func (cu *CommentUpdate) Exec(ctx context.Context) error
- func (cu *CommentUpdate) ExecX(ctx context.Context)
- func (cu *CommentUpdate) Mutation() *CommentMutation
- func (cu *CommentUpdate) Save(ctx context.Context) (int, error)
- func (cu *CommentUpdate) SaveX(ctx context.Context) int
- func (cu *CommentUpdate) SetNillableInt(i int) *CommentUpdate
- func (cu *CommentUpdate) SetNillableNillableInt(i *int) *CommentUpdate
- func (cu *CommentUpdate) SetUniqueFloat(f float64) *CommentUpdate
- func (cu *CommentUpdate) SetUniqueInt(i int) *CommentUpdate
- func (cu *CommentUpdate) Where(ps ...predicate.Comment) *CommentUpdate
- type CommentUpdateOne
- func (cuo *CommentUpdateOne) AddNillableInt(i int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddUniqueFloat(f float64) *CommentUpdateOne
- func (cuo *CommentUpdateOne) AddUniqueInt(i int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) ClearNillableInt() *CommentUpdateOne
- func (cuo *CommentUpdateOne) Exec(ctx context.Context) error
- func (cuo *CommentUpdateOne) ExecX(ctx context.Context)
- func (cuo *CommentUpdateOne) Mutation() *CommentMutation
- func (cuo *CommentUpdateOne) Save(ctx context.Context) (*Comment, error)
- func (cuo *CommentUpdateOne) SaveX(ctx context.Context) *Comment
- func (cuo *CommentUpdateOne) SetNillableInt(i int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) SetNillableNillableInt(i *int) *CommentUpdateOne
- func (cuo *CommentUpdateOne) SetUniqueFloat(f float64) *CommentUpdateOne
- func (cuo *CommentUpdateOne) SetUniqueInt(i int) *CommentUpdateOne
- type Comments
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type FieldType
- type FieldTypeClient
- func (c *FieldTypeClient) Create() *FieldTypeCreate
- func (c *FieldTypeClient) CreateBulk(builders ...*FieldTypeCreate) *FieldTypeCreateBulk
- func (c *FieldTypeClient) Delete() *FieldTypeDelete
- func (c *FieldTypeClient) DeleteOne(ft *FieldType) *FieldTypeDeleteOne
- func (c *FieldTypeClient) DeleteOneID(id string) *FieldTypeDeleteOne
- func (c *FieldTypeClient) Get(ctx context.Context, id string) (*FieldType, error)
- func (c *FieldTypeClient) GetX(ctx context.Context, id string) *FieldType
- func (c *FieldTypeClient) Hooks() []Hook
- func (c *FieldTypeClient) Query() *FieldTypeQuery
- func (c *FieldTypeClient) Update() *FieldTypeUpdate
- func (c *FieldTypeClient) UpdateOne(ft *FieldType) *FieldTypeUpdateOne
- func (c *FieldTypeClient) UpdateOneID(id string) *FieldTypeUpdateOne
- func (c *FieldTypeClient) Use(hooks ...Hook)
- type FieldTypeCreate
- func (ftc *FieldTypeCreate) Mutation() *FieldTypeMutation
- func (ftc *FieldTypeCreate) Save(ctx context.Context) (*FieldType, error)
- func (ftc *FieldTypeCreate) SaveX(ctx context.Context) *FieldType
- func (ftc *FieldTypeCreate) SetActive(s schema.Status) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetDatetime(t time.Time) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetDecimal(f float64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetDeleted(sb sql.NullBool) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetDeletedAt(st sql.NullTime) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetDir(h http.Dir) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetIP(n net.IP) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetInt(i int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetInt16(i int16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetInt32(i int32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetInt64(i int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetInt8(i int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetLink(s schema.Link) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNdir(h http.Dir) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableActive(s *schema.Status) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableDatetime(t *time.Time) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableDecimal(f *float64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableDir(h *http.Dir) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableInt(i int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableInt16(i int16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableInt32(i int32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableInt64(i int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableInt8(i int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNdir(h *http.Dir) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNillableInt(i *int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNillableInt16(i *int16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNillableInt32(i *int32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNillableInt64(i *int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNillableInt8(i *int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableNullActive(s *schema.Status) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalFloat(f *float64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalFloat32(f *float32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalInt(i *int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalInt16(i *int16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalInt32(i *int32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalInt64(i *int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalInt8(i *int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalUint(u *uint) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalUint16(u *uint16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalUint32(u *uint32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalUint64(u *uint64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableOptionalUint8(u *uint8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableRole(r *role.Role) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableSchemaFloat(s *schema.Float64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableSchemaFloat32(s *schema.Float32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableSchemaInt(s *schema.Int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableSchemaInt64(s *schema.Int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableSchemaInt8(s *schema.Int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableState(f *fieldtype.State) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNillableValidateOptionalInt32(i *int32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNullActive(s schema.Status) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNullFloat(sf sql.NullFloat64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNullInt64(si sql.NullInt64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNullLink(s schema.Link) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetNullStr(ss sql.NullString) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalFloat(f float64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalFloat32(f float32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalInt(i int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalInt16(i int16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalInt32(i int32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalInt64(i int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalInt8(i int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalUint(u uint) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalUint16(u uint16) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalUint32(u uint32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalUint64(u uint64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetOptionalUint8(u uint8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetRole(r role.Role) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetSchemaFloat(s schema.Float64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetSchemaFloat32(s schema.Float32) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetSchemaInt(s schema.Int) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetSchemaInt64(s schema.Int64) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetSchemaInt8(s schema.Int8) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetState(f fieldtype.State) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetStr(ss sql.NullString) *FieldTypeCreate
- func (ftc *FieldTypeCreate) SetValidateOptionalInt32(i int32) *FieldTypeCreate
- type FieldTypeCreateBulk
- type FieldTypeDelete
- type FieldTypeDeleteOne
- type FieldTypeGroupBy
- func (ftgb *FieldTypeGroupBy) Aggregate(fns ...AggregateFunc) *FieldTypeGroupBy
- func (ftgb *FieldTypeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ftgb *FieldTypeGroupBy) BoolX(ctx context.Context) bool
- func (ftgb *FieldTypeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ftgb *FieldTypeGroupBy) BoolsX(ctx context.Context) []bool
- func (ftgb *FieldTypeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ftgb *FieldTypeGroupBy) Float64X(ctx context.Context) float64
- func (ftgb *FieldTypeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ftgb *FieldTypeGroupBy) Float64sX(ctx context.Context) []float64
- func (ftgb *FieldTypeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ftgb *FieldTypeGroupBy) IntX(ctx context.Context) int
- func (ftgb *FieldTypeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ftgb *FieldTypeGroupBy) IntsX(ctx context.Context) []int
- func (ftgb *FieldTypeGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ftgb *FieldTypeGroupBy) ScanX(ctx context.Context, v interface{})
- func (ftgb *FieldTypeGroupBy) String(ctx context.Context) (_ string, err error)
- func (ftgb *FieldTypeGroupBy) StringX(ctx context.Context) string
- func (ftgb *FieldTypeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ftgb *FieldTypeGroupBy) StringsX(ctx context.Context) []string
- type FieldTypeMutation
- func (m *FieldTypeMutation) Active() (r schema.Status, exists bool)
- func (m *FieldTypeMutation) ActiveCleared() bool
- func (m *FieldTypeMutation) AddDecimal(f float64)
- func (m *FieldTypeMutation) AddField(name string, value ent.Value) error
- func (m *FieldTypeMutation) AddInt(i int)
- func (m *FieldTypeMutation) AddInt16(i int16)
- func (m *FieldTypeMutation) AddInt32(i int32)
- func (m *FieldTypeMutation) AddInt64(i int64)
- func (m *FieldTypeMutation) AddInt8(i int8)
- func (m *FieldTypeMutation) AddNillableInt(i int)
- func (m *FieldTypeMutation) AddNillableInt16(i int16)
- func (m *FieldTypeMutation) AddNillableInt32(i int32)
- func (m *FieldTypeMutation) AddNillableInt64(i int64)
- func (m *FieldTypeMutation) AddNillableInt8(i int8)
- func (m *FieldTypeMutation) AddOptionalFloat(f float64)
- func (m *FieldTypeMutation) AddOptionalFloat32(f float32)
- func (m *FieldTypeMutation) AddOptionalInt(i int)
- func (m *FieldTypeMutation) AddOptionalInt16(i int16)
- func (m *FieldTypeMutation) AddOptionalInt32(i int32)
- func (m *FieldTypeMutation) AddOptionalInt64(i int64)
- func (m *FieldTypeMutation) AddOptionalInt8(i int8)
- func (m *FieldTypeMutation) AddOptionalUint(u uint)
- func (m *FieldTypeMutation) AddOptionalUint16(u uint16)
- func (m *FieldTypeMutation) AddOptionalUint32(u uint32)
- func (m *FieldTypeMutation) AddOptionalUint64(u uint64)
- func (m *FieldTypeMutation) AddOptionalUint8(u uint8)
- func (m *FieldTypeMutation) AddSchemaFloat(s schema.Float64)
- func (m *FieldTypeMutation) AddSchemaFloat32(s schema.Float32)
- func (m *FieldTypeMutation) AddSchemaInt(s schema.Int)
- func (m *FieldTypeMutation) AddSchemaInt64(s schema.Int64)
- func (m *FieldTypeMutation) AddSchemaInt8(s schema.Int8)
- func (m *FieldTypeMutation) AddValidateOptionalInt32(i int32)
- func (m *FieldTypeMutation) AddedDecimal() (r float64, exists bool)
- func (m *FieldTypeMutation) AddedEdges() []string
- func (m *FieldTypeMutation) AddedField(name string) (ent.Value, bool)
- func (m *FieldTypeMutation) AddedFields() []string
- func (m *FieldTypeMutation) AddedIDs(name string) []ent.Value
- func (m *FieldTypeMutation) AddedInt() (r int, exists bool)
- func (m *FieldTypeMutation) AddedInt16() (r int16, exists bool)
- func (m *FieldTypeMutation) AddedInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) AddedInt64() (r int64, exists bool)
- func (m *FieldTypeMutation) AddedInt8() (r int8, exists bool)
- func (m *FieldTypeMutation) AddedNillableInt() (r int, exists bool)
- func (m *FieldTypeMutation) AddedNillableInt16() (r int16, exists bool)
- func (m *FieldTypeMutation) AddedNillableInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) AddedNillableInt64() (r int64, exists bool)
- func (m *FieldTypeMutation) AddedNillableInt8() (r int8, exists bool)
- func (m *FieldTypeMutation) AddedOptionalFloat() (r float64, exists bool)
- func (m *FieldTypeMutation) AddedOptionalFloat32() (r float32, exists bool)
- func (m *FieldTypeMutation) AddedOptionalInt() (r int, exists bool)
- func (m *FieldTypeMutation) AddedOptionalInt16() (r int16, exists bool)
- func (m *FieldTypeMutation) AddedOptionalInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) AddedOptionalInt64() (r int64, exists bool)
- func (m *FieldTypeMutation) AddedOptionalInt8() (r int8, exists bool)
- func (m *FieldTypeMutation) AddedOptionalUint() (r uint, exists bool)
- func (m *FieldTypeMutation) AddedOptionalUint16() (r uint16, exists bool)
- func (m *FieldTypeMutation) AddedOptionalUint32() (r uint32, exists bool)
- func (m *FieldTypeMutation) AddedOptionalUint64() (r uint64, exists bool)
- func (m *FieldTypeMutation) AddedOptionalUint8() (r uint8, exists bool)
- func (m *FieldTypeMutation) AddedSchemaFloat() (r schema.Float64, exists bool)
- func (m *FieldTypeMutation) AddedSchemaFloat32() (r schema.Float32, exists bool)
- func (m *FieldTypeMutation) AddedSchemaInt() (r schema.Int, exists bool)
- func (m *FieldTypeMutation) AddedSchemaInt64() (r schema.Int64, exists bool)
- func (m *FieldTypeMutation) AddedSchemaInt8() (r schema.Int8, exists bool)
- func (m *FieldTypeMutation) AddedValidateOptionalInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) ClearActive()
- func (m *FieldTypeMutation) ClearDatetime()
- func (m *FieldTypeMutation) ClearDecimal()
- func (m *FieldTypeMutation) ClearDeleted()
- func (m *FieldTypeMutation) ClearDeletedAt()
- func (m *FieldTypeMutation) ClearDir()
- func (m *FieldTypeMutation) ClearEdge(name string) error
- func (m *FieldTypeMutation) ClearField(name string) error
- func (m *FieldTypeMutation) ClearIP()
- func (m *FieldTypeMutation) ClearLink()
- func (m *FieldTypeMutation) ClearNdir()
- func (m *FieldTypeMutation) ClearNillableInt()
- func (m *FieldTypeMutation) ClearNillableInt16()
- func (m *FieldTypeMutation) ClearNillableInt32()
- func (m *FieldTypeMutation) ClearNillableInt64()
- func (m *FieldTypeMutation) ClearNillableInt8()
- func (m *FieldTypeMutation) ClearNullActive()
- func (m *FieldTypeMutation) ClearNullFloat()
- func (m *FieldTypeMutation) ClearNullInt64()
- func (m *FieldTypeMutation) ClearNullLink()
- func (m *FieldTypeMutation) ClearNullStr()
- func (m *FieldTypeMutation) ClearOptionalFloat()
- func (m *FieldTypeMutation) ClearOptionalFloat32()
- func (m *FieldTypeMutation) ClearOptionalInt()
- func (m *FieldTypeMutation) ClearOptionalInt16()
- func (m *FieldTypeMutation) ClearOptionalInt32()
- func (m *FieldTypeMutation) ClearOptionalInt64()
- func (m *FieldTypeMutation) ClearOptionalInt8()
- func (m *FieldTypeMutation) ClearOptionalUint()
- func (m *FieldTypeMutation) ClearOptionalUint16()
- func (m *FieldTypeMutation) ClearOptionalUint32()
- func (m *FieldTypeMutation) ClearOptionalUint64()
- func (m *FieldTypeMutation) ClearOptionalUint8()
- func (m *FieldTypeMutation) ClearSchemaFloat()
- func (m *FieldTypeMutation) ClearSchemaFloat32()
- func (m *FieldTypeMutation) ClearSchemaInt()
- func (m *FieldTypeMutation) ClearSchemaInt64()
- func (m *FieldTypeMutation) ClearSchemaInt8()
- func (m *FieldTypeMutation) ClearState()
- func (m *FieldTypeMutation) ClearStr()
- func (m *FieldTypeMutation) ClearValidateOptionalInt32()
- func (m *FieldTypeMutation) ClearedEdges() []string
- func (m *FieldTypeMutation) ClearedFields() []string
- func (m FieldTypeMutation) Client() *Client
- func (m *FieldTypeMutation) Datetime() (r time.Time, exists bool)
- func (m *FieldTypeMutation) DatetimeCleared() bool
- func (m *FieldTypeMutation) Decimal() (r float64, exists bool)
- func (m *FieldTypeMutation) DecimalCleared() bool
- func (m *FieldTypeMutation) Deleted() (r sql.NullBool, exists bool)
- func (m *FieldTypeMutation) DeletedAt() (r sql.NullTime, exists bool)
- func (m *FieldTypeMutation) DeletedAtCleared() bool
- func (m *FieldTypeMutation) DeletedCleared() bool
- func (m *FieldTypeMutation) Dir() (r http.Dir, exists bool)
- func (m *FieldTypeMutation) DirCleared() bool
- func (m *FieldTypeMutation) EdgeCleared(name string) bool
- func (m *FieldTypeMutation) Field(name string) (ent.Value, bool)
- func (m *FieldTypeMutation) FieldCleared(name string) bool
- func (m *FieldTypeMutation) Fields() []string
- func (m *FieldTypeMutation) ID() (id string, exists bool)
- func (m *FieldTypeMutation) IP() (r net.IP, exists bool)
- func (m *FieldTypeMutation) IPCleared() bool
- func (m *FieldTypeMutation) Int() (r int, exists bool)
- func (m *FieldTypeMutation) Int16() (r int16, exists bool)
- func (m *FieldTypeMutation) Int32() (r int32, exists bool)
- func (m *FieldTypeMutation) Int64() (r int64, exists bool)
- func (m *FieldTypeMutation) Int8() (r int8, exists bool)
- func (m *FieldTypeMutation) Link() (r schema.Link, exists bool)
- func (m *FieldTypeMutation) LinkCleared() bool
- func (m *FieldTypeMutation) Ndir() (r http.Dir, exists bool)
- func (m *FieldTypeMutation) NdirCleared() bool
- func (m *FieldTypeMutation) NillableInt() (r int, exists bool)
- func (m *FieldTypeMutation) NillableInt16() (r int16, exists bool)
- func (m *FieldTypeMutation) NillableInt16Cleared() bool
- func (m *FieldTypeMutation) NillableInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) NillableInt32Cleared() bool
- func (m *FieldTypeMutation) NillableInt64() (r int64, exists bool)
- func (m *FieldTypeMutation) NillableInt64Cleared() bool
- func (m *FieldTypeMutation) NillableInt8() (r int8, exists bool)
- func (m *FieldTypeMutation) NillableInt8Cleared() bool
- func (m *FieldTypeMutation) NillableIntCleared() bool
- func (m *FieldTypeMutation) NullActive() (r schema.Status, exists bool)
- func (m *FieldTypeMutation) NullActiveCleared() bool
- func (m *FieldTypeMutation) NullFloat() (r sql.NullFloat64, exists bool)
- func (m *FieldTypeMutation) NullFloatCleared() bool
- func (m *FieldTypeMutation) NullInt64() (r sql.NullInt64, exists bool)
- func (m *FieldTypeMutation) NullInt64Cleared() bool
- func (m *FieldTypeMutation) NullLink() (r schema.Link, exists bool)
- func (m *FieldTypeMutation) NullLinkCleared() bool
- func (m *FieldTypeMutation) NullStr() (r sql.NullString, exists bool)
- func (m *FieldTypeMutation) NullStrCleared() bool
- func (m *FieldTypeMutation) OldActive(ctx context.Context) (v schema.Status, err error)
- func (m *FieldTypeMutation) OldDatetime(ctx context.Context) (v time.Time, err error)
- func (m *FieldTypeMutation) OldDecimal(ctx context.Context) (v float64, err error)
- func (m *FieldTypeMutation) OldDeleted(ctx context.Context) (v sql.NullBool, err error)
- func (m *FieldTypeMutation) OldDeletedAt(ctx context.Context) (v sql.NullTime, err error)
- func (m *FieldTypeMutation) OldDir(ctx context.Context) (v http.Dir, err error)
- func (m *FieldTypeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *FieldTypeMutation) OldIP(ctx context.Context) (v net.IP, err error)
- func (m *FieldTypeMutation) OldInt(ctx context.Context) (v int, err error)
- func (m *FieldTypeMutation) OldInt16(ctx context.Context) (v int16, err error)
- func (m *FieldTypeMutation) OldInt32(ctx context.Context) (v int32, err error)
- func (m *FieldTypeMutation) OldInt64(ctx context.Context) (v int64, err error)
- func (m *FieldTypeMutation) OldInt8(ctx context.Context) (v int8, err error)
- func (m *FieldTypeMutation) OldLink(ctx context.Context) (v schema.Link, err error)
- func (m *FieldTypeMutation) OldNdir(ctx context.Context) (v *http.Dir, err error)
- func (m *FieldTypeMutation) OldNillableInt(ctx context.Context) (v *int, err error)
- func (m *FieldTypeMutation) OldNillableInt16(ctx context.Context) (v *int16, err error)
- func (m *FieldTypeMutation) OldNillableInt32(ctx context.Context) (v *int32, err error)
- func (m *FieldTypeMutation) OldNillableInt64(ctx context.Context) (v *int64, err error)
- func (m *FieldTypeMutation) OldNillableInt8(ctx context.Context) (v *int8, err error)
- func (m *FieldTypeMutation) OldNullActive(ctx context.Context) (v *schema.Status, err error)
- func (m *FieldTypeMutation) OldNullFloat(ctx context.Context) (v sql.NullFloat64, err error)
- func (m *FieldTypeMutation) OldNullInt64(ctx context.Context) (v sql.NullInt64, err error)
- func (m *FieldTypeMutation) OldNullLink(ctx context.Context) (v *schema.Link, err error)
- func (m *FieldTypeMutation) OldNullStr(ctx context.Context) (v *sql.NullString, err error)
- func (m *FieldTypeMutation) OldOptionalFloat(ctx context.Context) (v float64, err error)
- func (m *FieldTypeMutation) OldOptionalFloat32(ctx context.Context) (v float32, err error)
- func (m *FieldTypeMutation) OldOptionalInt(ctx context.Context) (v int, err error)
- func (m *FieldTypeMutation) OldOptionalInt16(ctx context.Context) (v int16, err error)
- func (m *FieldTypeMutation) OldOptionalInt32(ctx context.Context) (v int32, err error)
- func (m *FieldTypeMutation) OldOptionalInt64(ctx context.Context) (v int64, err error)
- func (m *FieldTypeMutation) OldOptionalInt8(ctx context.Context) (v int8, err error)
- func (m *FieldTypeMutation) OldOptionalUint(ctx context.Context) (v uint, err error)
- func (m *FieldTypeMutation) OldOptionalUint16(ctx context.Context) (v uint16, err error)
- func (m *FieldTypeMutation) OldOptionalUint32(ctx context.Context) (v uint32, err error)
- func (m *FieldTypeMutation) OldOptionalUint64(ctx context.Context) (v uint64, err error)
- func (m *FieldTypeMutation) OldOptionalUint8(ctx context.Context) (v uint8, err error)
- func (m *FieldTypeMutation) OldRole(ctx context.Context) (v role.Role, err error)
- func (m *FieldTypeMutation) OldSchemaFloat(ctx context.Context) (v schema.Float64, err error)
- func (m *FieldTypeMutation) OldSchemaFloat32(ctx context.Context) (v schema.Float32, err error)
- func (m *FieldTypeMutation) OldSchemaInt(ctx context.Context) (v schema.Int, err error)
- func (m *FieldTypeMutation) OldSchemaInt64(ctx context.Context) (v schema.Int64, err error)
- func (m *FieldTypeMutation) OldSchemaInt8(ctx context.Context) (v schema.Int8, err error)
- func (m *FieldTypeMutation) OldState(ctx context.Context) (v fieldtype.State, err error)
- func (m *FieldTypeMutation) OldStr(ctx context.Context) (v sql.NullString, err error)
- func (m *FieldTypeMutation) OldValidateOptionalInt32(ctx context.Context) (v int32, err error)
- func (m *FieldTypeMutation) Op() Op
- func (m *FieldTypeMutation) OptionalFloat() (r float64, exists bool)
- func (m *FieldTypeMutation) OptionalFloat32() (r float32, exists bool)
- func (m *FieldTypeMutation) OptionalFloat32Cleared() bool
- func (m *FieldTypeMutation) OptionalFloatCleared() bool
- func (m *FieldTypeMutation) OptionalInt() (r int, exists bool)
- func (m *FieldTypeMutation) OptionalInt16() (r int16, exists bool)
- func (m *FieldTypeMutation) OptionalInt16Cleared() bool
- func (m *FieldTypeMutation) OptionalInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) OptionalInt32Cleared() bool
- func (m *FieldTypeMutation) OptionalInt64() (r int64, exists bool)
- func (m *FieldTypeMutation) OptionalInt64Cleared() bool
- func (m *FieldTypeMutation) OptionalInt8() (r int8, exists bool)
- func (m *FieldTypeMutation) OptionalInt8Cleared() bool
- func (m *FieldTypeMutation) OptionalIntCleared() bool
- func (m *FieldTypeMutation) OptionalUint() (r uint, exists bool)
- func (m *FieldTypeMutation) OptionalUint16() (r uint16, exists bool)
- func (m *FieldTypeMutation) OptionalUint16Cleared() bool
- func (m *FieldTypeMutation) OptionalUint32() (r uint32, exists bool)
- func (m *FieldTypeMutation) OptionalUint32Cleared() bool
- func (m *FieldTypeMutation) OptionalUint64() (r uint64, exists bool)
- func (m *FieldTypeMutation) OptionalUint64Cleared() bool
- func (m *FieldTypeMutation) OptionalUint8() (r uint8, exists bool)
- func (m *FieldTypeMutation) OptionalUint8Cleared() bool
- func (m *FieldTypeMutation) OptionalUintCleared() bool
- func (m *FieldTypeMutation) RemovedEdges() []string
- func (m *FieldTypeMutation) RemovedIDs(name string) []ent.Value
- func (m *FieldTypeMutation) ResetActive()
- func (m *FieldTypeMutation) ResetDatetime()
- func (m *FieldTypeMutation) ResetDecimal()
- func (m *FieldTypeMutation) ResetDeleted()
- func (m *FieldTypeMutation) ResetDeletedAt()
- func (m *FieldTypeMutation) ResetDir()
- func (m *FieldTypeMutation) ResetEdge(name string) error
- func (m *FieldTypeMutation) ResetField(name string) error
- func (m *FieldTypeMutation) ResetIP()
- func (m *FieldTypeMutation) ResetInt()
- func (m *FieldTypeMutation) ResetInt16()
- func (m *FieldTypeMutation) ResetInt32()
- func (m *FieldTypeMutation) ResetInt64()
- func (m *FieldTypeMutation) ResetInt8()
- func (m *FieldTypeMutation) ResetLink()
- func (m *FieldTypeMutation) ResetNdir()
- func (m *FieldTypeMutation) ResetNillableInt()
- func (m *FieldTypeMutation) ResetNillableInt16()
- func (m *FieldTypeMutation) ResetNillableInt32()
- func (m *FieldTypeMutation) ResetNillableInt64()
- func (m *FieldTypeMutation) ResetNillableInt8()
- func (m *FieldTypeMutation) ResetNullActive()
- func (m *FieldTypeMutation) ResetNullFloat()
- func (m *FieldTypeMutation) ResetNullInt64()
- func (m *FieldTypeMutation) ResetNullLink()
- func (m *FieldTypeMutation) ResetNullStr()
- func (m *FieldTypeMutation) ResetOptionalFloat()
- func (m *FieldTypeMutation) ResetOptionalFloat32()
- func (m *FieldTypeMutation) ResetOptionalInt()
- func (m *FieldTypeMutation) ResetOptionalInt16()
- func (m *FieldTypeMutation) ResetOptionalInt32()
- func (m *FieldTypeMutation) ResetOptionalInt64()
- func (m *FieldTypeMutation) ResetOptionalInt8()
- func (m *FieldTypeMutation) ResetOptionalUint()
- func (m *FieldTypeMutation) ResetOptionalUint16()
- func (m *FieldTypeMutation) ResetOptionalUint32()
- func (m *FieldTypeMutation) ResetOptionalUint64()
- func (m *FieldTypeMutation) ResetOptionalUint8()
- func (m *FieldTypeMutation) ResetRole()
- func (m *FieldTypeMutation) ResetSchemaFloat()
- func (m *FieldTypeMutation) ResetSchemaFloat32()
- func (m *FieldTypeMutation) ResetSchemaInt()
- func (m *FieldTypeMutation) ResetSchemaInt64()
- func (m *FieldTypeMutation) ResetSchemaInt8()
- func (m *FieldTypeMutation) ResetState()
- func (m *FieldTypeMutation) ResetStr()
- func (m *FieldTypeMutation) ResetValidateOptionalInt32()
- func (m *FieldTypeMutation) Role() (r role.Role, exists bool)
- func (m *FieldTypeMutation) SchemaFloat() (r schema.Float64, exists bool)
- func (m *FieldTypeMutation) SchemaFloat32() (r schema.Float32, exists bool)
- func (m *FieldTypeMutation) SchemaFloat32Cleared() bool
- func (m *FieldTypeMutation) SchemaFloatCleared() bool
- func (m *FieldTypeMutation) SchemaInt() (r schema.Int, exists bool)
- func (m *FieldTypeMutation) SchemaInt64() (r schema.Int64, exists bool)
- func (m *FieldTypeMutation) SchemaInt64Cleared() bool
- func (m *FieldTypeMutation) SchemaInt8() (r schema.Int8, exists bool)
- func (m *FieldTypeMutation) SchemaInt8Cleared() bool
- func (m *FieldTypeMutation) SchemaIntCleared() bool
- func (m *FieldTypeMutation) SetActive(s schema.Status)
- func (m *FieldTypeMutation) SetDatetime(t time.Time)
- func (m *FieldTypeMutation) SetDecimal(f float64)
- func (m *FieldTypeMutation) SetDeleted(sb sql.NullBool)
- func (m *FieldTypeMutation) SetDeletedAt(st sql.NullTime)
- func (m *FieldTypeMutation) SetDir(h http.Dir)
- func (m *FieldTypeMutation) SetField(name string, value ent.Value) error
- func (m *FieldTypeMutation) SetIP(n net.IP)
- func (m *FieldTypeMutation) SetInt(i int)
- func (m *FieldTypeMutation) SetInt16(i int16)
- func (m *FieldTypeMutation) SetInt32(i int32)
- func (m *FieldTypeMutation) SetInt64(i int64)
- func (m *FieldTypeMutation) SetInt8(i int8)
- func (m *FieldTypeMutation) SetLink(s schema.Link)
- func (m *FieldTypeMutation) SetNdir(h http.Dir)
- func (m *FieldTypeMutation) SetNillableInt(i int)
- func (m *FieldTypeMutation) SetNillableInt16(i int16)
- func (m *FieldTypeMutation) SetNillableInt32(i int32)
- func (m *FieldTypeMutation) SetNillableInt64(i int64)
- func (m *FieldTypeMutation) SetNillableInt8(i int8)
- func (m *FieldTypeMutation) SetNullActive(s schema.Status)
- func (m *FieldTypeMutation) SetNullFloat(sf sql.NullFloat64)
- func (m *FieldTypeMutation) SetNullInt64(si sql.NullInt64)
- func (m *FieldTypeMutation) SetNullLink(s schema.Link)
- func (m *FieldTypeMutation) SetNullStr(ss sql.NullString)
- func (m *FieldTypeMutation) SetOptionalFloat(f float64)
- func (m *FieldTypeMutation) SetOptionalFloat32(f float32)
- func (m *FieldTypeMutation) SetOptionalInt(i int)
- func (m *FieldTypeMutation) SetOptionalInt16(i int16)
- func (m *FieldTypeMutation) SetOptionalInt32(i int32)
- func (m *FieldTypeMutation) SetOptionalInt64(i int64)
- func (m *FieldTypeMutation) SetOptionalInt8(i int8)
- func (m *FieldTypeMutation) SetOptionalUint(u uint)
- func (m *FieldTypeMutation) SetOptionalUint16(u uint16)
- func (m *FieldTypeMutation) SetOptionalUint32(u uint32)
- func (m *FieldTypeMutation) SetOptionalUint64(u uint64)
- func (m *FieldTypeMutation) SetOptionalUint8(u uint8)
- func (m *FieldTypeMutation) SetRole(r role.Role)
- func (m *FieldTypeMutation) SetSchemaFloat(s schema.Float64)
- func (m *FieldTypeMutation) SetSchemaFloat32(s schema.Float32)
- func (m *FieldTypeMutation) SetSchemaInt(s schema.Int)
- func (m *FieldTypeMutation) SetSchemaInt64(s schema.Int64)
- func (m *FieldTypeMutation) SetSchemaInt8(s schema.Int8)
- func (m *FieldTypeMutation) SetState(f fieldtype.State)
- func (m *FieldTypeMutation) SetStr(ss sql.NullString)
- func (m *FieldTypeMutation) SetValidateOptionalInt32(i int32)
- func (m *FieldTypeMutation) State() (r fieldtype.State, exists bool)
- func (m *FieldTypeMutation) StateCleared() bool
- func (m *FieldTypeMutation) Str() (r sql.NullString, exists bool)
- func (m *FieldTypeMutation) StrCleared() bool
- func (m FieldTypeMutation) Tx() (*Tx, error)
- func (m *FieldTypeMutation) Type() string
- func (m *FieldTypeMutation) ValidateOptionalInt32() (r int32, exists bool)
- func (m *FieldTypeMutation) ValidateOptionalInt32Cleared() bool
- type FieldTypeQuery
- func (ftq *FieldTypeQuery) All(ctx context.Context) ([]*FieldType, error)
- func (ftq *FieldTypeQuery) AllX(ctx context.Context) []*FieldType
- func (ftq *FieldTypeQuery) Clone() *FieldTypeQuery
- func (ftq *FieldTypeQuery) Count(ctx context.Context) (int, error)
- func (ftq *FieldTypeQuery) CountX(ctx context.Context) int
- func (ftq *FieldTypeQuery) Exist(ctx context.Context) (bool, error)
- func (ftq *FieldTypeQuery) ExistX(ctx context.Context) bool
- func (ftq *FieldTypeQuery) First(ctx context.Context) (*FieldType, error)
- func (ftq *FieldTypeQuery) FirstID(ctx context.Context) (id string, err error)
- func (ftq *FieldTypeQuery) FirstIDX(ctx context.Context) string
- func (ftq *FieldTypeQuery) FirstX(ctx context.Context) *FieldType
- func (ftq *FieldTypeQuery) GroupBy(field string, fields ...string) *FieldTypeGroupBy
- func (ftq *FieldTypeQuery) IDs(ctx context.Context) ([]string, error)
- func (ftq *FieldTypeQuery) IDsX(ctx context.Context) []string
- func (ftq *FieldTypeQuery) Limit(limit int) *FieldTypeQuery
- func (ftq *FieldTypeQuery) Offset(offset int) *FieldTypeQuery
- func (ftq *FieldTypeQuery) Only(ctx context.Context) (*FieldType, error)
- func (ftq *FieldTypeQuery) OnlyID(ctx context.Context) (id string, err error)
- func (ftq *FieldTypeQuery) OnlyIDX(ctx context.Context) string
- func (ftq *FieldTypeQuery) OnlyX(ctx context.Context) *FieldType
- func (ftq *FieldTypeQuery) Order(o ...OrderFunc) *FieldTypeQuery
- func (ftq *FieldTypeQuery) Select(field string, fields ...string) *FieldTypeSelect
- func (ftq *FieldTypeQuery) Where(ps ...predicate.FieldType) *FieldTypeQuery
- type FieldTypeSelect
- func (fts *FieldTypeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (fts *FieldTypeSelect) BoolX(ctx context.Context) bool
- func (fts *FieldTypeSelect) Bools(ctx context.Context) ([]bool, error)
- func (fts *FieldTypeSelect) BoolsX(ctx context.Context) []bool
- func (fts *FieldTypeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (fts *FieldTypeSelect) Float64X(ctx context.Context) float64
- func (fts *FieldTypeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (fts *FieldTypeSelect) Float64sX(ctx context.Context) []float64
- func (fts *FieldTypeSelect) Int(ctx context.Context) (_ int, err error)
- func (fts *FieldTypeSelect) IntX(ctx context.Context) int
- func (fts *FieldTypeSelect) Ints(ctx context.Context) ([]int, error)
- func (fts *FieldTypeSelect) IntsX(ctx context.Context) []int
- func (fts *FieldTypeSelect) Scan(ctx context.Context, v interface{}) error
- func (fts *FieldTypeSelect) ScanX(ctx context.Context, v interface{})
- func (fts *FieldTypeSelect) String(ctx context.Context) (_ string, err error)
- func (fts *FieldTypeSelect) StringX(ctx context.Context) string
- func (fts *FieldTypeSelect) Strings(ctx context.Context) ([]string, error)
- func (fts *FieldTypeSelect) StringsX(ctx context.Context) []string
- type FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddDecimal(f float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddInt(i int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddInt16(i int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddInt64(i int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddInt8(i int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddNillableInt(i int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddNillableInt16(i int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddNillableInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddNillableInt64(i int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddNillableInt8(i int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalFloat(f float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalFloat32(f float32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalInt(i int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalInt16(i int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalInt64(i int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalInt8(i int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalUint(u uint) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalUint16(u uint16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalUint32(u uint32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalUint64(u uint64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddOptionalUint8(u uint8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddSchemaFloat(s schema.Float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddSchemaFloat32(s schema.Float32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddSchemaInt(s schema.Int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddSchemaInt64(s schema.Int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddSchemaInt8(s schema.Int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) AddValidateOptionalInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearActive() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearDatetime() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearDecimal() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearDeleted() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearDeletedAt() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearDir() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearIP() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearLink() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNdir() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNillableInt() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNillableInt16() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNillableInt32() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNillableInt64() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNillableInt8() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNullActive() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNullFloat() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNullInt64() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNullLink() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearNullStr() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalFloat() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalFloat32() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalInt() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalInt16() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalInt32() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalInt64() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalInt8() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalUint() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalUint16() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalUint32() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalUint64() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearOptionalUint8() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearSchemaFloat() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearSchemaFloat32() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearSchemaInt() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearSchemaInt64() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearSchemaInt8() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearState() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearStr() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) ClearValidateOptionalInt32() *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) Exec(ctx context.Context) error
- func (ftu *FieldTypeUpdate) ExecX(ctx context.Context)
- func (ftu *FieldTypeUpdate) Mutation() *FieldTypeMutation
- func (ftu *FieldTypeUpdate) Save(ctx context.Context) (int, error)
- func (ftu *FieldTypeUpdate) SaveX(ctx context.Context) int
- func (ftu *FieldTypeUpdate) SetActive(s schema.Status) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetDatetime(t time.Time) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetDecimal(f float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetDeleted(sb sql.NullBool) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetDeletedAt(st sql.NullTime) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetDir(h http.Dir) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetIP(n net.IP) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetInt(i int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetInt16(i int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetInt64(i int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetInt8(i int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetLink(s schema.Link) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNdir(h http.Dir) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableActive(s *schema.Status) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableDatetime(t *time.Time) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableDecimal(f *float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableDir(h *http.Dir) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableInt(i int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableInt16(i int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableInt64(i int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableInt8(i int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNdir(h *http.Dir) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNillableInt(i *int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNillableInt16(i *int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNillableInt32(i *int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNillableInt64(i *int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNillableInt8(i *int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableNullActive(s *schema.Status) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalFloat(f *float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalFloat32(f *float32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalInt(i *int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalInt16(i *int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalInt32(i *int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalInt64(i *int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalInt8(i *int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalUint(u *uint) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalUint16(u *uint16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalUint32(u *uint32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalUint64(u *uint64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableOptionalUint8(u *uint8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableRole(r *role.Role) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableSchemaFloat(s *schema.Float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableSchemaFloat32(s *schema.Float32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableSchemaInt(s *schema.Int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableSchemaInt64(s *schema.Int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableSchemaInt8(s *schema.Int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableState(f *fieldtype.State) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNillableValidateOptionalInt32(i *int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNullActive(s schema.Status) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNullFloat(sf sql.NullFloat64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNullInt64(si sql.NullInt64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNullLink(s schema.Link) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetNullStr(ss sql.NullString) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalFloat(f float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalFloat32(f float32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalInt(i int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalInt16(i int16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalInt64(i int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalInt8(i int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalUint(u uint) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalUint16(u uint16) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalUint32(u uint32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalUint64(u uint64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetOptionalUint8(u uint8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetRole(r role.Role) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetSchemaFloat(s schema.Float64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetSchemaFloat32(s schema.Float32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetSchemaInt(s schema.Int) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetSchemaInt64(s schema.Int64) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetSchemaInt8(s schema.Int8) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetState(f fieldtype.State) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetStr(ss sql.NullString) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) SetValidateOptionalInt32(i int32) *FieldTypeUpdate
- func (ftu *FieldTypeUpdate) Where(ps ...predicate.FieldType) *FieldTypeUpdate
- type FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddDecimal(f float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddInt(i int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddInt16(i int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddInt64(i int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddInt8(i int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddNillableInt(i int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddNillableInt16(i int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddNillableInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddNillableInt64(i int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddNillableInt8(i int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalFloat(f float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalFloat32(f float32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalInt(i int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalInt16(i int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalInt64(i int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalInt8(i int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalUint(u uint) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalUint16(u uint16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalUint32(u uint32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalUint64(u uint64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddOptionalUint8(u uint8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddSchemaFloat(s schema.Float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddSchemaFloat32(s schema.Float32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddSchemaInt(s schema.Int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddSchemaInt64(s schema.Int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddSchemaInt8(s schema.Int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) AddValidateOptionalInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearActive() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearDatetime() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearDecimal() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearDeleted() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearDeletedAt() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearDir() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearIP() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearLink() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNdir() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNillableInt() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNillableInt16() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNillableInt32() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNillableInt64() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNillableInt8() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNullActive() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNullFloat() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNullInt64() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNullLink() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearNullStr() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalFloat() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalFloat32() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalInt() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalInt16() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalInt32() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalInt64() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalInt8() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalUint() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalUint16() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalUint32() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalUint64() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearOptionalUint8() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearSchemaFloat() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearSchemaFloat32() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearSchemaInt() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearSchemaInt64() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearSchemaInt8() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearState() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearStr() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) ClearValidateOptionalInt32() *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) Exec(ctx context.Context) error
- func (ftuo *FieldTypeUpdateOne) ExecX(ctx context.Context)
- func (ftuo *FieldTypeUpdateOne) Mutation() *FieldTypeMutation
- func (ftuo *FieldTypeUpdateOne) Save(ctx context.Context) (*FieldType, error)
- func (ftuo *FieldTypeUpdateOne) SaveX(ctx context.Context) *FieldType
- func (ftuo *FieldTypeUpdateOne) SetActive(s schema.Status) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetDatetime(t time.Time) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetDecimal(f float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetDeleted(sb sql.NullBool) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetDeletedAt(st sql.NullTime) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetDir(h http.Dir) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetIP(n net.IP) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetInt(i int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetInt16(i int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetInt64(i int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetInt8(i int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetLink(s schema.Link) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNdir(h http.Dir) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableActive(s *schema.Status) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableDatetime(t *time.Time) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableDecimal(f *float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableDir(h *http.Dir) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableInt(i int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableInt16(i int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableInt64(i int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableInt8(i int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNdir(h *http.Dir) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt(i *int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt16(i *int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt32(i *int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt64(i *int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt8(i *int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableNullActive(s *schema.Status) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalFloat(f *float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalFloat32(f *float32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt(i *int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt16(i *int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt32(i *int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt64(i *int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt8(i *int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint(u *uint) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint16(u *uint16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint32(u *uint32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint64(u *uint64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint8(u *uint8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableRole(r *role.Role) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableSchemaFloat(s *schema.Float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableSchemaFloat32(s *schema.Float32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableSchemaInt(s *schema.Int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableSchemaInt64(s *schema.Int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableSchemaInt8(s *schema.Int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableState(f *fieldtype.State) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNillableValidateOptionalInt32(i *int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNullActive(s schema.Status) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNullFloat(sf sql.NullFloat64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNullInt64(si sql.NullInt64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNullLink(s schema.Link) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetNullStr(ss sql.NullString) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalFloat(f float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalFloat32(f float32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalInt(i int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalInt16(i int16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalInt32(i int32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalInt64(i int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalInt8(i int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalUint(u uint) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalUint16(u uint16) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalUint32(u uint32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalUint64(u uint64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetOptionalUint8(u uint8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetRole(r role.Role) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetSchemaFloat(s schema.Float64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetSchemaFloat32(s schema.Float32) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetSchemaInt(s schema.Int) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetSchemaInt64(s schema.Int64) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetSchemaInt8(s schema.Int8) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetState(f fieldtype.State) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetStr(ss sql.NullString) *FieldTypeUpdateOne
- func (ftuo *FieldTypeUpdateOne) SetValidateOptionalInt32(i int32) *FieldTypeUpdateOne
- type FieldTypes
- type File
- type FileClient
- func (c *FileClient) Create() *FileCreate
- func (c *FileClient) CreateBulk(builders ...*FileCreate) *FileCreateBulk
- func (c *FileClient) Delete() *FileDelete
- func (c *FileClient) DeleteOne(f *File) *FileDeleteOne
- func (c *FileClient) DeleteOneID(id string) *FileDeleteOne
- func (c *FileClient) Get(ctx context.Context, id string) (*File, error)
- func (c *FileClient) GetX(ctx context.Context, id string) *File
- func (c *FileClient) Hooks() []Hook
- func (c *FileClient) Query() *FileQuery
- func (c *FileClient) QueryField(f *File) *FieldTypeQuery
- func (c *FileClient) QueryOwner(f *File) *UserQuery
- func (c *FileClient) QueryType(f *File) *FileTypeQuery
- func (c *FileClient) Update() *FileUpdate
- func (c *FileClient) UpdateOne(f *File) *FileUpdateOne
- func (c *FileClient) UpdateOneID(id string) *FileUpdateOne
- func (c *FileClient) Use(hooks ...Hook)
- type FileCreate
- func (fc *FileCreate) AddField(f ...*FieldType) *FileCreate
- func (fc *FileCreate) AddFieldIDs(ids ...string) *FileCreate
- func (fc *FileCreate) Mutation() *FileMutation
- func (fc *FileCreate) Save(ctx context.Context) (*File, error)
- func (fc *FileCreate) SaveX(ctx context.Context) *File
- func (fc *FileCreate) SetGroup(s string) *FileCreate
- func (fc *FileCreate) SetName(s string) *FileCreate
- func (fc *FileCreate) SetNillableGroup(s *string) *FileCreate
- func (fc *FileCreate) SetNillableOp(b *bool) *FileCreate
- func (fc *FileCreate) SetNillableOwnerID(id *string) *FileCreate
- func (fc *FileCreate) SetNillableSize(i *int) *FileCreate
- func (fc *FileCreate) SetNillableTypeID(id *string) *FileCreate
- func (fc *FileCreate) SetNillableUser(s *string) *FileCreate
- func (fc *FileCreate) SetOp(b bool) *FileCreate
- func (fc *FileCreate) SetOwner(u *User) *FileCreate
- func (fc *FileCreate) SetOwnerID(id string) *FileCreate
- func (fc *FileCreate) SetSize(i int) *FileCreate
- func (fc *FileCreate) SetType(f *FileType) *FileCreate
- func (fc *FileCreate) SetTypeID(id string) *FileCreate
- func (fc *FileCreate) SetUser(s string) *FileCreate
- type FileCreateBulk
- type FileDelete
- type FileDeleteOne
- type FileEdges
- type FileGroupBy
- func (fgb *FileGroupBy) Aggregate(fns ...AggregateFunc) *FileGroupBy
- func (fgb *FileGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (fgb *FileGroupBy) BoolX(ctx context.Context) bool
- func (fgb *FileGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (fgb *FileGroupBy) BoolsX(ctx context.Context) []bool
- func (fgb *FileGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (fgb *FileGroupBy) Float64X(ctx context.Context) float64
- func (fgb *FileGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (fgb *FileGroupBy) Float64sX(ctx context.Context) []float64
- func (fgb *FileGroupBy) Int(ctx context.Context) (_ int, err error)
- func (fgb *FileGroupBy) IntX(ctx context.Context) int
- func (fgb *FileGroupBy) Ints(ctx context.Context) ([]int, error)
- func (fgb *FileGroupBy) IntsX(ctx context.Context) []int
- func (fgb *FileGroupBy) Scan(ctx context.Context, v interface{}) error
- func (fgb *FileGroupBy) ScanX(ctx context.Context, v interface{})
- func (fgb *FileGroupBy) String(ctx context.Context) (_ string, err error)
- func (fgb *FileGroupBy) StringX(ctx context.Context) string
- func (fgb *FileGroupBy) Strings(ctx context.Context) ([]string, error)
- func (fgb *FileGroupBy) StringsX(ctx context.Context) []string
- type FileMutation
- func (m *FileMutation) AddField(name string, value ent.Value) error
- func (m *FileMutation) AddFieldIDs(ids ...string)
- func (m *FileMutation) AddSize(i int)
- func (m *FileMutation) AddedEdges() []string
- func (m *FileMutation) AddedField(name string) (ent.Value, bool)
- func (m *FileMutation) AddedFields() []string
- func (m *FileMutation) AddedIDs(name string) []ent.Value
- func (m *FileMutation) AddedSize() (r int, exists bool)
- func (m *FileMutation) ClearEdge(name string) error
- func (m *FileMutation) ClearField(name string) error
- func (m *FileMutation) ClearFieldEdge()
- func (m *FileMutation) ClearGroup()
- func (m *FileMutation) ClearOp()
- func (m *FileMutation) ClearOwner()
- func (m *FileMutation) ClearType()
- func (m *FileMutation) ClearUser()
- func (m *FileMutation) ClearedEdges() []string
- func (m *FileMutation) ClearedFields() []string
- func (m FileMutation) Client() *Client
- func (m *FileMutation) EdgeCleared(name string) bool
- func (m *FileMutation) Field(name string) (ent.Value, bool)
- func (m *FileMutation) FieldCleared(name string) bool
- func (m *FileMutation) FieldEdgeCleared() bool
- func (m *FileMutation) FieldIDs() (ids []string)
- func (m *FileMutation) Fields() []string
- func (m *FileMutation) GetOp() (r bool, exists bool)
- func (m *FileMutation) Group() (r string, exists bool)
- func (m *FileMutation) GroupCleared() bool
- func (m *FileMutation) ID() (id string, exists bool)
- func (m *FileMutation) Name() (r string, exists bool)
- func (m *FileMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *FileMutation) OldGroup(ctx context.Context) (v string, err error)
- func (m *FileMutation) OldName(ctx context.Context) (v string, err error)
- func (m *FileMutation) OldOp(ctx context.Context) (v bool, err error)
- func (m *FileMutation) OldSize(ctx context.Context) (v int, err error)
- func (m *FileMutation) OldUser(ctx context.Context) (v *string, err error)
- func (m *FileMutation) Op() Op
- func (m *FileMutation) OpCleared() bool
- func (m *FileMutation) OwnerCleared() bool
- func (m *FileMutation) OwnerID() (id string, exists bool)
- func (m *FileMutation) OwnerIDs() (ids []string)
- func (m *FileMutation) RemoveFieldIDs(ids ...string)
- func (m *FileMutation) RemovedEdges() []string
- func (m *FileMutation) RemovedFieldIDs() (ids []string)
- func (m *FileMutation) RemovedIDs(name string) []ent.Value
- func (m *FileMutation) ResetEdge(name string) error
- func (m *FileMutation) ResetField(name string) error
- func (m *FileMutation) ResetFieldEdge()
- func (m *FileMutation) ResetGroup()
- func (m *FileMutation) ResetName()
- func (m *FileMutation) ResetOp()
- func (m *FileMutation) ResetOwner()
- func (m *FileMutation) ResetSize()
- func (m *FileMutation) ResetType()
- func (m *FileMutation) ResetUser()
- func (m *FileMutation) SetField(name string, value ent.Value) error
- func (m *FileMutation) SetGroup(s string)
- func (m *FileMutation) SetName(s string)
- func (m *FileMutation) SetOp(b bool)
- func (m *FileMutation) SetOwnerID(id string)
- func (m *FileMutation) SetSize(i int)
- func (m *FileMutation) SetTypeID(id string)
- func (m *FileMutation) SetUser(s string)
- func (m *FileMutation) Size() (r int, exists bool)
- func (m FileMutation) Tx() (*Tx, error)
- func (m *FileMutation) Type() string
- func (m *FileMutation) TypeCleared() bool
- func (m *FileMutation) TypeID() (id string, exists bool)
- func (m *FileMutation) TypeIDs() (ids []string)
- func (m *FileMutation) User() (r string, exists bool)
- func (m *FileMutation) UserCleared() bool
- type FileQuery
- func (fq *FileQuery) All(ctx context.Context) ([]*File, error)
- func (fq *FileQuery) AllX(ctx context.Context) []*File
- func (fq *FileQuery) Clone() *FileQuery
- func (fq *FileQuery) Count(ctx context.Context) (int, error)
- func (fq *FileQuery) CountX(ctx context.Context) int
- func (fq *FileQuery) Exist(ctx context.Context) (bool, error)
- func (fq *FileQuery) ExistX(ctx context.Context) bool
- func (fq *FileQuery) First(ctx context.Context) (*File, error)
- func (fq *FileQuery) FirstID(ctx context.Context) (id string, err error)
- func (fq *FileQuery) FirstIDX(ctx context.Context) string
- func (fq *FileQuery) FirstX(ctx context.Context) *File
- func (fq *FileQuery) GroupBy(field string, fields ...string) *FileGroupBy
- func (fq *FileQuery) IDs(ctx context.Context) ([]string, error)
- func (fq *FileQuery) IDsX(ctx context.Context) []string
- func (fq *FileQuery) Limit(limit int) *FileQuery
- func (fq *FileQuery) Offset(offset int) *FileQuery
- func (fq *FileQuery) Only(ctx context.Context) (*File, error)
- func (fq *FileQuery) OnlyID(ctx context.Context) (id string, err error)
- func (fq *FileQuery) OnlyIDX(ctx context.Context) string
- func (fq *FileQuery) OnlyX(ctx context.Context) *File
- func (fq *FileQuery) Order(o ...OrderFunc) *FileQuery
- func (fq *FileQuery) QueryField() *FieldTypeQuery
- func (fq *FileQuery) QueryOwner() *UserQuery
- func (fq *FileQuery) QueryType() *FileTypeQuery
- func (fq *FileQuery) Select(field string, fields ...string) *FileSelect
- func (fq *FileQuery) Where(ps ...predicate.File) *FileQuery
- func (fq *FileQuery) WithField(opts ...func(*FieldTypeQuery)) *FileQuery
- func (fq *FileQuery) WithOwner(opts ...func(*UserQuery)) *FileQuery
- func (fq *FileQuery) WithType(opts ...func(*FileTypeQuery)) *FileQuery
- type FileSelect
- func (fs *FileSelect) Bool(ctx context.Context) (_ bool, err error)
- func (fs *FileSelect) BoolX(ctx context.Context) bool
- func (fs *FileSelect) Bools(ctx context.Context) ([]bool, error)
- func (fs *FileSelect) BoolsX(ctx context.Context) []bool
- func (fs *FileSelect) Float64(ctx context.Context) (_ float64, err error)
- func (fs *FileSelect) Float64X(ctx context.Context) float64
- func (fs *FileSelect) Float64s(ctx context.Context) ([]float64, error)
- func (fs *FileSelect) Float64sX(ctx context.Context) []float64
- func (fs *FileSelect) Int(ctx context.Context) (_ int, err error)
- func (fs *FileSelect) IntX(ctx context.Context) int
- func (fs *FileSelect) Ints(ctx context.Context) ([]int, error)
- func (fs *FileSelect) IntsX(ctx context.Context) []int
- func (fs *FileSelect) Scan(ctx context.Context, v interface{}) error
- func (fs *FileSelect) ScanX(ctx context.Context, v interface{})
- func (fs *FileSelect) String(ctx context.Context) (_ string, err error)
- func (fs *FileSelect) StringX(ctx context.Context) string
- func (fs *FileSelect) Strings(ctx context.Context) ([]string, error)
- func (fs *FileSelect) StringsX(ctx context.Context) []string
- type FileType
- type FileTypeClient
- func (c *FileTypeClient) Create() *FileTypeCreate
- func (c *FileTypeClient) CreateBulk(builders ...*FileTypeCreate) *FileTypeCreateBulk
- func (c *FileTypeClient) Delete() *FileTypeDelete
- func (c *FileTypeClient) DeleteOne(ft *FileType) *FileTypeDeleteOne
- func (c *FileTypeClient) DeleteOneID(id string) *FileTypeDeleteOne
- func (c *FileTypeClient) Get(ctx context.Context, id string) (*FileType, error)
- func (c *FileTypeClient) GetX(ctx context.Context, id string) *FileType
- func (c *FileTypeClient) Hooks() []Hook
- func (c *FileTypeClient) Query() *FileTypeQuery
- func (c *FileTypeClient) QueryFiles(ft *FileType) *FileQuery
- func (c *FileTypeClient) Update() *FileTypeUpdate
- func (c *FileTypeClient) UpdateOne(ft *FileType) *FileTypeUpdateOne
- func (c *FileTypeClient) UpdateOneID(id string) *FileTypeUpdateOne
- func (c *FileTypeClient) Use(hooks ...Hook)
- type FileTypeCreate
- func (ftc *FileTypeCreate) AddFileIDs(ids ...string) *FileTypeCreate
- func (ftc *FileTypeCreate) AddFiles(f ...*File) *FileTypeCreate
- func (ftc *FileTypeCreate) Mutation() *FileTypeMutation
- func (ftc *FileTypeCreate) Save(ctx context.Context) (*FileType, error)
- func (ftc *FileTypeCreate) SaveX(ctx context.Context) *FileType
- func (ftc *FileTypeCreate) SetName(s string) *FileTypeCreate
- func (ftc *FileTypeCreate) SetNillableState(f *filetype.State) *FileTypeCreate
- func (ftc *FileTypeCreate) SetNillableType(f *filetype.Type) *FileTypeCreate
- func (ftc *FileTypeCreate) SetState(f filetype.State) *FileTypeCreate
- func (ftc *FileTypeCreate) SetType(f filetype.Type) *FileTypeCreate
- type FileTypeCreateBulk
- type FileTypeDelete
- type FileTypeDeleteOne
- type FileTypeEdges
- type FileTypeGroupBy
- func (ftgb *FileTypeGroupBy) Aggregate(fns ...AggregateFunc) *FileTypeGroupBy
- func (ftgb *FileTypeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ftgb *FileTypeGroupBy) BoolX(ctx context.Context) bool
- func (ftgb *FileTypeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ftgb *FileTypeGroupBy) BoolsX(ctx context.Context) []bool
- func (ftgb *FileTypeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ftgb *FileTypeGroupBy) Float64X(ctx context.Context) float64
- func (ftgb *FileTypeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ftgb *FileTypeGroupBy) Float64sX(ctx context.Context) []float64
- func (ftgb *FileTypeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ftgb *FileTypeGroupBy) IntX(ctx context.Context) int
- func (ftgb *FileTypeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ftgb *FileTypeGroupBy) IntsX(ctx context.Context) []int
- func (ftgb *FileTypeGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ftgb *FileTypeGroupBy) ScanX(ctx context.Context, v interface{})
- func (ftgb *FileTypeGroupBy) String(ctx context.Context) (_ string, err error)
- func (ftgb *FileTypeGroupBy) StringX(ctx context.Context) string
- func (ftgb *FileTypeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ftgb *FileTypeGroupBy) StringsX(ctx context.Context) []string
- type FileTypeMutation
- func (m *FileTypeMutation) AddField(name string, value ent.Value) error
- func (m *FileTypeMutation) AddFileIDs(ids ...string)
- func (m *FileTypeMutation) AddedEdges() []string
- func (m *FileTypeMutation) AddedField(name string) (ent.Value, bool)
- func (m *FileTypeMutation) AddedFields() []string
- func (m *FileTypeMutation) AddedIDs(name string) []ent.Value
- func (m *FileTypeMutation) ClearEdge(name string) error
- func (m *FileTypeMutation) ClearField(name string) error
- func (m *FileTypeMutation) ClearFiles()
- func (m *FileTypeMutation) ClearedEdges() []string
- func (m *FileTypeMutation) ClearedFields() []string
- func (m FileTypeMutation) Client() *Client
- func (m *FileTypeMutation) EdgeCleared(name string) bool
- func (m *FileTypeMutation) Field(name string) (ent.Value, bool)
- func (m *FileTypeMutation) FieldCleared(name string) bool
- func (m *FileTypeMutation) Fields() []string
- func (m *FileTypeMutation) FilesCleared() bool
- func (m *FileTypeMutation) FilesIDs() (ids []string)
- func (m *FileTypeMutation) GetType() (r filetype.Type, exists bool)
- func (m *FileTypeMutation) ID() (id string, exists bool)
- func (m *FileTypeMutation) Name() (r string, exists bool)
- func (m *FileTypeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *FileTypeMutation) OldName(ctx context.Context) (v string, err error)
- func (m *FileTypeMutation) OldState(ctx context.Context) (v filetype.State, err error)
- func (m *FileTypeMutation) OldType(ctx context.Context) (v filetype.Type, err error)
- func (m *FileTypeMutation) Op() Op
- func (m *FileTypeMutation) RemoveFileIDs(ids ...string)
- func (m *FileTypeMutation) RemovedEdges() []string
- func (m *FileTypeMutation) RemovedFilesIDs() (ids []string)
- func (m *FileTypeMutation) RemovedIDs(name string) []ent.Value
- func (m *FileTypeMutation) ResetEdge(name string) error
- func (m *FileTypeMutation) ResetField(name string) error
- func (m *FileTypeMutation) ResetFiles()
- func (m *FileTypeMutation) ResetName()
- func (m *FileTypeMutation) ResetState()
- func (m *FileTypeMutation) ResetType()
- func (m *FileTypeMutation) SetField(name string, value ent.Value) error
- func (m *FileTypeMutation) SetName(s string)
- func (m *FileTypeMutation) SetState(f filetype.State)
- func (m *FileTypeMutation) SetType(f filetype.Type)
- func (m *FileTypeMutation) State() (r filetype.State, exists bool)
- func (m FileTypeMutation) Tx() (*Tx, error)
- func (m *FileTypeMutation) Type() string
- type FileTypeQuery
- func (ftq *FileTypeQuery) All(ctx context.Context) ([]*FileType, error)
- func (ftq *FileTypeQuery) AllX(ctx context.Context) []*FileType
- func (ftq *FileTypeQuery) Clone() *FileTypeQuery
- func (ftq *FileTypeQuery) Count(ctx context.Context) (int, error)
- func (ftq *FileTypeQuery) CountX(ctx context.Context) int
- func (ftq *FileTypeQuery) Exist(ctx context.Context) (bool, error)
- func (ftq *FileTypeQuery) ExistX(ctx context.Context) bool
- func (ftq *FileTypeQuery) First(ctx context.Context) (*FileType, error)
- func (ftq *FileTypeQuery) FirstID(ctx context.Context) (id string, err error)
- func (ftq *FileTypeQuery) FirstIDX(ctx context.Context) string
- func (ftq *FileTypeQuery) FirstX(ctx context.Context) *FileType
- func (ftq *FileTypeQuery) GroupBy(field string, fields ...string) *FileTypeGroupBy
- func (ftq *FileTypeQuery) IDs(ctx context.Context) ([]string, error)
- func (ftq *FileTypeQuery) IDsX(ctx context.Context) []string
- func (ftq *FileTypeQuery) Limit(limit int) *FileTypeQuery
- func (ftq *FileTypeQuery) Offset(offset int) *FileTypeQuery
- func (ftq *FileTypeQuery) Only(ctx context.Context) (*FileType, error)
- func (ftq *FileTypeQuery) OnlyID(ctx context.Context) (id string, err error)
- func (ftq *FileTypeQuery) OnlyIDX(ctx context.Context) string
- func (ftq *FileTypeQuery) OnlyX(ctx context.Context) *FileType
- func (ftq *FileTypeQuery) Order(o ...OrderFunc) *FileTypeQuery
- func (ftq *FileTypeQuery) QueryFiles() *FileQuery
- func (ftq *FileTypeQuery) Select(field string, fields ...string) *FileTypeSelect
- func (ftq *FileTypeQuery) Where(ps ...predicate.FileType) *FileTypeQuery
- func (ftq *FileTypeQuery) WithFiles(opts ...func(*FileQuery)) *FileTypeQuery
- type FileTypeSelect
- func (fts *FileTypeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (fts *FileTypeSelect) BoolX(ctx context.Context) bool
- func (fts *FileTypeSelect) Bools(ctx context.Context) ([]bool, error)
- func (fts *FileTypeSelect) BoolsX(ctx context.Context) []bool
- func (fts *FileTypeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (fts *FileTypeSelect) Float64X(ctx context.Context) float64
- func (fts *FileTypeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (fts *FileTypeSelect) Float64sX(ctx context.Context) []float64
- func (fts *FileTypeSelect) Int(ctx context.Context) (_ int, err error)
- func (fts *FileTypeSelect) IntX(ctx context.Context) int
- func (fts *FileTypeSelect) Ints(ctx context.Context) ([]int, error)
- func (fts *FileTypeSelect) IntsX(ctx context.Context) []int
- func (fts *FileTypeSelect) Scan(ctx context.Context, v interface{}) error
- func (fts *FileTypeSelect) ScanX(ctx context.Context, v interface{})
- func (fts *FileTypeSelect) String(ctx context.Context) (_ string, err error)
- func (fts *FileTypeSelect) StringX(ctx context.Context) string
- func (fts *FileTypeSelect) Strings(ctx context.Context) ([]string, error)
- func (fts *FileTypeSelect) StringsX(ctx context.Context) []string
- type FileTypeUpdate
- func (ftu *FileTypeUpdate) AddFileIDs(ids ...string) *FileTypeUpdate
- func (ftu *FileTypeUpdate) AddFiles(f ...*File) *FileTypeUpdate
- func (ftu *FileTypeUpdate) ClearFiles() *FileTypeUpdate
- func (ftu *FileTypeUpdate) Exec(ctx context.Context) error
- func (ftu *FileTypeUpdate) ExecX(ctx context.Context)
- func (ftu *FileTypeUpdate) Mutation() *FileTypeMutation
- func (ftu *FileTypeUpdate) RemoveFileIDs(ids ...string) *FileTypeUpdate
- func (ftu *FileTypeUpdate) RemoveFiles(f ...*File) *FileTypeUpdate
- func (ftu *FileTypeUpdate) Save(ctx context.Context) (int, error)
- func (ftu *FileTypeUpdate) SaveX(ctx context.Context) int
- func (ftu *FileTypeUpdate) SetName(s string) *FileTypeUpdate
- func (ftu *FileTypeUpdate) SetNillableState(f *filetype.State) *FileTypeUpdate
- func (ftu *FileTypeUpdate) SetNillableType(f *filetype.Type) *FileTypeUpdate
- func (ftu *FileTypeUpdate) SetState(f filetype.State) *FileTypeUpdate
- func (ftu *FileTypeUpdate) SetType(f filetype.Type) *FileTypeUpdate
- func (ftu *FileTypeUpdate) Where(ps ...predicate.FileType) *FileTypeUpdate
- type FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) AddFileIDs(ids ...string) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) AddFiles(f ...*File) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) ClearFiles() *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) Exec(ctx context.Context) error
- func (ftuo *FileTypeUpdateOne) ExecX(ctx context.Context)
- func (ftuo *FileTypeUpdateOne) Mutation() *FileTypeMutation
- func (ftuo *FileTypeUpdateOne) RemoveFileIDs(ids ...string) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) RemoveFiles(f ...*File) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) Save(ctx context.Context) (*FileType, error)
- func (ftuo *FileTypeUpdateOne) SaveX(ctx context.Context) *FileType
- func (ftuo *FileTypeUpdateOne) SetName(s string) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) SetNillableState(f *filetype.State) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) SetNillableType(f *filetype.Type) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) SetState(f filetype.State) *FileTypeUpdateOne
- func (ftuo *FileTypeUpdateOne) SetType(f filetype.Type) *FileTypeUpdateOne
- type FileTypes
- type FileUpdate
- func (fu *FileUpdate) AddField(f ...*FieldType) *FileUpdate
- func (fu *FileUpdate) AddFieldIDs(ids ...string) *FileUpdate
- func (fu *FileUpdate) AddSize(i int) *FileUpdate
- func (fu *FileUpdate) ClearFieldEdge() *FileUpdate
- func (fu *FileUpdate) ClearGroup() *FileUpdate
- func (fu *FileUpdate) ClearOp() *FileUpdate
- func (fu *FileUpdate) ClearOwner() *FileUpdate
- func (fu *FileUpdate) ClearType() *FileUpdate
- func (fu *FileUpdate) ClearUser() *FileUpdate
- func (fu *FileUpdate) Exec(ctx context.Context) error
- func (fu *FileUpdate) ExecX(ctx context.Context)
- func (fu *FileUpdate) Mutation() *FileMutation
- func (fu *FileUpdate) RemoveField(f ...*FieldType) *FileUpdate
- func (fu *FileUpdate) RemoveFieldIDs(ids ...string) *FileUpdate
- func (fu *FileUpdate) Save(ctx context.Context) (int, error)
- func (fu *FileUpdate) SaveX(ctx context.Context) int
- func (fu *FileUpdate) SetGroup(s string) *FileUpdate
- func (fu *FileUpdate) SetName(s string) *FileUpdate
- func (fu *FileUpdate) SetNillableGroup(s *string) *FileUpdate
- func (fu *FileUpdate) SetNillableOp(b *bool) *FileUpdate
- func (fu *FileUpdate) SetNillableOwnerID(id *string) *FileUpdate
- func (fu *FileUpdate) SetNillableSize(i *int) *FileUpdate
- func (fu *FileUpdate) SetNillableTypeID(id *string) *FileUpdate
- func (fu *FileUpdate) SetNillableUser(s *string) *FileUpdate
- func (fu *FileUpdate) SetOp(b bool) *FileUpdate
- func (fu *FileUpdate) SetOwner(u *User) *FileUpdate
- func (fu *FileUpdate) SetOwnerID(id string) *FileUpdate
- func (fu *FileUpdate) SetSize(i int) *FileUpdate
- func (fu *FileUpdate) SetType(f *FileType) *FileUpdate
- func (fu *FileUpdate) SetTypeID(id string) *FileUpdate
- func (fu *FileUpdate) SetUser(s string) *FileUpdate
- func (fu *FileUpdate) Where(ps ...predicate.File) *FileUpdate
- type FileUpdateOne
- func (fuo *FileUpdateOne) AddField(f ...*FieldType) *FileUpdateOne
- func (fuo *FileUpdateOne) AddFieldIDs(ids ...string) *FileUpdateOne
- func (fuo *FileUpdateOne) AddSize(i int) *FileUpdateOne
- func (fuo *FileUpdateOne) ClearFieldEdge() *FileUpdateOne
- func (fuo *FileUpdateOne) ClearGroup() *FileUpdateOne
- func (fuo *FileUpdateOne) ClearOp() *FileUpdateOne
- func (fuo *FileUpdateOne) ClearOwner() *FileUpdateOne
- func (fuo *FileUpdateOne) ClearType() *FileUpdateOne
- func (fuo *FileUpdateOne) ClearUser() *FileUpdateOne
- func (fuo *FileUpdateOne) Exec(ctx context.Context) error
- func (fuo *FileUpdateOne) ExecX(ctx context.Context)
- func (fuo *FileUpdateOne) Mutation() *FileMutation
- func (fuo *FileUpdateOne) RemoveField(f ...*FieldType) *FileUpdateOne
- func (fuo *FileUpdateOne) RemoveFieldIDs(ids ...string) *FileUpdateOne
- func (fuo *FileUpdateOne) Save(ctx context.Context) (*File, error)
- func (fuo *FileUpdateOne) SaveX(ctx context.Context) *File
- func (fuo *FileUpdateOne) SetGroup(s string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetName(s string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetNillableGroup(s *string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetNillableOp(b *bool) *FileUpdateOne
- func (fuo *FileUpdateOne) SetNillableOwnerID(id *string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetNillableSize(i *int) *FileUpdateOne
- func (fuo *FileUpdateOne) SetNillableTypeID(id *string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetNillableUser(s *string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetOp(b bool) *FileUpdateOne
- func (fuo *FileUpdateOne) SetOwner(u *User) *FileUpdateOne
- func (fuo *FileUpdateOne) SetOwnerID(id string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetSize(i int) *FileUpdateOne
- func (fuo *FileUpdateOne) SetType(f *FileType) *FileUpdateOne
- func (fuo *FileUpdateOne) SetTypeID(id string) *FileUpdateOne
- func (fuo *FileUpdateOne) SetUser(s string) *FileUpdateOne
- type Files
- type Goods
- type GoodsClient
- func (c *GoodsClient) Create() *GoodsCreate
- func (c *GoodsClient) CreateBulk(builders ...*GoodsCreate) *GoodsCreateBulk
- func (c *GoodsClient) Delete() *GoodsDelete
- func (c *GoodsClient) DeleteOne(_go *Goods) *GoodsDeleteOne
- func (c *GoodsClient) DeleteOneID(id string) *GoodsDeleteOne
- func (c *GoodsClient) Get(ctx context.Context, id string) (*Goods, error)
- func (c *GoodsClient) GetX(ctx context.Context, id string) *Goods
- func (c *GoodsClient) Hooks() []Hook
- func (c *GoodsClient) Query() *GoodsQuery
- func (c *GoodsClient) Update() *GoodsUpdate
- func (c *GoodsClient) UpdateOne(_go *Goods) *GoodsUpdateOne
- func (c *GoodsClient) UpdateOneID(id string) *GoodsUpdateOne
- func (c *GoodsClient) Use(hooks ...Hook)
- type GoodsCreate
- type GoodsCreateBulk
- type GoodsDelete
- type GoodsDeleteOne
- type GoodsGroupBy
- func (ggb *GoodsGroupBy) Aggregate(fns ...AggregateFunc) *GoodsGroupBy
- func (ggb *GoodsGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ggb *GoodsGroupBy) BoolX(ctx context.Context) bool
- func (ggb *GoodsGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ggb *GoodsGroupBy) BoolsX(ctx context.Context) []bool
- func (ggb *GoodsGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ggb *GoodsGroupBy) Float64X(ctx context.Context) float64
- func (ggb *GoodsGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ggb *GoodsGroupBy) Float64sX(ctx context.Context) []float64
- func (ggb *GoodsGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ggb *GoodsGroupBy) IntX(ctx context.Context) int
- func (ggb *GoodsGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ggb *GoodsGroupBy) IntsX(ctx context.Context) []int
- func (ggb *GoodsGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ggb *GoodsGroupBy) ScanX(ctx context.Context, v interface{})
- func (ggb *GoodsGroupBy) String(ctx context.Context) (_ string, err error)
- func (ggb *GoodsGroupBy) StringX(ctx context.Context) string
- func (ggb *GoodsGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ggb *GoodsGroupBy) StringsX(ctx context.Context) []string
- type GoodsMutation
- func (m *GoodsMutation) AddField(name string, value ent.Value) error
- func (m *GoodsMutation) AddedEdges() []string
- func (m *GoodsMutation) AddedField(name string) (ent.Value, bool)
- func (m *GoodsMutation) AddedFields() []string
- func (m *GoodsMutation) AddedIDs(name string) []ent.Value
- func (m *GoodsMutation) ClearEdge(name string) error
- func (m *GoodsMutation) ClearField(name string) error
- func (m *GoodsMutation) ClearedEdges() []string
- func (m *GoodsMutation) ClearedFields() []string
- func (m GoodsMutation) Client() *Client
- func (m *GoodsMutation) EdgeCleared(name string) bool
- func (m *GoodsMutation) Field(name string) (ent.Value, bool)
- func (m *GoodsMutation) FieldCleared(name string) bool
- func (m *GoodsMutation) Fields() []string
- func (m *GoodsMutation) ID() (id string, exists bool)
- func (m *GoodsMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *GoodsMutation) Op() Op
- func (m *GoodsMutation) RemovedEdges() []string
- func (m *GoodsMutation) RemovedIDs(name string) []ent.Value
- func (m *GoodsMutation) ResetEdge(name string) error
- func (m *GoodsMutation) ResetField(name string) error
- func (m *GoodsMutation) SetField(name string, value ent.Value) error
- func (m GoodsMutation) Tx() (*Tx, error)
- func (m *GoodsMutation) Type() string
- type GoodsQuery
- func (gq *GoodsQuery) All(ctx context.Context) ([]*Goods, error)
- func (gq *GoodsQuery) AllX(ctx context.Context) []*Goods
- func (gq *GoodsQuery) Clone() *GoodsQuery
- func (gq *GoodsQuery) Count(ctx context.Context) (int, error)
- func (gq *GoodsQuery) CountX(ctx context.Context) int
- func (gq *GoodsQuery) Exist(ctx context.Context) (bool, error)
- func (gq *GoodsQuery) ExistX(ctx context.Context) bool
- func (gq *GoodsQuery) First(ctx context.Context) (*Goods, error)
- func (gq *GoodsQuery) FirstID(ctx context.Context) (id string, err error)
- func (gq *GoodsQuery) FirstIDX(ctx context.Context) string
- func (gq *GoodsQuery) FirstX(ctx context.Context) *Goods
- func (gq *GoodsQuery) GroupBy(field string, fields ...string) *GoodsGroupBy
- func (gq *GoodsQuery) IDs(ctx context.Context) ([]string, error)
- func (gq *GoodsQuery) IDsX(ctx context.Context) []string
- func (gq *GoodsQuery) Limit(limit int) *GoodsQuery
- func (gq *GoodsQuery) Offset(offset int) *GoodsQuery
- func (gq *GoodsQuery) Only(ctx context.Context) (*Goods, error)
- func (gq *GoodsQuery) OnlyID(ctx context.Context) (id string, err error)
- func (gq *GoodsQuery) OnlyIDX(ctx context.Context) string
- func (gq *GoodsQuery) OnlyX(ctx context.Context) *Goods
- func (gq *GoodsQuery) Order(o ...OrderFunc) *GoodsQuery
- func (gq *GoodsQuery) Select(field string, fields ...string) *GoodsSelect
- func (gq *GoodsQuery) Where(ps ...predicate.Goods) *GoodsQuery
- type GoodsSelect
- func (gs *GoodsSelect) Bool(ctx context.Context) (_ bool, err error)
- func (gs *GoodsSelect) BoolX(ctx context.Context) bool
- func (gs *GoodsSelect) Bools(ctx context.Context) ([]bool, error)
- func (gs *GoodsSelect) BoolsX(ctx context.Context) []bool
- func (gs *GoodsSelect) Float64(ctx context.Context) (_ float64, err error)
- func (gs *GoodsSelect) Float64X(ctx context.Context) float64
- func (gs *GoodsSelect) Float64s(ctx context.Context) ([]float64, error)
- func (gs *GoodsSelect) Float64sX(ctx context.Context) []float64
- func (gs *GoodsSelect) Int(ctx context.Context) (_ int, err error)
- func (gs *GoodsSelect) IntX(ctx context.Context) int
- func (gs *GoodsSelect) Ints(ctx context.Context) ([]int, error)
- func (gs *GoodsSelect) IntsX(ctx context.Context) []int
- func (gs *GoodsSelect) Scan(ctx context.Context, v interface{}) error
- func (gs *GoodsSelect) ScanX(ctx context.Context, v interface{})
- func (gs *GoodsSelect) String(ctx context.Context) (_ string, err error)
- func (gs *GoodsSelect) StringX(ctx context.Context) string
- func (gs *GoodsSelect) Strings(ctx context.Context) ([]string, error)
- func (gs *GoodsSelect) StringsX(ctx context.Context) []string
- type GoodsSlice
- type GoodsUpdate
- func (gu *GoodsUpdate) Exec(ctx context.Context) error
- func (gu *GoodsUpdate) ExecX(ctx context.Context)
- func (gu *GoodsUpdate) Mutation() *GoodsMutation
- func (gu *GoodsUpdate) Save(ctx context.Context) (int, error)
- func (gu *GoodsUpdate) SaveX(ctx context.Context) int
- func (gu *GoodsUpdate) Where(ps ...predicate.Goods) *GoodsUpdate
- type GoodsUpdateOne
- type Group
- func (gr *Group) FromResponse(res *gremlin.Response) error
- func (gr *Group) QueryBlocked() *UserQuery
- func (gr *Group) QueryFiles() *FileQuery
- func (gr *Group) QueryInfo() *GroupInfoQuery
- func (gr *Group) QueryUsers() *UserQuery
- func (gr *Group) String() string
- func (gr *Group) Unwrap() *Group
- func (gr *Group) Update() *GroupUpdateOne
- type GroupClient
- func (c *GroupClient) Create() *GroupCreate
- func (c *GroupClient) CreateBulk(builders ...*GroupCreate) *GroupCreateBulk
- func (c *GroupClient) Delete() *GroupDelete
- func (c *GroupClient) DeleteOne(gr *Group) *GroupDeleteOne
- func (c *GroupClient) DeleteOneID(id string) *GroupDeleteOne
- func (c *GroupClient) Get(ctx context.Context, id string) (*Group, error)
- func (c *GroupClient) GetX(ctx context.Context, id string) *Group
- func (c *GroupClient) Hooks() []Hook
- func (c *GroupClient) Query() *GroupQuery
- func (c *GroupClient) QueryBlocked(gr *Group) *UserQuery
- func (c *GroupClient) QueryFiles(gr *Group) *FileQuery
- func (c *GroupClient) QueryInfo(gr *Group) *GroupInfoQuery
- func (c *GroupClient) QueryUsers(gr *Group) *UserQuery
- func (c *GroupClient) Update() *GroupUpdate
- func (c *GroupClient) UpdateOne(gr *Group) *GroupUpdateOne
- func (c *GroupClient) UpdateOneID(id string) *GroupUpdateOne
- func (c *GroupClient) Use(hooks ...Hook)
- type GroupCreate
- func (gc *GroupCreate) AddBlocked(u ...*User) *GroupCreate
- func (gc *GroupCreate) AddBlockedIDs(ids ...string) *GroupCreate
- func (gc *GroupCreate) AddFileIDs(ids ...string) *GroupCreate
- func (gc *GroupCreate) AddFiles(f ...*File) *GroupCreate
- func (gc *GroupCreate) AddUserIDs(ids ...string) *GroupCreate
- func (gc *GroupCreate) AddUsers(u ...*User) *GroupCreate
- func (gc *GroupCreate) Mutation() *GroupMutation
- func (gc *GroupCreate) Save(ctx context.Context) (*Group, error)
- func (gc *GroupCreate) SaveX(ctx context.Context) *Group
- func (gc *GroupCreate) SetActive(b bool) *GroupCreate
- func (gc *GroupCreate) SetExpire(t time.Time) *GroupCreate
- func (gc *GroupCreate) SetInfo(g *GroupInfo) *GroupCreate
- func (gc *GroupCreate) SetInfoID(id string) *GroupCreate
- func (gc *GroupCreate) SetMaxUsers(i int) *GroupCreate
- func (gc *GroupCreate) SetName(s string) *GroupCreate
- func (gc *GroupCreate) SetNillableActive(b *bool) *GroupCreate
- func (gc *GroupCreate) SetNillableMaxUsers(i *int) *GroupCreate
- func (gc *GroupCreate) SetNillableType(s *string) *GroupCreate
- func (gc *GroupCreate) SetType(s string) *GroupCreate
- type GroupCreateBulk
- type GroupDelete
- type GroupDeleteOne
- type GroupEdges
- type GroupGroupBy
- func (ggb *GroupGroupBy) Aggregate(fns ...AggregateFunc) *GroupGroupBy
- func (ggb *GroupGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ggb *GroupGroupBy) BoolX(ctx context.Context) bool
- func (ggb *GroupGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ggb *GroupGroupBy) BoolsX(ctx context.Context) []bool
- func (ggb *GroupGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ggb *GroupGroupBy) Float64X(ctx context.Context) float64
- func (ggb *GroupGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ggb *GroupGroupBy) Float64sX(ctx context.Context) []float64
- func (ggb *GroupGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ggb *GroupGroupBy) IntX(ctx context.Context) int
- func (ggb *GroupGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ggb *GroupGroupBy) IntsX(ctx context.Context) []int
- func (ggb *GroupGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ggb *GroupGroupBy) ScanX(ctx context.Context, v interface{})
- func (ggb *GroupGroupBy) String(ctx context.Context) (_ string, err error)
- func (ggb *GroupGroupBy) StringX(ctx context.Context) string
- func (ggb *GroupGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ggb *GroupGroupBy) StringsX(ctx context.Context) []string
- type GroupInfo
- type GroupInfoClient
- func (c *GroupInfoClient) Create() *GroupInfoCreate
- func (c *GroupInfoClient) CreateBulk(builders ...*GroupInfoCreate) *GroupInfoCreateBulk
- func (c *GroupInfoClient) Delete() *GroupInfoDelete
- func (c *GroupInfoClient) DeleteOne(gi *GroupInfo) *GroupInfoDeleteOne
- func (c *GroupInfoClient) DeleteOneID(id string) *GroupInfoDeleteOne
- func (c *GroupInfoClient) Get(ctx context.Context, id string) (*GroupInfo, error)
- func (c *GroupInfoClient) GetX(ctx context.Context, id string) *GroupInfo
- func (c *GroupInfoClient) Hooks() []Hook
- func (c *GroupInfoClient) Query() *GroupInfoQuery
- func (c *GroupInfoClient) QueryGroups(gi *GroupInfo) *GroupQuery
- func (c *GroupInfoClient) Update() *GroupInfoUpdate
- func (c *GroupInfoClient) UpdateOne(gi *GroupInfo) *GroupInfoUpdateOne
- func (c *GroupInfoClient) UpdateOneID(id string) *GroupInfoUpdateOne
- func (c *GroupInfoClient) Use(hooks ...Hook)
- type GroupInfoCreate
- func (gic *GroupInfoCreate) AddGroupIDs(ids ...string) *GroupInfoCreate
- func (gic *GroupInfoCreate) AddGroups(g ...*Group) *GroupInfoCreate
- func (gic *GroupInfoCreate) Mutation() *GroupInfoMutation
- func (gic *GroupInfoCreate) Save(ctx context.Context) (*GroupInfo, error)
- func (gic *GroupInfoCreate) SaveX(ctx context.Context) *GroupInfo
- func (gic *GroupInfoCreate) SetDesc(s string) *GroupInfoCreate
- func (gic *GroupInfoCreate) SetMaxUsers(i int) *GroupInfoCreate
- func (gic *GroupInfoCreate) SetNillableMaxUsers(i *int) *GroupInfoCreate
- type GroupInfoCreateBulk
- type GroupInfoDelete
- type GroupInfoDeleteOne
- type GroupInfoEdges
- type GroupInfoGroupBy
- func (gigb *GroupInfoGroupBy) Aggregate(fns ...AggregateFunc) *GroupInfoGroupBy
- func (gigb *GroupInfoGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (gigb *GroupInfoGroupBy) BoolX(ctx context.Context) bool
- func (gigb *GroupInfoGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (gigb *GroupInfoGroupBy) BoolsX(ctx context.Context) []bool
- func (gigb *GroupInfoGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (gigb *GroupInfoGroupBy) Float64X(ctx context.Context) float64
- func (gigb *GroupInfoGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (gigb *GroupInfoGroupBy) Float64sX(ctx context.Context) []float64
- func (gigb *GroupInfoGroupBy) Int(ctx context.Context) (_ int, err error)
- func (gigb *GroupInfoGroupBy) IntX(ctx context.Context) int
- func (gigb *GroupInfoGroupBy) Ints(ctx context.Context) ([]int, error)
- func (gigb *GroupInfoGroupBy) IntsX(ctx context.Context) []int
- func (gigb *GroupInfoGroupBy) Scan(ctx context.Context, v interface{}) error
- func (gigb *GroupInfoGroupBy) ScanX(ctx context.Context, v interface{})
- func (gigb *GroupInfoGroupBy) String(ctx context.Context) (_ string, err error)
- func (gigb *GroupInfoGroupBy) StringX(ctx context.Context) string
- func (gigb *GroupInfoGroupBy) Strings(ctx context.Context) ([]string, error)
- func (gigb *GroupInfoGroupBy) StringsX(ctx context.Context) []string
- type GroupInfoMutation
- func (m *GroupInfoMutation) AddField(name string, value ent.Value) error
- func (m *GroupInfoMutation) AddGroupIDs(ids ...string)
- func (m *GroupInfoMutation) AddMaxUsers(i int)
- func (m *GroupInfoMutation) AddedEdges() []string
- func (m *GroupInfoMutation) AddedField(name string) (ent.Value, bool)
- func (m *GroupInfoMutation) AddedFields() []string
- func (m *GroupInfoMutation) AddedIDs(name string) []ent.Value
- func (m *GroupInfoMutation) AddedMaxUsers() (r int, exists bool)
- func (m *GroupInfoMutation) ClearEdge(name string) error
- func (m *GroupInfoMutation) ClearField(name string) error
- func (m *GroupInfoMutation) ClearGroups()
- func (m *GroupInfoMutation) ClearedEdges() []string
- func (m *GroupInfoMutation) ClearedFields() []string
- func (m GroupInfoMutation) Client() *Client
- func (m *GroupInfoMutation) Desc() (r string, exists bool)
- func (m *GroupInfoMutation) EdgeCleared(name string) bool
- func (m *GroupInfoMutation) Field(name string) (ent.Value, bool)
- func (m *GroupInfoMutation) FieldCleared(name string) bool
- func (m *GroupInfoMutation) Fields() []string
- func (m *GroupInfoMutation) GroupsCleared() bool
- func (m *GroupInfoMutation) GroupsIDs() (ids []string)
- func (m *GroupInfoMutation) ID() (id string, exists bool)
- func (m *GroupInfoMutation) MaxUsers() (r int, exists bool)
- func (m *GroupInfoMutation) OldDesc(ctx context.Context) (v string, err error)
- func (m *GroupInfoMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *GroupInfoMutation) OldMaxUsers(ctx context.Context) (v int, err error)
- func (m *GroupInfoMutation) Op() Op
- func (m *GroupInfoMutation) RemoveGroupIDs(ids ...string)
- func (m *GroupInfoMutation) RemovedEdges() []string
- func (m *GroupInfoMutation) RemovedGroupsIDs() (ids []string)
- func (m *GroupInfoMutation) RemovedIDs(name string) []ent.Value
- func (m *GroupInfoMutation) ResetDesc()
- func (m *GroupInfoMutation) ResetEdge(name string) error
- func (m *GroupInfoMutation) ResetField(name string) error
- func (m *GroupInfoMutation) ResetGroups()
- func (m *GroupInfoMutation) ResetMaxUsers()
- func (m *GroupInfoMutation) SetDesc(s string)
- func (m *GroupInfoMutation) SetField(name string, value ent.Value) error
- func (m *GroupInfoMutation) SetMaxUsers(i int)
- func (m GroupInfoMutation) Tx() (*Tx, error)
- func (m *GroupInfoMutation) Type() string
- type GroupInfoQuery
- func (giq *GroupInfoQuery) All(ctx context.Context) ([]*GroupInfo, error)
- func (giq *GroupInfoQuery) AllX(ctx context.Context) []*GroupInfo
- func (giq *GroupInfoQuery) Clone() *GroupInfoQuery
- func (giq *GroupInfoQuery) Count(ctx context.Context) (int, error)
- func (giq *GroupInfoQuery) CountX(ctx context.Context) int
- func (giq *GroupInfoQuery) Exist(ctx context.Context) (bool, error)
- func (giq *GroupInfoQuery) ExistX(ctx context.Context) bool
- func (giq *GroupInfoQuery) First(ctx context.Context) (*GroupInfo, error)
- func (giq *GroupInfoQuery) FirstID(ctx context.Context) (id string, err error)
- func (giq *GroupInfoQuery) FirstIDX(ctx context.Context) string
- func (giq *GroupInfoQuery) FirstX(ctx context.Context) *GroupInfo
- func (giq *GroupInfoQuery) GroupBy(field string, fields ...string) *GroupInfoGroupBy
- func (giq *GroupInfoQuery) IDs(ctx context.Context) ([]string, error)
- func (giq *GroupInfoQuery) IDsX(ctx context.Context) []string
- func (giq *GroupInfoQuery) Limit(limit int) *GroupInfoQuery
- func (giq *GroupInfoQuery) Offset(offset int) *GroupInfoQuery
- func (giq *GroupInfoQuery) Only(ctx context.Context) (*GroupInfo, error)
- func (giq *GroupInfoQuery) OnlyID(ctx context.Context) (id string, err error)
- func (giq *GroupInfoQuery) OnlyIDX(ctx context.Context) string
- func (giq *GroupInfoQuery) OnlyX(ctx context.Context) *GroupInfo
- func (giq *GroupInfoQuery) Order(o ...OrderFunc) *GroupInfoQuery
- func (giq *GroupInfoQuery) QueryGroups() *GroupQuery
- func (giq *GroupInfoQuery) Select(field string, fields ...string) *GroupInfoSelect
- func (giq *GroupInfoQuery) Where(ps ...predicate.GroupInfo) *GroupInfoQuery
- func (giq *GroupInfoQuery) WithGroups(opts ...func(*GroupQuery)) *GroupInfoQuery
- type GroupInfoSelect
- func (gis *GroupInfoSelect) Bool(ctx context.Context) (_ bool, err error)
- func (gis *GroupInfoSelect) BoolX(ctx context.Context) bool
- func (gis *GroupInfoSelect) Bools(ctx context.Context) ([]bool, error)
- func (gis *GroupInfoSelect) BoolsX(ctx context.Context) []bool
- func (gis *GroupInfoSelect) Float64(ctx context.Context) (_ float64, err error)
- func (gis *GroupInfoSelect) Float64X(ctx context.Context) float64
- func (gis *GroupInfoSelect) Float64s(ctx context.Context) ([]float64, error)
- func (gis *GroupInfoSelect) Float64sX(ctx context.Context) []float64
- func (gis *GroupInfoSelect) Int(ctx context.Context) (_ int, err error)
- func (gis *GroupInfoSelect) IntX(ctx context.Context) int
- func (gis *GroupInfoSelect) Ints(ctx context.Context) ([]int, error)
- func (gis *GroupInfoSelect) IntsX(ctx context.Context) []int
- func (gis *GroupInfoSelect) Scan(ctx context.Context, v interface{}) error
- func (gis *GroupInfoSelect) ScanX(ctx context.Context, v interface{})
- func (gis *GroupInfoSelect) String(ctx context.Context) (_ string, err error)
- func (gis *GroupInfoSelect) StringX(ctx context.Context) string
- func (gis *GroupInfoSelect) Strings(ctx context.Context) ([]string, error)
- func (gis *GroupInfoSelect) StringsX(ctx context.Context) []string
- type GroupInfoUpdate
- func (giu *GroupInfoUpdate) AddGroupIDs(ids ...string) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) AddGroups(g ...*Group) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) AddMaxUsers(i int) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) ClearGroups() *GroupInfoUpdate
- func (giu *GroupInfoUpdate) Exec(ctx context.Context) error
- func (giu *GroupInfoUpdate) ExecX(ctx context.Context)
- func (giu *GroupInfoUpdate) Mutation() *GroupInfoMutation
- func (giu *GroupInfoUpdate) RemoveGroupIDs(ids ...string) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) RemoveGroups(g ...*Group) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) Save(ctx context.Context) (int, error)
- func (giu *GroupInfoUpdate) SaveX(ctx context.Context) int
- func (giu *GroupInfoUpdate) SetDesc(s string) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) SetMaxUsers(i int) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) SetNillableMaxUsers(i *int) *GroupInfoUpdate
- func (giu *GroupInfoUpdate) Where(ps ...predicate.GroupInfo) *GroupInfoUpdate
- type GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) AddGroupIDs(ids ...string) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) AddGroups(g ...*Group) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) AddMaxUsers(i int) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) ClearGroups() *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) Exec(ctx context.Context) error
- func (giuo *GroupInfoUpdateOne) ExecX(ctx context.Context)
- func (giuo *GroupInfoUpdateOne) Mutation() *GroupInfoMutation
- func (giuo *GroupInfoUpdateOne) RemoveGroupIDs(ids ...string) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) RemoveGroups(g ...*Group) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) Save(ctx context.Context) (*GroupInfo, error)
- func (giuo *GroupInfoUpdateOne) SaveX(ctx context.Context) *GroupInfo
- func (giuo *GroupInfoUpdateOne) SetDesc(s string) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) SetMaxUsers(i int) *GroupInfoUpdateOne
- func (giuo *GroupInfoUpdateOne) SetNillableMaxUsers(i *int) *GroupInfoUpdateOne
- type GroupInfos
- type GroupMutation
- func (m *GroupMutation) Active() (r bool, exists bool)
- func (m *GroupMutation) AddBlockedIDs(ids ...string)
- func (m *GroupMutation) AddField(name string, value ent.Value) error
- func (m *GroupMutation) AddFileIDs(ids ...string)
- func (m *GroupMutation) AddMaxUsers(i int)
- func (m *GroupMutation) AddUserIDs(ids ...string)
- func (m *GroupMutation) AddedEdges() []string
- func (m *GroupMutation) AddedField(name string) (ent.Value, bool)
- func (m *GroupMutation) AddedFields() []string
- func (m *GroupMutation) AddedIDs(name string) []ent.Value
- func (m *GroupMutation) AddedMaxUsers() (r int, exists bool)
- func (m *GroupMutation) BlockedCleared() bool
- func (m *GroupMutation) BlockedIDs() (ids []string)
- func (m *GroupMutation) ClearBlocked()
- func (m *GroupMutation) ClearEdge(name string) error
- func (m *GroupMutation) ClearField(name string) error
- func (m *GroupMutation) ClearFiles()
- func (m *GroupMutation) ClearInfo()
- func (m *GroupMutation) ClearMaxUsers()
- func (m *GroupMutation) ClearType()
- func (m *GroupMutation) ClearUsers()
- func (m *GroupMutation) ClearedEdges() []string
- func (m *GroupMutation) ClearedFields() []string
- func (m GroupMutation) Client() *Client
- func (m *GroupMutation) EdgeCleared(name string) bool
- func (m *GroupMutation) Expire() (r time.Time, exists bool)
- func (m *GroupMutation) Field(name string) (ent.Value, bool)
- func (m *GroupMutation) FieldCleared(name string) bool
- func (m *GroupMutation) Fields() []string
- func (m *GroupMutation) FilesCleared() bool
- func (m *GroupMutation) FilesIDs() (ids []string)
- func (m *GroupMutation) GetType() (r string, exists bool)
- func (m *GroupMutation) ID() (id string, exists bool)
- func (m *GroupMutation) InfoCleared() bool
- func (m *GroupMutation) InfoID() (id string, exists bool)
- func (m *GroupMutation) InfoIDs() (ids []string)
- func (m *GroupMutation) MaxUsers() (r int, exists bool)
- func (m *GroupMutation) MaxUsersCleared() bool
- func (m *GroupMutation) Name() (r string, exists bool)
- func (m *GroupMutation) OldActive(ctx context.Context) (v bool, err error)
- func (m *GroupMutation) OldExpire(ctx context.Context) (v time.Time, err error)
- func (m *GroupMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *GroupMutation) OldMaxUsers(ctx context.Context) (v int, err error)
- func (m *GroupMutation) OldName(ctx context.Context) (v string, err error)
- func (m *GroupMutation) OldType(ctx context.Context) (v *string, err error)
- func (m *GroupMutation) Op() Op
- func (m *GroupMutation) RemoveBlockedIDs(ids ...string)
- func (m *GroupMutation) RemoveFileIDs(ids ...string)
- func (m *GroupMutation) RemoveUserIDs(ids ...string)
- func (m *GroupMutation) RemovedBlockedIDs() (ids []string)
- func (m *GroupMutation) RemovedEdges() []string
- func (m *GroupMutation) RemovedFilesIDs() (ids []string)
- func (m *GroupMutation) RemovedIDs(name string) []ent.Value
- func (m *GroupMutation) RemovedUsersIDs() (ids []string)
- func (m *GroupMutation) ResetActive()
- func (m *GroupMutation) ResetBlocked()
- func (m *GroupMutation) ResetEdge(name string) error
- func (m *GroupMutation) ResetExpire()
- func (m *GroupMutation) ResetField(name string) error
- func (m *GroupMutation) ResetFiles()
- func (m *GroupMutation) ResetInfo()
- func (m *GroupMutation) ResetMaxUsers()
- func (m *GroupMutation) ResetName()
- func (m *GroupMutation) ResetType()
- func (m *GroupMutation) ResetUsers()
- func (m *GroupMutation) SetActive(b bool)
- func (m *GroupMutation) SetExpire(t time.Time)
- func (m *GroupMutation) SetField(name string, value ent.Value) error
- func (m *GroupMutation) SetInfoID(id string)
- func (m *GroupMutation) SetMaxUsers(i int)
- func (m *GroupMutation) SetName(s string)
- func (m *GroupMutation) SetType(s string)
- func (m GroupMutation) Tx() (*Tx, error)
- func (m *GroupMutation) Type() string
- func (m *GroupMutation) TypeCleared() bool
- func (m *GroupMutation) UsersCleared() bool
- func (m *GroupMutation) UsersIDs() (ids []string)
- type GroupQuery
- func (gq *GroupQuery) All(ctx context.Context) ([]*Group, error)
- func (gq *GroupQuery) AllX(ctx context.Context) []*Group
- func (gq *GroupQuery) Clone() *GroupQuery
- func (gq *GroupQuery) Count(ctx context.Context) (int, error)
- func (gq *GroupQuery) CountX(ctx context.Context) int
- func (gq *GroupQuery) Exist(ctx context.Context) (bool, error)
- func (gq *GroupQuery) ExistX(ctx context.Context) bool
- func (gq *GroupQuery) First(ctx context.Context) (*Group, error)
- func (gq *GroupQuery) FirstID(ctx context.Context) (id string, err error)
- func (gq *GroupQuery) FirstIDX(ctx context.Context) string
- func (gq *GroupQuery) FirstX(ctx context.Context) *Group
- func (gq *GroupQuery) GroupBy(field string, fields ...string) *GroupGroupBy
- func (gq *GroupQuery) IDs(ctx context.Context) ([]string, error)
- func (gq *GroupQuery) IDsX(ctx context.Context) []string
- func (gq *GroupQuery) Limit(limit int) *GroupQuery
- func (gq *GroupQuery) Offset(offset int) *GroupQuery
- func (gq *GroupQuery) Only(ctx context.Context) (*Group, error)
- func (gq *GroupQuery) OnlyID(ctx context.Context) (id string, err error)
- func (gq *GroupQuery) OnlyIDX(ctx context.Context) string
- func (gq *GroupQuery) OnlyX(ctx context.Context) *Group
- func (gq *GroupQuery) Order(o ...OrderFunc) *GroupQuery
- func (gq *GroupQuery) QueryBlocked() *UserQuery
- func (gq *GroupQuery) QueryFiles() *FileQuery
- func (gq *GroupQuery) QueryInfo() *GroupInfoQuery
- func (gq *GroupQuery) QueryUsers() *UserQuery
- func (gq *GroupQuery) Select(field string, fields ...string) *GroupSelect
- func (gq *GroupQuery) Where(ps ...predicate.Group) *GroupQuery
- func (gq *GroupQuery) WithBlocked(opts ...func(*UserQuery)) *GroupQuery
- func (gq *GroupQuery) WithFiles(opts ...func(*FileQuery)) *GroupQuery
- func (gq *GroupQuery) WithInfo(opts ...func(*GroupInfoQuery)) *GroupQuery
- func (gq *GroupQuery) WithUsers(opts ...func(*UserQuery)) *GroupQuery
- type GroupSelect
- func (gs *GroupSelect) Bool(ctx context.Context) (_ bool, err error)
- func (gs *GroupSelect) BoolX(ctx context.Context) bool
- func (gs *GroupSelect) Bools(ctx context.Context) ([]bool, error)
- func (gs *GroupSelect) BoolsX(ctx context.Context) []bool
- func (gs *GroupSelect) Float64(ctx context.Context) (_ float64, err error)
- func (gs *GroupSelect) Float64X(ctx context.Context) float64
- func (gs *GroupSelect) Float64s(ctx context.Context) ([]float64, error)
- func (gs *GroupSelect) Float64sX(ctx context.Context) []float64
- func (gs *GroupSelect) Int(ctx context.Context) (_ int, err error)
- func (gs *GroupSelect) IntX(ctx context.Context) int
- func (gs *GroupSelect) Ints(ctx context.Context) ([]int, error)
- func (gs *GroupSelect) IntsX(ctx context.Context) []int
- func (gs *GroupSelect) Scan(ctx context.Context, v interface{}) error
- func (gs *GroupSelect) ScanX(ctx context.Context, v interface{})
- func (gs *GroupSelect) String(ctx context.Context) (_ string, err error)
- func (gs *GroupSelect) StringX(ctx context.Context) string
- func (gs *GroupSelect) Strings(ctx context.Context) ([]string, error)
- func (gs *GroupSelect) StringsX(ctx context.Context) []string
- type GroupUpdate
- func (gu *GroupUpdate) AddBlocked(u ...*User) *GroupUpdate
- func (gu *GroupUpdate) AddBlockedIDs(ids ...string) *GroupUpdate
- func (gu *GroupUpdate) AddFileIDs(ids ...string) *GroupUpdate
- func (gu *GroupUpdate) AddFiles(f ...*File) *GroupUpdate
- func (gu *GroupUpdate) AddMaxUsers(i int) *GroupUpdate
- func (gu *GroupUpdate) AddUserIDs(ids ...string) *GroupUpdate
- func (gu *GroupUpdate) AddUsers(u ...*User) *GroupUpdate
- func (gu *GroupUpdate) ClearBlocked() *GroupUpdate
- func (gu *GroupUpdate) ClearFiles() *GroupUpdate
- func (gu *GroupUpdate) ClearInfo() *GroupUpdate
- func (gu *GroupUpdate) ClearMaxUsers() *GroupUpdate
- func (gu *GroupUpdate) ClearType() *GroupUpdate
- func (gu *GroupUpdate) ClearUsers() *GroupUpdate
- func (gu *GroupUpdate) Exec(ctx context.Context) error
- func (gu *GroupUpdate) ExecX(ctx context.Context)
- func (gu *GroupUpdate) Mutation() *GroupMutation
- func (gu *GroupUpdate) RemoveBlocked(u ...*User) *GroupUpdate
- func (gu *GroupUpdate) RemoveBlockedIDs(ids ...string) *GroupUpdate
- func (gu *GroupUpdate) RemoveFileIDs(ids ...string) *GroupUpdate
- func (gu *GroupUpdate) RemoveFiles(f ...*File) *GroupUpdate
- func (gu *GroupUpdate) RemoveUserIDs(ids ...string) *GroupUpdate
- func (gu *GroupUpdate) RemoveUsers(u ...*User) *GroupUpdate
- func (gu *GroupUpdate) Save(ctx context.Context) (int, error)
- func (gu *GroupUpdate) SaveX(ctx context.Context) int
- func (gu *GroupUpdate) SetActive(b bool) *GroupUpdate
- func (gu *GroupUpdate) SetExpire(t time.Time) *GroupUpdate
- func (gu *GroupUpdate) SetInfo(g *GroupInfo) *GroupUpdate
- func (gu *GroupUpdate) SetInfoID(id string) *GroupUpdate
- func (gu *GroupUpdate) SetMaxUsers(i int) *GroupUpdate
- func (gu *GroupUpdate) SetName(s string) *GroupUpdate
- func (gu *GroupUpdate) SetNillableActive(b *bool) *GroupUpdate
- func (gu *GroupUpdate) SetNillableMaxUsers(i *int) *GroupUpdate
- func (gu *GroupUpdate) SetNillableType(s *string) *GroupUpdate
- func (gu *GroupUpdate) SetType(s string) *GroupUpdate
- func (gu *GroupUpdate) Where(ps ...predicate.Group) *GroupUpdate
- type GroupUpdateOne
- func (guo *GroupUpdateOne) AddBlocked(u ...*User) *GroupUpdateOne
- func (guo *GroupUpdateOne) AddBlockedIDs(ids ...string) *GroupUpdateOne
- func (guo *GroupUpdateOne) AddFileIDs(ids ...string) *GroupUpdateOne
- func (guo *GroupUpdateOne) AddFiles(f ...*File) *GroupUpdateOne
- func (guo *GroupUpdateOne) AddMaxUsers(i int) *GroupUpdateOne
- func (guo *GroupUpdateOne) AddUserIDs(ids ...string) *GroupUpdateOne
- func (guo *GroupUpdateOne) AddUsers(u ...*User) *GroupUpdateOne
- func (guo *GroupUpdateOne) ClearBlocked() *GroupUpdateOne
- func (guo *GroupUpdateOne) ClearFiles() *GroupUpdateOne
- func (guo *GroupUpdateOne) ClearInfo() *GroupUpdateOne
- func (guo *GroupUpdateOne) ClearMaxUsers() *GroupUpdateOne
- func (guo *GroupUpdateOne) ClearType() *GroupUpdateOne
- func (guo *GroupUpdateOne) ClearUsers() *GroupUpdateOne
- func (guo *GroupUpdateOne) Exec(ctx context.Context) error
- func (guo *GroupUpdateOne) ExecX(ctx context.Context)
- func (guo *GroupUpdateOne) Mutation() *GroupMutation
- func (guo *GroupUpdateOne) RemoveBlocked(u ...*User) *GroupUpdateOne
- func (guo *GroupUpdateOne) RemoveBlockedIDs(ids ...string) *GroupUpdateOne
- func (guo *GroupUpdateOne) RemoveFileIDs(ids ...string) *GroupUpdateOne
- func (guo *GroupUpdateOne) RemoveFiles(f ...*File) *GroupUpdateOne
- func (guo *GroupUpdateOne) RemoveUserIDs(ids ...string) *GroupUpdateOne
- func (guo *GroupUpdateOne) RemoveUsers(u ...*User) *GroupUpdateOne
- func (guo *GroupUpdateOne) Save(ctx context.Context) (*Group, error)
- func (guo *GroupUpdateOne) SaveX(ctx context.Context) *Group
- func (guo *GroupUpdateOne) SetActive(b bool) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetExpire(t time.Time) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetInfo(g *GroupInfo) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetInfoID(id string) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetMaxUsers(i int) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetName(s string) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetNillableActive(b *bool) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetNillableMaxUsers(i *int) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetNillableType(s *string) *GroupUpdateOne
- func (guo *GroupUpdateOne) SetType(s string) *GroupUpdateOne
- type Groups
- type Hook
- type Item
- type ItemClient
- func (c *ItemClient) Create() *ItemCreate
- func (c *ItemClient) CreateBulk(builders ...*ItemCreate) *ItemCreateBulk
- func (c *ItemClient) Delete() *ItemDelete
- func (c *ItemClient) DeleteOne(i *Item) *ItemDeleteOne
- func (c *ItemClient) DeleteOneID(id string) *ItemDeleteOne
- func (c *ItemClient) Get(ctx context.Context, id string) (*Item, error)
- func (c *ItemClient) GetX(ctx context.Context, id string) *Item
- func (c *ItemClient) Hooks() []Hook
- func (c *ItemClient) Query() *ItemQuery
- func (c *ItemClient) Update() *ItemUpdate
- func (c *ItemClient) UpdateOne(i *Item) *ItemUpdateOne
- func (c *ItemClient) UpdateOneID(id string) *ItemUpdateOne
- func (c *ItemClient) Use(hooks ...Hook)
- type ItemCreate
- type ItemCreateBulk
- type ItemDelete
- type ItemDeleteOne
- type ItemGroupBy
- func (igb *ItemGroupBy) Aggregate(fns ...AggregateFunc) *ItemGroupBy
- func (igb *ItemGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (igb *ItemGroupBy) BoolX(ctx context.Context) bool
- func (igb *ItemGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (igb *ItemGroupBy) BoolsX(ctx context.Context) []bool
- func (igb *ItemGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (igb *ItemGroupBy) Float64X(ctx context.Context) float64
- func (igb *ItemGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (igb *ItemGroupBy) Float64sX(ctx context.Context) []float64
- func (igb *ItemGroupBy) Int(ctx context.Context) (_ int, err error)
- func (igb *ItemGroupBy) IntX(ctx context.Context) int
- func (igb *ItemGroupBy) Ints(ctx context.Context) ([]int, error)
- func (igb *ItemGroupBy) IntsX(ctx context.Context) []int
- func (igb *ItemGroupBy) Scan(ctx context.Context, v interface{}) error
- func (igb *ItemGroupBy) ScanX(ctx context.Context, v interface{})
- func (igb *ItemGroupBy) String(ctx context.Context) (_ string, err error)
- func (igb *ItemGroupBy) StringX(ctx context.Context) string
- func (igb *ItemGroupBy) Strings(ctx context.Context) ([]string, error)
- func (igb *ItemGroupBy) StringsX(ctx context.Context) []string
- type ItemMutation
- func (m *ItemMutation) AddField(name string, value ent.Value) error
- func (m *ItemMutation) AddedEdges() []string
- func (m *ItemMutation) AddedField(name string) (ent.Value, bool)
- func (m *ItemMutation) AddedFields() []string
- func (m *ItemMutation) AddedIDs(name string) []ent.Value
- func (m *ItemMutation) ClearEdge(name string) error
- func (m *ItemMutation) ClearField(name string) error
- func (m *ItemMutation) ClearedEdges() []string
- func (m *ItemMutation) ClearedFields() []string
- func (m ItemMutation) Client() *Client
- func (m *ItemMutation) EdgeCleared(name string) bool
- func (m *ItemMutation) Field(name string) (ent.Value, bool)
- func (m *ItemMutation) FieldCleared(name string) bool
- func (m *ItemMutation) Fields() []string
- func (m *ItemMutation) ID() (id string, exists bool)
- func (m *ItemMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ItemMutation) Op() Op
- func (m *ItemMutation) RemovedEdges() []string
- func (m *ItemMutation) RemovedIDs(name string) []ent.Value
- func (m *ItemMutation) ResetEdge(name string) error
- func (m *ItemMutation) ResetField(name string) error
- func (m *ItemMutation) SetField(name string, value ent.Value) error
- func (m ItemMutation) Tx() (*Tx, error)
- func (m *ItemMutation) Type() string
- type ItemQuery
- func (iq *ItemQuery) All(ctx context.Context) ([]*Item, error)
- func (iq *ItemQuery) AllX(ctx context.Context) []*Item
- func (iq *ItemQuery) Clone() *ItemQuery
- func (iq *ItemQuery) Count(ctx context.Context) (int, error)
- func (iq *ItemQuery) CountX(ctx context.Context) int
- func (iq *ItemQuery) Exist(ctx context.Context) (bool, error)
- func (iq *ItemQuery) ExistX(ctx context.Context) bool
- func (iq *ItemQuery) First(ctx context.Context) (*Item, error)
- func (iq *ItemQuery) FirstID(ctx context.Context) (id string, err error)
- func (iq *ItemQuery) FirstIDX(ctx context.Context) string
- func (iq *ItemQuery) FirstX(ctx context.Context) *Item
- func (iq *ItemQuery) GroupBy(field string, fields ...string) *ItemGroupBy
- func (iq *ItemQuery) IDs(ctx context.Context) ([]string, error)
- func (iq *ItemQuery) IDsX(ctx context.Context) []string
- func (iq *ItemQuery) Limit(limit int) *ItemQuery
- func (iq *ItemQuery) Offset(offset int) *ItemQuery
- func (iq *ItemQuery) Only(ctx context.Context) (*Item, error)
- func (iq *ItemQuery) OnlyID(ctx context.Context) (id string, err error)
- func (iq *ItemQuery) OnlyIDX(ctx context.Context) string
- func (iq *ItemQuery) OnlyX(ctx context.Context) *Item
- func (iq *ItemQuery) Order(o ...OrderFunc) *ItemQuery
- func (iq *ItemQuery) Select(field string, fields ...string) *ItemSelect
- func (iq *ItemQuery) Where(ps ...predicate.Item) *ItemQuery
- type ItemSelect
- func (is *ItemSelect) Bool(ctx context.Context) (_ bool, err error)
- func (is *ItemSelect) BoolX(ctx context.Context) bool
- func (is *ItemSelect) Bools(ctx context.Context) ([]bool, error)
- func (is *ItemSelect) BoolsX(ctx context.Context) []bool
- func (is *ItemSelect) Float64(ctx context.Context) (_ float64, err error)
- func (is *ItemSelect) Float64X(ctx context.Context) float64
- func (is *ItemSelect) Float64s(ctx context.Context) ([]float64, error)
- func (is *ItemSelect) Float64sX(ctx context.Context) []float64
- func (is *ItemSelect) Int(ctx context.Context) (_ int, err error)
- func (is *ItemSelect) IntX(ctx context.Context) int
- func (is *ItemSelect) Ints(ctx context.Context) ([]int, error)
- func (is *ItemSelect) IntsX(ctx context.Context) []int
- func (is *ItemSelect) Scan(ctx context.Context, v interface{}) error
- func (is *ItemSelect) ScanX(ctx context.Context, v interface{})
- func (is *ItemSelect) String(ctx context.Context) (_ string, err error)
- func (is *ItemSelect) StringX(ctx context.Context) string
- func (is *ItemSelect) Strings(ctx context.Context) ([]string, error)
- func (is *ItemSelect) StringsX(ctx context.Context) []string
- type ItemUpdate
- func (iu *ItemUpdate) Exec(ctx context.Context) error
- func (iu *ItemUpdate) ExecX(ctx context.Context)
- func (iu *ItemUpdate) Mutation() *ItemMutation
- func (iu *ItemUpdate) Save(ctx context.Context) (int, error)
- func (iu *ItemUpdate) SaveX(ctx context.Context) int
- func (iu *ItemUpdate) Where(ps ...predicate.Item) *ItemUpdate
- type ItemUpdateOne
- type Items
- type MutateFunc
- type Mutation
- type Mutator
- type Node
- type NodeClient
- func (c *NodeClient) Create() *NodeCreate
- func (c *NodeClient) CreateBulk(builders ...*NodeCreate) *NodeCreateBulk
- func (c *NodeClient) Delete() *NodeDelete
- func (c *NodeClient) DeleteOne(n *Node) *NodeDeleteOne
- func (c *NodeClient) DeleteOneID(id string) *NodeDeleteOne
- func (c *NodeClient) Get(ctx context.Context, id string) (*Node, error)
- func (c *NodeClient) GetX(ctx context.Context, id string) *Node
- func (c *NodeClient) Hooks() []Hook
- func (c *NodeClient) Query() *NodeQuery
- func (c *NodeClient) QueryNext(n *Node) *NodeQuery
- func (c *NodeClient) QueryPrev(n *Node) *NodeQuery
- func (c *NodeClient) Update() *NodeUpdate
- func (c *NodeClient) UpdateOne(n *Node) *NodeUpdateOne
- func (c *NodeClient) UpdateOneID(id string) *NodeUpdateOne
- func (c *NodeClient) Use(hooks ...Hook)
- type NodeCreate
- func (nc *NodeCreate) Mutation() *NodeMutation
- func (nc *NodeCreate) Save(ctx context.Context) (*Node, error)
- func (nc *NodeCreate) SaveX(ctx context.Context) *Node
- func (nc *NodeCreate) SetNext(n *Node) *NodeCreate
- func (nc *NodeCreate) SetNextID(id string) *NodeCreate
- func (nc *NodeCreate) SetNillableNextID(id *string) *NodeCreate
- func (nc *NodeCreate) SetNillablePrevID(id *string) *NodeCreate
- func (nc *NodeCreate) SetNillableValue(i *int) *NodeCreate
- func (nc *NodeCreate) SetPrev(n *Node) *NodeCreate
- func (nc *NodeCreate) SetPrevID(id string) *NodeCreate
- func (nc *NodeCreate) SetValue(i int) *NodeCreate
- type NodeCreateBulk
- type NodeDelete
- type NodeDeleteOne
- type NodeEdges
- type NodeGroupBy
- func (ngb *NodeGroupBy) Aggregate(fns ...AggregateFunc) *NodeGroupBy
- func (ngb *NodeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ngb *NodeGroupBy) BoolX(ctx context.Context) bool
- func (ngb *NodeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ngb *NodeGroupBy) BoolsX(ctx context.Context) []bool
- func (ngb *NodeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ngb *NodeGroupBy) Float64X(ctx context.Context) float64
- func (ngb *NodeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ngb *NodeGroupBy) Float64sX(ctx context.Context) []float64
- func (ngb *NodeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ngb *NodeGroupBy) IntX(ctx context.Context) int
- func (ngb *NodeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ngb *NodeGroupBy) IntsX(ctx context.Context) []int
- func (ngb *NodeGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ngb *NodeGroupBy) ScanX(ctx context.Context, v interface{})
- func (ngb *NodeGroupBy) String(ctx context.Context) (_ string, err error)
- func (ngb *NodeGroupBy) StringX(ctx context.Context) string
- func (ngb *NodeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ngb *NodeGroupBy) StringsX(ctx context.Context) []string
- type NodeMutation
- func (m *NodeMutation) AddField(name string, value ent.Value) error
- func (m *NodeMutation) AddValue(i int)
- func (m *NodeMutation) AddedEdges() []string
- func (m *NodeMutation) AddedField(name string) (ent.Value, bool)
- func (m *NodeMutation) AddedFields() []string
- func (m *NodeMutation) AddedIDs(name string) []ent.Value
- func (m *NodeMutation) AddedValue() (r int, exists bool)
- func (m *NodeMutation) ClearEdge(name string) error
- func (m *NodeMutation) ClearField(name string) error
- func (m *NodeMutation) ClearNext()
- func (m *NodeMutation) ClearPrev()
- func (m *NodeMutation) ClearValue()
- func (m *NodeMutation) ClearedEdges() []string
- func (m *NodeMutation) ClearedFields() []string
- func (m NodeMutation) Client() *Client
- func (m *NodeMutation) EdgeCleared(name string) bool
- func (m *NodeMutation) Field(name string) (ent.Value, bool)
- func (m *NodeMutation) FieldCleared(name string) bool
- func (m *NodeMutation) Fields() []string
- func (m *NodeMutation) ID() (id string, exists bool)
- func (m *NodeMutation) NextCleared() bool
- func (m *NodeMutation) NextID() (id string, exists bool)
- func (m *NodeMutation) NextIDs() (ids []string)
- func (m *NodeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *NodeMutation) OldValue(ctx context.Context) (v int, err error)
- func (m *NodeMutation) Op() Op
- func (m *NodeMutation) PrevCleared() bool
- func (m *NodeMutation) PrevID() (id string, exists bool)
- func (m *NodeMutation) PrevIDs() (ids []string)
- func (m *NodeMutation) RemovedEdges() []string
- func (m *NodeMutation) RemovedIDs(name string) []ent.Value
- func (m *NodeMutation) ResetEdge(name string) error
- func (m *NodeMutation) ResetField(name string) error
- func (m *NodeMutation) ResetNext()
- func (m *NodeMutation) ResetPrev()
- func (m *NodeMutation) ResetValue()
- func (m *NodeMutation) SetField(name string, value ent.Value) error
- func (m *NodeMutation) SetNextID(id string)
- func (m *NodeMutation) SetPrevID(id string)
- func (m *NodeMutation) SetValue(i int)
- func (m NodeMutation) Tx() (*Tx, error)
- func (m *NodeMutation) Type() string
- func (m *NodeMutation) Value() (r int, exists bool)
- func (m *NodeMutation) ValueCleared() bool
- type NodeQuery
- func (nq *NodeQuery) All(ctx context.Context) ([]*Node, error)
- func (nq *NodeQuery) AllX(ctx context.Context) []*Node
- func (nq *NodeQuery) Clone() *NodeQuery
- func (nq *NodeQuery) Count(ctx context.Context) (int, error)
- func (nq *NodeQuery) CountX(ctx context.Context) int
- func (nq *NodeQuery) Exist(ctx context.Context) (bool, error)
- func (nq *NodeQuery) ExistX(ctx context.Context) bool
- func (nq *NodeQuery) First(ctx context.Context) (*Node, error)
- func (nq *NodeQuery) FirstID(ctx context.Context) (id string, err error)
- func (nq *NodeQuery) FirstIDX(ctx context.Context) string
- func (nq *NodeQuery) FirstX(ctx context.Context) *Node
- func (nq *NodeQuery) GroupBy(field string, fields ...string) *NodeGroupBy
- func (nq *NodeQuery) IDs(ctx context.Context) ([]string, error)
- func (nq *NodeQuery) IDsX(ctx context.Context) []string
- func (nq *NodeQuery) Limit(limit int) *NodeQuery
- func (nq *NodeQuery) Offset(offset int) *NodeQuery
- func (nq *NodeQuery) Only(ctx context.Context) (*Node, error)
- func (nq *NodeQuery) OnlyID(ctx context.Context) (id string, err error)
- func (nq *NodeQuery) OnlyIDX(ctx context.Context) string
- func (nq *NodeQuery) OnlyX(ctx context.Context) *Node
- func (nq *NodeQuery) Order(o ...OrderFunc) *NodeQuery
- func (nq *NodeQuery) QueryNext() *NodeQuery
- func (nq *NodeQuery) QueryPrev() *NodeQuery
- func (nq *NodeQuery) Select(field string, fields ...string) *NodeSelect
- func (nq *NodeQuery) Where(ps ...predicate.Node) *NodeQuery
- func (nq *NodeQuery) WithNext(opts ...func(*NodeQuery)) *NodeQuery
- func (nq *NodeQuery) WithPrev(opts ...func(*NodeQuery)) *NodeQuery
- type NodeSelect
- func (ns *NodeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ns *NodeSelect) BoolX(ctx context.Context) bool
- func (ns *NodeSelect) Bools(ctx context.Context) ([]bool, error)
- func (ns *NodeSelect) BoolsX(ctx context.Context) []bool
- func (ns *NodeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ns *NodeSelect) Float64X(ctx context.Context) float64
- func (ns *NodeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ns *NodeSelect) Float64sX(ctx context.Context) []float64
- func (ns *NodeSelect) Int(ctx context.Context) (_ int, err error)
- func (ns *NodeSelect) IntX(ctx context.Context) int
- func (ns *NodeSelect) Ints(ctx context.Context) ([]int, error)
- func (ns *NodeSelect) IntsX(ctx context.Context) []int
- func (ns *NodeSelect) Scan(ctx context.Context, v interface{}) error
- func (ns *NodeSelect) ScanX(ctx context.Context, v interface{})
- func (ns *NodeSelect) String(ctx context.Context) (_ string, err error)
- func (ns *NodeSelect) StringX(ctx context.Context) string
- func (ns *NodeSelect) Strings(ctx context.Context) ([]string, error)
- func (ns *NodeSelect) StringsX(ctx context.Context) []string
- type NodeUpdate
- func (nu *NodeUpdate) AddValue(i int) *NodeUpdate
- func (nu *NodeUpdate) ClearNext() *NodeUpdate
- func (nu *NodeUpdate) ClearPrev() *NodeUpdate
- func (nu *NodeUpdate) ClearValue() *NodeUpdate
- func (nu *NodeUpdate) Exec(ctx context.Context) error
- func (nu *NodeUpdate) ExecX(ctx context.Context)
- func (nu *NodeUpdate) Mutation() *NodeMutation
- func (nu *NodeUpdate) Save(ctx context.Context) (int, error)
- func (nu *NodeUpdate) SaveX(ctx context.Context) int
- func (nu *NodeUpdate) SetNext(n *Node) *NodeUpdate
- func (nu *NodeUpdate) SetNextID(id string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableNextID(id *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillablePrevID(id *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableValue(i *int) *NodeUpdate
- func (nu *NodeUpdate) SetPrev(n *Node) *NodeUpdate
- func (nu *NodeUpdate) SetPrevID(id string) *NodeUpdate
- func (nu *NodeUpdate) SetValue(i int) *NodeUpdate
- func (nu *NodeUpdate) Where(ps ...predicate.Node) *NodeUpdate
- type NodeUpdateOne
- func (nuo *NodeUpdateOne) AddValue(i int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearNext() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearPrev() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearValue() *NodeUpdateOne
- func (nuo *NodeUpdateOne) Exec(ctx context.Context) error
- func (nuo *NodeUpdateOne) ExecX(ctx context.Context)
- func (nuo *NodeUpdateOne) Mutation() *NodeMutation
- func (nuo *NodeUpdateOne) Save(ctx context.Context) (*Node, error)
- func (nuo *NodeUpdateOne) SaveX(ctx context.Context) *Node
- func (nuo *NodeUpdateOne) SetNext(n *Node) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNextID(id string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableNextID(id *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillablePrevID(id *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableValue(i *int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetPrev(n *Node) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetPrevID(id string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetValue(i int) *NodeUpdateOne
- type Nodes
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Op
- type Option
- type OrderFunc
- type Pet
- type PetClient
- func (c *PetClient) Create() *PetCreate
- func (c *PetClient) CreateBulk(builders ...*PetCreate) *PetCreateBulk
- func (c *PetClient) Delete() *PetDelete
- func (c *PetClient) DeleteOne(pe *Pet) *PetDeleteOne
- func (c *PetClient) DeleteOneID(id string) *PetDeleteOne
- func (c *PetClient) Get(ctx context.Context, id string) (*Pet, error)
- func (c *PetClient) GetX(ctx context.Context, id string) *Pet
- func (c *PetClient) Hooks() []Hook
- func (c *PetClient) Query() *PetQuery
- func (c *PetClient) QueryOwner(pe *Pet) *UserQuery
- func (c *PetClient) QueryTeam(pe *Pet) *UserQuery
- func (c *PetClient) Update() *PetUpdate
- func (c *PetClient) UpdateOne(pe *Pet) *PetUpdateOne
- func (c *PetClient) UpdateOneID(id string) *PetUpdateOne
- func (c *PetClient) Use(hooks ...Hook)
- type PetCreate
- func (pc *PetCreate) Mutation() *PetMutation
- func (pc *PetCreate) Save(ctx context.Context) (*Pet, error)
- func (pc *PetCreate) SaveX(ctx context.Context) *Pet
- func (pc *PetCreate) SetName(s string) *PetCreate
- func (pc *PetCreate) SetNillableOwnerID(id *string) *PetCreate
- func (pc *PetCreate) SetNillableTeamID(id *string) *PetCreate
- func (pc *PetCreate) SetOwner(u *User) *PetCreate
- func (pc *PetCreate) SetOwnerID(id string) *PetCreate
- func (pc *PetCreate) SetTeam(u *User) *PetCreate
- func (pc *PetCreate) SetTeamID(id string) *PetCreate
- type PetCreateBulk
- type PetDelete
- type PetDeleteOne
- type PetEdges
- type PetGroupBy
- func (pgb *PetGroupBy) Aggregate(fns ...AggregateFunc) *PetGroupBy
- func (pgb *PetGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (pgb *PetGroupBy) BoolX(ctx context.Context) bool
- func (pgb *PetGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (pgb *PetGroupBy) BoolsX(ctx context.Context) []bool
- func (pgb *PetGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (pgb *PetGroupBy) Float64X(ctx context.Context) float64
- func (pgb *PetGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (pgb *PetGroupBy) Float64sX(ctx context.Context) []float64
- func (pgb *PetGroupBy) Int(ctx context.Context) (_ int, err error)
- func (pgb *PetGroupBy) IntX(ctx context.Context) int
- func (pgb *PetGroupBy) Ints(ctx context.Context) ([]int, error)
- func (pgb *PetGroupBy) IntsX(ctx context.Context) []int
- func (pgb *PetGroupBy) Scan(ctx context.Context, v interface{}) error
- func (pgb *PetGroupBy) ScanX(ctx context.Context, v interface{})
- func (pgb *PetGroupBy) String(ctx context.Context) (_ string, err error)
- func (pgb *PetGroupBy) StringX(ctx context.Context) string
- func (pgb *PetGroupBy) Strings(ctx context.Context) ([]string, error)
- func (pgb *PetGroupBy) StringsX(ctx context.Context) []string
- type PetMutation
- func (m *PetMutation) AddField(name string, value ent.Value) error
- func (m *PetMutation) AddedEdges() []string
- func (m *PetMutation) AddedField(name string) (ent.Value, bool)
- func (m *PetMutation) AddedFields() []string
- func (m *PetMutation) AddedIDs(name string) []ent.Value
- func (m *PetMutation) ClearEdge(name string) error
- func (m *PetMutation) ClearField(name string) error
- func (m *PetMutation) ClearOwner()
- func (m *PetMutation) ClearTeam()
- func (m *PetMutation) ClearedEdges() []string
- func (m *PetMutation) ClearedFields() []string
- func (m PetMutation) Client() *Client
- func (m *PetMutation) EdgeCleared(name string) bool
- func (m *PetMutation) Field(name string) (ent.Value, bool)
- func (m *PetMutation) FieldCleared(name string) bool
- func (m *PetMutation) Fields() []string
- func (m *PetMutation) ID() (id string, exists bool)
- func (m *PetMutation) Name() (r string, exists bool)
- func (m *PetMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *PetMutation) OldName(ctx context.Context) (v string, err error)
- func (m *PetMutation) Op() Op
- func (m *PetMutation) OwnerCleared() bool
- func (m *PetMutation) OwnerID() (id string, exists bool)
- func (m *PetMutation) OwnerIDs() (ids []string)
- func (m *PetMutation) RemovedEdges() []string
- func (m *PetMutation) RemovedIDs(name string) []ent.Value
- func (m *PetMutation) ResetEdge(name string) error
- func (m *PetMutation) ResetField(name string) error
- func (m *PetMutation) ResetName()
- func (m *PetMutation) ResetOwner()
- func (m *PetMutation) ResetTeam()
- func (m *PetMutation) SetField(name string, value ent.Value) error
- func (m *PetMutation) SetName(s string)
- func (m *PetMutation) SetOwnerID(id string)
- func (m *PetMutation) SetTeamID(id string)
- func (m *PetMutation) TeamCleared() bool
- func (m *PetMutation) TeamID() (id string, exists bool)
- func (m *PetMutation) TeamIDs() (ids []string)
- func (m PetMutation) Tx() (*Tx, error)
- func (m *PetMutation) Type() string
- type PetQuery
- func (pq *PetQuery) All(ctx context.Context) ([]*Pet, error)
- func (pq *PetQuery) AllX(ctx context.Context) []*Pet
- func (pq *PetQuery) Clone() *PetQuery
- func (pq *PetQuery) Count(ctx context.Context) (int, error)
- func (pq *PetQuery) CountX(ctx context.Context) int
- func (pq *PetQuery) Exist(ctx context.Context) (bool, error)
- func (pq *PetQuery) ExistX(ctx context.Context) bool
- func (pq *PetQuery) First(ctx context.Context) (*Pet, error)
- func (pq *PetQuery) FirstID(ctx context.Context) (id string, err error)
- func (pq *PetQuery) FirstIDX(ctx context.Context) string
- func (pq *PetQuery) FirstX(ctx context.Context) *Pet
- func (pq *PetQuery) GroupBy(field string, fields ...string) *PetGroupBy
- func (pq *PetQuery) IDs(ctx context.Context) ([]string, error)
- func (pq *PetQuery) IDsX(ctx context.Context) []string
- func (pq *PetQuery) Limit(limit int) *PetQuery
- func (pq *PetQuery) Offset(offset int) *PetQuery
- func (pq *PetQuery) Only(ctx context.Context) (*Pet, error)
- func (pq *PetQuery) OnlyID(ctx context.Context) (id string, err error)
- func (pq *PetQuery) OnlyIDX(ctx context.Context) string
- func (pq *PetQuery) OnlyX(ctx context.Context) *Pet
- func (pq *PetQuery) Order(o ...OrderFunc) *PetQuery
- func (pq *PetQuery) QueryOwner() *UserQuery
- func (pq *PetQuery) QueryTeam() *UserQuery
- func (pq *PetQuery) Select(field string, fields ...string) *PetSelect
- func (pq *PetQuery) Where(ps ...predicate.Pet) *PetQuery
- func (pq *PetQuery) WithOwner(opts ...func(*UserQuery)) *PetQuery
- func (pq *PetQuery) WithTeam(opts ...func(*UserQuery)) *PetQuery
- type PetSelect
- func (ps *PetSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ps *PetSelect) BoolX(ctx context.Context) bool
- func (ps *PetSelect) Bools(ctx context.Context) ([]bool, error)
- func (ps *PetSelect) BoolsX(ctx context.Context) []bool
- func (ps *PetSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ps *PetSelect) Float64X(ctx context.Context) float64
- func (ps *PetSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ps *PetSelect) Float64sX(ctx context.Context) []float64
- func (ps *PetSelect) Int(ctx context.Context) (_ int, err error)
- func (ps *PetSelect) IntX(ctx context.Context) int
- func (ps *PetSelect) Ints(ctx context.Context) ([]int, error)
- func (ps *PetSelect) IntsX(ctx context.Context) []int
- func (ps *PetSelect) Scan(ctx context.Context, v interface{}) error
- func (ps *PetSelect) ScanX(ctx context.Context, v interface{})
- func (ps *PetSelect) String(ctx context.Context) (_ string, err error)
- func (ps *PetSelect) StringX(ctx context.Context) string
- func (ps *PetSelect) Strings(ctx context.Context) ([]string, error)
- func (ps *PetSelect) StringsX(ctx context.Context) []string
- type PetUpdate
- func (pu *PetUpdate) ClearOwner() *PetUpdate
- func (pu *PetUpdate) ClearTeam() *PetUpdate
- func (pu *PetUpdate) Exec(ctx context.Context) error
- func (pu *PetUpdate) ExecX(ctx context.Context)
- func (pu *PetUpdate) Mutation() *PetMutation
- func (pu *PetUpdate) Save(ctx context.Context) (int, error)
- func (pu *PetUpdate) SaveX(ctx context.Context) int
- func (pu *PetUpdate) SetName(s string) *PetUpdate
- func (pu *PetUpdate) SetNillableOwnerID(id *string) *PetUpdate
- func (pu *PetUpdate) SetNillableTeamID(id *string) *PetUpdate
- func (pu *PetUpdate) SetOwner(u *User) *PetUpdate
- func (pu *PetUpdate) SetOwnerID(id string) *PetUpdate
- func (pu *PetUpdate) SetTeam(u *User) *PetUpdate
- func (pu *PetUpdate) SetTeamID(id string) *PetUpdate
- func (pu *PetUpdate) Where(ps ...predicate.Pet) *PetUpdate
- type PetUpdateOne
- func (puo *PetUpdateOne) ClearOwner() *PetUpdateOne
- func (puo *PetUpdateOne) ClearTeam() *PetUpdateOne
- func (puo *PetUpdateOne) Exec(ctx context.Context) error
- func (puo *PetUpdateOne) ExecX(ctx context.Context)
- func (puo *PetUpdateOne) Mutation() *PetMutation
- func (puo *PetUpdateOne) Save(ctx context.Context) (*Pet, error)
- func (puo *PetUpdateOne) SaveX(ctx context.Context) *Pet
- func (puo *PetUpdateOne) SetName(s string) *PetUpdateOne
- func (puo *PetUpdateOne) SetNillableOwnerID(id *string) *PetUpdateOne
- func (puo *PetUpdateOne) SetNillableTeamID(id *string) *PetUpdateOne
- func (puo *PetUpdateOne) SetOwner(u *User) *PetUpdateOne
- func (puo *PetUpdateOne) SetOwnerID(id string) *PetUpdateOne
- func (puo *PetUpdateOne) SetTeam(u *User) *PetUpdateOne
- func (puo *PetUpdateOne) SetTeamID(id string) *PetUpdateOne
- type Pets
- type Policy
- type Query
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type Spec
- type SpecClient
- func (c *SpecClient) Create() *SpecCreate
- func (c *SpecClient) CreateBulk(builders ...*SpecCreate) *SpecCreateBulk
- func (c *SpecClient) Delete() *SpecDelete
- func (c *SpecClient) DeleteOne(s *Spec) *SpecDeleteOne
- func (c *SpecClient) DeleteOneID(id string) *SpecDeleteOne
- func (c *SpecClient) Get(ctx context.Context, id string) (*Spec, error)
- func (c *SpecClient) GetX(ctx context.Context, id string) *Spec
- func (c *SpecClient) Hooks() []Hook
- func (c *SpecClient) Query() *SpecQuery
- func (c *SpecClient) QueryCard(s *Spec) *CardQuery
- func (c *SpecClient) Update() *SpecUpdate
- func (c *SpecClient) UpdateOne(s *Spec) *SpecUpdateOne
- func (c *SpecClient) UpdateOneID(id string) *SpecUpdateOne
- func (c *SpecClient) Use(hooks ...Hook)
- type SpecCreate
- type SpecCreateBulk
- type SpecDelete
- type SpecDeleteOne
- type SpecEdges
- type SpecGroupBy
- func (sgb *SpecGroupBy) Aggregate(fns ...AggregateFunc) *SpecGroupBy
- func (sgb *SpecGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (sgb *SpecGroupBy) BoolX(ctx context.Context) bool
- func (sgb *SpecGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (sgb *SpecGroupBy) BoolsX(ctx context.Context) []bool
- func (sgb *SpecGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (sgb *SpecGroupBy) Float64X(ctx context.Context) float64
- func (sgb *SpecGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (sgb *SpecGroupBy) Float64sX(ctx context.Context) []float64
- func (sgb *SpecGroupBy) Int(ctx context.Context) (_ int, err error)
- func (sgb *SpecGroupBy) IntX(ctx context.Context) int
- func (sgb *SpecGroupBy) Ints(ctx context.Context) ([]int, error)
- func (sgb *SpecGroupBy) IntsX(ctx context.Context) []int
- func (sgb *SpecGroupBy) Scan(ctx context.Context, v interface{}) error
- func (sgb *SpecGroupBy) ScanX(ctx context.Context, v interface{})
- func (sgb *SpecGroupBy) String(ctx context.Context) (_ string, err error)
- func (sgb *SpecGroupBy) StringX(ctx context.Context) string
- func (sgb *SpecGroupBy) Strings(ctx context.Context) ([]string, error)
- func (sgb *SpecGroupBy) StringsX(ctx context.Context) []string
- type SpecMutation
- func (m *SpecMutation) AddCardIDs(ids ...string)
- func (m *SpecMutation) AddField(name string, value ent.Value) error
- func (m *SpecMutation) AddedEdges() []string
- func (m *SpecMutation) AddedField(name string) (ent.Value, bool)
- func (m *SpecMutation) AddedFields() []string
- func (m *SpecMutation) AddedIDs(name string) []ent.Value
- func (m *SpecMutation) CardCleared() bool
- func (m *SpecMutation) CardIDs() (ids []string)
- func (m *SpecMutation) ClearCard()
- func (m *SpecMutation) ClearEdge(name string) error
- func (m *SpecMutation) ClearField(name string) error
- func (m *SpecMutation) ClearedEdges() []string
- func (m *SpecMutation) ClearedFields() []string
- func (m SpecMutation) Client() *Client
- func (m *SpecMutation) EdgeCleared(name string) bool
- func (m *SpecMutation) Field(name string) (ent.Value, bool)
- func (m *SpecMutation) FieldCleared(name string) bool
- func (m *SpecMutation) Fields() []string
- func (m *SpecMutation) ID() (id string, exists bool)
- func (m *SpecMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *SpecMutation) Op() Op
- func (m *SpecMutation) RemoveCardIDs(ids ...string)
- func (m *SpecMutation) RemovedCardIDs() (ids []string)
- func (m *SpecMutation) RemovedEdges() []string
- func (m *SpecMutation) RemovedIDs(name string) []ent.Value
- func (m *SpecMutation) ResetCard()
- func (m *SpecMutation) ResetEdge(name string) error
- func (m *SpecMutation) ResetField(name string) error
- func (m *SpecMutation) SetField(name string, value ent.Value) error
- func (m SpecMutation) Tx() (*Tx, error)
- func (m *SpecMutation) Type() string
- type SpecQuery
- func (sq *SpecQuery) All(ctx context.Context) ([]*Spec, error)
- func (sq *SpecQuery) AllX(ctx context.Context) []*Spec
- func (sq *SpecQuery) Clone() *SpecQuery
- func (sq *SpecQuery) Count(ctx context.Context) (int, error)
- func (sq *SpecQuery) CountX(ctx context.Context) int
- func (sq *SpecQuery) Exist(ctx context.Context) (bool, error)
- func (sq *SpecQuery) ExistX(ctx context.Context) bool
- func (sq *SpecQuery) First(ctx context.Context) (*Spec, error)
- func (sq *SpecQuery) FirstID(ctx context.Context) (id string, err error)
- func (sq *SpecQuery) FirstIDX(ctx context.Context) string
- func (sq *SpecQuery) FirstX(ctx context.Context) *Spec
- func (sq *SpecQuery) GroupBy(field string, fields ...string) *SpecGroupBy
- func (sq *SpecQuery) IDs(ctx context.Context) ([]string, error)
- func (sq *SpecQuery) IDsX(ctx context.Context) []string
- func (sq *SpecQuery) Limit(limit int) *SpecQuery
- func (sq *SpecQuery) Offset(offset int) *SpecQuery
- func (sq *SpecQuery) Only(ctx context.Context) (*Spec, error)
- func (sq *SpecQuery) OnlyID(ctx context.Context) (id string, err error)
- func (sq *SpecQuery) OnlyIDX(ctx context.Context) string
- func (sq *SpecQuery) OnlyX(ctx context.Context) *Spec
- func (sq *SpecQuery) Order(o ...OrderFunc) *SpecQuery
- func (sq *SpecQuery) QueryCard() *CardQuery
- func (sq *SpecQuery) Select(field string, fields ...string) *SpecSelect
- func (sq *SpecQuery) Where(ps ...predicate.Spec) *SpecQuery
- func (sq *SpecQuery) WithCard(opts ...func(*CardQuery)) *SpecQuery
- type SpecSelect
- func (ss *SpecSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ss *SpecSelect) BoolX(ctx context.Context) bool
- func (ss *SpecSelect) Bools(ctx context.Context) ([]bool, error)
- func (ss *SpecSelect) BoolsX(ctx context.Context) []bool
- func (ss *SpecSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ss *SpecSelect) Float64X(ctx context.Context) float64
- func (ss *SpecSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ss *SpecSelect) Float64sX(ctx context.Context) []float64
- func (ss *SpecSelect) Int(ctx context.Context) (_ int, err error)
- func (ss *SpecSelect) IntX(ctx context.Context) int
- func (ss *SpecSelect) Ints(ctx context.Context) ([]int, error)
- func (ss *SpecSelect) IntsX(ctx context.Context) []int
- func (ss *SpecSelect) Scan(ctx context.Context, v interface{}) error
- func (ss *SpecSelect) ScanX(ctx context.Context, v interface{})
- func (ss *SpecSelect) String(ctx context.Context) (_ string, err error)
- func (ss *SpecSelect) StringX(ctx context.Context) string
- func (ss *SpecSelect) Strings(ctx context.Context) ([]string, error)
- func (ss *SpecSelect) StringsX(ctx context.Context) []string
- type SpecUpdate
- func (su *SpecUpdate) AddCard(c ...*Card) *SpecUpdate
- func (su *SpecUpdate) AddCardIDs(ids ...string) *SpecUpdate
- func (su *SpecUpdate) ClearCard() *SpecUpdate
- func (su *SpecUpdate) Exec(ctx context.Context) error
- func (su *SpecUpdate) ExecX(ctx context.Context)
- func (su *SpecUpdate) Mutation() *SpecMutation
- func (su *SpecUpdate) RemoveCard(c ...*Card) *SpecUpdate
- func (su *SpecUpdate) RemoveCardIDs(ids ...string) *SpecUpdate
- func (su *SpecUpdate) Save(ctx context.Context) (int, error)
- func (su *SpecUpdate) SaveX(ctx context.Context) int
- func (su *SpecUpdate) Where(ps ...predicate.Spec) *SpecUpdate
- type SpecUpdateOne
- func (suo *SpecUpdateOne) AddCard(c ...*Card) *SpecUpdateOne
- func (suo *SpecUpdateOne) AddCardIDs(ids ...string) *SpecUpdateOne
- func (suo *SpecUpdateOne) ClearCard() *SpecUpdateOne
- func (suo *SpecUpdateOne) Exec(ctx context.Context) error
- func (suo *SpecUpdateOne) ExecX(ctx context.Context)
- func (suo *SpecUpdateOne) Mutation() *SpecMutation
- func (suo *SpecUpdateOne) RemoveCard(c ...*Card) *SpecUpdateOne
- func (suo *SpecUpdateOne) RemoveCardIDs(ids ...string) *SpecUpdateOne
- func (suo *SpecUpdateOne) Save(ctx context.Context) (*Spec, error)
- func (suo *SpecUpdateOne) SaveX(ctx context.Context) *Spec
- type Specs
- type Task
- type TaskClient
- func (c *TaskClient) Create() *TaskCreate
- func (c *TaskClient) CreateBulk(builders ...*TaskCreate) *TaskCreateBulk
- func (c *TaskClient) Delete() *TaskDelete
- func (c *TaskClient) DeleteOne(t *Task) *TaskDeleteOne
- func (c *TaskClient) DeleteOneID(id string) *TaskDeleteOne
- func (c *TaskClient) Get(ctx context.Context, id string) (*Task, error)
- func (c *TaskClient) GetX(ctx context.Context, id string) *Task
- func (c *TaskClient) Hooks() []Hook
- func (c *TaskClient) Query() *TaskQuery
- func (c *TaskClient) Update() *TaskUpdate
- func (c *TaskClient) UpdateOne(t *Task) *TaskUpdateOne
- func (c *TaskClient) UpdateOneID(id string) *TaskUpdateOne
- func (c *TaskClient) Use(hooks ...Hook)
- type TaskCreate
- func (tc *TaskCreate) Mutation() *TaskMutation
- func (tc *TaskCreate) Save(ctx context.Context) (*Task, error)
- func (tc *TaskCreate) SaveX(ctx context.Context) *Task
- func (tc *TaskCreate) SetNillablePriority(s *schema.Priority) *TaskCreate
- func (tc *TaskCreate) SetPriority(s schema.Priority) *TaskCreate
- type TaskCreateBulk
- type TaskDelete
- type TaskDeleteOne
- type TaskGroupBy
- func (tgb *TaskGroupBy) Aggregate(fns ...AggregateFunc) *TaskGroupBy
- func (tgb *TaskGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (tgb *TaskGroupBy) BoolX(ctx context.Context) bool
- func (tgb *TaskGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (tgb *TaskGroupBy) BoolsX(ctx context.Context) []bool
- func (tgb *TaskGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (tgb *TaskGroupBy) Float64X(ctx context.Context) float64
- func (tgb *TaskGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (tgb *TaskGroupBy) Float64sX(ctx context.Context) []float64
- func (tgb *TaskGroupBy) Int(ctx context.Context) (_ int, err error)
- func (tgb *TaskGroupBy) IntX(ctx context.Context) int
- func (tgb *TaskGroupBy) Ints(ctx context.Context) ([]int, error)
- func (tgb *TaskGroupBy) IntsX(ctx context.Context) []int
- func (tgb *TaskGroupBy) Scan(ctx context.Context, v interface{}) error
- func (tgb *TaskGroupBy) ScanX(ctx context.Context, v interface{})
- func (tgb *TaskGroupBy) String(ctx context.Context) (_ string, err error)
- func (tgb *TaskGroupBy) StringX(ctx context.Context) string
- func (tgb *TaskGroupBy) Strings(ctx context.Context) ([]string, error)
- func (tgb *TaskGroupBy) StringsX(ctx context.Context) []string
- type TaskMutation
- func (m *TaskMutation) AddField(name string, value ent.Value) error
- func (m *TaskMutation) AddPriority(s schema.Priority)
- func (m *TaskMutation) AddedEdges() []string
- func (m *TaskMutation) AddedField(name string) (ent.Value, bool)
- func (m *TaskMutation) AddedFields() []string
- func (m *TaskMutation) AddedIDs(name string) []ent.Value
- func (m *TaskMutation) AddedPriority() (r schema.Priority, exists bool)
- func (m *TaskMutation) ClearEdge(name string) error
- func (m *TaskMutation) ClearField(name string) error
- func (m *TaskMutation) ClearedEdges() []string
- func (m *TaskMutation) ClearedFields() []string
- func (m TaskMutation) Client() *Client
- func (m *TaskMutation) EdgeCleared(name string) bool
- func (m *TaskMutation) Field(name string) (ent.Value, bool)
- func (m *TaskMutation) FieldCleared(name string) bool
- func (m *TaskMutation) Fields() []string
- func (m *TaskMutation) ID() (id string, exists bool)
- func (m *TaskMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *TaskMutation) OldPriority(ctx context.Context) (v schema.Priority, err error)
- func (m *TaskMutation) Op() Op
- func (m *TaskMutation) Priority() (r schema.Priority, exists bool)
- func (m *TaskMutation) RemovedEdges() []string
- func (m *TaskMutation) RemovedIDs(name string) []ent.Value
- func (m *TaskMutation) ResetEdge(name string) error
- func (m *TaskMutation) ResetField(name string) error
- func (m *TaskMutation) ResetPriority()
- func (m *TaskMutation) SetField(name string, value ent.Value) error
- func (m *TaskMutation) SetPriority(s schema.Priority)
- func (m TaskMutation) Tx() (*Tx, error)
- func (m *TaskMutation) Type() string
- type TaskQuery
- func (tq *TaskQuery) All(ctx context.Context) ([]*Task, error)
- func (tq *TaskQuery) AllX(ctx context.Context) []*Task
- func (tq *TaskQuery) Clone() *TaskQuery
- func (tq *TaskQuery) Count(ctx context.Context) (int, error)
- func (tq *TaskQuery) CountX(ctx context.Context) int
- func (tq *TaskQuery) Exist(ctx context.Context) (bool, error)
- func (tq *TaskQuery) ExistX(ctx context.Context) bool
- func (tq *TaskQuery) First(ctx context.Context) (*Task, error)
- func (tq *TaskQuery) FirstID(ctx context.Context) (id string, err error)
- func (tq *TaskQuery) FirstIDX(ctx context.Context) string
- func (tq *TaskQuery) FirstX(ctx context.Context) *Task
- func (tq *TaskQuery) GroupBy(field string, fields ...string) *TaskGroupBy
- func (tq *TaskQuery) IDs(ctx context.Context) ([]string, error)
- func (tq *TaskQuery) IDsX(ctx context.Context) []string
- func (tq *TaskQuery) Limit(limit int) *TaskQuery
- func (tq *TaskQuery) Offset(offset int) *TaskQuery
- func (tq *TaskQuery) Only(ctx context.Context) (*Task, error)
- func (tq *TaskQuery) OnlyID(ctx context.Context) (id string, err error)
- func (tq *TaskQuery) OnlyIDX(ctx context.Context) string
- func (tq *TaskQuery) OnlyX(ctx context.Context) *Task
- func (tq *TaskQuery) Order(o ...OrderFunc) *TaskQuery
- func (tq *TaskQuery) Select(field string, fields ...string) *TaskSelect
- func (tq *TaskQuery) Where(ps ...predicate.Task) *TaskQuery
- type TaskSelect
- func (ts *TaskSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ts *TaskSelect) BoolX(ctx context.Context) bool
- func (ts *TaskSelect) Bools(ctx context.Context) ([]bool, error)
- func (ts *TaskSelect) BoolsX(ctx context.Context) []bool
- func (ts *TaskSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ts *TaskSelect) Float64X(ctx context.Context) float64
- func (ts *TaskSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ts *TaskSelect) Float64sX(ctx context.Context) []float64
- func (ts *TaskSelect) Int(ctx context.Context) (_ int, err error)
- func (ts *TaskSelect) IntX(ctx context.Context) int
- func (ts *TaskSelect) Ints(ctx context.Context) ([]int, error)
- func (ts *TaskSelect) IntsX(ctx context.Context) []int
- func (ts *TaskSelect) Scan(ctx context.Context, v interface{}) error
- func (ts *TaskSelect) ScanX(ctx context.Context, v interface{})
- func (ts *TaskSelect) String(ctx context.Context) (_ string, err error)
- func (ts *TaskSelect) StringX(ctx context.Context) string
- func (ts *TaskSelect) Strings(ctx context.Context) ([]string, error)
- func (ts *TaskSelect) StringsX(ctx context.Context) []string
- type TaskUpdate
- func (tu *TaskUpdate) AddPriority(s schema.Priority) *TaskUpdate
- func (tu *TaskUpdate) Exec(ctx context.Context) error
- func (tu *TaskUpdate) ExecX(ctx context.Context)
- func (tu *TaskUpdate) Mutation() *TaskMutation
- func (tu *TaskUpdate) Save(ctx context.Context) (int, error)
- func (tu *TaskUpdate) SaveX(ctx context.Context) int
- func (tu *TaskUpdate) SetNillablePriority(s *schema.Priority) *TaskUpdate
- func (tu *TaskUpdate) SetPriority(s schema.Priority) *TaskUpdate
- func (tu *TaskUpdate) Where(ps ...predicate.Task) *TaskUpdate
- type TaskUpdateOne
- func (tuo *TaskUpdateOne) AddPriority(s schema.Priority) *TaskUpdateOne
- func (tuo *TaskUpdateOne) Exec(ctx context.Context) error
- func (tuo *TaskUpdateOne) ExecX(ctx context.Context)
- func (tuo *TaskUpdateOne) Mutation() *TaskMutation
- func (tuo *TaskUpdateOne) Save(ctx context.Context) (*Task, error)
- func (tuo *TaskUpdateOne) SaveX(ctx context.Context) *Task
- func (tuo *TaskUpdateOne) SetNillablePriority(s *schema.Priority) *TaskUpdateOne
- func (tuo *TaskUpdateOne) SetPriority(s schema.Priority) *TaskUpdateOne
- type Tasks
- type Tx
- type User
- func (u *User) FromResponse(res *gremlin.Response) error
- func (u *User) QueryCard() *CardQuery
- func (u *User) QueryChildren() *UserQuery
- func (u *User) QueryFiles() *FileQuery
- func (u *User) QueryFollowers() *UserQuery
- func (u *User) QueryFollowing() *UserQuery
- func (u *User) QueryFriends() *UserQuery
- func (u *User) QueryGroups() *GroupQuery
- func (u *User) QueryParent() *UserQuery
- func (u *User) QueryPets() *PetQuery
- func (u *User) QuerySpouse() *UserQuery
- func (u *User) QueryTeam() *PetQuery
- func (u *User) String() string
- 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 string) *UserDeleteOne
- func (c *UserClient) Get(ctx context.Context, id string) (*User, error)
- func (c *UserClient) GetX(ctx context.Context, id string) *User
- func (c *UserClient) Hooks() []Hook
- func (c *UserClient) Query() *UserQuery
- func (c *UserClient) QueryCard(u *User) *CardQuery
- func (c *UserClient) QueryChildren(u *User) *UserQuery
- func (c *UserClient) QueryFiles(u *User) *FileQuery
- func (c *UserClient) QueryFollowers(u *User) *UserQuery
- func (c *UserClient) QueryFollowing(u *User) *UserQuery
- func (c *UserClient) QueryFriends(u *User) *UserQuery
- func (c *UserClient) QueryGroups(u *User) *GroupQuery
- func (c *UserClient) QueryParent(u *User) *UserQuery
- func (c *UserClient) QueryPets(u *User) *PetQuery
- func (c *UserClient) QuerySpouse(u *User) *UserQuery
- func (c *UserClient) QueryTeam(u *User) *PetQuery
- func (c *UserClient) Update() *UserUpdate
- func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
- func (c *UserClient) UpdateOneID(id string) *UserUpdateOne
- func (c *UserClient) Use(hooks ...Hook)
- type UserCreate
- func (uc *UserCreate) AddChildIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddChildren(u ...*User) *UserCreate
- func (uc *UserCreate) AddFileIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddFiles(f ...*File) *UserCreate
- func (uc *UserCreate) AddFollowerIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddFollowers(u ...*User) *UserCreate
- func (uc *UserCreate) AddFollowing(u ...*User) *UserCreate
- func (uc *UserCreate) AddFollowingIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddFriendIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddFriends(u ...*User) *UserCreate
- func (uc *UserCreate) AddGroupIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddGroups(g ...*Group) *UserCreate
- func (uc *UserCreate) AddPetIDs(ids ...string) *UserCreate
- func (uc *UserCreate) AddPets(p ...*Pet) *UserCreate
- 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) SetAge(i int) *UserCreate
- func (uc *UserCreate) SetCard(c *Card) *UserCreate
- func (uc *UserCreate) SetCardID(id string) *UserCreate
- func (uc *UserCreate) SetLast(s string) *UserCreate
- func (uc *UserCreate) SetName(s string) *UserCreate
- func (uc *UserCreate) SetNickname(s string) *UserCreate
- func (uc *UserCreate) SetNillableCardID(id *string) *UserCreate
- func (uc *UserCreate) SetNillableLast(s *string) *UserCreate
- func (uc *UserCreate) SetNillableNickname(s *string) *UserCreate
- func (uc *UserCreate) SetNillableOptionalInt(i *int) *UserCreate
- func (uc *UserCreate) SetNillableParentID(id *string) *UserCreate
- func (uc *UserCreate) SetNillablePassword(s *string) *UserCreate
- func (uc *UserCreate) SetNillablePhone(s *string) *UserCreate
- func (uc *UserCreate) SetNillableRole(u *user.Role) *UserCreate
- func (uc *UserCreate) SetNillableSSOCert(s *string) *UserCreate
- func (uc *UserCreate) SetNillableSpouseID(id *string) *UserCreate
- func (uc *UserCreate) SetNillableTeamID(id *string) *UserCreate
- func (uc *UserCreate) SetOptionalInt(i int) *UserCreate
- func (uc *UserCreate) SetParent(u *User) *UserCreate
- func (uc *UserCreate) SetParentID(id string) *UserCreate
- func (uc *UserCreate) SetPassword(s string) *UserCreate
- func (uc *UserCreate) SetPhone(s string) *UserCreate
- func (uc *UserCreate) SetRole(u user.Role) *UserCreate
- func (uc *UserCreate) SetSSOCert(s string) *UserCreate
- func (uc *UserCreate) SetSpouse(u *User) *UserCreate
- func (uc *UserCreate) SetSpouseID(id string) *UserCreate
- func (uc *UserCreate) SetTeam(p *Pet) *UserCreate
- func (uc *UserCreate) SetTeamID(id string) *UserCreate
- type UserCreateBulk
- type UserDelete
- type UserDeleteOne
- type UserEdges
- func (e UserEdges) CardOrErr() (*Card, error)
- func (e UserEdges) ChildrenOrErr() ([]*User, error)
- func (e UserEdges) FilesOrErr() ([]*File, error)
- func (e UserEdges) FollowersOrErr() ([]*User, error)
- func (e UserEdges) FollowingOrErr() ([]*User, error)
- func (e UserEdges) FriendsOrErr() ([]*User, error)
- func (e UserEdges) GroupsOrErr() ([]*Group, error)
- func (e UserEdges) ParentOrErr() (*User, error)
- func (e UserEdges) PetsOrErr() ([]*Pet, error)
- func (e UserEdges) SpouseOrErr() (*User, error)
- func (e UserEdges) TeamOrErr() (*Pet, error)
- type UserGroupBy
- func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
- func (ugb *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ugb *UserGroupBy) BoolX(ctx context.Context) bool
- func (ugb *UserGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ugb *UserGroupBy) BoolsX(ctx context.Context) []bool
- func (ugb *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ugb *UserGroupBy) Float64X(ctx context.Context) float64
- func (ugb *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ugb *UserGroupBy) Float64sX(ctx context.Context) []float64
- func (ugb *UserGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ugb *UserGroupBy) IntX(ctx context.Context) int
- func (ugb *UserGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ugb *UserGroupBy) IntsX(ctx context.Context) []int
- func (ugb *UserGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ugb *UserGroupBy) ScanX(ctx context.Context, v interface{})
- func (ugb *UserGroupBy) String(ctx context.Context) (_ string, err error)
- func (ugb *UserGroupBy) StringX(ctx context.Context) string
- func (ugb *UserGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ugb *UserGroupBy) StringsX(ctx context.Context) []string
- type UserMutation
- func (m *UserMutation) AddAge(i int)
- func (m *UserMutation) AddChildIDs(ids ...string)
- func (m *UserMutation) AddField(name string, value ent.Value) error
- func (m *UserMutation) AddFileIDs(ids ...string)
- func (m *UserMutation) AddFollowerIDs(ids ...string)
- func (m *UserMutation) AddFollowingIDs(ids ...string)
- func (m *UserMutation) AddFriendIDs(ids ...string)
- func (m *UserMutation) AddGroupIDs(ids ...string)
- func (m *UserMutation) AddOptionalInt(i int)
- func (m *UserMutation) AddPetIDs(ids ...string)
- func (m *UserMutation) AddedAge() (r int, exists bool)
- 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) AddedOptionalInt() (r int, exists bool)
- func (m *UserMutation) Age() (r int, exists bool)
- func (m *UserMutation) CardCleared() bool
- func (m *UserMutation) CardID() (id string, exists bool)
- func (m *UserMutation) CardIDs() (ids []string)
- func (m *UserMutation) ChildrenCleared() bool
- func (m *UserMutation) ChildrenIDs() (ids []string)
- func (m *UserMutation) ClearCard()
- func (m *UserMutation) ClearChildren()
- func (m *UserMutation) ClearEdge(name string) error
- func (m *UserMutation) ClearField(name string) error
- func (m *UserMutation) ClearFiles()
- func (m *UserMutation) ClearFollowers()
- func (m *UserMutation) ClearFollowing()
- func (m *UserMutation) ClearFriends()
- func (m *UserMutation) ClearGroups()
- func (m *UserMutation) ClearNickname()
- func (m *UserMutation) ClearOptionalInt()
- func (m *UserMutation) ClearParent()
- func (m *UserMutation) ClearPassword()
- func (m *UserMutation) ClearPets()
- func (m *UserMutation) ClearPhone()
- func (m *UserMutation) ClearSSOCert()
- func (m *UserMutation) ClearSpouse()
- func (m *UserMutation) ClearTeam()
- func (m *UserMutation) ClearedEdges() []string
- func (m *UserMutation) ClearedFields() []string
- func (m UserMutation) Client() *Client
- func (m *UserMutation) EdgeCleared(name string) 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) FilesCleared() bool
- func (m *UserMutation) FilesIDs() (ids []string)
- func (m *UserMutation) FollowersCleared() bool
- func (m *UserMutation) FollowersIDs() (ids []string)
- func (m *UserMutation) FollowingCleared() bool
- func (m *UserMutation) FollowingIDs() (ids []string)
- func (m *UserMutation) FriendsCleared() bool
- func (m *UserMutation) FriendsIDs() (ids []string)
- func (m *UserMutation) GroupsCleared() bool
- func (m *UserMutation) GroupsIDs() (ids []string)
- func (m *UserMutation) ID() (id string, exists bool)
- func (m *UserMutation) Last() (r string, exists bool)
- func (m *UserMutation) Name() (r string, exists bool)
- func (m *UserMutation) Nickname() (r string, exists bool)
- func (m *UserMutation) NicknameCleared() bool
- func (m *UserMutation) OldAge(ctx context.Context) (v int, err error)
- func (m *UserMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *UserMutation) OldLast(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldName(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldNickname(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldOptionalInt(ctx context.Context) (v int, err error)
- func (m *UserMutation) OldPassword(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldPhone(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldRole(ctx context.Context) (v user.Role, err error)
- func (m *UserMutation) OldSSOCert(ctx context.Context) (v string, err error)
- func (m *UserMutation) Op() Op
- func (m *UserMutation) OptionalInt() (r int, exists bool)
- func (m *UserMutation) OptionalIntCleared() bool
- func (m *UserMutation) ParentCleared() bool
- func (m *UserMutation) ParentID() (id string, exists bool)
- func (m *UserMutation) ParentIDs() (ids []string)
- func (m *UserMutation) Password() (r string, exists bool)
- func (m *UserMutation) PasswordCleared() bool
- func (m *UserMutation) PetsCleared() bool
- func (m *UserMutation) PetsIDs() (ids []string)
- func (m *UserMutation) Phone() (r string, exists bool)
- func (m *UserMutation) PhoneCleared() bool
- func (m *UserMutation) RemoveChildIDs(ids ...string)
- func (m *UserMutation) RemoveFileIDs(ids ...string)
- func (m *UserMutation) RemoveFollowerIDs(ids ...string)
- func (m *UserMutation) RemoveFollowingIDs(ids ...string)
- func (m *UserMutation) RemoveFriendIDs(ids ...string)
- func (m *UserMutation) RemoveGroupIDs(ids ...string)
- func (m *UserMutation) RemovePetIDs(ids ...string)
- func (m *UserMutation) RemovedChildrenIDs() (ids []string)
- func (m *UserMutation) RemovedEdges() []string
- func (m *UserMutation) RemovedFilesIDs() (ids []string)
- func (m *UserMutation) RemovedFollowersIDs() (ids []string)
- func (m *UserMutation) RemovedFollowingIDs() (ids []string)
- func (m *UserMutation) RemovedFriendsIDs() (ids []string)
- func (m *UserMutation) RemovedGroupsIDs() (ids []string)
- func (m *UserMutation) RemovedIDs(name string) []ent.Value
- func (m *UserMutation) RemovedPetsIDs() (ids []string)
- func (m *UserMutation) ResetAge()
- func (m *UserMutation) ResetCard()
- func (m *UserMutation) ResetChildren()
- func (m *UserMutation) ResetEdge(name string) error
- func (m *UserMutation) ResetField(name string) error
- func (m *UserMutation) ResetFiles()
- func (m *UserMutation) ResetFollowers()
- func (m *UserMutation) ResetFollowing()
- func (m *UserMutation) ResetFriends()
- func (m *UserMutation) ResetGroups()
- func (m *UserMutation) ResetLast()
- func (m *UserMutation) ResetName()
- func (m *UserMutation) ResetNickname()
- func (m *UserMutation) ResetOptionalInt()
- func (m *UserMutation) ResetParent()
- func (m *UserMutation) ResetPassword()
- func (m *UserMutation) ResetPets()
- func (m *UserMutation) ResetPhone()
- func (m *UserMutation) ResetRole()
- func (m *UserMutation) ResetSSOCert()
- func (m *UserMutation) ResetSpouse()
- func (m *UserMutation) ResetTeam()
- func (m *UserMutation) Role() (r user.Role, exists bool)
- func (m *UserMutation) SSOCert() (r string, exists bool)
- func (m *UserMutation) SSOCertCleared() bool
- func (m *UserMutation) SetAge(i int)
- func (m *UserMutation) SetCardID(id string)
- func (m *UserMutation) SetField(name string, value ent.Value) error
- func (m *UserMutation) SetLast(s string)
- func (m *UserMutation) SetName(s string)
- func (m *UserMutation) SetNickname(s string)
- func (m *UserMutation) SetOptionalInt(i int)
- func (m *UserMutation) SetParentID(id string)
- func (m *UserMutation) SetPassword(s string)
- func (m *UserMutation) SetPhone(s string)
- func (m *UserMutation) SetRole(u user.Role)
- func (m *UserMutation) SetSSOCert(s string)
- func (m *UserMutation) SetSpouseID(id string)
- func (m *UserMutation) SetTeamID(id string)
- func (m *UserMutation) SpouseCleared() bool
- func (m *UserMutation) SpouseID() (id string, exists bool)
- func (m *UserMutation) SpouseIDs() (ids []string)
- func (m *UserMutation) TeamCleared() bool
- func (m *UserMutation) TeamID() (id string, exists bool)
- func (m *UserMutation) TeamIDs() (ids []string)
- func (m UserMutation) Tx() (*Tx, error)
- func (m *UserMutation) Type() string
- type UserQuery
- func (uq *UserQuery) All(ctx context.Context) ([]*User, error)
- func (uq *UserQuery) AllX(ctx context.Context) []*User
- func (uq *UserQuery) Clone() *UserQuery
- 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 string, err error)
- func (uq *UserQuery) FirstIDX(ctx context.Context) string
- func (uq *UserQuery) FirstX(ctx context.Context) *User
- func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
- func (uq *UserQuery) IDs(ctx context.Context) ([]string, error)
- func (uq *UserQuery) IDsX(ctx context.Context) []string
- 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 string, err error)
- func (uq *UserQuery) OnlyIDX(ctx context.Context) string
- func (uq *UserQuery) OnlyX(ctx context.Context) *User
- func (uq *UserQuery) Order(o ...OrderFunc) *UserQuery
- func (uq *UserQuery) QueryCard() *CardQuery
- func (uq *UserQuery) QueryChildren() *UserQuery
- func (uq *UserQuery) QueryFiles() *FileQuery
- func (uq *UserQuery) QueryFollowers() *UserQuery
- func (uq *UserQuery) QueryFollowing() *UserQuery
- func (uq *UserQuery) QueryFriends() *UserQuery
- func (uq *UserQuery) QueryGroups() *GroupQuery
- func (uq *UserQuery) QueryParent() *UserQuery
- func (uq *UserQuery) QueryPets() *PetQuery
- func (uq *UserQuery) QuerySpouse() *UserQuery
- func (uq *UserQuery) QueryTeam() *PetQuery
- func (uq *UserQuery) Select(field string, fields ...string) *UserSelect
- func (uq *UserQuery) Where(ps ...predicate.User) *UserQuery
- func (uq *UserQuery) WithCard(opts ...func(*CardQuery)) *UserQuery
- func (uq *UserQuery) WithChildren(opts ...func(*UserQuery)) *UserQuery
- func (uq *UserQuery) WithFiles(opts ...func(*FileQuery)) *UserQuery
- func (uq *UserQuery) WithFollowers(opts ...func(*UserQuery)) *UserQuery
- func (uq *UserQuery) WithFollowing(opts ...func(*UserQuery)) *UserQuery
- func (uq *UserQuery) WithFriends(opts ...func(*UserQuery)) *UserQuery
- func (uq *UserQuery) WithGroups(opts ...func(*GroupQuery)) *UserQuery
- func (uq *UserQuery) WithParent(opts ...func(*UserQuery)) *UserQuery
- func (uq *UserQuery) WithPets(opts ...func(*PetQuery)) *UserQuery
- func (uq *UserQuery) WithSpouse(opts ...func(*UserQuery)) *UserQuery
- func (uq *UserQuery) WithTeam(opts ...func(*PetQuery)) *UserQuery
- type UserSelect
- func (us *UserSelect) Bool(ctx context.Context) (_ bool, err error)
- func (us *UserSelect) BoolX(ctx context.Context) bool
- func (us *UserSelect) Bools(ctx context.Context) ([]bool, error)
- func (us *UserSelect) BoolsX(ctx context.Context) []bool
- func (us *UserSelect) Float64(ctx context.Context) (_ float64, err error)
- func (us *UserSelect) Float64X(ctx context.Context) float64
- func (us *UserSelect) Float64s(ctx context.Context) ([]float64, error)
- func (us *UserSelect) Float64sX(ctx context.Context) []float64
- func (us *UserSelect) Int(ctx context.Context) (_ int, err error)
- func (us *UserSelect) IntX(ctx context.Context) int
- func (us *UserSelect) Ints(ctx context.Context) ([]int, error)
- func (us *UserSelect) IntsX(ctx context.Context) []int
- func (us *UserSelect) Scan(ctx context.Context, v interface{}) error
- func (us *UserSelect) ScanX(ctx context.Context, v interface{})
- func (us *UserSelect) String(ctx context.Context) (_ string, err error)
- func (us *UserSelect) StringX(ctx context.Context) string
- func (us *UserSelect) Strings(ctx context.Context) ([]string, error)
- func (us *UserSelect) StringsX(ctx context.Context) []string
- type UserUpdate
- func (uu *UserUpdate) AddAge(i int) *UserUpdate
- func (uu *UserUpdate) AddChildIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddChildren(u ...*User) *UserUpdate
- func (uu *UserUpdate) AddFileIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddFiles(f ...*File) *UserUpdate
- func (uu *UserUpdate) AddFollowerIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddFollowers(u ...*User) *UserUpdate
- func (uu *UserUpdate) AddFollowing(u ...*User) *UserUpdate
- func (uu *UserUpdate) AddFollowingIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddFriendIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddFriends(u ...*User) *UserUpdate
- func (uu *UserUpdate) AddGroupIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddGroups(g ...*Group) *UserUpdate
- func (uu *UserUpdate) AddOptionalInt(i int) *UserUpdate
- func (uu *UserUpdate) AddPetIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) AddPets(p ...*Pet) *UserUpdate
- func (uu *UserUpdate) ClearCard() *UserUpdate
- func (uu *UserUpdate) ClearChildren() *UserUpdate
- func (uu *UserUpdate) ClearFiles() *UserUpdate
- func (uu *UserUpdate) ClearFollowers() *UserUpdate
- func (uu *UserUpdate) ClearFollowing() *UserUpdate
- func (uu *UserUpdate) ClearFriends() *UserUpdate
- func (uu *UserUpdate) ClearGroups() *UserUpdate
- func (uu *UserUpdate) ClearNickname() *UserUpdate
- func (uu *UserUpdate) ClearOptionalInt() *UserUpdate
- func (uu *UserUpdate) ClearParent() *UserUpdate
- func (uu *UserUpdate) ClearPassword() *UserUpdate
- func (uu *UserUpdate) ClearPets() *UserUpdate
- func (uu *UserUpdate) ClearPhone() *UserUpdate
- func (uu *UserUpdate) ClearSSOCert() *UserUpdate
- func (uu *UserUpdate) ClearSpouse() *UserUpdate
- func (uu *UserUpdate) ClearTeam() *UserUpdate
- func (uu *UserUpdate) Exec(ctx context.Context) error
- func (uu *UserUpdate) ExecX(ctx context.Context)
- func (uu *UserUpdate) Mutation() *UserMutation
- func (uu *UserUpdate) RemoveChildIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemoveChildren(u ...*User) *UserUpdate
- func (uu *UserUpdate) RemoveFileIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemoveFiles(f ...*File) *UserUpdate
- func (uu *UserUpdate) RemoveFollowerIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemoveFollowers(u ...*User) *UserUpdate
- func (uu *UserUpdate) RemoveFollowing(u ...*User) *UserUpdate
- func (uu *UserUpdate) RemoveFollowingIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemoveFriendIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemoveFriends(u ...*User) *UserUpdate
- func (uu *UserUpdate) RemoveGroupIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemoveGroups(g ...*Group) *UserUpdate
- func (uu *UserUpdate) RemovePetIDs(ids ...string) *UserUpdate
- func (uu *UserUpdate) RemovePets(p ...*Pet) *UserUpdate
- func (uu *UserUpdate) Save(ctx context.Context) (int, error)
- func (uu *UserUpdate) SaveX(ctx context.Context) int
- func (uu *UserUpdate) SetAge(i int) *UserUpdate
- func (uu *UserUpdate) SetCard(c *Card) *UserUpdate
- func (uu *UserUpdate) SetCardID(id string) *UserUpdate
- func (uu *UserUpdate) SetLast(s string) *UserUpdate
- func (uu *UserUpdate) SetName(s string) *UserUpdate
- func (uu *UserUpdate) SetNickname(s string) *UserUpdate
- func (uu *UserUpdate) SetNillableCardID(id *string) *UserUpdate
- func (uu *UserUpdate) SetNillableLast(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableNickname(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableOptionalInt(i *int) *UserUpdate
- func (uu *UserUpdate) SetNillableParentID(id *string) *UserUpdate
- func (uu *UserUpdate) SetNillablePassword(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillablePhone(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableRole(u *user.Role) *UserUpdate
- func (uu *UserUpdate) SetNillableSSOCert(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableSpouseID(id *string) *UserUpdate
- func (uu *UserUpdate) SetNillableTeamID(id *string) *UserUpdate
- func (uu *UserUpdate) SetOptionalInt(i int) *UserUpdate
- func (uu *UserUpdate) SetParent(u *User) *UserUpdate
- func (uu *UserUpdate) SetParentID(id string) *UserUpdate
- func (uu *UserUpdate) SetPassword(s string) *UserUpdate
- func (uu *UserUpdate) SetPhone(s string) *UserUpdate
- func (uu *UserUpdate) SetRole(u user.Role) *UserUpdate
- func (uu *UserUpdate) SetSSOCert(s string) *UserUpdate
- func (uu *UserUpdate) SetSpouse(u *User) *UserUpdate
- func (uu *UserUpdate) SetSpouseID(id string) *UserUpdate
- func (uu *UserUpdate) SetTeam(p *Pet) *UserUpdate
- func (uu *UserUpdate) SetTeamID(id string) *UserUpdate
- func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
- type UserUpdateOne
- func (uuo *UserUpdateOne) AddAge(i int) *UserUpdateOne
- func (uuo *UserUpdateOne) AddChildIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddChildren(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFileIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFiles(f ...*File) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFollowerIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFollowers(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFollowing(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFollowingIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFriendIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddFriends(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) AddGroupIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddGroups(g ...*Group) *UserUpdateOne
- func (uuo *UserUpdateOne) AddOptionalInt(i int) *UserUpdateOne
- func (uuo *UserUpdateOne) AddPetIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) AddPets(p ...*Pet) *UserUpdateOne
- func (uuo *UserUpdateOne) ClearCard() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearChildren() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearFiles() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearFollowers() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearFollowing() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearFriends() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearGroups() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearNickname() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearOptionalInt() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearParent() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearPassword() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearPets() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearPhone() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearSSOCert() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearSpouse() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearTeam() *UserUpdateOne
- func (uuo *UserUpdateOne) Exec(ctx context.Context) error
- func (uuo *UserUpdateOne) ExecX(ctx context.Context)
- func (uuo *UserUpdateOne) Mutation() *UserMutation
- func (uuo *UserUpdateOne) RemoveChildIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveChildren(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFileIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFiles(f ...*File) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFollowerIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFollowers(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFollowing(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFollowingIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFriendIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveFriends(u ...*User) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveGroupIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveGroups(g ...*Group) *UserUpdateOne
- func (uuo *UserUpdateOne) RemovePetIDs(ids ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) RemovePets(p ...*Pet) *UserUpdateOne
- func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
- func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
- func (uuo *UserUpdateOne) SetAge(i int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetCard(c *Card) *UserUpdateOne
- func (uuo *UserUpdateOne) SetCardID(id string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetLast(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNickname(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableCardID(id *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableLast(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableNickname(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableOptionalInt(i *int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableParentID(id *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillablePassword(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillablePhone(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableRole(u *user.Role) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableSSOCert(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableSpouseID(id *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableTeamID(id *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetOptionalInt(i int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetParent(u *User) *UserUpdateOne
- func (uuo *UserUpdateOne) SetParentID(id string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPassword(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPhone(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetRole(u user.Role) *UserUpdateOne
- func (uuo *UserUpdateOne) SetSSOCert(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetSpouse(u *User) *UserUpdateOne
- func (uuo *UserUpdateOne) SetSpouseID(id string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetTeam(p *Pet) *UserUpdateOne
- func (uuo *UserUpdateOne) SetTeamID(id string) *UserUpdateOne
- 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. TypeCard = "Card" TypeComment = "Comment" TypeFieldType = "FieldType" TypeFile = "File" TypeFileType = "FileType" TypeGoods = "Goods" TypeGroup = "Group" TypeGroupInfo = "GroupInfo" TypeItem = "Item" TypeNode = "Node" TypePet = "Pet" TypeSpec = "Spec" TypeTask = "Task" TypeUser = "User" )
const DefaultCountLabel = "count"
DefaultCountLabel is the default label name for the Count aggregation function. It should be used as the struct-tag for decoding, or a map key for interaction with the returned response. In order to "count" 2 or more fields and avoid conflicting, use the `ent.As(ent.Count(field), "custom_name")` function with custom name in order to override it.
const DefaultMaxLabel = "max"
DefaultMaxLabel is the default label name for the Max aggregation function. It should be used as the struct-tag for decoding, or a map key for interaction with the returned response. In order to "max" 2 or more fields and avoid conflicting, use the `ent.As(ent.Max(field), "custom_name")` function with custom name in order to override it.
const DefaultMeanLabel = "mean"
DefaultMeanLabel is the default label name for the Mean aggregation function. It should be used as the struct-tag for decoding, or a map key for interaction with the returned response. In order to "mean" 2 or more fields and avoid conflicting, use the `ent.As(ent.Mean(field), "custom_name")` function with custom name in order to override it.
const DefaultMinLabel = "min"
DefaultMinLabel is the default label name for the Min aggregation function. It should be used as the struct-tag for decoding, or a map key for interaction with the returned response. In order to "min" 2 or more fields and avoid conflicting, use the `ent.As(ent.Min(field), "custom_name")` function with custom name in order to override it.
const DefaultSumLabel = "sum"
DefaultSumLabel is the default label name for the Sum aggregation function. It should be used as the struct-tag for decoding, or a map key for interaction with the returned response. In order to "sum" 2 or more fields and avoid conflicting, use the `ent.As(ent.Sum(field), "custom_name")` function with custom name in order to override it.
Variables ¶
This section 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 validaton error.
func NewContext ¶
NewContext returns a new context with the given Client attached.
Types ¶
type AggregateFunc ¶
AggregateFunc applies an aggregation step on the group-by traversal/selector. It gets two labels as parameters. The first used in the `As` step for the predicate, and the second is an optional name for the next predicates (or for later usage).
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 Card ¶
type Card struct { // ID of the ent. ID string `json:"-"` // CreateTime holds the value of the "create_time" field. CreateTime time.Time `json:"create_time,omitempty"` // UpdateTime holds the value of the "update_time" field. UpdateTime time.Time `json:"update_time,omitempty"` // Number holds the value of the "number" field. Number string `json:"-"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the CardQuery when eager-loading is set. Edges CardEdges `json:"card_edges" mashraki:"edges"` // StaticField defined by templates. StaticField string `json:"boring,omitempty"` // contains filtered or unexported fields }
Card is the model entity for the Card schema.
func (*Card) FromResponse ¶
FromResponse scans the gremlin response data into Card.
func (*Card) QueryOwner ¶
QueryOwner queries the owner edge of the Card.
func (*Card) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Card) Update ¶
func (c *Card) Update() *CardUpdateOne
Update returns a builder for updating this Card. Note that, you need to call Card.Unwrap() before calling this method, if this Card was returned from a transaction, and the transaction was committed or rolled back.
type CardClient ¶
type CardClient struct {
// contains filtered or unexported fields
}
CardClient is a client for the Card schema.
func NewCardClient ¶
func NewCardClient(c config) *CardClient
NewCardClient returns a client for the Card from the given config.
func (*CardClient) Create ¶
func (c *CardClient) Create() *CardCreate
Create returns a create builder for Card.
func (*CardClient) CreateBulk ¶
func (c *CardClient) CreateBulk(builders ...*CardCreate) *CardCreateBulk
BulkCreate returns a builder for creating a bulk of Card entities.
func (*CardClient) Delete ¶
func (c *CardClient) Delete() *CardDelete
Delete returns a delete builder for Card.
func (*CardClient) DeleteOne ¶
func (c *CardClient) DeleteOne(ca *Card) *CardDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*CardClient) DeleteOneID ¶
func (c *CardClient) DeleteOneID(id string) *CardDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*CardClient) GetX ¶
func (c *CardClient) GetX(ctx context.Context, id string) *Card
GetX is like Get, but panics if an error occurs.
func (*CardClient) Query ¶
func (c *CardClient) Query() *CardQuery
Query returns a query builder for Card.
func (*CardClient) QueryOwner ¶
func (c *CardClient) QueryOwner(ca *Card) *UserQuery
QueryOwner queries the owner edge of a Card.
func (*CardClient) QuerySpec ¶
func (c *CardClient) QuerySpec(ca *Card) *SpecQuery
QuerySpec queries the spec edge of a Card.
func (*CardClient) Update ¶
func (c *CardClient) Update() *CardUpdate
Update returns an update builder for Card.
func (*CardClient) UpdateOne ¶
func (c *CardClient) UpdateOne(ca *Card) *CardUpdateOne
UpdateOne returns an update builder for the given entity.
func (*CardClient) UpdateOneID ¶
func (c *CardClient) UpdateOneID(id string) *CardUpdateOne
UpdateOneID returns an update builder for the given id.
func (*CardClient) Use ¶
func (c *CardClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `card.Hooks(f(g(h())))`.
type CardCreate ¶
type CardCreate struct {
// contains filtered or unexported fields
}
CardCreate is the builder for creating a Card entity.
func (*CardCreate) AddSpec ¶
func (cc *CardCreate) AddSpec(s ...*Spec) *CardCreate
AddSpec adds the spec edges to Spec.
func (*CardCreate) AddSpecIDs ¶
func (cc *CardCreate) AddSpecIDs(ids ...string) *CardCreate
AddSpecIDs adds the spec edge to Spec by ids.
func (*CardCreate) Mutation ¶
func (cc *CardCreate) Mutation() *CardMutation
Mutation returns the CardMutation object of the builder.
func (*CardCreate) Save ¶
func (cc *CardCreate) Save(ctx context.Context) (*Card, error)
Save creates the Card in the database.
func (*CardCreate) SaveX ¶
func (cc *CardCreate) SaveX(ctx context.Context) *Card
SaveX calls Save and panics if Save returns an error.
func (*CardCreate) SetCreateTime ¶
func (cc *CardCreate) SetCreateTime(t time.Time) *CardCreate
SetCreateTime sets the create_time field.
func (*CardCreate) SetName ¶
func (cc *CardCreate) SetName(s string) *CardCreate
SetName sets the name field.
func (*CardCreate) SetNillableCreateTime ¶
func (cc *CardCreate) SetNillableCreateTime(t *time.Time) *CardCreate
SetNillableCreateTime sets the create_time field if the given value is not nil.
func (*CardCreate) SetNillableName ¶
func (cc *CardCreate) SetNillableName(s *string) *CardCreate
SetNillableName sets the name field if the given value is not nil.
func (*CardCreate) SetNillableOwnerID ¶
func (cc *CardCreate) SetNillableOwnerID(id *string) *CardCreate
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*CardCreate) SetNillableUpdateTime ¶
func (cc *CardCreate) SetNillableUpdateTime(t *time.Time) *CardCreate
SetNillableUpdateTime sets the update_time field if the given value is not nil.
func (*CardCreate) SetNumber ¶
func (cc *CardCreate) SetNumber(s string) *CardCreate
SetNumber sets the number field.
func (*CardCreate) SetOwner ¶
func (cc *CardCreate) SetOwner(u *User) *CardCreate
SetOwner sets the owner edge to User.
func (*CardCreate) SetOwnerID ¶
func (cc *CardCreate) SetOwnerID(id string) *CardCreate
SetOwnerID sets the owner edge to User by id.
func (*CardCreate) SetUpdateTime ¶
func (cc *CardCreate) SetUpdateTime(t time.Time) *CardCreate
SetUpdateTime sets the update_time field.
type CardCreateBulk ¶
type CardCreateBulk struct {
// contains filtered or unexported fields
}
CardCreateBulk is the builder for creating a bulk of Card entities.
type CardDelete ¶
type CardDelete struct {
// contains filtered or unexported fields
}
CardDelete is the builder for deleting a Card entity.
func (*CardDelete) Exec ¶
func (cd *CardDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*CardDelete) ExecX ¶
func (cd *CardDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*CardDelete) Where ¶
func (cd *CardDelete) Where(ps ...predicate.Card) *CardDelete
Where adds a new predicate to the delete builder.
type CardDeleteOne ¶
type CardDeleteOne struct {
// contains filtered or unexported fields
}
CardDeleteOne is the builder for deleting a single Card entity.
func (*CardDeleteOne) Exec ¶
func (cdo *CardDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*CardDeleteOne) ExecX ¶
func (cdo *CardDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type CardEdges ¶
type CardEdges struct { // Owner holds the value of the owner edge. Owner *User // Spec holds the value of the spec edge. Spec []*Spec // contains filtered or unexported fields }
CardEdges holds the relations/edges for other nodes in the graph.
func (CardEdges) OwnerOrErr ¶
OwnerOrErr returns the Owner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type CardExtension ¶
CardExtension is a type for holding the extension information defined in the schema.
type CardGroupBy ¶
type CardGroupBy struct {
// contains filtered or unexported fields
}
CardGroupBy is the builder for group-by Card entities.
func (*CardGroupBy) Aggregate ¶
func (cgb *CardGroupBy) Aggregate(fns ...AggregateFunc) *CardGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*CardGroupBy) Bool ¶
func (cgb *CardGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) BoolX ¶
func (cgb *CardGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*CardGroupBy) Bools ¶
func (cgb *CardGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) BoolsX ¶
func (cgb *CardGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*CardGroupBy) Float64 ¶
func (cgb *CardGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) Float64X ¶
func (cgb *CardGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*CardGroupBy) Float64s ¶
func (cgb *CardGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) Float64sX ¶
func (cgb *CardGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*CardGroupBy) Int ¶
func (cgb *CardGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) IntX ¶
func (cgb *CardGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*CardGroupBy) Ints ¶
func (cgb *CardGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) IntsX ¶
func (cgb *CardGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*CardGroupBy) Scan ¶
func (cgb *CardGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*CardGroupBy) ScanX ¶
func (cgb *CardGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*CardGroupBy) String ¶
func (cgb *CardGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*CardGroupBy) StringX ¶
func (cgb *CardGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type CardMutation ¶
type CardMutation struct {
// contains filtered or unexported fields
}
CardMutation represents an operation that mutate the Cards nodes in the graph.
func (*CardMutation) AddField ¶
func (m *CardMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*CardMutation) AddSpecIDs ¶
func (m *CardMutation) AddSpecIDs(ids ...string)
AddSpecIDs adds the spec edge to Spec by ids.
func (*CardMutation) AddedEdges ¶
func (m *CardMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*CardMutation) AddedField ¶
func (m *CardMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*CardMutation) AddedFields ¶
func (m *CardMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*CardMutation) AddedIDs ¶
func (m *CardMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*CardMutation) ClearEdge ¶
func (m *CardMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*CardMutation) ClearField ¶
func (m *CardMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*CardMutation) ClearName ¶
func (m *CardMutation) ClearName()
ClearName clears the value of name.
func (*CardMutation) ClearOwner ¶
func (m *CardMutation) ClearOwner()
ClearOwner clears the owner edge to User.
func (*CardMutation) ClearSpec ¶ added in v0.4.3
func (m *CardMutation) ClearSpec()
ClearSpec clears the spec edge to Spec.
func (*CardMutation) ClearedEdges ¶
func (m *CardMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*CardMutation) ClearedFields ¶
func (m *CardMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (CardMutation) Client ¶
func (m CardMutation) 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 (*CardMutation) CreateTime ¶
func (m *CardMutation) CreateTime() (r time.Time, exists bool)
CreateTime returns the create_time value in the mutation.
func (*CardMutation) EdgeCleared ¶
func (m *CardMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*CardMutation) Field ¶
func (m *CardMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*CardMutation) FieldCleared ¶
func (m *CardMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*CardMutation) Fields ¶
func (m *CardMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*CardMutation) ID ¶
func (m *CardMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*CardMutation) Name ¶
func (m *CardMutation) Name() (r string, exists bool)
Name returns the name value in the mutation.
func (*CardMutation) NameCleared ¶
func (m *CardMutation) NameCleared() bool
NameCleared returns if the field name was cleared in this mutation.
func (*CardMutation) Number ¶
func (m *CardMutation) Number() (r string, exists bool)
Number returns the number value in the mutation.
func (*CardMutation) OldCreateTime ¶
OldCreateTime returns the old create_time value of the Card. If the Card 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 database query fails.
func (*CardMutation) 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 was failed.
func (*CardMutation) OldName ¶
func (m *CardMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old name value of the Card. If the Card 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 database query fails.
func (*CardMutation) OldNumber ¶
func (m *CardMutation) OldNumber(ctx context.Context) (v string, err error)
OldNumber returns the old number value of the Card. If the Card 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 database query fails.
func (*CardMutation) OldUpdateTime ¶
OldUpdateTime returns the old update_time value of the Card. If the Card 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 database query fails.
func (*CardMutation) OwnerCleared ¶
func (m *CardMutation) OwnerCleared() bool
OwnerCleared returns if the edge owner was cleared.
func (*CardMutation) OwnerID ¶
func (m *CardMutation) OwnerID() (id string, exists bool)
OwnerID returns the owner id in the mutation.
func (*CardMutation) OwnerIDs ¶
func (m *CardMutation) OwnerIDs() (ids []string)
OwnerIDs returns the owner 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 (*CardMutation) RemoveSpecIDs ¶
func (m *CardMutation) RemoveSpecIDs(ids ...string)
RemoveSpecIDs removes the spec edge to Spec by ids.
func (*CardMutation) RemovedEdges ¶
func (m *CardMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*CardMutation) RemovedIDs ¶
func (m *CardMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*CardMutation) RemovedSpecIDs ¶
func (m *CardMutation) RemovedSpecIDs() (ids []string)
RemovedSpec returns the removed ids of spec.
func (*CardMutation) ResetCreateTime ¶
func (m *CardMutation) ResetCreateTime()
ResetCreateTime reset all changes of the "create_time" field.
func (*CardMutation) ResetEdge ¶
func (m *CardMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*CardMutation) ResetField ¶
func (m *CardMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*CardMutation) ResetName ¶
func (m *CardMutation) ResetName()
ResetName reset all changes of the "name" field.
func (*CardMutation) ResetNumber ¶
func (m *CardMutation) ResetNumber()
ResetNumber reset all changes of the "number" field.
func (*CardMutation) ResetOwner ¶
func (m *CardMutation) ResetOwner()
ResetOwner reset all changes of the "owner" edge.
func (*CardMutation) ResetSpec ¶
func (m *CardMutation) ResetSpec()
ResetSpec reset all changes of the "spec" edge.
func (*CardMutation) ResetUpdateTime ¶
func (m *CardMutation) ResetUpdateTime()
ResetUpdateTime reset all changes of the "update_time" field.
func (*CardMutation) SetCreateTime ¶
func (m *CardMutation) SetCreateTime(t time.Time)
SetCreateTime sets the create_time field.
func (*CardMutation) SetField ¶
func (m *CardMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*CardMutation) SetName ¶
func (m *CardMutation) SetName(s string)
SetName sets the name field.
func (*CardMutation) SetNumber ¶
func (m *CardMutation) SetNumber(s string)
SetNumber sets the number field.
func (*CardMutation) SetOwnerID ¶
func (m *CardMutation) SetOwnerID(id string)
SetOwnerID sets the owner edge to User by id.
func (*CardMutation) SetUpdateTime ¶
func (m *CardMutation) SetUpdateTime(t time.Time)
SetUpdateTime sets the update_time field.
func (*CardMutation) SpecCleared ¶ added in v0.4.3
func (m *CardMutation) SpecCleared() bool
SpecCleared returns if the edge spec was cleared.
func (*CardMutation) SpecIDs ¶
func (m *CardMutation) SpecIDs() (ids []string)
SpecIDs returns the spec ids in the mutation.
func (CardMutation) Tx ¶
func (m CardMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*CardMutation) Type ¶
func (m *CardMutation) Type() string
Type returns the node type of this mutation (Card).
func (*CardMutation) UpdateTime ¶
func (m *CardMutation) UpdateTime() (r time.Time, exists bool)
UpdateTime returns the update_time value in the mutation.
type CardQuery ¶
type CardQuery struct {
// contains filtered or unexported fields
}
CardQuery is the builder for querying Card entities.
func (*CardQuery) Clone ¶
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*CardQuery) First ¶
First returns the first Card entity in the query. Returns *NotFoundError when no card was found.
func (*CardQuery) FirstID ¶
FirstID returns the first Card id in the query. Returns *NotFoundError when no id was found.
func (*CardQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*CardQuery) GroupBy ¶
func (cq *CardQuery) GroupBy(field string, fields ...string) *CardGroupBy
GroupBy 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 { CreateTime time.Time `json:"create_time,omitempty"` Count int `json:"count,omitempty"` } client.Card.Query(). GroupBy(card.FieldCreateTime). Aggregate(ent.Count()). Scan(ctx, &v)
func (*CardQuery) Only ¶
Only returns the only Card entity in the query, returns an error if not exactly one entity was returned.
func (*CardQuery) OnlyID ¶
OnlyID returns the only Card id in the query, returns an error if not exactly one id was returned.
func (*CardQuery) QueryOwner ¶
QueryOwner chains the current query on the owner edge.
func (*CardQuery) Select ¶
func (cq *CardQuery) Select(field string, fields ...string) *CardSelect
Select one or more fields from the given query.
Example:
var v []struct { CreateTime time.Time `json:"create_time,omitempty"` } client.Card.Query(). Select(card.FieldCreateTime). Scan(ctx, &v)
type CardSelect ¶
type CardSelect struct {
// contains filtered or unexported fields
}
CardSelect is the builder for select fields of Card entities.
func (*CardSelect) Bool ¶
func (cs *CardSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*CardSelect) BoolX ¶
func (cs *CardSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*CardSelect) Bools ¶
func (cs *CardSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*CardSelect) BoolsX ¶
func (cs *CardSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*CardSelect) Float64 ¶
func (cs *CardSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*CardSelect) Float64X ¶
func (cs *CardSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*CardSelect) Float64s ¶
func (cs *CardSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*CardSelect) Float64sX ¶
func (cs *CardSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*CardSelect) Int ¶
func (cs *CardSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*CardSelect) IntX ¶
func (cs *CardSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*CardSelect) Ints ¶
func (cs *CardSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*CardSelect) IntsX ¶
func (cs *CardSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*CardSelect) Scan ¶
func (cs *CardSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*CardSelect) ScanX ¶
func (cs *CardSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*CardSelect) String ¶
func (cs *CardSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*CardSelect) StringX ¶
func (cs *CardSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type CardUpdate ¶
type CardUpdate struct {
// contains filtered or unexported fields
}
CardUpdate is the builder for updating Card entities.
func (*CardUpdate) AddSpec ¶
func (cu *CardUpdate) AddSpec(s ...*Spec) *CardUpdate
AddSpec adds the spec edges to Spec.
func (*CardUpdate) AddSpecIDs ¶
func (cu *CardUpdate) AddSpecIDs(ids ...string) *CardUpdate
AddSpecIDs adds the spec edge to Spec by ids.
func (*CardUpdate) ClearName ¶
func (cu *CardUpdate) ClearName() *CardUpdate
ClearName clears the value of name.
func (*CardUpdate) ClearOwner ¶
func (cu *CardUpdate) ClearOwner() *CardUpdate
ClearOwner clears the "owner" edge to type User.
func (*CardUpdate) ClearSpec ¶ added in v0.4.3
func (cu *CardUpdate) ClearSpec() *CardUpdate
ClearSpec clears all "spec" edges to type Spec.
func (*CardUpdate) Exec ¶
func (cu *CardUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*CardUpdate) ExecX ¶
func (cu *CardUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*CardUpdate) Mutation ¶
func (cu *CardUpdate) Mutation() *CardMutation
Mutation returns the CardMutation object of the builder.
func (*CardUpdate) RemoveSpec ¶
func (cu *CardUpdate) RemoveSpec(s ...*Spec) *CardUpdate
RemoveSpec removes spec edges to Spec.
func (*CardUpdate) RemoveSpecIDs ¶
func (cu *CardUpdate) RemoveSpecIDs(ids ...string) *CardUpdate
RemoveSpecIDs removes the spec edge to Spec by ids.
func (*CardUpdate) Save ¶
func (cu *CardUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*CardUpdate) SaveX ¶
func (cu *CardUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*CardUpdate) SetName ¶
func (cu *CardUpdate) SetName(s string) *CardUpdate
SetName sets the name field.
func (*CardUpdate) SetNillableName ¶
func (cu *CardUpdate) SetNillableName(s *string) *CardUpdate
SetNillableName sets the name field if the given value is not nil.
func (*CardUpdate) SetNillableOwnerID ¶
func (cu *CardUpdate) SetNillableOwnerID(id *string) *CardUpdate
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*CardUpdate) SetOwner ¶
func (cu *CardUpdate) SetOwner(u *User) *CardUpdate
SetOwner sets the owner edge to User.
func (*CardUpdate) SetOwnerID ¶
func (cu *CardUpdate) SetOwnerID(id string) *CardUpdate
SetOwnerID sets the owner edge to User by id.
func (*CardUpdate) Where ¶
func (cu *CardUpdate) Where(ps ...predicate.Card) *CardUpdate
Where adds a new predicate for the builder.
type CardUpdateOne ¶
type CardUpdateOne struct {
// contains filtered or unexported fields
}
CardUpdateOne is the builder for updating a single Card entity.
func (*CardUpdateOne) AddSpec ¶
func (cuo *CardUpdateOne) AddSpec(s ...*Spec) *CardUpdateOne
AddSpec adds the spec edges to Spec.
func (*CardUpdateOne) AddSpecIDs ¶
func (cuo *CardUpdateOne) AddSpecIDs(ids ...string) *CardUpdateOne
AddSpecIDs adds the spec edge to Spec by ids.
func (*CardUpdateOne) ClearName ¶
func (cuo *CardUpdateOne) ClearName() *CardUpdateOne
ClearName clears the value of name.
func (*CardUpdateOne) ClearOwner ¶
func (cuo *CardUpdateOne) ClearOwner() *CardUpdateOne
ClearOwner clears the "owner" edge to type User.
func (*CardUpdateOne) ClearSpec ¶ added in v0.4.3
func (cuo *CardUpdateOne) ClearSpec() *CardUpdateOne
ClearSpec clears all "spec" edges to type Spec.
func (*CardUpdateOne) Exec ¶
func (cuo *CardUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*CardUpdateOne) ExecX ¶
func (cuo *CardUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*CardUpdateOne) Mutation ¶
func (cuo *CardUpdateOne) Mutation() *CardMutation
Mutation returns the CardMutation object of the builder.
func (*CardUpdateOne) RemoveSpec ¶
func (cuo *CardUpdateOne) RemoveSpec(s ...*Spec) *CardUpdateOne
RemoveSpec removes spec edges to Spec.
func (*CardUpdateOne) RemoveSpecIDs ¶
func (cuo *CardUpdateOne) RemoveSpecIDs(ids ...string) *CardUpdateOne
RemoveSpecIDs removes the spec edge to Spec by ids.
func (*CardUpdateOne) Save ¶
func (cuo *CardUpdateOne) Save(ctx context.Context) (*Card, error)
Save executes the query and returns the updated entity.
func (*CardUpdateOne) SaveX ¶
func (cuo *CardUpdateOne) SaveX(ctx context.Context) *Card
SaveX is like Save, but panics if an error occurs.
func (*CardUpdateOne) SetName ¶
func (cuo *CardUpdateOne) SetName(s string) *CardUpdateOne
SetName sets the name field.
func (*CardUpdateOne) SetNillableName ¶
func (cuo *CardUpdateOne) SetNillableName(s *string) *CardUpdateOne
SetNillableName sets the name field if the given value is not nil.
func (*CardUpdateOne) SetNillableOwnerID ¶
func (cuo *CardUpdateOne) SetNillableOwnerID(id *string) *CardUpdateOne
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*CardUpdateOne) SetOwner ¶
func (cuo *CardUpdateOne) SetOwner(u *User) *CardUpdateOne
SetOwner sets the owner edge to User.
func (*CardUpdateOne) SetOwnerID ¶
func (cuo *CardUpdateOne) SetOwnerID(id string) *CardUpdateOne
SetOwnerID sets the owner edge to User by id.
type Client ¶
type Client struct { // Card is the client for interacting with the Card builders. Card *CardClient // Comment is the client for interacting with the Comment builders. Comment *CommentClient // FieldType is the client for interacting with the FieldType builders. FieldType *FieldTypeClient // File is the client for interacting with the File builders. File *FileClient // FileType is the client for interacting with the FileType builders. FileType *FileTypeClient // Goods is the client for interacting with the Goods builders. Goods *GoodsClient // Group is the client for interacting with the Group builders. Group *GroupClient // GroupInfo is the client for interacting with the GroupInfo builders. GroupInfo *GroupInfoClient // Item is the client for interacting with the Item builders. Item *ItemClient // Node is the client for interacting with the Node builders. Node *NodeClient // Pet is the client for interacting with the Pet builders. Pet *PetClient // Spec is the client for interacting with the Spec builders. Spec *SpecClient // Task is the client for interacting with the Task builders. Task *TaskClient // User is the client for interacting with the User builders. User *UserClient TemplateField struct{} // contains filtered or unexported fields }
Client is the client that holds all ent builders.
func FromContext ¶
FromContext returns the Client stored in 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(). Card. Query(). Count(ctx)
type Comment ¶
type Comment struct { // ID of the ent. ID string `json:"id,omitempty"` // UniqueInt holds the value of the "unique_int" field. UniqueInt int `json:"unique_int,omitempty"` // UniqueFloat holds the value of the "unique_float" field. UniqueFloat float64 `json:"unique_float,omitempty"` // NillableInt holds the value of the "nillable_int" field. NillableInt *int `json:"nillable_int,omitempty"` // contains filtered or unexported fields }
Comment is the model entity for the Comment schema.
func (*Comment) FromResponse ¶
FromResponse scans the gremlin response data into Comment.
func (*Comment) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next 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 create builder for Comment.
func (*CommentClient) CreateBulk ¶
func (c *CommentClient) CreateBulk(builders ...*CommentCreate) *CommentCreateBulk
BulkCreate 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 delete builder for the given entity.
func (*CommentClient) DeleteOneID ¶
func (c *CommentClient) DeleteOneID(id string) *CommentDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*CommentClient) GetX ¶
func (c *CommentClient) GetX(ctx context.Context, id string) *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) Query ¶
func (c *CommentClient) Query() *CommentQuery
Query returns a query builder for 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 string) *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 CommentCreate ¶
type CommentCreate struct {
// contains filtered or unexported fields
}
CommentCreate is the builder for creating a Comment entity.
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) SetNillableInt ¶
func (cc *CommentCreate) SetNillableInt(i int) *CommentCreate
SetNillableInt sets the nillable_int field.
func (*CommentCreate) SetNillableNillableInt ¶
func (cc *CommentCreate) SetNillableNillableInt(i *int) *CommentCreate
SetNillableNillableInt sets the nillable_int field if the given value is not nil.
func (*CommentCreate) SetUniqueFloat ¶
func (cc *CommentCreate) SetUniqueFloat(f float64) *CommentCreate
SetUniqueFloat sets the unique_float field.
func (*CommentCreate) SetUniqueInt ¶
func (cc *CommentCreate) SetUniqueInt(i int) *CommentCreate
SetUniqueInt sets the unique_int field.
type CommentCreateBulk ¶
type CommentCreateBulk struct {
// contains filtered or unexported fields
}
CommentCreateBulk is the builder for creating a bulk of Comment entities.
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 adds a new predicate to the delete 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 CommentGroupBy ¶
type CommentGroupBy struct {
// contains filtered or unexported fields
}
CommentGroupBy is the builder for group-by 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 ¶
func (cgb *CommentGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) BoolX ¶
func (cgb *CommentGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*CommentGroupBy) Bools ¶
func (cgb *CommentGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) BoolsX ¶
func (cgb *CommentGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*CommentGroupBy) Float64 ¶
func (cgb *CommentGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) Float64X ¶
func (cgb *CommentGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*CommentGroupBy) Float64s ¶
func (cgb *CommentGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) Float64sX ¶
func (cgb *CommentGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*CommentGroupBy) Int ¶
func (cgb *CommentGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) IntX ¶
func (cgb *CommentGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*CommentGroupBy) Ints ¶
func (cgb *CommentGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) IntsX ¶
func (cgb *CommentGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*CommentGroupBy) Scan ¶
func (cgb *CommentGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*CommentGroupBy) ScanX ¶
func (cgb *CommentGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*CommentGroupBy) String ¶
func (cgb *CommentGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*CommentGroupBy) StringX ¶
func (cgb *CommentGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type CommentMutation ¶
type CommentMutation struct {
// contains filtered or unexported fields
}
CommentMutation represents an operation that mutate the Comments nodes in the graph.
func (*CommentMutation) AddField ¶
func (m *CommentMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*CommentMutation) AddNillableInt ¶
func (m *CommentMutation) AddNillableInt(i int)
AddNillableInt adds i to nillable_int.
func (*CommentMutation) AddUniqueFloat ¶
func (m *CommentMutation) AddUniqueFloat(f float64)
AddUniqueFloat adds f to unique_float.
func (*CommentMutation) AddUniqueInt ¶
func (m *CommentMutation) AddUniqueInt(i int)
AddUniqueInt adds i to unique_int.
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 in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*CommentMutation) AddedFields ¶
func (m *CommentMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or 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.
func (*CommentMutation) AddedNillableInt ¶
func (m *CommentMutation) AddedNillableInt() (r int, exists bool)
AddedNillableInt returns the value that was added to the nillable_int field in this mutation.
func (*CommentMutation) AddedUniqueFloat ¶
func (m *CommentMutation) AddedUniqueFloat() (r float64, exists bool)
AddedUniqueFloat returns the value that was added to the unique_float field in this mutation.
func (*CommentMutation) AddedUniqueInt ¶
func (m *CommentMutation) AddedUniqueInt() (r int, exists bool)
AddedUniqueInt returns the value that was added to the unique_int field in this mutation.
func (*CommentMutation) ClearEdge ¶
func (m *CommentMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*CommentMutation) ClearField ¶
func (m *CommentMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*CommentMutation) ClearNillableInt ¶
func (m *CommentMutation) ClearNillableInt()
ClearNillableInt clears the value of nillable_int.
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 indicates if this edge was cleared in this 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 value indicates that this field was not set, or was not define in the schema.
func (*CommentMutation) FieldCleared ¶
func (m *CommentMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field 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 in/decremented, call AddedFields().
func (*CommentMutation) ID ¶
func (m *CommentMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*CommentMutation) NillableInt ¶
func (m *CommentMutation) NillableInt() (r int, exists bool)
NillableInt returns the nillable_int value in the mutation.
func (*CommentMutation) NillableIntCleared ¶
func (m *CommentMutation) NillableIntCleared() bool
NillableIntCleared returns if the field nillable_int was cleared in this 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 was failed.
func (*CommentMutation) OldNillableInt ¶
func (m *CommentMutation) OldNillableInt(ctx context.Context) (v *int, err error)
OldNillableInt returns the old nillable_int value of the Comment. 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 database query fails.
func (*CommentMutation) OldUniqueFloat ¶
func (m *CommentMutation) OldUniqueFloat(ctx context.Context) (v float64, err error)
OldUniqueFloat returns the old unique_float value of the Comment. 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 database query fails.
func (*CommentMutation) OldUniqueInt ¶
func (m *CommentMutation) OldUniqueInt(ctx context.Context) (v int, err error)
OldUniqueInt returns the old unique_int value of the Comment. 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 database query fails.
func (*CommentMutation) RemovedEdges ¶
func (m *CommentMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*CommentMutation) RemovedIDs ¶
func (m *CommentMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*CommentMutation) ResetEdge ¶
func (m *CommentMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*CommentMutation) ResetField ¶
func (m *CommentMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*CommentMutation) ResetNillableInt ¶
func (m *CommentMutation) ResetNillableInt()
ResetNillableInt reset all changes of the "nillable_int" field.
func (*CommentMutation) ResetUniqueFloat ¶
func (m *CommentMutation) ResetUniqueFloat()
ResetUniqueFloat reset all changes of the "unique_float" field.
func (*CommentMutation) ResetUniqueInt ¶
func (m *CommentMutation) ResetUniqueInt()
ResetUniqueInt reset all changes of the "unique_int" field.
func (*CommentMutation) SetField ¶
func (m *CommentMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*CommentMutation) SetNillableInt ¶
func (m *CommentMutation) SetNillableInt(i int)
SetNillableInt sets the nillable_int field.
func (*CommentMutation) SetUniqueFloat ¶
func (m *CommentMutation) SetUniqueFloat(f float64)
SetUniqueFloat sets the unique_float field.
func (*CommentMutation) SetUniqueInt ¶
func (m *CommentMutation) SetUniqueInt(i int)
SetUniqueInt sets the unique_int field.
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) UniqueFloat ¶
func (m *CommentMutation) UniqueFloat() (r float64, exists bool)
UniqueFloat returns the unique_float value in the mutation.
func (*CommentMutation) UniqueInt ¶
func (m *CommentMutation) UniqueInt() (r int, exists bool)
UniqueInt returns the unique_int value in the mutation.
type CommentQuery ¶
type CommentQuery struct {
// contains filtered or unexported fields
}
CommentQuery is the builder for querying Comment entities.
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 query 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) 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 in the query. Returns *NotFoundError when no comment was found.
func (*CommentQuery) FirstID ¶
func (cq *CommentQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first Comment id in the query. Returns *NotFoundError when no id was found.
func (*CommentQuery) FirstIDX ¶ added in v0.5.0
func (cq *CommentQuery) FirstIDX(ctx context.Context) string
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 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 { UniqueInt int `json:"unique_int,omitempty"` Count int `json:"count,omitempty"` } client.Comment.Query(). GroupBy(comment.FieldUniqueInt). Aggregate(ent.Count()). Scan(ctx, &v)
func (*CommentQuery) IDs ¶
func (cq *CommentQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of Comment ids.
func (*CommentQuery) IDsX ¶
func (cq *CommentQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*CommentQuery) Limit ¶
func (cq *CommentQuery) Limit(limit int) *CommentQuery
Limit adds a limit step to the query.
func (*CommentQuery) Offset ¶
func (cq *CommentQuery) Offset(offset int) *CommentQuery
Offset adds an offset step to the query.
func (*CommentQuery) Only ¶
func (cq *CommentQuery) Only(ctx context.Context) (*Comment, error)
Only returns the only Comment entity in the query, returns an error if not exactly one entity was returned.
func (*CommentQuery) OnlyID ¶
func (cq *CommentQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID returns the only Comment id in the query, returns an error if not exactly one id was returned.
func (*CommentQuery) OnlyIDX ¶
func (cq *CommentQuery) OnlyIDX(ctx context.Context) string
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 adds an order step to the query.
func (*CommentQuery) Select ¶
func (cq *CommentQuery) Select(field string, fields ...string) *CommentSelect
Select one or more fields from the given query.
Example:
var v []struct { UniqueInt int `json:"unique_int,omitempty"` } client.Comment.Query(). Select(comment.FieldUniqueInt). Scan(ctx, &v)
func (*CommentQuery) Where ¶
func (cq *CommentQuery) Where(ps ...predicate.Comment) *CommentQuery
Where adds a new predicate for the builder.
type CommentSelect ¶
type CommentSelect struct {
// contains filtered or unexported fields
}
CommentSelect is the builder for select fields of Comment entities.
func (*CommentSelect) Bool ¶
func (cs *CommentSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*CommentSelect) BoolX ¶
func (cs *CommentSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*CommentSelect) Bools ¶
func (cs *CommentSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*CommentSelect) BoolsX ¶
func (cs *CommentSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*CommentSelect) Float64 ¶
func (cs *CommentSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*CommentSelect) Float64X ¶
func (cs *CommentSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*CommentSelect) Float64s ¶
func (cs *CommentSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*CommentSelect) Float64sX ¶
func (cs *CommentSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*CommentSelect) Int ¶
func (cs *CommentSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*CommentSelect) IntX ¶
func (cs *CommentSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*CommentSelect) Ints ¶
func (cs *CommentSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*CommentSelect) IntsX ¶
func (cs *CommentSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*CommentSelect) Scan ¶
func (cs *CommentSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*CommentSelect) ScanX ¶
func (cs *CommentSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*CommentSelect) String ¶
func (cs *CommentSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*CommentSelect) StringX ¶
func (cs *CommentSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type CommentUpdate ¶
type CommentUpdate struct {
// contains filtered or unexported fields
}
CommentUpdate is the builder for updating Comment entities.
func (*CommentUpdate) AddNillableInt ¶
func (cu *CommentUpdate) AddNillableInt(i int) *CommentUpdate
AddNillableInt adds i to nillable_int.
func (*CommentUpdate) AddUniqueFloat ¶
func (cu *CommentUpdate) AddUniqueFloat(f float64) *CommentUpdate
AddUniqueFloat adds f to unique_float.
func (*CommentUpdate) AddUniqueInt ¶
func (cu *CommentUpdate) AddUniqueInt(i int) *CommentUpdate
AddUniqueInt adds i to unique_int.
func (*CommentUpdate) ClearNillableInt ¶
func (cu *CommentUpdate) ClearNillableInt() *CommentUpdate
ClearNillableInt clears the value of nillable_int.
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) Save ¶
func (cu *CommentUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*CommentUpdate) SaveX ¶
func (cu *CommentUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*CommentUpdate) SetNillableInt ¶
func (cu *CommentUpdate) SetNillableInt(i int) *CommentUpdate
SetNillableInt sets the nillable_int field.
func (*CommentUpdate) SetNillableNillableInt ¶
func (cu *CommentUpdate) SetNillableNillableInt(i *int) *CommentUpdate
SetNillableNillableInt sets the nillable_int field if the given value is not nil.
func (*CommentUpdate) SetUniqueFloat ¶
func (cu *CommentUpdate) SetUniqueFloat(f float64) *CommentUpdate
SetUniqueFloat sets the unique_float field.
func (*CommentUpdate) SetUniqueInt ¶
func (cu *CommentUpdate) SetUniqueInt(i int) *CommentUpdate
SetUniqueInt sets the unique_int field.
func (*CommentUpdate) Where ¶
func (cu *CommentUpdate) Where(ps ...predicate.Comment) *CommentUpdate
Where adds a new predicate for the builder.
type CommentUpdateOne ¶
type CommentUpdateOne struct {
// contains filtered or unexported fields
}
CommentUpdateOne is the builder for updating a single Comment entity.
func (*CommentUpdateOne) AddNillableInt ¶
func (cuo *CommentUpdateOne) AddNillableInt(i int) *CommentUpdateOne
AddNillableInt adds i to nillable_int.
func (*CommentUpdateOne) AddUniqueFloat ¶
func (cuo *CommentUpdateOne) AddUniqueFloat(f float64) *CommentUpdateOne
AddUniqueFloat adds f to unique_float.
func (*CommentUpdateOne) AddUniqueInt ¶
func (cuo *CommentUpdateOne) AddUniqueInt(i int) *CommentUpdateOne
AddUniqueInt adds i to unique_int.
func (*CommentUpdateOne) ClearNillableInt ¶
func (cuo *CommentUpdateOne) ClearNillableInt() *CommentUpdateOne
ClearNillableInt clears the value of nillable_int.
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) Save ¶
func (cuo *CommentUpdateOne) Save(ctx context.Context) (*Comment, error)
Save executes the query and returns the updated entity.
func (*CommentUpdateOne) SaveX ¶
func (cuo *CommentUpdateOne) SaveX(ctx context.Context) *Comment
SaveX is like Save, but panics if an error occurs.
func (*CommentUpdateOne) SetNillableInt ¶
func (cuo *CommentUpdateOne) SetNillableInt(i int) *CommentUpdateOne
SetNillableInt sets the nillable_int field.
func (*CommentUpdateOne) SetNillableNillableInt ¶
func (cuo *CommentUpdateOne) SetNillableNillableInt(i *int) *CommentUpdateOne
SetNillableNillableInt sets the nillable_int field if the given value is not nil.
func (*CommentUpdateOne) SetUniqueFloat ¶
func (cuo *CommentUpdateOne) SetUniqueFloat(f float64) *CommentUpdateOne
SetUniqueFloat sets the unique_float field.
func (*CommentUpdateOne) SetUniqueInt ¶
func (cuo *CommentUpdateOne) SetUniqueInt(i int) *CommentUpdateOne
SetUniqueInt sets the unique_int field.
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(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 NewErrUniqueEdge ¶
func NewErrUniqueEdge(label, edge, id string) *ConstraintError
NewErrUniqueEdge creates a constraint error for unique edges.
func NewErrUniqueField ¶
func NewErrUniqueField(label, field string, v interface{}) *ConstraintError
NewErrUniqueField creates a constraint error for unique fields.
func (ConstraintError) Code ¶
func (e ConstraintError) Code() (string, []interface{})
Code implements the dsl.Node interface.
func (ConstraintError) Error ¶
func (e ConstraintError) Error() string
Error implements the error interface.
func (*ConstraintError) UnmarshalGraphson ¶
func (e *ConstraintError) UnmarshalGraphson(b []byte) error
func (*ConstraintError) Unwrap ¶
func (e *ConstraintError) Unwrap() error
Unwrap implements the errors.Wrapper interface.
type FieldType ¶
type FieldType struct { // ID of the ent. ID string `json:"id,omitempty"` // Int holds the value of the "int" field. Int int `json:"int,omitempty"` // Int8 holds the value of the "int8" field. Int8 int8 `json:"int8,omitempty"` // Int16 holds the value of the "int16" field. Int16 int16 `json:"int16,omitempty"` // Int32 holds the value of the "int32" field. Int32 int32 `json:"int32,omitempty"` // Int64 holds the value of the "int64" field. Int64 int64 `json:"int64,omitempty"` // OptionalInt holds the value of the "optional_int" field. OptionalInt int `json:"optional_int,omitempty"` // OptionalInt8 holds the value of the "optional_int8" field. OptionalInt8 int8 `json:"optional_int8,omitempty"` // OptionalInt16 holds the value of the "optional_int16" field. OptionalInt16 int16 `json:"optional_int16,omitempty"` // OptionalInt32 holds the value of the "optional_int32" field. OptionalInt32 int32 `json:"optional_int32,omitempty"` // OptionalInt64 holds the value of the "optional_int64" field. OptionalInt64 int64 `json:"optional_int64,omitempty"` // NillableInt holds the value of the "nillable_int" field. NillableInt *int `json:"nillable_int,omitempty"` // NillableInt8 holds the value of the "nillable_int8" field. NillableInt8 *int8 `json:"nillable_int8,omitempty"` // NillableInt16 holds the value of the "nillable_int16" field. NillableInt16 *int16 `json:"nillable_int16,omitempty"` // NillableInt32 holds the value of the "nillable_int32" field. NillableInt32 *int32 `json:"nillable_int32,omitempty"` // NillableInt64 holds the value of the "nillable_int64" field. NillableInt64 *int64 `json:"nillable_int64,omitempty"` // ValidateOptionalInt32 holds the value of the "validate_optional_int32" field. ValidateOptionalInt32 int32 `json:"validate_optional_int32,omitempty"` // OptionalUint holds the value of the "optional_uint" field. OptionalUint uint `json:"optional_uint,omitempty"` // OptionalUint8 holds the value of the "optional_uint8" field. OptionalUint8 uint8 `json:"optional_uint8,omitempty"` // OptionalUint16 holds the value of the "optional_uint16" field. OptionalUint16 uint16 `json:"optional_uint16,omitempty"` // OptionalUint32 holds the value of the "optional_uint32" field. OptionalUint32 uint32 `json:"optional_uint32,omitempty"` // OptionalUint64 holds the value of the "optional_uint64" field. OptionalUint64 uint64 `json:"optional_uint64,omitempty"` // State holds the value of the "state" field. State fieldtype.State `json:"state,omitempty"` // OptionalFloat holds the value of the "optional_float" field. OptionalFloat float64 `json:"optional_float,omitempty"` // OptionalFloat32 holds the value of the "optional_float32" field. OptionalFloat32 float32 `json:"optional_float32,omitempty"` // Datetime holds the value of the "datetime" field. Datetime time.Time `json:"datetime,omitempty"` // Decimal holds the value of the "decimal" field. Decimal float64 `json:"decimal,omitempty"` // Dir holds the value of the "dir" field. Dir http.Dir `json:"dir,omitempty"` // Ndir holds the value of the "ndir" field. Ndir *http.Dir `json:"ndir,omitempty"` // Str holds the value of the "str" field. Str sql.NullString `json:"str,omitempty"` // NullStr holds the value of the "null_str" field. NullStr *sql.NullString `json:"null_str,omitempty"` // Link holds the value of the "link" field. Link schema.Link `json:"link,omitempty"` // NullLink holds the value of the "null_link" field. NullLink *schema.Link `json:"null_link,omitempty"` // Active holds the value of the "active" field. Active schema.Status `json:"active,omitempty"` // NullActive holds the value of the "null_active" field. NullActive *schema.Status `json:"null_active,omitempty"` // Deleted holds the value of the "deleted" field. Deleted sql.NullBool `json:"deleted,omitempty"` // DeletedAt holds the value of the "deleted_at" field. DeletedAt sql.NullTime `json:"deleted_at,omitempty"` // IP holds the value of the "ip" field. IP net.IP `json:"ip,omitempty"` // NullInt64 holds the value of the "null_int64" field. NullInt64 sql.NullInt64 `json:"null_int64,omitempty"` // SchemaInt holds the value of the "schema_int" field. SchemaInt schema.Int `json:"schema_int,omitempty"` // SchemaInt8 holds the value of the "schema_int8" field. SchemaInt8 schema.Int8 `json:"schema_int8,omitempty"` // SchemaInt64 holds the value of the "schema_int64" field. SchemaInt64 schema.Int64 `json:"schema_int64,omitempty"` // SchemaFloat holds the value of the "schema_float" field. SchemaFloat schema.Float64 `json:"schema_float,omitempty"` // SchemaFloat32 holds the value of the "schema_float32" field. SchemaFloat32 schema.Float32 `json:"schema_float32,omitempty"` // NullFloat holds the value of the "null_float" field. NullFloat sql.NullFloat64 `json:"null_float,omitempty"` // Role holds the value of the "role" field. Role role.Role `json:"role,omitempty"` // contains filtered or unexported fields }
FieldType is the model entity for the FieldType schema.
func (*FieldType) FromResponse ¶
FromResponse scans the gremlin response data into FieldType.
func (*FieldType) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*FieldType) Update ¶
func (ft *FieldType) Update() *FieldTypeUpdateOne
Update returns a builder for updating this FieldType. Note that, you need to call FieldType.Unwrap() before calling this method, if this FieldType was returned from a transaction, and the transaction was committed or rolled back.
type FieldTypeClient ¶
type FieldTypeClient struct {
// contains filtered or unexported fields
}
FieldTypeClient is a client for the FieldType schema.
func NewFieldTypeClient ¶
func NewFieldTypeClient(c config) *FieldTypeClient
NewFieldTypeClient returns a client for the FieldType from the given config.
func (*FieldTypeClient) Create ¶
func (c *FieldTypeClient) Create() *FieldTypeCreate
Create returns a create builder for FieldType.
func (*FieldTypeClient) CreateBulk ¶
func (c *FieldTypeClient) CreateBulk(builders ...*FieldTypeCreate) *FieldTypeCreateBulk
BulkCreate returns a builder for creating a bulk of FieldType entities.
func (*FieldTypeClient) Delete ¶
func (c *FieldTypeClient) Delete() *FieldTypeDelete
Delete returns a delete builder for FieldType.
func (*FieldTypeClient) DeleteOne ¶
func (c *FieldTypeClient) DeleteOne(ft *FieldType) *FieldTypeDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*FieldTypeClient) DeleteOneID ¶
func (c *FieldTypeClient) DeleteOneID(id string) *FieldTypeDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*FieldTypeClient) GetX ¶
func (c *FieldTypeClient) GetX(ctx context.Context, id string) *FieldType
GetX is like Get, but panics if an error occurs.
func (*FieldTypeClient) Hooks ¶
func (c *FieldTypeClient) Hooks() []Hook
Hooks returns the client hooks.
func (*FieldTypeClient) Query ¶
func (c *FieldTypeClient) Query() *FieldTypeQuery
Query returns a query builder for FieldType.
func (*FieldTypeClient) Update ¶
func (c *FieldTypeClient) Update() *FieldTypeUpdate
Update returns an update builder for FieldType.
func (*FieldTypeClient) UpdateOne ¶
func (c *FieldTypeClient) UpdateOne(ft *FieldType) *FieldTypeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*FieldTypeClient) UpdateOneID ¶
func (c *FieldTypeClient) UpdateOneID(id string) *FieldTypeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*FieldTypeClient) Use ¶
func (c *FieldTypeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `fieldtype.Hooks(f(g(h())))`.
type FieldTypeCreate ¶
type FieldTypeCreate struct {
// contains filtered or unexported fields
}
FieldTypeCreate is the builder for creating a FieldType entity.
func (*FieldTypeCreate) Mutation ¶
func (ftc *FieldTypeCreate) Mutation() *FieldTypeMutation
Mutation returns the FieldTypeMutation object of the builder.
func (*FieldTypeCreate) Save ¶
func (ftc *FieldTypeCreate) Save(ctx context.Context) (*FieldType, error)
Save creates the FieldType in the database.
func (*FieldTypeCreate) SaveX ¶
func (ftc *FieldTypeCreate) SaveX(ctx context.Context) *FieldType
SaveX calls Save and panics if Save returns an error.
func (*FieldTypeCreate) SetActive ¶
func (ftc *FieldTypeCreate) SetActive(s schema.Status) *FieldTypeCreate
SetActive sets the active field.
func (*FieldTypeCreate) SetDatetime ¶
func (ftc *FieldTypeCreate) SetDatetime(t time.Time) *FieldTypeCreate
SetDatetime sets the datetime field.
func (*FieldTypeCreate) SetDecimal ¶
func (ftc *FieldTypeCreate) SetDecimal(f float64) *FieldTypeCreate
SetDecimal sets the decimal field.
func (*FieldTypeCreate) SetDeleted ¶
func (ftc *FieldTypeCreate) SetDeleted(sb sql.NullBool) *FieldTypeCreate
SetDeleted sets the deleted field.
func (*FieldTypeCreate) SetDeletedAt ¶
func (ftc *FieldTypeCreate) SetDeletedAt(st sql.NullTime) *FieldTypeCreate
SetDeletedAt sets the deleted_at field.
func (*FieldTypeCreate) SetDir ¶
func (ftc *FieldTypeCreate) SetDir(h http.Dir) *FieldTypeCreate
SetDir sets the dir field.
func (*FieldTypeCreate) SetIP ¶
func (ftc *FieldTypeCreate) SetIP(n net.IP) *FieldTypeCreate
SetIP sets the ip field.
func (*FieldTypeCreate) SetInt ¶
func (ftc *FieldTypeCreate) SetInt(i int) *FieldTypeCreate
SetInt sets the int field.
func (*FieldTypeCreate) SetInt16 ¶
func (ftc *FieldTypeCreate) SetInt16(i int16) *FieldTypeCreate
SetInt16 sets the int16 field.
func (*FieldTypeCreate) SetInt32 ¶
func (ftc *FieldTypeCreate) SetInt32(i int32) *FieldTypeCreate
SetInt32 sets the int32 field.
func (*FieldTypeCreate) SetInt64 ¶
func (ftc *FieldTypeCreate) SetInt64(i int64) *FieldTypeCreate
SetInt64 sets the int64 field.
func (*FieldTypeCreate) SetInt8 ¶
func (ftc *FieldTypeCreate) SetInt8(i int8) *FieldTypeCreate
SetInt8 sets the int8 field.
func (*FieldTypeCreate) SetLink ¶
func (ftc *FieldTypeCreate) SetLink(s schema.Link) *FieldTypeCreate
SetLink sets the link field.
func (*FieldTypeCreate) SetNdir ¶
func (ftc *FieldTypeCreate) SetNdir(h http.Dir) *FieldTypeCreate
SetNdir sets the ndir field.
func (*FieldTypeCreate) SetNillableActive ¶
func (ftc *FieldTypeCreate) SetNillableActive(s *schema.Status) *FieldTypeCreate
SetNillableActive sets the active field if the given value is not nil.
func (*FieldTypeCreate) SetNillableDatetime ¶
func (ftc *FieldTypeCreate) SetNillableDatetime(t *time.Time) *FieldTypeCreate
SetNillableDatetime sets the datetime field if the given value is not nil.
func (*FieldTypeCreate) SetNillableDecimal ¶
func (ftc *FieldTypeCreate) SetNillableDecimal(f *float64) *FieldTypeCreate
SetNillableDecimal sets the decimal field if the given value is not nil.
func (*FieldTypeCreate) SetNillableDir ¶
func (ftc *FieldTypeCreate) SetNillableDir(h *http.Dir) *FieldTypeCreate
SetNillableDir sets the dir field if the given value is not nil.
func (*FieldTypeCreate) SetNillableInt ¶
func (ftc *FieldTypeCreate) SetNillableInt(i int) *FieldTypeCreate
SetNillableInt sets the nillable_int field.
func (*FieldTypeCreate) SetNillableInt16 ¶
func (ftc *FieldTypeCreate) SetNillableInt16(i int16) *FieldTypeCreate
SetNillableInt16 sets the nillable_int16 field.
func (*FieldTypeCreate) SetNillableInt32 ¶
func (ftc *FieldTypeCreate) SetNillableInt32(i int32) *FieldTypeCreate
SetNillableInt32 sets the nillable_int32 field.
func (*FieldTypeCreate) SetNillableInt64 ¶
func (ftc *FieldTypeCreate) SetNillableInt64(i int64) *FieldTypeCreate
SetNillableInt64 sets the nillable_int64 field.
func (*FieldTypeCreate) SetNillableInt8 ¶
func (ftc *FieldTypeCreate) SetNillableInt8(i int8) *FieldTypeCreate
SetNillableInt8 sets the nillable_int8 field.
func (*FieldTypeCreate) SetNillableNdir ¶
func (ftc *FieldTypeCreate) SetNillableNdir(h *http.Dir) *FieldTypeCreate
SetNillableNdir sets the ndir field if the given value is not nil.
func (*FieldTypeCreate) SetNillableNillableInt ¶
func (ftc *FieldTypeCreate) SetNillableNillableInt(i *int) *FieldTypeCreate
SetNillableNillableInt sets the nillable_int field if the given value is not nil.
func (*FieldTypeCreate) SetNillableNillableInt16 ¶
func (ftc *FieldTypeCreate) SetNillableNillableInt16(i *int16) *FieldTypeCreate
SetNillableNillableInt16 sets the nillable_int16 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableNillableInt32 ¶
func (ftc *FieldTypeCreate) SetNillableNillableInt32(i *int32) *FieldTypeCreate
SetNillableNillableInt32 sets the nillable_int32 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableNillableInt64 ¶
func (ftc *FieldTypeCreate) SetNillableNillableInt64(i *int64) *FieldTypeCreate
SetNillableNillableInt64 sets the nillable_int64 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableNillableInt8 ¶
func (ftc *FieldTypeCreate) SetNillableNillableInt8(i *int8) *FieldTypeCreate
SetNillableNillableInt8 sets the nillable_int8 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableNullActive ¶
func (ftc *FieldTypeCreate) SetNillableNullActive(s *schema.Status) *FieldTypeCreate
SetNillableNullActive sets the null_active field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalFloat ¶
func (ftc *FieldTypeCreate) SetNillableOptionalFloat(f *float64) *FieldTypeCreate
SetNillableOptionalFloat sets the optional_float field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalFloat32 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalFloat32(f *float32) *FieldTypeCreate
SetNillableOptionalFloat32 sets the optional_float32 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalInt ¶
func (ftc *FieldTypeCreate) SetNillableOptionalInt(i *int) *FieldTypeCreate
SetNillableOptionalInt sets the optional_int field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalInt16 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalInt16(i *int16) *FieldTypeCreate
SetNillableOptionalInt16 sets the optional_int16 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalInt32 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalInt32(i *int32) *FieldTypeCreate
SetNillableOptionalInt32 sets the optional_int32 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalInt64 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalInt64(i *int64) *FieldTypeCreate
SetNillableOptionalInt64 sets the optional_int64 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalInt8 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalInt8(i *int8) *FieldTypeCreate
SetNillableOptionalInt8 sets the optional_int8 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalUint ¶
func (ftc *FieldTypeCreate) SetNillableOptionalUint(u *uint) *FieldTypeCreate
SetNillableOptionalUint sets the optional_uint field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalUint16 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalUint16(u *uint16) *FieldTypeCreate
SetNillableOptionalUint16 sets the optional_uint16 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalUint32 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalUint32(u *uint32) *FieldTypeCreate
SetNillableOptionalUint32 sets the optional_uint32 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalUint64 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalUint64(u *uint64) *FieldTypeCreate
SetNillableOptionalUint64 sets the optional_uint64 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableOptionalUint8 ¶
func (ftc *FieldTypeCreate) SetNillableOptionalUint8(u *uint8) *FieldTypeCreate
SetNillableOptionalUint8 sets the optional_uint8 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableRole ¶
func (ftc *FieldTypeCreate) SetNillableRole(r *role.Role) *FieldTypeCreate
SetNillableRole sets the role field if the given value is not nil.
func (*FieldTypeCreate) SetNillableSchemaFloat ¶
func (ftc *FieldTypeCreate) SetNillableSchemaFloat(s *schema.Float64) *FieldTypeCreate
SetNillableSchemaFloat sets the schema_float field if the given value is not nil.
func (*FieldTypeCreate) SetNillableSchemaFloat32 ¶
func (ftc *FieldTypeCreate) SetNillableSchemaFloat32(s *schema.Float32) *FieldTypeCreate
SetNillableSchemaFloat32 sets the schema_float32 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableSchemaInt ¶
func (ftc *FieldTypeCreate) SetNillableSchemaInt(s *schema.Int) *FieldTypeCreate
SetNillableSchemaInt sets the schema_int field if the given value is not nil.
func (*FieldTypeCreate) SetNillableSchemaInt64 ¶
func (ftc *FieldTypeCreate) SetNillableSchemaInt64(s *schema.Int64) *FieldTypeCreate
SetNillableSchemaInt64 sets the schema_int64 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableSchemaInt8 ¶
func (ftc *FieldTypeCreate) SetNillableSchemaInt8(s *schema.Int8) *FieldTypeCreate
SetNillableSchemaInt8 sets the schema_int8 field if the given value is not nil.
func (*FieldTypeCreate) SetNillableState ¶
func (ftc *FieldTypeCreate) SetNillableState(f *fieldtype.State) *FieldTypeCreate
SetNillableState sets the state field if the given value is not nil.
func (*FieldTypeCreate) SetNillableValidateOptionalInt32 ¶
func (ftc *FieldTypeCreate) SetNillableValidateOptionalInt32(i *int32) *FieldTypeCreate
SetNillableValidateOptionalInt32 sets the validate_optional_int32 field if the given value is not nil.
func (*FieldTypeCreate) SetNullActive ¶
func (ftc *FieldTypeCreate) SetNullActive(s schema.Status) *FieldTypeCreate
SetNullActive sets the null_active field.
func (*FieldTypeCreate) SetNullFloat ¶
func (ftc *FieldTypeCreate) SetNullFloat(sf sql.NullFloat64) *FieldTypeCreate
SetNullFloat sets the null_float field.
func (*FieldTypeCreate) SetNullInt64 ¶
func (ftc *FieldTypeCreate) SetNullInt64(si sql.NullInt64) *FieldTypeCreate
SetNullInt64 sets the null_int64 field.
func (*FieldTypeCreate) SetNullLink ¶
func (ftc *FieldTypeCreate) SetNullLink(s schema.Link) *FieldTypeCreate
SetNullLink sets the null_link field.
func (*FieldTypeCreate) SetNullStr ¶
func (ftc *FieldTypeCreate) SetNullStr(ss sql.NullString) *FieldTypeCreate
SetNullStr sets the null_str field.
func (*FieldTypeCreate) SetOptionalFloat ¶
func (ftc *FieldTypeCreate) SetOptionalFloat(f float64) *FieldTypeCreate
SetOptionalFloat sets the optional_float field.
func (*FieldTypeCreate) SetOptionalFloat32 ¶
func (ftc *FieldTypeCreate) SetOptionalFloat32(f float32) *FieldTypeCreate
SetOptionalFloat32 sets the optional_float32 field.
func (*FieldTypeCreate) SetOptionalInt ¶
func (ftc *FieldTypeCreate) SetOptionalInt(i int) *FieldTypeCreate
SetOptionalInt sets the optional_int field.
func (*FieldTypeCreate) SetOptionalInt16 ¶
func (ftc *FieldTypeCreate) SetOptionalInt16(i int16) *FieldTypeCreate
SetOptionalInt16 sets the optional_int16 field.
func (*FieldTypeCreate) SetOptionalInt32 ¶
func (ftc *FieldTypeCreate) SetOptionalInt32(i int32) *FieldTypeCreate
SetOptionalInt32 sets the optional_int32 field.
func (*FieldTypeCreate) SetOptionalInt64 ¶
func (ftc *FieldTypeCreate) SetOptionalInt64(i int64) *FieldTypeCreate
SetOptionalInt64 sets the optional_int64 field.
func (*FieldTypeCreate) SetOptionalInt8 ¶
func (ftc *FieldTypeCreate) SetOptionalInt8(i int8) *FieldTypeCreate
SetOptionalInt8 sets the optional_int8 field.
func (*FieldTypeCreate) SetOptionalUint ¶
func (ftc *FieldTypeCreate) SetOptionalUint(u uint) *FieldTypeCreate
SetOptionalUint sets the optional_uint field.
func (*FieldTypeCreate) SetOptionalUint16 ¶
func (ftc *FieldTypeCreate) SetOptionalUint16(u uint16) *FieldTypeCreate
SetOptionalUint16 sets the optional_uint16 field.
func (*FieldTypeCreate) SetOptionalUint32 ¶
func (ftc *FieldTypeCreate) SetOptionalUint32(u uint32) *FieldTypeCreate
SetOptionalUint32 sets the optional_uint32 field.
func (*FieldTypeCreate) SetOptionalUint64 ¶
func (ftc *FieldTypeCreate) SetOptionalUint64(u uint64) *FieldTypeCreate
SetOptionalUint64 sets the optional_uint64 field.
func (*FieldTypeCreate) SetOptionalUint8 ¶
func (ftc *FieldTypeCreate) SetOptionalUint8(u uint8) *FieldTypeCreate
SetOptionalUint8 sets the optional_uint8 field.
func (*FieldTypeCreate) SetRole ¶
func (ftc *FieldTypeCreate) SetRole(r role.Role) *FieldTypeCreate
SetRole sets the role field.
func (*FieldTypeCreate) SetSchemaFloat ¶
func (ftc *FieldTypeCreate) SetSchemaFloat(s schema.Float64) *FieldTypeCreate
SetSchemaFloat sets the schema_float field.
func (*FieldTypeCreate) SetSchemaFloat32 ¶
func (ftc *FieldTypeCreate) SetSchemaFloat32(s schema.Float32) *FieldTypeCreate
SetSchemaFloat32 sets the schema_float32 field.
func (*FieldTypeCreate) SetSchemaInt ¶
func (ftc *FieldTypeCreate) SetSchemaInt(s schema.Int) *FieldTypeCreate
SetSchemaInt sets the schema_int field.
func (*FieldTypeCreate) SetSchemaInt64 ¶
func (ftc *FieldTypeCreate) SetSchemaInt64(s schema.Int64) *FieldTypeCreate
SetSchemaInt64 sets the schema_int64 field.
func (*FieldTypeCreate) SetSchemaInt8 ¶
func (ftc *FieldTypeCreate) SetSchemaInt8(s schema.Int8) *FieldTypeCreate
SetSchemaInt8 sets the schema_int8 field.
func (*FieldTypeCreate) SetState ¶
func (ftc *FieldTypeCreate) SetState(f fieldtype.State) *FieldTypeCreate
SetState sets the state field.
func (*FieldTypeCreate) SetStr ¶
func (ftc *FieldTypeCreate) SetStr(ss sql.NullString) *FieldTypeCreate
SetStr sets the str field.
func (*FieldTypeCreate) SetValidateOptionalInt32 ¶
func (ftc *FieldTypeCreate) SetValidateOptionalInt32(i int32) *FieldTypeCreate
SetValidateOptionalInt32 sets the validate_optional_int32 field.
type FieldTypeCreateBulk ¶
type FieldTypeCreateBulk struct {
// contains filtered or unexported fields
}
FieldTypeCreateBulk is the builder for creating a bulk of FieldType entities.
type FieldTypeDelete ¶
type FieldTypeDelete struct {
// contains filtered or unexported fields
}
FieldTypeDelete is the builder for deleting a FieldType entity.
func (*FieldTypeDelete) Exec ¶
func (ftd *FieldTypeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*FieldTypeDelete) ExecX ¶
func (ftd *FieldTypeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*FieldTypeDelete) Where ¶
func (ftd *FieldTypeDelete) Where(ps ...predicate.FieldType) *FieldTypeDelete
Where adds a new predicate to the delete builder.
type FieldTypeDeleteOne ¶
type FieldTypeDeleteOne struct {
// contains filtered or unexported fields
}
FieldTypeDeleteOne is the builder for deleting a single FieldType entity.
func (*FieldTypeDeleteOne) Exec ¶
func (ftdo *FieldTypeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*FieldTypeDeleteOne) ExecX ¶
func (ftdo *FieldTypeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type FieldTypeGroupBy ¶
type FieldTypeGroupBy struct {
// contains filtered or unexported fields
}
FieldTypeGroupBy is the builder for group-by FieldType entities.
func (*FieldTypeGroupBy) Aggregate ¶
func (ftgb *FieldTypeGroupBy) Aggregate(fns ...AggregateFunc) *FieldTypeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*FieldTypeGroupBy) Bool ¶
func (ftgb *FieldTypeGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) BoolX ¶
func (ftgb *FieldTypeGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*FieldTypeGroupBy) Bools ¶
func (ftgb *FieldTypeGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) BoolsX ¶
func (ftgb *FieldTypeGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*FieldTypeGroupBy) Float64 ¶
func (ftgb *FieldTypeGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) Float64X ¶
func (ftgb *FieldTypeGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*FieldTypeGroupBy) Float64s ¶
func (ftgb *FieldTypeGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) Float64sX ¶
func (ftgb *FieldTypeGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*FieldTypeGroupBy) Int ¶
func (ftgb *FieldTypeGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) IntX ¶
func (ftgb *FieldTypeGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*FieldTypeGroupBy) Ints ¶
func (ftgb *FieldTypeGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) IntsX ¶
func (ftgb *FieldTypeGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*FieldTypeGroupBy) Scan ¶
func (ftgb *FieldTypeGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*FieldTypeGroupBy) ScanX ¶
func (ftgb *FieldTypeGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*FieldTypeGroupBy) String ¶
func (ftgb *FieldTypeGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*FieldTypeGroupBy) StringX ¶
func (ftgb *FieldTypeGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type FieldTypeMutation ¶
type FieldTypeMutation struct {
// contains filtered or unexported fields
}
FieldTypeMutation represents an operation that mutate the FieldTypes nodes in the graph.
func (*FieldTypeMutation) Active ¶
func (m *FieldTypeMutation) Active() (r schema.Status, exists bool)
Active returns the active value in the mutation.
func (*FieldTypeMutation) ActiveCleared ¶
func (m *FieldTypeMutation) ActiveCleared() bool
ActiveCleared returns if the field active was cleared in this mutation.
func (*FieldTypeMutation) AddDecimal ¶
func (m *FieldTypeMutation) AddDecimal(f float64)
AddDecimal adds f to decimal.
func (*FieldTypeMutation) AddField ¶
func (m *FieldTypeMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*FieldTypeMutation) AddInt16 ¶
func (m *FieldTypeMutation) AddInt16(i int16)
AddInt16 adds i to int16.
func (*FieldTypeMutation) AddInt32 ¶
func (m *FieldTypeMutation) AddInt32(i int32)
AddInt32 adds i to int32.
func (*FieldTypeMutation) AddInt64 ¶
func (m *FieldTypeMutation) AddInt64(i int64)
AddInt64 adds i to int64.
func (*FieldTypeMutation) AddInt8 ¶
func (m *FieldTypeMutation) AddInt8(i int8)
AddInt8 adds i to int8.
func (*FieldTypeMutation) AddNillableInt ¶
func (m *FieldTypeMutation) AddNillableInt(i int)
AddNillableInt adds i to nillable_int.
func (*FieldTypeMutation) AddNillableInt16 ¶
func (m *FieldTypeMutation) AddNillableInt16(i int16)
AddNillableInt16 adds i to nillable_int16.
func (*FieldTypeMutation) AddNillableInt32 ¶
func (m *FieldTypeMutation) AddNillableInt32(i int32)
AddNillableInt32 adds i to nillable_int32.
func (*FieldTypeMutation) AddNillableInt64 ¶
func (m *FieldTypeMutation) AddNillableInt64(i int64)
AddNillableInt64 adds i to nillable_int64.
func (*FieldTypeMutation) AddNillableInt8 ¶
func (m *FieldTypeMutation) AddNillableInt8(i int8)
AddNillableInt8 adds i to nillable_int8.
func (*FieldTypeMutation) AddOptionalFloat ¶
func (m *FieldTypeMutation) AddOptionalFloat(f float64)
AddOptionalFloat adds f to optional_float.
func (*FieldTypeMutation) AddOptionalFloat32 ¶
func (m *FieldTypeMutation) AddOptionalFloat32(f float32)
AddOptionalFloat32 adds f to optional_float32.
func (*FieldTypeMutation) AddOptionalInt ¶
func (m *FieldTypeMutation) AddOptionalInt(i int)
AddOptionalInt adds i to optional_int.
func (*FieldTypeMutation) AddOptionalInt16 ¶
func (m *FieldTypeMutation) AddOptionalInt16(i int16)
AddOptionalInt16 adds i to optional_int16.
func (*FieldTypeMutation) AddOptionalInt32 ¶
func (m *FieldTypeMutation) AddOptionalInt32(i int32)
AddOptionalInt32 adds i to optional_int32.
func (*FieldTypeMutation) AddOptionalInt64 ¶
func (m *FieldTypeMutation) AddOptionalInt64(i int64)
AddOptionalInt64 adds i to optional_int64.
func (*FieldTypeMutation) AddOptionalInt8 ¶
func (m *FieldTypeMutation) AddOptionalInt8(i int8)
AddOptionalInt8 adds i to optional_int8.
func (*FieldTypeMutation) AddOptionalUint ¶
func (m *FieldTypeMutation) AddOptionalUint(u uint)
AddOptionalUint adds u to optional_uint.
func (*FieldTypeMutation) AddOptionalUint16 ¶
func (m *FieldTypeMutation) AddOptionalUint16(u uint16)
AddOptionalUint16 adds u to optional_uint16.
func (*FieldTypeMutation) AddOptionalUint32 ¶
func (m *FieldTypeMutation) AddOptionalUint32(u uint32)
AddOptionalUint32 adds u to optional_uint32.
func (*FieldTypeMutation) AddOptionalUint64 ¶
func (m *FieldTypeMutation) AddOptionalUint64(u uint64)
AddOptionalUint64 adds u to optional_uint64.
func (*FieldTypeMutation) AddOptionalUint8 ¶
func (m *FieldTypeMutation) AddOptionalUint8(u uint8)
AddOptionalUint8 adds u to optional_uint8.
func (*FieldTypeMutation) AddSchemaFloat ¶
func (m *FieldTypeMutation) AddSchemaFloat(s schema.Float64)
AddSchemaFloat adds s to schema_float.
func (*FieldTypeMutation) AddSchemaFloat32 ¶
func (m *FieldTypeMutation) AddSchemaFloat32(s schema.Float32)
AddSchemaFloat32 adds s to schema_float32.
func (*FieldTypeMutation) AddSchemaInt ¶
func (m *FieldTypeMutation) AddSchemaInt(s schema.Int)
AddSchemaInt adds s to schema_int.
func (*FieldTypeMutation) AddSchemaInt64 ¶
func (m *FieldTypeMutation) AddSchemaInt64(s schema.Int64)
AddSchemaInt64 adds s to schema_int64.
func (*FieldTypeMutation) AddSchemaInt8 ¶
func (m *FieldTypeMutation) AddSchemaInt8(s schema.Int8)
AddSchemaInt8 adds s to schema_int8.
func (*FieldTypeMutation) AddValidateOptionalInt32 ¶
func (m *FieldTypeMutation) AddValidateOptionalInt32(i int32)
AddValidateOptionalInt32 adds i to validate_optional_int32.
func (*FieldTypeMutation) AddedDecimal ¶
func (m *FieldTypeMutation) AddedDecimal() (r float64, exists bool)
AddedDecimal returns the value that was added to the decimal field in this mutation.
func (*FieldTypeMutation) AddedEdges ¶
func (m *FieldTypeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*FieldTypeMutation) AddedField ¶
func (m *FieldTypeMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*FieldTypeMutation) AddedFields ¶
func (m *FieldTypeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*FieldTypeMutation) AddedIDs ¶
func (m *FieldTypeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*FieldTypeMutation) AddedInt ¶
func (m *FieldTypeMutation) AddedInt() (r int, exists bool)
AddedInt returns the value that was added to the int field in this mutation.
func (*FieldTypeMutation) AddedInt16 ¶
func (m *FieldTypeMutation) AddedInt16() (r int16, exists bool)
AddedInt16 returns the value that was added to the int16 field in this mutation.
func (*FieldTypeMutation) AddedInt32 ¶
func (m *FieldTypeMutation) AddedInt32() (r int32, exists bool)
AddedInt32 returns the value that was added to the int32 field in this mutation.
func (*FieldTypeMutation) AddedInt64 ¶
func (m *FieldTypeMutation) AddedInt64() (r int64, exists bool)
AddedInt64 returns the value that was added to the int64 field in this mutation.
func (*FieldTypeMutation) AddedInt8 ¶
func (m *FieldTypeMutation) AddedInt8() (r int8, exists bool)
AddedInt8 returns the value that was added to the int8 field in this mutation.
func (*FieldTypeMutation) AddedNillableInt ¶
func (m *FieldTypeMutation) AddedNillableInt() (r int, exists bool)
AddedNillableInt returns the value that was added to the nillable_int field in this mutation.
func (*FieldTypeMutation) AddedNillableInt16 ¶
func (m *FieldTypeMutation) AddedNillableInt16() (r int16, exists bool)
AddedNillableInt16 returns the value that was added to the nillable_int16 field in this mutation.
func (*FieldTypeMutation) AddedNillableInt32 ¶
func (m *FieldTypeMutation) AddedNillableInt32() (r int32, exists bool)
AddedNillableInt32 returns the value that was added to the nillable_int32 field in this mutation.
func (*FieldTypeMutation) AddedNillableInt64 ¶
func (m *FieldTypeMutation) AddedNillableInt64() (r int64, exists bool)
AddedNillableInt64 returns the value that was added to the nillable_int64 field in this mutation.
func (*FieldTypeMutation) AddedNillableInt8 ¶
func (m *FieldTypeMutation) AddedNillableInt8() (r int8, exists bool)
AddedNillableInt8 returns the value that was added to the nillable_int8 field in this mutation.
func (*FieldTypeMutation) AddedOptionalFloat ¶
func (m *FieldTypeMutation) AddedOptionalFloat() (r float64, exists bool)
AddedOptionalFloat returns the value that was added to the optional_float field in this mutation.
func (*FieldTypeMutation) AddedOptionalFloat32 ¶
func (m *FieldTypeMutation) AddedOptionalFloat32() (r float32, exists bool)
AddedOptionalFloat32 returns the value that was added to the optional_float32 field in this mutation.
func (*FieldTypeMutation) AddedOptionalInt ¶
func (m *FieldTypeMutation) AddedOptionalInt() (r int, exists bool)
AddedOptionalInt returns the value that was added to the optional_int field in this mutation.
func (*FieldTypeMutation) AddedOptionalInt16 ¶
func (m *FieldTypeMutation) AddedOptionalInt16() (r int16, exists bool)
AddedOptionalInt16 returns the value that was added to the optional_int16 field in this mutation.
func (*FieldTypeMutation) AddedOptionalInt32 ¶
func (m *FieldTypeMutation) AddedOptionalInt32() (r int32, exists bool)
AddedOptionalInt32 returns the value that was added to the optional_int32 field in this mutation.
func (*FieldTypeMutation) AddedOptionalInt64 ¶
func (m *FieldTypeMutation) AddedOptionalInt64() (r int64, exists bool)
AddedOptionalInt64 returns the value that was added to the optional_int64 field in this mutation.
func (*FieldTypeMutation) AddedOptionalInt8 ¶
func (m *FieldTypeMutation) AddedOptionalInt8() (r int8, exists bool)
AddedOptionalInt8 returns the value that was added to the optional_int8 field in this mutation.
func (*FieldTypeMutation) AddedOptionalUint ¶
func (m *FieldTypeMutation) AddedOptionalUint() (r uint, exists bool)
AddedOptionalUint returns the value that was added to the optional_uint field in this mutation.
func (*FieldTypeMutation) AddedOptionalUint16 ¶
func (m *FieldTypeMutation) AddedOptionalUint16() (r uint16, exists bool)
AddedOptionalUint16 returns the value that was added to the optional_uint16 field in this mutation.
func (*FieldTypeMutation) AddedOptionalUint32 ¶
func (m *FieldTypeMutation) AddedOptionalUint32() (r uint32, exists bool)
AddedOptionalUint32 returns the value that was added to the optional_uint32 field in this mutation.
func (*FieldTypeMutation) AddedOptionalUint64 ¶
func (m *FieldTypeMutation) AddedOptionalUint64() (r uint64, exists bool)
AddedOptionalUint64 returns the value that was added to the optional_uint64 field in this mutation.
func (*FieldTypeMutation) AddedOptionalUint8 ¶
func (m *FieldTypeMutation) AddedOptionalUint8() (r uint8, exists bool)
AddedOptionalUint8 returns the value that was added to the optional_uint8 field in this mutation.
func (*FieldTypeMutation) AddedSchemaFloat ¶
func (m *FieldTypeMutation) AddedSchemaFloat() (r schema.Float64, exists bool)
AddedSchemaFloat returns the value that was added to the schema_float field in this mutation.
func (*FieldTypeMutation) AddedSchemaFloat32 ¶
func (m *FieldTypeMutation) AddedSchemaFloat32() (r schema.Float32, exists bool)
AddedSchemaFloat32 returns the value that was added to the schema_float32 field in this mutation.
func (*FieldTypeMutation) AddedSchemaInt ¶
func (m *FieldTypeMutation) AddedSchemaInt() (r schema.Int, exists bool)
AddedSchemaInt returns the value that was added to the schema_int field in this mutation.
func (*FieldTypeMutation) AddedSchemaInt64 ¶
func (m *FieldTypeMutation) AddedSchemaInt64() (r schema.Int64, exists bool)
AddedSchemaInt64 returns the value that was added to the schema_int64 field in this mutation.
func (*FieldTypeMutation) AddedSchemaInt8 ¶
func (m *FieldTypeMutation) AddedSchemaInt8() (r schema.Int8, exists bool)
AddedSchemaInt8 returns the value that was added to the schema_int8 field in this mutation.
func (*FieldTypeMutation) AddedValidateOptionalInt32 ¶
func (m *FieldTypeMutation) AddedValidateOptionalInt32() (r int32, exists bool)
AddedValidateOptionalInt32 returns the value that was added to the validate_optional_int32 field in this mutation.
func (*FieldTypeMutation) ClearActive ¶
func (m *FieldTypeMutation) ClearActive()
ClearActive clears the value of active.
func (*FieldTypeMutation) ClearDatetime ¶
func (m *FieldTypeMutation) ClearDatetime()
ClearDatetime clears the value of datetime.
func (*FieldTypeMutation) ClearDecimal ¶
func (m *FieldTypeMutation) ClearDecimal()
ClearDecimal clears the value of decimal.
func (*FieldTypeMutation) ClearDeleted ¶
func (m *FieldTypeMutation) ClearDeleted()
ClearDeleted clears the value of deleted.
func (*FieldTypeMutation) ClearDeletedAt ¶
func (m *FieldTypeMutation) ClearDeletedAt()
ClearDeletedAt clears the value of deleted_at.
func (*FieldTypeMutation) ClearDir ¶
func (m *FieldTypeMutation) ClearDir()
ClearDir clears the value of dir.
func (*FieldTypeMutation) ClearEdge ¶
func (m *FieldTypeMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*FieldTypeMutation) ClearField ¶
func (m *FieldTypeMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*FieldTypeMutation) ClearIP ¶
func (m *FieldTypeMutation) ClearIP()
ClearIP clears the value of ip.
func (*FieldTypeMutation) ClearLink ¶
func (m *FieldTypeMutation) ClearLink()
ClearLink clears the value of link.
func (*FieldTypeMutation) ClearNdir ¶
func (m *FieldTypeMutation) ClearNdir()
ClearNdir clears the value of ndir.
func (*FieldTypeMutation) ClearNillableInt ¶
func (m *FieldTypeMutation) ClearNillableInt()
ClearNillableInt clears the value of nillable_int.
func (*FieldTypeMutation) ClearNillableInt16 ¶
func (m *FieldTypeMutation) ClearNillableInt16()
ClearNillableInt16 clears the value of nillable_int16.
func (*FieldTypeMutation) ClearNillableInt32 ¶
func (m *FieldTypeMutation) ClearNillableInt32()
ClearNillableInt32 clears the value of nillable_int32.
func (*FieldTypeMutation) ClearNillableInt64 ¶
func (m *FieldTypeMutation) ClearNillableInt64()
ClearNillableInt64 clears the value of nillable_int64.
func (*FieldTypeMutation) ClearNillableInt8 ¶
func (m *FieldTypeMutation) ClearNillableInt8()
ClearNillableInt8 clears the value of nillable_int8.
func (*FieldTypeMutation) ClearNullActive ¶
func (m *FieldTypeMutation) ClearNullActive()
ClearNullActive clears the value of null_active.
func (*FieldTypeMutation) ClearNullFloat ¶
func (m *FieldTypeMutation) ClearNullFloat()
ClearNullFloat clears the value of null_float.
func (*FieldTypeMutation) ClearNullInt64 ¶
func (m *FieldTypeMutation) ClearNullInt64()
ClearNullInt64 clears the value of null_int64.
func (*FieldTypeMutation) ClearNullLink ¶
func (m *FieldTypeMutation) ClearNullLink()
ClearNullLink clears the value of null_link.
func (*FieldTypeMutation) ClearNullStr ¶
func (m *FieldTypeMutation) ClearNullStr()
ClearNullStr clears the value of null_str.
func (*FieldTypeMutation) ClearOptionalFloat ¶
func (m *FieldTypeMutation) ClearOptionalFloat()
ClearOptionalFloat clears the value of optional_float.
func (*FieldTypeMutation) ClearOptionalFloat32 ¶
func (m *FieldTypeMutation) ClearOptionalFloat32()
ClearOptionalFloat32 clears the value of optional_float32.
func (*FieldTypeMutation) ClearOptionalInt ¶
func (m *FieldTypeMutation) ClearOptionalInt()
ClearOptionalInt clears the value of optional_int.
func (*FieldTypeMutation) ClearOptionalInt16 ¶
func (m *FieldTypeMutation) ClearOptionalInt16()
ClearOptionalInt16 clears the value of optional_int16.
func (*FieldTypeMutation) ClearOptionalInt32 ¶
func (m *FieldTypeMutation) ClearOptionalInt32()
ClearOptionalInt32 clears the value of optional_int32.
func (*FieldTypeMutation) ClearOptionalInt64 ¶
func (m *FieldTypeMutation) ClearOptionalInt64()
ClearOptionalInt64 clears the value of optional_int64.
func (*FieldTypeMutation) ClearOptionalInt8 ¶
func (m *FieldTypeMutation) ClearOptionalInt8()
ClearOptionalInt8 clears the value of optional_int8.
func (*FieldTypeMutation) ClearOptionalUint ¶
func (m *FieldTypeMutation) ClearOptionalUint()
ClearOptionalUint clears the value of optional_uint.
func (*FieldTypeMutation) ClearOptionalUint16 ¶
func (m *FieldTypeMutation) ClearOptionalUint16()
ClearOptionalUint16 clears the value of optional_uint16.
func (*FieldTypeMutation) ClearOptionalUint32 ¶
func (m *FieldTypeMutation) ClearOptionalUint32()
ClearOptionalUint32 clears the value of optional_uint32.
func (*FieldTypeMutation) ClearOptionalUint64 ¶
func (m *FieldTypeMutation) ClearOptionalUint64()
ClearOptionalUint64 clears the value of optional_uint64.
func (*FieldTypeMutation) ClearOptionalUint8 ¶
func (m *FieldTypeMutation) ClearOptionalUint8()
ClearOptionalUint8 clears the value of optional_uint8.
func (*FieldTypeMutation) ClearSchemaFloat ¶
func (m *FieldTypeMutation) ClearSchemaFloat()
ClearSchemaFloat clears the value of schema_float.
func (*FieldTypeMutation) ClearSchemaFloat32 ¶
func (m *FieldTypeMutation) ClearSchemaFloat32()
ClearSchemaFloat32 clears the value of schema_float32.
func (*FieldTypeMutation) ClearSchemaInt ¶
func (m *FieldTypeMutation) ClearSchemaInt()
ClearSchemaInt clears the value of schema_int.
func (*FieldTypeMutation) ClearSchemaInt64 ¶
func (m *FieldTypeMutation) ClearSchemaInt64()
ClearSchemaInt64 clears the value of schema_int64.
func (*FieldTypeMutation) ClearSchemaInt8 ¶
func (m *FieldTypeMutation) ClearSchemaInt8()
ClearSchemaInt8 clears the value of schema_int8.
func (*FieldTypeMutation) ClearState ¶
func (m *FieldTypeMutation) ClearState()
ClearState clears the value of state.
func (*FieldTypeMutation) ClearStr ¶
func (m *FieldTypeMutation) ClearStr()
ClearStr clears the value of str.
func (*FieldTypeMutation) ClearValidateOptionalInt32 ¶
func (m *FieldTypeMutation) ClearValidateOptionalInt32()
ClearValidateOptionalInt32 clears the value of validate_optional_int32.
func (*FieldTypeMutation) ClearedEdges ¶
func (m *FieldTypeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*FieldTypeMutation) ClearedFields ¶
func (m *FieldTypeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (FieldTypeMutation) Client ¶
func (m FieldTypeMutation) 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 (*FieldTypeMutation) Datetime ¶
func (m *FieldTypeMutation) Datetime() (r time.Time, exists bool)
Datetime returns the datetime value in the mutation.
func (*FieldTypeMutation) DatetimeCleared ¶
func (m *FieldTypeMutation) DatetimeCleared() bool
DatetimeCleared returns if the field datetime was cleared in this mutation.
func (*FieldTypeMutation) Decimal ¶
func (m *FieldTypeMutation) Decimal() (r float64, exists bool)
Decimal returns the decimal value in the mutation.
func (*FieldTypeMutation) DecimalCleared ¶
func (m *FieldTypeMutation) DecimalCleared() bool
DecimalCleared returns if the field decimal was cleared in this mutation.
func (*FieldTypeMutation) Deleted ¶
func (m *FieldTypeMutation) Deleted() (r sql.NullBool, exists bool)
Deleted returns the deleted value in the mutation.
func (*FieldTypeMutation) DeletedAt ¶
func (m *FieldTypeMutation) DeletedAt() (r sql.NullTime, exists bool)
DeletedAt returns the deleted_at value in the mutation.
func (*FieldTypeMutation) DeletedAtCleared ¶
func (m *FieldTypeMutation) DeletedAtCleared() bool
DeletedAtCleared returns if the field deleted_at was cleared in this mutation.
func (*FieldTypeMutation) DeletedCleared ¶
func (m *FieldTypeMutation) DeletedCleared() bool
DeletedCleared returns if the field deleted was cleared in this mutation.
func (*FieldTypeMutation) Dir ¶
func (m *FieldTypeMutation) Dir() (r http.Dir, exists bool)
Dir returns the dir value in the mutation.
func (*FieldTypeMutation) DirCleared ¶
func (m *FieldTypeMutation) DirCleared() bool
DirCleared returns if the field dir was cleared in this mutation.
func (*FieldTypeMutation) EdgeCleared ¶
func (m *FieldTypeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*FieldTypeMutation) Field ¶
func (m *FieldTypeMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*FieldTypeMutation) FieldCleared ¶
func (m *FieldTypeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*FieldTypeMutation) Fields ¶
func (m *FieldTypeMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*FieldTypeMutation) ID ¶
func (m *FieldTypeMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*FieldTypeMutation) IP ¶
func (m *FieldTypeMutation) IP() (r net.IP, exists bool)
IP returns the ip value in the mutation.
func (*FieldTypeMutation) IPCleared ¶
func (m *FieldTypeMutation) IPCleared() bool
IPCleared returns if the field ip was cleared in this mutation.
func (*FieldTypeMutation) Int ¶
func (m *FieldTypeMutation) Int() (r int, exists bool)
Int returns the int value in the mutation.
func (*FieldTypeMutation) Int16 ¶
func (m *FieldTypeMutation) Int16() (r int16, exists bool)
Int16 returns the int16 value in the mutation.
func (*FieldTypeMutation) Int32 ¶
func (m *FieldTypeMutation) Int32() (r int32, exists bool)
Int32 returns the int32 value in the mutation.
func (*FieldTypeMutation) Int64 ¶
func (m *FieldTypeMutation) Int64() (r int64, exists bool)
Int64 returns the int64 value in the mutation.
func (*FieldTypeMutation) Int8 ¶
func (m *FieldTypeMutation) Int8() (r int8, exists bool)
Int8 returns the int8 value in the mutation.
func (*FieldTypeMutation) Link ¶
func (m *FieldTypeMutation) Link() (r schema.Link, exists bool)
Link returns the link value in the mutation.
func (*FieldTypeMutation) LinkCleared ¶
func (m *FieldTypeMutation) LinkCleared() bool
LinkCleared returns if the field link was cleared in this mutation.
func (*FieldTypeMutation) Ndir ¶
func (m *FieldTypeMutation) Ndir() (r http.Dir, exists bool)
Ndir returns the ndir value in the mutation.
func (*FieldTypeMutation) NdirCleared ¶
func (m *FieldTypeMutation) NdirCleared() bool
NdirCleared returns if the field ndir was cleared in this mutation.
func (*FieldTypeMutation) NillableInt ¶
func (m *FieldTypeMutation) NillableInt() (r int, exists bool)
NillableInt returns the nillable_int value in the mutation.
func (*FieldTypeMutation) NillableInt16 ¶
func (m *FieldTypeMutation) NillableInt16() (r int16, exists bool)
NillableInt16 returns the nillable_int16 value in the mutation.
func (*FieldTypeMutation) NillableInt16Cleared ¶
func (m *FieldTypeMutation) NillableInt16Cleared() bool
NillableInt16Cleared returns if the field nillable_int16 was cleared in this mutation.
func (*FieldTypeMutation) NillableInt32 ¶
func (m *FieldTypeMutation) NillableInt32() (r int32, exists bool)
NillableInt32 returns the nillable_int32 value in the mutation.
func (*FieldTypeMutation) NillableInt32Cleared ¶
func (m *FieldTypeMutation) NillableInt32Cleared() bool
NillableInt32Cleared returns if the field nillable_int32 was cleared in this mutation.
func (*FieldTypeMutation) NillableInt64 ¶
func (m *FieldTypeMutation) NillableInt64() (r int64, exists bool)
NillableInt64 returns the nillable_int64 value in the mutation.
func (*FieldTypeMutation) NillableInt64Cleared ¶
func (m *FieldTypeMutation) NillableInt64Cleared() bool
NillableInt64Cleared returns if the field nillable_int64 was cleared in this mutation.
func (*FieldTypeMutation) NillableInt8 ¶
func (m *FieldTypeMutation) NillableInt8() (r int8, exists bool)
NillableInt8 returns the nillable_int8 value in the mutation.
func (*FieldTypeMutation) NillableInt8Cleared ¶
func (m *FieldTypeMutation) NillableInt8Cleared() bool
NillableInt8Cleared returns if the field nillable_int8 was cleared in this mutation.
func (*FieldTypeMutation) NillableIntCleared ¶
func (m *FieldTypeMutation) NillableIntCleared() bool
NillableIntCleared returns if the field nillable_int was cleared in this mutation.
func (*FieldTypeMutation) NullActive ¶
func (m *FieldTypeMutation) NullActive() (r schema.Status, exists bool)
NullActive returns the null_active value in the mutation.
func (*FieldTypeMutation) NullActiveCleared ¶
func (m *FieldTypeMutation) NullActiveCleared() bool
NullActiveCleared returns if the field null_active was cleared in this mutation.
func (*FieldTypeMutation) NullFloat ¶
func (m *FieldTypeMutation) NullFloat() (r sql.NullFloat64, exists bool)
NullFloat returns the null_float value in the mutation.
func (*FieldTypeMutation) NullFloatCleared ¶
func (m *FieldTypeMutation) NullFloatCleared() bool
NullFloatCleared returns if the field null_float was cleared in this mutation.
func (*FieldTypeMutation) NullInt64 ¶
func (m *FieldTypeMutation) NullInt64() (r sql.NullInt64, exists bool)
NullInt64 returns the null_int64 value in the mutation.
func (*FieldTypeMutation) NullInt64Cleared ¶
func (m *FieldTypeMutation) NullInt64Cleared() bool
NullInt64Cleared returns if the field null_int64 was cleared in this mutation.
func (*FieldTypeMutation) NullLink ¶
func (m *FieldTypeMutation) NullLink() (r schema.Link, exists bool)
NullLink returns the null_link value in the mutation.
func (*FieldTypeMutation) NullLinkCleared ¶
func (m *FieldTypeMutation) NullLinkCleared() bool
NullLinkCleared returns if the field null_link was cleared in this mutation.
func (*FieldTypeMutation) NullStr ¶
func (m *FieldTypeMutation) NullStr() (r sql.NullString, exists bool)
NullStr returns the null_str value in the mutation.
func (*FieldTypeMutation) NullStrCleared ¶
func (m *FieldTypeMutation) NullStrCleared() bool
NullStrCleared returns if the field null_str was cleared in this mutation.
func (*FieldTypeMutation) OldActive ¶
OldActive returns the old active value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldDatetime ¶
OldDatetime returns the old datetime value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldDecimal ¶
func (m *FieldTypeMutation) OldDecimal(ctx context.Context) (v float64, err error)
OldDecimal returns the old decimal value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldDeleted ¶
OldDeleted returns the old deleted value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldDeletedAt ¶
OldDeletedAt returns the old deleted_at value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldDir ¶
OldDir returns the old dir value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) 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 was failed.
func (*FieldTypeMutation) OldIP ¶
OldIP returns the old ip value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldInt ¶
func (m *FieldTypeMutation) OldInt(ctx context.Context) (v int, err error)
OldInt returns the old int value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldInt16 ¶
func (m *FieldTypeMutation) OldInt16(ctx context.Context) (v int16, err error)
OldInt16 returns the old int16 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldInt32 ¶
func (m *FieldTypeMutation) OldInt32(ctx context.Context) (v int32, err error)
OldInt32 returns the old int32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldInt64 ¶
func (m *FieldTypeMutation) OldInt64(ctx context.Context) (v int64, err error)
OldInt64 returns the old int64 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldInt8 ¶
func (m *FieldTypeMutation) OldInt8(ctx context.Context) (v int8, err error)
OldInt8 returns the old int8 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldLink ¶
OldLink returns the old link value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNdir ¶
OldNdir returns the old ndir value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNillableInt ¶
func (m *FieldTypeMutation) OldNillableInt(ctx context.Context) (v *int, err error)
OldNillableInt returns the old nillable_int value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNillableInt16 ¶
func (m *FieldTypeMutation) OldNillableInt16(ctx context.Context) (v *int16, err error)
OldNillableInt16 returns the old nillable_int16 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNillableInt32 ¶
func (m *FieldTypeMutation) OldNillableInt32(ctx context.Context) (v *int32, err error)
OldNillableInt32 returns the old nillable_int32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNillableInt64 ¶
func (m *FieldTypeMutation) OldNillableInt64(ctx context.Context) (v *int64, err error)
OldNillableInt64 returns the old nillable_int64 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNillableInt8 ¶
func (m *FieldTypeMutation) OldNillableInt8(ctx context.Context) (v *int8, err error)
OldNillableInt8 returns the old nillable_int8 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNullActive ¶
OldNullActive returns the old null_active value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNullFloat ¶
func (m *FieldTypeMutation) OldNullFloat(ctx context.Context) (v sql.NullFloat64, err error)
OldNullFloat returns the old null_float value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNullInt64 ¶
OldNullInt64 returns the old null_int64 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNullLink ¶
OldNullLink returns the old null_link value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldNullStr ¶
func (m *FieldTypeMutation) OldNullStr(ctx context.Context) (v *sql.NullString, err error)
OldNullStr returns the old null_str value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalFloat ¶
func (m *FieldTypeMutation) OldOptionalFloat(ctx context.Context) (v float64, err error)
OldOptionalFloat returns the old optional_float value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalFloat32 ¶
func (m *FieldTypeMutation) OldOptionalFloat32(ctx context.Context) (v float32, err error)
OldOptionalFloat32 returns the old optional_float32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalInt ¶
func (m *FieldTypeMutation) OldOptionalInt(ctx context.Context) (v int, err error)
OldOptionalInt returns the old optional_int value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalInt16 ¶
func (m *FieldTypeMutation) OldOptionalInt16(ctx context.Context) (v int16, err error)
OldOptionalInt16 returns the old optional_int16 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalInt32 ¶
func (m *FieldTypeMutation) OldOptionalInt32(ctx context.Context) (v int32, err error)
OldOptionalInt32 returns the old optional_int32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalInt64 ¶
func (m *FieldTypeMutation) OldOptionalInt64(ctx context.Context) (v int64, err error)
OldOptionalInt64 returns the old optional_int64 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalInt8 ¶
func (m *FieldTypeMutation) OldOptionalInt8(ctx context.Context) (v int8, err error)
OldOptionalInt8 returns the old optional_int8 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalUint ¶
func (m *FieldTypeMutation) OldOptionalUint(ctx context.Context) (v uint, err error)
OldOptionalUint returns the old optional_uint value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalUint16 ¶
func (m *FieldTypeMutation) OldOptionalUint16(ctx context.Context) (v uint16, err error)
OldOptionalUint16 returns the old optional_uint16 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalUint32 ¶
func (m *FieldTypeMutation) OldOptionalUint32(ctx context.Context) (v uint32, err error)
OldOptionalUint32 returns the old optional_uint32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalUint64 ¶
func (m *FieldTypeMutation) OldOptionalUint64(ctx context.Context) (v uint64, err error)
OldOptionalUint64 returns the old optional_uint64 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldOptionalUint8 ¶
func (m *FieldTypeMutation) OldOptionalUint8(ctx context.Context) (v uint8, err error)
OldOptionalUint8 returns the old optional_uint8 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldRole ¶
OldRole returns the old role value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldSchemaFloat ¶
OldSchemaFloat returns the old schema_float value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldSchemaFloat32 ¶
OldSchemaFloat32 returns the old schema_float32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldSchemaInt ¶
OldSchemaInt returns the old schema_int value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldSchemaInt64 ¶
OldSchemaInt64 returns the old schema_int64 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldSchemaInt8 ¶
OldSchemaInt8 returns the old schema_int8 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldState ¶
OldState returns the old state value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldStr ¶
func (m *FieldTypeMutation) OldStr(ctx context.Context) (v sql.NullString, err error)
OldStr returns the old str value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OldValidateOptionalInt32 ¶
func (m *FieldTypeMutation) OldValidateOptionalInt32(ctx context.Context) (v int32, err error)
OldValidateOptionalInt32 returns the old validate_optional_int32 value of the FieldType. If the FieldType 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 database query fails.
func (*FieldTypeMutation) OptionalFloat ¶
func (m *FieldTypeMutation) OptionalFloat() (r float64, exists bool)
OptionalFloat returns the optional_float value in the mutation.
func (*FieldTypeMutation) OptionalFloat32 ¶
func (m *FieldTypeMutation) OptionalFloat32() (r float32, exists bool)
OptionalFloat32 returns the optional_float32 value in the mutation.
func (*FieldTypeMutation) OptionalFloat32Cleared ¶
func (m *FieldTypeMutation) OptionalFloat32Cleared() bool
OptionalFloat32Cleared returns if the field optional_float32 was cleared in this mutation.
func (*FieldTypeMutation) OptionalFloatCleared ¶
func (m *FieldTypeMutation) OptionalFloatCleared() bool
OptionalFloatCleared returns if the field optional_float was cleared in this mutation.
func (*FieldTypeMutation) OptionalInt ¶
func (m *FieldTypeMutation) OptionalInt() (r int, exists bool)
OptionalInt returns the optional_int value in the mutation.
func (*FieldTypeMutation) OptionalInt16 ¶
func (m *FieldTypeMutation) OptionalInt16() (r int16, exists bool)
OptionalInt16 returns the optional_int16 value in the mutation.
func (*FieldTypeMutation) OptionalInt16Cleared ¶
func (m *FieldTypeMutation) OptionalInt16Cleared() bool
OptionalInt16Cleared returns if the field optional_int16 was cleared in this mutation.
func (*FieldTypeMutation) OptionalInt32 ¶
func (m *FieldTypeMutation) OptionalInt32() (r int32, exists bool)
OptionalInt32 returns the optional_int32 value in the mutation.
func (*FieldTypeMutation) OptionalInt32Cleared ¶
func (m *FieldTypeMutation) OptionalInt32Cleared() bool
OptionalInt32Cleared returns if the field optional_int32 was cleared in this mutation.
func (*FieldTypeMutation) OptionalInt64 ¶
func (m *FieldTypeMutation) OptionalInt64() (r int64, exists bool)
OptionalInt64 returns the optional_int64 value in the mutation.
func (*FieldTypeMutation) OptionalInt64Cleared ¶
func (m *FieldTypeMutation) OptionalInt64Cleared() bool
OptionalInt64Cleared returns if the field optional_int64 was cleared in this mutation.
func (*FieldTypeMutation) OptionalInt8 ¶
func (m *FieldTypeMutation) OptionalInt8() (r int8, exists bool)
OptionalInt8 returns the optional_int8 value in the mutation.
func (*FieldTypeMutation) OptionalInt8Cleared ¶
func (m *FieldTypeMutation) OptionalInt8Cleared() bool
OptionalInt8Cleared returns if the field optional_int8 was cleared in this mutation.
func (*FieldTypeMutation) OptionalIntCleared ¶
func (m *FieldTypeMutation) OptionalIntCleared() bool
OptionalIntCleared returns if the field optional_int was cleared in this mutation.
func (*FieldTypeMutation) OptionalUint ¶
func (m *FieldTypeMutation) OptionalUint() (r uint, exists bool)
OptionalUint returns the optional_uint value in the mutation.
func (*FieldTypeMutation) OptionalUint16 ¶
func (m *FieldTypeMutation) OptionalUint16() (r uint16, exists bool)
OptionalUint16 returns the optional_uint16 value in the mutation.
func (*FieldTypeMutation) OptionalUint16Cleared ¶
func (m *FieldTypeMutation) OptionalUint16Cleared() bool
OptionalUint16Cleared returns if the field optional_uint16 was cleared in this mutation.
func (*FieldTypeMutation) OptionalUint32 ¶
func (m *FieldTypeMutation) OptionalUint32() (r uint32, exists bool)
OptionalUint32 returns the optional_uint32 value in the mutation.
func (*FieldTypeMutation) OptionalUint32Cleared ¶
func (m *FieldTypeMutation) OptionalUint32Cleared() bool
OptionalUint32Cleared returns if the field optional_uint32 was cleared in this mutation.
func (*FieldTypeMutation) OptionalUint64 ¶
func (m *FieldTypeMutation) OptionalUint64() (r uint64, exists bool)
OptionalUint64 returns the optional_uint64 value in the mutation.
func (*FieldTypeMutation) OptionalUint64Cleared ¶
func (m *FieldTypeMutation) OptionalUint64Cleared() bool
OptionalUint64Cleared returns if the field optional_uint64 was cleared in this mutation.
func (*FieldTypeMutation) OptionalUint8 ¶
func (m *FieldTypeMutation) OptionalUint8() (r uint8, exists bool)
OptionalUint8 returns the optional_uint8 value in the mutation.
func (*FieldTypeMutation) OptionalUint8Cleared ¶
func (m *FieldTypeMutation) OptionalUint8Cleared() bool
OptionalUint8Cleared returns if the field optional_uint8 was cleared in this mutation.
func (*FieldTypeMutation) OptionalUintCleared ¶
func (m *FieldTypeMutation) OptionalUintCleared() bool
OptionalUintCleared returns if the field optional_uint was cleared in this mutation.
func (*FieldTypeMutation) RemovedEdges ¶
func (m *FieldTypeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*FieldTypeMutation) RemovedIDs ¶
func (m *FieldTypeMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*FieldTypeMutation) ResetActive ¶
func (m *FieldTypeMutation) ResetActive()
ResetActive reset all changes of the "active" field.
func (*FieldTypeMutation) ResetDatetime ¶
func (m *FieldTypeMutation) ResetDatetime()
ResetDatetime reset all changes of the "datetime" field.
func (*FieldTypeMutation) ResetDecimal ¶
func (m *FieldTypeMutation) ResetDecimal()
ResetDecimal reset all changes of the "decimal" field.
func (*FieldTypeMutation) ResetDeleted ¶
func (m *FieldTypeMutation) ResetDeleted()
ResetDeleted reset all changes of the "deleted" field.
func (*FieldTypeMutation) ResetDeletedAt ¶
func (m *FieldTypeMutation) ResetDeletedAt()
ResetDeletedAt reset all changes of the "deleted_at" field.
func (*FieldTypeMutation) ResetDir ¶
func (m *FieldTypeMutation) ResetDir()
ResetDir reset all changes of the "dir" field.
func (*FieldTypeMutation) ResetEdge ¶
func (m *FieldTypeMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*FieldTypeMutation) ResetField ¶
func (m *FieldTypeMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*FieldTypeMutation) ResetIP ¶
func (m *FieldTypeMutation) ResetIP()
ResetIP reset all changes of the "ip" field.
func (*FieldTypeMutation) ResetInt ¶
func (m *FieldTypeMutation) ResetInt()
ResetInt reset all changes of the "int" field.
func (*FieldTypeMutation) ResetInt16 ¶
func (m *FieldTypeMutation) ResetInt16()
ResetInt16 reset all changes of the "int16" field.
func (*FieldTypeMutation) ResetInt32 ¶
func (m *FieldTypeMutation) ResetInt32()
ResetInt32 reset all changes of the "int32" field.
func (*FieldTypeMutation) ResetInt64 ¶
func (m *FieldTypeMutation) ResetInt64()
ResetInt64 reset all changes of the "int64" field.
func (*FieldTypeMutation) ResetInt8 ¶
func (m *FieldTypeMutation) ResetInt8()
ResetInt8 reset all changes of the "int8" field.
func (*FieldTypeMutation) ResetLink ¶
func (m *FieldTypeMutation) ResetLink()
ResetLink reset all changes of the "link" field.
func (*FieldTypeMutation) ResetNdir ¶
func (m *FieldTypeMutation) ResetNdir()
ResetNdir reset all changes of the "ndir" field.
func (*FieldTypeMutation) ResetNillableInt ¶
func (m *FieldTypeMutation) ResetNillableInt()
ResetNillableInt reset all changes of the "nillable_int" field.
func (*FieldTypeMutation) ResetNillableInt16 ¶
func (m *FieldTypeMutation) ResetNillableInt16()
ResetNillableInt16 reset all changes of the "nillable_int16" field.
func (*FieldTypeMutation) ResetNillableInt32 ¶
func (m *FieldTypeMutation) ResetNillableInt32()
ResetNillableInt32 reset all changes of the "nillable_int32" field.
func (*FieldTypeMutation) ResetNillableInt64 ¶
func (m *FieldTypeMutation) ResetNillableInt64()
ResetNillableInt64 reset all changes of the "nillable_int64" field.
func (*FieldTypeMutation) ResetNillableInt8 ¶
func (m *FieldTypeMutation) ResetNillableInt8()
ResetNillableInt8 reset all changes of the "nillable_int8" field.
func (*FieldTypeMutation) ResetNullActive ¶
func (m *FieldTypeMutation) ResetNullActive()
ResetNullActive reset all changes of the "null_active" field.
func (*FieldTypeMutation) ResetNullFloat ¶
func (m *FieldTypeMutation) ResetNullFloat()
ResetNullFloat reset all changes of the "null_float" field.
func (*FieldTypeMutation) ResetNullInt64 ¶
func (m *FieldTypeMutation) ResetNullInt64()
ResetNullInt64 reset all changes of the "null_int64" field.
func (*FieldTypeMutation) ResetNullLink ¶
func (m *FieldTypeMutation) ResetNullLink()
ResetNullLink reset all changes of the "null_link" field.
func (*FieldTypeMutation) ResetNullStr ¶
func (m *FieldTypeMutation) ResetNullStr()
ResetNullStr reset all changes of the "null_str" field.
func (*FieldTypeMutation) ResetOptionalFloat ¶
func (m *FieldTypeMutation) ResetOptionalFloat()
ResetOptionalFloat reset all changes of the "optional_float" field.
func (*FieldTypeMutation) ResetOptionalFloat32 ¶
func (m *FieldTypeMutation) ResetOptionalFloat32()
ResetOptionalFloat32 reset all changes of the "optional_float32" field.
func (*FieldTypeMutation) ResetOptionalInt ¶
func (m *FieldTypeMutation) ResetOptionalInt()
ResetOptionalInt reset all changes of the "optional_int" field.
func (*FieldTypeMutation) ResetOptionalInt16 ¶
func (m *FieldTypeMutation) ResetOptionalInt16()
ResetOptionalInt16 reset all changes of the "optional_int16" field.
func (*FieldTypeMutation) ResetOptionalInt32 ¶
func (m *FieldTypeMutation) ResetOptionalInt32()
ResetOptionalInt32 reset all changes of the "optional_int32" field.
func (*FieldTypeMutation) ResetOptionalInt64 ¶
func (m *FieldTypeMutation) ResetOptionalInt64()
ResetOptionalInt64 reset all changes of the "optional_int64" field.
func (*FieldTypeMutation) ResetOptionalInt8 ¶
func (m *FieldTypeMutation) ResetOptionalInt8()
ResetOptionalInt8 reset all changes of the "optional_int8" field.
func (*FieldTypeMutation) ResetOptionalUint ¶
func (m *FieldTypeMutation) ResetOptionalUint()
ResetOptionalUint reset all changes of the "optional_uint" field.
func (*FieldTypeMutation) ResetOptionalUint16 ¶
func (m *FieldTypeMutation) ResetOptionalUint16()
ResetOptionalUint16 reset all changes of the "optional_uint16" field.
func (*FieldTypeMutation) ResetOptionalUint32 ¶
func (m *FieldTypeMutation) ResetOptionalUint32()
ResetOptionalUint32 reset all changes of the "optional_uint32" field.
func (*FieldTypeMutation) ResetOptionalUint64 ¶
func (m *FieldTypeMutation) ResetOptionalUint64()
ResetOptionalUint64 reset all changes of the "optional_uint64" field.
func (*FieldTypeMutation) ResetOptionalUint8 ¶
func (m *FieldTypeMutation) ResetOptionalUint8()
ResetOptionalUint8 reset all changes of the "optional_uint8" field.
func (*FieldTypeMutation) ResetRole ¶
func (m *FieldTypeMutation) ResetRole()
ResetRole reset all changes of the "role" field.
func (*FieldTypeMutation) ResetSchemaFloat ¶
func (m *FieldTypeMutation) ResetSchemaFloat()
ResetSchemaFloat reset all changes of the "schema_float" field.
func (*FieldTypeMutation) ResetSchemaFloat32 ¶
func (m *FieldTypeMutation) ResetSchemaFloat32()
ResetSchemaFloat32 reset all changes of the "schema_float32" field.
func (*FieldTypeMutation) ResetSchemaInt ¶
func (m *FieldTypeMutation) ResetSchemaInt()
ResetSchemaInt reset all changes of the "schema_int" field.
func (*FieldTypeMutation) ResetSchemaInt64 ¶
func (m *FieldTypeMutation) ResetSchemaInt64()
ResetSchemaInt64 reset all changes of the "schema_int64" field.
func (*FieldTypeMutation) ResetSchemaInt8 ¶
func (m *FieldTypeMutation) ResetSchemaInt8()
ResetSchemaInt8 reset all changes of the "schema_int8" field.
func (*FieldTypeMutation) ResetState ¶
func (m *FieldTypeMutation) ResetState()
ResetState reset all changes of the "state" field.
func (*FieldTypeMutation) ResetStr ¶
func (m *FieldTypeMutation) ResetStr()
ResetStr reset all changes of the "str" field.
func (*FieldTypeMutation) ResetValidateOptionalInt32 ¶
func (m *FieldTypeMutation) ResetValidateOptionalInt32()
ResetValidateOptionalInt32 reset all changes of the "validate_optional_int32" field.
func (*FieldTypeMutation) Role ¶
func (m *FieldTypeMutation) Role() (r role.Role, exists bool)
Role returns the role value in the mutation.
func (*FieldTypeMutation) SchemaFloat ¶
func (m *FieldTypeMutation) SchemaFloat() (r schema.Float64, exists bool)
SchemaFloat returns the schema_float value in the mutation.
func (*FieldTypeMutation) SchemaFloat32 ¶
func (m *FieldTypeMutation) SchemaFloat32() (r schema.Float32, exists bool)
SchemaFloat32 returns the schema_float32 value in the mutation.
func (*FieldTypeMutation) SchemaFloat32Cleared ¶
func (m *FieldTypeMutation) SchemaFloat32Cleared() bool
SchemaFloat32Cleared returns if the field schema_float32 was cleared in this mutation.
func (*FieldTypeMutation) SchemaFloatCleared ¶
func (m *FieldTypeMutation) SchemaFloatCleared() bool
SchemaFloatCleared returns if the field schema_float was cleared in this mutation.
func (*FieldTypeMutation) SchemaInt ¶
func (m *FieldTypeMutation) SchemaInt() (r schema.Int, exists bool)
SchemaInt returns the schema_int value in the mutation.
func (*FieldTypeMutation) SchemaInt64 ¶
func (m *FieldTypeMutation) SchemaInt64() (r schema.Int64, exists bool)
SchemaInt64 returns the schema_int64 value in the mutation.
func (*FieldTypeMutation) SchemaInt64Cleared ¶
func (m *FieldTypeMutation) SchemaInt64Cleared() bool
SchemaInt64Cleared returns if the field schema_int64 was cleared in this mutation.
func (*FieldTypeMutation) SchemaInt8 ¶
func (m *FieldTypeMutation) SchemaInt8() (r schema.Int8, exists bool)
SchemaInt8 returns the schema_int8 value in the mutation.
func (*FieldTypeMutation) SchemaInt8Cleared ¶
func (m *FieldTypeMutation) SchemaInt8Cleared() bool
SchemaInt8Cleared returns if the field schema_int8 was cleared in this mutation.
func (*FieldTypeMutation) SchemaIntCleared ¶
func (m *FieldTypeMutation) SchemaIntCleared() bool
SchemaIntCleared returns if the field schema_int was cleared in this mutation.
func (*FieldTypeMutation) SetActive ¶
func (m *FieldTypeMutation) SetActive(s schema.Status)
SetActive sets the active field.
func (*FieldTypeMutation) SetDatetime ¶
func (m *FieldTypeMutation) SetDatetime(t time.Time)
SetDatetime sets the datetime field.
func (*FieldTypeMutation) SetDecimal ¶
func (m *FieldTypeMutation) SetDecimal(f float64)
SetDecimal sets the decimal field.
func (*FieldTypeMutation) SetDeleted ¶
func (m *FieldTypeMutation) SetDeleted(sb sql.NullBool)
SetDeleted sets the deleted field.
func (*FieldTypeMutation) SetDeletedAt ¶
func (m *FieldTypeMutation) SetDeletedAt(st sql.NullTime)
SetDeletedAt sets the deleted_at field.
func (*FieldTypeMutation) SetDir ¶
func (m *FieldTypeMutation) SetDir(h http.Dir)
SetDir sets the dir field.
func (*FieldTypeMutation) SetField ¶
func (m *FieldTypeMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*FieldTypeMutation) SetIP ¶
func (m *FieldTypeMutation) SetIP(n net.IP)
SetIP sets the ip field.
func (*FieldTypeMutation) SetInt ¶
func (m *FieldTypeMutation) SetInt(i int)
SetInt sets the int field.
func (*FieldTypeMutation) SetInt16 ¶
func (m *FieldTypeMutation) SetInt16(i int16)
SetInt16 sets the int16 field.
func (*FieldTypeMutation) SetInt32 ¶
func (m *FieldTypeMutation) SetInt32(i int32)
SetInt32 sets the int32 field.
func (*FieldTypeMutation) SetInt64 ¶
func (m *FieldTypeMutation) SetInt64(i int64)
SetInt64 sets the int64 field.
func (*FieldTypeMutation) SetInt8 ¶
func (m *FieldTypeMutation) SetInt8(i int8)
SetInt8 sets the int8 field.
func (*FieldTypeMutation) SetLink ¶
func (m *FieldTypeMutation) SetLink(s schema.Link)
SetLink sets the link field.
func (*FieldTypeMutation) SetNdir ¶
func (m *FieldTypeMutation) SetNdir(h http.Dir)
SetNdir sets the ndir field.
func (*FieldTypeMutation) SetNillableInt ¶
func (m *FieldTypeMutation) SetNillableInt(i int)
SetNillableInt sets the nillable_int field.
func (*FieldTypeMutation) SetNillableInt16 ¶
func (m *FieldTypeMutation) SetNillableInt16(i int16)
SetNillableInt16 sets the nillable_int16 field.
func (*FieldTypeMutation) SetNillableInt32 ¶
func (m *FieldTypeMutation) SetNillableInt32(i int32)
SetNillableInt32 sets the nillable_int32 field.
func (*FieldTypeMutation) SetNillableInt64 ¶
func (m *FieldTypeMutation) SetNillableInt64(i int64)
SetNillableInt64 sets the nillable_int64 field.
func (*FieldTypeMutation) SetNillableInt8 ¶
func (m *FieldTypeMutation) SetNillableInt8(i int8)
SetNillableInt8 sets the nillable_int8 field.
func (*FieldTypeMutation) SetNullActive ¶
func (m *FieldTypeMutation) SetNullActive(s schema.Status)
SetNullActive sets the null_active field.
func (*FieldTypeMutation) SetNullFloat ¶
func (m *FieldTypeMutation) SetNullFloat(sf sql.NullFloat64)
SetNullFloat sets the null_float field.
func (*FieldTypeMutation) SetNullInt64 ¶
func (m *FieldTypeMutation) SetNullInt64(si sql.NullInt64)
SetNullInt64 sets the null_int64 field.
func (*FieldTypeMutation) SetNullLink ¶
func (m *FieldTypeMutation) SetNullLink(s schema.Link)
SetNullLink sets the null_link field.
func (*FieldTypeMutation) SetNullStr ¶
func (m *FieldTypeMutation) SetNullStr(ss sql.NullString)
SetNullStr sets the null_str field.
func (*FieldTypeMutation) SetOptionalFloat ¶
func (m *FieldTypeMutation) SetOptionalFloat(f float64)
SetOptionalFloat sets the optional_float field.
func (*FieldTypeMutation) SetOptionalFloat32 ¶
func (m *FieldTypeMutation) SetOptionalFloat32(f float32)
SetOptionalFloat32 sets the optional_float32 field.
func (*FieldTypeMutation) SetOptionalInt ¶
func (m *FieldTypeMutation) SetOptionalInt(i int)
SetOptionalInt sets the optional_int field.
func (*FieldTypeMutation) SetOptionalInt16 ¶
func (m *FieldTypeMutation) SetOptionalInt16(i int16)
SetOptionalInt16 sets the optional_int16 field.
func (*FieldTypeMutation) SetOptionalInt32 ¶
func (m *FieldTypeMutation) SetOptionalInt32(i int32)
SetOptionalInt32 sets the optional_int32 field.
func (*FieldTypeMutation) SetOptionalInt64 ¶
func (m *FieldTypeMutation) SetOptionalInt64(i int64)
SetOptionalInt64 sets the optional_int64 field.
func (*FieldTypeMutation) SetOptionalInt8 ¶
func (m *FieldTypeMutation) SetOptionalInt8(i int8)
SetOptionalInt8 sets the optional_int8 field.
func (*FieldTypeMutation) SetOptionalUint ¶
func (m *FieldTypeMutation) SetOptionalUint(u uint)
SetOptionalUint sets the optional_uint field.
func (*FieldTypeMutation) SetOptionalUint16 ¶
func (m *FieldTypeMutation) SetOptionalUint16(u uint16)
SetOptionalUint16 sets the optional_uint16 field.
func (*FieldTypeMutation) SetOptionalUint32 ¶
func (m *FieldTypeMutation) SetOptionalUint32(u uint32)
SetOptionalUint32 sets the optional_uint32 field.
func (*FieldTypeMutation) SetOptionalUint64 ¶
func (m *FieldTypeMutation) SetOptionalUint64(u uint64)
SetOptionalUint64 sets the optional_uint64 field.
func (*FieldTypeMutation) SetOptionalUint8 ¶
func (m *FieldTypeMutation) SetOptionalUint8(u uint8)
SetOptionalUint8 sets the optional_uint8 field.
func (*FieldTypeMutation) SetRole ¶
func (m *FieldTypeMutation) SetRole(r role.Role)
SetRole sets the role field.
func (*FieldTypeMutation) SetSchemaFloat ¶
func (m *FieldTypeMutation) SetSchemaFloat(s schema.Float64)
SetSchemaFloat sets the schema_float field.
func (*FieldTypeMutation) SetSchemaFloat32 ¶
func (m *FieldTypeMutation) SetSchemaFloat32(s schema.Float32)
SetSchemaFloat32 sets the schema_float32 field.
func (*FieldTypeMutation) SetSchemaInt ¶
func (m *FieldTypeMutation) SetSchemaInt(s schema.Int)
SetSchemaInt sets the schema_int field.
func (*FieldTypeMutation) SetSchemaInt64 ¶
func (m *FieldTypeMutation) SetSchemaInt64(s schema.Int64)
SetSchemaInt64 sets the schema_int64 field.
func (*FieldTypeMutation) SetSchemaInt8 ¶
func (m *FieldTypeMutation) SetSchemaInt8(s schema.Int8)
SetSchemaInt8 sets the schema_int8 field.
func (*FieldTypeMutation) SetState ¶
func (m *FieldTypeMutation) SetState(f fieldtype.State)
SetState sets the state field.
func (*FieldTypeMutation) SetStr ¶
func (m *FieldTypeMutation) SetStr(ss sql.NullString)
SetStr sets the str field.
func (*FieldTypeMutation) SetValidateOptionalInt32 ¶
func (m *FieldTypeMutation) SetValidateOptionalInt32(i int32)
SetValidateOptionalInt32 sets the validate_optional_int32 field.
func (*FieldTypeMutation) State ¶
func (m *FieldTypeMutation) State() (r fieldtype.State, exists bool)
State returns the state value in the mutation.
func (*FieldTypeMutation) StateCleared ¶
func (m *FieldTypeMutation) StateCleared() bool
StateCleared returns if the field state was cleared in this mutation.
func (*FieldTypeMutation) Str ¶
func (m *FieldTypeMutation) Str() (r sql.NullString, exists bool)
Str returns the str value in the mutation.
func (*FieldTypeMutation) StrCleared ¶
func (m *FieldTypeMutation) StrCleared() bool
StrCleared returns if the field str was cleared in this mutation.
func (FieldTypeMutation) Tx ¶
func (m FieldTypeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*FieldTypeMutation) Type ¶
func (m *FieldTypeMutation) Type() string
Type returns the node type of this mutation (FieldType).
func (*FieldTypeMutation) ValidateOptionalInt32 ¶
func (m *FieldTypeMutation) ValidateOptionalInt32() (r int32, exists bool)
ValidateOptionalInt32 returns the validate_optional_int32 value in the mutation.
func (*FieldTypeMutation) ValidateOptionalInt32Cleared ¶
func (m *FieldTypeMutation) ValidateOptionalInt32Cleared() bool
ValidateOptionalInt32Cleared returns if the field validate_optional_int32 was cleared in this mutation.
type FieldTypeQuery ¶
type FieldTypeQuery struct {
// contains filtered or unexported fields
}
FieldTypeQuery is the builder for querying FieldType entities.
func (*FieldTypeQuery) All ¶
func (ftq *FieldTypeQuery) All(ctx context.Context) ([]*FieldType, error)
All executes the query and returns a list of FieldTypes.
func (*FieldTypeQuery) AllX ¶
func (ftq *FieldTypeQuery) AllX(ctx context.Context) []*FieldType
AllX is like All, but panics if an error occurs.
func (*FieldTypeQuery) Clone ¶
func (ftq *FieldTypeQuery) Clone() *FieldTypeQuery
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*FieldTypeQuery) Count ¶
func (ftq *FieldTypeQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*FieldTypeQuery) CountX ¶
func (ftq *FieldTypeQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*FieldTypeQuery) Exist ¶
func (ftq *FieldTypeQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*FieldTypeQuery) ExistX ¶
func (ftq *FieldTypeQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*FieldTypeQuery) First ¶
func (ftq *FieldTypeQuery) First(ctx context.Context) (*FieldType, error)
First returns the first FieldType entity in the query. Returns *NotFoundError when no fieldtype was found.
func (*FieldTypeQuery) FirstID ¶
func (ftq *FieldTypeQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first FieldType id in the query. Returns *NotFoundError when no id was found.
func (*FieldTypeQuery) FirstIDX ¶ added in v0.5.0
func (ftq *FieldTypeQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*FieldTypeQuery) FirstX ¶
func (ftq *FieldTypeQuery) FirstX(ctx context.Context) *FieldType
FirstX is like First, but panics if an error occurs.
func (*FieldTypeQuery) GroupBy ¶
func (ftq *FieldTypeQuery) GroupBy(field string, fields ...string) *FieldTypeGroupBy
GroupBy 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 { Int int `json:"int,omitempty"` Count int `json:"count,omitempty"` } client.FieldType.Query(). GroupBy(fieldtype.FieldInt). Aggregate(ent.Count()). Scan(ctx, &v)
func (*FieldTypeQuery) IDs ¶
func (ftq *FieldTypeQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of FieldType ids.
func (*FieldTypeQuery) IDsX ¶
func (ftq *FieldTypeQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*FieldTypeQuery) Limit ¶
func (ftq *FieldTypeQuery) Limit(limit int) *FieldTypeQuery
Limit adds a limit step to the query.
func (*FieldTypeQuery) Offset ¶
func (ftq *FieldTypeQuery) Offset(offset int) *FieldTypeQuery
Offset adds an offset step to the query.
func (*FieldTypeQuery) Only ¶
func (ftq *FieldTypeQuery) Only(ctx context.Context) (*FieldType, error)
Only returns the only FieldType entity in the query, returns an error if not exactly one entity was returned.
func (*FieldTypeQuery) OnlyID ¶
func (ftq *FieldTypeQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID returns the only FieldType id in the query, returns an error if not exactly one id was returned.
func (*FieldTypeQuery) OnlyIDX ¶
func (ftq *FieldTypeQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*FieldTypeQuery) OnlyX ¶
func (ftq *FieldTypeQuery) OnlyX(ctx context.Context) *FieldType
OnlyX is like Only, but panics if an error occurs.
func (*FieldTypeQuery) Order ¶
func (ftq *FieldTypeQuery) Order(o ...OrderFunc) *FieldTypeQuery
Order adds an order step to the query.
func (*FieldTypeQuery) Select ¶
func (ftq *FieldTypeQuery) Select(field string, fields ...string) *FieldTypeSelect
Select one or more fields from the given query.
Example:
var v []struct { Int int `json:"int,omitempty"` } client.FieldType.Query(). Select(fieldtype.FieldInt). Scan(ctx, &v)
func (*FieldTypeQuery) Where ¶
func (ftq *FieldTypeQuery) Where(ps ...predicate.FieldType) *FieldTypeQuery
Where adds a new predicate for the builder.
type FieldTypeSelect ¶
type FieldTypeSelect struct {
// contains filtered or unexported fields
}
FieldTypeSelect is the builder for select fields of FieldType entities.
func (*FieldTypeSelect) Bool ¶
func (fts *FieldTypeSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) BoolX ¶
func (fts *FieldTypeSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*FieldTypeSelect) Bools ¶
func (fts *FieldTypeSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) BoolsX ¶
func (fts *FieldTypeSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*FieldTypeSelect) Float64 ¶
func (fts *FieldTypeSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) Float64X ¶
func (fts *FieldTypeSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*FieldTypeSelect) Float64s ¶
func (fts *FieldTypeSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) Float64sX ¶
func (fts *FieldTypeSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*FieldTypeSelect) Int ¶
func (fts *FieldTypeSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) IntX ¶
func (fts *FieldTypeSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*FieldTypeSelect) Ints ¶
func (fts *FieldTypeSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) IntsX ¶
func (fts *FieldTypeSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*FieldTypeSelect) Scan ¶
func (fts *FieldTypeSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*FieldTypeSelect) ScanX ¶
func (fts *FieldTypeSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*FieldTypeSelect) String ¶
func (fts *FieldTypeSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*FieldTypeSelect) StringX ¶
func (fts *FieldTypeSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type FieldTypeUpdate ¶
type FieldTypeUpdate struct {
// contains filtered or unexported fields
}
FieldTypeUpdate is the builder for updating FieldType entities.
func (*FieldTypeUpdate) AddDecimal ¶
func (ftu *FieldTypeUpdate) AddDecimal(f float64) *FieldTypeUpdate
AddDecimal adds f to decimal.
func (*FieldTypeUpdate) AddInt ¶
func (ftu *FieldTypeUpdate) AddInt(i int) *FieldTypeUpdate
AddInt adds i to int.
func (*FieldTypeUpdate) AddInt16 ¶
func (ftu *FieldTypeUpdate) AddInt16(i int16) *FieldTypeUpdate
AddInt16 adds i to int16.
func (*FieldTypeUpdate) AddInt32 ¶
func (ftu *FieldTypeUpdate) AddInt32(i int32) *FieldTypeUpdate
AddInt32 adds i to int32.
func (*FieldTypeUpdate) AddInt64 ¶
func (ftu *FieldTypeUpdate) AddInt64(i int64) *FieldTypeUpdate
AddInt64 adds i to int64.
func (*FieldTypeUpdate) AddInt8 ¶
func (ftu *FieldTypeUpdate) AddInt8(i int8) *FieldTypeUpdate
AddInt8 adds i to int8.
func (*FieldTypeUpdate) AddNillableInt ¶
func (ftu *FieldTypeUpdate) AddNillableInt(i int) *FieldTypeUpdate
AddNillableInt adds i to nillable_int.
func (*FieldTypeUpdate) AddNillableInt16 ¶
func (ftu *FieldTypeUpdate) AddNillableInt16(i int16) *FieldTypeUpdate
AddNillableInt16 adds i to nillable_int16.
func (*FieldTypeUpdate) AddNillableInt32 ¶
func (ftu *FieldTypeUpdate) AddNillableInt32(i int32) *FieldTypeUpdate
AddNillableInt32 adds i to nillable_int32.
func (*FieldTypeUpdate) AddNillableInt64 ¶
func (ftu *FieldTypeUpdate) AddNillableInt64(i int64) *FieldTypeUpdate
AddNillableInt64 adds i to nillable_int64.
func (*FieldTypeUpdate) AddNillableInt8 ¶
func (ftu *FieldTypeUpdate) AddNillableInt8(i int8) *FieldTypeUpdate
AddNillableInt8 adds i to nillable_int8.
func (*FieldTypeUpdate) AddOptionalFloat ¶
func (ftu *FieldTypeUpdate) AddOptionalFloat(f float64) *FieldTypeUpdate
AddOptionalFloat adds f to optional_float.
func (*FieldTypeUpdate) AddOptionalFloat32 ¶
func (ftu *FieldTypeUpdate) AddOptionalFloat32(f float32) *FieldTypeUpdate
AddOptionalFloat32 adds f to optional_float32.
func (*FieldTypeUpdate) AddOptionalInt ¶
func (ftu *FieldTypeUpdate) AddOptionalInt(i int) *FieldTypeUpdate
AddOptionalInt adds i to optional_int.
func (*FieldTypeUpdate) AddOptionalInt16 ¶
func (ftu *FieldTypeUpdate) AddOptionalInt16(i int16) *FieldTypeUpdate
AddOptionalInt16 adds i to optional_int16.
func (*FieldTypeUpdate) AddOptionalInt32 ¶
func (ftu *FieldTypeUpdate) AddOptionalInt32(i int32) *FieldTypeUpdate
AddOptionalInt32 adds i to optional_int32.
func (*FieldTypeUpdate) AddOptionalInt64 ¶
func (ftu *FieldTypeUpdate) AddOptionalInt64(i int64) *FieldTypeUpdate
AddOptionalInt64 adds i to optional_int64.
func (*FieldTypeUpdate) AddOptionalInt8 ¶
func (ftu *FieldTypeUpdate) AddOptionalInt8(i int8) *FieldTypeUpdate
AddOptionalInt8 adds i to optional_int8.
func (*FieldTypeUpdate) AddOptionalUint ¶
func (ftu *FieldTypeUpdate) AddOptionalUint(u uint) *FieldTypeUpdate
AddOptionalUint adds u to optional_uint.
func (*FieldTypeUpdate) AddOptionalUint16 ¶
func (ftu *FieldTypeUpdate) AddOptionalUint16(u uint16) *FieldTypeUpdate
AddOptionalUint16 adds u to optional_uint16.
func (*FieldTypeUpdate) AddOptionalUint32 ¶
func (ftu *FieldTypeUpdate) AddOptionalUint32(u uint32) *FieldTypeUpdate
AddOptionalUint32 adds u to optional_uint32.
func (*FieldTypeUpdate) AddOptionalUint64 ¶
func (ftu *FieldTypeUpdate) AddOptionalUint64(u uint64) *FieldTypeUpdate
AddOptionalUint64 adds u to optional_uint64.
func (*FieldTypeUpdate) AddOptionalUint8 ¶
func (ftu *FieldTypeUpdate) AddOptionalUint8(u uint8) *FieldTypeUpdate
AddOptionalUint8 adds u to optional_uint8.
func (*FieldTypeUpdate) AddSchemaFloat ¶
func (ftu *FieldTypeUpdate) AddSchemaFloat(s schema.Float64) *FieldTypeUpdate
AddSchemaFloat adds s to schema_float.
func (*FieldTypeUpdate) AddSchemaFloat32 ¶
func (ftu *FieldTypeUpdate) AddSchemaFloat32(s schema.Float32) *FieldTypeUpdate
AddSchemaFloat32 adds s to schema_float32.
func (*FieldTypeUpdate) AddSchemaInt ¶
func (ftu *FieldTypeUpdate) AddSchemaInt(s schema.Int) *FieldTypeUpdate
AddSchemaInt adds s to schema_int.
func (*FieldTypeUpdate) AddSchemaInt64 ¶
func (ftu *FieldTypeUpdate) AddSchemaInt64(s schema.Int64) *FieldTypeUpdate
AddSchemaInt64 adds s to schema_int64.
func (*FieldTypeUpdate) AddSchemaInt8 ¶
func (ftu *FieldTypeUpdate) AddSchemaInt8(s schema.Int8) *FieldTypeUpdate
AddSchemaInt8 adds s to schema_int8.
func (*FieldTypeUpdate) AddValidateOptionalInt32 ¶
func (ftu *FieldTypeUpdate) AddValidateOptionalInt32(i int32) *FieldTypeUpdate
AddValidateOptionalInt32 adds i to validate_optional_int32.
func (*FieldTypeUpdate) ClearActive ¶
func (ftu *FieldTypeUpdate) ClearActive() *FieldTypeUpdate
ClearActive clears the value of active.
func (*FieldTypeUpdate) ClearDatetime ¶
func (ftu *FieldTypeUpdate) ClearDatetime() *FieldTypeUpdate
ClearDatetime clears the value of datetime.
func (*FieldTypeUpdate) ClearDecimal ¶
func (ftu *FieldTypeUpdate) ClearDecimal() *FieldTypeUpdate
ClearDecimal clears the value of decimal.
func (*FieldTypeUpdate) ClearDeleted ¶
func (ftu *FieldTypeUpdate) ClearDeleted() *FieldTypeUpdate
ClearDeleted clears the value of deleted.
func (*FieldTypeUpdate) ClearDeletedAt ¶
func (ftu *FieldTypeUpdate) ClearDeletedAt() *FieldTypeUpdate
ClearDeletedAt clears the value of deleted_at.
func (*FieldTypeUpdate) ClearDir ¶
func (ftu *FieldTypeUpdate) ClearDir() *FieldTypeUpdate
ClearDir clears the value of dir.
func (*FieldTypeUpdate) ClearIP ¶
func (ftu *FieldTypeUpdate) ClearIP() *FieldTypeUpdate
ClearIP clears the value of ip.
func (*FieldTypeUpdate) ClearLink ¶
func (ftu *FieldTypeUpdate) ClearLink() *FieldTypeUpdate
ClearLink clears the value of link.
func (*FieldTypeUpdate) ClearNdir ¶
func (ftu *FieldTypeUpdate) ClearNdir() *FieldTypeUpdate
ClearNdir clears the value of ndir.
func (*FieldTypeUpdate) ClearNillableInt ¶
func (ftu *FieldTypeUpdate) ClearNillableInt() *FieldTypeUpdate
ClearNillableInt clears the value of nillable_int.
func (*FieldTypeUpdate) ClearNillableInt16 ¶
func (ftu *FieldTypeUpdate) ClearNillableInt16() *FieldTypeUpdate
ClearNillableInt16 clears the value of nillable_int16.
func (*FieldTypeUpdate) ClearNillableInt32 ¶
func (ftu *FieldTypeUpdate) ClearNillableInt32() *FieldTypeUpdate
ClearNillableInt32 clears the value of nillable_int32.
func (*FieldTypeUpdate) ClearNillableInt64 ¶
func (ftu *FieldTypeUpdate) ClearNillableInt64() *FieldTypeUpdate
ClearNillableInt64 clears the value of nillable_int64.
func (*FieldTypeUpdate) ClearNillableInt8 ¶
func (ftu *FieldTypeUpdate) ClearNillableInt8() *FieldTypeUpdate
ClearNillableInt8 clears the value of nillable_int8.
func (*FieldTypeUpdate) ClearNullActive ¶
func (ftu *FieldTypeUpdate) ClearNullActive() *FieldTypeUpdate
ClearNullActive clears the value of null_active.
func (*FieldTypeUpdate) ClearNullFloat ¶
func (ftu *FieldTypeUpdate) ClearNullFloat() *FieldTypeUpdate
ClearNullFloat clears the value of null_float.
func (*FieldTypeUpdate) ClearNullInt64 ¶
func (ftu *FieldTypeUpdate) ClearNullInt64() *FieldTypeUpdate
ClearNullInt64 clears the value of null_int64.
func (*FieldTypeUpdate) ClearNullLink ¶
func (ftu *FieldTypeUpdate) ClearNullLink() *FieldTypeUpdate
ClearNullLink clears the value of null_link.
func (*FieldTypeUpdate) ClearNullStr ¶
func (ftu *FieldTypeUpdate) ClearNullStr() *FieldTypeUpdate
ClearNullStr clears the value of null_str.
func (*FieldTypeUpdate) ClearOptionalFloat ¶
func (ftu *FieldTypeUpdate) ClearOptionalFloat() *FieldTypeUpdate
ClearOptionalFloat clears the value of optional_float.
func (*FieldTypeUpdate) ClearOptionalFloat32 ¶
func (ftu *FieldTypeUpdate) ClearOptionalFloat32() *FieldTypeUpdate
ClearOptionalFloat32 clears the value of optional_float32.
func (*FieldTypeUpdate) ClearOptionalInt ¶
func (ftu *FieldTypeUpdate) ClearOptionalInt() *FieldTypeUpdate
ClearOptionalInt clears the value of optional_int.
func (*FieldTypeUpdate) ClearOptionalInt16 ¶
func (ftu *FieldTypeUpdate) ClearOptionalInt16() *FieldTypeUpdate
ClearOptionalInt16 clears the value of optional_int16.
func (*FieldTypeUpdate) ClearOptionalInt32 ¶
func (ftu *FieldTypeUpdate) ClearOptionalInt32() *FieldTypeUpdate
ClearOptionalInt32 clears the value of optional_int32.
func (*FieldTypeUpdate) ClearOptionalInt64 ¶
func (ftu *FieldTypeUpdate) ClearOptionalInt64() *FieldTypeUpdate
ClearOptionalInt64 clears the value of optional_int64.
func (*FieldTypeUpdate) ClearOptionalInt8 ¶
func (ftu *FieldTypeUpdate) ClearOptionalInt8() *FieldTypeUpdate
ClearOptionalInt8 clears the value of optional_int8.
func (*FieldTypeUpdate) ClearOptionalUint ¶
func (ftu *FieldTypeUpdate) ClearOptionalUint() *FieldTypeUpdate
ClearOptionalUint clears the value of optional_uint.
func (*FieldTypeUpdate) ClearOptionalUint16 ¶
func (ftu *FieldTypeUpdate) ClearOptionalUint16() *FieldTypeUpdate
ClearOptionalUint16 clears the value of optional_uint16.
func (*FieldTypeUpdate) ClearOptionalUint32 ¶
func (ftu *FieldTypeUpdate) ClearOptionalUint32() *FieldTypeUpdate
ClearOptionalUint32 clears the value of optional_uint32.
func (*FieldTypeUpdate) ClearOptionalUint64 ¶
func (ftu *FieldTypeUpdate) ClearOptionalUint64() *FieldTypeUpdate
ClearOptionalUint64 clears the value of optional_uint64.
func (*FieldTypeUpdate) ClearOptionalUint8 ¶
func (ftu *FieldTypeUpdate) ClearOptionalUint8() *FieldTypeUpdate
ClearOptionalUint8 clears the value of optional_uint8.
func (*FieldTypeUpdate) ClearSchemaFloat ¶
func (ftu *FieldTypeUpdate) ClearSchemaFloat() *FieldTypeUpdate
ClearSchemaFloat clears the value of schema_float.
func (*FieldTypeUpdate) ClearSchemaFloat32 ¶
func (ftu *FieldTypeUpdate) ClearSchemaFloat32() *FieldTypeUpdate
ClearSchemaFloat32 clears the value of schema_float32.
func (*FieldTypeUpdate) ClearSchemaInt ¶
func (ftu *FieldTypeUpdate) ClearSchemaInt() *FieldTypeUpdate
ClearSchemaInt clears the value of schema_int.
func (*FieldTypeUpdate) ClearSchemaInt64 ¶
func (ftu *FieldTypeUpdate) ClearSchemaInt64() *FieldTypeUpdate
ClearSchemaInt64 clears the value of schema_int64.
func (*FieldTypeUpdate) ClearSchemaInt8 ¶
func (ftu *FieldTypeUpdate) ClearSchemaInt8() *FieldTypeUpdate
ClearSchemaInt8 clears the value of schema_int8.
func (*FieldTypeUpdate) ClearState ¶
func (ftu *FieldTypeUpdate) ClearState() *FieldTypeUpdate
ClearState clears the value of state.
func (*FieldTypeUpdate) ClearStr ¶
func (ftu *FieldTypeUpdate) ClearStr() *FieldTypeUpdate
ClearStr clears the value of str.
func (*FieldTypeUpdate) ClearValidateOptionalInt32 ¶
func (ftu *FieldTypeUpdate) ClearValidateOptionalInt32() *FieldTypeUpdate
ClearValidateOptionalInt32 clears the value of validate_optional_int32.
func (*FieldTypeUpdate) Exec ¶
func (ftu *FieldTypeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*FieldTypeUpdate) ExecX ¶
func (ftu *FieldTypeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FieldTypeUpdate) Mutation ¶
func (ftu *FieldTypeUpdate) Mutation() *FieldTypeMutation
Mutation returns the FieldTypeMutation object of the builder.
func (*FieldTypeUpdate) Save ¶
func (ftu *FieldTypeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*FieldTypeUpdate) SaveX ¶
func (ftu *FieldTypeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*FieldTypeUpdate) SetActive ¶
func (ftu *FieldTypeUpdate) SetActive(s schema.Status) *FieldTypeUpdate
SetActive sets the active field.
func (*FieldTypeUpdate) SetDatetime ¶
func (ftu *FieldTypeUpdate) SetDatetime(t time.Time) *FieldTypeUpdate
SetDatetime sets the datetime field.
func (*FieldTypeUpdate) SetDecimal ¶
func (ftu *FieldTypeUpdate) SetDecimal(f float64) *FieldTypeUpdate
SetDecimal sets the decimal field.
func (*FieldTypeUpdate) SetDeleted ¶
func (ftu *FieldTypeUpdate) SetDeleted(sb sql.NullBool) *FieldTypeUpdate
SetDeleted sets the deleted field.
func (*FieldTypeUpdate) SetDeletedAt ¶
func (ftu *FieldTypeUpdate) SetDeletedAt(st sql.NullTime) *FieldTypeUpdate
SetDeletedAt sets the deleted_at field.
func (*FieldTypeUpdate) SetDir ¶
func (ftu *FieldTypeUpdate) SetDir(h http.Dir) *FieldTypeUpdate
SetDir sets the dir field.
func (*FieldTypeUpdate) SetIP ¶
func (ftu *FieldTypeUpdate) SetIP(n net.IP) *FieldTypeUpdate
SetIP sets the ip field.
func (*FieldTypeUpdate) SetInt ¶
func (ftu *FieldTypeUpdate) SetInt(i int) *FieldTypeUpdate
SetInt sets the int field.
func (*FieldTypeUpdate) SetInt16 ¶
func (ftu *FieldTypeUpdate) SetInt16(i int16) *FieldTypeUpdate
SetInt16 sets the int16 field.
func (*FieldTypeUpdate) SetInt32 ¶
func (ftu *FieldTypeUpdate) SetInt32(i int32) *FieldTypeUpdate
SetInt32 sets the int32 field.
func (*FieldTypeUpdate) SetInt64 ¶
func (ftu *FieldTypeUpdate) SetInt64(i int64) *FieldTypeUpdate
SetInt64 sets the int64 field.
func (*FieldTypeUpdate) SetInt8 ¶
func (ftu *FieldTypeUpdate) SetInt8(i int8) *FieldTypeUpdate
SetInt8 sets the int8 field.
func (*FieldTypeUpdate) SetLink ¶
func (ftu *FieldTypeUpdate) SetLink(s schema.Link) *FieldTypeUpdate
SetLink sets the link field.
func (*FieldTypeUpdate) SetNdir ¶
func (ftu *FieldTypeUpdate) SetNdir(h http.Dir) *FieldTypeUpdate
SetNdir sets the ndir field.
func (*FieldTypeUpdate) SetNillableActive ¶
func (ftu *FieldTypeUpdate) SetNillableActive(s *schema.Status) *FieldTypeUpdate
SetNillableActive sets the active field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableDatetime ¶
func (ftu *FieldTypeUpdate) SetNillableDatetime(t *time.Time) *FieldTypeUpdate
SetNillableDatetime sets the datetime field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableDecimal ¶
func (ftu *FieldTypeUpdate) SetNillableDecimal(f *float64) *FieldTypeUpdate
SetNillableDecimal sets the decimal field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableDir ¶
func (ftu *FieldTypeUpdate) SetNillableDir(h *http.Dir) *FieldTypeUpdate
SetNillableDir sets the dir field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableInt ¶
func (ftu *FieldTypeUpdate) SetNillableInt(i int) *FieldTypeUpdate
SetNillableInt sets the nillable_int field.
func (*FieldTypeUpdate) SetNillableInt16 ¶
func (ftu *FieldTypeUpdate) SetNillableInt16(i int16) *FieldTypeUpdate
SetNillableInt16 sets the nillable_int16 field.
func (*FieldTypeUpdate) SetNillableInt32 ¶
func (ftu *FieldTypeUpdate) SetNillableInt32(i int32) *FieldTypeUpdate
SetNillableInt32 sets the nillable_int32 field.
func (*FieldTypeUpdate) SetNillableInt64 ¶
func (ftu *FieldTypeUpdate) SetNillableInt64(i int64) *FieldTypeUpdate
SetNillableInt64 sets the nillable_int64 field.
func (*FieldTypeUpdate) SetNillableInt8 ¶
func (ftu *FieldTypeUpdate) SetNillableInt8(i int8) *FieldTypeUpdate
SetNillableInt8 sets the nillable_int8 field.
func (*FieldTypeUpdate) SetNillableNdir ¶
func (ftu *FieldTypeUpdate) SetNillableNdir(h *http.Dir) *FieldTypeUpdate
SetNillableNdir sets the ndir field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableNillableInt ¶
func (ftu *FieldTypeUpdate) SetNillableNillableInt(i *int) *FieldTypeUpdate
SetNillableNillableInt sets the nillable_int field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableNillableInt16 ¶
func (ftu *FieldTypeUpdate) SetNillableNillableInt16(i *int16) *FieldTypeUpdate
SetNillableNillableInt16 sets the nillable_int16 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableNillableInt32 ¶
func (ftu *FieldTypeUpdate) SetNillableNillableInt32(i *int32) *FieldTypeUpdate
SetNillableNillableInt32 sets the nillable_int32 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableNillableInt64 ¶
func (ftu *FieldTypeUpdate) SetNillableNillableInt64(i *int64) *FieldTypeUpdate
SetNillableNillableInt64 sets the nillable_int64 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableNillableInt8 ¶
func (ftu *FieldTypeUpdate) SetNillableNillableInt8(i *int8) *FieldTypeUpdate
SetNillableNillableInt8 sets the nillable_int8 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableNullActive ¶
func (ftu *FieldTypeUpdate) SetNillableNullActive(s *schema.Status) *FieldTypeUpdate
SetNillableNullActive sets the null_active field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalFloat ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalFloat(f *float64) *FieldTypeUpdate
SetNillableOptionalFloat sets the optional_float field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalFloat32 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalFloat32(f *float32) *FieldTypeUpdate
SetNillableOptionalFloat32 sets the optional_float32 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalInt ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalInt(i *int) *FieldTypeUpdate
SetNillableOptionalInt sets the optional_int field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalInt16 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalInt16(i *int16) *FieldTypeUpdate
SetNillableOptionalInt16 sets the optional_int16 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalInt32 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalInt32(i *int32) *FieldTypeUpdate
SetNillableOptionalInt32 sets the optional_int32 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalInt64 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalInt64(i *int64) *FieldTypeUpdate
SetNillableOptionalInt64 sets the optional_int64 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalInt8 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalInt8(i *int8) *FieldTypeUpdate
SetNillableOptionalInt8 sets the optional_int8 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalUint ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalUint(u *uint) *FieldTypeUpdate
SetNillableOptionalUint sets the optional_uint field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalUint16 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalUint16(u *uint16) *FieldTypeUpdate
SetNillableOptionalUint16 sets the optional_uint16 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalUint32 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalUint32(u *uint32) *FieldTypeUpdate
SetNillableOptionalUint32 sets the optional_uint32 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalUint64 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalUint64(u *uint64) *FieldTypeUpdate
SetNillableOptionalUint64 sets the optional_uint64 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableOptionalUint8 ¶
func (ftu *FieldTypeUpdate) SetNillableOptionalUint8(u *uint8) *FieldTypeUpdate
SetNillableOptionalUint8 sets the optional_uint8 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableRole ¶
func (ftu *FieldTypeUpdate) SetNillableRole(r *role.Role) *FieldTypeUpdate
SetNillableRole sets the role field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableSchemaFloat ¶
func (ftu *FieldTypeUpdate) SetNillableSchemaFloat(s *schema.Float64) *FieldTypeUpdate
SetNillableSchemaFloat sets the schema_float field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableSchemaFloat32 ¶
func (ftu *FieldTypeUpdate) SetNillableSchemaFloat32(s *schema.Float32) *FieldTypeUpdate
SetNillableSchemaFloat32 sets the schema_float32 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableSchemaInt ¶
func (ftu *FieldTypeUpdate) SetNillableSchemaInt(s *schema.Int) *FieldTypeUpdate
SetNillableSchemaInt sets the schema_int field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableSchemaInt64 ¶
func (ftu *FieldTypeUpdate) SetNillableSchemaInt64(s *schema.Int64) *FieldTypeUpdate
SetNillableSchemaInt64 sets the schema_int64 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableSchemaInt8 ¶
func (ftu *FieldTypeUpdate) SetNillableSchemaInt8(s *schema.Int8) *FieldTypeUpdate
SetNillableSchemaInt8 sets the schema_int8 field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableState ¶
func (ftu *FieldTypeUpdate) SetNillableState(f *fieldtype.State) *FieldTypeUpdate
SetNillableState sets the state field if the given value is not nil.
func (*FieldTypeUpdate) SetNillableValidateOptionalInt32 ¶
func (ftu *FieldTypeUpdate) SetNillableValidateOptionalInt32(i *int32) *FieldTypeUpdate
SetNillableValidateOptionalInt32 sets the validate_optional_int32 field if the given value is not nil.
func (*FieldTypeUpdate) SetNullActive ¶
func (ftu *FieldTypeUpdate) SetNullActive(s schema.Status) *FieldTypeUpdate
SetNullActive sets the null_active field.
func (*FieldTypeUpdate) SetNullFloat ¶
func (ftu *FieldTypeUpdate) SetNullFloat(sf sql.NullFloat64) *FieldTypeUpdate
SetNullFloat sets the null_float field.
func (*FieldTypeUpdate) SetNullInt64 ¶
func (ftu *FieldTypeUpdate) SetNullInt64(si sql.NullInt64) *FieldTypeUpdate
SetNullInt64 sets the null_int64 field.
func (*FieldTypeUpdate) SetNullLink ¶
func (ftu *FieldTypeUpdate) SetNullLink(s schema.Link) *FieldTypeUpdate
SetNullLink sets the null_link field.
func (*FieldTypeUpdate) SetNullStr ¶
func (ftu *FieldTypeUpdate) SetNullStr(ss sql.NullString) *FieldTypeUpdate
SetNullStr sets the null_str field.
func (*FieldTypeUpdate) SetOptionalFloat ¶
func (ftu *FieldTypeUpdate) SetOptionalFloat(f float64) *FieldTypeUpdate
SetOptionalFloat sets the optional_float field.
func (*FieldTypeUpdate) SetOptionalFloat32 ¶
func (ftu *FieldTypeUpdate) SetOptionalFloat32(f float32) *FieldTypeUpdate
SetOptionalFloat32 sets the optional_float32 field.
func (*FieldTypeUpdate) SetOptionalInt ¶
func (ftu *FieldTypeUpdate) SetOptionalInt(i int) *FieldTypeUpdate
SetOptionalInt sets the optional_int field.
func (*FieldTypeUpdate) SetOptionalInt16 ¶
func (ftu *FieldTypeUpdate) SetOptionalInt16(i int16) *FieldTypeUpdate
SetOptionalInt16 sets the optional_int16 field.
func (*FieldTypeUpdate) SetOptionalInt32 ¶
func (ftu *FieldTypeUpdate) SetOptionalInt32(i int32) *FieldTypeUpdate
SetOptionalInt32 sets the optional_int32 field.
func (*FieldTypeUpdate) SetOptionalInt64 ¶
func (ftu *FieldTypeUpdate) SetOptionalInt64(i int64) *FieldTypeUpdate
SetOptionalInt64 sets the optional_int64 field.
func (*FieldTypeUpdate) SetOptionalInt8 ¶
func (ftu *FieldTypeUpdate) SetOptionalInt8(i int8) *FieldTypeUpdate
SetOptionalInt8 sets the optional_int8 field.
func (*FieldTypeUpdate) SetOptionalUint ¶
func (ftu *FieldTypeUpdate) SetOptionalUint(u uint) *FieldTypeUpdate
SetOptionalUint sets the optional_uint field.
func (*FieldTypeUpdate) SetOptionalUint16 ¶
func (ftu *FieldTypeUpdate) SetOptionalUint16(u uint16) *FieldTypeUpdate
SetOptionalUint16 sets the optional_uint16 field.
func (*FieldTypeUpdate) SetOptionalUint32 ¶
func (ftu *FieldTypeUpdate) SetOptionalUint32(u uint32) *FieldTypeUpdate
SetOptionalUint32 sets the optional_uint32 field.
func (*FieldTypeUpdate) SetOptionalUint64 ¶
func (ftu *FieldTypeUpdate) SetOptionalUint64(u uint64) *FieldTypeUpdate
SetOptionalUint64 sets the optional_uint64 field.
func (*FieldTypeUpdate) SetOptionalUint8 ¶
func (ftu *FieldTypeUpdate) SetOptionalUint8(u uint8) *FieldTypeUpdate
SetOptionalUint8 sets the optional_uint8 field.
func (*FieldTypeUpdate) SetRole ¶
func (ftu *FieldTypeUpdate) SetRole(r role.Role) *FieldTypeUpdate
SetRole sets the role field.
func (*FieldTypeUpdate) SetSchemaFloat ¶
func (ftu *FieldTypeUpdate) SetSchemaFloat(s schema.Float64) *FieldTypeUpdate
SetSchemaFloat sets the schema_float field.
func (*FieldTypeUpdate) SetSchemaFloat32 ¶
func (ftu *FieldTypeUpdate) SetSchemaFloat32(s schema.Float32) *FieldTypeUpdate
SetSchemaFloat32 sets the schema_float32 field.
func (*FieldTypeUpdate) SetSchemaInt ¶
func (ftu *FieldTypeUpdate) SetSchemaInt(s schema.Int) *FieldTypeUpdate
SetSchemaInt sets the schema_int field.
func (*FieldTypeUpdate) SetSchemaInt64 ¶
func (ftu *FieldTypeUpdate) SetSchemaInt64(s schema.Int64) *FieldTypeUpdate
SetSchemaInt64 sets the schema_int64 field.
func (*FieldTypeUpdate) SetSchemaInt8 ¶
func (ftu *FieldTypeUpdate) SetSchemaInt8(s schema.Int8) *FieldTypeUpdate
SetSchemaInt8 sets the schema_int8 field.
func (*FieldTypeUpdate) SetState ¶
func (ftu *FieldTypeUpdate) SetState(f fieldtype.State) *FieldTypeUpdate
SetState sets the state field.
func (*FieldTypeUpdate) SetStr ¶
func (ftu *FieldTypeUpdate) SetStr(ss sql.NullString) *FieldTypeUpdate
SetStr sets the str field.
func (*FieldTypeUpdate) SetValidateOptionalInt32 ¶
func (ftu *FieldTypeUpdate) SetValidateOptionalInt32(i int32) *FieldTypeUpdate
SetValidateOptionalInt32 sets the validate_optional_int32 field.
func (*FieldTypeUpdate) Where ¶
func (ftu *FieldTypeUpdate) Where(ps ...predicate.FieldType) *FieldTypeUpdate
Where adds a new predicate for the builder.
type FieldTypeUpdateOne ¶
type FieldTypeUpdateOne struct {
// contains filtered or unexported fields
}
FieldTypeUpdateOne is the builder for updating a single FieldType entity.
func (*FieldTypeUpdateOne) AddDecimal ¶
func (ftuo *FieldTypeUpdateOne) AddDecimal(f float64) *FieldTypeUpdateOne
AddDecimal adds f to decimal.
func (*FieldTypeUpdateOne) AddInt ¶
func (ftuo *FieldTypeUpdateOne) AddInt(i int) *FieldTypeUpdateOne
AddInt adds i to int.
func (*FieldTypeUpdateOne) AddInt16 ¶
func (ftuo *FieldTypeUpdateOne) AddInt16(i int16) *FieldTypeUpdateOne
AddInt16 adds i to int16.
func (*FieldTypeUpdateOne) AddInt32 ¶
func (ftuo *FieldTypeUpdateOne) AddInt32(i int32) *FieldTypeUpdateOne
AddInt32 adds i to int32.
func (*FieldTypeUpdateOne) AddInt64 ¶
func (ftuo *FieldTypeUpdateOne) AddInt64(i int64) *FieldTypeUpdateOne
AddInt64 adds i to int64.
func (*FieldTypeUpdateOne) AddInt8 ¶
func (ftuo *FieldTypeUpdateOne) AddInt8(i int8) *FieldTypeUpdateOne
AddInt8 adds i to int8.
func (*FieldTypeUpdateOne) AddNillableInt ¶
func (ftuo *FieldTypeUpdateOne) AddNillableInt(i int) *FieldTypeUpdateOne
AddNillableInt adds i to nillable_int.
func (*FieldTypeUpdateOne) AddNillableInt16 ¶
func (ftuo *FieldTypeUpdateOne) AddNillableInt16(i int16) *FieldTypeUpdateOne
AddNillableInt16 adds i to nillable_int16.
func (*FieldTypeUpdateOne) AddNillableInt32 ¶
func (ftuo *FieldTypeUpdateOne) AddNillableInt32(i int32) *FieldTypeUpdateOne
AddNillableInt32 adds i to nillable_int32.
func (*FieldTypeUpdateOne) AddNillableInt64 ¶
func (ftuo *FieldTypeUpdateOne) AddNillableInt64(i int64) *FieldTypeUpdateOne
AddNillableInt64 adds i to nillable_int64.
func (*FieldTypeUpdateOne) AddNillableInt8 ¶
func (ftuo *FieldTypeUpdateOne) AddNillableInt8(i int8) *FieldTypeUpdateOne
AddNillableInt8 adds i to nillable_int8.
func (*FieldTypeUpdateOne) AddOptionalFloat ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalFloat(f float64) *FieldTypeUpdateOne
AddOptionalFloat adds f to optional_float.
func (*FieldTypeUpdateOne) AddOptionalFloat32 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalFloat32(f float32) *FieldTypeUpdateOne
AddOptionalFloat32 adds f to optional_float32.
func (*FieldTypeUpdateOne) AddOptionalInt ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalInt(i int) *FieldTypeUpdateOne
AddOptionalInt adds i to optional_int.
func (*FieldTypeUpdateOne) AddOptionalInt16 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalInt16(i int16) *FieldTypeUpdateOne
AddOptionalInt16 adds i to optional_int16.
func (*FieldTypeUpdateOne) AddOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalInt32(i int32) *FieldTypeUpdateOne
AddOptionalInt32 adds i to optional_int32.
func (*FieldTypeUpdateOne) AddOptionalInt64 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalInt64(i int64) *FieldTypeUpdateOne
AddOptionalInt64 adds i to optional_int64.
func (*FieldTypeUpdateOne) AddOptionalInt8 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalInt8(i int8) *FieldTypeUpdateOne
AddOptionalInt8 adds i to optional_int8.
func (*FieldTypeUpdateOne) AddOptionalUint ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalUint(u uint) *FieldTypeUpdateOne
AddOptionalUint adds u to optional_uint.
func (*FieldTypeUpdateOne) AddOptionalUint16 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalUint16(u uint16) *FieldTypeUpdateOne
AddOptionalUint16 adds u to optional_uint16.
func (*FieldTypeUpdateOne) AddOptionalUint32 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalUint32(u uint32) *FieldTypeUpdateOne
AddOptionalUint32 adds u to optional_uint32.
func (*FieldTypeUpdateOne) AddOptionalUint64 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalUint64(u uint64) *FieldTypeUpdateOne
AddOptionalUint64 adds u to optional_uint64.
func (*FieldTypeUpdateOne) AddOptionalUint8 ¶
func (ftuo *FieldTypeUpdateOne) AddOptionalUint8(u uint8) *FieldTypeUpdateOne
AddOptionalUint8 adds u to optional_uint8.
func (*FieldTypeUpdateOne) AddSchemaFloat ¶
func (ftuo *FieldTypeUpdateOne) AddSchemaFloat(s schema.Float64) *FieldTypeUpdateOne
AddSchemaFloat adds s to schema_float.
func (*FieldTypeUpdateOne) AddSchemaFloat32 ¶
func (ftuo *FieldTypeUpdateOne) AddSchemaFloat32(s schema.Float32) *FieldTypeUpdateOne
AddSchemaFloat32 adds s to schema_float32.
func (*FieldTypeUpdateOne) AddSchemaInt ¶
func (ftuo *FieldTypeUpdateOne) AddSchemaInt(s schema.Int) *FieldTypeUpdateOne
AddSchemaInt adds s to schema_int.
func (*FieldTypeUpdateOne) AddSchemaInt64 ¶
func (ftuo *FieldTypeUpdateOne) AddSchemaInt64(s schema.Int64) *FieldTypeUpdateOne
AddSchemaInt64 adds s to schema_int64.
func (*FieldTypeUpdateOne) AddSchemaInt8 ¶
func (ftuo *FieldTypeUpdateOne) AddSchemaInt8(s schema.Int8) *FieldTypeUpdateOne
AddSchemaInt8 adds s to schema_int8.
func (*FieldTypeUpdateOne) AddValidateOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) AddValidateOptionalInt32(i int32) *FieldTypeUpdateOne
AddValidateOptionalInt32 adds i to validate_optional_int32.
func (*FieldTypeUpdateOne) ClearActive ¶
func (ftuo *FieldTypeUpdateOne) ClearActive() *FieldTypeUpdateOne
ClearActive clears the value of active.
func (*FieldTypeUpdateOne) ClearDatetime ¶
func (ftuo *FieldTypeUpdateOne) ClearDatetime() *FieldTypeUpdateOne
ClearDatetime clears the value of datetime.
func (*FieldTypeUpdateOne) ClearDecimal ¶
func (ftuo *FieldTypeUpdateOne) ClearDecimal() *FieldTypeUpdateOne
ClearDecimal clears the value of decimal.
func (*FieldTypeUpdateOne) ClearDeleted ¶
func (ftuo *FieldTypeUpdateOne) ClearDeleted() *FieldTypeUpdateOne
ClearDeleted clears the value of deleted.
func (*FieldTypeUpdateOne) ClearDeletedAt ¶
func (ftuo *FieldTypeUpdateOne) ClearDeletedAt() *FieldTypeUpdateOne
ClearDeletedAt clears the value of deleted_at.
func (*FieldTypeUpdateOne) ClearDir ¶
func (ftuo *FieldTypeUpdateOne) ClearDir() *FieldTypeUpdateOne
ClearDir clears the value of dir.
func (*FieldTypeUpdateOne) ClearIP ¶
func (ftuo *FieldTypeUpdateOne) ClearIP() *FieldTypeUpdateOne
ClearIP clears the value of ip.
func (*FieldTypeUpdateOne) ClearLink ¶
func (ftuo *FieldTypeUpdateOne) ClearLink() *FieldTypeUpdateOne
ClearLink clears the value of link.
func (*FieldTypeUpdateOne) ClearNdir ¶
func (ftuo *FieldTypeUpdateOne) ClearNdir() *FieldTypeUpdateOne
ClearNdir clears the value of ndir.
func (*FieldTypeUpdateOne) ClearNillableInt ¶
func (ftuo *FieldTypeUpdateOne) ClearNillableInt() *FieldTypeUpdateOne
ClearNillableInt clears the value of nillable_int.
func (*FieldTypeUpdateOne) ClearNillableInt16 ¶
func (ftuo *FieldTypeUpdateOne) ClearNillableInt16() *FieldTypeUpdateOne
ClearNillableInt16 clears the value of nillable_int16.
func (*FieldTypeUpdateOne) ClearNillableInt32 ¶
func (ftuo *FieldTypeUpdateOne) ClearNillableInt32() *FieldTypeUpdateOne
ClearNillableInt32 clears the value of nillable_int32.
func (*FieldTypeUpdateOne) ClearNillableInt64 ¶
func (ftuo *FieldTypeUpdateOne) ClearNillableInt64() *FieldTypeUpdateOne
ClearNillableInt64 clears the value of nillable_int64.
func (*FieldTypeUpdateOne) ClearNillableInt8 ¶
func (ftuo *FieldTypeUpdateOne) ClearNillableInt8() *FieldTypeUpdateOne
ClearNillableInt8 clears the value of nillable_int8.
func (*FieldTypeUpdateOne) ClearNullActive ¶
func (ftuo *FieldTypeUpdateOne) ClearNullActive() *FieldTypeUpdateOne
ClearNullActive clears the value of null_active.
func (*FieldTypeUpdateOne) ClearNullFloat ¶
func (ftuo *FieldTypeUpdateOne) ClearNullFloat() *FieldTypeUpdateOne
ClearNullFloat clears the value of null_float.
func (*FieldTypeUpdateOne) ClearNullInt64 ¶
func (ftuo *FieldTypeUpdateOne) ClearNullInt64() *FieldTypeUpdateOne
ClearNullInt64 clears the value of null_int64.
func (*FieldTypeUpdateOne) ClearNullLink ¶
func (ftuo *FieldTypeUpdateOne) ClearNullLink() *FieldTypeUpdateOne
ClearNullLink clears the value of null_link.
func (*FieldTypeUpdateOne) ClearNullStr ¶
func (ftuo *FieldTypeUpdateOne) ClearNullStr() *FieldTypeUpdateOne
ClearNullStr clears the value of null_str.
func (*FieldTypeUpdateOne) ClearOptionalFloat ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalFloat() *FieldTypeUpdateOne
ClearOptionalFloat clears the value of optional_float.
func (*FieldTypeUpdateOne) ClearOptionalFloat32 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalFloat32() *FieldTypeUpdateOne
ClearOptionalFloat32 clears the value of optional_float32.
func (*FieldTypeUpdateOne) ClearOptionalInt ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalInt() *FieldTypeUpdateOne
ClearOptionalInt clears the value of optional_int.
func (*FieldTypeUpdateOne) ClearOptionalInt16 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalInt16() *FieldTypeUpdateOne
ClearOptionalInt16 clears the value of optional_int16.
func (*FieldTypeUpdateOne) ClearOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalInt32() *FieldTypeUpdateOne
ClearOptionalInt32 clears the value of optional_int32.
func (*FieldTypeUpdateOne) ClearOptionalInt64 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalInt64() *FieldTypeUpdateOne
ClearOptionalInt64 clears the value of optional_int64.
func (*FieldTypeUpdateOne) ClearOptionalInt8 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalInt8() *FieldTypeUpdateOne
ClearOptionalInt8 clears the value of optional_int8.
func (*FieldTypeUpdateOne) ClearOptionalUint ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalUint() *FieldTypeUpdateOne
ClearOptionalUint clears the value of optional_uint.
func (*FieldTypeUpdateOne) ClearOptionalUint16 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalUint16() *FieldTypeUpdateOne
ClearOptionalUint16 clears the value of optional_uint16.
func (*FieldTypeUpdateOne) ClearOptionalUint32 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalUint32() *FieldTypeUpdateOne
ClearOptionalUint32 clears the value of optional_uint32.
func (*FieldTypeUpdateOne) ClearOptionalUint64 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalUint64() *FieldTypeUpdateOne
ClearOptionalUint64 clears the value of optional_uint64.
func (*FieldTypeUpdateOne) ClearOptionalUint8 ¶
func (ftuo *FieldTypeUpdateOne) ClearOptionalUint8() *FieldTypeUpdateOne
ClearOptionalUint8 clears the value of optional_uint8.
func (*FieldTypeUpdateOne) ClearSchemaFloat ¶
func (ftuo *FieldTypeUpdateOne) ClearSchemaFloat() *FieldTypeUpdateOne
ClearSchemaFloat clears the value of schema_float.
func (*FieldTypeUpdateOne) ClearSchemaFloat32 ¶
func (ftuo *FieldTypeUpdateOne) ClearSchemaFloat32() *FieldTypeUpdateOne
ClearSchemaFloat32 clears the value of schema_float32.
func (*FieldTypeUpdateOne) ClearSchemaInt ¶
func (ftuo *FieldTypeUpdateOne) ClearSchemaInt() *FieldTypeUpdateOne
ClearSchemaInt clears the value of schema_int.
func (*FieldTypeUpdateOne) ClearSchemaInt64 ¶
func (ftuo *FieldTypeUpdateOne) ClearSchemaInt64() *FieldTypeUpdateOne
ClearSchemaInt64 clears the value of schema_int64.
func (*FieldTypeUpdateOne) ClearSchemaInt8 ¶
func (ftuo *FieldTypeUpdateOne) ClearSchemaInt8() *FieldTypeUpdateOne
ClearSchemaInt8 clears the value of schema_int8.
func (*FieldTypeUpdateOne) ClearState ¶
func (ftuo *FieldTypeUpdateOne) ClearState() *FieldTypeUpdateOne
ClearState clears the value of state.
func (*FieldTypeUpdateOne) ClearStr ¶
func (ftuo *FieldTypeUpdateOne) ClearStr() *FieldTypeUpdateOne
ClearStr clears the value of str.
func (*FieldTypeUpdateOne) ClearValidateOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) ClearValidateOptionalInt32() *FieldTypeUpdateOne
ClearValidateOptionalInt32 clears the value of validate_optional_int32.
func (*FieldTypeUpdateOne) Exec ¶
func (ftuo *FieldTypeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*FieldTypeUpdateOne) ExecX ¶
func (ftuo *FieldTypeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FieldTypeUpdateOne) Mutation ¶
func (ftuo *FieldTypeUpdateOne) Mutation() *FieldTypeMutation
Mutation returns the FieldTypeMutation object of the builder.
func (*FieldTypeUpdateOne) Save ¶
func (ftuo *FieldTypeUpdateOne) Save(ctx context.Context) (*FieldType, error)
Save executes the query and returns the updated entity.
func (*FieldTypeUpdateOne) SaveX ¶
func (ftuo *FieldTypeUpdateOne) SaveX(ctx context.Context) *FieldType
SaveX is like Save, but panics if an error occurs.
func (*FieldTypeUpdateOne) SetActive ¶
func (ftuo *FieldTypeUpdateOne) SetActive(s schema.Status) *FieldTypeUpdateOne
SetActive sets the active field.
func (*FieldTypeUpdateOne) SetDatetime ¶
func (ftuo *FieldTypeUpdateOne) SetDatetime(t time.Time) *FieldTypeUpdateOne
SetDatetime sets the datetime field.
func (*FieldTypeUpdateOne) SetDecimal ¶
func (ftuo *FieldTypeUpdateOne) SetDecimal(f float64) *FieldTypeUpdateOne
SetDecimal sets the decimal field.
func (*FieldTypeUpdateOne) SetDeleted ¶
func (ftuo *FieldTypeUpdateOne) SetDeleted(sb sql.NullBool) *FieldTypeUpdateOne
SetDeleted sets the deleted field.
func (*FieldTypeUpdateOne) SetDeletedAt ¶
func (ftuo *FieldTypeUpdateOne) SetDeletedAt(st sql.NullTime) *FieldTypeUpdateOne
SetDeletedAt sets the deleted_at field.
func (*FieldTypeUpdateOne) SetDir ¶
func (ftuo *FieldTypeUpdateOne) SetDir(h http.Dir) *FieldTypeUpdateOne
SetDir sets the dir field.
func (*FieldTypeUpdateOne) SetIP ¶
func (ftuo *FieldTypeUpdateOne) SetIP(n net.IP) *FieldTypeUpdateOne
SetIP sets the ip field.
func (*FieldTypeUpdateOne) SetInt ¶
func (ftuo *FieldTypeUpdateOne) SetInt(i int) *FieldTypeUpdateOne
SetInt sets the int field.
func (*FieldTypeUpdateOne) SetInt16 ¶
func (ftuo *FieldTypeUpdateOne) SetInt16(i int16) *FieldTypeUpdateOne
SetInt16 sets the int16 field.
func (*FieldTypeUpdateOne) SetInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetInt32(i int32) *FieldTypeUpdateOne
SetInt32 sets the int32 field.
func (*FieldTypeUpdateOne) SetInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetInt64(i int64) *FieldTypeUpdateOne
SetInt64 sets the int64 field.
func (*FieldTypeUpdateOne) SetInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetInt8(i int8) *FieldTypeUpdateOne
SetInt8 sets the int8 field.
func (*FieldTypeUpdateOne) SetLink ¶
func (ftuo *FieldTypeUpdateOne) SetLink(s schema.Link) *FieldTypeUpdateOne
SetLink sets the link field.
func (*FieldTypeUpdateOne) SetNdir ¶
func (ftuo *FieldTypeUpdateOne) SetNdir(h http.Dir) *FieldTypeUpdateOne
SetNdir sets the ndir field.
func (*FieldTypeUpdateOne) SetNillableActive ¶
func (ftuo *FieldTypeUpdateOne) SetNillableActive(s *schema.Status) *FieldTypeUpdateOne
SetNillableActive sets the active field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableDatetime ¶
func (ftuo *FieldTypeUpdateOne) SetNillableDatetime(t *time.Time) *FieldTypeUpdateOne
SetNillableDatetime sets the datetime field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableDecimal ¶
func (ftuo *FieldTypeUpdateOne) SetNillableDecimal(f *float64) *FieldTypeUpdateOne
SetNillableDecimal sets the decimal field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableDir ¶
func (ftuo *FieldTypeUpdateOne) SetNillableDir(h *http.Dir) *FieldTypeUpdateOne
SetNillableDir sets the dir field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableInt ¶
func (ftuo *FieldTypeUpdateOne) SetNillableInt(i int) *FieldTypeUpdateOne
SetNillableInt sets the nillable_int field.
func (*FieldTypeUpdateOne) SetNillableInt16 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableInt16(i int16) *FieldTypeUpdateOne
SetNillableInt16 sets the nillable_int16 field.
func (*FieldTypeUpdateOne) SetNillableInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableInt32(i int32) *FieldTypeUpdateOne
SetNillableInt32 sets the nillable_int32 field.
func (*FieldTypeUpdateOne) SetNillableInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableInt64(i int64) *FieldTypeUpdateOne
SetNillableInt64 sets the nillable_int64 field.
func (*FieldTypeUpdateOne) SetNillableInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableInt8(i int8) *FieldTypeUpdateOne
SetNillableInt8 sets the nillable_int8 field.
func (*FieldTypeUpdateOne) SetNillableNdir ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNdir(h *http.Dir) *FieldTypeUpdateOne
SetNillableNdir sets the ndir field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableNillableInt ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt(i *int) *FieldTypeUpdateOne
SetNillableNillableInt sets the nillable_int field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableNillableInt16 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt16(i *int16) *FieldTypeUpdateOne
SetNillableNillableInt16 sets the nillable_int16 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableNillableInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt32(i *int32) *FieldTypeUpdateOne
SetNillableNillableInt32 sets the nillable_int32 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableNillableInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt64(i *int64) *FieldTypeUpdateOne
SetNillableNillableInt64 sets the nillable_int64 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableNillableInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNillableInt8(i *int8) *FieldTypeUpdateOne
SetNillableNillableInt8 sets the nillable_int8 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableNullActive ¶
func (ftuo *FieldTypeUpdateOne) SetNillableNullActive(s *schema.Status) *FieldTypeUpdateOne
SetNillableNullActive sets the null_active field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalFloat ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalFloat(f *float64) *FieldTypeUpdateOne
SetNillableOptionalFloat sets the optional_float field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalFloat32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalFloat32(f *float32) *FieldTypeUpdateOne
SetNillableOptionalFloat32 sets the optional_float32 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalInt ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt(i *int) *FieldTypeUpdateOne
SetNillableOptionalInt sets the optional_int field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalInt16 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt16(i *int16) *FieldTypeUpdateOne
SetNillableOptionalInt16 sets the optional_int16 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt32(i *int32) *FieldTypeUpdateOne
SetNillableOptionalInt32 sets the optional_int32 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt64(i *int64) *FieldTypeUpdateOne
SetNillableOptionalInt64 sets the optional_int64 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalInt8(i *int8) *FieldTypeUpdateOne
SetNillableOptionalInt8 sets the optional_int8 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalUint ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint(u *uint) *FieldTypeUpdateOne
SetNillableOptionalUint sets the optional_uint field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalUint16 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint16(u *uint16) *FieldTypeUpdateOne
SetNillableOptionalUint16 sets the optional_uint16 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalUint32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint32(u *uint32) *FieldTypeUpdateOne
SetNillableOptionalUint32 sets the optional_uint32 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalUint64 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint64(u *uint64) *FieldTypeUpdateOne
SetNillableOptionalUint64 sets the optional_uint64 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableOptionalUint8 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableOptionalUint8(u *uint8) *FieldTypeUpdateOne
SetNillableOptionalUint8 sets the optional_uint8 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableRole ¶
func (ftuo *FieldTypeUpdateOne) SetNillableRole(r *role.Role) *FieldTypeUpdateOne
SetNillableRole sets the role field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableSchemaFloat ¶
func (ftuo *FieldTypeUpdateOne) SetNillableSchemaFloat(s *schema.Float64) *FieldTypeUpdateOne
SetNillableSchemaFloat sets the schema_float field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableSchemaFloat32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableSchemaFloat32(s *schema.Float32) *FieldTypeUpdateOne
SetNillableSchemaFloat32 sets the schema_float32 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableSchemaInt ¶
func (ftuo *FieldTypeUpdateOne) SetNillableSchemaInt(s *schema.Int) *FieldTypeUpdateOne
SetNillableSchemaInt sets the schema_int field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableSchemaInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableSchemaInt64(s *schema.Int64) *FieldTypeUpdateOne
SetNillableSchemaInt64 sets the schema_int64 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableSchemaInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableSchemaInt8(s *schema.Int8) *FieldTypeUpdateOne
SetNillableSchemaInt8 sets the schema_int8 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableState ¶
func (ftuo *FieldTypeUpdateOne) SetNillableState(f *fieldtype.State) *FieldTypeUpdateOne
SetNillableState sets the state field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNillableValidateOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetNillableValidateOptionalInt32(i *int32) *FieldTypeUpdateOne
SetNillableValidateOptionalInt32 sets the validate_optional_int32 field if the given value is not nil.
func (*FieldTypeUpdateOne) SetNullActive ¶
func (ftuo *FieldTypeUpdateOne) SetNullActive(s schema.Status) *FieldTypeUpdateOne
SetNullActive sets the null_active field.
func (*FieldTypeUpdateOne) SetNullFloat ¶
func (ftuo *FieldTypeUpdateOne) SetNullFloat(sf sql.NullFloat64) *FieldTypeUpdateOne
SetNullFloat sets the null_float field.
func (*FieldTypeUpdateOne) SetNullInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetNullInt64(si sql.NullInt64) *FieldTypeUpdateOne
SetNullInt64 sets the null_int64 field.
func (*FieldTypeUpdateOne) SetNullLink ¶
func (ftuo *FieldTypeUpdateOne) SetNullLink(s schema.Link) *FieldTypeUpdateOne
SetNullLink sets the null_link field.
func (*FieldTypeUpdateOne) SetNullStr ¶
func (ftuo *FieldTypeUpdateOne) SetNullStr(ss sql.NullString) *FieldTypeUpdateOne
SetNullStr sets the null_str field.
func (*FieldTypeUpdateOne) SetOptionalFloat ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalFloat(f float64) *FieldTypeUpdateOne
SetOptionalFloat sets the optional_float field.
func (*FieldTypeUpdateOne) SetOptionalFloat32 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalFloat32(f float32) *FieldTypeUpdateOne
SetOptionalFloat32 sets the optional_float32 field.
func (*FieldTypeUpdateOne) SetOptionalInt ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalInt(i int) *FieldTypeUpdateOne
SetOptionalInt sets the optional_int field.
func (*FieldTypeUpdateOne) SetOptionalInt16 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalInt16(i int16) *FieldTypeUpdateOne
SetOptionalInt16 sets the optional_int16 field.
func (*FieldTypeUpdateOne) SetOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalInt32(i int32) *FieldTypeUpdateOne
SetOptionalInt32 sets the optional_int32 field.
func (*FieldTypeUpdateOne) SetOptionalInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalInt64(i int64) *FieldTypeUpdateOne
SetOptionalInt64 sets the optional_int64 field.
func (*FieldTypeUpdateOne) SetOptionalInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalInt8(i int8) *FieldTypeUpdateOne
SetOptionalInt8 sets the optional_int8 field.
func (*FieldTypeUpdateOne) SetOptionalUint ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalUint(u uint) *FieldTypeUpdateOne
SetOptionalUint sets the optional_uint field.
func (*FieldTypeUpdateOne) SetOptionalUint16 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalUint16(u uint16) *FieldTypeUpdateOne
SetOptionalUint16 sets the optional_uint16 field.
func (*FieldTypeUpdateOne) SetOptionalUint32 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalUint32(u uint32) *FieldTypeUpdateOne
SetOptionalUint32 sets the optional_uint32 field.
func (*FieldTypeUpdateOne) SetOptionalUint64 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalUint64(u uint64) *FieldTypeUpdateOne
SetOptionalUint64 sets the optional_uint64 field.
func (*FieldTypeUpdateOne) SetOptionalUint8 ¶
func (ftuo *FieldTypeUpdateOne) SetOptionalUint8(u uint8) *FieldTypeUpdateOne
SetOptionalUint8 sets the optional_uint8 field.
func (*FieldTypeUpdateOne) SetRole ¶
func (ftuo *FieldTypeUpdateOne) SetRole(r role.Role) *FieldTypeUpdateOne
SetRole sets the role field.
func (*FieldTypeUpdateOne) SetSchemaFloat ¶
func (ftuo *FieldTypeUpdateOne) SetSchemaFloat(s schema.Float64) *FieldTypeUpdateOne
SetSchemaFloat sets the schema_float field.
func (*FieldTypeUpdateOne) SetSchemaFloat32 ¶
func (ftuo *FieldTypeUpdateOne) SetSchemaFloat32(s schema.Float32) *FieldTypeUpdateOne
SetSchemaFloat32 sets the schema_float32 field.
func (*FieldTypeUpdateOne) SetSchemaInt ¶
func (ftuo *FieldTypeUpdateOne) SetSchemaInt(s schema.Int) *FieldTypeUpdateOne
SetSchemaInt sets the schema_int field.
func (*FieldTypeUpdateOne) SetSchemaInt64 ¶
func (ftuo *FieldTypeUpdateOne) SetSchemaInt64(s schema.Int64) *FieldTypeUpdateOne
SetSchemaInt64 sets the schema_int64 field.
func (*FieldTypeUpdateOne) SetSchemaInt8 ¶
func (ftuo *FieldTypeUpdateOne) SetSchemaInt8(s schema.Int8) *FieldTypeUpdateOne
SetSchemaInt8 sets the schema_int8 field.
func (*FieldTypeUpdateOne) SetState ¶
func (ftuo *FieldTypeUpdateOne) SetState(f fieldtype.State) *FieldTypeUpdateOne
SetState sets the state field.
func (*FieldTypeUpdateOne) SetStr ¶
func (ftuo *FieldTypeUpdateOne) SetStr(ss sql.NullString) *FieldTypeUpdateOne
SetStr sets the str field.
func (*FieldTypeUpdateOne) SetValidateOptionalInt32 ¶
func (ftuo *FieldTypeUpdateOne) SetValidateOptionalInt32(i int32) *FieldTypeUpdateOne
SetValidateOptionalInt32 sets the validate_optional_int32 field.
type FieldTypes ¶
type FieldTypes []*FieldType
FieldTypes is a parsable slice of FieldType.
func (*FieldTypes) FromResponse ¶
func (ft *FieldTypes) FromResponse(res *gremlin.Response) error
FromResponse scans the gremlin response data into FieldTypes.
type File ¶
type File struct { // ID of the ent. ID string `json:"id,omitempty"` // Size holds the value of the "size" field. Size int `json:"size,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // User holds the value of the "user" field. User *string `json:"user,omitempty"` // Group holds the value of the "group" field. Group string `json:"group,omitempty"` // Op holds the value of the "op" field. Op bool `json:"op,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the FileQuery when eager-loading is set. Edges FileEdges `json:"edges"` // contains filtered or unexported fields }
File is the model entity for the File schema.
func (*File) FromResponse ¶
FromResponse scans the gremlin response data into File.
func (*File) QueryField ¶
func (f *File) QueryField() *FieldTypeQuery
QueryField queries the field edge of the File.
func (*File) QueryOwner ¶
QueryOwner queries the owner edge of the File.
func (*File) QueryType ¶
func (f *File) QueryType() *FileTypeQuery
QueryType queries the type edge of the File.
func (*File) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*File) Update ¶
func (f *File) Update() *FileUpdateOne
Update returns a builder for updating this File. Note that, you need to call File.Unwrap() before calling this method, if this File was returned from a transaction, and the transaction was committed or rolled back.
type FileClient ¶
type FileClient struct {
// contains filtered or unexported fields
}
FileClient is a client for the File schema.
func NewFileClient ¶
func NewFileClient(c config) *FileClient
NewFileClient returns a client for the File from the given config.
func (*FileClient) Create ¶
func (c *FileClient) Create() *FileCreate
Create returns a create builder for File.
func (*FileClient) CreateBulk ¶
func (c *FileClient) CreateBulk(builders ...*FileCreate) *FileCreateBulk
BulkCreate returns a builder for creating a bulk of File entities.
func (*FileClient) Delete ¶
func (c *FileClient) Delete() *FileDelete
Delete returns a delete builder for File.
func (*FileClient) DeleteOne ¶
func (c *FileClient) DeleteOne(f *File) *FileDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*FileClient) DeleteOneID ¶
func (c *FileClient) DeleteOneID(id string) *FileDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*FileClient) GetX ¶
func (c *FileClient) GetX(ctx context.Context, id string) *File
GetX is like Get, but panics if an error occurs.
func (*FileClient) Query ¶
func (c *FileClient) Query() *FileQuery
Query returns a query builder for File.
func (*FileClient) QueryField ¶
func (c *FileClient) QueryField(f *File) *FieldTypeQuery
QueryField queries the field edge of a File.
func (*FileClient) QueryOwner ¶
func (c *FileClient) QueryOwner(f *File) *UserQuery
QueryOwner queries the owner edge of a File.
func (*FileClient) QueryType ¶
func (c *FileClient) QueryType(f *File) *FileTypeQuery
QueryType queries the type edge of a File.
func (*FileClient) Update ¶
func (c *FileClient) Update() *FileUpdate
Update returns an update builder for File.
func (*FileClient) UpdateOne ¶
func (c *FileClient) UpdateOne(f *File) *FileUpdateOne
UpdateOne returns an update builder for the given entity.
func (*FileClient) UpdateOneID ¶
func (c *FileClient) UpdateOneID(id string) *FileUpdateOne
UpdateOneID returns an update builder for the given id.
func (*FileClient) Use ¶
func (c *FileClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `file.Hooks(f(g(h())))`.
type FileCreate ¶
type FileCreate struct {
// contains filtered or unexported fields
}
FileCreate is the builder for creating a File entity.
func (*FileCreate) AddField ¶
func (fc *FileCreate) AddField(f ...*FieldType) *FileCreate
AddField adds the field edges to FieldType.
func (*FileCreate) AddFieldIDs ¶
func (fc *FileCreate) AddFieldIDs(ids ...string) *FileCreate
AddFieldIDs adds the field edge to FieldType by ids.
func (*FileCreate) Mutation ¶
func (fc *FileCreate) Mutation() *FileMutation
Mutation returns the FileMutation object of the builder.
func (*FileCreate) Save ¶
func (fc *FileCreate) Save(ctx context.Context) (*File, error)
Save creates the File in the database.
func (*FileCreate) SaveX ¶
func (fc *FileCreate) SaveX(ctx context.Context) *File
SaveX calls Save and panics if Save returns an error.
func (*FileCreate) SetGroup ¶
func (fc *FileCreate) SetGroup(s string) *FileCreate
SetGroup sets the group field.
func (*FileCreate) SetName ¶
func (fc *FileCreate) SetName(s string) *FileCreate
SetName sets the name field.
func (*FileCreate) SetNillableGroup ¶
func (fc *FileCreate) SetNillableGroup(s *string) *FileCreate
SetNillableGroup sets the group field if the given value is not nil.
func (*FileCreate) SetNillableOp ¶ added in v0.4.3
func (fc *FileCreate) SetNillableOp(b *bool) *FileCreate
SetNillableOp sets the op field if the given value is not nil.
func (*FileCreate) SetNillableOwnerID ¶
func (fc *FileCreate) SetNillableOwnerID(id *string) *FileCreate
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*FileCreate) SetNillableSize ¶
func (fc *FileCreate) SetNillableSize(i *int) *FileCreate
SetNillableSize sets the size field if the given value is not nil.
func (*FileCreate) SetNillableTypeID ¶
func (fc *FileCreate) SetNillableTypeID(id *string) *FileCreate
SetNillableTypeID sets the type edge to FileType by id if the given value is not nil.
func (*FileCreate) SetNillableUser ¶
func (fc *FileCreate) SetNillableUser(s *string) *FileCreate
SetNillableUser sets the user field if the given value is not nil.
func (*FileCreate) SetOp ¶ added in v0.4.3
func (fc *FileCreate) SetOp(b bool) *FileCreate
SetOp sets the op field.
func (*FileCreate) SetOwner ¶
func (fc *FileCreate) SetOwner(u *User) *FileCreate
SetOwner sets the owner edge to User.
func (*FileCreate) SetOwnerID ¶
func (fc *FileCreate) SetOwnerID(id string) *FileCreate
SetOwnerID sets the owner edge to User by id.
func (*FileCreate) SetSize ¶
func (fc *FileCreate) SetSize(i int) *FileCreate
SetSize sets the size field.
func (*FileCreate) SetType ¶
func (fc *FileCreate) SetType(f *FileType) *FileCreate
SetType sets the type edge to FileType.
func (*FileCreate) SetTypeID ¶
func (fc *FileCreate) SetTypeID(id string) *FileCreate
SetTypeID sets the type edge to FileType by id.
func (*FileCreate) SetUser ¶
func (fc *FileCreate) SetUser(s string) *FileCreate
SetUser sets the user field.
type FileCreateBulk ¶
type FileCreateBulk struct {
// contains filtered or unexported fields
}
FileCreateBulk is the builder for creating a bulk of File entities.
type FileDelete ¶
type FileDelete struct {
// contains filtered or unexported fields
}
FileDelete is the builder for deleting a File entity.
func (*FileDelete) Exec ¶
func (fd *FileDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*FileDelete) ExecX ¶
func (fd *FileDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*FileDelete) Where ¶
func (fd *FileDelete) Where(ps ...predicate.File) *FileDelete
Where adds a new predicate to the delete builder.
type FileDeleteOne ¶
type FileDeleteOne struct {
// contains filtered or unexported fields
}
FileDeleteOne is the builder for deleting a single File entity.
func (*FileDeleteOne) Exec ¶
func (fdo *FileDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*FileDeleteOne) ExecX ¶
func (fdo *FileDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type FileEdges ¶
type FileEdges struct { // Owner holds the value of the owner edge. Owner *User // Type holds the value of the type edge. Type *FileType // Field holds the value of the field edge. Field []*FieldType // contains filtered or unexported fields }
FileEdges holds the relations/edges for other nodes in the graph.
func (FileEdges) FieldOrErr ¶
FieldOrErr returns the Field value or an error if the edge was not loaded in eager-loading.
func (FileEdges) OwnerOrErr ¶
OwnerOrErr returns the Owner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type FileGroupBy ¶
type FileGroupBy struct {
// contains filtered or unexported fields
}
FileGroupBy is the builder for group-by File entities.
func (*FileGroupBy) Aggregate ¶
func (fgb *FileGroupBy) Aggregate(fns ...AggregateFunc) *FileGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*FileGroupBy) Bool ¶
func (fgb *FileGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) BoolX ¶
func (fgb *FileGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*FileGroupBy) Bools ¶
func (fgb *FileGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) BoolsX ¶
func (fgb *FileGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*FileGroupBy) Float64 ¶
func (fgb *FileGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) Float64X ¶
func (fgb *FileGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*FileGroupBy) Float64s ¶
func (fgb *FileGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) Float64sX ¶
func (fgb *FileGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*FileGroupBy) Int ¶
func (fgb *FileGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) IntX ¶
func (fgb *FileGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*FileGroupBy) Ints ¶
func (fgb *FileGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) IntsX ¶
func (fgb *FileGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*FileGroupBy) Scan ¶
func (fgb *FileGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*FileGroupBy) ScanX ¶
func (fgb *FileGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*FileGroupBy) String ¶
func (fgb *FileGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*FileGroupBy) StringX ¶
func (fgb *FileGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type FileMutation ¶
type FileMutation struct {
// contains filtered or unexported fields
}
FileMutation represents an operation that mutate the Files nodes in the graph.
func (*FileMutation) AddField ¶
func (m *FileMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*FileMutation) AddFieldIDs ¶
func (m *FileMutation) AddFieldIDs(ids ...string)
AddFieldIDs adds the field edge to FieldType by ids.
func (*FileMutation) AddedEdges ¶
func (m *FileMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*FileMutation) AddedField ¶
func (m *FileMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*FileMutation) AddedFields ¶
func (m *FileMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*FileMutation) AddedIDs ¶
func (m *FileMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*FileMutation) AddedSize ¶
func (m *FileMutation) AddedSize() (r int, exists bool)
AddedSize returns the value that was added to the size field in this mutation.
func (*FileMutation) ClearEdge ¶
func (m *FileMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*FileMutation) ClearField ¶
func (m *FileMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*FileMutation) ClearFieldEdge ¶ added in v0.4.3
func (m *FileMutation) ClearFieldEdge()
ClearFieldEdge clears the field edge to FieldType.
func (*FileMutation) ClearGroup ¶
func (m *FileMutation) ClearGroup()
ClearGroup clears the value of group.
func (*FileMutation) ClearOp ¶ added in v0.4.3
func (m *FileMutation) ClearOp()
ClearOp clears the value of op.
func (*FileMutation) ClearOwner ¶
func (m *FileMutation) ClearOwner()
ClearOwner clears the owner edge to User.
func (*FileMutation) ClearType ¶
func (m *FileMutation) ClearType()
ClearType clears the type edge to FileType.
func (*FileMutation) ClearUser ¶
func (m *FileMutation) ClearUser()
ClearUser clears the value of user.
func (*FileMutation) ClearedEdges ¶
func (m *FileMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*FileMutation) ClearedFields ¶
func (m *FileMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (FileMutation) Client ¶
func (m FileMutation) 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 (*FileMutation) EdgeCleared ¶
func (m *FileMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*FileMutation) Field ¶
func (m *FileMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*FileMutation) FieldCleared ¶
func (m *FileMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*FileMutation) FieldEdgeCleared ¶ added in v0.4.3
func (m *FileMutation) FieldEdgeCleared() bool
FieldEdgeCleared returns if the edge field was cleared.
func (*FileMutation) FieldIDs ¶
func (m *FileMutation) FieldIDs() (ids []string)
FieldIDs returns the field ids in the mutation.
func (*FileMutation) Fields ¶
func (m *FileMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*FileMutation) GetOp ¶ added in v0.4.3
func (m *FileMutation) GetOp() (r bool, exists bool)
GetOp returns the op value in the mutation.
func (*FileMutation) Group ¶
func (m *FileMutation) Group() (r string, exists bool)
Group returns the group value in the mutation.
func (*FileMutation) GroupCleared ¶
func (m *FileMutation) GroupCleared() bool
GroupCleared returns if the field group was cleared in this mutation.
func (*FileMutation) ID ¶
func (m *FileMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*FileMutation) Name ¶
func (m *FileMutation) Name() (r string, exists bool)
Name returns the name value in the mutation.
func (*FileMutation) 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 was failed.
func (*FileMutation) OldGroup ¶
func (m *FileMutation) OldGroup(ctx context.Context) (v string, err error)
OldGroup returns the old group value of the File. If the File 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 database query fails.
func (*FileMutation) OldName ¶
func (m *FileMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old name value of the File. If the File 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 database query fails.
func (*FileMutation) OldOp ¶ added in v0.4.3
func (m *FileMutation) OldOp(ctx context.Context) (v bool, err error)
OldOp returns the old op value of the File. If the File 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 database query fails.
func (*FileMutation) OldSize ¶
func (m *FileMutation) OldSize(ctx context.Context) (v int, err error)
OldSize returns the old size value of the File. If the File 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 database query fails.
func (*FileMutation) OldUser ¶
func (m *FileMutation) OldUser(ctx context.Context) (v *string, err error)
OldUser returns the old user value of the File. If the File 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 database query fails.
func (*FileMutation) OpCleared ¶ added in v0.4.3
func (m *FileMutation) OpCleared() bool
OpCleared returns if the field op was cleared in this mutation.
func (*FileMutation) OwnerCleared ¶
func (m *FileMutation) OwnerCleared() bool
OwnerCleared returns if the edge owner was cleared.
func (*FileMutation) OwnerID ¶
func (m *FileMutation) OwnerID() (id string, exists bool)
OwnerID returns the owner id in the mutation.
func (*FileMutation) OwnerIDs ¶
func (m *FileMutation) OwnerIDs() (ids []string)
OwnerIDs returns the owner 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 (*FileMutation) RemoveFieldIDs ¶
func (m *FileMutation) RemoveFieldIDs(ids ...string)
RemoveFieldIDs removes the field edge to FieldType by ids.
func (*FileMutation) RemovedEdges ¶
func (m *FileMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*FileMutation) RemovedFieldIDs ¶
func (m *FileMutation) RemovedFieldIDs() (ids []string)
RemovedField returns the removed ids of field.
func (*FileMutation) RemovedIDs ¶
func (m *FileMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*FileMutation) ResetEdge ¶
func (m *FileMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*FileMutation) ResetField ¶
func (m *FileMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*FileMutation) ResetFieldEdge ¶
func (m *FileMutation) ResetFieldEdge()
ResetFieldEdge reset all changes of the "field" edge.
func (*FileMutation) ResetGroup ¶
func (m *FileMutation) ResetGroup()
ResetGroup reset all changes of the "group" field.
func (*FileMutation) ResetName ¶
func (m *FileMutation) ResetName()
ResetName reset all changes of the "name" field.
func (*FileMutation) ResetOp ¶ added in v0.4.3
func (m *FileMutation) ResetOp()
ResetOp reset all changes of the "op" field.
func (*FileMutation) ResetOwner ¶
func (m *FileMutation) ResetOwner()
ResetOwner reset all changes of the "owner" edge.
func (*FileMutation) ResetSize ¶
func (m *FileMutation) ResetSize()
ResetSize reset all changes of the "size" field.
func (*FileMutation) ResetType ¶
func (m *FileMutation) ResetType()
ResetType reset all changes of the "type" edge.
func (*FileMutation) ResetUser ¶
func (m *FileMutation) ResetUser()
ResetUser reset all changes of the "user" field.
func (*FileMutation) SetField ¶
func (m *FileMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*FileMutation) SetGroup ¶
func (m *FileMutation) SetGroup(s string)
SetGroup sets the group field.
func (*FileMutation) SetName ¶
func (m *FileMutation) SetName(s string)
SetName sets the name field.
func (*FileMutation) SetOp ¶ added in v0.4.3
func (m *FileMutation) SetOp(b bool)
SetOp sets the op field.
func (*FileMutation) SetOwnerID ¶
func (m *FileMutation) SetOwnerID(id string)
SetOwnerID sets the owner edge to User by id.
func (*FileMutation) SetTypeID ¶
func (m *FileMutation) SetTypeID(id string)
SetTypeID sets the type edge to FileType by id.
func (*FileMutation) SetUser ¶
func (m *FileMutation) SetUser(s string)
SetUser sets the user field.
func (*FileMutation) Size ¶
func (m *FileMutation) Size() (r int, exists bool)
Size returns the size value in the mutation.
func (FileMutation) Tx ¶
func (m FileMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*FileMutation) Type ¶
func (m *FileMutation) Type() string
Type returns the node type of this mutation (File).
func (*FileMutation) TypeCleared ¶
func (m *FileMutation) TypeCleared() bool
TypeCleared returns if the edge type was cleared.
func (*FileMutation) TypeID ¶
func (m *FileMutation) TypeID() (id string, exists bool)
TypeID returns the type id in the mutation.
func (*FileMutation) TypeIDs ¶
func (m *FileMutation) TypeIDs() (ids []string)
TypeIDs returns the type ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use TypeID instead. It exists only for internal usage by the builders.
func (*FileMutation) User ¶
func (m *FileMutation) User() (r string, exists bool)
User returns the user value in the mutation.
func (*FileMutation) UserCleared ¶
func (m *FileMutation) UserCleared() bool
UserCleared returns if the field user was cleared in this mutation.
type FileQuery ¶
type FileQuery struct {
// contains filtered or unexported fields
}
FileQuery is the builder for querying File entities.
func (*FileQuery) Clone ¶
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*FileQuery) First ¶
First returns the first File entity in the query. Returns *NotFoundError when no file was found.
func (*FileQuery) FirstID ¶
FirstID returns the first File id in the query. Returns *NotFoundError when no id was found.
func (*FileQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*FileQuery) GroupBy ¶
func (fq *FileQuery) GroupBy(field string, fields ...string) *FileGroupBy
GroupBy 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 { Size int `json:"size,omitempty"` Count int `json:"count,omitempty"` } client.File.Query(). GroupBy(file.FieldSize). Aggregate(ent.Count()). Scan(ctx, &v)
func (*FileQuery) Only ¶
Only returns the only File entity in the query, returns an error if not exactly one entity was returned.
func (*FileQuery) OnlyID ¶
OnlyID returns the only File id in the query, returns an error if not exactly one id was returned.
func (*FileQuery) QueryField ¶
func (fq *FileQuery) QueryField() *FieldTypeQuery
QueryField chains the current query on the field edge.
func (*FileQuery) QueryOwner ¶
QueryOwner chains the current query on the owner edge.
func (*FileQuery) QueryType ¶
func (fq *FileQuery) QueryType() *FileTypeQuery
QueryType chains the current query on the type edge.
func (*FileQuery) Select ¶
func (fq *FileQuery) Select(field string, fields ...string) *FileSelect
Select one or more fields from the given query.
Example:
var v []struct { Size int `json:"size,omitempty"` } client.File.Query(). Select(file.FieldSize). Scan(ctx, &v)
func (*FileQuery) WithField ¶
func (fq *FileQuery) WithField(opts ...func(*FieldTypeQuery)) *FileQuery
WithField tells the query-builder to eager-loads the nodes that are connected to
the "field" edge. The optional arguments used to configure the query builder of the edge.
func (*FileQuery) WithOwner ¶
WithOwner tells the query-builder to eager-loads the nodes that are connected to
the "owner" edge. The optional arguments used to configure the query builder of the edge.
func (*FileQuery) WithType ¶
func (fq *FileQuery) WithType(opts ...func(*FileTypeQuery)) *FileQuery
WithType tells the query-builder to eager-loads the nodes that are connected to
the "type" edge. The optional arguments used to configure the query builder of the edge.
type FileSelect ¶
type FileSelect struct {
// contains filtered or unexported fields
}
FileSelect is the builder for select fields of File entities.
func (*FileSelect) Bool ¶
func (fs *FileSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*FileSelect) BoolX ¶
func (fs *FileSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*FileSelect) Bools ¶
func (fs *FileSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*FileSelect) BoolsX ¶
func (fs *FileSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*FileSelect) Float64 ¶
func (fs *FileSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*FileSelect) Float64X ¶
func (fs *FileSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*FileSelect) Float64s ¶
func (fs *FileSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*FileSelect) Float64sX ¶
func (fs *FileSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*FileSelect) Int ¶
func (fs *FileSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*FileSelect) IntX ¶
func (fs *FileSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*FileSelect) Ints ¶
func (fs *FileSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*FileSelect) IntsX ¶
func (fs *FileSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*FileSelect) Scan ¶
func (fs *FileSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*FileSelect) ScanX ¶
func (fs *FileSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*FileSelect) String ¶
func (fs *FileSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*FileSelect) StringX ¶
func (fs *FileSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type FileType ¶
type FileType struct { // ID of the ent. ID string `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Type holds the value of the "type" field. Type filetype.Type `json:"type,omitempty"` // State holds the value of the "state" field. State filetype.State `json:"state,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the FileTypeQuery when eager-loading is set. Edges FileTypeEdges `json:"edges"` // contains filtered or unexported fields }
FileType is the model entity for the FileType schema.
func (*FileType) FromResponse ¶
FromResponse scans the gremlin response data into FileType.
func (*FileType) QueryFiles ¶
QueryFiles queries the files edge of the FileType.
func (*FileType) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*FileType) Update ¶
func (ft *FileType) Update() *FileTypeUpdateOne
Update returns a builder for updating this FileType. Note that, you need to call FileType.Unwrap() before calling this method, if this FileType was returned from a transaction, and the transaction was committed or rolled back.
type FileTypeClient ¶
type FileTypeClient struct {
// contains filtered or unexported fields
}
FileTypeClient is a client for the FileType schema.
func NewFileTypeClient ¶
func NewFileTypeClient(c config) *FileTypeClient
NewFileTypeClient returns a client for the FileType from the given config.
func (*FileTypeClient) Create ¶
func (c *FileTypeClient) Create() *FileTypeCreate
Create returns a create builder for FileType.
func (*FileTypeClient) CreateBulk ¶
func (c *FileTypeClient) CreateBulk(builders ...*FileTypeCreate) *FileTypeCreateBulk
BulkCreate returns a builder for creating a bulk of FileType entities.
func (*FileTypeClient) Delete ¶
func (c *FileTypeClient) Delete() *FileTypeDelete
Delete returns a delete builder for FileType.
func (*FileTypeClient) DeleteOne ¶
func (c *FileTypeClient) DeleteOne(ft *FileType) *FileTypeDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*FileTypeClient) DeleteOneID ¶
func (c *FileTypeClient) DeleteOneID(id string) *FileTypeDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*FileTypeClient) GetX ¶
func (c *FileTypeClient) GetX(ctx context.Context, id string) *FileType
GetX is like Get, but panics if an error occurs.
func (*FileTypeClient) Hooks ¶
func (c *FileTypeClient) Hooks() []Hook
Hooks returns the client hooks.
func (*FileTypeClient) Query ¶
func (c *FileTypeClient) Query() *FileTypeQuery
Query returns a query builder for FileType.
func (*FileTypeClient) QueryFiles ¶
func (c *FileTypeClient) QueryFiles(ft *FileType) *FileQuery
QueryFiles queries the files edge of a FileType.
func (*FileTypeClient) Update ¶
func (c *FileTypeClient) Update() *FileTypeUpdate
Update returns an update builder for FileType.
func (*FileTypeClient) UpdateOne ¶
func (c *FileTypeClient) UpdateOne(ft *FileType) *FileTypeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*FileTypeClient) UpdateOneID ¶
func (c *FileTypeClient) UpdateOneID(id string) *FileTypeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*FileTypeClient) Use ¶
func (c *FileTypeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `filetype.Hooks(f(g(h())))`.
type FileTypeCreate ¶
type FileTypeCreate struct {
// contains filtered or unexported fields
}
FileTypeCreate is the builder for creating a FileType entity.
func (*FileTypeCreate) AddFileIDs ¶
func (ftc *FileTypeCreate) AddFileIDs(ids ...string) *FileTypeCreate
AddFileIDs adds the files edge to File by ids.
func (*FileTypeCreate) AddFiles ¶
func (ftc *FileTypeCreate) AddFiles(f ...*File) *FileTypeCreate
AddFiles adds the files edges to File.
func (*FileTypeCreate) Mutation ¶
func (ftc *FileTypeCreate) Mutation() *FileTypeMutation
Mutation returns the FileTypeMutation object of the builder.
func (*FileTypeCreate) Save ¶
func (ftc *FileTypeCreate) Save(ctx context.Context) (*FileType, error)
Save creates the FileType in the database.
func (*FileTypeCreate) SaveX ¶
func (ftc *FileTypeCreate) SaveX(ctx context.Context) *FileType
SaveX calls Save and panics if Save returns an error.
func (*FileTypeCreate) SetName ¶
func (ftc *FileTypeCreate) SetName(s string) *FileTypeCreate
SetName sets the name field.
func (*FileTypeCreate) SetNillableState ¶
func (ftc *FileTypeCreate) SetNillableState(f *filetype.State) *FileTypeCreate
SetNillableState sets the state field if the given value is not nil.
func (*FileTypeCreate) SetNillableType ¶
func (ftc *FileTypeCreate) SetNillableType(f *filetype.Type) *FileTypeCreate
SetNillableType sets the type field if the given value is not nil.
func (*FileTypeCreate) SetState ¶
func (ftc *FileTypeCreate) SetState(f filetype.State) *FileTypeCreate
SetState sets the state field.
func (*FileTypeCreate) SetType ¶
func (ftc *FileTypeCreate) SetType(f filetype.Type) *FileTypeCreate
SetType sets the type field.
type FileTypeCreateBulk ¶
type FileTypeCreateBulk struct {
// contains filtered or unexported fields
}
FileTypeCreateBulk is the builder for creating a bulk of FileType entities.
type FileTypeDelete ¶
type FileTypeDelete struct {
// contains filtered or unexported fields
}
FileTypeDelete is the builder for deleting a FileType entity.
func (*FileTypeDelete) Exec ¶
func (ftd *FileTypeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*FileTypeDelete) ExecX ¶
func (ftd *FileTypeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*FileTypeDelete) Where ¶
func (ftd *FileTypeDelete) Where(ps ...predicate.FileType) *FileTypeDelete
Where adds a new predicate to the delete builder.
type FileTypeDeleteOne ¶
type FileTypeDeleteOne struct {
// contains filtered or unexported fields
}
FileTypeDeleteOne is the builder for deleting a single FileType entity.
func (*FileTypeDeleteOne) Exec ¶
func (ftdo *FileTypeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*FileTypeDeleteOne) ExecX ¶
func (ftdo *FileTypeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type FileTypeEdges ¶
type FileTypeEdges struct { // Files holds the value of the files edge. Files []*File // contains filtered or unexported fields }
FileTypeEdges holds the relations/edges for other nodes in the graph.
func (FileTypeEdges) FilesOrErr ¶
func (e FileTypeEdges) FilesOrErr() ([]*File, error)
FilesOrErr returns the Files value or an error if the edge was not loaded in eager-loading.
type FileTypeGroupBy ¶
type FileTypeGroupBy struct {
// contains filtered or unexported fields
}
FileTypeGroupBy is the builder for group-by FileType entities.
func (*FileTypeGroupBy) Aggregate ¶
func (ftgb *FileTypeGroupBy) Aggregate(fns ...AggregateFunc) *FileTypeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*FileTypeGroupBy) Bool ¶
func (ftgb *FileTypeGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) BoolX ¶
func (ftgb *FileTypeGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*FileTypeGroupBy) Bools ¶
func (ftgb *FileTypeGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) BoolsX ¶
func (ftgb *FileTypeGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*FileTypeGroupBy) Float64 ¶
func (ftgb *FileTypeGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) Float64X ¶
func (ftgb *FileTypeGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*FileTypeGroupBy) Float64s ¶
func (ftgb *FileTypeGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) Float64sX ¶
func (ftgb *FileTypeGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*FileTypeGroupBy) Int ¶
func (ftgb *FileTypeGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) IntX ¶
func (ftgb *FileTypeGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*FileTypeGroupBy) Ints ¶
func (ftgb *FileTypeGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) IntsX ¶
func (ftgb *FileTypeGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*FileTypeGroupBy) Scan ¶
func (ftgb *FileTypeGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*FileTypeGroupBy) ScanX ¶
func (ftgb *FileTypeGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*FileTypeGroupBy) String ¶
func (ftgb *FileTypeGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*FileTypeGroupBy) StringX ¶
func (ftgb *FileTypeGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type FileTypeMutation ¶
type FileTypeMutation struct {
// contains filtered or unexported fields
}
FileTypeMutation represents an operation that mutate the FileTypes nodes in the graph.
func (*FileTypeMutation) AddField ¶
func (m *FileTypeMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*FileTypeMutation) AddFileIDs ¶
func (m *FileTypeMutation) AddFileIDs(ids ...string)
AddFileIDs adds the files edge to File by ids.
func (*FileTypeMutation) AddedEdges ¶
func (m *FileTypeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*FileTypeMutation) AddedField ¶
func (m *FileTypeMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*FileTypeMutation) AddedFields ¶
func (m *FileTypeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*FileTypeMutation) AddedIDs ¶
func (m *FileTypeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*FileTypeMutation) ClearEdge ¶
func (m *FileTypeMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*FileTypeMutation) ClearField ¶
func (m *FileTypeMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*FileTypeMutation) ClearFiles ¶ added in v0.4.3
func (m *FileTypeMutation) ClearFiles()
ClearFiles clears the files edge to File.
func (*FileTypeMutation) ClearedEdges ¶
func (m *FileTypeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*FileTypeMutation) ClearedFields ¶
func (m *FileTypeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (FileTypeMutation) Client ¶
func (m FileTypeMutation) 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 (*FileTypeMutation) EdgeCleared ¶
func (m *FileTypeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*FileTypeMutation) Field ¶
func (m *FileTypeMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*FileTypeMutation) FieldCleared ¶
func (m *FileTypeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*FileTypeMutation) Fields ¶
func (m *FileTypeMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*FileTypeMutation) FilesCleared ¶ added in v0.4.3
func (m *FileTypeMutation) FilesCleared() bool
FilesCleared returns if the edge files was cleared.
func (*FileTypeMutation) FilesIDs ¶
func (m *FileTypeMutation) FilesIDs() (ids []string)
FilesIDs returns the files ids in the mutation.
func (*FileTypeMutation) GetType ¶
func (m *FileTypeMutation) GetType() (r filetype.Type, exists bool)
GetType returns the type value in the mutation.
func (*FileTypeMutation) ID ¶
func (m *FileTypeMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*FileTypeMutation) Name ¶
func (m *FileTypeMutation) Name() (r string, exists bool)
Name returns the name value in the mutation.
func (*FileTypeMutation) 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 was failed.
func (*FileTypeMutation) OldName ¶
func (m *FileTypeMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old name value of the FileType. If the FileType 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 database query fails.
func (*FileTypeMutation) OldState ¶
OldState returns the old state value of the FileType. If the FileType 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 database query fails.
func (*FileTypeMutation) OldType ¶
OldType returns the old type value of the FileType. If the FileType 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 database query fails.
func (*FileTypeMutation) RemoveFileIDs ¶
func (m *FileTypeMutation) RemoveFileIDs(ids ...string)
RemoveFileIDs removes the files edge to File by ids.
func (*FileTypeMutation) RemovedEdges ¶
func (m *FileTypeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*FileTypeMutation) RemovedFilesIDs ¶
func (m *FileTypeMutation) RemovedFilesIDs() (ids []string)
RemovedFiles returns the removed ids of files.
func (*FileTypeMutation) RemovedIDs ¶
func (m *FileTypeMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*FileTypeMutation) ResetEdge ¶
func (m *FileTypeMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*FileTypeMutation) ResetField ¶
func (m *FileTypeMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*FileTypeMutation) ResetFiles ¶
func (m *FileTypeMutation) ResetFiles()
ResetFiles reset all changes of the "files" edge.
func (*FileTypeMutation) ResetName ¶
func (m *FileTypeMutation) ResetName()
ResetName reset all changes of the "name" field.
func (*FileTypeMutation) ResetState ¶
func (m *FileTypeMutation) ResetState()
ResetState reset all changes of the "state" field.
func (*FileTypeMutation) ResetType ¶
func (m *FileTypeMutation) ResetType()
ResetType reset all changes of the "type" field.
func (*FileTypeMutation) SetField ¶
func (m *FileTypeMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*FileTypeMutation) SetName ¶
func (m *FileTypeMutation) SetName(s string)
SetName sets the name field.
func (*FileTypeMutation) SetState ¶
func (m *FileTypeMutation) SetState(f filetype.State)
SetState sets the state field.
func (*FileTypeMutation) SetType ¶
func (m *FileTypeMutation) SetType(f filetype.Type)
SetType sets the type field.
func (*FileTypeMutation) State ¶
func (m *FileTypeMutation) State() (r filetype.State, exists bool)
State returns the state value in the mutation.
func (FileTypeMutation) Tx ¶
func (m FileTypeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*FileTypeMutation) Type ¶
func (m *FileTypeMutation) Type() string
Type returns the node type of this mutation (FileType).
type FileTypeQuery ¶
type FileTypeQuery struct {
// contains filtered or unexported fields
}
FileTypeQuery is the builder for querying FileType entities.
func (*FileTypeQuery) All ¶
func (ftq *FileTypeQuery) All(ctx context.Context) ([]*FileType, error)
All executes the query and returns a list of FileTypes.
func (*FileTypeQuery) AllX ¶
func (ftq *FileTypeQuery) AllX(ctx context.Context) []*FileType
AllX is like All, but panics if an error occurs.
func (*FileTypeQuery) Clone ¶
func (ftq *FileTypeQuery) Clone() *FileTypeQuery
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*FileTypeQuery) Count ¶
func (ftq *FileTypeQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*FileTypeQuery) CountX ¶
func (ftq *FileTypeQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*FileTypeQuery) Exist ¶
func (ftq *FileTypeQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*FileTypeQuery) ExistX ¶
func (ftq *FileTypeQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*FileTypeQuery) First ¶
func (ftq *FileTypeQuery) First(ctx context.Context) (*FileType, error)
First returns the first FileType entity in the query. Returns *NotFoundError when no filetype was found.
func (*FileTypeQuery) FirstID ¶
func (ftq *FileTypeQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first FileType id in the query. Returns *NotFoundError when no id was found.
func (*FileTypeQuery) FirstIDX ¶ added in v0.5.0
func (ftq *FileTypeQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*FileTypeQuery) FirstX ¶
func (ftq *FileTypeQuery) FirstX(ctx context.Context) *FileType
FirstX is like First, but panics if an error occurs.
func (*FileTypeQuery) GroupBy ¶
func (ftq *FileTypeQuery) GroupBy(field string, fields ...string) *FileTypeGroupBy
GroupBy 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.FileType.Query(). GroupBy(filetype.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*FileTypeQuery) IDs ¶
func (ftq *FileTypeQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of FileType ids.
func (*FileTypeQuery) IDsX ¶
func (ftq *FileTypeQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*FileTypeQuery) Limit ¶
func (ftq *FileTypeQuery) Limit(limit int) *FileTypeQuery
Limit adds a limit step to the query.
func (*FileTypeQuery) Offset ¶
func (ftq *FileTypeQuery) Offset(offset int) *FileTypeQuery
Offset adds an offset step to the query.
func (*FileTypeQuery) Only ¶
func (ftq *FileTypeQuery) Only(ctx context.Context) (*FileType, error)
Only returns the only FileType entity in the query, returns an error if not exactly one entity was returned.
func (*FileTypeQuery) OnlyID ¶
func (ftq *FileTypeQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID returns the only FileType id in the query, returns an error if not exactly one id was returned.
func (*FileTypeQuery) OnlyIDX ¶
func (ftq *FileTypeQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*FileTypeQuery) OnlyX ¶
func (ftq *FileTypeQuery) OnlyX(ctx context.Context) *FileType
OnlyX is like Only, but panics if an error occurs.
func (*FileTypeQuery) Order ¶
func (ftq *FileTypeQuery) Order(o ...OrderFunc) *FileTypeQuery
Order adds an order step to the query.
func (*FileTypeQuery) QueryFiles ¶
func (ftq *FileTypeQuery) QueryFiles() *FileQuery
QueryFiles chains the current query on the files edge.
func (*FileTypeQuery) Select ¶
func (ftq *FileTypeQuery) Select(field string, fields ...string) *FileTypeSelect
Select one or more fields from the given query.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.FileType.Query(). Select(filetype.FieldName). Scan(ctx, &v)
func (*FileTypeQuery) Where ¶
func (ftq *FileTypeQuery) Where(ps ...predicate.FileType) *FileTypeQuery
Where adds a new predicate for the builder.
func (*FileTypeQuery) WithFiles ¶
func (ftq *FileTypeQuery) WithFiles(opts ...func(*FileQuery)) *FileTypeQuery
WithFiles tells the query-builder to eager-loads the nodes that are connected to
the "files" edge. The optional arguments used to configure the query builder of the edge.
type FileTypeSelect ¶
type FileTypeSelect struct {
// contains filtered or unexported fields
}
FileTypeSelect is the builder for select fields of FileType entities.
func (*FileTypeSelect) Bool ¶
func (fts *FileTypeSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) BoolX ¶
func (fts *FileTypeSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*FileTypeSelect) Bools ¶
func (fts *FileTypeSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) BoolsX ¶
func (fts *FileTypeSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*FileTypeSelect) Float64 ¶
func (fts *FileTypeSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) Float64X ¶
func (fts *FileTypeSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*FileTypeSelect) Float64s ¶
func (fts *FileTypeSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) Float64sX ¶
func (fts *FileTypeSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*FileTypeSelect) Int ¶
func (fts *FileTypeSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) IntX ¶
func (fts *FileTypeSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*FileTypeSelect) Ints ¶
func (fts *FileTypeSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) IntsX ¶
func (fts *FileTypeSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*FileTypeSelect) Scan ¶
func (fts *FileTypeSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*FileTypeSelect) ScanX ¶
func (fts *FileTypeSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*FileTypeSelect) String ¶
func (fts *FileTypeSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*FileTypeSelect) StringX ¶
func (fts *FileTypeSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type FileTypeUpdate ¶
type FileTypeUpdate struct {
// contains filtered or unexported fields
}
FileTypeUpdate is the builder for updating FileType entities.
func (*FileTypeUpdate) AddFileIDs ¶
func (ftu *FileTypeUpdate) AddFileIDs(ids ...string) *FileTypeUpdate
AddFileIDs adds the files edge to File by ids.
func (*FileTypeUpdate) AddFiles ¶
func (ftu *FileTypeUpdate) AddFiles(f ...*File) *FileTypeUpdate
AddFiles adds the files edges to File.
func (*FileTypeUpdate) ClearFiles ¶ added in v0.4.3
func (ftu *FileTypeUpdate) ClearFiles() *FileTypeUpdate
ClearFiles clears all "files" edges to type File.
func (*FileTypeUpdate) Exec ¶
func (ftu *FileTypeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*FileTypeUpdate) ExecX ¶
func (ftu *FileTypeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FileTypeUpdate) Mutation ¶
func (ftu *FileTypeUpdate) Mutation() *FileTypeMutation
Mutation returns the FileTypeMutation object of the builder.
func (*FileTypeUpdate) RemoveFileIDs ¶
func (ftu *FileTypeUpdate) RemoveFileIDs(ids ...string) *FileTypeUpdate
RemoveFileIDs removes the files edge to File by ids.
func (*FileTypeUpdate) RemoveFiles ¶
func (ftu *FileTypeUpdate) RemoveFiles(f ...*File) *FileTypeUpdate
RemoveFiles removes files edges to File.
func (*FileTypeUpdate) Save ¶
func (ftu *FileTypeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*FileTypeUpdate) SaveX ¶
func (ftu *FileTypeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*FileTypeUpdate) SetName ¶
func (ftu *FileTypeUpdate) SetName(s string) *FileTypeUpdate
SetName sets the name field.
func (*FileTypeUpdate) SetNillableState ¶
func (ftu *FileTypeUpdate) SetNillableState(f *filetype.State) *FileTypeUpdate
SetNillableState sets the state field if the given value is not nil.
func (*FileTypeUpdate) SetNillableType ¶
func (ftu *FileTypeUpdate) SetNillableType(f *filetype.Type) *FileTypeUpdate
SetNillableType sets the type field if the given value is not nil.
func (*FileTypeUpdate) SetState ¶
func (ftu *FileTypeUpdate) SetState(f filetype.State) *FileTypeUpdate
SetState sets the state field.
func (*FileTypeUpdate) SetType ¶
func (ftu *FileTypeUpdate) SetType(f filetype.Type) *FileTypeUpdate
SetType sets the type field.
func (*FileTypeUpdate) Where ¶
func (ftu *FileTypeUpdate) Where(ps ...predicate.FileType) *FileTypeUpdate
Where adds a new predicate for the builder.
type FileTypeUpdateOne ¶
type FileTypeUpdateOne struct {
// contains filtered or unexported fields
}
FileTypeUpdateOne is the builder for updating a single FileType entity.
func (*FileTypeUpdateOne) AddFileIDs ¶
func (ftuo *FileTypeUpdateOne) AddFileIDs(ids ...string) *FileTypeUpdateOne
AddFileIDs adds the files edge to File by ids.
func (*FileTypeUpdateOne) AddFiles ¶
func (ftuo *FileTypeUpdateOne) AddFiles(f ...*File) *FileTypeUpdateOne
AddFiles adds the files edges to File.
func (*FileTypeUpdateOne) ClearFiles ¶ added in v0.4.3
func (ftuo *FileTypeUpdateOne) ClearFiles() *FileTypeUpdateOne
ClearFiles clears all "files" edges to type File.
func (*FileTypeUpdateOne) Exec ¶
func (ftuo *FileTypeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*FileTypeUpdateOne) ExecX ¶
func (ftuo *FileTypeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FileTypeUpdateOne) Mutation ¶
func (ftuo *FileTypeUpdateOne) Mutation() *FileTypeMutation
Mutation returns the FileTypeMutation object of the builder.
func (*FileTypeUpdateOne) RemoveFileIDs ¶
func (ftuo *FileTypeUpdateOne) RemoveFileIDs(ids ...string) *FileTypeUpdateOne
RemoveFileIDs removes the files edge to File by ids.
func (*FileTypeUpdateOne) RemoveFiles ¶
func (ftuo *FileTypeUpdateOne) RemoveFiles(f ...*File) *FileTypeUpdateOne
RemoveFiles removes files edges to File.
func (*FileTypeUpdateOne) Save ¶
func (ftuo *FileTypeUpdateOne) Save(ctx context.Context) (*FileType, error)
Save executes the query and returns the updated entity.
func (*FileTypeUpdateOne) SaveX ¶
func (ftuo *FileTypeUpdateOne) SaveX(ctx context.Context) *FileType
SaveX is like Save, but panics if an error occurs.
func (*FileTypeUpdateOne) SetName ¶
func (ftuo *FileTypeUpdateOne) SetName(s string) *FileTypeUpdateOne
SetName sets the name field.
func (*FileTypeUpdateOne) SetNillableState ¶
func (ftuo *FileTypeUpdateOne) SetNillableState(f *filetype.State) *FileTypeUpdateOne
SetNillableState sets the state field if the given value is not nil.
func (*FileTypeUpdateOne) SetNillableType ¶
func (ftuo *FileTypeUpdateOne) SetNillableType(f *filetype.Type) *FileTypeUpdateOne
SetNillableType sets the type field if the given value is not nil.
func (*FileTypeUpdateOne) SetState ¶
func (ftuo *FileTypeUpdateOne) SetState(f filetype.State) *FileTypeUpdateOne
SetState sets the state field.
func (*FileTypeUpdateOne) SetType ¶
func (ftuo *FileTypeUpdateOne) SetType(f filetype.Type) *FileTypeUpdateOne
SetType sets the type field.
type FileUpdate ¶
type FileUpdate struct {
// contains filtered or unexported fields
}
FileUpdate is the builder for updating File entities.
func (*FileUpdate) AddField ¶
func (fu *FileUpdate) AddField(f ...*FieldType) *FileUpdate
AddField adds the field edges to FieldType.
func (*FileUpdate) AddFieldIDs ¶
func (fu *FileUpdate) AddFieldIDs(ids ...string) *FileUpdate
AddFieldIDs adds the field edge to FieldType by ids.
func (*FileUpdate) AddSize ¶
func (fu *FileUpdate) AddSize(i int) *FileUpdate
AddSize adds i to size.
func (*FileUpdate) ClearFieldEdge ¶ added in v0.4.3
func (fu *FileUpdate) ClearFieldEdge() *FileUpdate
ClearFieldEdge clears all "field" edges to type FieldType.
func (*FileUpdate) ClearGroup ¶
func (fu *FileUpdate) ClearGroup() *FileUpdate
ClearGroup clears the value of group.
func (*FileUpdate) ClearOp ¶ added in v0.4.3
func (fu *FileUpdate) ClearOp() *FileUpdate
ClearOp clears the value of op.
func (*FileUpdate) ClearOwner ¶
func (fu *FileUpdate) ClearOwner() *FileUpdate
ClearOwner clears the "owner" edge to type User.
func (*FileUpdate) ClearType ¶
func (fu *FileUpdate) ClearType() *FileUpdate
ClearType clears the "type" edge to type FileType.
func (*FileUpdate) ClearUser ¶
func (fu *FileUpdate) ClearUser() *FileUpdate
ClearUser clears the value of user.
func (*FileUpdate) Exec ¶
func (fu *FileUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*FileUpdate) ExecX ¶
func (fu *FileUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FileUpdate) Mutation ¶
func (fu *FileUpdate) Mutation() *FileMutation
Mutation returns the FileMutation object of the builder.
func (*FileUpdate) RemoveField ¶
func (fu *FileUpdate) RemoveField(f ...*FieldType) *FileUpdate
RemoveField removes field edges to FieldType.
func (*FileUpdate) RemoveFieldIDs ¶
func (fu *FileUpdate) RemoveFieldIDs(ids ...string) *FileUpdate
RemoveFieldIDs removes the field edge to FieldType by ids.
func (*FileUpdate) Save ¶
func (fu *FileUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*FileUpdate) SaveX ¶
func (fu *FileUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*FileUpdate) SetGroup ¶
func (fu *FileUpdate) SetGroup(s string) *FileUpdate
SetGroup sets the group field.
func (*FileUpdate) SetName ¶
func (fu *FileUpdate) SetName(s string) *FileUpdate
SetName sets the name field.
func (*FileUpdate) SetNillableGroup ¶
func (fu *FileUpdate) SetNillableGroup(s *string) *FileUpdate
SetNillableGroup sets the group field if the given value is not nil.
func (*FileUpdate) SetNillableOp ¶ added in v0.4.3
func (fu *FileUpdate) SetNillableOp(b *bool) *FileUpdate
SetNillableOp sets the op field if the given value is not nil.
func (*FileUpdate) SetNillableOwnerID ¶
func (fu *FileUpdate) SetNillableOwnerID(id *string) *FileUpdate
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*FileUpdate) SetNillableSize ¶
func (fu *FileUpdate) SetNillableSize(i *int) *FileUpdate
SetNillableSize sets the size field if the given value is not nil.
func (*FileUpdate) SetNillableTypeID ¶
func (fu *FileUpdate) SetNillableTypeID(id *string) *FileUpdate
SetNillableTypeID sets the type edge to FileType by id if the given value is not nil.
func (*FileUpdate) SetNillableUser ¶
func (fu *FileUpdate) SetNillableUser(s *string) *FileUpdate
SetNillableUser sets the user field if the given value is not nil.
func (*FileUpdate) SetOp ¶ added in v0.4.3
func (fu *FileUpdate) SetOp(b bool) *FileUpdate
SetOp sets the op field.
func (*FileUpdate) SetOwner ¶
func (fu *FileUpdate) SetOwner(u *User) *FileUpdate
SetOwner sets the owner edge to User.
func (*FileUpdate) SetOwnerID ¶
func (fu *FileUpdate) SetOwnerID(id string) *FileUpdate
SetOwnerID sets the owner edge to User by id.
func (*FileUpdate) SetSize ¶
func (fu *FileUpdate) SetSize(i int) *FileUpdate
SetSize sets the size field.
func (*FileUpdate) SetType ¶
func (fu *FileUpdate) SetType(f *FileType) *FileUpdate
SetType sets the type edge to FileType.
func (*FileUpdate) SetTypeID ¶
func (fu *FileUpdate) SetTypeID(id string) *FileUpdate
SetTypeID sets the type edge to FileType by id.
func (*FileUpdate) SetUser ¶
func (fu *FileUpdate) SetUser(s string) *FileUpdate
SetUser sets the user field.
func (*FileUpdate) Where ¶
func (fu *FileUpdate) Where(ps ...predicate.File) *FileUpdate
Where adds a new predicate for the builder.
type FileUpdateOne ¶
type FileUpdateOne struct {
// contains filtered or unexported fields
}
FileUpdateOne is the builder for updating a single File entity.
func (*FileUpdateOne) AddField ¶
func (fuo *FileUpdateOne) AddField(f ...*FieldType) *FileUpdateOne
AddField adds the field edges to FieldType.
func (*FileUpdateOne) AddFieldIDs ¶
func (fuo *FileUpdateOne) AddFieldIDs(ids ...string) *FileUpdateOne
AddFieldIDs adds the field edge to FieldType by ids.
func (*FileUpdateOne) AddSize ¶
func (fuo *FileUpdateOne) AddSize(i int) *FileUpdateOne
AddSize adds i to size.
func (*FileUpdateOne) ClearFieldEdge ¶ added in v0.4.3
func (fuo *FileUpdateOne) ClearFieldEdge() *FileUpdateOne
ClearFieldEdge clears all "field" edges to type FieldType.
func (*FileUpdateOne) ClearGroup ¶
func (fuo *FileUpdateOne) ClearGroup() *FileUpdateOne
ClearGroup clears the value of group.
func (*FileUpdateOne) ClearOp ¶ added in v0.4.3
func (fuo *FileUpdateOne) ClearOp() *FileUpdateOne
ClearOp clears the value of op.
func (*FileUpdateOne) ClearOwner ¶
func (fuo *FileUpdateOne) ClearOwner() *FileUpdateOne
ClearOwner clears the "owner" edge to type User.
func (*FileUpdateOne) ClearType ¶
func (fuo *FileUpdateOne) ClearType() *FileUpdateOne
ClearType clears the "type" edge to type FileType.
func (*FileUpdateOne) ClearUser ¶
func (fuo *FileUpdateOne) ClearUser() *FileUpdateOne
ClearUser clears the value of user.
func (*FileUpdateOne) Exec ¶
func (fuo *FileUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*FileUpdateOne) ExecX ¶
func (fuo *FileUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FileUpdateOne) Mutation ¶
func (fuo *FileUpdateOne) Mutation() *FileMutation
Mutation returns the FileMutation object of the builder.
func (*FileUpdateOne) RemoveField ¶
func (fuo *FileUpdateOne) RemoveField(f ...*FieldType) *FileUpdateOne
RemoveField removes field edges to FieldType.
func (*FileUpdateOne) RemoveFieldIDs ¶
func (fuo *FileUpdateOne) RemoveFieldIDs(ids ...string) *FileUpdateOne
RemoveFieldIDs removes the field edge to FieldType by ids.
func (*FileUpdateOne) Save ¶
func (fuo *FileUpdateOne) Save(ctx context.Context) (*File, error)
Save executes the query and returns the updated entity.
func (*FileUpdateOne) SaveX ¶
func (fuo *FileUpdateOne) SaveX(ctx context.Context) *File
SaveX is like Save, but panics if an error occurs.
func (*FileUpdateOne) SetGroup ¶
func (fuo *FileUpdateOne) SetGroup(s string) *FileUpdateOne
SetGroup sets the group field.
func (*FileUpdateOne) SetName ¶
func (fuo *FileUpdateOne) SetName(s string) *FileUpdateOne
SetName sets the name field.
func (*FileUpdateOne) SetNillableGroup ¶
func (fuo *FileUpdateOne) SetNillableGroup(s *string) *FileUpdateOne
SetNillableGroup sets the group field if the given value is not nil.
func (*FileUpdateOne) SetNillableOp ¶ added in v0.4.3
func (fuo *FileUpdateOne) SetNillableOp(b *bool) *FileUpdateOne
SetNillableOp sets the op field if the given value is not nil.
func (*FileUpdateOne) SetNillableOwnerID ¶
func (fuo *FileUpdateOne) SetNillableOwnerID(id *string) *FileUpdateOne
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*FileUpdateOne) SetNillableSize ¶
func (fuo *FileUpdateOne) SetNillableSize(i *int) *FileUpdateOne
SetNillableSize sets the size field if the given value is not nil.
func (*FileUpdateOne) SetNillableTypeID ¶
func (fuo *FileUpdateOne) SetNillableTypeID(id *string) *FileUpdateOne
SetNillableTypeID sets the type edge to FileType by id if the given value is not nil.
func (*FileUpdateOne) SetNillableUser ¶
func (fuo *FileUpdateOne) SetNillableUser(s *string) *FileUpdateOne
SetNillableUser sets the user field if the given value is not nil.
func (*FileUpdateOne) SetOp ¶ added in v0.4.3
func (fuo *FileUpdateOne) SetOp(b bool) *FileUpdateOne
SetOp sets the op field.
func (*FileUpdateOne) SetOwner ¶
func (fuo *FileUpdateOne) SetOwner(u *User) *FileUpdateOne
SetOwner sets the owner edge to User.
func (*FileUpdateOne) SetOwnerID ¶
func (fuo *FileUpdateOne) SetOwnerID(id string) *FileUpdateOne
SetOwnerID sets the owner edge to User by id.
func (*FileUpdateOne) SetSize ¶
func (fuo *FileUpdateOne) SetSize(i int) *FileUpdateOne
SetSize sets the size field.
func (*FileUpdateOne) SetType ¶
func (fuo *FileUpdateOne) SetType(f *FileType) *FileUpdateOne
SetType sets the type edge to FileType.
func (*FileUpdateOne) SetTypeID ¶
func (fuo *FileUpdateOne) SetTypeID(id string) *FileUpdateOne
SetTypeID sets the type edge to FileType by id.
func (*FileUpdateOne) SetUser ¶
func (fuo *FileUpdateOne) SetUser(s string) *FileUpdateOne
SetUser sets the user field.
type Goods ¶ added in v0.4.3
type Goods struct { // ID of the ent. ID string `json:"id,omitempty"` // contains filtered or unexported fields }
Goods is the model entity for the Goods schema.
func (*Goods) FromResponse ¶ added in v0.4.3
FromResponse scans the gremlin response data into Goods.
func (*Goods) Unwrap ¶ added in v0.4.3
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Goods) Update ¶ added in v0.4.3
func (_go *Goods) Update() *GoodsUpdateOne
Update returns a builder for updating this Goods. Note that, you need to call Goods.Unwrap() before calling this method, if this Goods was returned from a transaction, and the transaction was committed or rolled back.
type GoodsClient ¶ added in v0.4.3
type GoodsClient struct {
// contains filtered or unexported fields
}
GoodsClient is a client for the Goods schema.
func NewGoodsClient ¶ added in v0.4.3
func NewGoodsClient(c config) *GoodsClient
NewGoodsClient returns a client for the Goods from the given config.
func (*GoodsClient) Create ¶ added in v0.4.3
func (c *GoodsClient) Create() *GoodsCreate
Create returns a create builder for Goods.
func (*GoodsClient) CreateBulk ¶ added in v0.4.3
func (c *GoodsClient) CreateBulk(builders ...*GoodsCreate) *GoodsCreateBulk
BulkCreate returns a builder for creating a bulk of Goods entities.
func (*GoodsClient) Delete ¶ added in v0.4.3
func (c *GoodsClient) Delete() *GoodsDelete
Delete returns a delete builder for Goods.
func (*GoodsClient) DeleteOne ¶ added in v0.4.3
func (c *GoodsClient) DeleteOne(_go *Goods) *GoodsDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*GoodsClient) DeleteOneID ¶ added in v0.4.3
func (c *GoodsClient) DeleteOneID(id string) *GoodsDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*GoodsClient) GetX ¶ added in v0.4.3
func (c *GoodsClient) GetX(ctx context.Context, id string) *Goods
GetX is like Get, but panics if an error occurs.
func (*GoodsClient) Hooks ¶ added in v0.4.3
func (c *GoodsClient) Hooks() []Hook
Hooks returns the client hooks.
func (*GoodsClient) Query ¶ added in v0.4.3
func (c *GoodsClient) Query() *GoodsQuery
Query returns a query builder for Goods.
func (*GoodsClient) Update ¶ added in v0.4.3
func (c *GoodsClient) Update() *GoodsUpdate
Update returns an update builder for Goods.
func (*GoodsClient) UpdateOne ¶ added in v0.4.3
func (c *GoodsClient) UpdateOne(_go *Goods) *GoodsUpdateOne
UpdateOne returns an update builder for the given entity.
func (*GoodsClient) UpdateOneID ¶ added in v0.4.3
func (c *GoodsClient) UpdateOneID(id string) *GoodsUpdateOne
UpdateOneID returns an update builder for the given id.
func (*GoodsClient) Use ¶ added in v0.4.3
func (c *GoodsClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `goods.Hooks(f(g(h())))`.
type GoodsCreate ¶ added in v0.4.3
type GoodsCreate struct {
// contains filtered or unexported fields
}
GoodsCreate is the builder for creating a Goods entity.
func (*GoodsCreate) Mutation ¶ added in v0.4.3
func (gc *GoodsCreate) Mutation() *GoodsMutation
Mutation returns the GoodsMutation object of the builder.
type GoodsCreateBulk ¶ added in v0.4.3
type GoodsCreateBulk struct {
// contains filtered or unexported fields
}
GoodsCreateBulk is the builder for creating a bulk of Goods entities.
type GoodsDelete ¶ added in v0.4.3
type GoodsDelete struct {
// contains filtered or unexported fields
}
GoodsDelete is the builder for deleting a Goods entity.
func (*GoodsDelete) Exec ¶ added in v0.4.3
func (gd *GoodsDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*GoodsDelete) ExecX ¶ added in v0.4.3
func (gd *GoodsDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*GoodsDelete) Where ¶ added in v0.4.3
func (gd *GoodsDelete) Where(ps ...predicate.Goods) *GoodsDelete
Where adds a new predicate to the delete builder.
type GoodsDeleteOne ¶ added in v0.4.3
type GoodsDeleteOne struct {
// contains filtered or unexported fields
}
GoodsDeleteOne is the builder for deleting a single Goods entity.
func (*GoodsDeleteOne) Exec ¶ added in v0.4.3
func (gdo *GoodsDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*GoodsDeleteOne) ExecX ¶ added in v0.4.3
func (gdo *GoodsDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type GoodsGroupBy ¶ added in v0.4.3
type GoodsGroupBy struct {
// contains filtered or unexported fields
}
GoodsGroupBy is the builder for group-by Goods entities.
func (*GoodsGroupBy) Aggregate ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Aggregate(fns ...AggregateFunc) *GoodsGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*GoodsGroupBy) Bool ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) BoolX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*GoodsGroupBy) Bools ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) BoolsX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*GoodsGroupBy) Float64 ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) Float64X ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*GoodsGroupBy) Float64s ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) Float64sX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*GoodsGroupBy) Int ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) IntX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*GoodsGroupBy) Ints ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) IntsX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*GoodsGroupBy) Scan ¶ added in v0.4.3
func (ggb *GoodsGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*GoodsGroupBy) ScanX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*GoodsGroupBy) String ¶ added in v0.4.3
func (ggb *GoodsGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*GoodsGroupBy) StringX ¶ added in v0.4.3
func (ggb *GoodsGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type GoodsMutation ¶ added in v0.4.3
type GoodsMutation struct {
// contains filtered or unexported fields
}
GoodsMutation represents an operation that mutate the GoodsSlice nodes in the graph.
func (*GoodsMutation) AddField ¶ added in v0.4.3
func (m *GoodsMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*GoodsMutation) AddedEdges ¶ added in v0.4.3
func (m *GoodsMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*GoodsMutation) AddedField ¶ added in v0.4.3
func (m *GoodsMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*GoodsMutation) AddedFields ¶ added in v0.4.3
func (m *GoodsMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*GoodsMutation) AddedIDs ¶ added in v0.4.3
func (m *GoodsMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*GoodsMutation) ClearEdge ¶ added in v0.4.3
func (m *GoodsMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*GoodsMutation) ClearField ¶ added in v0.4.3
func (m *GoodsMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*GoodsMutation) ClearedEdges ¶ added in v0.4.3
func (m *GoodsMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*GoodsMutation) ClearedFields ¶ added in v0.4.3
func (m *GoodsMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (GoodsMutation) Client ¶ added in v0.4.3
func (m GoodsMutation) 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 (*GoodsMutation) EdgeCleared ¶ added in v0.4.3
func (m *GoodsMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*GoodsMutation) Field ¶ added in v0.4.3
func (m *GoodsMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*GoodsMutation) FieldCleared ¶ added in v0.4.3
func (m *GoodsMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*GoodsMutation) Fields ¶ added in v0.4.3
func (m *GoodsMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*GoodsMutation) ID ¶ added in v0.4.3
func (m *GoodsMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*GoodsMutation) OldField ¶ added in v0.4.3
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 was failed.
func (*GoodsMutation) Op ¶ added in v0.4.3
func (m *GoodsMutation) Op() Op
Op returns the operation name.
func (*GoodsMutation) RemovedEdges ¶ added in v0.4.3
func (m *GoodsMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*GoodsMutation) RemovedIDs ¶ added in v0.4.3
func (m *GoodsMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*GoodsMutation) ResetEdge ¶ added in v0.4.3
func (m *GoodsMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*GoodsMutation) ResetField ¶ added in v0.4.3
func (m *GoodsMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*GoodsMutation) SetField ¶ added in v0.4.3
func (m *GoodsMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (GoodsMutation) Tx ¶ added in v0.4.3
func (m GoodsMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*GoodsMutation) Type ¶ added in v0.4.3
func (m *GoodsMutation) Type() string
Type returns the node type of this mutation (Goods).
type GoodsQuery ¶ added in v0.4.3
type GoodsQuery struct {
// contains filtered or unexported fields
}
GoodsQuery is the builder for querying Goods entities.
func (*GoodsQuery) All ¶ added in v0.4.3
func (gq *GoodsQuery) All(ctx context.Context) ([]*Goods, error)
All executes the query and returns a list of GoodsSlice.
func (*GoodsQuery) AllX ¶ added in v0.4.3
func (gq *GoodsQuery) AllX(ctx context.Context) []*Goods
AllX is like All, but panics if an error occurs.
func (*GoodsQuery) Clone ¶ added in v0.4.3
func (gq *GoodsQuery) Clone() *GoodsQuery
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*GoodsQuery) Count ¶ added in v0.4.3
func (gq *GoodsQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*GoodsQuery) CountX ¶ added in v0.4.3
func (gq *GoodsQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*GoodsQuery) Exist ¶ added in v0.4.3
func (gq *GoodsQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*GoodsQuery) ExistX ¶ added in v0.4.3
func (gq *GoodsQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*GoodsQuery) First ¶ added in v0.4.3
func (gq *GoodsQuery) First(ctx context.Context) (*Goods, error)
First returns the first Goods entity in the query. Returns *NotFoundError when no goods was found.
func (*GoodsQuery) FirstID ¶ added in v0.4.3
func (gq *GoodsQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first Goods id in the query. Returns *NotFoundError when no id was found.
func (*GoodsQuery) FirstIDX ¶ added in v0.5.0
func (gq *GoodsQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*GoodsQuery) FirstX ¶ added in v0.4.3
func (gq *GoodsQuery) FirstX(ctx context.Context) *Goods
FirstX is like First, but panics if an error occurs.
func (*GoodsQuery) GroupBy ¶ added in v0.4.3
func (gq *GoodsQuery) GroupBy(field string, fields ...string) *GoodsGroupBy
GroupBy used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
func (*GoodsQuery) IDs ¶ added in v0.4.3
func (gq *GoodsQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of Goods ids.
func (*GoodsQuery) IDsX ¶ added in v0.4.3
func (gq *GoodsQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*GoodsQuery) Limit ¶ added in v0.4.3
func (gq *GoodsQuery) Limit(limit int) *GoodsQuery
Limit adds a limit step to the query.
func (*GoodsQuery) Offset ¶ added in v0.4.3
func (gq *GoodsQuery) Offset(offset int) *GoodsQuery
Offset adds an offset step to the query.
func (*GoodsQuery) Only ¶ added in v0.4.3
func (gq *GoodsQuery) Only(ctx context.Context) (*Goods, error)
Only returns the only Goods entity in the query, returns an error if not exactly one entity was returned.
func (*GoodsQuery) OnlyID ¶ added in v0.4.3
func (gq *GoodsQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID returns the only Goods id in the query, returns an error if not exactly one id was returned.
func (*GoodsQuery) OnlyIDX ¶ added in v0.4.3
func (gq *GoodsQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*GoodsQuery) OnlyX ¶ added in v0.4.3
func (gq *GoodsQuery) OnlyX(ctx context.Context) *Goods
OnlyX is like Only, but panics if an error occurs.
func (*GoodsQuery) Order ¶ added in v0.4.3
func (gq *GoodsQuery) Order(o ...OrderFunc) *GoodsQuery
Order adds an order step to the query.
func (*GoodsQuery) Select ¶ added in v0.4.3
func (gq *GoodsQuery) Select(field string, fields ...string) *GoodsSelect
Select one or more fields from the given query.
func (*GoodsQuery) Where ¶ added in v0.4.3
func (gq *GoodsQuery) Where(ps ...predicate.Goods) *GoodsQuery
Where adds a new predicate for the builder.
type GoodsSelect ¶ added in v0.4.3
type GoodsSelect struct {
// contains filtered or unexported fields
}
GoodsSelect is the builder for select fields of Goods entities.
func (*GoodsSelect) Bool ¶ added in v0.4.3
func (gs *GoodsSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*GoodsSelect) BoolX ¶ added in v0.4.3
func (gs *GoodsSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*GoodsSelect) Bools ¶ added in v0.4.3
func (gs *GoodsSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*GoodsSelect) BoolsX ¶ added in v0.4.3
func (gs *GoodsSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*GoodsSelect) Float64 ¶ added in v0.4.3
func (gs *GoodsSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*GoodsSelect) Float64X ¶ added in v0.4.3
func (gs *GoodsSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*GoodsSelect) Float64s ¶ added in v0.4.3
func (gs *GoodsSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*GoodsSelect) Float64sX ¶ added in v0.4.3
func (gs *GoodsSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*GoodsSelect) Int ¶ added in v0.4.3
func (gs *GoodsSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*GoodsSelect) IntX ¶ added in v0.4.3
func (gs *GoodsSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*GoodsSelect) Ints ¶ added in v0.4.3
func (gs *GoodsSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*GoodsSelect) IntsX ¶ added in v0.4.3
func (gs *GoodsSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*GoodsSelect) Scan ¶ added in v0.4.3
func (gs *GoodsSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*GoodsSelect) ScanX ¶ added in v0.4.3
func (gs *GoodsSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*GoodsSelect) String ¶ added in v0.4.3
func (gs *GoodsSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*GoodsSelect) StringX ¶ added in v0.4.3
func (gs *GoodsSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type GoodsSlice ¶ added in v0.4.3
type GoodsSlice []*Goods
GoodsSlice is a parsable slice of Goods.
func (*GoodsSlice) FromResponse ¶ added in v0.4.3
func (_go *GoodsSlice) FromResponse(res *gremlin.Response) error
FromResponse scans the gremlin response data into GoodsSlice.
type GoodsUpdate ¶ added in v0.4.3
type GoodsUpdate struct {
// contains filtered or unexported fields
}
GoodsUpdate is the builder for updating Goods entities.
func (*GoodsUpdate) Exec ¶ added in v0.4.3
func (gu *GoodsUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*GoodsUpdate) ExecX ¶ added in v0.4.3
func (gu *GoodsUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*GoodsUpdate) Mutation ¶ added in v0.4.3
func (gu *GoodsUpdate) Mutation() *GoodsMutation
Mutation returns the GoodsMutation object of the builder.
func (*GoodsUpdate) Save ¶ added in v0.4.3
func (gu *GoodsUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*GoodsUpdate) SaveX ¶ added in v0.4.3
func (gu *GoodsUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*GoodsUpdate) Where ¶ added in v0.4.3
func (gu *GoodsUpdate) Where(ps ...predicate.Goods) *GoodsUpdate
Where adds a new predicate for the builder.
type GoodsUpdateOne ¶ added in v0.4.3
type GoodsUpdateOne struct {
// contains filtered or unexported fields
}
GoodsUpdateOne is the builder for updating a single Goods entity.
func (*GoodsUpdateOne) Exec ¶ added in v0.4.3
func (guo *GoodsUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*GoodsUpdateOne) ExecX ¶ added in v0.4.3
func (guo *GoodsUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*GoodsUpdateOne) Mutation ¶ added in v0.4.3
func (guo *GoodsUpdateOne) Mutation() *GoodsMutation
Mutation returns the GoodsMutation object of the builder.
type Group ¶
type Group struct { // ID of the ent. ID string `json:"id,omitempty"` // Active holds the value of the "active" field. Active bool `json:"active,omitempty"` // Expire holds the value of the "expire" field. Expire time.Time `json:"expire,omitempty"` // Type holds the value of the "type" field. Type *string `json:"type,omitempty"` // MaxUsers holds the value of the "max_users" field. MaxUsers int `json:"max_users,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the GroupQuery when eager-loading is set. Edges GroupEdges `json:"edges"` // contains filtered or unexported fields }
Group is the model entity for the Group schema.
func (*Group) FromResponse ¶
FromResponse scans the gremlin response data into Group.
func (*Group) QueryBlocked ¶
QueryBlocked queries the blocked edge of the Group.
func (*Group) QueryFiles ¶
QueryFiles queries the files edge of the Group.
func (*Group) QueryInfo ¶
func (gr *Group) QueryInfo() *GroupInfoQuery
QueryInfo queries the info edge of the Group.
func (*Group) QueryUsers ¶
QueryUsers queries the users edge of the Group.
func (*Group) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Group) Update ¶
func (gr *Group) Update() *GroupUpdateOne
Update returns a builder for updating this Group. Note that, you need to call Group.Unwrap() before calling this method, if this Group was returned from a transaction, and the transaction was committed or rolled back.
type GroupClient ¶
type GroupClient struct {
// contains filtered or unexported fields
}
GroupClient is a client for the Group schema.
func NewGroupClient ¶
func NewGroupClient(c config) *GroupClient
NewGroupClient returns a client for the Group from the given config.
func (*GroupClient) Create ¶
func (c *GroupClient) Create() *GroupCreate
Create returns a create builder for Group.
func (*GroupClient) CreateBulk ¶
func (c *GroupClient) CreateBulk(builders ...*GroupCreate) *GroupCreateBulk
BulkCreate returns a builder for creating a bulk of Group entities.
func (*GroupClient) Delete ¶
func (c *GroupClient) Delete() *GroupDelete
Delete returns a delete builder for Group.
func (*GroupClient) DeleteOne ¶
func (c *GroupClient) DeleteOne(gr *Group) *GroupDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*GroupClient) DeleteOneID ¶
func (c *GroupClient) DeleteOneID(id string) *GroupDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*GroupClient) GetX ¶
func (c *GroupClient) GetX(ctx context.Context, id string) *Group
GetX is like Get, but panics if an error occurs.
func (*GroupClient) Query ¶
func (c *GroupClient) Query() *GroupQuery
Query returns a query builder for Group.
func (*GroupClient) QueryBlocked ¶
func (c *GroupClient) QueryBlocked(gr *Group) *UserQuery
QueryBlocked queries the blocked edge of a Group.
func (*GroupClient) QueryFiles ¶
func (c *GroupClient) QueryFiles(gr *Group) *FileQuery
QueryFiles queries the files edge of a Group.
func (*GroupClient) QueryInfo ¶
func (c *GroupClient) QueryInfo(gr *Group) *GroupInfoQuery
QueryInfo queries the info edge of a Group.
func (*GroupClient) QueryUsers ¶
func (c *GroupClient) QueryUsers(gr *Group) *UserQuery
QueryUsers queries the users edge of a Group.
func (*GroupClient) Update ¶
func (c *GroupClient) Update() *GroupUpdate
Update returns an update builder for Group.
func (*GroupClient) UpdateOne ¶
func (c *GroupClient) UpdateOne(gr *Group) *GroupUpdateOne
UpdateOne returns an update builder for the given entity.
func (*GroupClient) UpdateOneID ¶
func (c *GroupClient) UpdateOneID(id string) *GroupUpdateOne
UpdateOneID returns an update builder for the given id.
func (*GroupClient) Use ¶
func (c *GroupClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `group.Hooks(f(g(h())))`.
type GroupCreate ¶
type GroupCreate struct {
// contains filtered or unexported fields
}
GroupCreate is the builder for creating a Group entity.
func (*GroupCreate) AddBlocked ¶
func (gc *GroupCreate) AddBlocked(u ...*User) *GroupCreate
AddBlocked adds the blocked edges to User.
func (*GroupCreate) AddBlockedIDs ¶
func (gc *GroupCreate) AddBlockedIDs(ids ...string) *GroupCreate
AddBlockedIDs adds the blocked edge to User by ids.
func (*GroupCreate) AddFileIDs ¶
func (gc *GroupCreate) AddFileIDs(ids ...string) *GroupCreate
AddFileIDs adds the files edge to File by ids.
func (*GroupCreate) AddFiles ¶
func (gc *GroupCreate) AddFiles(f ...*File) *GroupCreate
AddFiles adds the files edges to File.
func (*GroupCreate) AddUserIDs ¶
func (gc *GroupCreate) AddUserIDs(ids ...string) *GroupCreate
AddUserIDs adds the users edge to User by ids.
func (*GroupCreate) AddUsers ¶
func (gc *GroupCreate) AddUsers(u ...*User) *GroupCreate
AddUsers adds the users edges to User.
func (*GroupCreate) Mutation ¶
func (gc *GroupCreate) Mutation() *GroupMutation
Mutation returns the GroupMutation object of the builder.
func (*GroupCreate) Save ¶
func (gc *GroupCreate) Save(ctx context.Context) (*Group, error)
Save creates the Group in the database.
func (*GroupCreate) SaveX ¶
func (gc *GroupCreate) SaveX(ctx context.Context) *Group
SaveX calls Save and panics if Save returns an error.
func (*GroupCreate) SetActive ¶
func (gc *GroupCreate) SetActive(b bool) *GroupCreate
SetActive sets the active field.
func (*GroupCreate) SetExpire ¶
func (gc *GroupCreate) SetExpire(t time.Time) *GroupCreate
SetExpire sets the expire field.
func (*GroupCreate) SetInfo ¶
func (gc *GroupCreate) SetInfo(g *GroupInfo) *GroupCreate
SetInfo sets the info edge to GroupInfo.
func (*GroupCreate) SetInfoID ¶
func (gc *GroupCreate) SetInfoID(id string) *GroupCreate
SetInfoID sets the info edge to GroupInfo by id.
func (*GroupCreate) SetMaxUsers ¶
func (gc *GroupCreate) SetMaxUsers(i int) *GroupCreate
SetMaxUsers sets the max_users field.
func (*GroupCreate) SetName ¶
func (gc *GroupCreate) SetName(s string) *GroupCreate
SetName sets the name field.
func (*GroupCreate) SetNillableActive ¶
func (gc *GroupCreate) SetNillableActive(b *bool) *GroupCreate
SetNillableActive sets the active field if the given value is not nil.
func (*GroupCreate) SetNillableMaxUsers ¶
func (gc *GroupCreate) SetNillableMaxUsers(i *int) *GroupCreate
SetNillableMaxUsers sets the max_users field if the given value is not nil.
func (*GroupCreate) SetNillableType ¶
func (gc *GroupCreate) SetNillableType(s *string) *GroupCreate
SetNillableType sets the type field if the given value is not nil.
func (*GroupCreate) SetType ¶
func (gc *GroupCreate) SetType(s string) *GroupCreate
SetType sets the type field.
type GroupCreateBulk ¶
type GroupCreateBulk struct {
// contains filtered or unexported fields
}
GroupCreateBulk is the builder for creating a bulk of Group entities.
type GroupDelete ¶
type GroupDelete struct {
// contains filtered or unexported fields
}
GroupDelete is the builder for deleting a Group entity.
func (*GroupDelete) Exec ¶
func (gd *GroupDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*GroupDelete) ExecX ¶
func (gd *GroupDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*GroupDelete) Where ¶
func (gd *GroupDelete) Where(ps ...predicate.Group) *GroupDelete
Where adds a new predicate to the delete builder.
type GroupDeleteOne ¶
type GroupDeleteOne struct {
// contains filtered or unexported fields
}
GroupDeleteOne is the builder for deleting a single Group entity.
func (*GroupDeleteOne) Exec ¶
func (gdo *GroupDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*GroupDeleteOne) ExecX ¶
func (gdo *GroupDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type GroupEdges ¶
type GroupEdges struct { // Files holds the value of the files edge. Files []*File // Blocked holds the value of the blocked edge. Blocked []*User // Users holds the value of the users edge. Users []*User // Info holds the value of the info edge. Info *GroupInfo // contains filtered or unexported fields }
GroupEdges holds the relations/edges for other nodes in the graph.
func (GroupEdges) BlockedOrErr ¶
func (e GroupEdges) BlockedOrErr() ([]*User, error)
BlockedOrErr returns the Blocked value or an error if the edge was not loaded in eager-loading.
func (GroupEdges) FilesOrErr ¶
func (e GroupEdges) FilesOrErr() ([]*File, error)
FilesOrErr returns the Files value or an error if the edge was not loaded in eager-loading.
func (GroupEdges) InfoOrErr ¶
func (e GroupEdges) InfoOrErr() (*GroupInfo, error)
InfoOrErr returns the Info value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (GroupEdges) UsersOrErr ¶
func (e GroupEdges) UsersOrErr() ([]*User, error)
UsersOrErr returns the Users value or an error if the edge was not loaded in eager-loading.
type GroupGroupBy ¶
type GroupGroupBy struct {
// contains filtered or unexported fields
}
GroupGroupBy is the builder for group-by Group entities.
func (*GroupGroupBy) Aggregate ¶
func (ggb *GroupGroupBy) Aggregate(fns ...AggregateFunc) *GroupGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*GroupGroupBy) Bool ¶
func (ggb *GroupGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) BoolX ¶
func (ggb *GroupGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*GroupGroupBy) Bools ¶
func (ggb *GroupGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) BoolsX ¶
func (ggb *GroupGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*GroupGroupBy) Float64 ¶
func (ggb *GroupGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) Float64X ¶
func (ggb *GroupGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*GroupGroupBy) Float64s ¶
func (ggb *GroupGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) Float64sX ¶
func (ggb *GroupGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*GroupGroupBy) Int ¶
func (ggb *GroupGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) IntX ¶
func (ggb *GroupGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*GroupGroupBy) Ints ¶
func (ggb *GroupGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) IntsX ¶
func (ggb *GroupGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*GroupGroupBy) Scan ¶
func (ggb *GroupGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*GroupGroupBy) ScanX ¶
func (ggb *GroupGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*GroupGroupBy) String ¶
func (ggb *GroupGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*GroupGroupBy) StringX ¶
func (ggb *GroupGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type GroupInfo ¶
type GroupInfo struct { // ID of the ent. ID string `json:"id,omitempty"` // Desc holds the value of the "desc" field. Desc string `json:"desc,omitempty"` // MaxUsers holds the value of the "max_users" field. MaxUsers int `json:"max_users,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the GroupInfoQuery when eager-loading is set. Edges GroupInfoEdges `json:"edges"` // contains filtered or unexported fields }
GroupInfo is the model entity for the GroupInfo schema.
func (*GroupInfo) FromResponse ¶
FromResponse scans the gremlin response data into GroupInfo.
func (*GroupInfo) QueryGroups ¶
func (gi *GroupInfo) QueryGroups() *GroupQuery
QueryGroups queries the groups edge of the GroupInfo.
func (*GroupInfo) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*GroupInfo) Update ¶
func (gi *GroupInfo) Update() *GroupInfoUpdateOne
Update returns a builder for updating this GroupInfo. Note that, you need to call GroupInfo.Unwrap() before calling this method, if this GroupInfo was returned from a transaction, and the transaction was committed or rolled back.
type GroupInfoClient ¶
type GroupInfoClient struct {
// contains filtered or unexported fields
}
GroupInfoClient is a client for the GroupInfo schema.
func NewGroupInfoClient ¶
func NewGroupInfoClient(c config) *GroupInfoClient
NewGroupInfoClient returns a client for the GroupInfo from the given config.
func (*GroupInfoClient) Create ¶
func (c *GroupInfoClient) Create() *GroupInfoCreate
Create returns a create builder for GroupInfo.
func (*GroupInfoClient) CreateBulk ¶
func (c *GroupInfoClient) CreateBulk(builders ...*GroupInfoCreate) *GroupInfoCreateBulk
BulkCreate returns a builder for creating a bulk of GroupInfo entities.
func (*GroupInfoClient) Delete ¶
func (c *GroupInfoClient) Delete() *GroupInfoDelete
Delete returns a delete builder for GroupInfo.
func (*GroupInfoClient) DeleteOne ¶
func (c *GroupInfoClient) DeleteOne(gi *GroupInfo) *GroupInfoDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*GroupInfoClient) DeleteOneID ¶
func (c *GroupInfoClient) DeleteOneID(id string) *GroupInfoDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*GroupInfoClient) GetX ¶
func (c *GroupInfoClient) GetX(ctx context.Context, id string) *GroupInfo
GetX is like Get, but panics if an error occurs.
func (*GroupInfoClient) Hooks ¶
func (c *GroupInfoClient) Hooks() []Hook
Hooks returns the client hooks.
func (*GroupInfoClient) Query ¶
func (c *GroupInfoClient) Query() *GroupInfoQuery
Query returns a query builder for GroupInfo.
func (*GroupInfoClient) QueryGroups ¶
func (c *GroupInfoClient) QueryGroups(gi *GroupInfo) *GroupQuery
QueryGroups queries the groups edge of a GroupInfo.
func (*GroupInfoClient) Update ¶
func (c *GroupInfoClient) Update() *GroupInfoUpdate
Update returns an update builder for GroupInfo.
func (*GroupInfoClient) UpdateOne ¶
func (c *GroupInfoClient) UpdateOne(gi *GroupInfo) *GroupInfoUpdateOne
UpdateOne returns an update builder for the given entity.
func (*GroupInfoClient) UpdateOneID ¶
func (c *GroupInfoClient) UpdateOneID(id string) *GroupInfoUpdateOne
UpdateOneID returns an update builder for the given id.
func (*GroupInfoClient) Use ¶
func (c *GroupInfoClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `groupinfo.Hooks(f(g(h())))`.
type GroupInfoCreate ¶
type GroupInfoCreate struct {
// contains filtered or unexported fields
}
GroupInfoCreate is the builder for creating a GroupInfo entity.
func (*GroupInfoCreate) AddGroupIDs ¶
func (gic *GroupInfoCreate) AddGroupIDs(ids ...string) *GroupInfoCreate
AddGroupIDs adds the groups edge to Group by ids.
func (*GroupInfoCreate) AddGroups ¶
func (gic *GroupInfoCreate) AddGroups(g ...*Group) *GroupInfoCreate
AddGroups adds the groups edges to Group.
func (*GroupInfoCreate) Mutation ¶
func (gic *GroupInfoCreate) Mutation() *GroupInfoMutation
Mutation returns the GroupInfoMutation object of the builder.
func (*GroupInfoCreate) Save ¶
func (gic *GroupInfoCreate) Save(ctx context.Context) (*GroupInfo, error)
Save creates the GroupInfo in the database.
func (*GroupInfoCreate) SaveX ¶
func (gic *GroupInfoCreate) SaveX(ctx context.Context) *GroupInfo
SaveX calls Save and panics if Save returns an error.
func (*GroupInfoCreate) SetDesc ¶
func (gic *GroupInfoCreate) SetDesc(s string) *GroupInfoCreate
SetDesc sets the desc field.
func (*GroupInfoCreate) SetMaxUsers ¶
func (gic *GroupInfoCreate) SetMaxUsers(i int) *GroupInfoCreate
SetMaxUsers sets the max_users field.
func (*GroupInfoCreate) SetNillableMaxUsers ¶
func (gic *GroupInfoCreate) SetNillableMaxUsers(i *int) *GroupInfoCreate
SetNillableMaxUsers sets the max_users field if the given value is not nil.
type GroupInfoCreateBulk ¶
type GroupInfoCreateBulk struct {
// contains filtered or unexported fields
}
GroupInfoCreateBulk is the builder for creating a bulk of GroupInfo entities.
type GroupInfoDelete ¶
type GroupInfoDelete struct {
// contains filtered or unexported fields
}
GroupInfoDelete is the builder for deleting a GroupInfo entity.
func (*GroupInfoDelete) Exec ¶
func (gid *GroupInfoDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*GroupInfoDelete) ExecX ¶
func (gid *GroupInfoDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*GroupInfoDelete) Where ¶
func (gid *GroupInfoDelete) Where(ps ...predicate.GroupInfo) *GroupInfoDelete
Where adds a new predicate to the delete builder.
type GroupInfoDeleteOne ¶
type GroupInfoDeleteOne struct {
// contains filtered or unexported fields
}
GroupInfoDeleteOne is the builder for deleting a single GroupInfo entity.
func (*GroupInfoDeleteOne) Exec ¶
func (gido *GroupInfoDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*GroupInfoDeleteOne) ExecX ¶
func (gido *GroupInfoDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type GroupInfoEdges ¶
type GroupInfoEdges struct { // Groups holds the value of the groups edge. Groups []*Group // contains filtered or unexported fields }
GroupInfoEdges holds the relations/edges for other nodes in the graph.
func (GroupInfoEdges) GroupsOrErr ¶
func (e GroupInfoEdges) GroupsOrErr() ([]*Group, error)
GroupsOrErr returns the Groups value or an error if the edge was not loaded in eager-loading.
type GroupInfoGroupBy ¶
type GroupInfoGroupBy struct {
// contains filtered or unexported fields
}
GroupInfoGroupBy is the builder for group-by GroupInfo entities.
func (*GroupInfoGroupBy) Aggregate ¶
func (gigb *GroupInfoGroupBy) Aggregate(fns ...AggregateFunc) *GroupInfoGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*GroupInfoGroupBy) Bool ¶
func (gigb *GroupInfoGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) BoolX ¶
func (gigb *GroupInfoGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*GroupInfoGroupBy) Bools ¶
func (gigb *GroupInfoGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) BoolsX ¶
func (gigb *GroupInfoGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*GroupInfoGroupBy) Float64 ¶
func (gigb *GroupInfoGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) Float64X ¶
func (gigb *GroupInfoGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*GroupInfoGroupBy) Float64s ¶
func (gigb *GroupInfoGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) Float64sX ¶
func (gigb *GroupInfoGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*GroupInfoGroupBy) Int ¶
func (gigb *GroupInfoGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) IntX ¶
func (gigb *GroupInfoGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*GroupInfoGroupBy) Ints ¶
func (gigb *GroupInfoGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) IntsX ¶
func (gigb *GroupInfoGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*GroupInfoGroupBy) Scan ¶
func (gigb *GroupInfoGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*GroupInfoGroupBy) ScanX ¶
func (gigb *GroupInfoGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*GroupInfoGroupBy) String ¶
func (gigb *GroupInfoGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*GroupInfoGroupBy) StringX ¶
func (gigb *GroupInfoGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type GroupInfoMutation ¶
type GroupInfoMutation struct {
// contains filtered or unexported fields
}
GroupInfoMutation represents an operation that mutate the GroupInfos nodes in the graph.
func (*GroupInfoMutation) AddField ¶
func (m *GroupInfoMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*GroupInfoMutation) AddGroupIDs ¶
func (m *GroupInfoMutation) AddGroupIDs(ids ...string)
AddGroupIDs adds the groups edge to Group by ids.
func (*GroupInfoMutation) AddMaxUsers ¶
func (m *GroupInfoMutation) AddMaxUsers(i int)
AddMaxUsers adds i to max_users.
func (*GroupInfoMutation) AddedEdges ¶
func (m *GroupInfoMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*GroupInfoMutation) AddedField ¶
func (m *GroupInfoMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*GroupInfoMutation) AddedFields ¶
func (m *GroupInfoMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*GroupInfoMutation) AddedIDs ¶
func (m *GroupInfoMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*GroupInfoMutation) AddedMaxUsers ¶
func (m *GroupInfoMutation) AddedMaxUsers() (r int, exists bool)
AddedMaxUsers returns the value that was added to the max_users field in this mutation.
func (*GroupInfoMutation) ClearEdge ¶
func (m *GroupInfoMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*GroupInfoMutation) ClearField ¶
func (m *GroupInfoMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*GroupInfoMutation) ClearGroups ¶ added in v0.4.3
func (m *GroupInfoMutation) ClearGroups()
ClearGroups clears the groups edge to Group.
func (*GroupInfoMutation) ClearedEdges ¶
func (m *GroupInfoMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*GroupInfoMutation) ClearedFields ¶
func (m *GroupInfoMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (GroupInfoMutation) Client ¶
func (m GroupInfoMutation) 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 (*GroupInfoMutation) Desc ¶
func (m *GroupInfoMutation) Desc() (r string, exists bool)
Desc returns the desc value in the mutation.
func (*GroupInfoMutation) EdgeCleared ¶
func (m *GroupInfoMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*GroupInfoMutation) Field ¶
func (m *GroupInfoMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*GroupInfoMutation) FieldCleared ¶
func (m *GroupInfoMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*GroupInfoMutation) Fields ¶
func (m *GroupInfoMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*GroupInfoMutation) GroupsCleared ¶ added in v0.4.3
func (m *GroupInfoMutation) GroupsCleared() bool
GroupsCleared returns if the edge groups was cleared.
func (*GroupInfoMutation) GroupsIDs ¶
func (m *GroupInfoMutation) GroupsIDs() (ids []string)
GroupsIDs returns the groups ids in the mutation.
func (*GroupInfoMutation) ID ¶
func (m *GroupInfoMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*GroupInfoMutation) MaxUsers ¶
func (m *GroupInfoMutation) MaxUsers() (r int, exists bool)
MaxUsers returns the max_users value in the mutation.
func (*GroupInfoMutation) OldDesc ¶
func (m *GroupInfoMutation) OldDesc(ctx context.Context) (v string, err error)
OldDesc returns the old desc value of the GroupInfo. If the GroupInfo 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 database query fails.
func (*GroupInfoMutation) 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 was failed.
func (*GroupInfoMutation) OldMaxUsers ¶
func (m *GroupInfoMutation) OldMaxUsers(ctx context.Context) (v int, err error)
OldMaxUsers returns the old max_users value of the GroupInfo. If the GroupInfo 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 database query fails.
func (*GroupInfoMutation) RemoveGroupIDs ¶
func (m *GroupInfoMutation) RemoveGroupIDs(ids ...string)
RemoveGroupIDs removes the groups edge to Group by ids.
func (*GroupInfoMutation) RemovedEdges ¶
func (m *GroupInfoMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*GroupInfoMutation) RemovedGroupsIDs ¶
func (m *GroupInfoMutation) RemovedGroupsIDs() (ids []string)
RemovedGroups returns the removed ids of groups.
func (*GroupInfoMutation) RemovedIDs ¶
func (m *GroupInfoMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*GroupInfoMutation) ResetDesc ¶
func (m *GroupInfoMutation) ResetDesc()
ResetDesc reset all changes of the "desc" field.
func (*GroupInfoMutation) ResetEdge ¶
func (m *GroupInfoMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*GroupInfoMutation) ResetField ¶
func (m *GroupInfoMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*GroupInfoMutation) ResetGroups ¶
func (m *GroupInfoMutation) ResetGroups()
ResetGroups reset all changes of the "groups" edge.
func (*GroupInfoMutation) ResetMaxUsers ¶
func (m *GroupInfoMutation) ResetMaxUsers()
ResetMaxUsers reset all changes of the "max_users" field.
func (*GroupInfoMutation) SetDesc ¶
func (m *GroupInfoMutation) SetDesc(s string)
SetDesc sets the desc field.
func (*GroupInfoMutation) SetField ¶
func (m *GroupInfoMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*GroupInfoMutation) SetMaxUsers ¶
func (m *GroupInfoMutation) SetMaxUsers(i int)
SetMaxUsers sets the max_users field.
func (GroupInfoMutation) Tx ¶
func (m GroupInfoMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*GroupInfoMutation) Type ¶
func (m *GroupInfoMutation) Type() string
Type returns the node type of this mutation (GroupInfo).
type GroupInfoQuery ¶
type GroupInfoQuery struct {
// contains filtered or unexported fields
}
GroupInfoQuery is the builder for querying GroupInfo entities.
func (*GroupInfoQuery) All ¶
func (giq *GroupInfoQuery) All(ctx context.Context) ([]*GroupInfo, error)
All executes the query and returns a list of GroupInfos.
func (*GroupInfoQuery) AllX ¶
func (giq *GroupInfoQuery) AllX(ctx context.Context) []*GroupInfo
AllX is like All, but panics if an error occurs.
func (*GroupInfoQuery) Clone ¶
func (giq *GroupInfoQuery) Clone() *GroupInfoQuery
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*GroupInfoQuery) Count ¶
func (giq *GroupInfoQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*GroupInfoQuery) CountX ¶
func (giq *GroupInfoQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*GroupInfoQuery) Exist ¶
func (giq *GroupInfoQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*GroupInfoQuery) ExistX ¶
func (giq *GroupInfoQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*GroupInfoQuery) First ¶
func (giq *GroupInfoQuery) First(ctx context.Context) (*GroupInfo, error)
First returns the first GroupInfo entity in the query. Returns *NotFoundError when no groupinfo was found.
func (*GroupInfoQuery) FirstID ¶
func (giq *GroupInfoQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first GroupInfo id in the query. Returns *NotFoundError when no id was found.
func (*GroupInfoQuery) FirstIDX ¶ added in v0.5.0
func (giq *GroupInfoQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*GroupInfoQuery) FirstX ¶
func (giq *GroupInfoQuery) FirstX(ctx context.Context) *GroupInfo
FirstX is like First, but panics if an error occurs.
func (*GroupInfoQuery) GroupBy ¶
func (giq *GroupInfoQuery) GroupBy(field string, fields ...string) *GroupInfoGroupBy
GroupBy 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 { Desc string `json:"desc,omitempty"` Count int `json:"count,omitempty"` } client.GroupInfo.Query(). GroupBy(groupinfo.FieldDesc). Aggregate(ent.Count()). Scan(ctx, &v)
func (*GroupInfoQuery) IDs ¶
func (giq *GroupInfoQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of GroupInfo ids.
func (*GroupInfoQuery) IDsX ¶
func (giq *GroupInfoQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*GroupInfoQuery) Limit ¶
func (giq *GroupInfoQuery) Limit(limit int) *GroupInfoQuery
Limit adds a limit step to the query.
func (*GroupInfoQuery) Offset ¶
func (giq *GroupInfoQuery) Offset(offset int) *GroupInfoQuery
Offset adds an offset step to the query.
func (*GroupInfoQuery) Only ¶
func (giq *GroupInfoQuery) Only(ctx context.Context) (*GroupInfo, error)
Only returns the only GroupInfo entity in the query, returns an error if not exactly one entity was returned.
func (*GroupInfoQuery) OnlyID ¶
func (giq *GroupInfoQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID returns the only GroupInfo id in the query, returns an error if not exactly one id was returned.
func (*GroupInfoQuery) OnlyIDX ¶
func (giq *GroupInfoQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*GroupInfoQuery) OnlyX ¶
func (giq *GroupInfoQuery) OnlyX(ctx context.Context) *GroupInfo
OnlyX is like Only, but panics if an error occurs.
func (*GroupInfoQuery) Order ¶
func (giq *GroupInfoQuery) Order(o ...OrderFunc) *GroupInfoQuery
Order adds an order step to the query.
func (*GroupInfoQuery) QueryGroups ¶
func (giq *GroupInfoQuery) QueryGroups() *GroupQuery
QueryGroups chains the current query on the groups edge.
func (*GroupInfoQuery) Select ¶
func (giq *GroupInfoQuery) Select(field string, fields ...string) *GroupInfoSelect
Select one or more fields from the given query.
Example:
var v []struct { Desc string `json:"desc,omitempty"` } client.GroupInfo.Query(). Select(groupinfo.FieldDesc). Scan(ctx, &v)
func (*GroupInfoQuery) Where ¶
func (giq *GroupInfoQuery) Where(ps ...predicate.GroupInfo) *GroupInfoQuery
Where adds a new predicate for the builder.
func (*GroupInfoQuery) WithGroups ¶
func (giq *GroupInfoQuery) WithGroups(opts ...func(*GroupQuery)) *GroupInfoQuery
WithGroups tells the query-builder to eager-loads the nodes that are connected to
the "groups" edge. The optional arguments used to configure the query builder of the edge.
type GroupInfoSelect ¶
type GroupInfoSelect struct {
// contains filtered or unexported fields
}
GroupInfoSelect is the builder for select fields of GroupInfo entities.
func (*GroupInfoSelect) Bool ¶
func (gis *GroupInfoSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) BoolX ¶
func (gis *GroupInfoSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*GroupInfoSelect) Bools ¶
func (gis *GroupInfoSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) BoolsX ¶
func (gis *GroupInfoSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*GroupInfoSelect) Float64 ¶
func (gis *GroupInfoSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) Float64X ¶
func (gis *GroupInfoSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*GroupInfoSelect) Float64s ¶
func (gis *GroupInfoSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) Float64sX ¶
func (gis *GroupInfoSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*GroupInfoSelect) Int ¶
func (gis *GroupInfoSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) IntX ¶
func (gis *GroupInfoSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*GroupInfoSelect) Ints ¶
func (gis *GroupInfoSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) IntsX ¶
func (gis *GroupInfoSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*GroupInfoSelect) Scan ¶
func (gis *GroupInfoSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*GroupInfoSelect) ScanX ¶
func (gis *GroupInfoSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*GroupInfoSelect) String ¶
func (gis *GroupInfoSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*GroupInfoSelect) StringX ¶
func (gis *GroupInfoSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type GroupInfoUpdate ¶
type GroupInfoUpdate struct {
// contains filtered or unexported fields
}
GroupInfoUpdate is the builder for updating GroupInfo entities.
func (*GroupInfoUpdate) AddGroupIDs ¶
func (giu *GroupInfoUpdate) AddGroupIDs(ids ...string) *GroupInfoUpdate
AddGroupIDs adds the groups edge to Group by ids.
func (*GroupInfoUpdate) AddGroups ¶
func (giu *GroupInfoUpdate) AddGroups(g ...*Group) *GroupInfoUpdate
AddGroups adds the groups edges to Group.
func (*GroupInfoUpdate) AddMaxUsers ¶
func (giu *GroupInfoUpdate) AddMaxUsers(i int) *GroupInfoUpdate
AddMaxUsers adds i to max_users.
func (*GroupInfoUpdate) ClearGroups ¶ added in v0.4.3
func (giu *GroupInfoUpdate) ClearGroups() *GroupInfoUpdate
ClearGroups clears all "groups" edges to type Group.
func (*GroupInfoUpdate) Exec ¶
func (giu *GroupInfoUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*GroupInfoUpdate) ExecX ¶
func (giu *GroupInfoUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*GroupInfoUpdate) Mutation ¶
func (giu *GroupInfoUpdate) Mutation() *GroupInfoMutation
Mutation returns the GroupInfoMutation object of the builder.
func (*GroupInfoUpdate) RemoveGroupIDs ¶
func (giu *GroupInfoUpdate) RemoveGroupIDs(ids ...string) *GroupInfoUpdate
RemoveGroupIDs removes the groups edge to Group by ids.
func (*GroupInfoUpdate) RemoveGroups ¶
func (giu *GroupInfoUpdate) RemoveGroups(g ...*Group) *GroupInfoUpdate
RemoveGroups removes groups edges to Group.
func (*GroupInfoUpdate) Save ¶
func (giu *GroupInfoUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*GroupInfoUpdate) SaveX ¶
func (giu *GroupInfoUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*GroupInfoUpdate) SetDesc ¶
func (giu *GroupInfoUpdate) SetDesc(s string) *GroupInfoUpdate
SetDesc sets the desc field.
func (*GroupInfoUpdate) SetMaxUsers ¶
func (giu *GroupInfoUpdate) SetMaxUsers(i int) *GroupInfoUpdate
SetMaxUsers sets the max_users field.
func (*GroupInfoUpdate) SetNillableMaxUsers ¶
func (giu *GroupInfoUpdate) SetNillableMaxUsers(i *int) *GroupInfoUpdate
SetNillableMaxUsers sets the max_users field if the given value is not nil.
func (*GroupInfoUpdate) Where ¶
func (giu *GroupInfoUpdate) Where(ps ...predicate.GroupInfo) *GroupInfoUpdate
Where adds a new predicate for the builder.
type GroupInfoUpdateOne ¶
type GroupInfoUpdateOne struct {
// contains filtered or unexported fields
}
GroupInfoUpdateOne is the builder for updating a single GroupInfo entity.
func (*GroupInfoUpdateOne) AddGroupIDs ¶
func (giuo *GroupInfoUpdateOne) AddGroupIDs(ids ...string) *GroupInfoUpdateOne
AddGroupIDs adds the groups edge to Group by ids.
func (*GroupInfoUpdateOne) AddGroups ¶
func (giuo *GroupInfoUpdateOne) AddGroups(g ...*Group) *GroupInfoUpdateOne
AddGroups adds the groups edges to Group.
func (*GroupInfoUpdateOne) AddMaxUsers ¶
func (giuo *GroupInfoUpdateOne) AddMaxUsers(i int) *GroupInfoUpdateOne
AddMaxUsers adds i to max_users.
func (*GroupInfoUpdateOne) ClearGroups ¶ added in v0.4.3
func (giuo *GroupInfoUpdateOne) ClearGroups() *GroupInfoUpdateOne
ClearGroups clears all "groups" edges to type Group.
func (*GroupInfoUpdateOne) Exec ¶
func (giuo *GroupInfoUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*GroupInfoUpdateOne) ExecX ¶
func (giuo *GroupInfoUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*GroupInfoUpdateOne) Mutation ¶
func (giuo *GroupInfoUpdateOne) Mutation() *GroupInfoMutation
Mutation returns the GroupInfoMutation object of the builder.
func (*GroupInfoUpdateOne) RemoveGroupIDs ¶
func (giuo *GroupInfoUpdateOne) RemoveGroupIDs(ids ...string) *GroupInfoUpdateOne
RemoveGroupIDs removes the groups edge to Group by ids.
func (*GroupInfoUpdateOne) RemoveGroups ¶
func (giuo *GroupInfoUpdateOne) RemoveGroups(g ...*Group) *GroupInfoUpdateOne
RemoveGroups removes groups edges to Group.
func (*GroupInfoUpdateOne) Save ¶
func (giuo *GroupInfoUpdateOne) Save(ctx context.Context) (*GroupInfo, error)
Save executes the query and returns the updated entity.
func (*GroupInfoUpdateOne) SaveX ¶
func (giuo *GroupInfoUpdateOne) SaveX(ctx context.Context) *GroupInfo
SaveX is like Save, but panics if an error occurs.
func (*GroupInfoUpdateOne) SetDesc ¶
func (giuo *GroupInfoUpdateOne) SetDesc(s string) *GroupInfoUpdateOne
SetDesc sets the desc field.
func (*GroupInfoUpdateOne) SetMaxUsers ¶
func (giuo *GroupInfoUpdateOne) SetMaxUsers(i int) *GroupInfoUpdateOne
SetMaxUsers sets the max_users field.
func (*GroupInfoUpdateOne) SetNillableMaxUsers ¶
func (giuo *GroupInfoUpdateOne) SetNillableMaxUsers(i *int) *GroupInfoUpdateOne
SetNillableMaxUsers sets the max_users field if the given value is not nil.
type GroupInfos ¶
type GroupInfos []*GroupInfo
GroupInfos is a parsable slice of GroupInfo.
func (*GroupInfos) FromResponse ¶
func (gi *GroupInfos) FromResponse(res *gremlin.Response) error
FromResponse scans the gremlin response data into GroupInfos.
type GroupMutation ¶
type GroupMutation struct {
// contains filtered or unexported fields
}
GroupMutation represents an operation that mutate the Groups nodes in the graph.
func (*GroupMutation) Active ¶
func (m *GroupMutation) Active() (r bool, exists bool)
Active returns the active value in the mutation.
func (*GroupMutation) AddBlockedIDs ¶
func (m *GroupMutation) AddBlockedIDs(ids ...string)
AddBlockedIDs adds the blocked edge to User by ids.
func (*GroupMutation) AddField ¶
func (m *GroupMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*GroupMutation) AddFileIDs ¶
func (m *GroupMutation) AddFileIDs(ids ...string)
AddFileIDs adds the files edge to File by ids.
func (*GroupMutation) AddMaxUsers ¶
func (m *GroupMutation) AddMaxUsers(i int)
AddMaxUsers adds i to max_users.
func (*GroupMutation) AddUserIDs ¶
func (m *GroupMutation) AddUserIDs(ids ...string)
AddUserIDs adds the users edge to User by ids.
func (*GroupMutation) AddedEdges ¶
func (m *GroupMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*GroupMutation) AddedField ¶
func (m *GroupMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*GroupMutation) AddedFields ¶
func (m *GroupMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*GroupMutation) AddedIDs ¶
func (m *GroupMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*GroupMutation) AddedMaxUsers ¶
func (m *GroupMutation) AddedMaxUsers() (r int, exists bool)
AddedMaxUsers returns the value that was added to the max_users field in this mutation.
func (*GroupMutation) BlockedCleared ¶ added in v0.4.3
func (m *GroupMutation) BlockedCleared() bool
BlockedCleared returns if the edge blocked was cleared.
func (*GroupMutation) BlockedIDs ¶
func (m *GroupMutation) BlockedIDs() (ids []string)
BlockedIDs returns the blocked ids in the mutation.
func (*GroupMutation) ClearBlocked ¶ added in v0.4.3
func (m *GroupMutation) ClearBlocked()
ClearBlocked clears the blocked edge to User.
func (*GroupMutation) ClearEdge ¶
func (m *GroupMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*GroupMutation) ClearField ¶
func (m *GroupMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*GroupMutation) ClearFiles ¶ added in v0.4.3
func (m *GroupMutation) ClearFiles()
ClearFiles clears the files edge to File.
func (*GroupMutation) ClearInfo ¶
func (m *GroupMutation) ClearInfo()
ClearInfo clears the info edge to GroupInfo.
func (*GroupMutation) ClearMaxUsers ¶
func (m *GroupMutation) ClearMaxUsers()
ClearMaxUsers clears the value of max_users.
func (*GroupMutation) ClearType ¶
func (m *GroupMutation) ClearType()
ClearType clears the value of type.
func (*GroupMutation) ClearUsers ¶ added in v0.4.3
func (m *GroupMutation) ClearUsers()
ClearUsers clears the users edge to User.
func (*GroupMutation) ClearedEdges ¶
func (m *GroupMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*GroupMutation) ClearedFields ¶
func (m *GroupMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (GroupMutation) Client ¶
func (m GroupMutation) 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 (*GroupMutation) EdgeCleared ¶
func (m *GroupMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*GroupMutation) Expire ¶
func (m *GroupMutation) Expire() (r time.Time, exists bool)
Expire returns the expire value in the mutation.
func (*GroupMutation) Field ¶
func (m *GroupMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*GroupMutation) FieldCleared ¶
func (m *GroupMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*GroupMutation) Fields ¶
func (m *GroupMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*GroupMutation) FilesCleared ¶ added in v0.4.3
func (m *GroupMutation) FilesCleared() bool
FilesCleared returns if the edge files was cleared.
func (*GroupMutation) FilesIDs ¶
func (m *GroupMutation) FilesIDs() (ids []string)
FilesIDs returns the files ids in the mutation.
func (*GroupMutation) GetType ¶
func (m *GroupMutation) GetType() (r string, exists bool)
GetType returns the type value in the mutation.
func (*GroupMutation) ID ¶
func (m *GroupMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*GroupMutation) InfoCleared ¶
func (m *GroupMutation) InfoCleared() bool
InfoCleared returns if the edge info was cleared.
func (*GroupMutation) InfoID ¶
func (m *GroupMutation) InfoID() (id string, exists bool)
InfoID returns the info id in the mutation.
func (*GroupMutation) InfoIDs ¶
func (m *GroupMutation) InfoIDs() (ids []string)
InfoIDs returns the info ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use InfoID instead. It exists only for internal usage by the builders.
func (*GroupMutation) MaxUsers ¶
func (m *GroupMutation) MaxUsers() (r int, exists bool)
MaxUsers returns the max_users value in the mutation.
func (*GroupMutation) MaxUsersCleared ¶
func (m *GroupMutation) MaxUsersCleared() bool
MaxUsersCleared returns if the field max_users was cleared in this mutation.
func (*GroupMutation) Name ¶
func (m *GroupMutation) Name() (r string, exists bool)
Name returns the name value in the mutation.
func (*GroupMutation) OldActive ¶
func (m *GroupMutation) OldActive(ctx context.Context) (v bool, err error)
OldActive returns the old active value of the Group. If the Group 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 database query fails.
func (*GroupMutation) OldExpire ¶
OldExpire returns the old expire value of the Group. If the Group 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 database query fails.
func (*GroupMutation) 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 was failed.
func (*GroupMutation) OldMaxUsers ¶
func (m *GroupMutation) OldMaxUsers(ctx context.Context) (v int, err error)
OldMaxUsers returns the old max_users value of the Group. If the Group 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 database query fails.
func (*GroupMutation) OldName ¶
func (m *GroupMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old name value of the Group. If the Group 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 database query fails.
func (*GroupMutation) OldType ¶
func (m *GroupMutation) OldType(ctx context.Context) (v *string, err error)
OldType returns the old type value of the Group. If the Group 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 database query fails.
func (*GroupMutation) RemoveBlockedIDs ¶
func (m *GroupMutation) RemoveBlockedIDs(ids ...string)
RemoveBlockedIDs removes the blocked edge to User by ids.
func (*GroupMutation) RemoveFileIDs ¶
func (m *GroupMutation) RemoveFileIDs(ids ...string)
RemoveFileIDs removes the files edge to File by ids.
func (*GroupMutation) RemoveUserIDs ¶
func (m *GroupMutation) RemoveUserIDs(ids ...string)
RemoveUserIDs removes the users edge to User by ids.
func (*GroupMutation) RemovedBlockedIDs ¶
func (m *GroupMutation) RemovedBlockedIDs() (ids []string)
RemovedBlocked returns the removed ids of blocked.
func (*GroupMutation) RemovedEdges ¶
func (m *GroupMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*GroupMutation) RemovedFilesIDs ¶
func (m *GroupMutation) RemovedFilesIDs() (ids []string)
RemovedFiles returns the removed ids of files.
func (*GroupMutation) RemovedIDs ¶
func (m *GroupMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*GroupMutation) RemovedUsersIDs ¶
func (m *GroupMutation) RemovedUsersIDs() (ids []string)
RemovedUsers returns the removed ids of users.
func (*GroupMutation) ResetActive ¶
func (m *GroupMutation) ResetActive()
ResetActive reset all changes of the "active" field.
func (*GroupMutation) ResetBlocked ¶
func (m *GroupMutation) ResetBlocked()
ResetBlocked reset all changes of the "blocked" edge.
func (*GroupMutation) ResetEdge ¶
func (m *GroupMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*GroupMutation) ResetExpire ¶
func (m *GroupMutation) ResetExpire()
ResetExpire reset all changes of the "expire" field.
func (*GroupMutation) ResetField ¶
func (m *GroupMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*GroupMutation) ResetFiles ¶
func (m *GroupMutation) ResetFiles()
ResetFiles reset all changes of the "files" edge.
func (*GroupMutation) ResetInfo ¶
func (m *GroupMutation) ResetInfo()
ResetInfo reset all changes of the "info" edge.
func (*GroupMutation) ResetMaxUsers ¶
func (m *GroupMutation) ResetMaxUsers()
ResetMaxUsers reset all changes of the "max_users" field.
func (*GroupMutation) ResetName ¶
func (m *GroupMutation) ResetName()
ResetName reset all changes of the "name" field.
func (*GroupMutation) ResetType ¶
func (m *GroupMutation) ResetType()
ResetType reset all changes of the "type" field.
func (*GroupMutation) ResetUsers ¶
func (m *GroupMutation) ResetUsers()
ResetUsers reset all changes of the "users" edge.
func (*GroupMutation) SetActive ¶
func (m *GroupMutation) SetActive(b bool)
SetActive sets the active field.
func (*GroupMutation) SetExpire ¶
func (m *GroupMutation) SetExpire(t time.Time)
SetExpire sets the expire field.
func (*GroupMutation) SetField ¶
func (m *GroupMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*GroupMutation) SetInfoID ¶
func (m *GroupMutation) SetInfoID(id string)
SetInfoID sets the info edge to GroupInfo by id.
func (*GroupMutation) SetMaxUsers ¶
func (m *GroupMutation) SetMaxUsers(i int)
SetMaxUsers sets the max_users field.
func (*GroupMutation) SetName ¶
func (m *GroupMutation) SetName(s string)
SetName sets the name field.
func (*GroupMutation) SetType ¶
func (m *GroupMutation) SetType(s string)
SetType sets the type field.
func (GroupMutation) Tx ¶
func (m GroupMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*GroupMutation) Type ¶
func (m *GroupMutation) Type() string
Type returns the node type of this mutation (Group).
func (*GroupMutation) TypeCleared ¶
func (m *GroupMutation) TypeCleared() bool
TypeCleared returns if the field type was cleared in this mutation.
func (*GroupMutation) UsersCleared ¶ added in v0.4.3
func (m *GroupMutation) UsersCleared() bool
UsersCleared returns if the edge users was cleared.
func (*GroupMutation) UsersIDs ¶
func (m *GroupMutation) UsersIDs() (ids []string)
UsersIDs returns the users ids in the mutation.
type GroupQuery ¶
type GroupQuery struct {
// contains filtered or unexported fields
}
GroupQuery is the builder for querying Group entities.
func (*GroupQuery) All ¶
func (gq *GroupQuery) All(ctx context.Context) ([]*Group, error)
All executes the query and returns a list of Groups.
func (*GroupQuery) AllX ¶
func (gq *GroupQuery) AllX(ctx context.Context) []*Group
AllX is like All, but panics if an error occurs.
func (*GroupQuery) Clone ¶
func (gq *GroupQuery) Clone() *GroupQuery
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*GroupQuery) Count ¶
func (gq *GroupQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*GroupQuery) CountX ¶
func (gq *GroupQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*GroupQuery) Exist ¶
func (gq *GroupQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*GroupQuery) ExistX ¶
func (gq *GroupQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*GroupQuery) First ¶
func (gq *GroupQuery) First(ctx context.Context) (*Group, error)
First returns the first Group entity in the query. Returns *NotFoundError when no group was found.
func (*GroupQuery) FirstID ¶
func (gq *GroupQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first Group id in the query. Returns *NotFoundError when no id was found.
func (*GroupQuery) FirstIDX ¶ added in v0.5.0
func (gq *GroupQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*GroupQuery) FirstX ¶
func (gq *GroupQuery) FirstX(ctx context.Context) *Group
FirstX is like First, but panics if an error occurs.
func (*GroupQuery) GroupBy ¶
func (gq *GroupQuery) GroupBy(field string, fields ...string) *GroupGroupBy
GroupBy 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 { Active bool `json:"active,omitempty"` Count int `json:"count,omitempty"` } client.Group.Query(). GroupBy(group.FieldActive). Aggregate(ent.Count()). Scan(ctx, &v)
func (*GroupQuery) IDs ¶
func (gq *GroupQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of Group ids.
func (*GroupQuery) IDsX ¶
func (gq *GroupQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*GroupQuery) Limit ¶
func (gq *GroupQuery) Limit(limit int) *GroupQuery
Limit adds a limit step to the query.
func (*GroupQuery) Offset ¶
func (gq *GroupQuery) Offset(offset int) *GroupQuery
Offset adds an offset step to the query.
func (*GroupQuery) Only ¶
func (gq *GroupQuery) Only(ctx context.Context) (*Group, error)
Only returns the only Group entity in the query, returns an error if not exactly one entity was returned.
func (*GroupQuery) OnlyID ¶
func (gq *GroupQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID returns the only Group id in the query, returns an error if not exactly one id was returned.
func (*GroupQuery) OnlyIDX ¶
func (gq *GroupQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*GroupQuery) OnlyX ¶
func (gq *GroupQuery) OnlyX(ctx context.Context) *Group
OnlyX is like Only, but panics if an error occurs.
func (*GroupQuery) Order ¶
func (gq *GroupQuery) Order(o ...OrderFunc) *GroupQuery
Order adds an order step to the query.
func (*GroupQuery) QueryBlocked ¶
func (gq *GroupQuery) QueryBlocked() *UserQuery
QueryBlocked chains the current query on the blocked edge.
func (*GroupQuery) QueryFiles ¶
func (gq *GroupQuery) QueryFiles() *FileQuery
QueryFiles chains the current query on the files edge.
func (*GroupQuery) QueryInfo ¶
func (gq *GroupQuery) QueryInfo() *GroupInfoQuery
QueryInfo chains the current query on the info edge.
func (*GroupQuery) QueryUsers ¶
func (gq *GroupQuery) QueryUsers() *UserQuery
QueryUsers chains the current query on the users edge.
func (*GroupQuery) Select ¶
func (gq *GroupQuery) Select(field string, fields ...string) *GroupSelect
Select one or more fields from the given query.
Example:
var v []struct { Active bool `json:"active,omitempty"` } client.Group.Query(). Select(group.FieldActive). Scan(ctx, &v)
func (*GroupQuery) Where ¶
func (gq *GroupQuery) Where(ps ...predicate.Group) *GroupQuery
Where adds a new predicate for the builder.
func (*GroupQuery) WithBlocked ¶
func (gq *GroupQuery) WithBlocked(opts ...func(*UserQuery)) *GroupQuery
WithBlocked tells the query-builder to eager-loads the nodes that are connected to
the "blocked" edge. The optional arguments used to configure the query builder of the edge.
func (*GroupQuery) WithFiles ¶
func (gq *GroupQuery) WithFiles(opts ...func(*FileQuery)) *GroupQuery
WithFiles tells the query-builder to eager-loads the nodes that are connected to
the "files" edge. The optional arguments used to configure the query builder of the edge.
func (*GroupQuery) WithInfo ¶
func (gq *GroupQuery) WithInfo(opts ...func(*GroupInfoQuery)) *GroupQuery
WithInfo tells the query-builder to eager-loads the nodes that are connected to
the "info" edge. The optional arguments used to configure the query builder of the edge.
func (*GroupQuery) WithUsers ¶
func (gq *GroupQuery) WithUsers(opts ...func(*UserQuery)) *GroupQuery
WithUsers tells the query-builder to eager-loads the nodes that are connected to
the "users" edge. The optional arguments used to configure the query builder of the edge.
type GroupSelect ¶
type GroupSelect struct {
// contains filtered or unexported fields
}
GroupSelect is the builder for select fields of Group entities.
func (*GroupSelect) Bool ¶
func (gs *GroupSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*GroupSelect) BoolX ¶
func (gs *GroupSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*GroupSelect) Bools ¶
func (gs *GroupSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*GroupSelect) BoolsX ¶
func (gs *GroupSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*GroupSelect) Float64 ¶
func (gs *GroupSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*GroupSelect) Float64X ¶
func (gs *GroupSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*GroupSelect) Float64s ¶
func (gs *GroupSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*GroupSelect) Float64sX ¶
func (gs *GroupSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*GroupSelect) Int ¶
func (gs *GroupSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*GroupSelect) IntX ¶
func (gs *GroupSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*GroupSelect) Ints ¶
func (gs *GroupSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*GroupSelect) IntsX ¶
func (gs *GroupSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*GroupSelect) Scan ¶
func (gs *GroupSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*GroupSelect) ScanX ¶
func (gs *GroupSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*GroupSelect) String ¶
func (gs *GroupSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*GroupSelect) StringX ¶
func (gs *GroupSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type GroupUpdate ¶
type GroupUpdate struct {
// contains filtered or unexported fields
}
GroupUpdate is the builder for updating Group entities.
func (*GroupUpdate) AddBlocked ¶
func (gu *GroupUpdate) AddBlocked(u ...*User) *GroupUpdate
AddBlocked adds the blocked edges to User.
func (*GroupUpdate) AddBlockedIDs ¶
func (gu *GroupUpdate) AddBlockedIDs(ids ...string) *GroupUpdate
AddBlockedIDs adds the blocked edge to User by ids.
func (*GroupUpdate) AddFileIDs ¶
func (gu *GroupUpdate) AddFileIDs(ids ...string) *GroupUpdate
AddFileIDs adds the files edge to File by ids.
func (*GroupUpdate) AddFiles ¶
func (gu *GroupUpdate) AddFiles(f ...*File) *GroupUpdate
AddFiles adds the files edges to File.
func (*GroupUpdate) AddMaxUsers ¶
func (gu *GroupUpdate) AddMaxUsers(i int) *GroupUpdate
AddMaxUsers adds i to max_users.
func (*GroupUpdate) AddUserIDs ¶
func (gu *GroupUpdate) AddUserIDs(ids ...string) *GroupUpdate
AddUserIDs adds the users edge to User by ids.
func (*GroupUpdate) AddUsers ¶
func (gu *GroupUpdate) AddUsers(u ...*User) *GroupUpdate
AddUsers adds the users edges to User.
func (*GroupUpdate) ClearBlocked ¶ added in v0.4.3
func (gu *GroupUpdate) ClearBlocked() *GroupUpdate
ClearBlocked clears all "blocked" edges to type User.
func (*GroupUpdate) ClearFiles ¶ added in v0.4.3
func (gu *GroupUpdate) ClearFiles() *GroupUpdate
ClearFiles clears all "files" edges to type File.
func (*GroupUpdate) ClearInfo ¶
func (gu *GroupUpdate) ClearInfo() *GroupUpdate
ClearInfo clears the "info" edge to type GroupInfo.
func (*GroupUpdate) ClearMaxUsers ¶
func (gu *GroupUpdate) ClearMaxUsers() *GroupUpdate
ClearMaxUsers clears the value of max_users.
func (*GroupUpdate) ClearType ¶
func (gu *GroupUpdate) ClearType() *GroupUpdate
ClearType clears the value of type.
func (*GroupUpdate) ClearUsers ¶ added in v0.4.3
func (gu *GroupUpdate) ClearUsers() *GroupUpdate
ClearUsers clears all "users" edges to type User.
func (*GroupUpdate) Exec ¶
func (gu *GroupUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*GroupUpdate) ExecX ¶
func (gu *GroupUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*GroupUpdate) Mutation ¶
func (gu *GroupUpdate) Mutation() *GroupMutation
Mutation returns the GroupMutation object of the builder.
func (*GroupUpdate) RemoveBlocked ¶
func (gu *GroupUpdate) RemoveBlocked(u ...*User) *GroupUpdate
RemoveBlocked removes blocked edges to User.
func (*GroupUpdate) RemoveBlockedIDs ¶
func (gu *GroupUpdate) RemoveBlockedIDs(ids ...string) *GroupUpdate
RemoveBlockedIDs removes the blocked edge to User by ids.
func (*GroupUpdate) RemoveFileIDs ¶
func (gu *GroupUpdate) RemoveFileIDs(ids ...string) *GroupUpdate
RemoveFileIDs removes the files edge to File by ids.
func (*GroupUpdate) RemoveFiles ¶
func (gu *GroupUpdate) RemoveFiles(f ...*File) *GroupUpdate
RemoveFiles removes files edges to File.
func (*GroupUpdate) RemoveUserIDs ¶
func (gu *GroupUpdate) RemoveUserIDs(ids ...string) *GroupUpdate
RemoveUserIDs removes the users edge to User by ids.
func (*GroupUpdate) RemoveUsers ¶
func (gu *GroupUpdate) RemoveUsers(u ...*User) *GroupUpdate
RemoveUsers removes users edges to User.
func (*GroupUpdate) Save ¶
func (gu *GroupUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*GroupUpdate) SaveX ¶
func (gu *GroupUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*GroupUpdate) SetActive ¶
func (gu *GroupUpdate) SetActive(b bool) *GroupUpdate
SetActive sets the active field.
func (*GroupUpdate) SetExpire ¶
func (gu *GroupUpdate) SetExpire(t time.Time) *GroupUpdate
SetExpire sets the expire field.
func (*GroupUpdate) SetInfo ¶
func (gu *GroupUpdate) SetInfo(g *GroupInfo) *GroupUpdate
SetInfo sets the info edge to GroupInfo.
func (*GroupUpdate) SetInfoID ¶
func (gu *GroupUpdate) SetInfoID(id string) *GroupUpdate
SetInfoID sets the info edge to GroupInfo by id.
func (*GroupUpdate) SetMaxUsers ¶
func (gu *GroupUpdate) SetMaxUsers(i int) *GroupUpdate
SetMaxUsers sets the max_users field.
func (*GroupUpdate) SetName ¶
func (gu *GroupUpdate) SetName(s string) *GroupUpdate
SetName sets the name field.
func (*GroupUpdate) SetNillableActive ¶
func (gu *GroupUpdate) SetNillableActive(b *bool) *GroupUpdate
SetNillableActive sets the active field if the given value is not nil.
func (*GroupUpdate) SetNillableMaxUsers ¶
func (gu *GroupUpdate) SetNillableMaxUsers(i *int) *GroupUpdate
SetNillableMaxUsers sets the max_users field if the given value is not nil.
func (*GroupUpdate) SetNillableType ¶
func (gu *GroupUpdate) SetNillableType(s *string) *GroupUpdate
SetNillableType sets the type field if the given value is not nil.
func (*GroupUpdate) SetType ¶
func (gu *GroupUpdate) SetType(s string) *GroupUpdate
SetType sets the type field.
func (*GroupUpdate) Where ¶
func (gu *GroupUpdate) Where(ps ...predicate.Group) *GroupUpdate
Where adds a new predicate for the builder.
type GroupUpdateOne ¶
type GroupUpdateOne struct {
// contains filtered or unexported fields
}
GroupUpdateOne is the builder for updating a single Group entity.
func (*GroupUpdateOne) AddBlocked ¶
func (guo *GroupUpdateOne) AddBlocked(u ...*User) *GroupUpdateOne
AddBlocked adds the blocked edges to User.
func (*GroupUpdateOne) AddBlockedIDs ¶
func (guo *GroupUpdateOne) AddBlockedIDs(ids ...string) *GroupUpdateOne
AddBlockedIDs adds the blocked edge to User by ids.
func (*GroupUpdateOne) AddFileIDs ¶
func (guo *GroupUpdateOne) AddFileIDs(ids ...string) *GroupUpdateOne
AddFileIDs adds the files edge to File by ids.
func (*GroupUpdateOne) AddFiles ¶
func (guo *GroupUpdateOne) AddFiles(f ...*File) *GroupUpdateOne
AddFiles adds the files edges to File.
func (*GroupUpdateOne) AddMaxUsers ¶
func (guo *GroupUpdateOne) AddMaxUsers(i int) *GroupUpdateOne
AddMaxUsers adds i to max_users.
func (*GroupUpdateOne) AddUserIDs ¶
func (guo *GroupUpdateOne) AddUserIDs(ids ...string) *GroupUpdateOne
AddUserIDs adds the users edge to User by ids.
func (*GroupUpdateOne) AddUsers ¶
func (guo *GroupUpdateOne) AddUsers(u ...*User) *GroupUpdateOne
AddUsers adds the users edges to User.
func (*GroupUpdateOne) ClearBlocked ¶ added in v0.4.3
func (guo *GroupUpdateOne) ClearBlocked() *GroupUpdateOne
ClearBlocked clears all "blocked" edges to type User.
func (*GroupUpdateOne) ClearFiles ¶ added in v0.4.3
func (guo *GroupUpdateOne) ClearFiles() *GroupUpdateOne
ClearFiles clears all "files" edges to type File.
func (*GroupUpdateOne) ClearInfo ¶
func (guo *GroupUpdateOne) ClearInfo() *GroupUpdateOne
ClearInfo clears the "info" edge to type GroupInfo.
func (*GroupUpdateOne) ClearMaxUsers ¶
func (guo *GroupUpdateOne) ClearMaxUsers() *GroupUpdateOne
ClearMaxUsers clears the value of max_users.
func (*GroupUpdateOne) ClearType ¶
func (guo *GroupUpdateOne) ClearType() *GroupUpdateOne
ClearType clears the value of type.
func (*GroupUpdateOne) ClearUsers ¶ added in v0.4.3
func (guo *GroupUpdateOne) ClearUsers() *GroupUpdateOne
ClearUsers clears all "users" edges to type User.
func (*GroupUpdateOne) Exec ¶
func (guo *GroupUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*GroupUpdateOne) ExecX ¶
func (guo *GroupUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*GroupUpdateOne) Mutation ¶
func (guo *GroupUpdateOne) Mutation() *GroupMutation
Mutation returns the GroupMutation object of the builder.
func (*GroupUpdateOne) RemoveBlocked ¶
func (guo *GroupUpdateOne) RemoveBlocked(u ...*User) *GroupUpdateOne
RemoveBlocked removes blocked edges to User.
func (*GroupUpdateOne) RemoveBlockedIDs ¶
func (guo *GroupUpdateOne) RemoveBlockedIDs(ids ...string) *GroupUpdateOne
RemoveBlockedIDs removes the blocked edge to User by ids.
func (*GroupUpdateOne) RemoveFileIDs ¶
func (guo *GroupUpdateOne) RemoveFileIDs(ids ...string) *GroupUpdateOne
RemoveFileIDs removes the files edge to File by ids.
func (*GroupUpdateOne) RemoveFiles ¶
func (guo *GroupUpdateOne) RemoveFiles(f ...*File) *GroupUpdateOne
RemoveFiles removes files edges to File.
func (*GroupUpdateOne) RemoveUserIDs ¶
func (guo *GroupUpdateOne) RemoveUserIDs(ids ...string) *GroupUpdateOne
RemoveUserIDs removes the users edge to User by ids.
func (*GroupUpdateOne) RemoveUsers ¶
func (guo *GroupUpdateOne) RemoveUsers(u ...*User) *GroupUpdateOne
RemoveUsers removes users edges to User.
func (*GroupUpdateOne) Save ¶
func (guo *GroupUpdateOne) Save(ctx context.Context) (*Group, error)
Save executes the query and returns the updated entity.
func (*GroupUpdateOne) SaveX ¶
func (guo *GroupUpdateOne) SaveX(ctx context.Context) *Group
SaveX is like Save, but panics if an error occurs.
func (*GroupUpdateOne) SetActive ¶
func (guo *GroupUpdateOne) SetActive(b bool) *GroupUpdateOne
SetActive sets the active field.
func (*GroupUpdateOne) SetExpire ¶
func (guo *GroupUpdateOne) SetExpire(t time.Time) *GroupUpdateOne
SetExpire sets the expire field.
func (*GroupUpdateOne) SetInfo ¶
func (guo *GroupUpdateOne) SetInfo(g *GroupInfo) *GroupUpdateOne
SetInfo sets the info edge to GroupInfo.
func (*GroupUpdateOne) SetInfoID ¶
func (guo *GroupUpdateOne) SetInfoID(id string) *GroupUpdateOne
SetInfoID sets the info edge to GroupInfo by id.
func (*GroupUpdateOne) SetMaxUsers ¶
func (guo *GroupUpdateOne) SetMaxUsers(i int) *GroupUpdateOne
SetMaxUsers sets the max_users field.
func (*GroupUpdateOne) SetName ¶
func (guo *GroupUpdateOne) SetName(s string) *GroupUpdateOne
SetName sets the name field.
func (*GroupUpdateOne) SetNillableActive ¶
func (guo *GroupUpdateOne) SetNillableActive(b *bool) *GroupUpdateOne
SetNillableActive sets the active field if the given value is not nil.
func (*GroupUpdateOne) SetNillableMaxUsers ¶
func (guo *GroupUpdateOne) SetNillableMaxUsers(i *int) *GroupUpdateOne
SetNillableMaxUsers sets the max_users field if the given value is not nil.
func (*GroupUpdateOne) SetNillableType ¶
func (guo *GroupUpdateOne) SetNillableType(s *string) *GroupUpdateOne
SetNillableType sets the type field if the given value is not nil.
func (*GroupUpdateOne) SetType ¶
func (guo *GroupUpdateOne) SetType(s string) *GroupUpdateOne
SetType sets the type field.
type Item ¶
type Item struct { // ID of the ent. ID string `json:"id,omitempty"` // contains filtered or unexported fields }
Item is the model entity for the Item schema.
func (*Item) FromResponse ¶
FromResponse scans the gremlin response data into Item.
func (*Item) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Item) Update ¶
func (i *Item) Update() *ItemUpdateOne
Update returns a builder for updating this Item. Note that, you need to call Item.Unwrap() before calling this method, if this Item was returned from a transaction, and the transaction was committed or rolled back.
type ItemClient ¶
type ItemClient struct {
// contains filtered or unexported fields
}
ItemClient is a client for the Item schema.
func NewItemClient ¶
func NewItemClient(c config) *ItemClient
NewItemClient returns a client for the Item from the given config.
func (*ItemClient) Create ¶
func (c *ItemClient) Create() *ItemCreate
Create returns a create builder for Item.
func (*ItemClient) CreateBulk ¶
func (c *ItemClient) CreateBulk(builders ...*ItemCreate) *ItemCreateBulk
BulkCreate returns a builder for creating a bulk of Item entities.
func (*ItemClient) Delete ¶
func (c *ItemClient) Delete() *ItemDelete
Delete returns a delete builder for Item.
func (*ItemClient) DeleteOne ¶
func (c *ItemClient) DeleteOne(i *Item) *ItemDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*ItemClient) DeleteOneID ¶
func (c *ItemClient) DeleteOneID(id string) *ItemDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*ItemClient) GetX ¶
func (c *ItemClient) GetX(ctx context.Context, id string) *Item
GetX is like Get, but panics if an error occurs.
func (*ItemClient) Query ¶
func (c *ItemClient) Query() *ItemQuery
Query returns a query builder for Item.
func (*ItemClient) Update ¶
func (c *ItemClient) Update() *ItemUpdate
Update returns an update builder for Item.
func (*ItemClient) UpdateOne ¶
func (c *ItemClient) UpdateOne(i *Item) *ItemUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ItemClient) UpdateOneID ¶
func (c *ItemClient) UpdateOneID(id string) *ItemUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ItemClient) Use ¶
func (c *ItemClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `item.Hooks(f(g(h())))`.
type ItemCreate ¶
type ItemCreate struct {
// contains filtered or unexported fields
}
ItemCreate is the builder for creating a Item entity.
func (*ItemCreate) Mutation ¶
func (ic *ItemCreate) Mutation() *ItemMutation
Mutation returns the ItemMutation object of the builder.
type ItemCreateBulk ¶
type ItemCreateBulk struct {
// contains filtered or unexported fields
}
ItemCreateBulk is the builder for creating a bulk of Item entities.
type ItemDelete ¶
type ItemDelete struct {
// contains filtered or unexported fields
}
ItemDelete is the builder for deleting a Item entity.
func (*ItemDelete) Exec ¶
func (id *ItemDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ItemDelete) ExecX ¶
func (id *ItemDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ItemDelete) Where ¶
func (id *ItemDelete) Where(ps ...predicate.Item) *ItemDelete
Where adds a new predicate to the delete builder.
type ItemDeleteOne ¶
type ItemDeleteOne struct {
// contains filtered or unexported fields
}
ItemDeleteOne is the builder for deleting a single Item entity.
func (*ItemDeleteOne) Exec ¶
func (ido *ItemDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ItemDeleteOne) ExecX ¶
func (ido *ItemDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type ItemGroupBy ¶
type ItemGroupBy struct {
// contains filtered or unexported fields
}
ItemGroupBy is the builder for group-by Item entities.
func (*ItemGroupBy) Aggregate ¶
func (igb *ItemGroupBy) Aggregate(fns ...AggregateFunc) *ItemGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ItemGroupBy) Bool ¶
func (igb *ItemGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) BoolX ¶
func (igb *ItemGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*ItemGroupBy) Bools ¶
func (igb *ItemGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) BoolsX ¶
func (igb *ItemGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*ItemGroupBy) Float64 ¶
func (igb *ItemGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) Float64X ¶
func (igb *ItemGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*ItemGroupBy) Float64s ¶
func (igb *ItemGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) Float64sX ¶
func (igb *ItemGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*ItemGroupBy) Int ¶
func (igb *ItemGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) IntX ¶
func (igb *ItemGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*ItemGroupBy) Ints ¶
func (igb *ItemGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) IntsX ¶
func (igb *ItemGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*ItemGroupBy) Scan ¶
func (igb *ItemGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*ItemGroupBy) ScanX ¶
func (igb *ItemGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*ItemGroupBy) String ¶
func (igb *ItemGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*ItemGroupBy) StringX ¶
func (igb *ItemGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type ItemMutation ¶
type ItemMutation struct {
// contains filtered or unexported fields
}
ItemMutation represents an operation that mutate the Items nodes in the graph.
func (*ItemMutation) AddField ¶
func (m *ItemMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*ItemMutation) AddedEdges ¶
func (m *ItemMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ItemMutation) AddedField ¶
func (m *ItemMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*ItemMutation) AddedFields ¶
func (m *ItemMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*ItemMutation) AddedIDs ¶
func (m *ItemMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*ItemMutation) ClearEdge ¶
func (m *ItemMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*ItemMutation) ClearField ¶
func (m *ItemMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*ItemMutation) ClearedEdges ¶
func (m *ItemMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ItemMutation) ClearedFields ¶
func (m *ItemMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ItemMutation) Client ¶
func (m ItemMutation) 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 (*ItemMutation) EdgeCleared ¶
func (m *ItemMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*ItemMutation) Field ¶
func (m *ItemMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*ItemMutation) FieldCleared ¶
func (m *ItemMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*ItemMutation) Fields ¶
func (m *ItemMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*ItemMutation) ID ¶
func (m *ItemMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*ItemMutation) 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 was failed.
func (*ItemMutation) RemovedEdges ¶
func (m *ItemMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ItemMutation) RemovedIDs ¶
func (m *ItemMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*ItemMutation) ResetEdge ¶
func (m *ItemMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*ItemMutation) ResetField ¶
func (m *ItemMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*ItemMutation) SetField ¶
func (m *ItemMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (ItemMutation) Tx ¶
func (m ItemMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ItemMutation) Type ¶
func (m *ItemMutation) Type() string
Type returns the node type of this mutation (Item).
type ItemQuery ¶
type ItemQuery struct {
// contains filtered or unexported fields
}
ItemQuery is the builder for querying Item entities.
func (*ItemQuery) Clone ¶
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ItemQuery) First ¶
First returns the first Item entity in the query. Returns *NotFoundError when no item was found.
func (*ItemQuery) FirstID ¶
FirstID returns the first Item id in the query. Returns *NotFoundError when no id was found.
func (*ItemQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*ItemQuery) GroupBy ¶
func (iq *ItemQuery) GroupBy(field string, fields ...string) *ItemGroupBy
GroupBy used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
func (*ItemQuery) Only ¶
Only returns the only Item entity in the query, returns an error if not exactly one entity was returned.
func (*ItemQuery) OnlyID ¶
OnlyID returns the only Item id in the query, returns an error if not exactly one id was returned.
type ItemSelect ¶
type ItemSelect struct {
// contains filtered or unexported fields
}
ItemSelect is the builder for select fields of Item entities.
func (*ItemSelect) Bool ¶
func (is *ItemSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*ItemSelect) BoolX ¶
func (is *ItemSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*ItemSelect) Bools ¶
func (is *ItemSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*ItemSelect) BoolsX ¶
func (is *ItemSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*ItemSelect) Float64 ¶
func (is *ItemSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*ItemSelect) Float64X ¶
func (is *ItemSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*ItemSelect) Float64s ¶
func (is *ItemSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*ItemSelect) Float64sX ¶
func (is *ItemSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*ItemSelect) Int ¶
func (is *ItemSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*ItemSelect) IntX ¶
func (is *ItemSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*ItemSelect) Ints ¶
func (is *ItemSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*ItemSelect) IntsX ¶
func (is *ItemSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*ItemSelect) Scan ¶
func (is *ItemSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*ItemSelect) ScanX ¶
func (is *ItemSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*ItemSelect) String ¶
func (is *ItemSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*ItemSelect) StringX ¶
func (is *ItemSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type ItemUpdate ¶
type ItemUpdate struct {
// contains filtered or unexported fields
}
ItemUpdate is the builder for updating Item entities.
func (*ItemUpdate) Exec ¶
func (iu *ItemUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ItemUpdate) ExecX ¶
func (iu *ItemUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ItemUpdate) Mutation ¶
func (iu *ItemUpdate) Mutation() *ItemMutation
Mutation returns the ItemMutation object of the builder.
func (*ItemUpdate) Save ¶
func (iu *ItemUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*ItemUpdate) SaveX ¶
func (iu *ItemUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ItemUpdate) Where ¶
func (iu *ItemUpdate) Where(ps ...predicate.Item) *ItemUpdate
Where adds a new predicate for the builder.
type ItemUpdateOne ¶
type ItemUpdateOne struct {
// contains filtered or unexported fields
}
ItemUpdateOne is the builder for updating a single Item entity.
func (*ItemUpdateOne) Exec ¶
func (iuo *ItemUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ItemUpdateOne) ExecX ¶
func (iuo *ItemUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ItemUpdateOne) Mutation ¶
func (iuo *ItemUpdateOne) Mutation() *ItemMutation
Mutation returns the ItemMutation object of the builder.
type MutateFunc ¶
type MutateFunc = ent.MutateFunc
ent aliases to avoid import conflict in user's code.
type Node ¶
type Node struct { // ID of the ent. ID string `json:"id,omitempty"` // Value holds the value of the "value" field. Value int `json:"value,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the NodeQuery when eager-loading is set. Edges NodeEdges `json:"edges"` // contains filtered or unexported fields }
Node is the model entity for the Node schema.
func (*Node) FromResponse ¶
FromResponse scans the gremlin response data into Node.
func (*Node) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Node) Update ¶
func (n *Node) Update() *NodeUpdateOne
Update returns a builder for updating this Node. Note that, you need to call Node.Unwrap() before calling this method, if this Node was returned from a transaction, and the transaction was committed or rolled back.
type NodeClient ¶
type NodeClient struct {
// contains filtered or unexported fields
}
NodeClient is a client for the Node schema.
func NewNodeClient ¶
func NewNodeClient(c config) *NodeClient
NewNodeClient returns a client for the Node from the given config.
func (*NodeClient) Create ¶
func (c *NodeClient) Create() *NodeCreate
Create returns a create builder for Node.
func (*NodeClient) CreateBulk ¶
func (c *NodeClient) CreateBulk(builders ...*NodeCreate) *NodeCreateBulk
BulkCreate returns a builder for creating a bulk of Node entities.
func (*NodeClient) Delete ¶
func (c *NodeClient) Delete() *NodeDelete
Delete returns a delete builder for Node.
func (*NodeClient) DeleteOne ¶
func (c *NodeClient) DeleteOne(n *Node) *NodeDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*NodeClient) DeleteOneID ¶
func (c *NodeClient) DeleteOneID(id string) *NodeDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*NodeClient) GetX ¶
func (c *NodeClient) GetX(ctx context.Context, id string) *Node
GetX is like Get, but panics if an error occurs.
func (*NodeClient) Query ¶
func (c *NodeClient) Query() *NodeQuery
Query returns a query builder for Node.
func (*NodeClient) QueryNext ¶
func (c *NodeClient) QueryNext(n *Node) *NodeQuery
QueryNext queries the next edge of a Node.
func (*NodeClient) QueryPrev ¶
func (c *NodeClient) QueryPrev(n *Node) *NodeQuery
QueryPrev queries the prev edge of a Node.
func (*NodeClient) Update ¶
func (c *NodeClient) Update() *NodeUpdate
Update returns an update builder for Node.
func (*NodeClient) UpdateOne ¶
func (c *NodeClient) UpdateOne(n *Node) *NodeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*NodeClient) UpdateOneID ¶
func (c *NodeClient) UpdateOneID(id string) *NodeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*NodeClient) Use ¶
func (c *NodeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `node.Hooks(f(g(h())))`.
type NodeCreate ¶
type NodeCreate struct {
// contains filtered or unexported fields
}
NodeCreate is the builder for creating a Node entity.
func (*NodeCreate) Mutation ¶
func (nc *NodeCreate) Mutation() *NodeMutation
Mutation returns the NodeMutation object of the builder.
func (*NodeCreate) Save ¶
func (nc *NodeCreate) Save(ctx context.Context) (*Node, error)
Save creates the Node in the database.
func (*NodeCreate) SaveX ¶
func (nc *NodeCreate) SaveX(ctx context.Context) *Node
SaveX calls Save and panics if Save returns an error.
func (*NodeCreate) SetNext ¶
func (nc *NodeCreate) SetNext(n *Node) *NodeCreate
SetNext sets the next edge to Node.
func (*NodeCreate) SetNextID ¶
func (nc *NodeCreate) SetNextID(id string) *NodeCreate
SetNextID sets the next edge to Node by id.
func (*NodeCreate) SetNillableNextID ¶
func (nc *NodeCreate) SetNillableNextID(id *string) *NodeCreate
SetNillableNextID sets the next edge to Node by id if the given value is not nil.
func (*NodeCreate) SetNillablePrevID ¶
func (nc *NodeCreate) SetNillablePrevID(id *string) *NodeCreate
SetNillablePrevID sets the prev edge to Node by id if the given value is not nil.
func (*NodeCreate) SetNillableValue ¶
func (nc *NodeCreate) SetNillableValue(i *int) *NodeCreate
SetNillableValue sets the value field if the given value is not nil.
func (*NodeCreate) SetPrev ¶
func (nc *NodeCreate) SetPrev(n *Node) *NodeCreate
SetPrev sets the prev edge to Node.
func (*NodeCreate) SetPrevID ¶
func (nc *NodeCreate) SetPrevID(id string) *NodeCreate
SetPrevID sets the prev edge to Node by id.
func (*NodeCreate) SetValue ¶
func (nc *NodeCreate) SetValue(i int) *NodeCreate
SetValue sets the value field.
type NodeCreateBulk ¶
type NodeCreateBulk struct {
// contains filtered or unexported fields
}
NodeCreateBulk is the builder for creating a bulk of Node entities.
type NodeDelete ¶
type NodeDelete struct {
// contains filtered or unexported fields
}
NodeDelete is the builder for deleting a Node entity.
func (*NodeDelete) Exec ¶
func (nd *NodeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*NodeDelete) ExecX ¶
func (nd *NodeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*NodeDelete) Where ¶
func (nd *NodeDelete) Where(ps ...predicate.Node) *NodeDelete
Where adds a new predicate to the delete builder.
type NodeDeleteOne ¶
type NodeDeleteOne struct {
// contains filtered or unexported fields
}
NodeDeleteOne is the builder for deleting a single Node entity.
func (*NodeDeleteOne) Exec ¶
func (ndo *NodeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*NodeDeleteOne) ExecX ¶
func (ndo *NodeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type NodeEdges ¶
type NodeEdges struct { // Prev holds the value of the prev edge. Prev *Node `gqlgen:prev` // Next holds the value of the next edge. Next *Node `gqlgen:next` // contains filtered or unexported fields }
NodeEdges holds the relations/edges for other nodes in the graph.
type NodeGroupBy ¶
type NodeGroupBy struct {
// contains filtered or unexported fields
}
NodeGroupBy is the builder for group-by Node entities.
func (*NodeGroupBy) Aggregate ¶
func (ngb *NodeGroupBy) Aggregate(fns ...AggregateFunc) *NodeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*NodeGroupBy) Bool ¶
func (ngb *NodeGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) BoolX ¶
func (ngb *NodeGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*NodeGroupBy) Bools ¶
func (ngb *NodeGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) BoolsX ¶
func (ngb *NodeGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*NodeGroupBy) Float64 ¶
func (ngb *NodeGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) Float64X ¶
func (ngb *NodeGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*NodeGroupBy) Float64s ¶
func (ngb *NodeGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) Float64sX ¶
func (ngb *NodeGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*NodeGroupBy) Int ¶
func (ngb *NodeGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) IntX ¶
func (ngb *NodeGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*NodeGroupBy) Ints ¶
func (ngb *NodeGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) IntsX ¶
func (ngb *NodeGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*NodeGroupBy) Scan ¶
func (ngb *NodeGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*NodeGroupBy) ScanX ¶
func (ngb *NodeGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*NodeGroupBy) String ¶
func (ngb *NodeGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*NodeGroupBy) StringX ¶
func (ngb *NodeGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type NodeMutation ¶
type NodeMutation struct {
// contains filtered or unexported fields
}
NodeMutation represents an operation that mutate the Nodes nodes in the graph.
func (*NodeMutation) AddField ¶
func (m *NodeMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*NodeMutation) AddedEdges ¶
func (m *NodeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*NodeMutation) AddedField ¶
func (m *NodeMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*NodeMutation) AddedFields ¶
func (m *NodeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*NodeMutation) AddedIDs ¶
func (m *NodeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*NodeMutation) AddedValue ¶
func (m *NodeMutation) AddedValue() (r int, exists bool)
AddedValue returns the value that was added to the value field in this mutation.
func (*NodeMutation) ClearEdge ¶
func (m *NodeMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*NodeMutation) ClearField ¶
func (m *NodeMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*NodeMutation) ClearNext ¶
func (m *NodeMutation) ClearNext()
ClearNext clears the next edge to Node.
func (*NodeMutation) ClearPrev ¶
func (m *NodeMutation) ClearPrev()
ClearPrev clears the prev edge to Node.
func (*NodeMutation) ClearValue ¶
func (m *NodeMutation) ClearValue()
ClearValue clears the value of value.
func (*NodeMutation) ClearedEdges ¶
func (m *NodeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*NodeMutation) ClearedFields ¶
func (m *NodeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (NodeMutation) Client ¶
func (m NodeMutation) 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 (*NodeMutation) EdgeCleared ¶
func (m *NodeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*NodeMutation) Field ¶
func (m *NodeMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*NodeMutation) FieldCleared ¶
func (m *NodeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*NodeMutation) Fields ¶
func (m *NodeMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*NodeMutation) ID ¶
func (m *NodeMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*NodeMutation) NextCleared ¶
func (m *NodeMutation) NextCleared() bool
NextCleared returns if the edge next was cleared.
func (*NodeMutation) NextID ¶
func (m *NodeMutation) NextID() (id string, exists bool)
NextID returns the next id in the mutation.
func (*NodeMutation) NextIDs ¶
func (m *NodeMutation) NextIDs() (ids []string)
NextIDs returns the next ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use NextID instead. It exists only for internal usage by the builders.
func (*NodeMutation) 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 was failed.
func (*NodeMutation) OldValue ¶
func (m *NodeMutation) OldValue(ctx context.Context) (v int, err error)
OldValue returns the old value value of the Node. If the Node 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 database query fails.
func (*NodeMutation) PrevCleared ¶
func (m *NodeMutation) PrevCleared() bool
PrevCleared returns if the edge prev was cleared.
func (*NodeMutation) PrevID ¶
func (m *NodeMutation) PrevID() (id string, exists bool)
PrevID returns the prev id in the mutation.
func (*NodeMutation) PrevIDs ¶
func (m *NodeMutation) PrevIDs() (ids []string)
PrevIDs returns the prev ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use PrevID instead. It exists only for internal usage by the builders.
func (*NodeMutation) RemovedEdges ¶
func (m *NodeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*NodeMutation) RemovedIDs ¶
func (m *NodeMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*NodeMutation) ResetEdge ¶
func (m *NodeMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*NodeMutation) ResetField ¶
func (m *NodeMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*NodeMutation) ResetNext ¶
func (m *NodeMutation) ResetNext()
ResetNext reset all changes of the "next" edge.
func (*NodeMutation) ResetPrev ¶
func (m *NodeMutation) ResetPrev()
ResetPrev reset all changes of the "prev" edge.
func (*NodeMutation) ResetValue ¶
func (m *NodeMutation) ResetValue()
ResetValue reset all changes of the "value" field.
func (*NodeMutation) SetField ¶
func (m *NodeMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*NodeMutation) SetNextID ¶
func (m *NodeMutation) SetNextID(id string)
SetNextID sets the next edge to Node by id.
func (*NodeMutation) SetPrevID ¶
func (m *NodeMutation) SetPrevID(id string)
SetPrevID sets the prev edge to Node by id.
func (*NodeMutation) SetValue ¶
func (m *NodeMutation) SetValue(i int)
SetValue sets the value field.
func (NodeMutation) Tx ¶
func (m NodeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*NodeMutation) Type ¶
func (m *NodeMutation) Type() string
Type returns the node type of this mutation (Node).
func (*NodeMutation) Value ¶
func (m *NodeMutation) Value() (r int, exists bool)
Value returns the value value in the mutation.
func (*NodeMutation) ValueCleared ¶
func (m *NodeMutation) ValueCleared() bool
ValueCleared returns if the field value was cleared in this mutation.
type NodeQuery ¶
type NodeQuery struct {
// contains filtered or unexported fields
}
NodeQuery is the builder for querying Node entities.
func (*NodeQuery) Clone ¶
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*NodeQuery) First ¶
First returns the first Node entity in the query. Returns *NotFoundError when no node was found.
func (*NodeQuery) FirstID ¶
FirstID returns the first Node id in the query. Returns *NotFoundError when no id was found.
func (*NodeQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*NodeQuery) GroupBy ¶
func (nq *NodeQuery) GroupBy(field string, fields ...string) *NodeGroupBy
GroupBy 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 { Value int `json:"value,omitempty"` Count int `json:"count,omitempty"` } client.Node.Query(). GroupBy(node.FieldValue). Aggregate(ent.Count()). Scan(ctx, &v)
func (*NodeQuery) Only ¶
Only returns the only Node entity in the query, returns an error if not exactly one entity was returned.
func (*NodeQuery) OnlyID ¶
OnlyID returns the only Node id in the query, returns an error if not exactly one id was returned.
func (*NodeQuery) Select ¶
func (nq *NodeQuery) Select(field string, fields ...string) *NodeSelect
Select one or more fields from the given query.
Example:
var v []struct { Value int `json:"value,omitempty"` } client.Node.Query(). Select(node.FieldValue). Scan(ctx, &v)
type NodeSelect ¶
type NodeSelect struct {
// contains filtered or unexported fields
}
NodeSelect is the builder for select fields of Node entities.
func (*NodeSelect) Bool ¶
func (ns *NodeSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*NodeSelect) BoolX ¶
func (ns *NodeSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*NodeSelect) Bools ¶
func (ns *NodeSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*NodeSelect) BoolsX ¶
func (ns *NodeSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*NodeSelect) Float64 ¶
func (ns *NodeSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*NodeSelect) Float64X ¶
func (ns *NodeSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*NodeSelect) Float64s ¶
func (ns *NodeSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*NodeSelect) Float64sX ¶
func (ns *NodeSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*NodeSelect) Int ¶
func (ns *NodeSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*NodeSelect) IntX ¶
func (ns *NodeSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*NodeSelect) Ints ¶
func (ns *NodeSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*NodeSelect) IntsX ¶
func (ns *NodeSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*NodeSelect) Scan ¶
func (ns *NodeSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*NodeSelect) ScanX ¶
func (ns *NodeSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*NodeSelect) String ¶
func (ns *NodeSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*NodeSelect) StringX ¶
func (ns *NodeSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type NodeUpdate ¶
type NodeUpdate struct {
// contains filtered or unexported fields
}
NodeUpdate is the builder for updating Node entities.
func (*NodeUpdate) AddValue ¶
func (nu *NodeUpdate) AddValue(i int) *NodeUpdate
AddValue adds i to value.
func (*NodeUpdate) ClearNext ¶
func (nu *NodeUpdate) ClearNext() *NodeUpdate
ClearNext clears the "next" edge to type Node.
func (*NodeUpdate) ClearPrev ¶
func (nu *NodeUpdate) ClearPrev() *NodeUpdate
ClearPrev clears the "prev" edge to type Node.
func (*NodeUpdate) ClearValue ¶
func (nu *NodeUpdate) ClearValue() *NodeUpdate
ClearValue clears the value of value.
func (*NodeUpdate) Exec ¶
func (nu *NodeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeUpdate) ExecX ¶
func (nu *NodeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeUpdate) Mutation ¶
func (nu *NodeUpdate) Mutation() *NodeMutation
Mutation returns the NodeMutation object of the builder.
func (*NodeUpdate) Save ¶
func (nu *NodeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*NodeUpdate) SaveX ¶
func (nu *NodeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*NodeUpdate) SetNext ¶
func (nu *NodeUpdate) SetNext(n *Node) *NodeUpdate
SetNext sets the next edge to Node.
func (*NodeUpdate) SetNextID ¶
func (nu *NodeUpdate) SetNextID(id string) *NodeUpdate
SetNextID sets the next edge to Node by id.
func (*NodeUpdate) SetNillableNextID ¶
func (nu *NodeUpdate) SetNillableNextID(id *string) *NodeUpdate
SetNillableNextID sets the next edge to Node by id if the given value is not nil.
func (*NodeUpdate) SetNillablePrevID ¶
func (nu *NodeUpdate) SetNillablePrevID(id *string) *NodeUpdate
SetNillablePrevID sets the prev edge to Node by id if the given value is not nil.
func (*NodeUpdate) SetNillableValue ¶
func (nu *NodeUpdate) SetNillableValue(i *int) *NodeUpdate
SetNillableValue sets the value field if the given value is not nil.
func (*NodeUpdate) SetPrev ¶
func (nu *NodeUpdate) SetPrev(n *Node) *NodeUpdate
SetPrev sets the prev edge to Node.
func (*NodeUpdate) SetPrevID ¶
func (nu *NodeUpdate) SetPrevID(id string) *NodeUpdate
SetPrevID sets the prev edge to Node by id.
func (*NodeUpdate) SetValue ¶
func (nu *NodeUpdate) SetValue(i int) *NodeUpdate
SetValue sets the value field.
func (*NodeUpdate) Where ¶
func (nu *NodeUpdate) Where(ps ...predicate.Node) *NodeUpdate
Where adds a new predicate for the builder.
type NodeUpdateOne ¶
type NodeUpdateOne struct {
// contains filtered or unexported fields
}
NodeUpdateOne is the builder for updating a single Node entity.
func (*NodeUpdateOne) AddValue ¶
func (nuo *NodeUpdateOne) AddValue(i int) *NodeUpdateOne
AddValue adds i to value.
func (*NodeUpdateOne) ClearNext ¶
func (nuo *NodeUpdateOne) ClearNext() *NodeUpdateOne
ClearNext clears the "next" edge to type Node.
func (*NodeUpdateOne) ClearPrev ¶
func (nuo *NodeUpdateOne) ClearPrev() *NodeUpdateOne
ClearPrev clears the "prev" edge to type Node.
func (*NodeUpdateOne) ClearValue ¶
func (nuo *NodeUpdateOne) ClearValue() *NodeUpdateOne
ClearValue clears the value of value.
func (*NodeUpdateOne) Exec ¶
func (nuo *NodeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*NodeUpdateOne) ExecX ¶
func (nuo *NodeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeUpdateOne) Mutation ¶
func (nuo *NodeUpdateOne) Mutation() *NodeMutation
Mutation returns the NodeMutation object of the builder.
func (*NodeUpdateOne) Save ¶
func (nuo *NodeUpdateOne) Save(ctx context.Context) (*Node, error)
Save executes the query and returns the updated entity.
func (*NodeUpdateOne) SaveX ¶
func (nuo *NodeUpdateOne) SaveX(ctx context.Context) *Node
SaveX is like Save, but panics if an error occurs.
func (*NodeUpdateOne) SetNext ¶
func (nuo *NodeUpdateOne) SetNext(n *Node) *NodeUpdateOne
SetNext sets the next edge to Node.
func (*NodeUpdateOne) SetNextID ¶
func (nuo *NodeUpdateOne) SetNextID(id string) *NodeUpdateOne
SetNextID sets the next edge to Node by id.
func (*NodeUpdateOne) SetNillableNextID ¶
func (nuo *NodeUpdateOne) SetNillableNextID(id *string) *NodeUpdateOne
SetNillableNextID sets the next edge to Node by id if the given value is not nil.
func (*NodeUpdateOne) SetNillablePrevID ¶
func (nuo *NodeUpdateOne) SetNillablePrevID(id *string) *NodeUpdateOne
SetNillablePrevID sets the prev edge to Node by id if the given value is not nil.
func (*NodeUpdateOne) SetNillableValue ¶
func (nuo *NodeUpdateOne) SetNillableValue(i *int) *NodeUpdateOne
SetNillableValue sets the value field if the given value is not nil.
func (*NodeUpdateOne) SetPrev ¶
func (nuo *NodeUpdateOne) SetPrev(n *Node) *NodeUpdateOne
SetPrev sets the prev edge to Node.
func (*NodeUpdateOne) SetPrevID ¶
func (nuo *NodeUpdateOne) SetPrevID(id string) *NodeUpdateOne
SetPrevID sets the prev edge to Node by id.
func (*NodeUpdateOne) SetValue ¶
func (nuo *NodeUpdateOne) SetValue(i int) *NodeUpdateOne
SetValue sets the value field.
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 Pet ¶
type Pet struct { // ID of the ent. ID string `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the PetQuery when eager-loading is set. Edges PetEdges `json:"edges"` // contains filtered or unexported fields }
Pet is the model entity for the Pet schema.
func (*Pet) FromResponse ¶
FromResponse scans the gremlin response data into Pet.
func (*Pet) QueryOwner ¶
QueryOwner queries the owner edge of the Pet.
func (*Pet) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Pet) Update ¶
func (pe *Pet) Update() *PetUpdateOne
Update returns a builder for updating this Pet. Note that, you need to call Pet.Unwrap() before calling this method, if this Pet was returned from a transaction, and the transaction was committed or rolled back.
type PetClient ¶
type PetClient struct {
// contains filtered or unexported fields
}
PetClient is a client for the Pet schema.
func NewPetClient ¶
func NewPetClient(c config) *PetClient
NewPetClient returns a client for the Pet from the given config.
func (*PetClient) CreateBulk ¶
func (c *PetClient) CreateBulk(builders ...*PetCreate) *PetCreateBulk
BulkCreate returns a builder for creating a bulk of Pet entities.
func (*PetClient) DeleteOne ¶
func (c *PetClient) DeleteOne(pe *Pet) *PetDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*PetClient) DeleteOneID ¶
func (c *PetClient) DeleteOneID(id string) *PetDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*PetClient) QueryOwner ¶
QueryOwner queries the owner edge of a Pet.
func (*PetClient) UpdateOne ¶
func (c *PetClient) UpdateOne(pe *Pet) *PetUpdateOne
UpdateOne returns an update builder for the given entity.
func (*PetClient) UpdateOneID ¶
func (c *PetClient) UpdateOneID(id string) *PetUpdateOne
UpdateOneID returns an update builder for the given id.
type PetCreate ¶
type PetCreate struct {
// contains filtered or unexported fields
}
PetCreate is the builder for creating a Pet entity.
func (*PetCreate) Mutation ¶
func (pc *PetCreate) Mutation() *PetMutation
Mutation returns the PetMutation object of the builder.
func (*PetCreate) SetNillableOwnerID ¶
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*PetCreate) SetNillableTeamID ¶
SetNillableTeamID sets the team edge to User by id if the given value is not nil.
func (*PetCreate) SetOwnerID ¶
SetOwnerID sets the owner edge to User by id.
type PetCreateBulk ¶
type PetCreateBulk struct {
// contains filtered or unexported fields
}
PetCreateBulk is the builder for creating a bulk of Pet entities.
type PetDelete ¶
type PetDelete struct {
// contains filtered or unexported fields
}
PetDelete is the builder for deleting a Pet entity.
func (*PetDelete) Exec ¶
Exec executes the deletion query and returns how many vertices were deleted.
type PetDeleteOne ¶
type PetDeleteOne struct {
// contains filtered or unexported fields
}
PetDeleteOne is the builder for deleting a single Pet entity.
func (*PetDeleteOne) Exec ¶
func (pdo *PetDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*PetDeleteOne) ExecX ¶
func (pdo *PetDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type PetEdges ¶
type PetEdges struct { // Team holds the value of the team edge. Team *User // Owner holds the value of the owner edge. Owner *User // contains filtered or unexported fields }
PetEdges holds the relations/edges for other nodes in the graph.
func (PetEdges) OwnerOrErr ¶
OwnerOrErr returns the Owner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type PetGroupBy ¶
type PetGroupBy struct {
// contains filtered or unexported fields
}
PetGroupBy is the builder for group-by Pet entities.
func (*PetGroupBy) Aggregate ¶
func (pgb *PetGroupBy) Aggregate(fns ...AggregateFunc) *PetGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*PetGroupBy) Bool ¶
func (pgb *PetGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) BoolX ¶
func (pgb *PetGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*PetGroupBy) Bools ¶
func (pgb *PetGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) BoolsX ¶
func (pgb *PetGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*PetGroupBy) Float64 ¶
func (pgb *PetGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) Float64X ¶
func (pgb *PetGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*PetGroupBy) Float64s ¶
func (pgb *PetGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) Float64sX ¶
func (pgb *PetGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*PetGroupBy) Int ¶
func (pgb *PetGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) IntX ¶
func (pgb *PetGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*PetGroupBy) Ints ¶
func (pgb *PetGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) IntsX ¶
func (pgb *PetGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*PetGroupBy) Scan ¶
func (pgb *PetGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*PetGroupBy) ScanX ¶
func (pgb *PetGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*PetGroupBy) String ¶
func (pgb *PetGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*PetGroupBy) StringX ¶
func (pgb *PetGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type PetMutation ¶
type PetMutation struct {
// contains filtered or unexported fields
}
PetMutation represents an operation that mutate the Pets nodes in the graph.
func (*PetMutation) AddField ¶
func (m *PetMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*PetMutation) AddedEdges ¶
func (m *PetMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*PetMutation) AddedField ¶
func (m *PetMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*PetMutation) AddedFields ¶
func (m *PetMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*PetMutation) AddedIDs ¶
func (m *PetMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*PetMutation) ClearEdge ¶
func (m *PetMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*PetMutation) ClearField ¶
func (m *PetMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*PetMutation) ClearOwner ¶
func (m *PetMutation) ClearOwner()
ClearOwner clears the owner edge to User.
func (*PetMutation) ClearTeam ¶
func (m *PetMutation) ClearTeam()
ClearTeam clears the team edge to User.
func (*PetMutation) ClearedEdges ¶
func (m *PetMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*PetMutation) ClearedFields ¶
func (m *PetMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (PetMutation) Client ¶
func (m PetMutation) 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 (*PetMutation) EdgeCleared ¶
func (m *PetMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*PetMutation) Field ¶
func (m *PetMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*PetMutation) FieldCleared ¶
func (m *PetMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*PetMutation) Fields ¶
func (m *PetMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*PetMutation) ID ¶
func (m *PetMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*PetMutation) Name ¶
func (m *PetMutation) Name() (r string, exists bool)
Name returns the name value in the mutation.
func (*PetMutation) 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 was failed.
func (*PetMutation) OldName ¶
func (m *PetMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old name value of the Pet. If the Pet 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 database query fails.
func (*PetMutation) OwnerCleared ¶
func (m *PetMutation) OwnerCleared() bool
OwnerCleared returns if the edge owner was cleared.
func (*PetMutation) OwnerID ¶
func (m *PetMutation) OwnerID() (id string, exists bool)
OwnerID returns the owner id in the mutation.
func (*PetMutation) OwnerIDs ¶
func (m *PetMutation) OwnerIDs() (ids []string)
OwnerIDs returns the owner 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 (*PetMutation) RemovedEdges ¶
func (m *PetMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*PetMutation) RemovedIDs ¶
func (m *PetMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*PetMutation) ResetEdge ¶
func (m *PetMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*PetMutation) ResetField ¶
func (m *PetMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*PetMutation) ResetName ¶
func (m *PetMutation) ResetName()
ResetName reset all changes of the "name" field.
func (*PetMutation) ResetOwner ¶
func (m *PetMutation) ResetOwner()
ResetOwner reset all changes of the "owner" edge.
func (*PetMutation) ResetTeam ¶
func (m *PetMutation) ResetTeam()
ResetTeam reset all changes of the "team" edge.
func (*PetMutation) SetField ¶
func (m *PetMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*PetMutation) SetOwnerID ¶
func (m *PetMutation) SetOwnerID(id string)
SetOwnerID sets the owner edge to User by id.
func (*PetMutation) SetTeamID ¶
func (m *PetMutation) SetTeamID(id string)
SetTeamID sets the team edge to User by id.
func (*PetMutation) TeamCleared ¶
func (m *PetMutation) TeamCleared() bool
TeamCleared returns if the edge team was cleared.
func (*PetMutation) TeamID ¶
func (m *PetMutation) TeamID() (id string, exists bool)
TeamID returns the team id in the mutation.
func (*PetMutation) TeamIDs ¶
func (m *PetMutation) TeamIDs() (ids []string)
TeamIDs returns the team ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use TeamID instead. It exists only for internal usage by the builders.
func (PetMutation) Tx ¶
func (m PetMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*PetMutation) Type ¶
func (m *PetMutation) Type() string
Type returns the node type of this mutation (Pet).
type PetQuery ¶
type PetQuery struct {
// contains filtered or unexported fields
}
PetQuery is the builder for querying Pet entities.
func (*PetQuery) Clone ¶
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*PetQuery) First ¶
First returns the first Pet entity in the query. Returns *NotFoundError when no pet was found.
func (*PetQuery) FirstID ¶
FirstID returns the first Pet id in the query. Returns *NotFoundError when no id was found.
func (*PetQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*PetQuery) GroupBy ¶
func (pq *PetQuery) GroupBy(field string, fields ...string) *PetGroupBy
GroupBy 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.Pet.Query(). GroupBy(pet.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*PetQuery) Only ¶
Only returns the only Pet entity in the query, returns an error if not exactly one entity was returned.
func (*PetQuery) OnlyID ¶
OnlyID returns the only Pet id in the query, returns an error if not exactly one id was returned.
func (*PetQuery) QueryOwner ¶
QueryOwner chains the current query on the owner edge.
func (*PetQuery) Select ¶
Select one or more fields from the given query.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.Pet.Query(). Select(pet.FieldName). Scan(ctx, &v)
type PetSelect ¶
type PetSelect struct {
// contains filtered or unexported fields
}
PetSelect is the builder for select fields of Pet entities.
func (*PetSelect) Bool ¶
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*PetSelect) Bools ¶
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*PetSelect) Float64 ¶
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*PetSelect) Float64s ¶
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*PetSelect) Int ¶
Int returns a single int from selector. It is only allowed when selecting one field.
func (*PetSelect) Ints ¶
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*PetSelect) String ¶
String returns a single string from selector. It is only allowed when selecting one field.
type PetUpdate ¶
type PetUpdate struct {
// contains filtered or unexported fields
}
PetUpdate is the builder for updating Pet entities.
func (*PetUpdate) ClearOwner ¶
ClearOwner clears the "owner" edge to type User.
func (*PetUpdate) Mutation ¶
func (pu *PetUpdate) Mutation() *PetMutation
Mutation returns the PetMutation object of the builder.
func (*PetUpdate) Save ¶
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*PetUpdate) SetNillableOwnerID ¶
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*PetUpdate) SetNillableTeamID ¶
SetNillableTeamID sets the team edge to User by id if the given value is not nil.
func (*PetUpdate) SetOwnerID ¶
SetOwnerID sets the owner edge to User by id.
type PetUpdateOne ¶
type PetUpdateOne struct {
// contains filtered or unexported fields
}
PetUpdateOne is the builder for updating a single Pet entity.
func (*PetUpdateOne) ClearOwner ¶
func (puo *PetUpdateOne) ClearOwner() *PetUpdateOne
ClearOwner clears the "owner" edge to type User.
func (*PetUpdateOne) ClearTeam ¶
func (puo *PetUpdateOne) ClearTeam() *PetUpdateOne
ClearTeam clears the "team" edge to type User.
func (*PetUpdateOne) Exec ¶
func (puo *PetUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*PetUpdateOne) ExecX ¶
func (puo *PetUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PetUpdateOne) Mutation ¶
func (puo *PetUpdateOne) Mutation() *PetMutation
Mutation returns the PetMutation object of the builder.
func (*PetUpdateOne) Save ¶
func (puo *PetUpdateOne) Save(ctx context.Context) (*Pet, error)
Save executes the query and returns the updated entity.
func (*PetUpdateOne) SaveX ¶
func (puo *PetUpdateOne) SaveX(ctx context.Context) *Pet
SaveX is like Save, but panics if an error occurs.
func (*PetUpdateOne) SetName ¶
func (puo *PetUpdateOne) SetName(s string) *PetUpdateOne
SetName sets the name field.
func (*PetUpdateOne) SetNillableOwnerID ¶
func (puo *PetUpdateOne) SetNillableOwnerID(id *string) *PetUpdateOne
SetNillableOwnerID sets the owner edge to User by id if the given value is not nil.
func (*PetUpdateOne) SetNillableTeamID ¶
func (puo *PetUpdateOne) SetNillableTeamID(id *string) *PetUpdateOne
SetNillableTeamID sets the team edge to User by id if the given value is not nil.
func (*PetUpdateOne) SetOwner ¶
func (puo *PetUpdateOne) SetOwner(u *User) *PetUpdateOne
SetOwner sets the owner edge to User.
func (*PetUpdateOne) SetOwnerID ¶
func (puo *PetUpdateOne) SetOwnerID(id string) *PetUpdateOne
SetOwnerID sets the owner edge to User by id.
func (*PetUpdateOne) SetTeam ¶
func (puo *PetUpdateOne) SetTeam(u *User) *PetUpdateOne
SetTeam sets the team edge to User.
func (*PetUpdateOne) SetTeamID ¶
func (puo *PetUpdateOne) SetTeamID(id string) *PetUpdateOne
SetTeamID sets the team edge to User by id.
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(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 Rollbacker method.
type Spec ¶
type Spec struct { // ID of the ent. ID string `json:"id,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the SpecQuery when eager-loading is set. Edges SpecEdges `json:"edges"` // contains filtered or unexported fields }
Spec is the model entity for the Spec schema.
func (*Spec) FromResponse ¶
FromResponse scans the gremlin response data into Spec.
func (*Spec) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Spec) Update ¶
func (s *Spec) Update() *SpecUpdateOne
Update returns a builder for updating this Spec. Note that, you need to call Spec.Unwrap() before calling this method, if this Spec was returned from a transaction, and the transaction was committed or rolled back.
type SpecClient ¶
type SpecClient struct {
// contains filtered or unexported fields
}
SpecClient is a client for the Spec schema.
func NewSpecClient ¶
func NewSpecClient(c config) *SpecClient
NewSpecClient returns a client for the Spec from the given config.
func (*SpecClient) Create ¶
func (c *SpecClient) Create() *SpecCreate
Create returns a create builder for Spec.
func (*SpecClient) CreateBulk ¶
func (c *SpecClient) CreateBulk(builders ...*SpecCreate) *SpecCreateBulk
BulkCreate returns a builder for creating a bulk of Spec entities.
func (*SpecClient) Delete ¶
func (c *SpecClient) Delete() *SpecDelete
Delete returns a delete builder for Spec.
func (*SpecClient) DeleteOne ¶
func (c *SpecClient) DeleteOne(s *Spec) *SpecDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*SpecClient) DeleteOneID ¶
func (c *SpecClient) DeleteOneID(id string) *SpecDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*SpecClient) GetX ¶
func (c *SpecClient) GetX(ctx context.Context, id string) *Spec
GetX is like Get, but panics if an error occurs.
func (*SpecClient) Query ¶
func (c *SpecClient) Query() *SpecQuery
Query returns a query builder for Spec.
func (*SpecClient) QueryCard ¶
func (c *SpecClient) QueryCard(s *Spec) *CardQuery
QueryCard queries the card edge of a Spec.
func (*SpecClient) Update ¶
func (c *SpecClient) Update() *SpecUpdate
Update returns an update builder for Spec.
func (*SpecClient) UpdateOne ¶
func (c *SpecClient) UpdateOne(s *Spec) *SpecUpdateOne
UpdateOne returns an update builder for the given entity.
func (*SpecClient) UpdateOneID ¶
func (c *SpecClient) UpdateOneID(id string) *SpecUpdateOne
UpdateOneID returns an update builder for the given id.
func (*SpecClient) Use ¶
func (c *SpecClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `spec.Hooks(f(g(h())))`.
type SpecCreate ¶
type SpecCreate struct {
// contains filtered or unexported fields
}
SpecCreate is the builder for creating a Spec entity.
func (*SpecCreate) AddCard ¶
func (sc *SpecCreate) AddCard(c ...*Card) *SpecCreate
AddCard adds the card edges to Card.
func (*SpecCreate) AddCardIDs ¶
func (sc *SpecCreate) AddCardIDs(ids ...string) *SpecCreate
AddCardIDs adds the card edge to Card by ids.
func (*SpecCreate) Mutation ¶
func (sc *SpecCreate) Mutation() *SpecMutation
Mutation returns the SpecMutation object of the builder.
type SpecCreateBulk ¶
type SpecCreateBulk struct {
// contains filtered or unexported fields
}
SpecCreateBulk is the builder for creating a bulk of Spec entities.
type SpecDelete ¶
type SpecDelete struct {
// contains filtered or unexported fields
}
SpecDelete is the builder for deleting a Spec entity.
func (*SpecDelete) Exec ¶
func (sd *SpecDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*SpecDelete) ExecX ¶
func (sd *SpecDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*SpecDelete) Where ¶
func (sd *SpecDelete) Where(ps ...predicate.Spec) *SpecDelete
Where adds a new predicate to the delete builder.
type SpecDeleteOne ¶
type SpecDeleteOne struct {
// contains filtered or unexported fields
}
SpecDeleteOne is the builder for deleting a single Spec entity.
func (*SpecDeleteOne) Exec ¶
func (sdo *SpecDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*SpecDeleteOne) ExecX ¶
func (sdo *SpecDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type SpecEdges ¶
type SpecEdges struct { // Card holds the value of the card edge. Card []*Card // contains filtered or unexported fields }
SpecEdges holds the relations/edges for other nodes in the graph.
type SpecGroupBy ¶
type SpecGroupBy struct {
// contains filtered or unexported fields
}
SpecGroupBy is the builder for group-by Spec entities.
func (*SpecGroupBy) Aggregate ¶
func (sgb *SpecGroupBy) Aggregate(fns ...AggregateFunc) *SpecGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*SpecGroupBy) Bool ¶
func (sgb *SpecGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) BoolX ¶
func (sgb *SpecGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*SpecGroupBy) Bools ¶
func (sgb *SpecGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) BoolsX ¶
func (sgb *SpecGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*SpecGroupBy) Float64 ¶
func (sgb *SpecGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) Float64X ¶
func (sgb *SpecGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*SpecGroupBy) Float64s ¶
func (sgb *SpecGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) Float64sX ¶
func (sgb *SpecGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*SpecGroupBy) Int ¶
func (sgb *SpecGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) IntX ¶
func (sgb *SpecGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*SpecGroupBy) Ints ¶
func (sgb *SpecGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) IntsX ¶
func (sgb *SpecGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*SpecGroupBy) Scan ¶
func (sgb *SpecGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*SpecGroupBy) ScanX ¶
func (sgb *SpecGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*SpecGroupBy) String ¶
func (sgb *SpecGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*SpecGroupBy) StringX ¶
func (sgb *SpecGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type SpecMutation ¶
type SpecMutation struct {
// contains filtered or unexported fields
}
SpecMutation represents an operation that mutate the Specs nodes in the graph.
func (*SpecMutation) AddCardIDs ¶
func (m *SpecMutation) AddCardIDs(ids ...string)
AddCardIDs adds the card edge to Card by ids.
func (*SpecMutation) AddField ¶
func (m *SpecMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*SpecMutation) AddedEdges ¶
func (m *SpecMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*SpecMutation) AddedField ¶
func (m *SpecMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*SpecMutation) AddedFields ¶
func (m *SpecMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*SpecMutation) AddedIDs ¶
func (m *SpecMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*SpecMutation) CardCleared ¶ added in v0.4.3
func (m *SpecMutation) CardCleared() bool
CardCleared returns if the edge card was cleared.
func (*SpecMutation) CardIDs ¶
func (m *SpecMutation) CardIDs() (ids []string)
CardIDs returns the card ids in the mutation.
func (*SpecMutation) ClearCard ¶ added in v0.4.3
func (m *SpecMutation) ClearCard()
ClearCard clears the card edge to Card.
func (*SpecMutation) ClearEdge ¶
func (m *SpecMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*SpecMutation) ClearField ¶
func (m *SpecMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*SpecMutation) ClearedEdges ¶
func (m *SpecMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*SpecMutation) ClearedFields ¶
func (m *SpecMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (SpecMutation) Client ¶
func (m SpecMutation) 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 (*SpecMutation) EdgeCleared ¶
func (m *SpecMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*SpecMutation) Field ¶
func (m *SpecMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*SpecMutation) FieldCleared ¶
func (m *SpecMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*SpecMutation) Fields ¶
func (m *SpecMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*SpecMutation) ID ¶
func (m *SpecMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*SpecMutation) 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 was failed.
func (*SpecMutation) RemoveCardIDs ¶
func (m *SpecMutation) RemoveCardIDs(ids ...string)
RemoveCardIDs removes the card edge to Card by ids.
func (*SpecMutation) RemovedCardIDs ¶
func (m *SpecMutation) RemovedCardIDs() (ids []string)
RemovedCard returns the removed ids of card.
func (*SpecMutation) RemovedEdges ¶
func (m *SpecMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*SpecMutation) RemovedIDs ¶
func (m *SpecMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*SpecMutation) ResetCard ¶
func (m *SpecMutation) ResetCard()
ResetCard reset all changes of the "card" edge.
func (*SpecMutation) ResetEdge ¶
func (m *SpecMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*SpecMutation) ResetField ¶
func (m *SpecMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*SpecMutation) SetField ¶
func (m *SpecMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (SpecMutation) Tx ¶
func (m SpecMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*SpecMutation) Type ¶
func (m *SpecMutation) Type() string
Type returns the node type of this mutation (Spec).
type SpecQuery ¶
type SpecQuery struct {
// contains filtered or unexported fields
}
SpecQuery is the builder for querying Spec entities.
func (*SpecQuery) Clone ¶
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*SpecQuery) First ¶
First returns the first Spec entity in the query. Returns *NotFoundError when no spec was found.
func (*SpecQuery) FirstID ¶
FirstID returns the first Spec id in the query. Returns *NotFoundError when no id was found.
func (*SpecQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*SpecQuery) GroupBy ¶
func (sq *SpecQuery) GroupBy(field string, fields ...string) *SpecGroupBy
GroupBy used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
func (*SpecQuery) Only ¶
Only returns the only Spec entity in the query, returns an error if not exactly one entity was returned.
func (*SpecQuery) OnlyID ¶
OnlyID returns the only Spec id in the query, returns an error if not exactly one id was returned.
func (*SpecQuery) Select ¶
func (sq *SpecQuery) Select(field string, fields ...string) *SpecSelect
Select one or more fields from the given query.
type SpecSelect ¶
type SpecSelect struct {
// contains filtered or unexported fields
}
SpecSelect is the builder for select fields of Spec entities.
func (*SpecSelect) Bool ¶
func (ss *SpecSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*SpecSelect) BoolX ¶
func (ss *SpecSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*SpecSelect) Bools ¶
func (ss *SpecSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*SpecSelect) BoolsX ¶
func (ss *SpecSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*SpecSelect) Float64 ¶
func (ss *SpecSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*SpecSelect) Float64X ¶
func (ss *SpecSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*SpecSelect) Float64s ¶
func (ss *SpecSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*SpecSelect) Float64sX ¶
func (ss *SpecSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*SpecSelect) Int ¶
func (ss *SpecSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*SpecSelect) IntX ¶
func (ss *SpecSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*SpecSelect) Ints ¶
func (ss *SpecSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*SpecSelect) IntsX ¶
func (ss *SpecSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*SpecSelect) Scan ¶
func (ss *SpecSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*SpecSelect) ScanX ¶
func (ss *SpecSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*SpecSelect) String ¶
func (ss *SpecSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*SpecSelect) StringX ¶
func (ss *SpecSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type SpecUpdate ¶
type SpecUpdate struct {
// contains filtered or unexported fields
}
SpecUpdate is the builder for updating Spec entities.
func (*SpecUpdate) AddCard ¶
func (su *SpecUpdate) AddCard(c ...*Card) *SpecUpdate
AddCard adds the card edges to Card.
func (*SpecUpdate) AddCardIDs ¶
func (su *SpecUpdate) AddCardIDs(ids ...string) *SpecUpdate
AddCardIDs adds the card edge to Card by ids.
func (*SpecUpdate) ClearCard ¶ added in v0.4.3
func (su *SpecUpdate) ClearCard() *SpecUpdate
ClearCard clears all "card" edges to type Card.
func (*SpecUpdate) Exec ¶
func (su *SpecUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*SpecUpdate) ExecX ¶
func (su *SpecUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SpecUpdate) Mutation ¶
func (su *SpecUpdate) Mutation() *SpecMutation
Mutation returns the SpecMutation object of the builder.
func (*SpecUpdate) RemoveCard ¶
func (su *SpecUpdate) RemoveCard(c ...*Card) *SpecUpdate
RemoveCard removes card edges to Card.
func (*SpecUpdate) RemoveCardIDs ¶
func (su *SpecUpdate) RemoveCardIDs(ids ...string) *SpecUpdate
RemoveCardIDs removes the card edge to Card by ids.
func (*SpecUpdate) Save ¶
func (su *SpecUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*SpecUpdate) SaveX ¶
func (su *SpecUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*SpecUpdate) Where ¶
func (su *SpecUpdate) Where(ps ...predicate.Spec) *SpecUpdate
Where adds a new predicate for the builder.
type SpecUpdateOne ¶
type SpecUpdateOne struct {
// contains filtered or unexported fields
}
SpecUpdateOne is the builder for updating a single Spec entity.
func (*SpecUpdateOne) AddCard ¶
func (suo *SpecUpdateOne) AddCard(c ...*Card) *SpecUpdateOne
AddCard adds the card edges to Card.
func (*SpecUpdateOne) AddCardIDs ¶
func (suo *SpecUpdateOne) AddCardIDs(ids ...string) *SpecUpdateOne
AddCardIDs adds the card edge to Card by ids.
func (*SpecUpdateOne) ClearCard ¶ added in v0.4.3
func (suo *SpecUpdateOne) ClearCard() *SpecUpdateOne
ClearCard clears all "card" edges to type Card.
func (*SpecUpdateOne) Exec ¶
func (suo *SpecUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*SpecUpdateOne) ExecX ¶
func (suo *SpecUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SpecUpdateOne) Mutation ¶
func (suo *SpecUpdateOne) Mutation() *SpecMutation
Mutation returns the SpecMutation object of the builder.
func (*SpecUpdateOne) RemoveCard ¶
func (suo *SpecUpdateOne) RemoveCard(c ...*Card) *SpecUpdateOne
RemoveCard removes card edges to Card.
func (*SpecUpdateOne) RemoveCardIDs ¶
func (suo *SpecUpdateOne) RemoveCardIDs(ids ...string) *SpecUpdateOne
RemoveCardIDs removes the card edge to Card by ids.
type Task ¶ added in v0.4.1
type Task struct { // ID of the ent. ID string `json:"id,omitempty"` // Priority holds the value of the "priority" field. Priority schema.Priority `json:"priority,omitempty"` // contains filtered or unexported fields }
Task is the model entity for the Task schema.
func (*Task) FromResponse ¶ added in v0.4.1
FromResponse scans the gremlin response data into Task.
func (*Task) Unwrap ¶ added in v0.4.1
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next queries will be executed through the driver which created the transaction.
func (*Task) Update ¶ added in v0.4.1
func (t *Task) Update() *TaskUpdateOne
Update returns a builder for updating this Task. Note that, you need to call Task.Unwrap() before calling this method, if this Task was returned from a transaction, and the transaction was committed or rolled back.
type TaskClient ¶ added in v0.4.1
type TaskClient struct {
// contains filtered or unexported fields
}
TaskClient is a client for the Task schema.
func NewTaskClient ¶ added in v0.4.1
func NewTaskClient(c config) *TaskClient
NewTaskClient returns a client for the Task from the given config.
func (*TaskClient) Create ¶ added in v0.4.1
func (c *TaskClient) Create() *TaskCreate
Create returns a create builder for Task.
func (*TaskClient) CreateBulk ¶ added in v0.4.1
func (c *TaskClient) CreateBulk(builders ...*TaskCreate) *TaskCreateBulk
BulkCreate returns a builder for creating a bulk of Task entities.
func (*TaskClient) Delete ¶ added in v0.4.1
func (c *TaskClient) Delete() *TaskDelete
Delete returns a delete builder for Task.
func (*TaskClient) DeleteOne ¶ added in v0.4.1
func (c *TaskClient) DeleteOne(t *Task) *TaskDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*TaskClient) DeleteOneID ¶ added in v0.4.1
func (c *TaskClient) DeleteOneID(id string) *TaskDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*TaskClient) GetX ¶ added in v0.4.1
func (c *TaskClient) GetX(ctx context.Context, id string) *Task
GetX is like Get, but panics if an error occurs.
func (*TaskClient) Hooks ¶ added in v0.4.1
func (c *TaskClient) Hooks() []Hook
Hooks returns the client hooks.
func (*TaskClient) Query ¶ added in v0.4.1
func (c *TaskClient) Query() *TaskQuery
Query returns a query builder for Task.
func (*TaskClient) Update ¶ added in v0.4.1
func (c *TaskClient) Update() *TaskUpdate
Update returns an update builder for Task.
func (*TaskClient) UpdateOne ¶ added in v0.4.1
func (c *TaskClient) UpdateOne(t *Task) *TaskUpdateOne
UpdateOne returns an update builder for the given entity.
func (*TaskClient) UpdateOneID ¶ added in v0.4.1
func (c *TaskClient) UpdateOneID(id string) *TaskUpdateOne
UpdateOneID returns an update builder for the given id.
func (*TaskClient) Use ¶ added in v0.4.1
func (c *TaskClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `task.Hooks(f(g(h())))`.
type TaskCreate ¶ added in v0.4.1
type TaskCreate struct {
// contains filtered or unexported fields
}
TaskCreate is the builder for creating a Task entity.
func (*TaskCreate) Mutation ¶ added in v0.4.1
func (tc *TaskCreate) Mutation() *TaskMutation
Mutation returns the TaskMutation object of the builder.
func (*TaskCreate) Save ¶ added in v0.4.1
func (tc *TaskCreate) Save(ctx context.Context) (*Task, error)
Save creates the Task in the database.
func (*TaskCreate) SaveX ¶ added in v0.4.1
func (tc *TaskCreate) SaveX(ctx context.Context) *Task
SaveX calls Save and panics if Save returns an error.
func (*TaskCreate) SetNillablePriority ¶ added in v0.4.1
func (tc *TaskCreate) SetNillablePriority(s *schema.Priority) *TaskCreate
SetNillablePriority sets the priority field if the given value is not nil.
func (*TaskCreate) SetPriority ¶ added in v0.4.1
func (tc *TaskCreate) SetPriority(s schema.Priority) *TaskCreate
SetPriority sets the priority field.
type TaskCreateBulk ¶ added in v0.4.1
type TaskCreateBulk struct {
// contains filtered or unexported fields
}
TaskCreateBulk is the builder for creating a bulk of Task entities.
type TaskDelete ¶ added in v0.4.1
type TaskDelete struct {
// contains filtered or unexported fields
}
TaskDelete is the builder for deleting a Task entity.
func (*TaskDelete) Exec ¶ added in v0.4.1
func (td *TaskDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*TaskDelete) ExecX ¶ added in v0.4.1
func (td *TaskDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*TaskDelete) Where ¶ added in v0.4.1
func (td *TaskDelete) Where(ps ...predicate.Task) *TaskDelete
Where adds a new predicate to the delete builder.
type TaskDeleteOne ¶ added in v0.4.1
type TaskDeleteOne struct {
// contains filtered or unexported fields
}
TaskDeleteOne is the builder for deleting a single Task entity.
func (*TaskDeleteOne) Exec ¶ added in v0.4.1
func (tdo *TaskDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*TaskDeleteOne) ExecX ¶ added in v0.4.1
func (tdo *TaskDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type TaskGroupBy ¶ added in v0.4.1
type TaskGroupBy struct {
// contains filtered or unexported fields
}
TaskGroupBy is the builder for group-by Task entities.
func (*TaskGroupBy) Aggregate ¶ added in v0.4.1
func (tgb *TaskGroupBy) Aggregate(fns ...AggregateFunc) *TaskGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*TaskGroupBy) Bool ¶ added in v0.4.1
func (tgb *TaskGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) BoolX ¶ added in v0.4.1
func (tgb *TaskGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*TaskGroupBy) Bools ¶ added in v0.4.1
func (tgb *TaskGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) BoolsX ¶ added in v0.4.1
func (tgb *TaskGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*TaskGroupBy) Float64 ¶ added in v0.4.1
func (tgb *TaskGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) Float64X ¶ added in v0.4.1
func (tgb *TaskGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*TaskGroupBy) Float64s ¶ added in v0.4.1
func (tgb *TaskGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) Float64sX ¶ added in v0.4.1
func (tgb *TaskGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*TaskGroupBy) Int ¶ added in v0.4.1
func (tgb *TaskGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) IntX ¶ added in v0.4.1
func (tgb *TaskGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*TaskGroupBy) Ints ¶ added in v0.4.1
func (tgb *TaskGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) IntsX ¶ added in v0.4.1
func (tgb *TaskGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*TaskGroupBy) Scan ¶ added in v0.4.1
func (tgb *TaskGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*TaskGroupBy) ScanX ¶ added in v0.4.1
func (tgb *TaskGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*TaskGroupBy) String ¶ added in v0.4.1
func (tgb *TaskGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*TaskGroupBy) StringX ¶ added in v0.4.1
func (tgb *TaskGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type TaskMutation ¶ added in v0.4.1
type TaskMutation struct {
// contains filtered or unexported fields
}
TaskMutation represents an operation that mutate the Tasks nodes in the graph.
func (*TaskMutation) AddField ¶ added in v0.4.1
func (m *TaskMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*TaskMutation) AddPriority ¶ added in v0.4.1
func (m *TaskMutation) AddPriority(s schema.Priority)
AddPriority adds s to priority.
func (*TaskMutation) AddedEdges ¶ added in v0.4.1
func (m *TaskMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*TaskMutation) AddedField ¶ added in v0.4.1
func (m *TaskMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*TaskMutation) AddedFields ¶ added in v0.4.1
func (m *TaskMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or decremented during this mutation.
func (*TaskMutation) AddedIDs ¶ added in v0.4.1
func (m *TaskMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all ids (to other nodes) that were added for the given edge name.
func (*TaskMutation) AddedPriority ¶ added in v0.4.1
func (m *TaskMutation) AddedPriority() (r schema.Priority, exists bool)
AddedPriority returns the value that was added to the priority field in this mutation.
func (*TaskMutation) ClearEdge ¶ added in v0.4.1
func (m *TaskMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*TaskMutation) ClearField ¶ added in v0.4.1
func (m *TaskMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*TaskMutation) ClearedEdges ¶ added in v0.4.1
func (m *TaskMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*TaskMutation) ClearedFields ¶ added in v0.4.1
func (m *TaskMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (TaskMutation) Client ¶ added in v0.4.1
func (m TaskMutation) 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 (*TaskMutation) EdgeCleared ¶ added in v0.4.1
func (m *TaskMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this mutation.
func (*TaskMutation) Field ¶ added in v0.4.1
func (m *TaskMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean value indicates that this field was not set, or was not define in the schema.
func (*TaskMutation) FieldCleared ¶ added in v0.4.1
func (m *TaskMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field was cleared in this mutation.
func (*TaskMutation) Fields ¶ added in v0.4.1
func (m *TaskMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that, in order to get all numeric fields that were in/decremented, call AddedFields().
func (*TaskMutation) ID ¶ added in v0.4.1
func (m *TaskMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*TaskMutation) OldField ¶ added in v0.4.1
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 was failed.
func (*TaskMutation) OldPriority ¶ added in v0.4.1
OldPriority returns the old priority value of the Task. If the Task 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 database query fails.
func (*TaskMutation) Op ¶ added in v0.4.1
func (m *TaskMutation) Op() Op
Op returns the operation name.
func (*TaskMutation) Priority ¶ added in v0.4.1
func (m *TaskMutation) Priority() (r schema.Priority, exists bool)
Priority returns the priority value in the mutation.
func (*TaskMutation) RemovedEdges ¶ added in v0.4.1
func (m *TaskMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*TaskMutation) RemovedIDs ¶ added in v0.4.1
func (m *TaskMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*TaskMutation) ResetEdge ¶ added in v0.4.1
func (m *TaskMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*TaskMutation) ResetField ¶ added in v0.4.1
func (m *TaskMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*TaskMutation) ResetPriority ¶ added in v0.4.1
func (m *TaskMutation) ResetPriority()
ResetPriority reset all changes of the "priority" field.
func (*TaskMutation) SetField ¶ added in v0.4.1
func (m *TaskMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*TaskMutation) SetPriority ¶ added in v0.4.1
func (m *TaskMutation) SetPriority(s schema.Priority)
SetPriority sets the priority field.
func (TaskMutation) Tx ¶ added in v0.4.1
func (m TaskMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*TaskMutation) Type ¶ added in v0.4.1
func (m *TaskMutation) Type() string
Type returns the node type of this mutation (Task).
type TaskQuery ¶ added in v0.4.1
type TaskQuery struct {
// contains filtered or unexported fields
}
TaskQuery is the builder for querying Task entities.
func (*TaskQuery) Clone ¶ added in v0.4.1
Clone returns a duplicate of the query builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*TaskQuery) Exist ¶ added in v0.4.1
Exist returns true if the query has elements in the graph.
func (*TaskQuery) First ¶ added in v0.4.1
First returns the first Task entity in the query. Returns *NotFoundError when no task was found.
func (*TaskQuery) FirstID ¶ added in v0.4.1
FirstID returns the first Task id in the query. Returns *NotFoundError when no id was found.
func (*TaskQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*TaskQuery) GroupBy ¶ added in v0.4.1
func (tq *TaskQuery) GroupBy(field string, fields ...string) *TaskGroupBy
GroupBy 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 { Priority schema.Priority `json:"priority,omitempty"` Count int `json:"count,omitempty"` } client.Task.Query(). GroupBy(task.FieldPriority). Aggregate(ent.Count()). Scan(ctx, &v)
func (*TaskQuery) Only ¶ added in v0.4.1
Only returns the only Task entity in the query, returns an error if not exactly one entity was returned.
func (*TaskQuery) OnlyID ¶ added in v0.4.1
OnlyID returns the only Task id in the query, returns an error if not exactly one id was returned.
func (*TaskQuery) Select ¶ added in v0.4.1
func (tq *TaskQuery) Select(field string, fields ...string) *TaskSelect
Select one or more fields from the given query.
Example:
var v []struct { Priority schema.Priority `json:"priority,omitempty"` } client.Task.Query(). Select(task.FieldPriority). Scan(ctx, &v)
type TaskSelect ¶ added in v0.4.1
type TaskSelect struct {
// contains filtered or unexported fields
}
TaskSelect is the builder for select fields of Task entities.
func (*TaskSelect) Bool ¶ added in v0.4.1
func (ts *TaskSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*TaskSelect) BoolX ¶ added in v0.4.1
func (ts *TaskSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*TaskSelect) Bools ¶ added in v0.4.1
func (ts *TaskSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*TaskSelect) BoolsX ¶ added in v0.4.1
func (ts *TaskSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*TaskSelect) Float64 ¶ added in v0.4.1
func (ts *TaskSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*TaskSelect) Float64X ¶ added in v0.4.1
func (ts *TaskSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*TaskSelect) Float64s ¶ added in v0.4.1
func (ts *TaskSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*TaskSelect) Float64sX ¶ added in v0.4.1
func (ts *TaskSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*TaskSelect) Int ¶ added in v0.4.1
func (ts *TaskSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*TaskSelect) IntX ¶ added in v0.4.1
func (ts *TaskSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*TaskSelect) Ints ¶ added in v0.4.1
func (ts *TaskSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*TaskSelect) IntsX ¶ added in v0.4.1
func (ts *TaskSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*TaskSelect) Scan ¶ added in v0.4.1
func (ts *TaskSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*TaskSelect) ScanX ¶ added in v0.4.1
func (ts *TaskSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*TaskSelect) String ¶ added in v0.4.1
func (ts *TaskSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*TaskSelect) StringX ¶ added in v0.4.1
func (ts *TaskSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type TaskUpdate ¶ added in v0.4.1
type TaskUpdate struct {
// contains filtered or unexported fields
}
TaskUpdate is the builder for updating Task entities.
func (*TaskUpdate) AddPriority ¶ added in v0.4.1
func (tu *TaskUpdate) AddPriority(s schema.Priority) *TaskUpdate
AddPriority adds s to priority.
func (*TaskUpdate) Exec ¶ added in v0.4.1
func (tu *TaskUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*TaskUpdate) ExecX ¶ added in v0.4.1
func (tu *TaskUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*TaskUpdate) Mutation ¶ added in v0.4.1
func (tu *TaskUpdate) Mutation() *TaskMutation
Mutation returns the TaskMutation object of the builder.
func (*TaskUpdate) Save ¶ added in v0.4.1
func (tu *TaskUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*TaskUpdate) SaveX ¶ added in v0.4.1
func (tu *TaskUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*TaskUpdate) SetNillablePriority ¶ added in v0.4.1
func (tu *TaskUpdate) SetNillablePriority(s *schema.Priority) *TaskUpdate
SetNillablePriority sets the priority field if the given value is not nil.
func (*TaskUpdate) SetPriority ¶ added in v0.4.1
func (tu *TaskUpdate) SetPriority(s schema.Priority) *TaskUpdate
SetPriority sets the priority field.
func (*TaskUpdate) Where ¶ added in v0.4.1
func (tu *TaskUpdate) Where(ps ...predicate.Task) *TaskUpdate
Where adds a new predicate for the builder.
type TaskUpdateOne ¶ added in v0.4.1
type TaskUpdateOne struct {
// contains filtered or unexported fields
}
TaskUpdateOne is the builder for updating a single Task entity.
func (*TaskUpdateOne) AddPriority ¶ added in v0.4.1
func (tuo *TaskUpdateOne) AddPriority(s schema.Priority) *TaskUpdateOne
AddPriority adds s to priority.
func (*TaskUpdateOne) Exec ¶ added in v0.4.1
func (tuo *TaskUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*TaskUpdateOne) ExecX ¶ added in v0.4.1
func (tuo *TaskUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*TaskUpdateOne) Mutation ¶ added in v0.4.1
func (tuo *TaskUpdateOne) Mutation() *TaskMutation
Mutation returns the TaskMutation object of the builder.
func (*TaskUpdateOne) Save ¶ added in v0.4.1
func (tuo *TaskUpdateOne) Save(ctx context.Context) (*Task, error)
Save executes the query and returns the updated entity.
func (*TaskUpdateOne) SaveX ¶ added in v0.4.1
func (tuo *TaskUpdateOne) SaveX(ctx context.Context) *Task
SaveX is like Save, but panics if an error occurs.
func (*TaskUpdateOne) SetNillablePriority ¶ added in v0.4.1
func (tuo *TaskUpdateOne) SetNillablePriority(s *schema.Priority) *TaskUpdateOne
SetNillablePriority sets the priority field if the given value is not nil.
func (*TaskUpdateOne) SetPriority ¶ added in v0.4.1
func (tuo *TaskUpdateOne) SetPriority(s schema.Priority) *TaskUpdateOne
SetPriority sets the priority field.
type Tx ¶
type Tx struct { // Card is the client for interacting with the Card builders. Card *CardClient // Comment is the client for interacting with the Comment builders. Comment *CommentClient // FieldType is the client for interacting with the FieldType builders. FieldType *FieldTypeClient // File is the client for interacting with the File builders. File *FileClient // FileType is the client for interacting with the FileType builders. FileType *FileTypeClient // Goods is the client for interacting with the Goods builders. Goods *GoodsClient // Group is the client for interacting with the Group builders. Group *GroupClient // GroupInfo is the client for interacting with the GroupInfo builders. GroupInfo *GroupInfoClient // Item is the client for interacting with the Item builders. Item *ItemClient // Node is the client for interacting with the Node builders. Node *NodeClient // Pet is the client for interacting with the Pet builders. Pet *PetClient // Spec is the client for interacting with the Spec builders. Spec *SpecClient // Task is the client for interacting with the Task builders. Task *TaskClient // 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 the Tx stored in 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 User ¶
type User struct { // ID of the ent. ID string `json:"id,omitempty"` // OptionalInt holds the value of the "optional_int" field. OptionalInt int `json:"optional_int,omitempty"` // Age holds the value of the "age" field. Age int `json:"age,omitempty"` // Name holds the value of the "name" field. Name string `json:"first_name" graphql:"first_name"` // Last holds the value of the "last" field. Last string `json:"last,omitempty" graphql:"last_name"` // Nickname holds the value of the "nickname" field. Nickname string `json:"nickname,omitempty"` // Phone holds the value of the "phone" field. Phone string `json:"phone,omitempty"` // Password holds the value of the "password" field. Password string `graphql:"-" json:"-"` // Role holds the value of the "role" field. Role user.Role `json:"role,omitempty"` // SSOCert holds the value of the "SSOCert" field. SSOCert string `json:"SSOCert,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) FromResponse ¶
FromResponse scans the gremlin response data into User.
func (*User) QueryChildren ¶
QueryChildren queries the children edge of the User.
func (*User) QueryFiles ¶
QueryFiles queries the files edge of the User.
func (*User) QueryFollowers ¶
QueryFollowers queries the followers edge of the User.
func (*User) QueryFollowing ¶
QueryFollowing queries the following edge of the User.
func (*User) QueryFriends ¶
QueryFriends queries the friends edge of the User.
func (*User) QueryGroups ¶
func (u *User) QueryGroups() *GroupQuery
QueryGroups queries the groups edge of the User.
func (*User) QueryParent ¶
QueryParent queries the parent edge of the User.
func (*User) QuerySpouse ¶
QuerySpouse queries the spouse edge of the User.
func (*User) Unwrap ¶
Unwrap unwraps the entity that was returned from a transaction after it was closed, so that all next 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 create builder for User.
func (*UserClient) CreateBulk ¶
func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
BulkCreate 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 delete builder for the given entity.
func (*UserClient) DeleteOneID ¶
func (c *UserClient) DeleteOneID(id string) *UserDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*UserClient) GetX ¶
func (c *UserClient) GetX(ctx context.Context, id string) *User
GetX is like Get, but panics if an error occurs.
func (*UserClient) Query ¶
func (c *UserClient) Query() *UserQuery
Query returns a query builder for User.
func (*UserClient) QueryCard ¶
func (c *UserClient) QueryCard(u *User) *CardQuery
QueryCard queries the card edge of a User.
func (*UserClient) QueryChildren ¶
func (c *UserClient) QueryChildren(u *User) *UserQuery
QueryChildren queries the children edge of a User.
func (*UserClient) QueryFiles ¶
func (c *UserClient) QueryFiles(u *User) *FileQuery
QueryFiles queries the files edge of a User.
func (*UserClient) QueryFollowers ¶
func (c *UserClient) QueryFollowers(u *User) *UserQuery
QueryFollowers queries the followers edge of a User.
func (*UserClient) QueryFollowing ¶
func (c *UserClient) QueryFollowing(u *User) *UserQuery
QueryFollowing queries the following edge of a User.
func (*UserClient) QueryFriends ¶
func (c *UserClient) QueryFriends(u *User) *UserQuery
QueryFriends queries the friends edge of a User.
func (*UserClient) QueryGroups ¶
func (c *UserClient) QueryGroups(u *User) *GroupQuery
QueryGroups queries the groups edge of a User.
func (*UserClient) QueryParent ¶
func (c *UserClient) QueryParent(u *User) *UserQuery
QueryParent queries the parent edge of a User.
func (*UserClient) QueryPets ¶
func (c *UserClient) QueryPets(u *User) *PetQuery
QueryPets queries the pets edge of a User.
func (*UserClient) QuerySpouse ¶
func (c *UserClient) QuerySpouse(u *User) *UserQuery
QuerySpouse queries the spouse edge of a User.
func (*UserClient) QueryTeam ¶
func (c *UserClient) QueryTeam(u *User) *PetQuery
QueryTeam queries the team 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 string) *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 UserCreate ¶
type UserCreate struct {
// contains filtered or unexported fields
}
UserCreate is the builder for creating a User entity.
func (*UserCreate) AddChildIDs ¶
func (uc *UserCreate) AddChildIDs(ids ...string) *UserCreate
AddChildIDs adds the children edge to User by ids.
func (*UserCreate) AddChildren ¶
func (uc *UserCreate) AddChildren(u ...*User) *UserCreate
AddChildren adds the children edges to User.
func (*UserCreate) AddFileIDs ¶
func (uc *UserCreate) AddFileIDs(ids ...string) *UserCreate
AddFileIDs adds the files edge to File by ids.
func (*UserCreate) AddFiles ¶
func (uc *UserCreate) AddFiles(f ...*File) *UserCreate
AddFiles adds the files edges to File.
func (*UserCreate) AddFollowerIDs ¶
func (uc *UserCreate) AddFollowerIDs(ids ...string) *UserCreate
AddFollowerIDs adds the followers edge to User by ids.
func (*UserCreate) AddFollowers ¶
func (uc *UserCreate) AddFollowers(u ...*User) *UserCreate
AddFollowers adds the followers edges to User.
func (*UserCreate) AddFollowing ¶
func (uc *UserCreate) AddFollowing(u ...*User) *UserCreate
AddFollowing adds the following edges to User.
func (*UserCreate) AddFollowingIDs ¶
func (uc *UserCreate) AddFollowingIDs(ids ...string) *UserCreate
AddFollowingIDs adds the following edge to User by ids.
func (*UserCreate) AddFriendIDs ¶
func (uc *UserCreate) AddFriendIDs(ids ...string) *UserCreate
AddFriendIDs adds the friends edge to User by ids.
func (*UserCreate) AddFriends ¶
func (uc *UserCreate) AddFriends(u ...*User) *UserCreate
AddFriends adds the friends edges to User.
func (*UserCreate) AddGroupIDs ¶
func (uc *UserCreate) AddGroupIDs(ids ...string) *UserCreate
AddGroupIDs adds the groups edge to Group by ids.
func (*UserCreate) AddGroups ¶
func (uc *UserCreate) AddGroups(g ...*Group) *UserCreate
AddGroups adds the groups edges to Group.
func (*UserCreate) AddPetIDs ¶
func (uc *UserCreate) AddPetIDs(ids ...string) *UserCreate
AddPetIDs adds the pets edge to Pet by ids.
func (*UserCreate) AddPets ¶
func (uc *UserCreate) AddPets(p ...*Pet) *UserCreate
AddPets adds the pets edges to Pet.
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) SetAge ¶
func (uc *UserCreate) SetAge(i int) *UserCreate
SetAge sets the age field.
func (*UserCreate) SetCard ¶
func (uc *UserCreate) SetCard(c *Card) *UserCreate
SetCard sets the card edge to Card.
func (*UserCreate) SetCardID ¶
func (uc *UserCreate) SetCardID(id string) *UserCreate
SetCardID sets the card edge to Card by id.
func (*UserCreate) SetLast ¶
func (uc *UserCreate) SetLast(s string) *UserCreate
SetLast sets the last field.
func (*UserCreate) SetName ¶
func (uc *UserCreate) SetName(s string) *UserCreate
SetName sets the name field.
func (*UserCreate) SetNickname ¶
func (uc *UserCreate) SetNickname(s string) *UserCreate
SetNickname sets the nickname field.
func (*UserCreate) SetNillableCardID ¶
func (uc *UserCreate) SetNillableCardID(id *string) *UserCreate
SetNillableCardID sets the card edge to Card by id if the given value is not nil.
func (*UserCreate) SetNillableLast ¶
func (uc *UserCreate) SetNillableLast(s *string) *UserCreate
SetNillableLast sets the last field if the given value is not nil.
func (*UserCreate) SetNillableNickname ¶
func (uc *UserCreate) SetNillableNickname(s *string) *UserCreate
SetNillableNickname sets the nickname field if the given value is not nil.
func (*UserCreate) SetNillableOptionalInt ¶
func (uc *UserCreate) SetNillableOptionalInt(i *int) *UserCreate
SetNillableOptionalInt sets the optional_int field if the given value is not nil.
func (*UserCreate) SetNillableParentID ¶
func (uc *UserCreate) SetNillableParentID(id *string) *UserCreate
SetNillableParentID sets the parent edge to User by id if the given value is not nil.
func (*UserCreate) SetNillablePassword ¶
func (uc *UserCreate) SetNillablePassword(s *string) *UserCreate
SetNillablePassword sets the password field if the given value is not nil.
func (*UserCreate) SetNillablePhone ¶
func (uc *UserCreate) SetNillablePhone(s *string) *UserCreate
SetNillablePhone sets the phone field if the given value is not nil.
func (*UserCreate) SetNillableRole ¶
func (uc *UserCreate) SetNillableRole(u *user.Role) *UserCreate
SetNillableRole sets the role field if the given value is not nil.
func (*UserCreate) SetNillableSSOCert ¶
func (uc *UserCreate) SetNillableSSOCert(s *string) *UserCreate
SetNillableSSOCert sets the SSOCert field if the given value is not nil.
func (*UserCreate) SetNillableSpouseID ¶
func (uc *UserCreate) SetNillableSpouseID(id *string) *UserCreate
SetNillableSpouseID sets the spouse edge to User by id if the given value is not nil.
func (*UserCreate) SetNillableTeamID ¶
func (uc *UserCreate) SetNillableTeamID(id *string) *UserCreate
SetNillableTeamID sets the team edge to Pet by id if the given value is not nil.
func (*UserCreate) SetOptionalInt ¶
func (uc *UserCreate) SetOptionalInt(i int) *UserCreate
SetOptionalInt sets the optional_int field.
func (*UserCreate) SetParent ¶
func (uc *UserCreate) SetParent(u *User) *UserCreate
SetParent sets the parent edge to User.
func (*UserCreate) SetParentID ¶
func (uc *UserCreate) SetParentID(id string) *UserCreate
SetParentID sets the parent edge to User by id.
func (*UserCreate) SetPassword ¶
func (uc *UserCreate) SetPassword(s string) *UserCreate
SetPassword sets the password field.
func (*UserCreate) SetPhone ¶
func (uc *UserCreate) SetPhone(s string) *UserCreate
SetPhone sets the phone field.
func (*UserCreate) SetRole ¶
func (uc *UserCreate) SetRole(u user.Role) *UserCreate
SetRole sets the role field.
func (*UserCreate) SetSSOCert ¶
func (uc *UserCreate) SetSSOCert(s string) *UserCreate
SetSSOCert sets the SSOCert field.
func (*UserCreate) SetSpouse ¶
func (uc *UserCreate) SetSpouse(u *User) *UserCreate
SetSpouse sets the spouse edge to User.
func (*UserCreate) SetSpouseID ¶
func (uc *UserCreate) SetSpouseID(id string) *UserCreate
SetSpouseID sets the spouse edge to User by id.
func (*UserCreate) SetTeam ¶
func (uc *UserCreate) SetTeam(p *Pet) *UserCreate
SetTeam sets the team edge to Pet.
func (*UserCreate) SetTeamID ¶
func (uc *UserCreate) SetTeamID(id string) *UserCreate
SetTeamID sets the team edge to Pet by id.
type UserCreateBulk ¶
type UserCreateBulk struct {
// contains filtered or unexported fields
}
UserCreateBulk is the builder for creating a bulk of User entities.
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 adds a new predicate to the delete 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 { // Card holds the value of the card edge. Card *Card // Pets holds the value of the pets edge. Pets []*Pet // Files holds the value of the files edge. Files []*File // Groups holds the value of the groups edge. Groups []*Group // Friends holds the value of the friends edge. Friends []*User // Followers holds the value of the followers edge. Followers []*User // Following holds the value of the following edge. Following []*User // Team holds the value of the team edge. Team *Pet // Spouse holds the value of the spouse edge. Spouse *User // Children holds the value of the children edge. Children []*User // Parent holds the value of the parent edge. Parent *User // contains filtered or unexported fields }
UserEdges holds the relations/edges for other nodes in the graph.
func (UserEdges) CardOrErr ¶
CardOrErr returns the Card value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (UserEdges) ChildrenOrErr ¶
ChildrenOrErr returns the Children value or an error if the edge was not loaded in eager-loading.
func (UserEdges) FilesOrErr ¶
FilesOrErr returns the Files value or an error if the edge was not loaded in eager-loading.
func (UserEdges) FollowersOrErr ¶
FollowersOrErr returns the Followers value or an error if the edge was not loaded in eager-loading.
func (UserEdges) FollowingOrErr ¶
FollowingOrErr returns the Following value or an error if the edge was not loaded in eager-loading.
func (UserEdges) FriendsOrErr ¶
FriendsOrErr returns the Friends value or an error if the edge was not loaded in eager-loading.
func (UserEdges) GroupsOrErr ¶
GroupsOrErr returns the Groups value or an error if the edge was not loaded in eager-loading.
func (UserEdges) ParentOrErr ¶
ParentOrErr returns the Parent value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (UserEdges) PetsOrErr ¶
PetsOrErr returns the Pets value or an error if the edge was not loaded in eager-loading.
func (UserEdges) SpouseOrErr ¶
SpouseOrErr returns the Spouse value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type UserGroupBy ¶
type UserGroupBy struct {
// contains filtered or unexported fields
}
UserGroupBy is the builder for group-by 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 ¶
func (ugb *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) BoolX ¶
func (ugb *UserGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*UserGroupBy) Bools ¶
func (ugb *UserGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) BoolsX ¶
func (ugb *UserGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*UserGroupBy) Float64 ¶
func (ugb *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) Float64X ¶
func (ugb *UserGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*UserGroupBy) Float64s ¶
func (ugb *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) Float64sX ¶
func (ugb *UserGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*UserGroupBy) Int ¶
func (ugb *UserGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) IntX ¶
func (ugb *UserGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*UserGroupBy) Ints ¶
func (ugb *UserGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) IntsX ¶
func (ugb *UserGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*UserGroupBy) Scan ¶
func (ugb *UserGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scan the result into the given value.
func (*UserGroupBy) ScanX ¶
func (ugb *UserGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*UserGroupBy) String ¶
func (ugb *UserGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from group-by. It is only allowed when querying group-by with one field.
func (*UserGroupBy) StringX ¶
func (ugb *UserGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type UserMutation ¶
type UserMutation struct {
// contains filtered or unexported fields
}
UserMutation represents an operation that mutate the Users nodes in the graph.
func (*UserMutation) AddChildIDs ¶
func (m *UserMutation) AddChildIDs(ids ...string)
AddChildIDs adds the children edge to User by ids.
func (*UserMutation) AddField ¶
func (m *UserMutation) AddField(name string, value ent.Value) error
AddField adds the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*UserMutation) AddFileIDs ¶
func (m *UserMutation) AddFileIDs(ids ...string)
AddFileIDs adds the files edge to File by ids.
func (*UserMutation) AddFollowerIDs ¶
func (m *UserMutation) AddFollowerIDs(ids ...string)
AddFollowerIDs adds the followers edge to User by ids.
func (*UserMutation) AddFollowingIDs ¶
func (m *UserMutation) AddFollowingIDs(ids ...string)
AddFollowingIDs adds the following edge to User by ids.
func (*UserMutation) AddFriendIDs ¶
func (m *UserMutation) AddFriendIDs(ids ...string)
AddFriendIDs adds the friends edge to User by ids.
func (*UserMutation) AddGroupIDs ¶
func (m *UserMutation) AddGroupIDs(ids ...string)
AddGroupIDs adds the groups edge to Group by ids.
func (*UserMutation) AddOptionalInt ¶
func (m *UserMutation) AddOptionalInt(i int)
AddOptionalInt adds i to optional_int.
func (*UserMutation) AddPetIDs ¶
func (m *UserMutation) AddPetIDs(ids ...string)
AddPetIDs adds the pets edge to Pet by ids.
func (*UserMutation) AddedAge ¶
func (m *UserMutation) AddedAge() (r int, exists bool)
AddedAge returns the value that was added to the age field in this mutation.
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 in/decremented from a field with the given name. The second value indicates that this field was not set, or was not define in the schema.
func (*UserMutation) AddedFields ¶
func (m *UserMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented or 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.
func (*UserMutation) AddedOptionalInt ¶
func (m *UserMutation) AddedOptionalInt() (r int, exists bool)
AddedOptionalInt returns the value that was added to the optional_int field in this mutation.
func (*UserMutation) Age ¶
func (m *UserMutation) Age() (r int, exists bool)
Age returns the age value in the mutation.
func (*UserMutation) CardCleared ¶
func (m *UserMutation) CardCleared() bool
CardCleared returns if the edge card was cleared.
func (*UserMutation) CardID ¶
func (m *UserMutation) CardID() (id string, exists bool)
CardID returns the card id in the mutation.
func (*UserMutation) CardIDs ¶
func (m *UserMutation) CardIDs() (ids []string)
CardIDs returns the card ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use CardID instead. It exists only for internal usage by the builders.
func (*UserMutation) ChildrenCleared ¶ added in v0.4.3
func (m *UserMutation) ChildrenCleared() bool
ChildrenCleared returns if the edge children was cleared.
func (*UserMutation) ChildrenIDs ¶
func (m *UserMutation) ChildrenIDs() (ids []string)
ChildrenIDs returns the children ids in the mutation.
func (*UserMutation) ClearCard ¶
func (m *UserMutation) ClearCard()
ClearCard clears the card edge to Card.
func (*UserMutation) ClearChildren ¶ added in v0.4.3
func (m *UserMutation) ClearChildren()
ClearChildren clears the children edge to User.
func (*UserMutation) ClearEdge ¶
func (m *UserMutation) ClearEdge(name string) error
ClearEdge clears the value for the given name. It returns an error if the edge name is not defined in the schema.
func (*UserMutation) ClearField ¶
func (m *UserMutation) ClearField(name string) error
ClearField clears the value for the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ClearFiles ¶ added in v0.4.3
func (m *UserMutation) ClearFiles()
ClearFiles clears the files edge to File.
func (*UserMutation) ClearFollowers ¶ added in v0.4.3
func (m *UserMutation) ClearFollowers()
ClearFollowers clears the followers edge to User.
func (*UserMutation) ClearFollowing ¶ added in v0.4.3
func (m *UserMutation) ClearFollowing()
ClearFollowing clears the following edge to User.
func (*UserMutation) ClearFriends ¶ added in v0.4.3
func (m *UserMutation) ClearFriends()
ClearFriends clears the friends edge to User.
func (*UserMutation) ClearGroups ¶ added in v0.4.3
func (m *UserMutation) ClearGroups()
ClearGroups clears the groups edge to Group.
func (*UserMutation) ClearNickname ¶
func (m *UserMutation) ClearNickname()
ClearNickname clears the value of nickname.
func (*UserMutation) ClearOptionalInt ¶
func (m *UserMutation) ClearOptionalInt()
ClearOptionalInt clears the value of optional_int.
func (*UserMutation) ClearParent ¶
func (m *UserMutation) ClearParent()
ClearParent clears the parent edge to User.
func (*UserMutation) ClearPassword ¶
func (m *UserMutation) ClearPassword()
ClearPassword clears the value of password.
func (*UserMutation) ClearPets ¶ added in v0.4.3
func (m *UserMutation) ClearPets()
ClearPets clears the pets edge to Pet.
func (*UserMutation) ClearPhone ¶
func (m *UserMutation) ClearPhone()
ClearPhone clears the value of phone.
func (*UserMutation) ClearSSOCert ¶
func (m *UserMutation) ClearSSOCert()
ClearSSOCert clears the value of SSOCert.
func (*UserMutation) ClearSpouse ¶
func (m *UserMutation) ClearSpouse()
ClearSpouse clears the spouse edge to User.
func (*UserMutation) ClearTeam ¶
func (m *UserMutation) ClearTeam()
ClearTeam clears the team edge to Pet.
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) EdgeCleared ¶
func (m *UserMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean indicates if this edge was cleared in this 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 value indicates that this field was not set, or was not define in the schema.
func (*UserMutation) FieldCleared ¶
func (m *UserMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicates if this field 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 in/decremented, call AddedFields().
func (*UserMutation) FilesCleared ¶ added in v0.4.3
func (m *UserMutation) FilesCleared() bool
FilesCleared returns if the edge files was cleared.
func (*UserMutation) FilesIDs ¶
func (m *UserMutation) FilesIDs() (ids []string)
FilesIDs returns the files ids in the mutation.
func (*UserMutation) FollowersCleared ¶ added in v0.4.3
func (m *UserMutation) FollowersCleared() bool
FollowersCleared returns if the edge followers was cleared.
func (*UserMutation) FollowersIDs ¶
func (m *UserMutation) FollowersIDs() (ids []string)
FollowersIDs returns the followers ids in the mutation.
func (*UserMutation) FollowingCleared ¶ added in v0.4.3
func (m *UserMutation) FollowingCleared() bool
FollowingCleared returns if the edge following was cleared.
func (*UserMutation) FollowingIDs ¶
func (m *UserMutation) FollowingIDs() (ids []string)
FollowingIDs returns the following ids in the mutation.
func (*UserMutation) FriendsCleared ¶ added in v0.4.3
func (m *UserMutation) FriendsCleared() bool
FriendsCleared returns if the edge friends was cleared.
func (*UserMutation) FriendsIDs ¶
func (m *UserMutation) FriendsIDs() (ids []string)
FriendsIDs returns the friends ids in the mutation.
func (*UserMutation) GroupsCleared ¶ added in v0.4.3
func (m *UserMutation) GroupsCleared() bool
GroupsCleared returns if the edge groups was cleared.
func (*UserMutation) GroupsIDs ¶
func (m *UserMutation) GroupsIDs() (ids []string)
GroupsIDs returns the groups ids in the mutation.
func (*UserMutation) ID ¶
func (m *UserMutation) ID() (id string, exists bool)
ID returns the id value in the mutation. Note that, the id is available only if it was provided to the builder.
func (*UserMutation) Last ¶
func (m *UserMutation) Last() (r string, exists bool)
Last returns the last value in the mutation.
func (*UserMutation) Name ¶
func (m *UserMutation) Name() (r string, exists bool)
Name returns the name value in the mutation.
func (*UserMutation) Nickname ¶
func (m *UserMutation) Nickname() (r string, exists bool)
Nickname returns the nickname value in the mutation.
func (*UserMutation) NicknameCleared ¶
func (m *UserMutation) NicknameCleared() bool
NicknameCleared returns if the field nickname was cleared in this mutation.
func (*UserMutation) OldAge ¶
func (m *UserMutation) OldAge(ctx context.Context) (v int, err error)
OldAge returns the old age value of the User. 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 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 was failed.
func (*UserMutation) OldLast ¶
func (m *UserMutation) OldLast(ctx context.Context) (v string, err error)
OldLast returns the old last value of the User. 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 database query fails.
func (*UserMutation) OldName ¶
func (m *UserMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old name value of the User. 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 database query fails.
func (*UserMutation) OldNickname ¶
func (m *UserMutation) OldNickname(ctx context.Context) (v string, err error)
OldNickname returns the old nickname value of the User. 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 database query fails.
func (*UserMutation) OldOptionalInt ¶
func (m *UserMutation) OldOptionalInt(ctx context.Context) (v int, err error)
OldOptionalInt returns the old optional_int value of the User. 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 database query fails.
func (*UserMutation) OldPassword ¶
func (m *UserMutation) OldPassword(ctx context.Context) (v string, err error)
OldPassword returns the old password value of the User. 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 database query fails.
func (*UserMutation) OldPhone ¶
func (m *UserMutation) OldPhone(ctx context.Context) (v string, err error)
OldPhone returns the old phone value of the User. 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 database query fails.
func (*UserMutation) OldRole ¶
OldRole returns the old role value of the User. 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 database query fails.
func (*UserMutation) OldSSOCert ¶
func (m *UserMutation) OldSSOCert(ctx context.Context) (v string, err error)
OldSSOCert returns the old SSOCert value of the User. 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 database query fails.
func (*UserMutation) OptionalInt ¶
func (m *UserMutation) OptionalInt() (r int, exists bool)
OptionalInt returns the optional_int value in the mutation.
func (*UserMutation) OptionalIntCleared ¶
func (m *UserMutation) OptionalIntCleared() bool
OptionalIntCleared returns if the field optional_int was cleared in this mutation.
func (*UserMutation) ParentCleared ¶
func (m *UserMutation) ParentCleared() bool
ParentCleared returns if the edge parent was cleared.
func (*UserMutation) ParentID ¶
func (m *UserMutation) ParentID() (id string, exists bool)
ParentID returns the parent id in the mutation.
func (*UserMutation) ParentIDs ¶
func (m *UserMutation) ParentIDs() (ids []string)
ParentIDs returns the parent ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use ParentID instead. It exists only for internal usage by the builders.
func (*UserMutation) Password ¶
func (m *UserMutation) Password() (r string, exists bool)
Password returns the password value in the mutation.
func (*UserMutation) PasswordCleared ¶
func (m *UserMutation) PasswordCleared() bool
PasswordCleared returns if the field password was cleared in this mutation.
func (*UserMutation) PetsCleared ¶ added in v0.4.3
func (m *UserMutation) PetsCleared() bool
PetsCleared returns if the edge pets was cleared.
func (*UserMutation) PetsIDs ¶
func (m *UserMutation) PetsIDs() (ids []string)
PetsIDs returns the pets ids in the mutation.
func (*UserMutation) Phone ¶
func (m *UserMutation) Phone() (r string, exists bool)
Phone returns the phone value in the mutation.
func (*UserMutation) PhoneCleared ¶
func (m *UserMutation) PhoneCleared() bool
PhoneCleared returns if the field phone was cleared in this mutation.
func (*UserMutation) RemoveChildIDs ¶
func (m *UserMutation) RemoveChildIDs(ids ...string)
RemoveChildIDs removes the children edge to User by ids.
func (*UserMutation) RemoveFileIDs ¶
func (m *UserMutation) RemoveFileIDs(ids ...string)
RemoveFileIDs removes the files edge to File by ids.
func (*UserMutation) RemoveFollowerIDs ¶
func (m *UserMutation) RemoveFollowerIDs(ids ...string)
RemoveFollowerIDs removes the followers edge to User by ids.
func (*UserMutation) RemoveFollowingIDs ¶
func (m *UserMutation) RemoveFollowingIDs(ids ...string)
RemoveFollowingIDs removes the following edge to User by ids.
func (*UserMutation) RemoveFriendIDs ¶
func (m *UserMutation) RemoveFriendIDs(ids ...string)
RemoveFriendIDs removes the friends edge to User by ids.
func (*UserMutation) RemoveGroupIDs ¶
func (m *UserMutation) RemoveGroupIDs(ids ...string)
RemoveGroupIDs removes the groups edge to Group by ids.
func (*UserMutation) RemovePetIDs ¶
func (m *UserMutation) RemovePetIDs(ids ...string)
RemovePetIDs removes the pets edge to Pet by ids.
func (*UserMutation) RemovedChildrenIDs ¶
func (m *UserMutation) RemovedChildrenIDs() (ids []string)
RemovedChildren returns the removed ids of children.
func (*UserMutation) RemovedEdges ¶
func (m *UserMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*UserMutation) RemovedFilesIDs ¶
func (m *UserMutation) RemovedFilesIDs() (ids []string)
RemovedFiles returns the removed ids of files.
func (*UserMutation) RemovedFollowersIDs ¶
func (m *UserMutation) RemovedFollowersIDs() (ids []string)
RemovedFollowers returns the removed ids of followers.
func (*UserMutation) RemovedFollowingIDs ¶
func (m *UserMutation) RemovedFollowingIDs() (ids []string)
RemovedFollowing returns the removed ids of following.
func (*UserMutation) RemovedFriendsIDs ¶
func (m *UserMutation) RemovedFriendsIDs() (ids []string)
RemovedFriends returns the removed ids of friends.
func (*UserMutation) RemovedGroupsIDs ¶
func (m *UserMutation) RemovedGroupsIDs() (ids []string)
RemovedGroups returns the removed ids of groups.
func (*UserMutation) RemovedIDs ¶
func (m *UserMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all ids (to other nodes) that were removed for the given edge name.
func (*UserMutation) RemovedPetsIDs ¶
func (m *UserMutation) RemovedPetsIDs() (ids []string)
RemovedPets returns the removed ids of pets.
func (*UserMutation) ResetAge ¶
func (m *UserMutation) ResetAge()
ResetAge reset all changes of the "age" field.
func (*UserMutation) ResetCard ¶
func (m *UserMutation) ResetCard()
ResetCard reset all changes of the "card" edge.
func (*UserMutation) ResetChildren ¶
func (m *UserMutation) ResetChildren()
ResetChildren reset all changes of the "children" edge.
func (*UserMutation) ResetEdge ¶
func (m *UserMutation) ResetEdge(name string) error
ResetEdge resets all changes in the mutation regarding the given edge name. It returns an error if the edge is not defined in the schema.
func (*UserMutation) ResetField ¶
func (m *UserMutation) ResetField(name string) error
ResetField resets all changes in the mutation regarding the given field name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ResetFiles ¶
func (m *UserMutation) ResetFiles()
ResetFiles reset all changes of the "files" edge.
func (*UserMutation) ResetFollowers ¶
func (m *UserMutation) ResetFollowers()
ResetFollowers reset all changes of the "followers" edge.
func (*UserMutation) ResetFollowing ¶
func (m *UserMutation) ResetFollowing()
ResetFollowing reset all changes of the "following" edge.
func (*UserMutation) ResetFriends ¶
func (m *UserMutation) ResetFriends()
ResetFriends reset all changes of the "friends" edge.
func (*UserMutation) ResetGroups ¶
func (m *UserMutation) ResetGroups()
ResetGroups reset all changes of the "groups" edge.
func (*UserMutation) ResetLast ¶
func (m *UserMutation) ResetLast()
ResetLast reset all changes of the "last" field.
func (*UserMutation) ResetName ¶
func (m *UserMutation) ResetName()
ResetName reset all changes of the "name" field.
func (*UserMutation) ResetNickname ¶
func (m *UserMutation) ResetNickname()
ResetNickname reset all changes of the "nickname" field.
func (*UserMutation) ResetOptionalInt ¶
func (m *UserMutation) ResetOptionalInt()
ResetOptionalInt reset all changes of the "optional_int" field.
func (*UserMutation) ResetParent ¶
func (m *UserMutation) ResetParent()
ResetParent reset all changes of the "parent" edge.
func (*UserMutation) ResetPassword ¶
func (m *UserMutation) ResetPassword()
ResetPassword reset all changes of the "password" field.
func (*UserMutation) ResetPets ¶
func (m *UserMutation) ResetPets()
ResetPets reset all changes of the "pets" edge.
func (*UserMutation) ResetPhone ¶
func (m *UserMutation) ResetPhone()
ResetPhone reset all changes of the "phone" field.
func (*UserMutation) ResetRole ¶
func (m *UserMutation) ResetRole()
ResetRole reset all changes of the "role" field.
func (*UserMutation) ResetSSOCert ¶
func (m *UserMutation) ResetSSOCert()
ResetSSOCert reset all changes of the "SSOCert" field.
func (*UserMutation) ResetSpouse ¶
func (m *UserMutation) ResetSpouse()
ResetSpouse reset all changes of the "spouse" edge.
func (*UserMutation) ResetTeam ¶
func (m *UserMutation) ResetTeam()
ResetTeam reset all changes of the "team" edge.
func (*UserMutation) Role ¶
func (m *UserMutation) Role() (r user.Role, exists bool)
Role returns the role value in the mutation.
func (*UserMutation) SSOCert ¶
func (m *UserMutation) SSOCert() (r string, exists bool)
SSOCert returns the SSOCert value in the mutation.
func (*UserMutation) SSOCertCleared ¶
func (m *UserMutation) SSOCertCleared() bool
SSOCertCleared returns if the field SSOCert was cleared in this mutation.
func (*UserMutation) SetCardID ¶
func (m *UserMutation) SetCardID(id string)
SetCardID sets the card edge to Card by id.
func (*UserMutation) SetField ¶
func (m *UserMutation) SetField(name string, value ent.Value) error
SetField sets the value for the given name. It returns an error if the field is not defined in the schema, or if the type mismatch the field type.
func (*UserMutation) SetLast ¶
func (m *UserMutation) SetLast(s string)
SetLast sets the last field.
func (*UserMutation) SetName ¶
func (m *UserMutation) SetName(s string)
SetName sets the name field.
func (*UserMutation) SetNickname ¶
func (m *UserMutation) SetNickname(s string)
SetNickname sets the nickname field.
func (*UserMutation) SetOptionalInt ¶
func (m *UserMutation) SetOptionalInt(i int)
SetOptionalInt sets the optional_int field.
func (*UserMutation) SetParentID ¶
func (m *UserMutation) SetParentID(id string)
SetParentID sets the parent edge to User by id.
func (*UserMutation) SetPassword ¶
func (m *UserMutation) SetPassword(s string)
SetPassword sets the password field.
func (*UserMutation) SetPhone ¶
func (m *UserMutation) SetPhone(s string)
SetPhone sets the phone field.
func (*UserMutation) SetRole ¶
func (m *UserMutation) SetRole(u user.Role)
SetRole sets the role field.
func (*UserMutation) SetSSOCert ¶
func (m *UserMutation) SetSSOCert(s string)
SetSSOCert sets the SSOCert field.
func (*UserMutation) SetSpouseID ¶
func (m *UserMutation) SetSpouseID(id string)
SetSpouseID sets the spouse edge to User by id.
func (*UserMutation) SetTeamID ¶
func (m *UserMutation) SetTeamID(id string)
SetTeamID sets the team edge to Pet by id.
func (*UserMutation) SpouseCleared ¶
func (m *UserMutation) SpouseCleared() bool
SpouseCleared returns if the edge spouse was cleared.
func (*UserMutation) SpouseID ¶
func (m *UserMutation) SpouseID() (id string, exists bool)
SpouseID returns the spouse id in the mutation.
func (*UserMutation) SpouseIDs ¶
func (m *UserMutation) SpouseIDs() (ids []string)
SpouseIDs returns the spouse ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use SpouseID instead. It exists only for internal usage by the builders.
func (*UserMutation) TeamCleared ¶
func (m *UserMutation) TeamCleared() bool
TeamCleared returns if the edge team was cleared.
func (*UserMutation) TeamID ¶
func (m *UserMutation) TeamID() (id string, exists bool)
TeamID returns the team id in the mutation.
func (*UserMutation) TeamIDs ¶
func (m *UserMutation) TeamIDs() (ids []string)
TeamIDs returns the team ids in the mutation. Note that ids always returns len(ids) <= 1 for unique edges, and you should use TeamID instead. It exists only for internal usage by the builders.
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).
type UserQuery ¶
type UserQuery struct {
// contains filtered or unexported fields
}
UserQuery is the builder for querying User entities.
func (*UserQuery) Clone ¶
Clone returns a duplicate of the query 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) First ¶
First returns the first User entity in the query. Returns *NotFoundError when no user was found.
func (*UserQuery) FirstID ¶
FirstID returns the first User id in the query. Returns *NotFoundError when no id was found.
func (*UserQuery) FirstIDX ¶ added in v0.5.0
FirstIDX is like FirstID, but panics if an error occurs.
func (*UserQuery) GroupBy ¶
func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
GroupBy 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 { OptionalInt int `json:"optional_int,omitempty"` Count int `json:"count,omitempty"` } client.User.Query(). GroupBy(user.FieldOptionalInt). Aggregate(ent.Count()). Scan(ctx, &v)
func (*UserQuery) Only ¶
Only returns the only User entity in the query, returns an error if not exactly one entity was returned.
func (*UserQuery) OnlyID ¶
OnlyID returns the only User id in the query, returns an error if not exactly one id was returned.
func (*UserQuery) QueryChildren ¶
QueryChildren chains the current query on the children edge.
func (*UserQuery) QueryFiles ¶
QueryFiles chains the current query on the files edge.
func (*UserQuery) QueryFollowers ¶
QueryFollowers chains the current query on the followers edge.
func (*UserQuery) QueryFollowing ¶
QueryFollowing chains the current query on the following edge.
func (*UserQuery) QueryFriends ¶
QueryFriends chains the current query on the friends edge.
func (*UserQuery) QueryGroups ¶
func (uq *UserQuery) QueryGroups() *GroupQuery
QueryGroups chains the current query on the groups edge.
func (*UserQuery) QueryParent ¶
QueryParent chains the current query on the parent edge.
func (*UserQuery) QuerySpouse ¶
QuerySpouse chains the current query on the spouse edge.
func (*UserQuery) Select ¶
func (uq *UserQuery) Select(field string, fields ...string) *UserSelect
Select one or more fields from the given query.
Example:
var v []struct { OptionalInt int `json:"optional_int,omitempty"` } client.User.Query(). Select(user.FieldOptionalInt). Scan(ctx, &v)
func (*UserQuery) WithCard ¶
WithCard tells the query-builder to eager-loads the nodes that are connected to
the "card" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithChildren ¶
WithChildren tells the query-builder to eager-loads the nodes that are connected to
the "children" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithFiles ¶
WithFiles tells the query-builder to eager-loads the nodes that are connected to
the "files" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithFollowers ¶
WithFollowers tells the query-builder to eager-loads the nodes that are connected to
the "followers" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithFollowing ¶
WithFollowing tells the query-builder to eager-loads the nodes that are connected to
the "following" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithFriends ¶
WithFriends tells the query-builder to eager-loads the nodes that are connected to
the "friends" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithGroups ¶
func (uq *UserQuery) WithGroups(opts ...func(*GroupQuery)) *UserQuery
WithGroups tells the query-builder to eager-loads the nodes that are connected to
the "groups" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithParent ¶
WithParent tells the query-builder to eager-loads the nodes that are connected to
the "parent" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithPets ¶
WithPets tells the query-builder to eager-loads the nodes that are connected to
the "pets" edge. The optional arguments used to configure the query builder of the edge.
func (*UserQuery) WithSpouse ¶
WithSpouse tells the query-builder to eager-loads the nodes that are connected to
the "spouse" edge. The optional arguments used to configure the query builder of the edge.
type UserSelect ¶
type UserSelect struct {
// contains filtered or unexported fields
}
UserSelect is the builder for select fields of User entities.
func (*UserSelect) Bool ¶
func (us *UserSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from selector. It is only allowed when selecting one field.
func (*UserSelect) BoolX ¶
func (us *UserSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*UserSelect) Bools ¶
func (us *UserSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from selector. It is only allowed when selecting one field.
func (*UserSelect) BoolsX ¶
func (us *UserSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*UserSelect) Float64 ¶
func (us *UserSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from selector. It is only allowed when selecting one field.
func (*UserSelect) Float64X ¶
func (us *UserSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*UserSelect) Float64s ¶
func (us *UserSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from selector. It is only allowed when selecting one field.
func (*UserSelect) Float64sX ¶
func (us *UserSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*UserSelect) Int ¶
func (us *UserSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from selector. It is only allowed when selecting one field.
func (*UserSelect) IntX ¶
func (us *UserSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*UserSelect) Ints ¶
func (us *UserSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from selector. It is only allowed when selecting one field.
func (*UserSelect) IntsX ¶
func (us *UserSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*UserSelect) Scan ¶
func (us *UserSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scan the result into the given value.
func (*UserSelect) ScanX ¶
func (us *UserSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*UserSelect) String ¶
func (us *UserSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from selector. It is only allowed when selecting one field.
func (*UserSelect) StringX ¶
func (us *UserSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type UserUpdate ¶
type UserUpdate struct {
// contains filtered or unexported fields
}
UserUpdate is the builder for updating User entities.
func (*UserUpdate) AddChildIDs ¶
func (uu *UserUpdate) AddChildIDs(ids ...string) *UserUpdate
AddChildIDs adds the children edge to User by ids.
func (*UserUpdate) AddChildren ¶
func (uu *UserUpdate) AddChildren(u ...*User) *UserUpdate
AddChildren adds the children edges to User.
func (*UserUpdate) AddFileIDs ¶
func (uu *UserUpdate) AddFileIDs(ids ...string) *UserUpdate
AddFileIDs adds the files edge to File by ids.
func (*UserUpdate) AddFiles ¶
func (uu *UserUpdate) AddFiles(f ...*File) *UserUpdate
AddFiles adds the files edges to File.
func (*UserUpdate) AddFollowerIDs ¶
func (uu *UserUpdate) AddFollowerIDs(ids ...string) *UserUpdate
AddFollowerIDs adds the followers edge to User by ids.
func (*UserUpdate) AddFollowers ¶
func (uu *UserUpdate) AddFollowers(u ...*User) *UserUpdate
AddFollowers adds the followers edges to User.
func (*UserUpdate) AddFollowing ¶
func (uu *UserUpdate) AddFollowing(u ...*User) *UserUpdate
AddFollowing adds the following edges to User.
func (*UserUpdate) AddFollowingIDs ¶
func (uu *UserUpdate) AddFollowingIDs(ids ...string) *UserUpdate
AddFollowingIDs adds the following edge to User by ids.
func (*UserUpdate) AddFriendIDs ¶
func (uu *UserUpdate) AddFriendIDs(ids ...string) *UserUpdate
AddFriendIDs adds the friends edge to User by ids.
func (*UserUpdate) AddFriends ¶
func (uu *UserUpdate) AddFriends(u ...*User) *UserUpdate
AddFriends adds the friends edges to User.
func (*UserUpdate) AddGroupIDs ¶
func (uu *UserUpdate) AddGroupIDs(ids ...string) *UserUpdate
AddGroupIDs adds the groups edge to Group by ids.
func (*UserUpdate) AddGroups ¶
func (uu *UserUpdate) AddGroups(g ...*Group) *UserUpdate
AddGroups adds the groups edges to Group.
func (*UserUpdate) AddOptionalInt ¶
func (uu *UserUpdate) AddOptionalInt(i int) *UserUpdate
AddOptionalInt adds i to optional_int.
func (*UserUpdate) AddPetIDs ¶
func (uu *UserUpdate) AddPetIDs(ids ...string) *UserUpdate
AddPetIDs adds the pets edge to Pet by ids.
func (*UserUpdate) AddPets ¶
func (uu *UserUpdate) AddPets(p ...*Pet) *UserUpdate
AddPets adds the pets edges to Pet.
func (*UserUpdate) ClearCard ¶
func (uu *UserUpdate) ClearCard() *UserUpdate
ClearCard clears the "card" edge to type Card.
func (*UserUpdate) ClearChildren ¶ added in v0.4.3
func (uu *UserUpdate) ClearChildren() *UserUpdate
ClearChildren clears all "children" edges to type User.
func (*UserUpdate) ClearFiles ¶ added in v0.4.3
func (uu *UserUpdate) ClearFiles() *UserUpdate
ClearFiles clears all "files" edges to type File.
func (*UserUpdate) ClearFollowers ¶ added in v0.4.3
func (uu *UserUpdate) ClearFollowers() *UserUpdate
ClearFollowers clears all "followers" edges to type User.
func (*UserUpdate) ClearFollowing ¶ added in v0.4.3
func (uu *UserUpdate) ClearFollowing() *UserUpdate
ClearFollowing clears all "following" edges to type User.
func (*UserUpdate) ClearFriends ¶ added in v0.4.3
func (uu *UserUpdate) ClearFriends() *UserUpdate
ClearFriends clears all "friends" edges to type User.
func (*UserUpdate) ClearGroups ¶ added in v0.4.3
func (uu *UserUpdate) ClearGroups() *UserUpdate
ClearGroups clears all "groups" edges to type Group.
func (*UserUpdate) ClearNickname ¶
func (uu *UserUpdate) ClearNickname() *UserUpdate
ClearNickname clears the value of nickname.
func (*UserUpdate) ClearOptionalInt ¶
func (uu *UserUpdate) ClearOptionalInt() *UserUpdate
ClearOptionalInt clears the value of optional_int.
func (*UserUpdate) ClearParent ¶
func (uu *UserUpdate) ClearParent() *UserUpdate
ClearParent clears the "parent" edge to type User.
func (*UserUpdate) ClearPassword ¶
func (uu *UserUpdate) ClearPassword() *UserUpdate
ClearPassword clears the value of password.
func (*UserUpdate) ClearPets ¶ added in v0.4.3
func (uu *UserUpdate) ClearPets() *UserUpdate
ClearPets clears all "pets" edges to type Pet.
func (*UserUpdate) ClearPhone ¶
func (uu *UserUpdate) ClearPhone() *UserUpdate
ClearPhone clears the value of phone.
func (*UserUpdate) ClearSSOCert ¶
func (uu *UserUpdate) ClearSSOCert() *UserUpdate
ClearSSOCert clears the value of SSOCert.
func (*UserUpdate) ClearSpouse ¶
func (uu *UserUpdate) ClearSpouse() *UserUpdate
ClearSpouse clears the "spouse" edge to type User.
func (*UserUpdate) ClearTeam ¶
func (uu *UserUpdate) ClearTeam() *UserUpdate
ClearTeam clears the "team" edge to type Pet.
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) RemoveChildIDs ¶
func (uu *UserUpdate) RemoveChildIDs(ids ...string) *UserUpdate
RemoveChildIDs removes the children edge to User by ids.
func (*UserUpdate) RemoveChildren ¶
func (uu *UserUpdate) RemoveChildren(u ...*User) *UserUpdate
RemoveChildren removes children edges to User.
func (*UserUpdate) RemoveFileIDs ¶
func (uu *UserUpdate) RemoveFileIDs(ids ...string) *UserUpdate
RemoveFileIDs removes the files edge to File by ids.
func (*UserUpdate) RemoveFiles ¶
func (uu *UserUpdate) RemoveFiles(f ...*File) *UserUpdate
RemoveFiles removes files edges to File.
func (*UserUpdate) RemoveFollowerIDs ¶
func (uu *UserUpdate) RemoveFollowerIDs(ids ...string) *UserUpdate
RemoveFollowerIDs removes the followers edge to User by ids.
func (*UserUpdate) RemoveFollowers ¶
func (uu *UserUpdate) RemoveFollowers(u ...*User) *UserUpdate
RemoveFollowers removes followers edges to User.
func (*UserUpdate) RemoveFollowing ¶
func (uu *UserUpdate) RemoveFollowing(u ...*User) *UserUpdate
RemoveFollowing removes following edges to User.
func (*UserUpdate) RemoveFollowingIDs ¶
func (uu *UserUpdate) RemoveFollowingIDs(ids ...string) *UserUpdate
RemoveFollowingIDs removes the following edge to User by ids.
func (*UserUpdate) RemoveFriendIDs ¶
func (uu *UserUpdate) RemoveFriendIDs(ids ...string) *UserUpdate
RemoveFriendIDs removes the friends edge to User by ids.
func (*UserUpdate) RemoveFriends ¶
func (uu *UserUpdate) RemoveFriends(u ...*User) *UserUpdate
RemoveFriends removes friends edges to User.
func (*UserUpdate) RemoveGroupIDs ¶
func (uu *UserUpdate) RemoveGroupIDs(ids ...string) *UserUpdate
RemoveGroupIDs removes the groups edge to Group by ids.
func (*UserUpdate) RemoveGroups ¶
func (uu *UserUpdate) RemoveGroups(g ...*Group) *UserUpdate
RemoveGroups removes groups edges to Group.
func (*UserUpdate) RemovePetIDs ¶
func (uu *UserUpdate) RemovePetIDs(ids ...string) *UserUpdate
RemovePetIDs removes the pets edge to Pet by ids.
func (*UserUpdate) RemovePets ¶
func (uu *UserUpdate) RemovePets(p ...*Pet) *UserUpdate
RemovePets removes pets edges to Pet.
func (*UserUpdate) Save ¶
func (uu *UserUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of rows/vertices matched by this operation.
func (*UserUpdate) SaveX ¶
func (uu *UserUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*UserUpdate) SetAge ¶
func (uu *UserUpdate) SetAge(i int) *UserUpdate
SetAge sets the age field.
func (*UserUpdate) SetCard ¶
func (uu *UserUpdate) SetCard(c *Card) *UserUpdate
SetCard sets the card edge to Card.
func (*UserUpdate) SetCardID ¶
func (uu *UserUpdate) SetCardID(id string) *UserUpdate
SetCardID sets the card edge to Card by id.
func (*UserUpdate) SetLast ¶
func (uu *UserUpdate) SetLast(s string) *UserUpdate
SetLast sets the last field.
func (*UserUpdate) SetName ¶
func (uu *UserUpdate) SetName(s string) *UserUpdate
SetName sets the name field.
func (*UserUpdate) SetNickname ¶
func (uu *UserUpdate) SetNickname(s string) *UserUpdate
SetNickname sets the nickname field.
func (*UserUpdate) SetNillableCardID ¶
func (uu *UserUpdate) SetNillableCardID(id *string) *UserUpdate
SetNillableCardID sets the card edge to Card by id if the given value is not nil.
func (*UserUpdate) SetNillableLast ¶
func (uu *UserUpdate) SetNillableLast(s *string) *UserUpdate
SetNillableLast sets the last field if the given value is not nil.
func (*UserUpdate) SetNillableNickname ¶
func (uu *UserUpdate) SetNillableNickname(s *string) *UserUpdate
SetNillableNickname sets the nickname field if the given value is not nil.
func (*UserUpdate) SetNillableOptionalInt ¶
func (uu *UserUpdate) SetNillableOptionalInt(i *int) *UserUpdate
SetNillableOptionalInt sets the optional_int field if the given value is not nil.
func (*UserUpdate) SetNillableParentID ¶
func (uu *UserUpdate) SetNillableParentID(id *string) *UserUpdate
SetNillableParentID sets the parent edge to User by id if the given value is not nil.
func (*UserUpdate) SetNillablePassword ¶
func (uu *UserUpdate) SetNillablePassword(s *string) *UserUpdate
SetNillablePassword sets the password field if the given value is not nil.
func (*UserUpdate) SetNillablePhone ¶
func (uu *UserUpdate) SetNillablePhone(s *string) *UserUpdate
SetNillablePhone sets the phone field if the given value is not nil.
func (*UserUpdate) SetNillableRole ¶
func (uu *UserUpdate) SetNillableRole(u *user.Role) *UserUpdate
SetNillableRole sets the role field if the given value is not nil.
func (*UserUpdate) SetNillableSSOCert ¶
func (uu *UserUpdate) SetNillableSSOCert(s *string) *UserUpdate
SetNillableSSOCert sets the SSOCert field if the given value is not nil.
func (*UserUpdate) SetNillableSpouseID ¶
func (uu *UserUpdate) SetNillableSpouseID(id *string) *UserUpdate
SetNillableSpouseID sets the spouse edge to User by id if the given value is not nil.
func (*UserUpdate) SetNillableTeamID ¶
func (uu *UserUpdate) SetNillableTeamID(id *string) *UserUpdate
SetNillableTeamID sets the team edge to Pet by id if the given value is not nil.
func (*UserUpdate) SetOptionalInt ¶
func (uu *UserUpdate) SetOptionalInt(i int) *UserUpdate
SetOptionalInt sets the optional_int field.
func (*UserUpdate) SetParent ¶
func (uu *UserUpdate) SetParent(u *User) *UserUpdate
SetParent sets the parent edge to User.
func (*UserUpdate) SetParentID ¶
func (uu *UserUpdate) SetParentID(id string) *UserUpdate
SetParentID sets the parent edge to User by id.
func (*UserUpdate) SetPassword ¶
func (uu *UserUpdate) SetPassword(s string) *UserUpdate
SetPassword sets the password field.
func (*UserUpdate) SetPhone ¶
func (uu *UserUpdate) SetPhone(s string) *UserUpdate
SetPhone sets the phone field.
func (*UserUpdate) SetRole ¶
func (uu *UserUpdate) SetRole(u user.Role) *UserUpdate
SetRole sets the role field.
func (*UserUpdate) SetSSOCert ¶
func (uu *UserUpdate) SetSSOCert(s string) *UserUpdate
SetSSOCert sets the SSOCert field.
func (*UserUpdate) SetSpouse ¶
func (uu *UserUpdate) SetSpouse(u *User) *UserUpdate
SetSpouse sets the spouse edge to User.
func (*UserUpdate) SetSpouseID ¶
func (uu *UserUpdate) SetSpouseID(id string) *UserUpdate
SetSpouseID sets the spouse edge to User by id.
func (*UserUpdate) SetTeam ¶
func (uu *UserUpdate) SetTeam(p *Pet) *UserUpdate
SetTeam sets the team edge to Pet.
func (*UserUpdate) SetTeamID ¶
func (uu *UserUpdate) SetTeamID(id string) *UserUpdate
SetTeamID sets the team edge to Pet by id.
func (*UserUpdate) Where ¶
func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
Where adds a new predicate for the builder.
type UserUpdateOne ¶
type UserUpdateOne struct {
// contains filtered or unexported fields
}
UserUpdateOne is the builder for updating a single User entity.
func (*UserUpdateOne) AddAge ¶
func (uuo *UserUpdateOne) AddAge(i int) *UserUpdateOne
AddAge adds i to age.
func (*UserUpdateOne) AddChildIDs ¶
func (uuo *UserUpdateOne) AddChildIDs(ids ...string) *UserUpdateOne
AddChildIDs adds the children edge to User by ids.
func (*UserUpdateOne) AddChildren ¶
func (uuo *UserUpdateOne) AddChildren(u ...*User) *UserUpdateOne
AddChildren adds the children edges to User.
func (*UserUpdateOne) AddFileIDs ¶
func (uuo *UserUpdateOne) AddFileIDs(ids ...string) *UserUpdateOne
AddFileIDs adds the files edge to File by ids.
func (*UserUpdateOne) AddFiles ¶
func (uuo *UserUpdateOne) AddFiles(f ...*File) *UserUpdateOne
AddFiles adds the files edges to File.
func (*UserUpdateOne) AddFollowerIDs ¶
func (uuo *UserUpdateOne) AddFollowerIDs(ids ...string) *UserUpdateOne
AddFollowerIDs adds the followers edge to User by ids.
func (*UserUpdateOne) AddFollowers ¶
func (uuo *UserUpdateOne) AddFollowers(u ...*User) *UserUpdateOne
AddFollowers adds the followers edges to User.
func (*UserUpdateOne) AddFollowing ¶
func (uuo *UserUpdateOne) AddFollowing(u ...*User) *UserUpdateOne
AddFollowing adds the following edges to User.
func (*UserUpdateOne) AddFollowingIDs ¶
func (uuo *UserUpdateOne) AddFollowingIDs(ids ...string) *UserUpdateOne
AddFollowingIDs adds the following edge to User by ids.
func (*UserUpdateOne) AddFriendIDs ¶
func (uuo *UserUpdateOne) AddFriendIDs(ids ...string) *UserUpdateOne
AddFriendIDs adds the friends edge to User by ids.
func (*UserUpdateOne) AddFriends ¶
func (uuo *UserUpdateOne) AddFriends(u ...*User) *UserUpdateOne
AddFriends adds the friends edges to User.
func (*UserUpdateOne) AddGroupIDs ¶
func (uuo *UserUpdateOne) AddGroupIDs(ids ...string) *UserUpdateOne
AddGroupIDs adds the groups edge to Group by ids.
func (*UserUpdateOne) AddGroups ¶
func (uuo *UserUpdateOne) AddGroups(g ...*Group) *UserUpdateOne
AddGroups adds the groups edges to Group.
func (*UserUpdateOne) AddOptionalInt ¶
func (uuo *UserUpdateOne) AddOptionalInt(i int) *UserUpdateOne
AddOptionalInt adds i to optional_int.
func (*UserUpdateOne) AddPetIDs ¶
func (uuo *UserUpdateOne) AddPetIDs(ids ...string) *UserUpdateOne
AddPetIDs adds the pets edge to Pet by ids.
func (*UserUpdateOne) AddPets ¶
func (uuo *UserUpdateOne) AddPets(p ...*Pet) *UserUpdateOne
AddPets adds the pets edges to Pet.
func (*UserUpdateOne) ClearCard ¶
func (uuo *UserUpdateOne) ClearCard() *UserUpdateOne
ClearCard clears the "card" edge to type Card.
func (*UserUpdateOne) ClearChildren ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearChildren() *UserUpdateOne
ClearChildren clears all "children" edges to type User.
func (*UserUpdateOne) ClearFiles ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearFiles() *UserUpdateOne
ClearFiles clears all "files" edges to type File.
func (*UserUpdateOne) ClearFollowers ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearFollowers() *UserUpdateOne
ClearFollowers clears all "followers" edges to type User.
func (*UserUpdateOne) ClearFollowing ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearFollowing() *UserUpdateOne
ClearFollowing clears all "following" edges to type User.
func (*UserUpdateOne) ClearFriends ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearFriends() *UserUpdateOne
ClearFriends clears all "friends" edges to type User.
func (*UserUpdateOne) ClearGroups ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearGroups() *UserUpdateOne
ClearGroups clears all "groups" edges to type Group.
func (*UserUpdateOne) ClearNickname ¶
func (uuo *UserUpdateOne) ClearNickname() *UserUpdateOne
ClearNickname clears the value of nickname.
func (*UserUpdateOne) ClearOptionalInt ¶
func (uuo *UserUpdateOne) ClearOptionalInt() *UserUpdateOne
ClearOptionalInt clears the value of optional_int.
func (*UserUpdateOne) ClearParent ¶
func (uuo *UserUpdateOne) ClearParent() *UserUpdateOne
ClearParent clears the "parent" edge to type User.
func (*UserUpdateOne) ClearPassword ¶
func (uuo *UserUpdateOne) ClearPassword() *UserUpdateOne
ClearPassword clears the value of password.
func (*UserUpdateOne) ClearPets ¶ added in v0.4.3
func (uuo *UserUpdateOne) ClearPets() *UserUpdateOne
ClearPets clears all "pets" edges to type Pet.
func (*UserUpdateOne) ClearPhone ¶
func (uuo *UserUpdateOne) ClearPhone() *UserUpdateOne
ClearPhone clears the value of phone.
func (*UserUpdateOne) ClearSSOCert ¶
func (uuo *UserUpdateOne) ClearSSOCert() *UserUpdateOne
ClearSSOCert clears the value of SSOCert.
func (*UserUpdateOne) ClearSpouse ¶
func (uuo *UserUpdateOne) ClearSpouse() *UserUpdateOne
ClearSpouse clears the "spouse" edge to type User.
func (*UserUpdateOne) ClearTeam ¶
func (uuo *UserUpdateOne) ClearTeam() *UserUpdateOne
ClearTeam clears the "team" edge to type Pet.
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) RemoveChildIDs ¶
func (uuo *UserUpdateOne) RemoveChildIDs(ids ...string) *UserUpdateOne
RemoveChildIDs removes the children edge to User by ids.
func (*UserUpdateOne) RemoveChildren ¶
func (uuo *UserUpdateOne) RemoveChildren(u ...*User) *UserUpdateOne
RemoveChildren removes children edges to User.
func (*UserUpdateOne) RemoveFileIDs ¶
func (uuo *UserUpdateOne) RemoveFileIDs(ids ...string) *UserUpdateOne
RemoveFileIDs removes the files edge to File by ids.
func (*UserUpdateOne) RemoveFiles ¶
func (uuo *UserUpdateOne) RemoveFiles(f ...*File) *UserUpdateOne
RemoveFiles removes files edges to File.
func (*UserUpdateOne) RemoveFollowerIDs ¶
func (uuo *UserUpdateOne) RemoveFollowerIDs(ids ...string) *UserUpdateOne
RemoveFollowerIDs removes the followers edge to User by ids.
func (*UserUpdateOne) RemoveFollowers ¶
func (uuo *UserUpdateOne) RemoveFollowers(u ...*User) *UserUpdateOne
RemoveFollowers removes followers edges to User.
func (*UserUpdateOne) RemoveFollowing ¶
func (uuo *UserUpdateOne) RemoveFollowing(u ...*User) *UserUpdateOne
RemoveFollowing removes following edges to User.
func (*UserUpdateOne) RemoveFollowingIDs ¶
func (uuo *UserUpdateOne) RemoveFollowingIDs(ids ...string) *UserUpdateOne
RemoveFollowingIDs removes the following edge to User by ids.
func (*UserUpdateOne) RemoveFriendIDs ¶
func (uuo *UserUpdateOne) RemoveFriendIDs(ids ...string) *UserUpdateOne
RemoveFriendIDs removes the friends edge to User by ids.
func (*UserUpdateOne) RemoveFriends ¶
func (uuo *UserUpdateOne) RemoveFriends(u ...*User) *UserUpdateOne
RemoveFriends removes friends edges to User.
func (*UserUpdateOne) RemoveGroupIDs ¶
func (uuo *UserUpdateOne) RemoveGroupIDs(ids ...string) *UserUpdateOne
RemoveGroupIDs removes the groups edge to Group by ids.
func (*UserUpdateOne) RemoveGroups ¶
func (uuo *UserUpdateOne) RemoveGroups(g ...*Group) *UserUpdateOne
RemoveGroups removes groups edges to Group.
func (*UserUpdateOne) RemovePetIDs ¶
func (uuo *UserUpdateOne) RemovePetIDs(ids ...string) *UserUpdateOne
RemovePetIDs removes the pets edge to Pet by ids.
func (*UserUpdateOne) RemovePets ¶
func (uuo *UserUpdateOne) RemovePets(p ...*Pet) *UserUpdateOne
RemovePets removes pets edges to Pet.
func (*UserUpdateOne) Save ¶
func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
Save executes the query and returns the updated entity.
func (*UserUpdateOne) SaveX ¶
func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
SaveX is like Save, but panics if an error occurs.
func (*UserUpdateOne) SetAge ¶
func (uuo *UserUpdateOne) SetAge(i int) *UserUpdateOne
SetAge sets the age field.
func (*UserUpdateOne) SetCard ¶
func (uuo *UserUpdateOne) SetCard(c *Card) *UserUpdateOne
SetCard sets the card edge to Card.
func (*UserUpdateOne) SetCardID ¶
func (uuo *UserUpdateOne) SetCardID(id string) *UserUpdateOne
SetCardID sets the card edge to Card by id.
func (*UserUpdateOne) SetLast ¶
func (uuo *UserUpdateOne) SetLast(s string) *UserUpdateOne
SetLast sets the last field.
func (*UserUpdateOne) SetName ¶
func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne
SetName sets the name field.
func (*UserUpdateOne) SetNickname ¶
func (uuo *UserUpdateOne) SetNickname(s string) *UserUpdateOne
SetNickname sets the nickname field.
func (*UserUpdateOne) SetNillableCardID ¶
func (uuo *UserUpdateOne) SetNillableCardID(id *string) *UserUpdateOne
SetNillableCardID sets the card edge to Card by id if the given value is not nil.
func (*UserUpdateOne) SetNillableLast ¶
func (uuo *UserUpdateOne) SetNillableLast(s *string) *UserUpdateOne
SetNillableLast sets the last field if the given value is not nil.
func (*UserUpdateOne) SetNillableNickname ¶
func (uuo *UserUpdateOne) SetNillableNickname(s *string) *UserUpdateOne
SetNillableNickname sets the nickname field if the given value is not nil.
func (*UserUpdateOne) SetNillableOptionalInt ¶
func (uuo *UserUpdateOne) SetNillableOptionalInt(i *int) *UserUpdateOne
SetNillableOptionalInt sets the optional_int field if the given value is not nil.
func (*UserUpdateOne) SetNillableParentID ¶
func (uuo *UserUpdateOne) SetNillableParentID(id *string) *UserUpdateOne
SetNillableParentID sets the parent edge to User by id if the given value is not nil.
func (*UserUpdateOne) SetNillablePassword ¶
func (uuo *UserUpdateOne) SetNillablePassword(s *string) *UserUpdateOne
SetNillablePassword sets the password field if the given value is not nil.
func (*UserUpdateOne) SetNillablePhone ¶
func (uuo *UserUpdateOne) SetNillablePhone(s *string) *UserUpdateOne
SetNillablePhone sets the phone field if the given value is not nil.
func (*UserUpdateOne) SetNillableRole ¶
func (uuo *UserUpdateOne) SetNillableRole(u *user.Role) *UserUpdateOne
SetNillableRole sets the role field if the given value is not nil.
func (*UserUpdateOne) SetNillableSSOCert ¶
func (uuo *UserUpdateOne) SetNillableSSOCert(s *string) *UserUpdateOne
SetNillableSSOCert sets the SSOCert field if the given value is not nil.
func (*UserUpdateOne) SetNillableSpouseID ¶
func (uuo *UserUpdateOne) SetNillableSpouseID(id *string) *UserUpdateOne
SetNillableSpouseID sets the spouse edge to User by id if the given value is not nil.
func (*UserUpdateOne) SetNillableTeamID ¶
func (uuo *UserUpdateOne) SetNillableTeamID(id *string) *UserUpdateOne
SetNillableTeamID sets the team edge to Pet by id if the given value is not nil.
func (*UserUpdateOne) SetOptionalInt ¶
func (uuo *UserUpdateOne) SetOptionalInt(i int) *UserUpdateOne
SetOptionalInt sets the optional_int field.
func (*UserUpdateOne) SetParent ¶
func (uuo *UserUpdateOne) SetParent(u *User) *UserUpdateOne
SetParent sets the parent edge to User.
func (*UserUpdateOne) SetParentID ¶
func (uuo *UserUpdateOne) SetParentID(id string) *UserUpdateOne
SetParentID sets the parent edge to User by id.
func (*UserUpdateOne) SetPassword ¶
func (uuo *UserUpdateOne) SetPassword(s string) *UserUpdateOne
SetPassword sets the password field.
func (*UserUpdateOne) SetPhone ¶
func (uuo *UserUpdateOne) SetPhone(s string) *UserUpdateOne
SetPhone sets the phone field.
func (*UserUpdateOne) SetRole ¶
func (uuo *UserUpdateOne) SetRole(u user.Role) *UserUpdateOne
SetRole sets the role field.
func (*UserUpdateOne) SetSSOCert ¶
func (uuo *UserUpdateOne) SetSSOCert(s string) *UserUpdateOne
SetSSOCert sets the SSOCert field.
func (*UserUpdateOne) SetSpouse ¶
func (uuo *UserUpdateOne) SetSpouse(u *User) *UserUpdateOne
SetSpouse sets the spouse edge to User.
func (*UserUpdateOne) SetSpouseID ¶
func (uuo *UserUpdateOne) SetSpouseID(id string) *UserUpdateOne
SetSpouseID sets the spouse edge to User by id.
func (*UserUpdateOne) SetTeam ¶
func (uuo *UserUpdateOne) SetTeam(p *Pet) *UserUpdateOne
SetTeam sets the team edge to Pet.
func (*UserUpdateOne) SetTeamID ¶
func (uuo *UserUpdateOne) SetTeamID(id string) *UserUpdateOne
SetTeamID sets the team edge to Pet by id.
type ValidationError ¶
type ValidationError struct { Name string // Field or edge name. // contains filtered or unexported fields }
ValidationError returns when validating a field 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 ¶
- card.go
- card_create.go
- card_delete.go
- card_query.go
- card_update.go
- client.go
- comment.go
- comment_create.go
- comment_delete.go
- comment_query.go
- comment_update.go
- config.go
- context.go
- ent.go
- extension.go
- fieldtype.go
- fieldtype_create.go
- fieldtype_delete.go
- fieldtype_query.go
- fieldtype_update.go
- file.go
- file_create.go
- file_delete.go
- file_query.go
- file_update.go
- filetype.go
- filetype_create.go
- filetype_delete.go
- filetype_query.go
- filetype_update.go
- generate.go
- goods.go
- goods_create.go
- goods_delete.go
- goods_query.go
- goods_update.go
- group.go
- group_create.go
- group_delete.go
- group_query.go
- group_update.go
- groupinfo.go
- groupinfo_create.go
- groupinfo_delete.go
- groupinfo_query.go
- groupinfo_update.go
- item.go
- item_create.go
- item_delete.go
- item_query.go
- item_update.go
- mutation.go
- node.go
- node_create.go
- node_delete.go
- node_query.go
- node_update.go
- pet.go
- pet_create.go
- pet_delete.go
- pet_query.go
- pet_update.go
- runtime.go
- spec.go
- spec_create.go
- spec_delete.go
- spec_query.go
- spec_update.go
- task.go
- task_create.go
- task_delete.go
- task_query.go
- task_update.go
- tx.go
- user.go
- user_create.go
- user_delete.go
- user_query.go
- user_update.go