Versions in this module Expand all Collapse all v0 v0.5.4 Jan 6, 2021 Changes in this version type User + Foods []string type UserCreate + func (uc *UserCreate) SetFoods(s []string) *UserCreate type UserFilter + func (f *UserFilter) WhereFoods(p entql.BytesP) type UserMutation + func (m *UserMutation) ClearFoods() + func (m *UserMutation) Foods() (r []string, exists bool) + func (m *UserMutation) FoodsCleared() bool + func (m *UserMutation) OldFoods(ctx context.Context) (v []string, err error) + func (m *UserMutation) ResetFoods() + func (m *UserMutation) SetFoods(s []string) type UserUpdate + func (uu *UserUpdate) ClearFoods() *UserUpdate + func (uu *UserUpdate) SetFoods(s []string) *UserUpdate type UserUpdateOne + func (uuo *UserUpdateOne) ClearFoods() *UserUpdateOne + func (uuo *UserUpdateOne) SetFoods(s []string) *UserUpdateOne v0.5.3 Dec 13, 2020 v0.5.2 Dec 11, 2020 v0.5.1 Nov 29, 2020 v0.5.0 Nov 3, 2020 Changes in this version + const OpCreate + const OpDelete + const OpDeleteOne + const OpUpdate + const OpUpdateOne + const TypeGroup + const TypeTenant + const TypeUser + 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 func(*sql.Selector, func(string) bool) string + func As(fn AggregateFunc, end string) AggregateFunc + func Count() AggregateFunc + func Max(field string) AggregateFunc + func Mean(field string) AggregateFunc + func Min(field string) AggregateFunc + func Sum(field string) AggregateFunc + type Client struct + Group *GroupClient + Schema *migrate.Schema + Tenant *TenantClient + User *UserClient + func FromContext(ctx context.Context) *Client + func NewClient(opts ...Option) *Client + func Open(driverName, dataSourceName string, options ...Option) (*Client, error) + func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error) + func (c *Client) Close() error + func (c *Client) Debug() *Client + func (c *Client) Tx(ctx context.Context) (*Tx, error) + func (c *Client) Use(hooks ...Hook) + type CommitFunc func(context.Context, *Tx) error + func (f CommitFunc) Commit(ctx context.Context, tx *Tx) error + type CommitHook func(Committer) Committer + type Committer interface + Commit func(context.Context, *Tx) error + type ConstraintError struct + func (e *ConstraintError) Unwrap() error + func (e ConstraintError) Error() string + type Group struct + Edges GroupEdges + ID int + Name string + func (gr *Group) QueryTenant() *TenantQuery + func (gr *Group) QueryUsers() *UserQuery + func (gr *Group) String() string + func (gr *Group) Unwrap() *Group + func (gr *Group) Update() *GroupUpdateOne + type GroupClient struct + func NewGroupClient(c config) *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 int) *GroupDeleteOne + func (c *GroupClient) Get(ctx context.Context, id int) (*Group, error) + func (c *GroupClient) GetX(ctx context.Context, id int) *Group + func (c *GroupClient) Hooks() []Hook + func (c *GroupClient) Query() *GroupQuery + func (c *GroupClient) QueryTenant(gr *Group) *TenantQuery + func (c *GroupClient) QueryUsers(gr *Group) *UserQuery + func (c *GroupClient) Update() *GroupUpdate + func (c *GroupClient) UpdateOne(gr *Group) *GroupUpdateOne + func (c *GroupClient) UpdateOneID(id int) *GroupUpdateOne + func (c *GroupClient) Use(hooks ...Hook) + type GroupCreate struct + func (gc *GroupCreate) AddUserIDs(ids ...int) *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) SetName(s string) *GroupCreate + func (gc *GroupCreate) SetNillableName(s *string) *GroupCreate + func (gc *GroupCreate) SetTenant(t *Tenant) *GroupCreate + func (gc *GroupCreate) SetTenantID(id int) *GroupCreate + type GroupCreateBulk struct + func (gcb *GroupCreateBulk) Save(ctx context.Context) ([]*Group, error) + func (gcb *GroupCreateBulk) SaveX(ctx context.Context) []*Group + type GroupDelete struct + func (gd *GroupDelete) Exec(ctx context.Context) (int, error) + func (gd *GroupDelete) ExecX(ctx context.Context) int + func (gd *GroupDelete) Where(ps ...predicate.Group) *GroupDelete + type GroupDeleteOne struct + func (gdo *GroupDeleteOne) Exec(ctx context.Context) error + func (gdo *GroupDeleteOne) ExecX(ctx context.Context) + type GroupEdges struct + Tenant *Tenant + Users []*User + func (e GroupEdges) TenantOrErr() (*Tenant, error) + func (e GroupEdges) UsersOrErr() ([]*User, error) + type GroupFilter struct + func (f *GroupFilter) Where(p entql.P) + func (f *GroupFilter) WhereHasTenant() + func (f *GroupFilter) WhereHasTenantWith(preds ...predicate.Tenant) + func (f *GroupFilter) WhereHasUsers() + func (f *GroupFilter) WhereHasUsersWith(preds ...predicate.User) + func (f *GroupFilter) WhereID(p entql.IntP) + func (f *GroupFilter) WhereName(p entql.StringP) + type GroupGroupBy struct + 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 GroupMutation struct + func (m *GroupMutation) AddField(name string, value ent.Value) error + func (m *GroupMutation) AddUserIDs(ids ...int) + 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) ClearEdge(name string) error + func (m *GroupMutation) ClearField(name string) error + func (m *GroupMutation) ClearTenant() + func (m *GroupMutation) ClearUsers() + func (m *GroupMutation) ClearedEdges() []string + func (m *GroupMutation) ClearedFields() []string + func (m *GroupMutation) EdgeCleared(name string) 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) Filter() *GroupFilter + func (m *GroupMutation) ID() (id int, exists bool) + func (m *GroupMutation) Name() (r string, exists bool) + func (m *GroupMutation) OldField(ctx context.Context, name string) (ent.Value, error) + func (m *GroupMutation) OldName(ctx context.Context) (v string, err error) + func (m *GroupMutation) Op() Op + func (m *GroupMutation) RemoveUserIDs(ids ...int) + func (m *GroupMutation) RemovedEdges() []string + func (m *GroupMutation) RemovedIDs(name string) []ent.Value + func (m *GroupMutation) RemovedUsersIDs() (ids []int) + func (m *GroupMutation) ResetEdge(name string) error + func (m *GroupMutation) ResetField(name string) error + func (m *GroupMutation) ResetName() + func (m *GroupMutation) ResetTenant() + func (m *GroupMutation) ResetUsers() + func (m *GroupMutation) SetField(name string, value ent.Value) error + func (m *GroupMutation) SetName(s string) + func (m *GroupMutation) SetTenantID(id int) + func (m *GroupMutation) TenantCleared() bool + func (m *GroupMutation) TenantID() (id int, exists bool) + func (m *GroupMutation) TenantIDs() (ids []int) + func (m *GroupMutation) Type() string + func (m *GroupMutation) UsersCleared() bool + func (m *GroupMutation) UsersIDs() (ids []int) + func (m GroupMutation) Client() *Client + func (m GroupMutation) Tx() (*Tx, error) + type GroupQuery struct + 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) Filter() *GroupFilter + func (gq *GroupQuery) First(ctx context.Context) (*Group, error) + func (gq *GroupQuery) FirstID(ctx context.Context) (id int, err error) + func (gq *GroupQuery) FirstIDX(ctx context.Context) int + func (gq *GroupQuery) FirstX(ctx context.Context) *Group + func (gq *GroupQuery) GroupBy(field string, fields ...string) *GroupGroupBy + func (gq *GroupQuery) IDs(ctx context.Context) ([]int, error) + func (gq *GroupQuery) IDsX(ctx context.Context) []int + 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 int, err error) + func (gq *GroupQuery) OnlyIDX(ctx context.Context) int + func (gq *GroupQuery) OnlyX(ctx context.Context) *Group + func (gq *GroupQuery) Order(o ...OrderFunc) *GroupQuery + func (gq *GroupQuery) QueryTenant() *TenantQuery + 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) WithTenant(opts ...func(*TenantQuery)) *GroupQuery + func (gq *GroupQuery) WithUsers(opts ...func(*UserQuery)) *GroupQuery + type GroupSelect struct + 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 struct + func (gu *GroupUpdate) AddUserIDs(ids ...int) *GroupUpdate + func (gu *GroupUpdate) AddUsers(u ...*User) *GroupUpdate + func (gu *GroupUpdate) ClearTenant() *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) RemoveUserIDs(ids ...int) *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) SetName(s string) *GroupUpdate + func (gu *GroupUpdate) SetNillableName(s *string) *GroupUpdate + func (gu *GroupUpdate) SetTenant(t *Tenant) *GroupUpdate + func (gu *GroupUpdate) SetTenantID(id int) *GroupUpdate + func (gu *GroupUpdate) Where(ps ...predicate.Group) *GroupUpdate + type GroupUpdateOne struct + func (guo *GroupUpdateOne) AddUserIDs(ids ...int) *GroupUpdateOne + func (guo *GroupUpdateOne) AddUsers(u ...*User) *GroupUpdateOne + func (guo *GroupUpdateOne) ClearTenant() *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) RemoveUserIDs(ids ...int) *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) SetName(s string) *GroupUpdateOne + func (guo *GroupUpdateOne) SetNillableName(s *string) *GroupUpdateOne + func (guo *GroupUpdateOne) SetTenant(t *Tenant) *GroupUpdateOne + func (guo *GroupUpdateOne) SetTenantID(id int) *GroupUpdateOne + type Groups []*Group + type Hook = ent.Hook + type MutateFunc = ent.MutateFunc + type Mutation = ent.Mutation + type Mutator = ent.Mutator + type NotFoundError struct + func (e *NotFoundError) Error() string + type NotLoadedError struct + func (e *NotLoadedError) Error() string + type NotSingularError struct + func (e *NotSingularError) Error() string + type Op = ent.Op + type Option func(*config) + func Debug() Option + func Driver(driver dialect.Driver) Option + func Log(fn func(...interface{})) Option + type OrderFunc func(*sql.Selector, func(string) bool) + func Asc(fields ...string) OrderFunc + func Desc(fields ...string) OrderFunc + type Policy = ent.Policy + type Query = ent.Query + type RollbackFunc func(context.Context, *Tx) error + func (f RollbackFunc) Rollback(ctx context.Context, tx *Tx) error + type RollbackHook func(Rollbacker) Rollbacker + type Rollbacker interface + Rollback func(context.Context, *Tx) error + type Tenant struct + ID int + Name string + func (t *Tenant) String() string + func (t *Tenant) Unwrap() *Tenant + func (t *Tenant) Update() *TenantUpdateOne + type TenantClient struct + func NewTenantClient(c config) *TenantClient + func (c *TenantClient) Create() *TenantCreate + func (c *TenantClient) CreateBulk(builders ...*TenantCreate) *TenantCreateBulk + func (c *TenantClient) Delete() *TenantDelete + func (c *TenantClient) DeleteOne(t *Tenant) *TenantDeleteOne + func (c *TenantClient) DeleteOneID(id int) *TenantDeleteOne + func (c *TenantClient) Get(ctx context.Context, id int) (*Tenant, error) + func (c *TenantClient) GetX(ctx context.Context, id int) *Tenant + func (c *TenantClient) Hooks() []Hook + func (c *TenantClient) Query() *TenantQuery + func (c *TenantClient) Update() *TenantUpdate + func (c *TenantClient) UpdateOne(t *Tenant) *TenantUpdateOne + func (c *TenantClient) UpdateOneID(id int) *TenantUpdateOne + func (c *TenantClient) Use(hooks ...Hook) + type TenantCreate struct + func (tc *TenantCreate) Mutation() *TenantMutation + func (tc *TenantCreate) Save(ctx context.Context) (*Tenant, error) + func (tc *TenantCreate) SaveX(ctx context.Context) *Tenant + func (tc *TenantCreate) SetName(s string) *TenantCreate + type TenantCreateBulk struct + func (tcb *TenantCreateBulk) Save(ctx context.Context) ([]*Tenant, error) + func (tcb *TenantCreateBulk) SaveX(ctx context.Context) []*Tenant + type TenantDelete struct + func (td *TenantDelete) Exec(ctx context.Context) (int, error) + func (td *TenantDelete) ExecX(ctx context.Context) int + func (td *TenantDelete) Where(ps ...predicate.Tenant) *TenantDelete + type TenantDeleteOne struct + func (tdo *TenantDeleteOne) Exec(ctx context.Context) error + func (tdo *TenantDeleteOne) ExecX(ctx context.Context) + type TenantFilter struct + func (f *TenantFilter) Where(p entql.P) + func (f *TenantFilter) WhereID(p entql.IntP) + func (f *TenantFilter) WhereName(p entql.StringP) + type TenantGroupBy struct + func (tgb *TenantGroupBy) Aggregate(fns ...AggregateFunc) *TenantGroupBy + func (tgb *TenantGroupBy) Bool(ctx context.Context) (_ bool, err error) + func (tgb *TenantGroupBy) BoolX(ctx context.Context) bool + func (tgb *TenantGroupBy) Bools(ctx context.Context) ([]bool, error) + func (tgb *TenantGroupBy) BoolsX(ctx context.Context) []bool + func (tgb *TenantGroupBy) Float64(ctx context.Context) (_ float64, err error) + func (tgb *TenantGroupBy) Float64X(ctx context.Context) float64 + func (tgb *TenantGroupBy) Float64s(ctx context.Context) ([]float64, error) + func (tgb *TenantGroupBy) Float64sX(ctx context.Context) []float64 + func (tgb *TenantGroupBy) Int(ctx context.Context) (_ int, err error) + func (tgb *TenantGroupBy) IntX(ctx context.Context) int + func (tgb *TenantGroupBy) Ints(ctx context.Context) ([]int, error) + func (tgb *TenantGroupBy) IntsX(ctx context.Context) []int + func (tgb *TenantGroupBy) Scan(ctx context.Context, v interface{}) error + func (tgb *TenantGroupBy) ScanX(ctx context.Context, v interface{}) + func (tgb *TenantGroupBy) String(ctx context.Context) (_ string, err error) + func (tgb *TenantGroupBy) StringX(ctx context.Context) string + func (tgb *TenantGroupBy) Strings(ctx context.Context) ([]string, error) + func (tgb *TenantGroupBy) StringsX(ctx context.Context) []string + type TenantMutation struct + func (m *TenantMutation) AddField(name string, value ent.Value) error + func (m *TenantMutation) AddedEdges() []string + func (m *TenantMutation) AddedField(name string) (ent.Value, bool) + func (m *TenantMutation) AddedFields() []string + func (m *TenantMutation) AddedIDs(name string) []ent.Value + func (m *TenantMutation) ClearEdge(name string) error + func (m *TenantMutation) ClearField(name string) error + func (m *TenantMutation) ClearedEdges() []string + func (m *TenantMutation) ClearedFields() []string + func (m *TenantMutation) EdgeCleared(name string) bool + func (m *TenantMutation) Field(name string) (ent.Value, bool) + func (m *TenantMutation) FieldCleared(name string) bool + func (m *TenantMutation) Fields() []string + func (m *TenantMutation) Filter() *TenantFilter + func (m *TenantMutation) ID() (id int, exists bool) + func (m *TenantMutation) Name() (r string, exists bool) + func (m *TenantMutation) OldField(ctx context.Context, name string) (ent.Value, error) + func (m *TenantMutation) OldName(ctx context.Context) (v string, err error) + func (m *TenantMutation) Op() Op + func (m *TenantMutation) RemovedEdges() []string + func (m *TenantMutation) RemovedIDs(name string) []ent.Value + func (m *TenantMutation) ResetEdge(name string) error + func (m *TenantMutation) ResetField(name string) error + func (m *TenantMutation) ResetName() + func (m *TenantMutation) SetField(name string, value ent.Value) error + func (m *TenantMutation) SetName(s string) + func (m *TenantMutation) Type() string + func (m TenantMutation) Client() *Client + func (m TenantMutation) Tx() (*Tx, error) + type TenantQuery struct + func (tq *TenantQuery) All(ctx context.Context) ([]*Tenant, error) + func (tq *TenantQuery) AllX(ctx context.Context) []*Tenant + func (tq *TenantQuery) Clone() *TenantQuery + func (tq *TenantQuery) Count(ctx context.Context) (int, error) + func (tq *TenantQuery) CountX(ctx context.Context) int + func (tq *TenantQuery) Exist(ctx context.Context) (bool, error) + func (tq *TenantQuery) ExistX(ctx context.Context) bool + func (tq *TenantQuery) Filter() *TenantFilter + func (tq *TenantQuery) First(ctx context.Context) (*Tenant, error) + func (tq *TenantQuery) FirstID(ctx context.Context) (id int, err error) + func (tq *TenantQuery) FirstIDX(ctx context.Context) int + func (tq *TenantQuery) FirstX(ctx context.Context) *Tenant + func (tq *TenantQuery) GroupBy(field string, fields ...string) *TenantGroupBy + func (tq *TenantQuery) IDs(ctx context.Context) ([]int, error) + func (tq *TenantQuery) IDsX(ctx context.Context) []int + func (tq *TenantQuery) Limit(limit int) *TenantQuery + func (tq *TenantQuery) Offset(offset int) *TenantQuery + func (tq *TenantQuery) Only(ctx context.Context) (*Tenant, error) + func (tq *TenantQuery) OnlyID(ctx context.Context) (id int, err error) + func (tq *TenantQuery) OnlyIDX(ctx context.Context) int + func (tq *TenantQuery) OnlyX(ctx context.Context) *Tenant + func (tq *TenantQuery) Order(o ...OrderFunc) *TenantQuery + func (tq *TenantQuery) Select(field string, fields ...string) *TenantSelect + func (tq *TenantQuery) Where(ps ...predicate.Tenant) *TenantQuery + type TenantSelect struct + func (ts *TenantSelect) Bool(ctx context.Context) (_ bool, err error) + func (ts *TenantSelect) BoolX(ctx context.Context) bool + func (ts *TenantSelect) Bools(ctx context.Context) ([]bool, error) + func (ts *TenantSelect) BoolsX(ctx context.Context) []bool + func (ts *TenantSelect) Float64(ctx context.Context) (_ float64, err error) + func (ts *TenantSelect) Float64X(ctx context.Context) float64 + func (ts *TenantSelect) Float64s(ctx context.Context) ([]float64, error) + func (ts *TenantSelect) Float64sX(ctx context.Context) []float64 + func (ts *TenantSelect) Int(ctx context.Context) (_ int, err error) + func (ts *TenantSelect) IntX(ctx context.Context) int + func (ts *TenantSelect) Ints(ctx context.Context) ([]int, error) + func (ts *TenantSelect) IntsX(ctx context.Context) []int + func (ts *TenantSelect) Scan(ctx context.Context, v interface{}) error + func (ts *TenantSelect) ScanX(ctx context.Context, v interface{}) + func (ts *TenantSelect) String(ctx context.Context) (_ string, err error) + func (ts *TenantSelect) StringX(ctx context.Context) string + func (ts *TenantSelect) Strings(ctx context.Context) ([]string, error) + func (ts *TenantSelect) StringsX(ctx context.Context) []string + type TenantUpdate struct + func (tu *TenantUpdate) Exec(ctx context.Context) error + func (tu *TenantUpdate) ExecX(ctx context.Context) + func (tu *TenantUpdate) Mutation() *TenantMutation + func (tu *TenantUpdate) Save(ctx context.Context) (int, error) + func (tu *TenantUpdate) SaveX(ctx context.Context) int + func (tu *TenantUpdate) SetName(s string) *TenantUpdate + func (tu *TenantUpdate) Where(ps ...predicate.Tenant) *TenantUpdate + type TenantUpdateOne struct + func (tuo *TenantUpdateOne) Exec(ctx context.Context) error + func (tuo *TenantUpdateOne) ExecX(ctx context.Context) + func (tuo *TenantUpdateOne) Mutation() *TenantMutation + func (tuo *TenantUpdateOne) Save(ctx context.Context) (*Tenant, error) + func (tuo *TenantUpdateOne) SaveX(ctx context.Context) *Tenant + func (tuo *TenantUpdateOne) SetName(s string) *TenantUpdateOne + type Tenants []*Tenant + type Tx struct + Group *GroupClient + Tenant *TenantClient + User *UserClient + func TxFromContext(ctx context.Context) *Tx + func (tx *Tx) Client() *Client + func (tx *Tx) Commit() error + func (tx *Tx) OnCommit(f CommitHook) + func (tx *Tx) OnRollback(f RollbackHook) + func (tx *Tx) Rollback() error + type User struct + Edges UserEdges + ID int + Name string + func (u *User) QueryGroups() *GroupQuery + func (u *User) QueryTenant() *TenantQuery + func (u *User) String() string + func (u *User) Unwrap() *User + func (u *User) Update() *UserUpdateOne + type UserClient struct + func NewUserClient(c config) *UserClient + func (c *UserClient) Create() *UserCreate + func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk + func (c *UserClient) Delete() *UserDelete + func (c *UserClient) DeleteOne(u *User) *UserDeleteOne + func (c *UserClient) DeleteOneID(id int) *UserDeleteOne + func (c *UserClient) Get(ctx context.Context, id int) (*User, error) + func (c *UserClient) GetX(ctx context.Context, id int) *User + func (c *UserClient) Hooks() []Hook + func (c *UserClient) Query() *UserQuery + func (c *UserClient) QueryGroups(u *User) *GroupQuery + func (c *UserClient) QueryTenant(u *User) *TenantQuery + func (c *UserClient) Update() *UserUpdate + func (c *UserClient) UpdateOne(u *User) *UserUpdateOne + func (c *UserClient) UpdateOneID(id int) *UserUpdateOne + func (c *UserClient) Use(hooks ...Hook) + type UserCreate struct + func (uc *UserCreate) AddGroupIDs(ids ...int) *UserCreate + func (uc *UserCreate) AddGroups(g ...*Group) *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) SetName(s string) *UserCreate + func (uc *UserCreate) SetNillableName(s *string) *UserCreate + func (uc *UserCreate) SetTenant(t *Tenant) *UserCreate + func (uc *UserCreate) SetTenantID(id int) *UserCreate + type UserCreateBulk struct + func (ucb *UserCreateBulk) Save(ctx context.Context) ([]*User, error) + func (ucb *UserCreateBulk) SaveX(ctx context.Context) []*User + type UserDelete struct + func (ud *UserDelete) Exec(ctx context.Context) (int, error) + func (ud *UserDelete) ExecX(ctx context.Context) int + func (ud *UserDelete) Where(ps ...predicate.User) *UserDelete + type UserDeleteOne struct + func (udo *UserDeleteOne) Exec(ctx context.Context) error + func (udo *UserDeleteOne) ExecX(ctx context.Context) + type UserEdges struct + Groups []*Group + Tenant *Tenant + func (e UserEdges) GroupsOrErr() ([]*Group, error) + func (e UserEdges) TenantOrErr() (*Tenant, error) + type UserFilter struct + func (f *UserFilter) Where(p entql.P) + func (f *UserFilter) WhereHasGroups() + func (f *UserFilter) WhereHasGroupsWith(preds ...predicate.Group) + func (f *UserFilter) WhereHasTenant() + func (f *UserFilter) WhereHasTenantWith(preds ...predicate.Tenant) + func (f *UserFilter) WhereID(p entql.IntP) + func (f *UserFilter) WhereName(p entql.StringP) + type UserGroupBy struct + 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 struct + func (m *UserMutation) AddField(name string, value ent.Value) error + func (m *UserMutation) AddGroupIDs(ids ...int) + func (m *UserMutation) AddedEdges() []string + func (m *UserMutation) AddedField(name string) (ent.Value, bool) + func (m *UserMutation) AddedFields() []string + func (m *UserMutation) AddedIDs(name string) []ent.Value + func (m *UserMutation) ClearEdge(name string) error + func (m *UserMutation) ClearField(name string) error + func (m *UserMutation) ClearGroups() + func (m *UserMutation) ClearTenant() + func (m *UserMutation) ClearedEdges() []string + func (m *UserMutation) ClearedFields() []string + 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) Filter() *UserFilter + func (m *UserMutation) GroupsCleared() bool + func (m *UserMutation) GroupsIDs() (ids []int) + func (m *UserMutation) ID() (id int, exists bool) + func (m *UserMutation) Name() (r string, exists bool) + func (m *UserMutation) OldField(ctx context.Context, name string) (ent.Value, error) + func (m *UserMutation) OldName(ctx context.Context) (v string, err error) + func (m *UserMutation) Op() Op + func (m *UserMutation) RemoveGroupIDs(ids ...int) + func (m *UserMutation) RemovedEdges() []string + func (m *UserMutation) RemovedGroupsIDs() (ids []int) + func (m *UserMutation) RemovedIDs(name string) []ent.Value + func (m *UserMutation) ResetEdge(name string) error + func (m *UserMutation) ResetField(name string) error + func (m *UserMutation) ResetGroups() + func (m *UserMutation) ResetName() + func (m *UserMutation) ResetTenant() + func (m *UserMutation) SetField(name string, value ent.Value) error + func (m *UserMutation) SetName(s string) + func (m *UserMutation) SetTenantID(id int) + func (m *UserMutation) TenantCleared() bool + func (m *UserMutation) TenantID() (id int, exists bool) + func (m *UserMutation) TenantIDs() (ids []int) + func (m *UserMutation) Type() string + func (m UserMutation) Client() *Client + func (m UserMutation) Tx() (*Tx, error) + type UserQuery struct + 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) Filter() *UserFilter + func (uq *UserQuery) First(ctx context.Context) (*User, error) + func (uq *UserQuery) FirstID(ctx context.Context) (id int, err error) + func (uq *UserQuery) FirstIDX(ctx context.Context) int + func (uq *UserQuery) FirstX(ctx context.Context) *User + func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy + func (uq *UserQuery) IDs(ctx context.Context) ([]int, error) + func (uq *UserQuery) IDsX(ctx context.Context) []int + func (uq *UserQuery) Limit(limit int) *UserQuery + func (uq *UserQuery) Offset(offset int) *UserQuery + func (uq *UserQuery) Only(ctx context.Context) (*User, error) + func (uq *UserQuery) OnlyID(ctx context.Context) (id int, err error) + func (uq *UserQuery) OnlyIDX(ctx context.Context) int + func (uq *UserQuery) OnlyX(ctx context.Context) *User + func (uq *UserQuery) Order(o ...OrderFunc) *UserQuery + func (uq *UserQuery) QueryGroups() *GroupQuery + func (uq *UserQuery) QueryTenant() *TenantQuery + func (uq *UserQuery) Select(field string, fields ...string) *UserSelect + func (uq *UserQuery) Where(ps ...predicate.User) *UserQuery + func (uq *UserQuery) WithGroups(opts ...func(*GroupQuery)) *UserQuery + func (uq *UserQuery) WithTenant(opts ...func(*TenantQuery)) *UserQuery + type UserSelect struct + 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 struct + func (uu *UserUpdate) AddGroupIDs(ids ...int) *UserUpdate + func (uu *UserUpdate) AddGroups(g ...*Group) *UserUpdate + func (uu *UserUpdate) ClearGroups() *UserUpdate + func (uu *UserUpdate) ClearTenant() *UserUpdate + func (uu *UserUpdate) Exec(ctx context.Context) error + func (uu *UserUpdate) ExecX(ctx context.Context) + func (uu *UserUpdate) Mutation() *UserMutation + func (uu *UserUpdate) RemoveGroupIDs(ids ...int) *UserUpdate + func (uu *UserUpdate) RemoveGroups(g ...*Group) *UserUpdate + func (uu *UserUpdate) Save(ctx context.Context) (int, error) + func (uu *UserUpdate) SaveX(ctx context.Context) int + func (uu *UserUpdate) SetName(s string) *UserUpdate + func (uu *UserUpdate) SetNillableName(s *string) *UserUpdate + func (uu *UserUpdate) SetTenant(t *Tenant) *UserUpdate + func (uu *UserUpdate) SetTenantID(id int) *UserUpdate + func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate + type UserUpdateOne struct + func (uuo *UserUpdateOne) AddGroupIDs(ids ...int) *UserUpdateOne + func (uuo *UserUpdateOne) AddGroups(g ...*Group) *UserUpdateOne + func (uuo *UserUpdateOne) ClearGroups() *UserUpdateOne + func (uuo *UserUpdateOne) ClearTenant() *UserUpdateOne + func (uuo *UserUpdateOne) Exec(ctx context.Context) error + func (uuo *UserUpdateOne) ExecX(ctx context.Context) + func (uuo *UserUpdateOne) Mutation() *UserMutation + func (uuo *UserUpdateOne) RemoveGroupIDs(ids ...int) *UserUpdateOne + func (uuo *UserUpdateOne) RemoveGroups(g ...*Group) *UserUpdateOne + func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error) + func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User + func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne + func (uuo *UserUpdateOne) SetNillableName(s *string) *UserUpdateOne + func (uuo *UserUpdateOne) SetTenant(t *Tenant) *UserUpdateOne + func (uuo *UserUpdateOne) SetTenantID(id int) *UserUpdateOne + type Users []*User + type ValidationError struct + Name string + func (e *ValidationError) Error() string + func (e *ValidationError) Unwrap() error + type Value = ent.Value