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 Client
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type Hook
- type Mailbox
- func (m *Mailbox) QueryAttributes() *MailboxAttrQuery
- func (m *Mailbox) QueryFlags() *MailboxFlagQuery
- func (m *Mailbox) QueryPermanentFlags() *MailboxPermFlagQuery
- func (m *Mailbox) QueryUIDs() *UIDQuery
- func (m *Mailbox) String() string
- func (m *Mailbox) Unwrap() *Mailbox
- func (m *Mailbox) Update() *MailboxUpdateOne
- type MailboxAttr
- type MailboxAttrClient
- func (c *MailboxAttrClient) Create() *MailboxAttrCreate
- func (c *MailboxAttrClient) CreateBulk(builders ...*MailboxAttrCreate) *MailboxAttrCreateBulk
- func (c *MailboxAttrClient) Delete() *MailboxAttrDelete
- func (c *MailboxAttrClient) DeleteOne(ma *MailboxAttr) *MailboxAttrDeleteOne
- func (c *MailboxAttrClient) DeleteOneID(id int) *MailboxAttrDeleteOne
- func (c *MailboxAttrClient) Get(ctx context.Context, id int) (*MailboxAttr, error)
- func (c *MailboxAttrClient) GetX(ctx context.Context, id int) *MailboxAttr
- func (c *MailboxAttrClient) Hooks() []Hook
- func (c *MailboxAttrClient) Query() *MailboxAttrQuery
- func (c *MailboxAttrClient) Update() *MailboxAttrUpdate
- func (c *MailboxAttrClient) UpdateOne(ma *MailboxAttr) *MailboxAttrUpdateOne
- func (c *MailboxAttrClient) UpdateOneID(id int) *MailboxAttrUpdateOne
- func (c *MailboxAttrClient) Use(hooks ...Hook)
- type MailboxAttrCreate
- func (mac *MailboxAttrCreate) Exec(ctx context.Context) error
- func (mac *MailboxAttrCreate) ExecX(ctx context.Context)
- func (mac *MailboxAttrCreate) Mutation() *MailboxAttrMutation
- func (mac *MailboxAttrCreate) Save(ctx context.Context) (*MailboxAttr, error)
- func (mac *MailboxAttrCreate) SaveX(ctx context.Context) *MailboxAttr
- func (mac *MailboxAttrCreate) SetValue(s string) *MailboxAttrCreate
- type MailboxAttrCreateBulk
- type MailboxAttrDelete
- type MailboxAttrDeleteOne
- type MailboxAttrGroupBy
- func (magb *MailboxAttrGroupBy) Aggregate(fns ...AggregateFunc) *MailboxAttrGroupBy
- func (magb *MailboxAttrGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (magb *MailboxAttrGroupBy) BoolX(ctx context.Context) bool
- func (magb *MailboxAttrGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (magb *MailboxAttrGroupBy) BoolsX(ctx context.Context) []bool
- func (magb *MailboxAttrGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (magb *MailboxAttrGroupBy) Float64X(ctx context.Context) float64
- func (magb *MailboxAttrGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (magb *MailboxAttrGroupBy) Float64sX(ctx context.Context) []float64
- func (magb *MailboxAttrGroupBy) Int(ctx context.Context) (_ int, err error)
- func (magb *MailboxAttrGroupBy) IntX(ctx context.Context) int
- func (magb *MailboxAttrGroupBy) Ints(ctx context.Context) ([]int, error)
- func (magb *MailboxAttrGroupBy) IntsX(ctx context.Context) []int
- func (magb *MailboxAttrGroupBy) Scan(ctx context.Context, v interface{}) error
- func (magb *MailboxAttrGroupBy) ScanX(ctx context.Context, v interface{})
- func (magb *MailboxAttrGroupBy) String(ctx context.Context) (_ string, err error)
- func (magb *MailboxAttrGroupBy) StringX(ctx context.Context) string
- func (magb *MailboxAttrGroupBy) Strings(ctx context.Context) ([]string, error)
- func (magb *MailboxAttrGroupBy) StringsX(ctx context.Context) []string
- type MailboxAttrMutation
- func (m *MailboxAttrMutation) AddField(name string, value ent.Value) error
- func (m *MailboxAttrMutation) AddedEdges() []string
- func (m *MailboxAttrMutation) AddedField(name string) (ent.Value, bool)
- func (m *MailboxAttrMutation) AddedFields() []string
- func (m *MailboxAttrMutation) AddedIDs(name string) []ent.Value
- func (m *MailboxAttrMutation) ClearEdge(name string) error
- func (m *MailboxAttrMutation) ClearField(name string) error
- func (m *MailboxAttrMutation) ClearedEdges() []string
- func (m *MailboxAttrMutation) ClearedFields() []string
- func (m MailboxAttrMutation) Client() *Client
- func (m *MailboxAttrMutation) EdgeCleared(name string) bool
- func (m *MailboxAttrMutation) Field(name string) (ent.Value, bool)
- func (m *MailboxAttrMutation) FieldCleared(name string) bool
- func (m *MailboxAttrMutation) Fields() []string
- func (m *MailboxAttrMutation) ID() (id int, exists bool)
- func (m *MailboxAttrMutation) IDs(ctx context.Context) ([]int, error)
- func (m *MailboxAttrMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MailboxAttrMutation) OldValue(ctx context.Context) (v string, err error)
- func (m *MailboxAttrMutation) Op() Op
- func (m *MailboxAttrMutation) RemovedEdges() []string
- func (m *MailboxAttrMutation) RemovedIDs(name string) []ent.Value
- func (m *MailboxAttrMutation) ResetEdge(name string) error
- func (m *MailboxAttrMutation) ResetField(name string) error
- func (m *MailboxAttrMutation) ResetValue()
- func (m *MailboxAttrMutation) SetField(name string, value ent.Value) error
- func (m *MailboxAttrMutation) SetValue(s string)
- func (m MailboxAttrMutation) Tx() (*Tx, error)
- func (m *MailboxAttrMutation) Type() string
- func (m *MailboxAttrMutation) Value() (r string, exists bool)
- func (m *MailboxAttrMutation) Where(ps ...predicate.MailboxAttr)
- type MailboxAttrQuery
- func (maq *MailboxAttrQuery) All(ctx context.Context) ([]*MailboxAttr, error)
- func (maq *MailboxAttrQuery) AllX(ctx context.Context) []*MailboxAttr
- func (maq *MailboxAttrQuery) Clone() *MailboxAttrQuery
- func (maq *MailboxAttrQuery) Count(ctx context.Context) (int, error)
- func (maq *MailboxAttrQuery) CountX(ctx context.Context) int
- func (maq *MailboxAttrQuery) Exist(ctx context.Context) (bool, error)
- func (maq *MailboxAttrQuery) ExistX(ctx context.Context) bool
- func (maq *MailboxAttrQuery) First(ctx context.Context) (*MailboxAttr, error)
- func (maq *MailboxAttrQuery) FirstID(ctx context.Context) (id int, err error)
- func (maq *MailboxAttrQuery) FirstIDX(ctx context.Context) int
- func (maq *MailboxAttrQuery) FirstX(ctx context.Context) *MailboxAttr
- func (maq *MailboxAttrQuery) GroupBy(field string, fields ...string) *MailboxAttrGroupBy
- func (maq *MailboxAttrQuery) IDs(ctx context.Context) ([]int, error)
- func (maq *MailboxAttrQuery) IDsX(ctx context.Context) []int
- func (maq *MailboxAttrQuery) Limit(limit int) *MailboxAttrQuery
- func (maq *MailboxAttrQuery) Offset(offset int) *MailboxAttrQuery
- func (maq *MailboxAttrQuery) Only(ctx context.Context) (*MailboxAttr, error)
- func (maq *MailboxAttrQuery) OnlyID(ctx context.Context) (id int, err error)
- func (maq *MailboxAttrQuery) OnlyIDX(ctx context.Context) int
- func (maq *MailboxAttrQuery) OnlyX(ctx context.Context) *MailboxAttr
- func (maq *MailboxAttrQuery) Order(o ...OrderFunc) *MailboxAttrQuery
- func (maq *MailboxAttrQuery) Select(fields ...string) *MailboxAttrSelect
- func (maq *MailboxAttrQuery) Unique(unique bool) *MailboxAttrQuery
- func (maq *MailboxAttrQuery) Where(ps ...predicate.MailboxAttr) *MailboxAttrQuery
- type MailboxAttrSelect
- func (mas *MailboxAttrSelect) Bool(ctx context.Context) (_ bool, err error)
- func (mas *MailboxAttrSelect) BoolX(ctx context.Context) bool
- func (mas *MailboxAttrSelect) Bools(ctx context.Context) ([]bool, error)
- func (mas *MailboxAttrSelect) BoolsX(ctx context.Context) []bool
- func (mas *MailboxAttrSelect) Float64(ctx context.Context) (_ float64, err error)
- func (mas *MailboxAttrSelect) Float64X(ctx context.Context) float64
- func (mas *MailboxAttrSelect) Float64s(ctx context.Context) ([]float64, error)
- func (mas *MailboxAttrSelect) Float64sX(ctx context.Context) []float64
- func (mas *MailboxAttrSelect) Int(ctx context.Context) (_ int, err error)
- func (mas *MailboxAttrSelect) IntX(ctx context.Context) int
- func (mas *MailboxAttrSelect) Ints(ctx context.Context) ([]int, error)
- func (mas *MailboxAttrSelect) IntsX(ctx context.Context) []int
- func (mas *MailboxAttrSelect) Scan(ctx context.Context, v interface{}) error
- func (mas *MailboxAttrSelect) ScanX(ctx context.Context, v interface{})
- func (mas *MailboxAttrSelect) String(ctx context.Context) (_ string, err error)
- func (mas *MailboxAttrSelect) StringX(ctx context.Context) string
- func (mas *MailboxAttrSelect) Strings(ctx context.Context) ([]string, error)
- func (mas *MailboxAttrSelect) StringsX(ctx context.Context) []string
- type MailboxAttrUpdate
- func (mau *MailboxAttrUpdate) Exec(ctx context.Context) error
- func (mau *MailboxAttrUpdate) ExecX(ctx context.Context)
- func (mau *MailboxAttrUpdate) Mutation() *MailboxAttrMutation
- func (mau *MailboxAttrUpdate) Save(ctx context.Context) (int, error)
- func (mau *MailboxAttrUpdate) SaveX(ctx context.Context) int
- func (mau *MailboxAttrUpdate) SetValue(s string) *MailboxAttrUpdate
- func (mau *MailboxAttrUpdate) Where(ps ...predicate.MailboxAttr) *MailboxAttrUpdate
- type MailboxAttrUpdateOne
- func (mauo *MailboxAttrUpdateOne) Exec(ctx context.Context) error
- func (mauo *MailboxAttrUpdateOne) ExecX(ctx context.Context)
- func (mauo *MailboxAttrUpdateOne) Mutation() *MailboxAttrMutation
- func (mauo *MailboxAttrUpdateOne) Save(ctx context.Context) (*MailboxAttr, error)
- func (mauo *MailboxAttrUpdateOne) SaveX(ctx context.Context) *MailboxAttr
- func (mauo *MailboxAttrUpdateOne) Select(field string, fields ...string) *MailboxAttrUpdateOne
- func (mauo *MailboxAttrUpdateOne) SetValue(s string) *MailboxAttrUpdateOne
- type MailboxAttrs
- type MailboxClient
- func (c *MailboxClient) Create() *MailboxCreate
- func (c *MailboxClient) CreateBulk(builders ...*MailboxCreate) *MailboxCreateBulk
- func (c *MailboxClient) Delete() *MailboxDelete
- func (c *MailboxClient) DeleteOne(m *Mailbox) *MailboxDeleteOne
- func (c *MailboxClient) DeleteOneID(id int) *MailboxDeleteOne
- func (c *MailboxClient) Get(ctx context.Context, id int) (*Mailbox, error)
- func (c *MailboxClient) GetX(ctx context.Context, id int) *Mailbox
- func (c *MailboxClient) Hooks() []Hook
- func (c *MailboxClient) Query() *MailboxQuery
- func (c *MailboxClient) QueryAttributes(m *Mailbox) *MailboxAttrQuery
- func (c *MailboxClient) QueryFlags(m *Mailbox) *MailboxFlagQuery
- func (c *MailboxClient) QueryPermanentFlags(m *Mailbox) *MailboxPermFlagQuery
- func (c *MailboxClient) QueryUIDs(m *Mailbox) *UIDQuery
- func (c *MailboxClient) Update() *MailboxUpdate
- func (c *MailboxClient) UpdateOne(m *Mailbox) *MailboxUpdateOne
- func (c *MailboxClient) UpdateOneID(id int) *MailboxUpdateOne
- func (c *MailboxClient) Use(hooks ...Hook)
- type MailboxCreate
- func (mc *MailboxCreate) AddAttributeIDs(ids ...int) *MailboxCreate
- func (mc *MailboxCreate) AddAttributes(m ...*MailboxAttr) *MailboxCreate
- func (mc *MailboxCreate) AddFlagIDs(ids ...int) *MailboxCreate
- func (mc *MailboxCreate) AddFlags(m ...*MailboxFlag) *MailboxCreate
- func (mc *MailboxCreate) AddPermanentFlagIDs(ids ...int) *MailboxCreate
- func (mc *MailboxCreate) AddPermanentFlags(m ...*MailboxPermFlag) *MailboxCreate
- func (mc *MailboxCreate) AddUIDIDs(ids ...int) *MailboxCreate
- func (mc *MailboxCreate) AddUIDs(u ...*UID) *MailboxCreate
- func (mc *MailboxCreate) Exec(ctx context.Context) error
- func (mc *MailboxCreate) ExecX(ctx context.Context)
- func (mc *MailboxCreate) Mutation() *MailboxMutation
- func (mc *MailboxCreate) Save(ctx context.Context) (*Mailbox, error)
- func (mc *MailboxCreate) SaveX(ctx context.Context) *Mailbox
- func (mc *MailboxCreate) SetMailboxID(s string) *MailboxCreate
- func (mc *MailboxCreate) SetName(s string) *MailboxCreate
- func (mc *MailboxCreate) SetNillableSubscribed(b *bool) *MailboxCreate
- func (mc *MailboxCreate) SetNillableUIDNext(i *int) *MailboxCreate
- func (mc *MailboxCreate) SetNillableUIDValidity(i *int) *MailboxCreate
- func (mc *MailboxCreate) SetSubscribed(b bool) *MailboxCreate
- func (mc *MailboxCreate) SetUIDNext(i int) *MailboxCreate
- func (mc *MailboxCreate) SetUIDValidity(i int) *MailboxCreate
- type MailboxCreateBulk
- type MailboxDelete
- type MailboxDeleteOne
- type MailboxEdges
- type MailboxFlag
- type MailboxFlagClient
- func (c *MailboxFlagClient) Create() *MailboxFlagCreate
- func (c *MailboxFlagClient) CreateBulk(builders ...*MailboxFlagCreate) *MailboxFlagCreateBulk
- func (c *MailboxFlagClient) Delete() *MailboxFlagDelete
- func (c *MailboxFlagClient) DeleteOne(mf *MailboxFlag) *MailboxFlagDeleteOne
- func (c *MailboxFlagClient) DeleteOneID(id int) *MailboxFlagDeleteOne
- func (c *MailboxFlagClient) Get(ctx context.Context, id int) (*MailboxFlag, error)
- func (c *MailboxFlagClient) GetX(ctx context.Context, id int) *MailboxFlag
- func (c *MailboxFlagClient) Hooks() []Hook
- func (c *MailboxFlagClient) Query() *MailboxFlagQuery
- func (c *MailboxFlagClient) Update() *MailboxFlagUpdate
- func (c *MailboxFlagClient) UpdateOne(mf *MailboxFlag) *MailboxFlagUpdateOne
- func (c *MailboxFlagClient) UpdateOneID(id int) *MailboxFlagUpdateOne
- func (c *MailboxFlagClient) Use(hooks ...Hook)
- type MailboxFlagCreate
- func (mfc *MailboxFlagCreate) Exec(ctx context.Context) error
- func (mfc *MailboxFlagCreate) ExecX(ctx context.Context)
- func (mfc *MailboxFlagCreate) Mutation() *MailboxFlagMutation
- func (mfc *MailboxFlagCreate) Save(ctx context.Context) (*MailboxFlag, error)
- func (mfc *MailboxFlagCreate) SaveX(ctx context.Context) *MailboxFlag
- func (mfc *MailboxFlagCreate) SetValue(s string) *MailboxFlagCreate
- type MailboxFlagCreateBulk
- type MailboxFlagDelete
- type MailboxFlagDeleteOne
- type MailboxFlagGroupBy
- func (mfgb *MailboxFlagGroupBy) Aggregate(fns ...AggregateFunc) *MailboxFlagGroupBy
- func (mfgb *MailboxFlagGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (mfgb *MailboxFlagGroupBy) BoolX(ctx context.Context) bool
- func (mfgb *MailboxFlagGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (mfgb *MailboxFlagGroupBy) BoolsX(ctx context.Context) []bool
- func (mfgb *MailboxFlagGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (mfgb *MailboxFlagGroupBy) Float64X(ctx context.Context) float64
- func (mfgb *MailboxFlagGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (mfgb *MailboxFlagGroupBy) Float64sX(ctx context.Context) []float64
- func (mfgb *MailboxFlagGroupBy) Int(ctx context.Context) (_ int, err error)
- func (mfgb *MailboxFlagGroupBy) IntX(ctx context.Context) int
- func (mfgb *MailboxFlagGroupBy) Ints(ctx context.Context) ([]int, error)
- func (mfgb *MailboxFlagGroupBy) IntsX(ctx context.Context) []int
- func (mfgb *MailboxFlagGroupBy) Scan(ctx context.Context, v interface{}) error
- func (mfgb *MailboxFlagGroupBy) ScanX(ctx context.Context, v interface{})
- func (mfgb *MailboxFlagGroupBy) String(ctx context.Context) (_ string, err error)
- func (mfgb *MailboxFlagGroupBy) StringX(ctx context.Context) string
- func (mfgb *MailboxFlagGroupBy) Strings(ctx context.Context) ([]string, error)
- func (mfgb *MailboxFlagGroupBy) StringsX(ctx context.Context) []string
- type MailboxFlagMutation
- func (m *MailboxFlagMutation) AddField(name string, value ent.Value) error
- func (m *MailboxFlagMutation) AddedEdges() []string
- func (m *MailboxFlagMutation) AddedField(name string) (ent.Value, bool)
- func (m *MailboxFlagMutation) AddedFields() []string
- func (m *MailboxFlagMutation) AddedIDs(name string) []ent.Value
- func (m *MailboxFlagMutation) ClearEdge(name string) error
- func (m *MailboxFlagMutation) ClearField(name string) error
- func (m *MailboxFlagMutation) ClearedEdges() []string
- func (m *MailboxFlagMutation) ClearedFields() []string
- func (m MailboxFlagMutation) Client() *Client
- func (m *MailboxFlagMutation) EdgeCleared(name string) bool
- func (m *MailboxFlagMutation) Field(name string) (ent.Value, bool)
- func (m *MailboxFlagMutation) FieldCleared(name string) bool
- func (m *MailboxFlagMutation) Fields() []string
- func (m *MailboxFlagMutation) ID() (id int, exists bool)
- func (m *MailboxFlagMutation) IDs(ctx context.Context) ([]int, error)
- func (m *MailboxFlagMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MailboxFlagMutation) OldValue(ctx context.Context) (v string, err error)
- func (m *MailboxFlagMutation) Op() Op
- func (m *MailboxFlagMutation) RemovedEdges() []string
- func (m *MailboxFlagMutation) RemovedIDs(name string) []ent.Value
- func (m *MailboxFlagMutation) ResetEdge(name string) error
- func (m *MailboxFlagMutation) ResetField(name string) error
- func (m *MailboxFlagMutation) ResetValue()
- func (m *MailboxFlagMutation) SetField(name string, value ent.Value) error
- func (m *MailboxFlagMutation) SetValue(s string)
- func (m MailboxFlagMutation) Tx() (*Tx, error)
- func (m *MailboxFlagMutation) Type() string
- func (m *MailboxFlagMutation) Value() (r string, exists bool)
- func (m *MailboxFlagMutation) Where(ps ...predicate.MailboxFlag)
- type MailboxFlagQuery
- func (mfq *MailboxFlagQuery) All(ctx context.Context) ([]*MailboxFlag, error)
- func (mfq *MailboxFlagQuery) AllX(ctx context.Context) []*MailboxFlag
- func (mfq *MailboxFlagQuery) Clone() *MailboxFlagQuery
- func (mfq *MailboxFlagQuery) Count(ctx context.Context) (int, error)
- func (mfq *MailboxFlagQuery) CountX(ctx context.Context) int
- func (mfq *MailboxFlagQuery) Exist(ctx context.Context) (bool, error)
- func (mfq *MailboxFlagQuery) ExistX(ctx context.Context) bool
- func (mfq *MailboxFlagQuery) First(ctx context.Context) (*MailboxFlag, error)
- func (mfq *MailboxFlagQuery) FirstID(ctx context.Context) (id int, err error)
- func (mfq *MailboxFlagQuery) FirstIDX(ctx context.Context) int
- func (mfq *MailboxFlagQuery) FirstX(ctx context.Context) *MailboxFlag
- func (mfq *MailboxFlagQuery) GroupBy(field string, fields ...string) *MailboxFlagGroupBy
- func (mfq *MailboxFlagQuery) IDs(ctx context.Context) ([]int, error)
- func (mfq *MailboxFlagQuery) IDsX(ctx context.Context) []int
- func (mfq *MailboxFlagQuery) Limit(limit int) *MailboxFlagQuery
- func (mfq *MailboxFlagQuery) Offset(offset int) *MailboxFlagQuery
- func (mfq *MailboxFlagQuery) Only(ctx context.Context) (*MailboxFlag, error)
- func (mfq *MailboxFlagQuery) OnlyID(ctx context.Context) (id int, err error)
- func (mfq *MailboxFlagQuery) OnlyIDX(ctx context.Context) int
- func (mfq *MailboxFlagQuery) OnlyX(ctx context.Context) *MailboxFlag
- func (mfq *MailboxFlagQuery) Order(o ...OrderFunc) *MailboxFlagQuery
- func (mfq *MailboxFlagQuery) Select(fields ...string) *MailboxFlagSelect
- func (mfq *MailboxFlagQuery) Unique(unique bool) *MailboxFlagQuery
- func (mfq *MailboxFlagQuery) Where(ps ...predicate.MailboxFlag) *MailboxFlagQuery
- type MailboxFlagSelect
- func (mfs *MailboxFlagSelect) Bool(ctx context.Context) (_ bool, err error)
- func (mfs *MailboxFlagSelect) BoolX(ctx context.Context) bool
- func (mfs *MailboxFlagSelect) Bools(ctx context.Context) ([]bool, error)
- func (mfs *MailboxFlagSelect) BoolsX(ctx context.Context) []bool
- func (mfs *MailboxFlagSelect) Float64(ctx context.Context) (_ float64, err error)
- func (mfs *MailboxFlagSelect) Float64X(ctx context.Context) float64
- func (mfs *MailboxFlagSelect) Float64s(ctx context.Context) ([]float64, error)
- func (mfs *MailboxFlagSelect) Float64sX(ctx context.Context) []float64
- func (mfs *MailboxFlagSelect) Int(ctx context.Context) (_ int, err error)
- func (mfs *MailboxFlagSelect) IntX(ctx context.Context) int
- func (mfs *MailboxFlagSelect) Ints(ctx context.Context) ([]int, error)
- func (mfs *MailboxFlagSelect) IntsX(ctx context.Context) []int
- func (mfs *MailboxFlagSelect) Scan(ctx context.Context, v interface{}) error
- func (mfs *MailboxFlagSelect) ScanX(ctx context.Context, v interface{})
- func (mfs *MailboxFlagSelect) String(ctx context.Context) (_ string, err error)
- func (mfs *MailboxFlagSelect) StringX(ctx context.Context) string
- func (mfs *MailboxFlagSelect) Strings(ctx context.Context) ([]string, error)
- func (mfs *MailboxFlagSelect) StringsX(ctx context.Context) []string
- type MailboxFlagUpdate
- func (mfu *MailboxFlagUpdate) Exec(ctx context.Context) error
- func (mfu *MailboxFlagUpdate) ExecX(ctx context.Context)
- func (mfu *MailboxFlagUpdate) Mutation() *MailboxFlagMutation
- func (mfu *MailboxFlagUpdate) Save(ctx context.Context) (int, error)
- func (mfu *MailboxFlagUpdate) SaveX(ctx context.Context) int
- func (mfu *MailboxFlagUpdate) SetValue(s string) *MailboxFlagUpdate
- func (mfu *MailboxFlagUpdate) Where(ps ...predicate.MailboxFlag) *MailboxFlagUpdate
- type MailboxFlagUpdateOne
- func (mfuo *MailboxFlagUpdateOne) Exec(ctx context.Context) error
- func (mfuo *MailboxFlagUpdateOne) ExecX(ctx context.Context)
- func (mfuo *MailboxFlagUpdateOne) Mutation() *MailboxFlagMutation
- func (mfuo *MailboxFlagUpdateOne) Save(ctx context.Context) (*MailboxFlag, error)
- func (mfuo *MailboxFlagUpdateOne) SaveX(ctx context.Context) *MailboxFlag
- func (mfuo *MailboxFlagUpdateOne) Select(field string, fields ...string) *MailboxFlagUpdateOne
- func (mfuo *MailboxFlagUpdateOne) SetValue(s string) *MailboxFlagUpdateOne
- type MailboxFlags
- type MailboxGroupBy
- func (mgb *MailboxGroupBy) Aggregate(fns ...AggregateFunc) *MailboxGroupBy
- func (mgb *MailboxGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (mgb *MailboxGroupBy) BoolX(ctx context.Context) bool
- func (mgb *MailboxGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (mgb *MailboxGroupBy) BoolsX(ctx context.Context) []bool
- func (mgb *MailboxGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (mgb *MailboxGroupBy) Float64X(ctx context.Context) float64
- func (mgb *MailboxGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (mgb *MailboxGroupBy) Float64sX(ctx context.Context) []float64
- func (mgb *MailboxGroupBy) Int(ctx context.Context) (_ int, err error)
- func (mgb *MailboxGroupBy) IntX(ctx context.Context) int
- func (mgb *MailboxGroupBy) Ints(ctx context.Context) ([]int, error)
- func (mgb *MailboxGroupBy) IntsX(ctx context.Context) []int
- func (mgb *MailboxGroupBy) Scan(ctx context.Context, v interface{}) error
- func (mgb *MailboxGroupBy) ScanX(ctx context.Context, v interface{})
- func (mgb *MailboxGroupBy) String(ctx context.Context) (_ string, err error)
- func (mgb *MailboxGroupBy) StringX(ctx context.Context) string
- func (mgb *MailboxGroupBy) Strings(ctx context.Context) ([]string, error)
- func (mgb *MailboxGroupBy) StringsX(ctx context.Context) []string
- type MailboxMutation
- func (m *MailboxMutation) AddAttributeIDs(ids ...int)
- func (m *MailboxMutation) AddField(name string, value ent.Value) error
- func (m *MailboxMutation) AddFlagIDs(ids ...int)
- func (m *MailboxMutation) AddPermanentFlagIDs(ids ...int)
- func (m *MailboxMutation) AddUIDIDs(ids ...int)
- func (m *MailboxMutation) AddUIDNext(i int)
- func (m *MailboxMutation) AddUIDValidity(i int)
- func (m *MailboxMutation) AddedEdges() []string
- func (m *MailboxMutation) AddedField(name string) (ent.Value, bool)
- func (m *MailboxMutation) AddedFields() []string
- func (m *MailboxMutation) AddedIDs(name string) []ent.Value
- func (m *MailboxMutation) AddedUIDNext() (r int, exists bool)
- func (m *MailboxMutation) AddedUIDValidity() (r int, exists bool)
- func (m *MailboxMutation) AttributesCleared() bool
- func (m *MailboxMutation) AttributesIDs() (ids []int)
- func (m *MailboxMutation) ClearAttributes()
- func (m *MailboxMutation) ClearEdge(name string) error
- func (m *MailboxMutation) ClearField(name string) error
- func (m *MailboxMutation) ClearFlags()
- func (m *MailboxMutation) ClearPermanentFlags()
- func (m *MailboxMutation) ClearUIDs()
- func (m *MailboxMutation) ClearedEdges() []string
- func (m *MailboxMutation) ClearedFields() []string
- func (m MailboxMutation) Client() *Client
- func (m *MailboxMutation) EdgeCleared(name string) bool
- func (m *MailboxMutation) Field(name string) (ent.Value, bool)
- func (m *MailboxMutation) FieldCleared(name string) bool
- func (m *MailboxMutation) Fields() []string
- func (m *MailboxMutation) FlagsCleared() bool
- func (m *MailboxMutation) FlagsIDs() (ids []int)
- func (m *MailboxMutation) ID() (id int, exists bool)
- func (m *MailboxMutation) IDs(ctx context.Context) ([]int, error)
- func (m *MailboxMutation) MailboxID() (r string, exists bool)
- func (m *MailboxMutation) Name() (r string, exists bool)
- func (m *MailboxMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MailboxMutation) OldMailboxID(ctx context.Context) (v string, err error)
- func (m *MailboxMutation) OldName(ctx context.Context) (v string, err error)
- func (m *MailboxMutation) OldSubscribed(ctx context.Context) (v bool, err error)
- func (m *MailboxMutation) OldUIDNext(ctx context.Context) (v int, err error)
- func (m *MailboxMutation) OldUIDValidity(ctx context.Context) (v int, err error)
- func (m *MailboxMutation) Op() Op
- func (m *MailboxMutation) PermanentFlagsCleared() bool
- func (m *MailboxMutation) PermanentFlagsIDs() (ids []int)
- func (m *MailboxMutation) RemoveAttributeIDs(ids ...int)
- func (m *MailboxMutation) RemoveFlagIDs(ids ...int)
- func (m *MailboxMutation) RemovePermanentFlagIDs(ids ...int)
- func (m *MailboxMutation) RemoveUIDIDs(ids ...int)
- func (m *MailboxMutation) RemovedAttributesIDs() (ids []int)
- func (m *MailboxMutation) RemovedEdges() []string
- func (m *MailboxMutation) RemovedFlagsIDs() (ids []int)
- func (m *MailboxMutation) RemovedIDs(name string) []ent.Value
- func (m *MailboxMutation) RemovedPermanentFlagsIDs() (ids []int)
- func (m *MailboxMutation) RemovedUIDsIDs() (ids []int)
- func (m *MailboxMutation) ResetAttributes()
- func (m *MailboxMutation) ResetEdge(name string) error
- func (m *MailboxMutation) ResetField(name string) error
- func (m *MailboxMutation) ResetFlags()
- func (m *MailboxMutation) ResetMailboxID()
- func (m *MailboxMutation) ResetName()
- func (m *MailboxMutation) ResetPermanentFlags()
- func (m *MailboxMutation) ResetSubscribed()
- func (m *MailboxMutation) ResetUIDNext()
- func (m *MailboxMutation) ResetUIDValidity()
- func (m *MailboxMutation) ResetUIDs()
- func (m *MailboxMutation) SetField(name string, value ent.Value) error
- func (m *MailboxMutation) SetMailboxID(s string)
- func (m *MailboxMutation) SetName(s string)
- func (m *MailboxMutation) SetSubscribed(b bool)
- func (m *MailboxMutation) SetUIDNext(i int)
- func (m *MailboxMutation) SetUIDValidity(i int)
- func (m *MailboxMutation) Subscribed() (r bool, exists bool)
- func (m MailboxMutation) Tx() (*Tx, error)
- func (m *MailboxMutation) Type() string
- func (m *MailboxMutation) UIDNext() (r int, exists bool)
- func (m *MailboxMutation) UIDValidity() (r int, exists bool)
- func (m *MailboxMutation) UIDsCleared() bool
- func (m *MailboxMutation) UIDsIDs() (ids []int)
- func (m *MailboxMutation) Where(ps ...predicate.Mailbox)
- type MailboxPermFlag
- type MailboxPermFlagClient
- func (c *MailboxPermFlagClient) Create() *MailboxPermFlagCreate
- func (c *MailboxPermFlagClient) CreateBulk(builders ...*MailboxPermFlagCreate) *MailboxPermFlagCreateBulk
- func (c *MailboxPermFlagClient) Delete() *MailboxPermFlagDelete
- func (c *MailboxPermFlagClient) DeleteOne(mpf *MailboxPermFlag) *MailboxPermFlagDeleteOne
- func (c *MailboxPermFlagClient) DeleteOneID(id int) *MailboxPermFlagDeleteOne
- func (c *MailboxPermFlagClient) Get(ctx context.Context, id int) (*MailboxPermFlag, error)
- func (c *MailboxPermFlagClient) GetX(ctx context.Context, id int) *MailboxPermFlag
- func (c *MailboxPermFlagClient) Hooks() []Hook
- func (c *MailboxPermFlagClient) Query() *MailboxPermFlagQuery
- func (c *MailboxPermFlagClient) Update() *MailboxPermFlagUpdate
- func (c *MailboxPermFlagClient) UpdateOne(mpf *MailboxPermFlag) *MailboxPermFlagUpdateOne
- func (c *MailboxPermFlagClient) UpdateOneID(id int) *MailboxPermFlagUpdateOne
- func (c *MailboxPermFlagClient) Use(hooks ...Hook)
- type MailboxPermFlagCreate
- func (mpfc *MailboxPermFlagCreate) Exec(ctx context.Context) error
- func (mpfc *MailboxPermFlagCreate) ExecX(ctx context.Context)
- func (mpfc *MailboxPermFlagCreate) Mutation() *MailboxPermFlagMutation
- func (mpfc *MailboxPermFlagCreate) Save(ctx context.Context) (*MailboxPermFlag, error)
- func (mpfc *MailboxPermFlagCreate) SaveX(ctx context.Context) *MailboxPermFlag
- func (mpfc *MailboxPermFlagCreate) SetValue(s string) *MailboxPermFlagCreate
- type MailboxPermFlagCreateBulk
- func (mpfcb *MailboxPermFlagCreateBulk) Exec(ctx context.Context) error
- func (mpfcb *MailboxPermFlagCreateBulk) ExecX(ctx context.Context)
- func (mpfcb *MailboxPermFlagCreateBulk) Save(ctx context.Context) ([]*MailboxPermFlag, error)
- func (mpfcb *MailboxPermFlagCreateBulk) SaveX(ctx context.Context) []*MailboxPermFlag
- type MailboxPermFlagDelete
- type MailboxPermFlagDeleteOne
- type MailboxPermFlagGroupBy
- func (mpfgb *MailboxPermFlagGroupBy) Aggregate(fns ...AggregateFunc) *MailboxPermFlagGroupBy
- func (mpfgb *MailboxPermFlagGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (mpfgb *MailboxPermFlagGroupBy) BoolX(ctx context.Context) bool
- func (mpfgb *MailboxPermFlagGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (mpfgb *MailboxPermFlagGroupBy) BoolsX(ctx context.Context) []bool
- func (mpfgb *MailboxPermFlagGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (mpfgb *MailboxPermFlagGroupBy) Float64X(ctx context.Context) float64
- func (mpfgb *MailboxPermFlagGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (mpfgb *MailboxPermFlagGroupBy) Float64sX(ctx context.Context) []float64
- func (mpfgb *MailboxPermFlagGroupBy) Int(ctx context.Context) (_ int, err error)
- func (mpfgb *MailboxPermFlagGroupBy) IntX(ctx context.Context) int
- func (mpfgb *MailboxPermFlagGroupBy) Ints(ctx context.Context) ([]int, error)
- func (mpfgb *MailboxPermFlagGroupBy) IntsX(ctx context.Context) []int
- func (mpfgb *MailboxPermFlagGroupBy) Scan(ctx context.Context, v interface{}) error
- func (mpfgb *MailboxPermFlagGroupBy) ScanX(ctx context.Context, v interface{})
- func (mpfgb *MailboxPermFlagGroupBy) String(ctx context.Context) (_ string, err error)
- func (mpfgb *MailboxPermFlagGroupBy) StringX(ctx context.Context) string
- func (mpfgb *MailboxPermFlagGroupBy) Strings(ctx context.Context) ([]string, error)
- func (mpfgb *MailboxPermFlagGroupBy) StringsX(ctx context.Context) []string
- type MailboxPermFlagMutation
- func (m *MailboxPermFlagMutation) AddField(name string, value ent.Value) error
- func (m *MailboxPermFlagMutation) AddedEdges() []string
- func (m *MailboxPermFlagMutation) AddedField(name string) (ent.Value, bool)
- func (m *MailboxPermFlagMutation) AddedFields() []string
- func (m *MailboxPermFlagMutation) AddedIDs(name string) []ent.Value
- func (m *MailboxPermFlagMutation) ClearEdge(name string) error
- func (m *MailboxPermFlagMutation) ClearField(name string) error
- func (m *MailboxPermFlagMutation) ClearedEdges() []string
- func (m *MailboxPermFlagMutation) ClearedFields() []string
- func (m MailboxPermFlagMutation) Client() *Client
- func (m *MailboxPermFlagMutation) EdgeCleared(name string) bool
- func (m *MailboxPermFlagMutation) Field(name string) (ent.Value, bool)
- func (m *MailboxPermFlagMutation) FieldCleared(name string) bool
- func (m *MailboxPermFlagMutation) Fields() []string
- func (m *MailboxPermFlagMutation) ID() (id int, exists bool)
- func (m *MailboxPermFlagMutation) IDs(ctx context.Context) ([]int, error)
- func (m *MailboxPermFlagMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MailboxPermFlagMutation) OldValue(ctx context.Context) (v string, err error)
- func (m *MailboxPermFlagMutation) Op() Op
- func (m *MailboxPermFlagMutation) RemovedEdges() []string
- func (m *MailboxPermFlagMutation) RemovedIDs(name string) []ent.Value
- func (m *MailboxPermFlagMutation) ResetEdge(name string) error
- func (m *MailboxPermFlagMutation) ResetField(name string) error
- func (m *MailboxPermFlagMutation) ResetValue()
- func (m *MailboxPermFlagMutation) SetField(name string, value ent.Value) error
- func (m *MailboxPermFlagMutation) SetValue(s string)
- func (m MailboxPermFlagMutation) Tx() (*Tx, error)
- func (m *MailboxPermFlagMutation) Type() string
- func (m *MailboxPermFlagMutation) Value() (r string, exists bool)
- func (m *MailboxPermFlagMutation) Where(ps ...predicate.MailboxPermFlag)
- type MailboxPermFlagQuery
- func (mpfq *MailboxPermFlagQuery) All(ctx context.Context) ([]*MailboxPermFlag, error)
- func (mpfq *MailboxPermFlagQuery) AllX(ctx context.Context) []*MailboxPermFlag
- func (mpfq *MailboxPermFlagQuery) Clone() *MailboxPermFlagQuery
- func (mpfq *MailboxPermFlagQuery) Count(ctx context.Context) (int, error)
- func (mpfq *MailboxPermFlagQuery) CountX(ctx context.Context) int
- func (mpfq *MailboxPermFlagQuery) Exist(ctx context.Context) (bool, error)
- func (mpfq *MailboxPermFlagQuery) ExistX(ctx context.Context) bool
- func (mpfq *MailboxPermFlagQuery) First(ctx context.Context) (*MailboxPermFlag, error)
- func (mpfq *MailboxPermFlagQuery) FirstID(ctx context.Context) (id int, err error)
- func (mpfq *MailboxPermFlagQuery) FirstIDX(ctx context.Context) int
- func (mpfq *MailboxPermFlagQuery) FirstX(ctx context.Context) *MailboxPermFlag
- func (mpfq *MailboxPermFlagQuery) GroupBy(field string, fields ...string) *MailboxPermFlagGroupBy
- func (mpfq *MailboxPermFlagQuery) IDs(ctx context.Context) ([]int, error)
- func (mpfq *MailboxPermFlagQuery) IDsX(ctx context.Context) []int
- func (mpfq *MailboxPermFlagQuery) Limit(limit int) *MailboxPermFlagQuery
- func (mpfq *MailboxPermFlagQuery) Offset(offset int) *MailboxPermFlagQuery
- func (mpfq *MailboxPermFlagQuery) Only(ctx context.Context) (*MailboxPermFlag, error)
- func (mpfq *MailboxPermFlagQuery) OnlyID(ctx context.Context) (id int, err error)
- func (mpfq *MailboxPermFlagQuery) OnlyIDX(ctx context.Context) int
- func (mpfq *MailboxPermFlagQuery) OnlyX(ctx context.Context) *MailboxPermFlag
- func (mpfq *MailboxPermFlagQuery) Order(o ...OrderFunc) *MailboxPermFlagQuery
- func (mpfq *MailboxPermFlagQuery) Select(fields ...string) *MailboxPermFlagSelect
- func (mpfq *MailboxPermFlagQuery) Unique(unique bool) *MailboxPermFlagQuery
- func (mpfq *MailboxPermFlagQuery) Where(ps ...predicate.MailboxPermFlag) *MailboxPermFlagQuery
- type MailboxPermFlagSelect
- func (mpfs *MailboxPermFlagSelect) Bool(ctx context.Context) (_ bool, err error)
- func (mpfs *MailboxPermFlagSelect) BoolX(ctx context.Context) bool
- func (mpfs *MailboxPermFlagSelect) Bools(ctx context.Context) ([]bool, error)
- func (mpfs *MailboxPermFlagSelect) BoolsX(ctx context.Context) []bool
- func (mpfs *MailboxPermFlagSelect) Float64(ctx context.Context) (_ float64, err error)
- func (mpfs *MailboxPermFlagSelect) Float64X(ctx context.Context) float64
- func (mpfs *MailboxPermFlagSelect) Float64s(ctx context.Context) ([]float64, error)
- func (mpfs *MailboxPermFlagSelect) Float64sX(ctx context.Context) []float64
- func (mpfs *MailboxPermFlagSelect) Int(ctx context.Context) (_ int, err error)
- func (mpfs *MailboxPermFlagSelect) IntX(ctx context.Context) int
- func (mpfs *MailboxPermFlagSelect) Ints(ctx context.Context) ([]int, error)
- func (mpfs *MailboxPermFlagSelect) IntsX(ctx context.Context) []int
- func (mpfs *MailboxPermFlagSelect) Scan(ctx context.Context, v interface{}) error
- func (mpfs *MailboxPermFlagSelect) ScanX(ctx context.Context, v interface{})
- func (mpfs *MailboxPermFlagSelect) String(ctx context.Context) (_ string, err error)
- func (mpfs *MailboxPermFlagSelect) StringX(ctx context.Context) string
- func (mpfs *MailboxPermFlagSelect) Strings(ctx context.Context) ([]string, error)
- func (mpfs *MailboxPermFlagSelect) StringsX(ctx context.Context) []string
- type MailboxPermFlagUpdate
- func (mpfu *MailboxPermFlagUpdate) Exec(ctx context.Context) error
- func (mpfu *MailboxPermFlagUpdate) ExecX(ctx context.Context)
- func (mpfu *MailboxPermFlagUpdate) Mutation() *MailboxPermFlagMutation
- func (mpfu *MailboxPermFlagUpdate) Save(ctx context.Context) (int, error)
- func (mpfu *MailboxPermFlagUpdate) SaveX(ctx context.Context) int
- func (mpfu *MailboxPermFlagUpdate) SetValue(s string) *MailboxPermFlagUpdate
- func (mpfu *MailboxPermFlagUpdate) Where(ps ...predicate.MailboxPermFlag) *MailboxPermFlagUpdate
- type MailboxPermFlagUpdateOne
- func (mpfuo *MailboxPermFlagUpdateOne) Exec(ctx context.Context) error
- func (mpfuo *MailboxPermFlagUpdateOne) ExecX(ctx context.Context)
- func (mpfuo *MailboxPermFlagUpdateOne) Mutation() *MailboxPermFlagMutation
- func (mpfuo *MailboxPermFlagUpdateOne) Save(ctx context.Context) (*MailboxPermFlag, error)
- func (mpfuo *MailboxPermFlagUpdateOne) SaveX(ctx context.Context) *MailboxPermFlag
- func (mpfuo *MailboxPermFlagUpdateOne) Select(field string, fields ...string) *MailboxPermFlagUpdateOne
- func (mpfuo *MailboxPermFlagUpdateOne) SetValue(s string) *MailboxPermFlagUpdateOne
- type MailboxPermFlags
- type MailboxQuery
- func (mq *MailboxQuery) All(ctx context.Context) ([]*Mailbox, error)
- func (mq *MailboxQuery) AllX(ctx context.Context) []*Mailbox
- func (mq *MailboxQuery) Clone() *MailboxQuery
- func (mq *MailboxQuery) Count(ctx context.Context) (int, error)
- func (mq *MailboxQuery) CountX(ctx context.Context) int
- func (mq *MailboxQuery) Exist(ctx context.Context) (bool, error)
- func (mq *MailboxQuery) ExistX(ctx context.Context) bool
- func (mq *MailboxQuery) First(ctx context.Context) (*Mailbox, error)
- func (mq *MailboxQuery) FirstID(ctx context.Context) (id int, err error)
- func (mq *MailboxQuery) FirstIDX(ctx context.Context) int
- func (mq *MailboxQuery) FirstX(ctx context.Context) *Mailbox
- func (mq *MailboxQuery) GroupBy(field string, fields ...string) *MailboxGroupBy
- func (mq *MailboxQuery) IDs(ctx context.Context) ([]int, error)
- func (mq *MailboxQuery) IDsX(ctx context.Context) []int
- func (mq *MailboxQuery) Limit(limit int) *MailboxQuery
- func (mq *MailboxQuery) Offset(offset int) *MailboxQuery
- func (mq *MailboxQuery) Only(ctx context.Context) (*Mailbox, error)
- func (mq *MailboxQuery) OnlyID(ctx context.Context) (id int, err error)
- func (mq *MailboxQuery) OnlyIDX(ctx context.Context) int
- func (mq *MailboxQuery) OnlyX(ctx context.Context) *Mailbox
- func (mq *MailboxQuery) Order(o ...OrderFunc) *MailboxQuery
- func (mq *MailboxQuery) QueryAttributes() *MailboxAttrQuery
- func (mq *MailboxQuery) QueryFlags() *MailboxFlagQuery
- func (mq *MailboxQuery) QueryPermanentFlags() *MailboxPermFlagQuery
- func (mq *MailboxQuery) QueryUIDs() *UIDQuery
- func (mq *MailboxQuery) Select(fields ...string) *MailboxSelect
- func (mq *MailboxQuery) Unique(unique bool) *MailboxQuery
- func (mq *MailboxQuery) Where(ps ...predicate.Mailbox) *MailboxQuery
- func (mq *MailboxQuery) WithAttributes(opts ...func(*MailboxAttrQuery)) *MailboxQuery
- func (mq *MailboxQuery) WithFlags(opts ...func(*MailboxFlagQuery)) *MailboxQuery
- func (mq *MailboxQuery) WithPermanentFlags(opts ...func(*MailboxPermFlagQuery)) *MailboxQuery
- func (mq *MailboxQuery) WithUIDs(opts ...func(*UIDQuery)) *MailboxQuery
- type MailboxSelect
- func (ms *MailboxSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ms *MailboxSelect) BoolX(ctx context.Context) bool
- func (ms *MailboxSelect) Bools(ctx context.Context) ([]bool, error)
- func (ms *MailboxSelect) BoolsX(ctx context.Context) []bool
- func (ms *MailboxSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ms *MailboxSelect) Float64X(ctx context.Context) float64
- func (ms *MailboxSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ms *MailboxSelect) Float64sX(ctx context.Context) []float64
- func (ms *MailboxSelect) Int(ctx context.Context) (_ int, err error)
- func (ms *MailboxSelect) IntX(ctx context.Context) int
- func (ms *MailboxSelect) Ints(ctx context.Context) ([]int, error)
- func (ms *MailboxSelect) IntsX(ctx context.Context) []int
- func (ms *MailboxSelect) Scan(ctx context.Context, v interface{}) error
- func (ms *MailboxSelect) ScanX(ctx context.Context, v interface{})
- func (ms *MailboxSelect) String(ctx context.Context) (_ string, err error)
- func (ms *MailboxSelect) StringX(ctx context.Context) string
- func (ms *MailboxSelect) Strings(ctx context.Context) ([]string, error)
- func (ms *MailboxSelect) StringsX(ctx context.Context) []string
- type MailboxUpdate
- func (mu *MailboxUpdate) AddAttributeIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) AddAttributes(m ...*MailboxAttr) *MailboxUpdate
- func (mu *MailboxUpdate) AddFlagIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) AddFlags(m ...*MailboxFlag) *MailboxUpdate
- func (mu *MailboxUpdate) AddPermanentFlagIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) AddPermanentFlags(m ...*MailboxPermFlag) *MailboxUpdate
- func (mu *MailboxUpdate) AddUIDIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) AddUIDNext(i int) *MailboxUpdate
- func (mu *MailboxUpdate) AddUIDValidity(i int) *MailboxUpdate
- func (mu *MailboxUpdate) AddUIDs(u ...*UID) *MailboxUpdate
- func (mu *MailboxUpdate) ClearAttributes() *MailboxUpdate
- func (mu *MailboxUpdate) ClearFlags() *MailboxUpdate
- func (mu *MailboxUpdate) ClearPermanentFlags() *MailboxUpdate
- func (mu *MailboxUpdate) ClearUIDs() *MailboxUpdate
- func (mu *MailboxUpdate) Exec(ctx context.Context) error
- func (mu *MailboxUpdate) ExecX(ctx context.Context)
- func (mu *MailboxUpdate) Mutation() *MailboxMutation
- func (mu *MailboxUpdate) RemoveAttributeIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) RemoveAttributes(m ...*MailboxAttr) *MailboxUpdate
- func (mu *MailboxUpdate) RemoveFlagIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) RemoveFlags(m ...*MailboxFlag) *MailboxUpdate
- func (mu *MailboxUpdate) RemovePermanentFlagIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) RemovePermanentFlags(m ...*MailboxPermFlag) *MailboxUpdate
- func (mu *MailboxUpdate) RemoveUIDIDs(ids ...int) *MailboxUpdate
- func (mu *MailboxUpdate) RemoveUIDs(u ...*UID) *MailboxUpdate
- func (mu *MailboxUpdate) Save(ctx context.Context) (int, error)
- func (mu *MailboxUpdate) SaveX(ctx context.Context) int
- func (mu *MailboxUpdate) SetMailboxID(s string) *MailboxUpdate
- func (mu *MailboxUpdate) SetName(s string) *MailboxUpdate
- func (mu *MailboxUpdate) SetNillableSubscribed(b *bool) *MailboxUpdate
- func (mu *MailboxUpdate) SetNillableUIDNext(i *int) *MailboxUpdate
- func (mu *MailboxUpdate) SetNillableUIDValidity(i *int) *MailboxUpdate
- func (mu *MailboxUpdate) SetSubscribed(b bool) *MailboxUpdate
- func (mu *MailboxUpdate) SetUIDNext(i int) *MailboxUpdate
- func (mu *MailboxUpdate) SetUIDValidity(i int) *MailboxUpdate
- func (mu *MailboxUpdate) Where(ps ...predicate.Mailbox) *MailboxUpdate
- type MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddAttributeIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddAttributes(m ...*MailboxAttr) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddFlagIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddFlags(m ...*MailboxFlag) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddPermanentFlagIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddPermanentFlags(m ...*MailboxPermFlag) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddUIDIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddUIDNext(i int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddUIDValidity(i int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) AddUIDs(u ...*UID) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) ClearAttributes() *MailboxUpdateOne
- func (muo *MailboxUpdateOne) ClearFlags() *MailboxUpdateOne
- func (muo *MailboxUpdateOne) ClearPermanentFlags() *MailboxUpdateOne
- func (muo *MailboxUpdateOne) ClearUIDs() *MailboxUpdateOne
- func (muo *MailboxUpdateOne) Exec(ctx context.Context) error
- func (muo *MailboxUpdateOne) ExecX(ctx context.Context)
- func (muo *MailboxUpdateOne) Mutation() *MailboxMutation
- func (muo *MailboxUpdateOne) RemoveAttributeIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemoveAttributes(m ...*MailboxAttr) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemoveFlagIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemoveFlags(m ...*MailboxFlag) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemovePermanentFlagIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemovePermanentFlags(m ...*MailboxPermFlag) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemoveUIDIDs(ids ...int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) RemoveUIDs(u ...*UID) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) Save(ctx context.Context) (*Mailbox, error)
- func (muo *MailboxUpdateOne) SaveX(ctx context.Context) *Mailbox
- func (muo *MailboxUpdateOne) Select(field string, fields ...string) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetMailboxID(s string) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetName(s string) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetNillableSubscribed(b *bool) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetNillableUIDNext(i *int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetNillableUIDValidity(i *int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetSubscribed(b bool) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetUIDNext(i int) *MailboxUpdateOne
- func (muo *MailboxUpdateOne) SetUIDValidity(i int) *MailboxUpdateOne
- type Mailboxes
- type Message
- type MessageClient
- func (c *MessageClient) Create() *MessageCreate
- func (c *MessageClient) CreateBulk(builders ...*MessageCreate) *MessageCreateBulk
- func (c *MessageClient) Delete() *MessageDelete
- func (c *MessageClient) DeleteOne(m *Message) *MessageDeleteOne
- func (c *MessageClient) DeleteOneID(id int) *MessageDeleteOne
- func (c *MessageClient) Get(ctx context.Context, id int) (*Message, error)
- func (c *MessageClient) GetX(ctx context.Context, id int) *Message
- func (c *MessageClient) Hooks() []Hook
- func (c *MessageClient) Query() *MessageQuery
- func (c *MessageClient) QueryFlags(m *Message) *MessageFlagQuery
- func (c *MessageClient) QueryUIDs(m *Message) *UIDQuery
- func (c *MessageClient) Update() *MessageUpdate
- func (c *MessageClient) UpdateOne(m *Message) *MessageUpdateOne
- func (c *MessageClient) UpdateOneID(id int) *MessageUpdateOne
- func (c *MessageClient) Use(hooks ...Hook)
- type MessageCreate
- func (mc *MessageCreate) AddFlagIDs(ids ...int) *MessageCreate
- func (mc *MessageCreate) AddFlags(m ...*MessageFlag) *MessageCreate
- func (mc *MessageCreate) AddUIDIDs(ids ...int) *MessageCreate
- func (mc *MessageCreate) AddUIDs(u ...*UID) *MessageCreate
- func (mc *MessageCreate) Exec(ctx context.Context) error
- func (mc *MessageCreate) ExecX(ctx context.Context)
- func (mc *MessageCreate) Mutation() *MessageMutation
- func (mc *MessageCreate) Save(ctx context.Context) (*Message, error)
- func (mc *MessageCreate) SaveX(ctx context.Context) *Message
- func (mc *MessageCreate) SetBody(s string) *MessageCreate
- func (mc *MessageCreate) SetBodyStructure(s string) *MessageCreate
- func (mc *MessageCreate) SetDate(t time.Time) *MessageCreate
- func (mc *MessageCreate) SetEnvelope(s string) *MessageCreate
- func (mc *MessageCreate) SetInternalID(s string) *MessageCreate
- func (mc *MessageCreate) SetMessageID(s string) *MessageCreate
- func (mc *MessageCreate) SetSize(i int) *MessageCreate
- type MessageCreateBulk
- type MessageDelete
- type MessageDeleteOne
- type MessageEdges
- type MessageFlag
- type MessageFlagClient
- func (c *MessageFlagClient) Create() *MessageFlagCreate
- func (c *MessageFlagClient) CreateBulk(builders ...*MessageFlagCreate) *MessageFlagCreateBulk
- func (c *MessageFlagClient) Delete() *MessageFlagDelete
- func (c *MessageFlagClient) DeleteOne(mf *MessageFlag) *MessageFlagDeleteOne
- func (c *MessageFlagClient) DeleteOneID(id int) *MessageFlagDeleteOne
- func (c *MessageFlagClient) Get(ctx context.Context, id int) (*MessageFlag, error)
- func (c *MessageFlagClient) GetX(ctx context.Context, id int) *MessageFlag
- func (c *MessageFlagClient) Hooks() []Hook
- func (c *MessageFlagClient) Query() *MessageFlagQuery
- func (c *MessageFlagClient) Update() *MessageFlagUpdate
- func (c *MessageFlagClient) UpdateOne(mf *MessageFlag) *MessageFlagUpdateOne
- func (c *MessageFlagClient) UpdateOneID(id int) *MessageFlagUpdateOne
- func (c *MessageFlagClient) Use(hooks ...Hook)
- type MessageFlagCreate
- func (mfc *MessageFlagCreate) Exec(ctx context.Context) error
- func (mfc *MessageFlagCreate) ExecX(ctx context.Context)
- func (mfc *MessageFlagCreate) Mutation() *MessageFlagMutation
- func (mfc *MessageFlagCreate) Save(ctx context.Context) (*MessageFlag, error)
- func (mfc *MessageFlagCreate) SaveX(ctx context.Context) *MessageFlag
- func (mfc *MessageFlagCreate) SetValue(s string) *MessageFlagCreate
- type MessageFlagCreateBulk
- type MessageFlagDelete
- type MessageFlagDeleteOne
- type MessageFlagGroupBy
- func (mfgb *MessageFlagGroupBy) Aggregate(fns ...AggregateFunc) *MessageFlagGroupBy
- func (mfgb *MessageFlagGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (mfgb *MessageFlagGroupBy) BoolX(ctx context.Context) bool
- func (mfgb *MessageFlagGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (mfgb *MessageFlagGroupBy) BoolsX(ctx context.Context) []bool
- func (mfgb *MessageFlagGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (mfgb *MessageFlagGroupBy) Float64X(ctx context.Context) float64
- func (mfgb *MessageFlagGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (mfgb *MessageFlagGroupBy) Float64sX(ctx context.Context) []float64
- func (mfgb *MessageFlagGroupBy) Int(ctx context.Context) (_ int, err error)
- func (mfgb *MessageFlagGroupBy) IntX(ctx context.Context) int
- func (mfgb *MessageFlagGroupBy) Ints(ctx context.Context) ([]int, error)
- func (mfgb *MessageFlagGroupBy) IntsX(ctx context.Context) []int
- func (mfgb *MessageFlagGroupBy) Scan(ctx context.Context, v interface{}) error
- func (mfgb *MessageFlagGroupBy) ScanX(ctx context.Context, v interface{})
- func (mfgb *MessageFlagGroupBy) String(ctx context.Context) (_ string, err error)
- func (mfgb *MessageFlagGroupBy) StringX(ctx context.Context) string
- func (mfgb *MessageFlagGroupBy) Strings(ctx context.Context) ([]string, error)
- func (mfgb *MessageFlagGroupBy) StringsX(ctx context.Context) []string
- type MessageFlagMutation
- func (m *MessageFlagMutation) AddField(name string, value ent.Value) error
- func (m *MessageFlagMutation) AddedEdges() []string
- func (m *MessageFlagMutation) AddedField(name string) (ent.Value, bool)
- func (m *MessageFlagMutation) AddedFields() []string
- func (m *MessageFlagMutation) AddedIDs(name string) []ent.Value
- func (m *MessageFlagMutation) ClearEdge(name string) error
- func (m *MessageFlagMutation) ClearField(name string) error
- func (m *MessageFlagMutation) ClearedEdges() []string
- func (m *MessageFlagMutation) ClearedFields() []string
- func (m MessageFlagMutation) Client() *Client
- func (m *MessageFlagMutation) EdgeCleared(name string) bool
- func (m *MessageFlagMutation) Field(name string) (ent.Value, bool)
- func (m *MessageFlagMutation) FieldCleared(name string) bool
- func (m *MessageFlagMutation) Fields() []string
- func (m *MessageFlagMutation) ID() (id int, exists bool)
- func (m *MessageFlagMutation) IDs(ctx context.Context) ([]int, error)
- func (m *MessageFlagMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MessageFlagMutation) OldValue(ctx context.Context) (v string, err error)
- func (m *MessageFlagMutation) Op() Op
- func (m *MessageFlagMutation) RemovedEdges() []string
- func (m *MessageFlagMutation) RemovedIDs(name string) []ent.Value
- func (m *MessageFlagMutation) ResetEdge(name string) error
- func (m *MessageFlagMutation) ResetField(name string) error
- func (m *MessageFlagMutation) ResetValue()
- func (m *MessageFlagMutation) SetField(name string, value ent.Value) error
- func (m *MessageFlagMutation) SetValue(s string)
- func (m MessageFlagMutation) Tx() (*Tx, error)
- func (m *MessageFlagMutation) Type() string
- func (m *MessageFlagMutation) Value() (r string, exists bool)
- func (m *MessageFlagMutation) Where(ps ...predicate.MessageFlag)
- type MessageFlagQuery
- func (mfq *MessageFlagQuery) All(ctx context.Context) ([]*MessageFlag, error)
- func (mfq *MessageFlagQuery) AllX(ctx context.Context) []*MessageFlag
- func (mfq *MessageFlagQuery) Clone() *MessageFlagQuery
- func (mfq *MessageFlagQuery) Count(ctx context.Context) (int, error)
- func (mfq *MessageFlagQuery) CountX(ctx context.Context) int
- func (mfq *MessageFlagQuery) Exist(ctx context.Context) (bool, error)
- func (mfq *MessageFlagQuery) ExistX(ctx context.Context) bool
- func (mfq *MessageFlagQuery) First(ctx context.Context) (*MessageFlag, error)
- func (mfq *MessageFlagQuery) FirstID(ctx context.Context) (id int, err error)
- func (mfq *MessageFlagQuery) FirstIDX(ctx context.Context) int
- func (mfq *MessageFlagQuery) FirstX(ctx context.Context) *MessageFlag
- func (mfq *MessageFlagQuery) GroupBy(field string, fields ...string) *MessageFlagGroupBy
- func (mfq *MessageFlagQuery) IDs(ctx context.Context) ([]int, error)
- func (mfq *MessageFlagQuery) IDsX(ctx context.Context) []int
- func (mfq *MessageFlagQuery) Limit(limit int) *MessageFlagQuery
- func (mfq *MessageFlagQuery) Offset(offset int) *MessageFlagQuery
- func (mfq *MessageFlagQuery) Only(ctx context.Context) (*MessageFlag, error)
- func (mfq *MessageFlagQuery) OnlyID(ctx context.Context) (id int, err error)
- func (mfq *MessageFlagQuery) OnlyIDX(ctx context.Context) int
- func (mfq *MessageFlagQuery) OnlyX(ctx context.Context) *MessageFlag
- func (mfq *MessageFlagQuery) Order(o ...OrderFunc) *MessageFlagQuery
- func (mfq *MessageFlagQuery) Select(fields ...string) *MessageFlagSelect
- func (mfq *MessageFlagQuery) Unique(unique bool) *MessageFlagQuery
- func (mfq *MessageFlagQuery) Where(ps ...predicate.MessageFlag) *MessageFlagQuery
- type MessageFlagSelect
- func (mfs *MessageFlagSelect) Bool(ctx context.Context) (_ bool, err error)
- func (mfs *MessageFlagSelect) BoolX(ctx context.Context) bool
- func (mfs *MessageFlagSelect) Bools(ctx context.Context) ([]bool, error)
- func (mfs *MessageFlagSelect) BoolsX(ctx context.Context) []bool
- func (mfs *MessageFlagSelect) Float64(ctx context.Context) (_ float64, err error)
- func (mfs *MessageFlagSelect) Float64X(ctx context.Context) float64
- func (mfs *MessageFlagSelect) Float64s(ctx context.Context) ([]float64, error)
- func (mfs *MessageFlagSelect) Float64sX(ctx context.Context) []float64
- func (mfs *MessageFlagSelect) Int(ctx context.Context) (_ int, err error)
- func (mfs *MessageFlagSelect) IntX(ctx context.Context) int
- func (mfs *MessageFlagSelect) Ints(ctx context.Context) ([]int, error)
- func (mfs *MessageFlagSelect) IntsX(ctx context.Context) []int
- func (mfs *MessageFlagSelect) Scan(ctx context.Context, v interface{}) error
- func (mfs *MessageFlagSelect) ScanX(ctx context.Context, v interface{})
- func (mfs *MessageFlagSelect) String(ctx context.Context) (_ string, err error)
- func (mfs *MessageFlagSelect) StringX(ctx context.Context) string
- func (mfs *MessageFlagSelect) Strings(ctx context.Context) ([]string, error)
- func (mfs *MessageFlagSelect) StringsX(ctx context.Context) []string
- type MessageFlagUpdate
- func (mfu *MessageFlagUpdate) Exec(ctx context.Context) error
- func (mfu *MessageFlagUpdate) ExecX(ctx context.Context)
- func (mfu *MessageFlagUpdate) Mutation() *MessageFlagMutation
- func (mfu *MessageFlagUpdate) Save(ctx context.Context) (int, error)
- func (mfu *MessageFlagUpdate) SaveX(ctx context.Context) int
- func (mfu *MessageFlagUpdate) SetValue(s string) *MessageFlagUpdate
- func (mfu *MessageFlagUpdate) Where(ps ...predicate.MessageFlag) *MessageFlagUpdate
- type MessageFlagUpdateOne
- func (mfuo *MessageFlagUpdateOne) Exec(ctx context.Context) error
- func (mfuo *MessageFlagUpdateOne) ExecX(ctx context.Context)
- func (mfuo *MessageFlagUpdateOne) Mutation() *MessageFlagMutation
- func (mfuo *MessageFlagUpdateOne) Save(ctx context.Context) (*MessageFlag, error)
- func (mfuo *MessageFlagUpdateOne) SaveX(ctx context.Context) *MessageFlag
- func (mfuo *MessageFlagUpdateOne) Select(field string, fields ...string) *MessageFlagUpdateOne
- func (mfuo *MessageFlagUpdateOne) SetValue(s string) *MessageFlagUpdateOne
- type MessageFlags
- type MessageGroupBy
- func (mgb *MessageGroupBy) Aggregate(fns ...AggregateFunc) *MessageGroupBy
- func (mgb *MessageGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (mgb *MessageGroupBy) BoolX(ctx context.Context) bool
- func (mgb *MessageGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (mgb *MessageGroupBy) BoolsX(ctx context.Context) []bool
- func (mgb *MessageGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (mgb *MessageGroupBy) Float64X(ctx context.Context) float64
- func (mgb *MessageGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (mgb *MessageGroupBy) Float64sX(ctx context.Context) []float64
- func (mgb *MessageGroupBy) Int(ctx context.Context) (_ int, err error)
- func (mgb *MessageGroupBy) IntX(ctx context.Context) int
- func (mgb *MessageGroupBy) Ints(ctx context.Context) ([]int, error)
- func (mgb *MessageGroupBy) IntsX(ctx context.Context) []int
- func (mgb *MessageGroupBy) Scan(ctx context.Context, v interface{}) error
- func (mgb *MessageGroupBy) ScanX(ctx context.Context, v interface{})
- func (mgb *MessageGroupBy) String(ctx context.Context) (_ string, err error)
- func (mgb *MessageGroupBy) StringX(ctx context.Context) string
- func (mgb *MessageGroupBy) Strings(ctx context.Context) ([]string, error)
- func (mgb *MessageGroupBy) StringsX(ctx context.Context) []string
- type MessageMutation
- func (m *MessageMutation) AddField(name string, value ent.Value) error
- func (m *MessageMutation) AddFlagIDs(ids ...int)
- func (m *MessageMutation) AddSize(i int)
- func (m *MessageMutation) AddUIDIDs(ids ...int)
- func (m *MessageMutation) AddedEdges() []string
- func (m *MessageMutation) AddedField(name string) (ent.Value, bool)
- func (m *MessageMutation) AddedFields() []string
- func (m *MessageMutation) AddedIDs(name string) []ent.Value
- func (m *MessageMutation) AddedSize() (r int, exists bool)
- func (m *MessageMutation) Body() (r string, exists bool)
- func (m *MessageMutation) BodyStructure() (r string, exists bool)
- func (m *MessageMutation) ClearEdge(name string) error
- func (m *MessageMutation) ClearField(name string) error
- func (m *MessageMutation) ClearFlags()
- func (m *MessageMutation) ClearUIDs()
- func (m *MessageMutation) ClearedEdges() []string
- func (m *MessageMutation) ClearedFields() []string
- func (m MessageMutation) Client() *Client
- func (m *MessageMutation) Date() (r time.Time, exists bool)
- func (m *MessageMutation) EdgeCleared(name string) bool
- func (m *MessageMutation) Envelope() (r string, exists bool)
- func (m *MessageMutation) Field(name string) (ent.Value, bool)
- func (m *MessageMutation) FieldCleared(name string) bool
- func (m *MessageMutation) Fields() []string
- func (m *MessageMutation) FlagsCleared() bool
- func (m *MessageMutation) FlagsIDs() (ids []int)
- func (m *MessageMutation) ID() (id int, exists bool)
- func (m *MessageMutation) IDs(ctx context.Context) ([]int, error)
- func (m *MessageMutation) InternalID() (r string, exists bool)
- func (m *MessageMutation) MessageID() (r string, exists bool)
- func (m *MessageMutation) OldBody(ctx context.Context) (v string, err error)
- func (m *MessageMutation) OldBodyStructure(ctx context.Context) (v string, err error)
- func (m *MessageMutation) OldDate(ctx context.Context) (v time.Time, err error)
- func (m *MessageMutation) OldEnvelope(ctx context.Context) (v string, err error)
- func (m *MessageMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MessageMutation) OldInternalID(ctx context.Context) (v string, err error)
- func (m *MessageMutation) OldMessageID(ctx context.Context) (v string, err error)
- func (m *MessageMutation) OldSize(ctx context.Context) (v int, err error)
- func (m *MessageMutation) Op() Op
- func (m *MessageMutation) RemoveFlagIDs(ids ...int)
- func (m *MessageMutation) RemoveUIDIDs(ids ...int)
- func (m *MessageMutation) RemovedEdges() []string
- func (m *MessageMutation) RemovedFlagsIDs() (ids []int)
- func (m *MessageMutation) RemovedIDs(name string) []ent.Value
- func (m *MessageMutation) RemovedUIDsIDs() (ids []int)
- func (m *MessageMutation) ResetBody()
- func (m *MessageMutation) ResetBodyStructure()
- func (m *MessageMutation) ResetDate()
- func (m *MessageMutation) ResetEdge(name string) error
- func (m *MessageMutation) ResetEnvelope()
- func (m *MessageMutation) ResetField(name string) error
- func (m *MessageMutation) ResetFlags()
- func (m *MessageMutation) ResetInternalID()
- func (m *MessageMutation) ResetMessageID()
- func (m *MessageMutation) ResetSize()
- func (m *MessageMutation) ResetUIDs()
- func (m *MessageMutation) SetBody(s string)
- func (m *MessageMutation) SetBodyStructure(s string)
- func (m *MessageMutation) SetDate(t time.Time)
- func (m *MessageMutation) SetEnvelope(s string)
- func (m *MessageMutation) SetField(name string, value ent.Value) error
- func (m *MessageMutation) SetInternalID(s string)
- func (m *MessageMutation) SetMessageID(s string)
- func (m *MessageMutation) SetSize(i int)
- func (m *MessageMutation) Size() (r int, exists bool)
- func (m MessageMutation) Tx() (*Tx, error)
- func (m *MessageMutation) Type() string
- func (m *MessageMutation) UIDsCleared() bool
- func (m *MessageMutation) UIDsIDs() (ids []int)
- func (m *MessageMutation) Where(ps ...predicate.Message)
- type MessageQuery
- func (mq *MessageQuery) All(ctx context.Context) ([]*Message, error)
- func (mq *MessageQuery) AllX(ctx context.Context) []*Message
- func (mq *MessageQuery) Clone() *MessageQuery
- func (mq *MessageQuery) Count(ctx context.Context) (int, error)
- func (mq *MessageQuery) CountX(ctx context.Context) int
- func (mq *MessageQuery) Exist(ctx context.Context) (bool, error)
- func (mq *MessageQuery) ExistX(ctx context.Context) bool
- func (mq *MessageQuery) First(ctx context.Context) (*Message, error)
- func (mq *MessageQuery) FirstID(ctx context.Context) (id int, err error)
- func (mq *MessageQuery) FirstIDX(ctx context.Context) int
- func (mq *MessageQuery) FirstX(ctx context.Context) *Message
- func (mq *MessageQuery) GroupBy(field string, fields ...string) *MessageGroupBy
- func (mq *MessageQuery) IDs(ctx context.Context) ([]int, error)
- func (mq *MessageQuery) IDsX(ctx context.Context) []int
- func (mq *MessageQuery) Limit(limit int) *MessageQuery
- func (mq *MessageQuery) Offset(offset int) *MessageQuery
- func (mq *MessageQuery) Only(ctx context.Context) (*Message, error)
- func (mq *MessageQuery) OnlyID(ctx context.Context) (id int, err error)
- func (mq *MessageQuery) OnlyIDX(ctx context.Context) int
- func (mq *MessageQuery) OnlyX(ctx context.Context) *Message
- func (mq *MessageQuery) Order(o ...OrderFunc) *MessageQuery
- func (mq *MessageQuery) QueryFlags() *MessageFlagQuery
- func (mq *MessageQuery) QueryUIDs() *UIDQuery
- func (mq *MessageQuery) Select(fields ...string) *MessageSelect
- func (mq *MessageQuery) Unique(unique bool) *MessageQuery
- func (mq *MessageQuery) Where(ps ...predicate.Message) *MessageQuery
- func (mq *MessageQuery) WithFlags(opts ...func(*MessageFlagQuery)) *MessageQuery
- func (mq *MessageQuery) WithUIDs(opts ...func(*UIDQuery)) *MessageQuery
- type MessageSelect
- func (ms *MessageSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ms *MessageSelect) BoolX(ctx context.Context) bool
- func (ms *MessageSelect) Bools(ctx context.Context) ([]bool, error)
- func (ms *MessageSelect) BoolsX(ctx context.Context) []bool
- func (ms *MessageSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ms *MessageSelect) Float64X(ctx context.Context) float64
- func (ms *MessageSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ms *MessageSelect) Float64sX(ctx context.Context) []float64
- func (ms *MessageSelect) Int(ctx context.Context) (_ int, err error)
- func (ms *MessageSelect) IntX(ctx context.Context) int
- func (ms *MessageSelect) Ints(ctx context.Context) ([]int, error)
- func (ms *MessageSelect) IntsX(ctx context.Context) []int
- func (ms *MessageSelect) Scan(ctx context.Context, v interface{}) error
- func (ms *MessageSelect) ScanX(ctx context.Context, v interface{})
- func (ms *MessageSelect) String(ctx context.Context) (_ string, err error)
- func (ms *MessageSelect) StringX(ctx context.Context) string
- func (ms *MessageSelect) Strings(ctx context.Context) ([]string, error)
- func (ms *MessageSelect) StringsX(ctx context.Context) []string
- type MessageUpdate
- func (mu *MessageUpdate) AddFlagIDs(ids ...int) *MessageUpdate
- func (mu *MessageUpdate) AddFlags(m ...*MessageFlag) *MessageUpdate
- func (mu *MessageUpdate) AddSize(i int) *MessageUpdate
- func (mu *MessageUpdate) AddUIDIDs(ids ...int) *MessageUpdate
- func (mu *MessageUpdate) AddUIDs(u ...*UID) *MessageUpdate
- func (mu *MessageUpdate) ClearFlags() *MessageUpdate
- func (mu *MessageUpdate) ClearUIDs() *MessageUpdate
- func (mu *MessageUpdate) Exec(ctx context.Context) error
- func (mu *MessageUpdate) ExecX(ctx context.Context)
- func (mu *MessageUpdate) Mutation() *MessageMutation
- func (mu *MessageUpdate) RemoveFlagIDs(ids ...int) *MessageUpdate
- func (mu *MessageUpdate) RemoveFlags(m ...*MessageFlag) *MessageUpdate
- func (mu *MessageUpdate) RemoveUIDIDs(ids ...int) *MessageUpdate
- func (mu *MessageUpdate) RemoveUIDs(u ...*UID) *MessageUpdate
- func (mu *MessageUpdate) Save(ctx context.Context) (int, error)
- func (mu *MessageUpdate) SaveX(ctx context.Context) int
- func (mu *MessageUpdate) SetBody(s string) *MessageUpdate
- func (mu *MessageUpdate) SetBodyStructure(s string) *MessageUpdate
- func (mu *MessageUpdate) SetDate(t time.Time) *MessageUpdate
- func (mu *MessageUpdate) SetEnvelope(s string) *MessageUpdate
- func (mu *MessageUpdate) SetInternalID(s string) *MessageUpdate
- func (mu *MessageUpdate) SetMessageID(s string) *MessageUpdate
- func (mu *MessageUpdate) SetSize(i int) *MessageUpdate
- func (mu *MessageUpdate) Where(ps ...predicate.Message) *MessageUpdate
- type MessageUpdateOne
- func (muo *MessageUpdateOne) AddFlagIDs(ids ...int) *MessageUpdateOne
- func (muo *MessageUpdateOne) AddFlags(m ...*MessageFlag) *MessageUpdateOne
- func (muo *MessageUpdateOne) AddSize(i int) *MessageUpdateOne
- func (muo *MessageUpdateOne) AddUIDIDs(ids ...int) *MessageUpdateOne
- func (muo *MessageUpdateOne) AddUIDs(u ...*UID) *MessageUpdateOne
- func (muo *MessageUpdateOne) ClearFlags() *MessageUpdateOne
- func (muo *MessageUpdateOne) ClearUIDs() *MessageUpdateOne
- func (muo *MessageUpdateOne) Exec(ctx context.Context) error
- func (muo *MessageUpdateOne) ExecX(ctx context.Context)
- func (muo *MessageUpdateOne) Mutation() *MessageMutation
- func (muo *MessageUpdateOne) RemoveFlagIDs(ids ...int) *MessageUpdateOne
- func (muo *MessageUpdateOne) RemoveFlags(m ...*MessageFlag) *MessageUpdateOne
- func (muo *MessageUpdateOne) RemoveUIDIDs(ids ...int) *MessageUpdateOne
- func (muo *MessageUpdateOne) RemoveUIDs(u ...*UID) *MessageUpdateOne
- func (muo *MessageUpdateOne) Save(ctx context.Context) (*Message, error)
- func (muo *MessageUpdateOne) SaveX(ctx context.Context) *Message
- func (muo *MessageUpdateOne) Select(field string, fields ...string) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetBody(s string) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetBodyStructure(s string) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetDate(t time.Time) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetEnvelope(s string) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetInternalID(s string) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetMessageID(s string) *MessageUpdateOne
- func (muo *MessageUpdateOne) SetSize(i int) *MessageUpdateOne
- type Messages
- type MutateFunc
- type Mutation
- type Mutator
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Op
- type Option
- type OrderFunc
- type Policy
- type Query
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type Tx
- type UID
- type UIDClient
- func (c *UIDClient) Create() *UIDCreate
- func (c *UIDClient) CreateBulk(builders ...*UIDCreate) *UIDCreateBulk
- func (c *UIDClient) Delete() *UIDDelete
- func (c *UIDClient) DeleteOne(u *UID) *UIDDeleteOne
- func (c *UIDClient) DeleteOneID(id int) *UIDDeleteOne
- func (c *UIDClient) Get(ctx context.Context, id int) (*UID, error)
- func (c *UIDClient) GetX(ctx context.Context, id int) *UID
- func (c *UIDClient) Hooks() []Hook
- func (c *UIDClient) Query() *UIDQuery
- func (c *UIDClient) QueryMailbox(u *UID) *MailboxQuery
- func (c *UIDClient) QueryMessage(u *UID) *MessageQuery
- func (c *UIDClient) Update() *UIDUpdate
- func (c *UIDClient) UpdateOne(u *UID) *UIDUpdateOne
- func (c *UIDClient) UpdateOneID(id int) *UIDUpdateOne
- func (c *UIDClient) Use(hooks ...Hook)
- type UIDCreate
- func (uc *UIDCreate) Exec(ctx context.Context) error
- func (uc *UIDCreate) ExecX(ctx context.Context)
- func (uc *UIDCreate) Mutation() *UIDMutation
- func (uc *UIDCreate) Save(ctx context.Context) (*UID, error)
- func (uc *UIDCreate) SaveX(ctx context.Context) *UID
- func (uc *UIDCreate) SetDeleted(b bool) *UIDCreate
- func (uc *UIDCreate) SetInDeletionPool(b bool) *UIDCreate
- func (uc *UIDCreate) SetMailbox(m *Mailbox) *UIDCreate
- func (uc *UIDCreate) SetMailboxID(id int) *UIDCreate
- func (uc *UIDCreate) SetMessage(m *Message) *UIDCreate
- func (uc *UIDCreate) SetMessageID(id int) *UIDCreate
- func (uc *UIDCreate) SetNillableDeleted(b *bool) *UIDCreate
- func (uc *UIDCreate) SetNillableInDeletionPool(b *bool) *UIDCreate
- func (uc *UIDCreate) SetNillableMailboxID(id *int) *UIDCreate
- func (uc *UIDCreate) SetNillableMessageID(id *int) *UIDCreate
- func (uc *UIDCreate) SetNillableRecent(b *bool) *UIDCreate
- func (uc *UIDCreate) SetRecent(b bool) *UIDCreate
- func (uc *UIDCreate) SetUID(i int) *UIDCreate
- type UIDCreateBulk
- type UIDDelete
- type UIDDeleteOne
- type UIDEdges
- type UIDGroupBy
- func (ugb *UIDGroupBy) Aggregate(fns ...AggregateFunc) *UIDGroupBy
- func (ugb *UIDGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ugb *UIDGroupBy) BoolX(ctx context.Context) bool
- func (ugb *UIDGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ugb *UIDGroupBy) BoolsX(ctx context.Context) []bool
- func (ugb *UIDGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ugb *UIDGroupBy) Float64X(ctx context.Context) float64
- func (ugb *UIDGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ugb *UIDGroupBy) Float64sX(ctx context.Context) []float64
- func (ugb *UIDGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ugb *UIDGroupBy) IntX(ctx context.Context) int
- func (ugb *UIDGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ugb *UIDGroupBy) IntsX(ctx context.Context) []int
- func (ugb *UIDGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ugb *UIDGroupBy) ScanX(ctx context.Context, v interface{})
- func (ugb *UIDGroupBy) String(ctx context.Context) (_ string, err error)
- func (ugb *UIDGroupBy) StringX(ctx context.Context) string
- func (ugb *UIDGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ugb *UIDGroupBy) StringsX(ctx context.Context) []string
- type UIDMutation
- func (m *UIDMutation) AddField(name string, value ent.Value) error
- func (m *UIDMutation) AddUID(i int)
- func (m *UIDMutation) AddedEdges() []string
- func (m *UIDMutation) AddedField(name string) (ent.Value, bool)
- func (m *UIDMutation) AddedFields() []string
- func (m *UIDMutation) AddedIDs(name string) []ent.Value
- func (m *UIDMutation) AddedUID() (r int, exists bool)
- func (m *UIDMutation) ClearEdge(name string) error
- func (m *UIDMutation) ClearField(name string) error
- func (m *UIDMutation) ClearMailbox()
- func (m *UIDMutation) ClearMessage()
- func (m *UIDMutation) ClearedEdges() []string
- func (m *UIDMutation) ClearedFields() []string
- func (m UIDMutation) Client() *Client
- func (m *UIDMutation) Deleted() (r bool, exists bool)
- func (m *UIDMutation) EdgeCleared(name string) bool
- func (m *UIDMutation) Field(name string) (ent.Value, bool)
- func (m *UIDMutation) FieldCleared(name string) bool
- func (m *UIDMutation) Fields() []string
- func (m *UIDMutation) ID() (id int, exists bool)
- func (m *UIDMutation) IDs(ctx context.Context) ([]int, error)
- func (m *UIDMutation) InDeletionPool() (r bool, exists bool)
- func (m *UIDMutation) MailboxCleared() bool
- func (m *UIDMutation) MailboxID() (id int, exists bool)
- func (m *UIDMutation) MailboxIDs() (ids []int)
- func (m *UIDMutation) MessageCleared() bool
- func (m *UIDMutation) MessageID() (id int, exists bool)
- func (m *UIDMutation) MessageIDs() (ids []int)
- func (m *UIDMutation) OldDeleted(ctx context.Context) (v bool, err error)
- func (m *UIDMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *UIDMutation) OldInDeletionPool(ctx context.Context) (v bool, err error)
- func (m *UIDMutation) OldRecent(ctx context.Context) (v bool, err error)
- func (m *UIDMutation) OldUID(ctx context.Context) (v int, err error)
- func (m *UIDMutation) Op() Op
- func (m *UIDMutation) Recent() (r bool, exists bool)
- func (m *UIDMutation) RemovedEdges() []string
- func (m *UIDMutation) RemovedIDs(name string) []ent.Value
- func (m *UIDMutation) ResetDeleted()
- func (m *UIDMutation) ResetEdge(name string) error
- func (m *UIDMutation) ResetField(name string) error
- func (m *UIDMutation) ResetInDeletionPool()
- func (m *UIDMutation) ResetMailbox()
- func (m *UIDMutation) ResetMessage()
- func (m *UIDMutation) ResetRecent()
- func (m *UIDMutation) ResetUID()
- func (m *UIDMutation) SetDeleted(b bool)
- func (m *UIDMutation) SetField(name string, value ent.Value) error
- func (m *UIDMutation) SetInDeletionPool(b bool)
- func (m *UIDMutation) SetMailboxID(id int)
- func (m *UIDMutation) SetMessageID(id int)
- func (m *UIDMutation) SetRecent(b bool)
- func (m *UIDMutation) SetUID(i int)
- func (m UIDMutation) Tx() (*Tx, error)
- func (m *UIDMutation) Type() string
- func (m *UIDMutation) UID() (r int, exists bool)
- func (m *UIDMutation) Where(ps ...predicate.UID)
- type UIDQuery
- func (uq *UIDQuery) All(ctx context.Context) ([]*UID, error)
- func (uq *UIDQuery) AllX(ctx context.Context) []*UID
- func (uq *UIDQuery) Clone() *UIDQuery
- func (uq *UIDQuery) Count(ctx context.Context) (int, error)
- func (uq *UIDQuery) CountX(ctx context.Context) int
- func (uq *UIDQuery) Exist(ctx context.Context) (bool, error)
- func (uq *UIDQuery) ExistX(ctx context.Context) bool
- func (uq *UIDQuery) First(ctx context.Context) (*UID, error)
- func (uq *UIDQuery) FirstID(ctx context.Context) (id int, err error)
- func (uq *UIDQuery) FirstIDX(ctx context.Context) int
- func (uq *UIDQuery) FirstX(ctx context.Context) *UID
- func (uq *UIDQuery) GroupBy(field string, fields ...string) *UIDGroupBy
- func (uq *UIDQuery) IDs(ctx context.Context) ([]int, error)
- func (uq *UIDQuery) IDsX(ctx context.Context) []int
- func (uq *UIDQuery) Limit(limit int) *UIDQuery
- func (uq *UIDQuery) Offset(offset int) *UIDQuery
- func (uq *UIDQuery) Only(ctx context.Context) (*UID, error)
- func (uq *UIDQuery) OnlyID(ctx context.Context) (id int, err error)
- func (uq *UIDQuery) OnlyIDX(ctx context.Context) int
- func (uq *UIDQuery) OnlyX(ctx context.Context) *UID
- func (uq *UIDQuery) Order(o ...OrderFunc) *UIDQuery
- func (uq *UIDQuery) QueryMailbox() *MailboxQuery
- func (uq *UIDQuery) QueryMessage() *MessageQuery
- func (uq *UIDQuery) Select(fields ...string) *UIDSelect
- func (uq *UIDQuery) Unique(unique bool) *UIDQuery
- func (uq *UIDQuery) Where(ps ...predicate.UID) *UIDQuery
- func (uq *UIDQuery) WithMailbox(opts ...func(*MailboxQuery)) *UIDQuery
- func (uq *UIDQuery) WithMessage(opts ...func(*MessageQuery)) *UIDQuery
- type UIDSelect
- func (us *UIDSelect) Bool(ctx context.Context) (_ bool, err error)
- func (us *UIDSelect) BoolX(ctx context.Context) bool
- func (us *UIDSelect) Bools(ctx context.Context) ([]bool, error)
- func (us *UIDSelect) BoolsX(ctx context.Context) []bool
- func (us *UIDSelect) Float64(ctx context.Context) (_ float64, err error)
- func (us *UIDSelect) Float64X(ctx context.Context) float64
- func (us *UIDSelect) Float64s(ctx context.Context) ([]float64, error)
- func (us *UIDSelect) Float64sX(ctx context.Context) []float64
- func (us *UIDSelect) Int(ctx context.Context) (_ int, err error)
- func (us *UIDSelect) IntX(ctx context.Context) int
- func (us *UIDSelect) Ints(ctx context.Context) ([]int, error)
- func (us *UIDSelect) IntsX(ctx context.Context) []int
- func (us *UIDSelect) Scan(ctx context.Context, v interface{}) error
- func (us *UIDSelect) ScanX(ctx context.Context, v interface{})
- func (us *UIDSelect) String(ctx context.Context) (_ string, err error)
- func (us *UIDSelect) StringX(ctx context.Context) string
- func (us *UIDSelect) Strings(ctx context.Context) ([]string, error)
- func (us *UIDSelect) StringsX(ctx context.Context) []string
- type UIDUpdate
- func (uu *UIDUpdate) AddUID(i int) *UIDUpdate
- func (uu *UIDUpdate) ClearMailbox() *UIDUpdate
- func (uu *UIDUpdate) ClearMessage() *UIDUpdate
- func (uu *UIDUpdate) Exec(ctx context.Context) error
- func (uu *UIDUpdate) ExecX(ctx context.Context)
- func (uu *UIDUpdate) Mutation() *UIDMutation
- func (uu *UIDUpdate) Save(ctx context.Context) (int, error)
- func (uu *UIDUpdate) SaveX(ctx context.Context) int
- func (uu *UIDUpdate) SetDeleted(b bool) *UIDUpdate
- func (uu *UIDUpdate) SetInDeletionPool(b bool) *UIDUpdate
- func (uu *UIDUpdate) SetMailbox(m *Mailbox) *UIDUpdate
- func (uu *UIDUpdate) SetMailboxID(id int) *UIDUpdate
- func (uu *UIDUpdate) SetMessage(m *Message) *UIDUpdate
- func (uu *UIDUpdate) SetMessageID(id int) *UIDUpdate
- func (uu *UIDUpdate) SetNillableDeleted(b *bool) *UIDUpdate
- func (uu *UIDUpdate) SetNillableInDeletionPool(b *bool) *UIDUpdate
- func (uu *UIDUpdate) SetNillableMailboxID(id *int) *UIDUpdate
- func (uu *UIDUpdate) SetNillableMessageID(id *int) *UIDUpdate
- func (uu *UIDUpdate) SetNillableRecent(b *bool) *UIDUpdate
- func (uu *UIDUpdate) SetRecent(b bool) *UIDUpdate
- func (uu *UIDUpdate) SetUID(i int) *UIDUpdate
- func (uu *UIDUpdate) Where(ps ...predicate.UID) *UIDUpdate
- type UIDUpdateOne
- func (uuo *UIDUpdateOne) AddUID(i int) *UIDUpdateOne
- func (uuo *UIDUpdateOne) ClearMailbox() *UIDUpdateOne
- func (uuo *UIDUpdateOne) ClearMessage() *UIDUpdateOne
- func (uuo *UIDUpdateOne) Exec(ctx context.Context) error
- func (uuo *UIDUpdateOne) ExecX(ctx context.Context)
- func (uuo *UIDUpdateOne) Mutation() *UIDMutation
- func (uuo *UIDUpdateOne) Save(ctx context.Context) (*UID, error)
- func (uuo *UIDUpdateOne) SaveX(ctx context.Context) *UID
- func (uuo *UIDUpdateOne) Select(field string, fields ...string) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetDeleted(b bool) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetInDeletionPool(b bool) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetMailbox(m *Mailbox) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetMailboxID(id int) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetMessage(m *Message) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetMessageID(id int) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetNillableDeleted(b *bool) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetNillableInDeletionPool(b *bool) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetNillableMailboxID(id *int) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetNillableMessageID(id *int) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetNillableRecent(b *bool) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetRecent(b bool) *UIDUpdateOne
- func (uuo *UIDUpdateOne) SetUID(i int) *UIDUpdateOne
- type UIDs
- 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. TypeMailbox = "Mailbox" TypeMailboxAttr = "MailboxAttr" TypeMailboxFlag = "MailboxFlag" TypeMailboxPermFlag = "MailboxPermFlag" TypeMessage = "Message" TypeMessageFlag = "MessageFlag" TypeUID = "UID" )
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 validation 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.
func As ¶
func As(fn AggregateFunc, end string) AggregateFunc
As is a pseudo aggregation function for renaming another other functions with custom names. For example:
GroupBy(field1, field2). Aggregate(ent.As(ent.Sum(field1), "sum_field1"), (ent.As(ent.Sum(field2), "sum_field2")). Scan(ctx, &v)
func Count ¶
func Count() AggregateFunc
Count applies the "count" aggregation function on each group.
func Max ¶
func Max(field string) AggregateFunc
Max applies the "max" aggregation function on the given field of each group.
func Mean ¶
func Mean(field string) AggregateFunc
Mean applies the "mean" aggregation function on the given field of each group.
func Min ¶
func Min(field string) AggregateFunc
Min applies the "min" aggregation function on the given field of each group.
func Sum ¶
func Sum(field string) AggregateFunc
Sum applies the "sum" aggregation function on the given field of each group.
type Client ¶
type Client struct { // Schema is the client for creating, migrating and dropping schema. Schema *migrate.Schema // Mailbox is the client for interacting with the Mailbox builders. Mailbox *MailboxClient // MailboxAttr is the client for interacting with the MailboxAttr builders. MailboxAttr *MailboxAttrClient // MailboxFlag is the client for interacting with the MailboxFlag builders. MailboxFlag *MailboxFlagClient // MailboxPermFlag is the client for interacting with the MailboxPermFlag builders. MailboxPermFlag *MailboxPermFlagClient // Message is the client for interacting with the Message builders. Message *MessageClient // MessageFlag is the client for interacting with the MessageFlag builders. MessageFlag *MessageFlagClient // UID is the client for interacting with the UID builders. UID *UIDClient // contains filtered or unexported fields }
Client is the client that holds all ent builders.
func FromContext ¶
FromContext returns a Client stored inside a context, or nil if there isn't one.
func Open ¶
Open opens a database/sql.DB specified by the driver name and the data source name, and returns a new client attached to it. Optional parameters can be added for configuring the client.
func (*Client) Debug ¶
Debug returns a new debug-client. It's used to get verbose logging on specific operations.
client.Debug(). Mailbox. Query(). Count(ctx)
type CommitFunc ¶
The CommitFunc type is an adapter to allow the use of ordinary function as a Committer. If f is a function with the appropriate signature, CommitFunc(f) is a Committer that calls f.
type CommitHook ¶
CommitHook defines the "commit middleware". A function that gets a Committer and returns a Committer. For example:
hook := func(next ent.Committer) ent.Committer { return ent.CommitFunc(func(ctx context.Context, tx *ent.Tx) error { // Do some stuff before. if err := next.Commit(ctx, tx); err != nil { return err } // Do some stuff after. return nil }) }
type ConstraintError ¶
type ConstraintError struct {
// contains filtered or unexported fields
}
ConstraintError returns when trying to create/update one or more entities and one or more of their constraints failed. For example, violation of edge or field uniqueness.
func (ConstraintError) Error ¶
func (e ConstraintError) Error() string
Error implements the error interface.
func (*ConstraintError) Unwrap ¶
func (e *ConstraintError) Unwrap() error
Unwrap implements the errors.Wrapper interface.
type Mailbox ¶
type Mailbox struct { // ID of the ent. ID int `json:"id,omitempty"` // MailboxID holds the value of the "MailboxID" field. MailboxID string `json:"MailboxID,omitempty"` // Name holds the value of the "Name" field. Name string `json:"Name,omitempty"` // UIDNext holds the value of the "UIDNext" field. UIDNext int `json:"UIDNext,omitempty"` // UIDValidity holds the value of the "UIDValidity" field. UIDValidity int `json:"UIDValidity,omitempty"` // Subscribed holds the value of the "Subscribed" field. Subscribed bool `json:"Subscribed,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the MailboxQuery when eager-loading is set. Edges MailboxEdges `json:"edges"` // contains filtered or unexported fields }
Mailbox is the model entity for the Mailbox schema.
func (*Mailbox) QueryAttributes ¶
func (m *Mailbox) QueryAttributes() *MailboxAttrQuery
QueryAttributes queries the "attributes" edge of the Mailbox entity.
func (*Mailbox) QueryFlags ¶
func (m *Mailbox) QueryFlags() *MailboxFlagQuery
QueryFlags queries the "flags" edge of the Mailbox entity.
func (*Mailbox) QueryPermanentFlags ¶
func (m *Mailbox) QueryPermanentFlags() *MailboxPermFlagQuery
QueryPermanentFlags queries the "permanent_flags" edge of the Mailbox entity.
func (*Mailbox) Unwrap ¶
Unwrap unwraps the Mailbox entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*Mailbox) Update ¶
func (m *Mailbox) Update() *MailboxUpdateOne
Update returns a builder for updating this Mailbox. Note that you need to call Mailbox.Unwrap() before calling this method if this Mailbox was returned from a transaction, and the transaction was committed or rolled back.
type MailboxAttr ¶
type MailboxAttr struct { // ID of the ent. ID int `json:"id,omitempty"` // Value holds the value of the "Value" field. Value string `json:"Value,omitempty"` // contains filtered or unexported fields }
MailboxAttr is the model entity for the MailboxAttr schema.
func (*MailboxAttr) String ¶
func (ma *MailboxAttr) String() string
String implements the fmt.Stringer.
func (*MailboxAttr) Unwrap ¶
func (ma *MailboxAttr) Unwrap() *MailboxAttr
Unwrap unwraps the MailboxAttr entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*MailboxAttr) Update ¶
func (ma *MailboxAttr) Update() *MailboxAttrUpdateOne
Update returns a builder for updating this MailboxAttr. Note that you need to call MailboxAttr.Unwrap() before calling this method if this MailboxAttr was returned from a transaction, and the transaction was committed or rolled back.
type MailboxAttrClient ¶
type MailboxAttrClient struct {
// contains filtered or unexported fields
}
MailboxAttrClient is a client for the MailboxAttr schema.
func NewMailboxAttrClient ¶
func NewMailboxAttrClient(c config) *MailboxAttrClient
NewMailboxAttrClient returns a client for the MailboxAttr from the given config.
func (*MailboxAttrClient) Create ¶
func (c *MailboxAttrClient) Create() *MailboxAttrCreate
Create returns a create builder for MailboxAttr.
func (*MailboxAttrClient) CreateBulk ¶
func (c *MailboxAttrClient) CreateBulk(builders ...*MailboxAttrCreate) *MailboxAttrCreateBulk
CreateBulk returns a builder for creating a bulk of MailboxAttr entities.
func (*MailboxAttrClient) Delete ¶
func (c *MailboxAttrClient) Delete() *MailboxAttrDelete
Delete returns a delete builder for MailboxAttr.
func (*MailboxAttrClient) DeleteOne ¶
func (c *MailboxAttrClient) DeleteOne(ma *MailboxAttr) *MailboxAttrDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*MailboxAttrClient) DeleteOneID ¶
func (c *MailboxAttrClient) DeleteOneID(id int) *MailboxAttrDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*MailboxAttrClient) Get ¶
func (c *MailboxAttrClient) Get(ctx context.Context, id int) (*MailboxAttr, error)
Get returns a MailboxAttr entity by its id.
func (*MailboxAttrClient) GetX ¶
func (c *MailboxAttrClient) GetX(ctx context.Context, id int) *MailboxAttr
GetX is like Get, but panics if an error occurs.
func (*MailboxAttrClient) Hooks ¶
func (c *MailboxAttrClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MailboxAttrClient) Query ¶
func (c *MailboxAttrClient) Query() *MailboxAttrQuery
Query returns a query builder for MailboxAttr.
func (*MailboxAttrClient) Update ¶
func (c *MailboxAttrClient) Update() *MailboxAttrUpdate
Update returns an update builder for MailboxAttr.
func (*MailboxAttrClient) UpdateOne ¶
func (c *MailboxAttrClient) UpdateOne(ma *MailboxAttr) *MailboxAttrUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MailboxAttrClient) UpdateOneID ¶
func (c *MailboxAttrClient) UpdateOneID(id int) *MailboxAttrUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MailboxAttrClient) Use ¶
func (c *MailboxAttrClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `mailboxattr.Hooks(f(g(h())))`.
type MailboxAttrCreate ¶
type MailboxAttrCreate struct {
// contains filtered or unexported fields
}
MailboxAttrCreate is the builder for creating a MailboxAttr entity.
func (*MailboxAttrCreate) Exec ¶
func (mac *MailboxAttrCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxAttrCreate) ExecX ¶
func (mac *MailboxAttrCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxAttrCreate) Mutation ¶
func (mac *MailboxAttrCreate) Mutation() *MailboxAttrMutation
Mutation returns the MailboxAttrMutation object of the builder.
func (*MailboxAttrCreate) Save ¶
func (mac *MailboxAttrCreate) Save(ctx context.Context) (*MailboxAttr, error)
Save creates the MailboxAttr in the database.
func (*MailboxAttrCreate) SaveX ¶
func (mac *MailboxAttrCreate) SaveX(ctx context.Context) *MailboxAttr
SaveX calls Save and panics if Save returns an error.
func (*MailboxAttrCreate) SetValue ¶
func (mac *MailboxAttrCreate) SetValue(s string) *MailboxAttrCreate
SetValue sets the "Value" field.
type MailboxAttrCreateBulk ¶
type MailboxAttrCreateBulk struct {
// contains filtered or unexported fields
}
MailboxAttrCreateBulk is the builder for creating many MailboxAttr entities in bulk.
func (*MailboxAttrCreateBulk) Exec ¶
func (macb *MailboxAttrCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxAttrCreateBulk) ExecX ¶
func (macb *MailboxAttrCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxAttrCreateBulk) Save ¶
func (macb *MailboxAttrCreateBulk) Save(ctx context.Context) ([]*MailboxAttr, error)
Save creates the MailboxAttr entities in the database.
func (*MailboxAttrCreateBulk) SaveX ¶
func (macb *MailboxAttrCreateBulk) SaveX(ctx context.Context) []*MailboxAttr
SaveX is like Save, but panics if an error occurs.
type MailboxAttrDelete ¶
type MailboxAttrDelete struct {
// contains filtered or unexported fields
}
MailboxAttrDelete is the builder for deleting a MailboxAttr entity.
func (*MailboxAttrDelete) Exec ¶
func (mad *MailboxAttrDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MailboxAttrDelete) ExecX ¶
func (mad *MailboxAttrDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MailboxAttrDelete) Where ¶
func (mad *MailboxAttrDelete) Where(ps ...predicate.MailboxAttr) *MailboxAttrDelete
Where appends a list predicates to the MailboxAttrDelete builder.
type MailboxAttrDeleteOne ¶
type MailboxAttrDeleteOne struct {
// contains filtered or unexported fields
}
MailboxAttrDeleteOne is the builder for deleting a single MailboxAttr entity.
func (*MailboxAttrDeleteOne) Exec ¶
func (mado *MailboxAttrDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MailboxAttrDeleteOne) ExecX ¶
func (mado *MailboxAttrDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MailboxAttrGroupBy ¶
type MailboxAttrGroupBy struct {
// contains filtered or unexported fields
}
MailboxAttrGroupBy is the group-by builder for MailboxAttr entities.
func (*MailboxAttrGroupBy) Aggregate ¶
func (magb *MailboxAttrGroupBy) Aggregate(fns ...AggregateFunc) *MailboxAttrGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MailboxAttrGroupBy) Bool ¶
func (magb *MailboxAttrGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) BoolX ¶
func (magb *MailboxAttrGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxAttrGroupBy) Bools ¶
func (magb *MailboxAttrGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) BoolsX ¶
func (magb *MailboxAttrGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxAttrGroupBy) Float64 ¶
func (magb *MailboxAttrGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) Float64X ¶
func (magb *MailboxAttrGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxAttrGroupBy) Float64s ¶
func (magb *MailboxAttrGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) Float64sX ¶
func (magb *MailboxAttrGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxAttrGroupBy) Int ¶
func (magb *MailboxAttrGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) IntX ¶
func (magb *MailboxAttrGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxAttrGroupBy) Ints ¶
func (magb *MailboxAttrGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) IntsX ¶
func (magb *MailboxAttrGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxAttrGroupBy) Scan ¶
func (magb *MailboxAttrGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*MailboxAttrGroupBy) ScanX ¶
func (magb *MailboxAttrGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxAttrGroupBy) String ¶
func (magb *MailboxAttrGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxAttrGroupBy) StringX ¶
func (magb *MailboxAttrGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxAttrMutation ¶
type MailboxAttrMutation struct {
// contains filtered or unexported fields
}
MailboxAttrMutation represents an operation that mutates the MailboxAttr nodes in the graph.
func (*MailboxAttrMutation) AddField ¶
func (m *MailboxAttrMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxAttrMutation) AddedEdges ¶
func (m *MailboxAttrMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MailboxAttrMutation) AddedField ¶
func (m *MailboxAttrMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxAttrMutation) AddedFields ¶
func (m *MailboxAttrMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MailboxAttrMutation) AddedIDs ¶
func (m *MailboxAttrMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MailboxAttrMutation) ClearEdge ¶
func (m *MailboxAttrMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*MailboxAttrMutation) ClearField ¶
func (m *MailboxAttrMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxAttrMutation) ClearedEdges ¶
func (m *MailboxAttrMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MailboxAttrMutation) ClearedFields ¶
func (m *MailboxAttrMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MailboxAttrMutation) Client ¶
func (m MailboxAttrMutation) 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 (*MailboxAttrMutation) EdgeCleared ¶
func (m *MailboxAttrMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MailboxAttrMutation) Field ¶
func (m *MailboxAttrMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxAttrMutation) FieldCleared ¶
func (m *MailboxAttrMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MailboxAttrMutation) Fields ¶
func (m *MailboxAttrMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*MailboxAttrMutation) ID ¶
func (m *MailboxAttrMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*MailboxAttrMutation) IDs ¶
func (m *MailboxAttrMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*MailboxAttrMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*MailboxAttrMutation) OldValue ¶
func (m *MailboxAttrMutation) OldValue(ctx context.Context) (v string, err error)
OldValue returns the old "Value" field's value of the MailboxAttr entity. If the MailboxAttr object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxAttrMutation) Op ¶
func (m *MailboxAttrMutation) Op() Op
Op returns the operation name.
func (*MailboxAttrMutation) RemovedEdges ¶
func (m *MailboxAttrMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MailboxAttrMutation) RemovedIDs ¶
func (m *MailboxAttrMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*MailboxAttrMutation) ResetEdge ¶
func (m *MailboxAttrMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*MailboxAttrMutation) ResetField ¶
func (m *MailboxAttrMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxAttrMutation) ResetValue ¶
func (m *MailboxAttrMutation) ResetValue()
ResetValue resets all changes to the "Value" field.
func (*MailboxAttrMutation) SetField ¶
func (m *MailboxAttrMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxAttrMutation) SetValue ¶
func (m *MailboxAttrMutation) SetValue(s string)
SetValue sets the "Value" field.
func (MailboxAttrMutation) Tx ¶
func (m MailboxAttrMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MailboxAttrMutation) Type ¶
func (m *MailboxAttrMutation) Type() string
Type returns the node type of this mutation (MailboxAttr).
func (*MailboxAttrMutation) Value ¶
func (m *MailboxAttrMutation) Value() (r string, exists bool)
Value returns the value of the "Value" field in the mutation.
func (*MailboxAttrMutation) Where ¶
func (m *MailboxAttrMutation) Where(ps ...predicate.MailboxAttr)
Where appends a list predicates to the MailboxAttrMutation builder.
type MailboxAttrQuery ¶
type MailboxAttrQuery struct {
// contains filtered or unexported fields
}
MailboxAttrQuery is the builder for querying MailboxAttr entities.
func (*MailboxAttrQuery) All ¶
func (maq *MailboxAttrQuery) All(ctx context.Context) ([]*MailboxAttr, error)
All executes the query and returns a list of MailboxAttrs.
func (*MailboxAttrQuery) AllX ¶
func (maq *MailboxAttrQuery) AllX(ctx context.Context) []*MailboxAttr
AllX is like All, but panics if an error occurs.
func (*MailboxAttrQuery) Clone ¶
func (maq *MailboxAttrQuery) Clone() *MailboxAttrQuery
Clone returns a duplicate of the MailboxAttrQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MailboxAttrQuery) Count ¶
func (maq *MailboxAttrQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MailboxAttrQuery) CountX ¶
func (maq *MailboxAttrQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MailboxAttrQuery) Exist ¶
func (maq *MailboxAttrQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MailboxAttrQuery) ExistX ¶
func (maq *MailboxAttrQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MailboxAttrQuery) First ¶
func (maq *MailboxAttrQuery) First(ctx context.Context) (*MailboxAttr, error)
First returns the first MailboxAttr entity from the query. Returns a *NotFoundError when no MailboxAttr was found.
func (*MailboxAttrQuery) FirstID ¶
func (maq *MailboxAttrQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first MailboxAttr ID from the query. Returns a *NotFoundError when no MailboxAttr ID was found.
func (*MailboxAttrQuery) FirstIDX ¶
func (maq *MailboxAttrQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*MailboxAttrQuery) FirstX ¶
func (maq *MailboxAttrQuery) FirstX(ctx context.Context) *MailboxAttr
FirstX is like First, but panics if an error occurs.
func (*MailboxAttrQuery) GroupBy ¶
func (maq *MailboxAttrQuery) GroupBy(field string, fields ...string) *MailboxAttrGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Value string `json:"Value,omitempty"` Count int `json:"count,omitempty"` } client.MailboxAttr.Query(). GroupBy(mailboxattr.FieldValue). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MailboxAttrQuery) IDs ¶
func (maq *MailboxAttrQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of MailboxAttr IDs.
func (*MailboxAttrQuery) IDsX ¶
func (maq *MailboxAttrQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*MailboxAttrQuery) Limit ¶
func (maq *MailboxAttrQuery) Limit(limit int) *MailboxAttrQuery
Limit adds a limit step to the query.
func (*MailboxAttrQuery) Offset ¶
func (maq *MailboxAttrQuery) Offset(offset int) *MailboxAttrQuery
Offset adds an offset step to the query.
func (*MailboxAttrQuery) Only ¶
func (maq *MailboxAttrQuery) Only(ctx context.Context) (*MailboxAttr, error)
Only returns a single MailboxAttr entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one MailboxAttr entity is found. Returns a *NotFoundError when no MailboxAttr entities are found.
func (*MailboxAttrQuery) OnlyID ¶
func (maq *MailboxAttrQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only MailboxAttr ID in the query. Returns a *NotSingularError when more than one MailboxAttr ID is found. Returns a *NotFoundError when no entities are found.
func (*MailboxAttrQuery) OnlyIDX ¶
func (maq *MailboxAttrQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MailboxAttrQuery) OnlyX ¶
func (maq *MailboxAttrQuery) OnlyX(ctx context.Context) *MailboxAttr
OnlyX is like Only, but panics if an error occurs.
func (*MailboxAttrQuery) Order ¶
func (maq *MailboxAttrQuery) Order(o ...OrderFunc) *MailboxAttrQuery
Order adds an order step to the query.
func (*MailboxAttrQuery) Select ¶
func (maq *MailboxAttrQuery) Select(fields ...string) *MailboxAttrSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Value string `json:"Value,omitempty"` } client.MailboxAttr.Query(). Select(mailboxattr.FieldValue). Scan(ctx, &v)
func (*MailboxAttrQuery) Unique ¶
func (maq *MailboxAttrQuery) Unique(unique bool) *MailboxAttrQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*MailboxAttrQuery) Where ¶
func (maq *MailboxAttrQuery) Where(ps ...predicate.MailboxAttr) *MailboxAttrQuery
Where adds a new predicate for the MailboxAttrQuery builder.
type MailboxAttrSelect ¶
type MailboxAttrSelect struct { *MailboxAttrQuery // contains filtered or unexported fields }
MailboxAttrSelect is the builder for selecting fields of MailboxAttr entities.
func (*MailboxAttrSelect) Bool ¶
func (mas *MailboxAttrSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) BoolX ¶
func (mas *MailboxAttrSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxAttrSelect) Bools ¶
func (mas *MailboxAttrSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) BoolsX ¶
func (mas *MailboxAttrSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxAttrSelect) Float64 ¶
func (mas *MailboxAttrSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) Float64X ¶
func (mas *MailboxAttrSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxAttrSelect) Float64s ¶
func (mas *MailboxAttrSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) Float64sX ¶
func (mas *MailboxAttrSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxAttrSelect) Int ¶
func (mas *MailboxAttrSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) IntX ¶
func (mas *MailboxAttrSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxAttrSelect) Ints ¶
func (mas *MailboxAttrSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) IntsX ¶
func (mas *MailboxAttrSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxAttrSelect) Scan ¶
func (mas *MailboxAttrSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*MailboxAttrSelect) ScanX ¶
func (mas *MailboxAttrSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxAttrSelect) String ¶
func (mas *MailboxAttrSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*MailboxAttrSelect) StringX ¶
func (mas *MailboxAttrSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxAttrUpdate ¶
type MailboxAttrUpdate struct {
// contains filtered or unexported fields
}
MailboxAttrUpdate is the builder for updating MailboxAttr entities.
func (*MailboxAttrUpdate) Exec ¶
func (mau *MailboxAttrUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxAttrUpdate) ExecX ¶
func (mau *MailboxAttrUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxAttrUpdate) Mutation ¶
func (mau *MailboxAttrUpdate) Mutation() *MailboxAttrMutation
Mutation returns the MailboxAttrMutation object of the builder.
func (*MailboxAttrUpdate) Save ¶
func (mau *MailboxAttrUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MailboxAttrUpdate) SaveX ¶
func (mau *MailboxAttrUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MailboxAttrUpdate) SetValue ¶
func (mau *MailboxAttrUpdate) SetValue(s string) *MailboxAttrUpdate
SetValue sets the "Value" field.
func (*MailboxAttrUpdate) Where ¶
func (mau *MailboxAttrUpdate) Where(ps ...predicate.MailboxAttr) *MailboxAttrUpdate
Where appends a list predicates to the MailboxAttrUpdate builder.
type MailboxAttrUpdateOne ¶
type MailboxAttrUpdateOne struct {
// contains filtered or unexported fields
}
MailboxAttrUpdateOne is the builder for updating a single MailboxAttr entity.
func (*MailboxAttrUpdateOne) Exec ¶
func (mauo *MailboxAttrUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MailboxAttrUpdateOne) ExecX ¶
func (mauo *MailboxAttrUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxAttrUpdateOne) Mutation ¶
func (mauo *MailboxAttrUpdateOne) Mutation() *MailboxAttrMutation
Mutation returns the MailboxAttrMutation object of the builder.
func (*MailboxAttrUpdateOne) Save ¶
func (mauo *MailboxAttrUpdateOne) Save(ctx context.Context) (*MailboxAttr, error)
Save executes the query and returns the updated MailboxAttr entity.
func (*MailboxAttrUpdateOne) SaveX ¶
func (mauo *MailboxAttrUpdateOne) SaveX(ctx context.Context) *MailboxAttr
SaveX is like Save, but panics if an error occurs.
func (*MailboxAttrUpdateOne) Select ¶
func (mauo *MailboxAttrUpdateOne) Select(field string, fields ...string) *MailboxAttrUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MailboxAttrUpdateOne) SetValue ¶
func (mauo *MailboxAttrUpdateOne) SetValue(s string) *MailboxAttrUpdateOne
SetValue sets the "Value" field.
type MailboxAttrs ¶
type MailboxAttrs []*MailboxAttr
MailboxAttrs is a parsable slice of MailboxAttr.
type MailboxClient ¶
type MailboxClient struct {
// contains filtered or unexported fields
}
MailboxClient is a client for the Mailbox schema.
func NewMailboxClient ¶
func NewMailboxClient(c config) *MailboxClient
NewMailboxClient returns a client for the Mailbox from the given config.
func (*MailboxClient) Create ¶
func (c *MailboxClient) Create() *MailboxCreate
Create returns a create builder for Mailbox.
func (*MailboxClient) CreateBulk ¶
func (c *MailboxClient) CreateBulk(builders ...*MailboxCreate) *MailboxCreateBulk
CreateBulk returns a builder for creating a bulk of Mailbox entities.
func (*MailboxClient) Delete ¶
func (c *MailboxClient) Delete() *MailboxDelete
Delete returns a delete builder for Mailbox.
func (*MailboxClient) DeleteOne ¶
func (c *MailboxClient) DeleteOne(m *Mailbox) *MailboxDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*MailboxClient) DeleteOneID ¶
func (c *MailboxClient) DeleteOneID(id int) *MailboxDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*MailboxClient) GetX ¶
func (c *MailboxClient) GetX(ctx context.Context, id int) *Mailbox
GetX is like Get, but panics if an error occurs.
func (*MailboxClient) Hooks ¶
func (c *MailboxClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MailboxClient) Query ¶
func (c *MailboxClient) Query() *MailboxQuery
Query returns a query builder for Mailbox.
func (*MailboxClient) QueryAttributes ¶
func (c *MailboxClient) QueryAttributes(m *Mailbox) *MailboxAttrQuery
QueryAttributes queries the attributes edge of a Mailbox.
func (*MailboxClient) QueryFlags ¶
func (c *MailboxClient) QueryFlags(m *Mailbox) *MailboxFlagQuery
QueryFlags queries the flags edge of a Mailbox.
func (*MailboxClient) QueryPermanentFlags ¶
func (c *MailboxClient) QueryPermanentFlags(m *Mailbox) *MailboxPermFlagQuery
QueryPermanentFlags queries the permanent_flags edge of a Mailbox.
func (*MailboxClient) QueryUIDs ¶
func (c *MailboxClient) QueryUIDs(m *Mailbox) *UIDQuery
QueryUIDs queries the UIDs edge of a Mailbox.
func (*MailboxClient) Update ¶
func (c *MailboxClient) Update() *MailboxUpdate
Update returns an update builder for Mailbox.
func (*MailboxClient) UpdateOne ¶
func (c *MailboxClient) UpdateOne(m *Mailbox) *MailboxUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MailboxClient) UpdateOneID ¶
func (c *MailboxClient) UpdateOneID(id int) *MailboxUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MailboxClient) Use ¶
func (c *MailboxClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `mailbox.Hooks(f(g(h())))`.
type MailboxCreate ¶
type MailboxCreate struct {
// contains filtered or unexported fields
}
MailboxCreate is the builder for creating a Mailbox entity.
func (*MailboxCreate) AddAttributeIDs ¶
func (mc *MailboxCreate) AddAttributeIDs(ids ...int) *MailboxCreate
AddAttributeIDs adds the "attributes" edge to the MailboxAttr entity by IDs.
func (*MailboxCreate) AddAttributes ¶
func (mc *MailboxCreate) AddAttributes(m ...*MailboxAttr) *MailboxCreate
AddAttributes adds the "attributes" edges to the MailboxAttr entity.
func (*MailboxCreate) AddFlagIDs ¶
func (mc *MailboxCreate) AddFlagIDs(ids ...int) *MailboxCreate
AddFlagIDs adds the "flags" edge to the MailboxFlag entity by IDs.
func (*MailboxCreate) AddFlags ¶
func (mc *MailboxCreate) AddFlags(m ...*MailboxFlag) *MailboxCreate
AddFlags adds the "flags" edges to the MailboxFlag entity.
func (*MailboxCreate) AddPermanentFlagIDs ¶
func (mc *MailboxCreate) AddPermanentFlagIDs(ids ...int) *MailboxCreate
AddPermanentFlagIDs adds the "permanent_flags" edge to the MailboxPermFlag entity by IDs.
func (*MailboxCreate) AddPermanentFlags ¶
func (mc *MailboxCreate) AddPermanentFlags(m ...*MailboxPermFlag) *MailboxCreate
AddPermanentFlags adds the "permanent_flags" edges to the MailboxPermFlag entity.
func (*MailboxCreate) AddUIDIDs ¶
func (mc *MailboxCreate) AddUIDIDs(ids ...int) *MailboxCreate
AddUIDIDs adds the "UIDs" edge to the UID entity by IDs.
func (*MailboxCreate) AddUIDs ¶
func (mc *MailboxCreate) AddUIDs(u ...*UID) *MailboxCreate
AddUIDs adds the "UIDs" edges to the UID entity.
func (*MailboxCreate) Exec ¶
func (mc *MailboxCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxCreate) ExecX ¶
func (mc *MailboxCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxCreate) Mutation ¶
func (mc *MailboxCreate) Mutation() *MailboxMutation
Mutation returns the MailboxMutation object of the builder.
func (*MailboxCreate) Save ¶
func (mc *MailboxCreate) Save(ctx context.Context) (*Mailbox, error)
Save creates the Mailbox in the database.
func (*MailboxCreate) SaveX ¶
func (mc *MailboxCreate) SaveX(ctx context.Context) *Mailbox
SaveX calls Save and panics if Save returns an error.
func (*MailboxCreate) SetMailboxID ¶
func (mc *MailboxCreate) SetMailboxID(s string) *MailboxCreate
SetMailboxID sets the "MailboxID" field.
func (*MailboxCreate) SetName ¶
func (mc *MailboxCreate) SetName(s string) *MailboxCreate
SetName sets the "Name" field.
func (*MailboxCreate) SetNillableSubscribed ¶
func (mc *MailboxCreate) SetNillableSubscribed(b *bool) *MailboxCreate
SetNillableSubscribed sets the "Subscribed" field if the given value is not nil.
func (*MailboxCreate) SetNillableUIDNext ¶
func (mc *MailboxCreate) SetNillableUIDNext(i *int) *MailboxCreate
SetNillableUIDNext sets the "UIDNext" field if the given value is not nil.
func (*MailboxCreate) SetNillableUIDValidity ¶
func (mc *MailboxCreate) SetNillableUIDValidity(i *int) *MailboxCreate
SetNillableUIDValidity sets the "UIDValidity" field if the given value is not nil.
func (*MailboxCreate) SetSubscribed ¶
func (mc *MailboxCreate) SetSubscribed(b bool) *MailboxCreate
SetSubscribed sets the "Subscribed" field.
func (*MailboxCreate) SetUIDNext ¶
func (mc *MailboxCreate) SetUIDNext(i int) *MailboxCreate
SetUIDNext sets the "UIDNext" field.
func (*MailboxCreate) SetUIDValidity ¶
func (mc *MailboxCreate) SetUIDValidity(i int) *MailboxCreate
SetUIDValidity sets the "UIDValidity" field.
type MailboxCreateBulk ¶
type MailboxCreateBulk struct {
// contains filtered or unexported fields
}
MailboxCreateBulk is the builder for creating many Mailbox entities in bulk.
func (*MailboxCreateBulk) Exec ¶
func (mcb *MailboxCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxCreateBulk) ExecX ¶
func (mcb *MailboxCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MailboxDelete ¶
type MailboxDelete struct {
// contains filtered or unexported fields
}
MailboxDelete is the builder for deleting a Mailbox entity.
func (*MailboxDelete) Exec ¶
func (md *MailboxDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MailboxDelete) ExecX ¶
func (md *MailboxDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MailboxDelete) Where ¶
func (md *MailboxDelete) Where(ps ...predicate.Mailbox) *MailboxDelete
Where appends a list predicates to the MailboxDelete builder.
type MailboxDeleteOne ¶
type MailboxDeleteOne struct {
// contains filtered or unexported fields
}
MailboxDeleteOne is the builder for deleting a single Mailbox entity.
func (*MailboxDeleteOne) Exec ¶
func (mdo *MailboxDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MailboxDeleteOne) ExecX ¶
func (mdo *MailboxDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MailboxEdges ¶
type MailboxEdges struct { // UIDs holds the value of the UIDs edge. UIDs []*UID `json:"UIDs,omitempty"` // Flags holds the value of the flags edge. Flags []*MailboxFlag `json:"flags,omitempty"` // PermanentFlags holds the value of the permanent_flags edge. PermanentFlags []*MailboxPermFlag `json:"permanent_flags,omitempty"` // Attributes holds the value of the attributes edge. Attributes []*MailboxAttr `json:"attributes,omitempty"` // contains filtered or unexported fields }
MailboxEdges holds the relations/edges for other nodes in the graph.
func (MailboxEdges) AttributesOrErr ¶
func (e MailboxEdges) AttributesOrErr() ([]*MailboxAttr, error)
AttributesOrErr returns the Attributes value or an error if the edge was not loaded in eager-loading.
func (MailboxEdges) FlagsOrErr ¶
func (e MailboxEdges) FlagsOrErr() ([]*MailboxFlag, error)
FlagsOrErr returns the Flags value or an error if the edge was not loaded in eager-loading.
func (MailboxEdges) PermanentFlagsOrErr ¶
func (e MailboxEdges) PermanentFlagsOrErr() ([]*MailboxPermFlag, error)
PermanentFlagsOrErr returns the PermanentFlags value or an error if the edge was not loaded in eager-loading.
func (MailboxEdges) UIDsOrErr ¶
func (e MailboxEdges) UIDsOrErr() ([]*UID, error)
UIDsOrErr returns the UIDs value or an error if the edge was not loaded in eager-loading.
type MailboxFlag ¶
type MailboxFlag struct { // ID of the ent. ID int `json:"id,omitempty"` // Value holds the value of the "Value" field. Value string `json:"Value,omitempty"` // contains filtered or unexported fields }
MailboxFlag is the model entity for the MailboxFlag schema.
func (*MailboxFlag) String ¶
func (mf *MailboxFlag) String() string
String implements the fmt.Stringer.
func (*MailboxFlag) Unwrap ¶
func (mf *MailboxFlag) Unwrap() *MailboxFlag
Unwrap unwraps the MailboxFlag entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*MailboxFlag) Update ¶
func (mf *MailboxFlag) Update() *MailboxFlagUpdateOne
Update returns a builder for updating this MailboxFlag. Note that you need to call MailboxFlag.Unwrap() before calling this method if this MailboxFlag was returned from a transaction, and the transaction was committed or rolled back.
type MailboxFlagClient ¶
type MailboxFlagClient struct {
// contains filtered or unexported fields
}
MailboxFlagClient is a client for the MailboxFlag schema.
func NewMailboxFlagClient ¶
func NewMailboxFlagClient(c config) *MailboxFlagClient
NewMailboxFlagClient returns a client for the MailboxFlag from the given config.
func (*MailboxFlagClient) Create ¶
func (c *MailboxFlagClient) Create() *MailboxFlagCreate
Create returns a create builder for MailboxFlag.
func (*MailboxFlagClient) CreateBulk ¶
func (c *MailboxFlagClient) CreateBulk(builders ...*MailboxFlagCreate) *MailboxFlagCreateBulk
CreateBulk returns a builder for creating a bulk of MailboxFlag entities.
func (*MailboxFlagClient) Delete ¶
func (c *MailboxFlagClient) Delete() *MailboxFlagDelete
Delete returns a delete builder for MailboxFlag.
func (*MailboxFlagClient) DeleteOne ¶
func (c *MailboxFlagClient) DeleteOne(mf *MailboxFlag) *MailboxFlagDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*MailboxFlagClient) DeleteOneID ¶
func (c *MailboxFlagClient) DeleteOneID(id int) *MailboxFlagDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*MailboxFlagClient) Get ¶
func (c *MailboxFlagClient) Get(ctx context.Context, id int) (*MailboxFlag, error)
Get returns a MailboxFlag entity by its id.
func (*MailboxFlagClient) GetX ¶
func (c *MailboxFlagClient) GetX(ctx context.Context, id int) *MailboxFlag
GetX is like Get, but panics if an error occurs.
func (*MailboxFlagClient) Hooks ¶
func (c *MailboxFlagClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MailboxFlagClient) Query ¶
func (c *MailboxFlagClient) Query() *MailboxFlagQuery
Query returns a query builder for MailboxFlag.
func (*MailboxFlagClient) Update ¶
func (c *MailboxFlagClient) Update() *MailboxFlagUpdate
Update returns an update builder for MailboxFlag.
func (*MailboxFlagClient) UpdateOne ¶
func (c *MailboxFlagClient) UpdateOne(mf *MailboxFlag) *MailboxFlagUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MailboxFlagClient) UpdateOneID ¶
func (c *MailboxFlagClient) UpdateOneID(id int) *MailboxFlagUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MailboxFlagClient) Use ¶
func (c *MailboxFlagClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `mailboxflag.Hooks(f(g(h())))`.
type MailboxFlagCreate ¶
type MailboxFlagCreate struct {
// contains filtered or unexported fields
}
MailboxFlagCreate is the builder for creating a MailboxFlag entity.
func (*MailboxFlagCreate) Exec ¶
func (mfc *MailboxFlagCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxFlagCreate) ExecX ¶
func (mfc *MailboxFlagCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxFlagCreate) Mutation ¶
func (mfc *MailboxFlagCreate) Mutation() *MailboxFlagMutation
Mutation returns the MailboxFlagMutation object of the builder.
func (*MailboxFlagCreate) Save ¶
func (mfc *MailboxFlagCreate) Save(ctx context.Context) (*MailboxFlag, error)
Save creates the MailboxFlag in the database.
func (*MailboxFlagCreate) SaveX ¶
func (mfc *MailboxFlagCreate) SaveX(ctx context.Context) *MailboxFlag
SaveX calls Save and panics if Save returns an error.
func (*MailboxFlagCreate) SetValue ¶
func (mfc *MailboxFlagCreate) SetValue(s string) *MailboxFlagCreate
SetValue sets the "Value" field.
type MailboxFlagCreateBulk ¶
type MailboxFlagCreateBulk struct {
// contains filtered or unexported fields
}
MailboxFlagCreateBulk is the builder for creating many MailboxFlag entities in bulk.
func (*MailboxFlagCreateBulk) Exec ¶
func (mfcb *MailboxFlagCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxFlagCreateBulk) ExecX ¶
func (mfcb *MailboxFlagCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxFlagCreateBulk) Save ¶
func (mfcb *MailboxFlagCreateBulk) Save(ctx context.Context) ([]*MailboxFlag, error)
Save creates the MailboxFlag entities in the database.
func (*MailboxFlagCreateBulk) SaveX ¶
func (mfcb *MailboxFlagCreateBulk) SaveX(ctx context.Context) []*MailboxFlag
SaveX is like Save, but panics if an error occurs.
type MailboxFlagDelete ¶
type MailboxFlagDelete struct {
// contains filtered or unexported fields
}
MailboxFlagDelete is the builder for deleting a MailboxFlag entity.
func (*MailboxFlagDelete) Exec ¶
func (mfd *MailboxFlagDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MailboxFlagDelete) ExecX ¶
func (mfd *MailboxFlagDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MailboxFlagDelete) Where ¶
func (mfd *MailboxFlagDelete) Where(ps ...predicate.MailboxFlag) *MailboxFlagDelete
Where appends a list predicates to the MailboxFlagDelete builder.
type MailboxFlagDeleteOne ¶
type MailboxFlagDeleteOne struct {
// contains filtered or unexported fields
}
MailboxFlagDeleteOne is the builder for deleting a single MailboxFlag entity.
func (*MailboxFlagDeleteOne) Exec ¶
func (mfdo *MailboxFlagDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MailboxFlagDeleteOne) ExecX ¶
func (mfdo *MailboxFlagDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MailboxFlagGroupBy ¶
type MailboxFlagGroupBy struct {
// contains filtered or unexported fields
}
MailboxFlagGroupBy is the group-by builder for MailboxFlag entities.
func (*MailboxFlagGroupBy) Aggregate ¶
func (mfgb *MailboxFlagGroupBy) Aggregate(fns ...AggregateFunc) *MailboxFlagGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MailboxFlagGroupBy) Bool ¶
func (mfgb *MailboxFlagGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) BoolX ¶
func (mfgb *MailboxFlagGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxFlagGroupBy) Bools ¶
func (mfgb *MailboxFlagGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) BoolsX ¶
func (mfgb *MailboxFlagGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxFlagGroupBy) Float64 ¶
func (mfgb *MailboxFlagGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) Float64X ¶
func (mfgb *MailboxFlagGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxFlagGroupBy) Float64s ¶
func (mfgb *MailboxFlagGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) Float64sX ¶
func (mfgb *MailboxFlagGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxFlagGroupBy) Int ¶
func (mfgb *MailboxFlagGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) IntX ¶
func (mfgb *MailboxFlagGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxFlagGroupBy) Ints ¶
func (mfgb *MailboxFlagGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) IntsX ¶
func (mfgb *MailboxFlagGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxFlagGroupBy) Scan ¶
func (mfgb *MailboxFlagGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*MailboxFlagGroupBy) ScanX ¶
func (mfgb *MailboxFlagGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxFlagGroupBy) String ¶
func (mfgb *MailboxFlagGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxFlagGroupBy) StringX ¶
func (mfgb *MailboxFlagGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxFlagMutation ¶
type MailboxFlagMutation struct {
// contains filtered or unexported fields
}
MailboxFlagMutation represents an operation that mutates the MailboxFlag nodes in the graph.
func (*MailboxFlagMutation) AddField ¶
func (m *MailboxFlagMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxFlagMutation) AddedEdges ¶
func (m *MailboxFlagMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MailboxFlagMutation) AddedField ¶
func (m *MailboxFlagMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxFlagMutation) AddedFields ¶
func (m *MailboxFlagMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MailboxFlagMutation) AddedIDs ¶
func (m *MailboxFlagMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MailboxFlagMutation) ClearEdge ¶
func (m *MailboxFlagMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*MailboxFlagMutation) ClearField ¶
func (m *MailboxFlagMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxFlagMutation) ClearedEdges ¶
func (m *MailboxFlagMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MailboxFlagMutation) ClearedFields ¶
func (m *MailboxFlagMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MailboxFlagMutation) Client ¶
func (m MailboxFlagMutation) 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 (*MailboxFlagMutation) EdgeCleared ¶
func (m *MailboxFlagMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MailboxFlagMutation) Field ¶
func (m *MailboxFlagMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxFlagMutation) FieldCleared ¶
func (m *MailboxFlagMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MailboxFlagMutation) Fields ¶
func (m *MailboxFlagMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*MailboxFlagMutation) ID ¶
func (m *MailboxFlagMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*MailboxFlagMutation) IDs ¶
func (m *MailboxFlagMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*MailboxFlagMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*MailboxFlagMutation) OldValue ¶
func (m *MailboxFlagMutation) OldValue(ctx context.Context) (v string, err error)
OldValue returns the old "Value" field's value of the MailboxFlag entity. If the MailboxFlag object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxFlagMutation) Op ¶
func (m *MailboxFlagMutation) Op() Op
Op returns the operation name.
func (*MailboxFlagMutation) RemovedEdges ¶
func (m *MailboxFlagMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MailboxFlagMutation) RemovedIDs ¶
func (m *MailboxFlagMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*MailboxFlagMutation) ResetEdge ¶
func (m *MailboxFlagMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*MailboxFlagMutation) ResetField ¶
func (m *MailboxFlagMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxFlagMutation) ResetValue ¶
func (m *MailboxFlagMutation) ResetValue()
ResetValue resets all changes to the "Value" field.
func (*MailboxFlagMutation) SetField ¶
func (m *MailboxFlagMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxFlagMutation) SetValue ¶
func (m *MailboxFlagMutation) SetValue(s string)
SetValue sets the "Value" field.
func (MailboxFlagMutation) Tx ¶
func (m MailboxFlagMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MailboxFlagMutation) Type ¶
func (m *MailboxFlagMutation) Type() string
Type returns the node type of this mutation (MailboxFlag).
func (*MailboxFlagMutation) Value ¶
func (m *MailboxFlagMutation) Value() (r string, exists bool)
Value returns the value of the "Value" field in the mutation.
func (*MailboxFlagMutation) Where ¶
func (m *MailboxFlagMutation) Where(ps ...predicate.MailboxFlag)
Where appends a list predicates to the MailboxFlagMutation builder.
type MailboxFlagQuery ¶
type MailboxFlagQuery struct {
// contains filtered or unexported fields
}
MailboxFlagQuery is the builder for querying MailboxFlag entities.
func (*MailboxFlagQuery) All ¶
func (mfq *MailboxFlagQuery) All(ctx context.Context) ([]*MailboxFlag, error)
All executes the query and returns a list of MailboxFlags.
func (*MailboxFlagQuery) AllX ¶
func (mfq *MailboxFlagQuery) AllX(ctx context.Context) []*MailboxFlag
AllX is like All, but panics if an error occurs.
func (*MailboxFlagQuery) Clone ¶
func (mfq *MailboxFlagQuery) Clone() *MailboxFlagQuery
Clone returns a duplicate of the MailboxFlagQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MailboxFlagQuery) Count ¶
func (mfq *MailboxFlagQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MailboxFlagQuery) CountX ¶
func (mfq *MailboxFlagQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MailboxFlagQuery) Exist ¶
func (mfq *MailboxFlagQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MailboxFlagQuery) ExistX ¶
func (mfq *MailboxFlagQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MailboxFlagQuery) First ¶
func (mfq *MailboxFlagQuery) First(ctx context.Context) (*MailboxFlag, error)
First returns the first MailboxFlag entity from the query. Returns a *NotFoundError when no MailboxFlag was found.
func (*MailboxFlagQuery) FirstID ¶
func (mfq *MailboxFlagQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first MailboxFlag ID from the query. Returns a *NotFoundError when no MailboxFlag ID was found.
func (*MailboxFlagQuery) FirstIDX ¶
func (mfq *MailboxFlagQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*MailboxFlagQuery) FirstX ¶
func (mfq *MailboxFlagQuery) FirstX(ctx context.Context) *MailboxFlag
FirstX is like First, but panics if an error occurs.
func (*MailboxFlagQuery) GroupBy ¶
func (mfq *MailboxFlagQuery) GroupBy(field string, fields ...string) *MailboxFlagGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Value string `json:"Value,omitempty"` Count int `json:"count,omitempty"` } client.MailboxFlag.Query(). GroupBy(mailboxflag.FieldValue). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MailboxFlagQuery) IDs ¶
func (mfq *MailboxFlagQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of MailboxFlag IDs.
func (*MailboxFlagQuery) IDsX ¶
func (mfq *MailboxFlagQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*MailboxFlagQuery) Limit ¶
func (mfq *MailboxFlagQuery) Limit(limit int) *MailboxFlagQuery
Limit adds a limit step to the query.
func (*MailboxFlagQuery) Offset ¶
func (mfq *MailboxFlagQuery) Offset(offset int) *MailboxFlagQuery
Offset adds an offset step to the query.
func (*MailboxFlagQuery) Only ¶
func (mfq *MailboxFlagQuery) Only(ctx context.Context) (*MailboxFlag, error)
Only returns a single MailboxFlag entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one MailboxFlag entity is found. Returns a *NotFoundError when no MailboxFlag entities are found.
func (*MailboxFlagQuery) OnlyID ¶
func (mfq *MailboxFlagQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only MailboxFlag ID in the query. Returns a *NotSingularError when more than one MailboxFlag ID is found. Returns a *NotFoundError when no entities are found.
func (*MailboxFlagQuery) OnlyIDX ¶
func (mfq *MailboxFlagQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MailboxFlagQuery) OnlyX ¶
func (mfq *MailboxFlagQuery) OnlyX(ctx context.Context) *MailboxFlag
OnlyX is like Only, but panics if an error occurs.
func (*MailboxFlagQuery) Order ¶
func (mfq *MailboxFlagQuery) Order(o ...OrderFunc) *MailboxFlagQuery
Order adds an order step to the query.
func (*MailboxFlagQuery) Select ¶
func (mfq *MailboxFlagQuery) Select(fields ...string) *MailboxFlagSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Value string `json:"Value,omitempty"` } client.MailboxFlag.Query(). Select(mailboxflag.FieldValue). Scan(ctx, &v)
func (*MailboxFlagQuery) Unique ¶
func (mfq *MailboxFlagQuery) Unique(unique bool) *MailboxFlagQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*MailboxFlagQuery) Where ¶
func (mfq *MailboxFlagQuery) Where(ps ...predicate.MailboxFlag) *MailboxFlagQuery
Where adds a new predicate for the MailboxFlagQuery builder.
type MailboxFlagSelect ¶
type MailboxFlagSelect struct { *MailboxFlagQuery // contains filtered or unexported fields }
MailboxFlagSelect is the builder for selecting fields of MailboxFlag entities.
func (*MailboxFlagSelect) Bool ¶
func (mfs *MailboxFlagSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) BoolX ¶
func (mfs *MailboxFlagSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxFlagSelect) Bools ¶
func (mfs *MailboxFlagSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) BoolsX ¶
func (mfs *MailboxFlagSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxFlagSelect) Float64 ¶
func (mfs *MailboxFlagSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) Float64X ¶
func (mfs *MailboxFlagSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxFlagSelect) Float64s ¶
func (mfs *MailboxFlagSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) Float64sX ¶
func (mfs *MailboxFlagSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxFlagSelect) Int ¶
func (mfs *MailboxFlagSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) IntX ¶
func (mfs *MailboxFlagSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxFlagSelect) Ints ¶
func (mfs *MailboxFlagSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) IntsX ¶
func (mfs *MailboxFlagSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxFlagSelect) Scan ¶
func (mfs *MailboxFlagSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*MailboxFlagSelect) ScanX ¶
func (mfs *MailboxFlagSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxFlagSelect) String ¶
func (mfs *MailboxFlagSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*MailboxFlagSelect) StringX ¶
func (mfs *MailboxFlagSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxFlagUpdate ¶
type MailboxFlagUpdate struct {
// contains filtered or unexported fields
}
MailboxFlagUpdate is the builder for updating MailboxFlag entities.
func (*MailboxFlagUpdate) Exec ¶
func (mfu *MailboxFlagUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxFlagUpdate) ExecX ¶
func (mfu *MailboxFlagUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxFlagUpdate) Mutation ¶
func (mfu *MailboxFlagUpdate) Mutation() *MailboxFlagMutation
Mutation returns the MailboxFlagMutation object of the builder.
func (*MailboxFlagUpdate) Save ¶
func (mfu *MailboxFlagUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MailboxFlagUpdate) SaveX ¶
func (mfu *MailboxFlagUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MailboxFlagUpdate) SetValue ¶
func (mfu *MailboxFlagUpdate) SetValue(s string) *MailboxFlagUpdate
SetValue sets the "Value" field.
func (*MailboxFlagUpdate) Where ¶
func (mfu *MailboxFlagUpdate) Where(ps ...predicate.MailboxFlag) *MailboxFlagUpdate
Where appends a list predicates to the MailboxFlagUpdate builder.
type MailboxFlagUpdateOne ¶
type MailboxFlagUpdateOne struct {
// contains filtered or unexported fields
}
MailboxFlagUpdateOne is the builder for updating a single MailboxFlag entity.
func (*MailboxFlagUpdateOne) Exec ¶
func (mfuo *MailboxFlagUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MailboxFlagUpdateOne) ExecX ¶
func (mfuo *MailboxFlagUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxFlagUpdateOne) Mutation ¶
func (mfuo *MailboxFlagUpdateOne) Mutation() *MailboxFlagMutation
Mutation returns the MailboxFlagMutation object of the builder.
func (*MailboxFlagUpdateOne) Save ¶
func (mfuo *MailboxFlagUpdateOne) Save(ctx context.Context) (*MailboxFlag, error)
Save executes the query and returns the updated MailboxFlag entity.
func (*MailboxFlagUpdateOne) SaveX ¶
func (mfuo *MailboxFlagUpdateOne) SaveX(ctx context.Context) *MailboxFlag
SaveX is like Save, but panics if an error occurs.
func (*MailboxFlagUpdateOne) Select ¶
func (mfuo *MailboxFlagUpdateOne) Select(field string, fields ...string) *MailboxFlagUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MailboxFlagUpdateOne) SetValue ¶
func (mfuo *MailboxFlagUpdateOne) SetValue(s string) *MailboxFlagUpdateOne
SetValue sets the "Value" field.
type MailboxFlags ¶
type MailboxFlags []*MailboxFlag
MailboxFlags is a parsable slice of MailboxFlag.
type MailboxGroupBy ¶
type MailboxGroupBy struct {
// contains filtered or unexported fields
}
MailboxGroupBy is the group-by builder for Mailbox entities.
func (*MailboxGroupBy) Aggregate ¶
func (mgb *MailboxGroupBy) Aggregate(fns ...AggregateFunc) *MailboxGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MailboxGroupBy) Bool ¶
func (mgb *MailboxGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) BoolX ¶
func (mgb *MailboxGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxGroupBy) Bools ¶
func (mgb *MailboxGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) BoolsX ¶
func (mgb *MailboxGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxGroupBy) Float64 ¶
func (mgb *MailboxGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) Float64X ¶
func (mgb *MailboxGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxGroupBy) Float64s ¶
func (mgb *MailboxGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) Float64sX ¶
func (mgb *MailboxGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxGroupBy) Int ¶
func (mgb *MailboxGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) IntX ¶
func (mgb *MailboxGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxGroupBy) Ints ¶
func (mgb *MailboxGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) IntsX ¶
func (mgb *MailboxGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxGroupBy) Scan ¶
func (mgb *MailboxGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*MailboxGroupBy) ScanX ¶
func (mgb *MailboxGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxGroupBy) String ¶
func (mgb *MailboxGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxGroupBy) StringX ¶
func (mgb *MailboxGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxMutation ¶
type MailboxMutation struct {
// contains filtered or unexported fields
}
MailboxMutation represents an operation that mutates the Mailbox nodes in the graph.
func (*MailboxMutation) AddAttributeIDs ¶
func (m *MailboxMutation) AddAttributeIDs(ids ...int)
AddAttributeIDs adds the "attributes" edge to the MailboxAttr entity by ids.
func (*MailboxMutation) AddField ¶
func (m *MailboxMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxMutation) AddFlagIDs ¶
func (m *MailboxMutation) AddFlagIDs(ids ...int)
AddFlagIDs adds the "flags" edge to the MailboxFlag entity by ids.
func (*MailboxMutation) AddPermanentFlagIDs ¶
func (m *MailboxMutation) AddPermanentFlagIDs(ids ...int)
AddPermanentFlagIDs adds the "permanent_flags" edge to the MailboxPermFlag entity by ids.
func (*MailboxMutation) AddUIDIDs ¶
func (m *MailboxMutation) AddUIDIDs(ids ...int)
AddUIDIDs adds the "UIDs" edge to the UID entity by ids.
func (*MailboxMutation) AddUIDNext ¶
func (m *MailboxMutation) AddUIDNext(i int)
AddUIDNext adds i to the "UIDNext" field.
func (*MailboxMutation) AddUIDValidity ¶
func (m *MailboxMutation) AddUIDValidity(i int)
AddUIDValidity adds i to the "UIDValidity" field.
func (*MailboxMutation) AddedEdges ¶
func (m *MailboxMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MailboxMutation) AddedField ¶
func (m *MailboxMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxMutation) AddedFields ¶
func (m *MailboxMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MailboxMutation) AddedIDs ¶
func (m *MailboxMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MailboxMutation) AddedUIDNext ¶
func (m *MailboxMutation) AddedUIDNext() (r int, exists bool)
AddedUIDNext returns the value that was added to the "UIDNext" field in this mutation.
func (*MailboxMutation) AddedUIDValidity ¶
func (m *MailboxMutation) AddedUIDValidity() (r int, exists bool)
AddedUIDValidity returns the value that was added to the "UIDValidity" field in this mutation.
func (*MailboxMutation) AttributesCleared ¶
func (m *MailboxMutation) AttributesCleared() bool
AttributesCleared reports if the "attributes" edge to the MailboxAttr entity was cleared.
func (*MailboxMutation) AttributesIDs ¶
func (m *MailboxMutation) AttributesIDs() (ids []int)
AttributesIDs returns the "attributes" edge IDs in the mutation.
func (*MailboxMutation) ClearAttributes ¶
func (m *MailboxMutation) ClearAttributes()
ClearAttributes clears the "attributes" edge to the MailboxAttr entity.
func (*MailboxMutation) ClearEdge ¶
func (m *MailboxMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*MailboxMutation) ClearField ¶
func (m *MailboxMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxMutation) ClearFlags ¶
func (m *MailboxMutation) ClearFlags()
ClearFlags clears the "flags" edge to the MailboxFlag entity.
func (*MailboxMutation) ClearPermanentFlags ¶
func (m *MailboxMutation) ClearPermanentFlags()
ClearPermanentFlags clears the "permanent_flags" edge to the MailboxPermFlag entity.
func (*MailboxMutation) ClearUIDs ¶
func (m *MailboxMutation) ClearUIDs()
ClearUIDs clears the "UIDs" edge to the UID entity.
func (*MailboxMutation) ClearedEdges ¶
func (m *MailboxMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MailboxMutation) ClearedFields ¶
func (m *MailboxMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MailboxMutation) Client ¶
func (m MailboxMutation) 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 (*MailboxMutation) EdgeCleared ¶
func (m *MailboxMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MailboxMutation) Field ¶
func (m *MailboxMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxMutation) FieldCleared ¶
func (m *MailboxMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MailboxMutation) Fields ¶
func (m *MailboxMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*MailboxMutation) FlagsCleared ¶
func (m *MailboxMutation) FlagsCleared() bool
FlagsCleared reports if the "flags" edge to the MailboxFlag entity was cleared.
func (*MailboxMutation) FlagsIDs ¶
func (m *MailboxMutation) FlagsIDs() (ids []int)
FlagsIDs returns the "flags" edge IDs in the mutation.
func (*MailboxMutation) ID ¶
func (m *MailboxMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*MailboxMutation) IDs ¶
func (m *MailboxMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*MailboxMutation) MailboxID ¶
func (m *MailboxMutation) MailboxID() (r string, exists bool)
MailboxID returns the value of the "MailboxID" field in the mutation.
func (*MailboxMutation) Name ¶
func (m *MailboxMutation) Name() (r string, exists bool)
Name returns the value of the "Name" field in the mutation.
func (*MailboxMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*MailboxMutation) OldMailboxID ¶
func (m *MailboxMutation) OldMailboxID(ctx context.Context) (v string, err error)
OldMailboxID returns the old "MailboxID" field's value of the Mailbox entity. If the Mailbox object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxMutation) OldName ¶
func (m *MailboxMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "Name" field's value of the Mailbox entity. If the Mailbox object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxMutation) OldSubscribed ¶
func (m *MailboxMutation) OldSubscribed(ctx context.Context) (v bool, err error)
OldSubscribed returns the old "Subscribed" field's value of the Mailbox entity. If the Mailbox object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxMutation) OldUIDNext ¶
func (m *MailboxMutation) OldUIDNext(ctx context.Context) (v int, err error)
OldUIDNext returns the old "UIDNext" field's value of the Mailbox entity. If the Mailbox object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxMutation) OldUIDValidity ¶
func (m *MailboxMutation) OldUIDValidity(ctx context.Context) (v int, err error)
OldUIDValidity returns the old "UIDValidity" field's value of the Mailbox entity. If the Mailbox object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxMutation) PermanentFlagsCleared ¶
func (m *MailboxMutation) PermanentFlagsCleared() bool
PermanentFlagsCleared reports if the "permanent_flags" edge to the MailboxPermFlag entity was cleared.
func (*MailboxMutation) PermanentFlagsIDs ¶
func (m *MailboxMutation) PermanentFlagsIDs() (ids []int)
PermanentFlagsIDs returns the "permanent_flags" edge IDs in the mutation.
func (*MailboxMutation) RemoveAttributeIDs ¶
func (m *MailboxMutation) RemoveAttributeIDs(ids ...int)
RemoveAttributeIDs removes the "attributes" edge to the MailboxAttr entity by IDs.
func (*MailboxMutation) RemoveFlagIDs ¶
func (m *MailboxMutation) RemoveFlagIDs(ids ...int)
RemoveFlagIDs removes the "flags" edge to the MailboxFlag entity by IDs.
func (*MailboxMutation) RemovePermanentFlagIDs ¶
func (m *MailboxMutation) RemovePermanentFlagIDs(ids ...int)
RemovePermanentFlagIDs removes the "permanent_flags" edge to the MailboxPermFlag entity by IDs.
func (*MailboxMutation) RemoveUIDIDs ¶
func (m *MailboxMutation) RemoveUIDIDs(ids ...int)
RemoveUIDIDs removes the "UIDs" edge to the UID entity by IDs.
func (*MailboxMutation) RemovedAttributesIDs ¶
func (m *MailboxMutation) RemovedAttributesIDs() (ids []int)
RemovedAttributes returns the removed IDs of the "attributes" edge to the MailboxAttr entity.
func (*MailboxMutation) RemovedEdges ¶
func (m *MailboxMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MailboxMutation) RemovedFlagsIDs ¶
func (m *MailboxMutation) RemovedFlagsIDs() (ids []int)
RemovedFlags returns the removed IDs of the "flags" edge to the MailboxFlag entity.
func (*MailboxMutation) RemovedIDs ¶
func (m *MailboxMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*MailboxMutation) RemovedPermanentFlagsIDs ¶
func (m *MailboxMutation) RemovedPermanentFlagsIDs() (ids []int)
RemovedPermanentFlags returns the removed IDs of the "permanent_flags" edge to the MailboxPermFlag entity.
func (*MailboxMutation) RemovedUIDsIDs ¶
func (m *MailboxMutation) RemovedUIDsIDs() (ids []int)
RemovedUIDs returns the removed IDs of the "UIDs" edge to the UID entity.
func (*MailboxMutation) ResetAttributes ¶
func (m *MailboxMutation) ResetAttributes()
ResetAttributes resets all changes to the "attributes" edge.
func (*MailboxMutation) ResetEdge ¶
func (m *MailboxMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*MailboxMutation) ResetField ¶
func (m *MailboxMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxMutation) ResetFlags ¶
func (m *MailboxMutation) ResetFlags()
ResetFlags resets all changes to the "flags" edge.
func (*MailboxMutation) ResetMailboxID ¶
func (m *MailboxMutation) ResetMailboxID()
ResetMailboxID resets all changes to the "MailboxID" field.
func (*MailboxMutation) ResetName ¶
func (m *MailboxMutation) ResetName()
ResetName resets all changes to the "Name" field.
func (*MailboxMutation) ResetPermanentFlags ¶
func (m *MailboxMutation) ResetPermanentFlags()
ResetPermanentFlags resets all changes to the "permanent_flags" edge.
func (*MailboxMutation) ResetSubscribed ¶
func (m *MailboxMutation) ResetSubscribed()
ResetSubscribed resets all changes to the "Subscribed" field.
func (*MailboxMutation) ResetUIDNext ¶
func (m *MailboxMutation) ResetUIDNext()
ResetUIDNext resets all changes to the "UIDNext" field.
func (*MailboxMutation) ResetUIDValidity ¶
func (m *MailboxMutation) ResetUIDValidity()
ResetUIDValidity resets all changes to the "UIDValidity" field.
func (*MailboxMutation) ResetUIDs ¶
func (m *MailboxMutation) ResetUIDs()
ResetUIDs resets all changes to the "UIDs" edge.
func (*MailboxMutation) SetField ¶
func (m *MailboxMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxMutation) SetMailboxID ¶
func (m *MailboxMutation) SetMailboxID(s string)
SetMailboxID sets the "MailboxID" field.
func (*MailboxMutation) SetName ¶
func (m *MailboxMutation) SetName(s string)
SetName sets the "Name" field.
func (*MailboxMutation) SetSubscribed ¶
func (m *MailboxMutation) SetSubscribed(b bool)
SetSubscribed sets the "Subscribed" field.
func (*MailboxMutation) SetUIDNext ¶
func (m *MailboxMutation) SetUIDNext(i int)
SetUIDNext sets the "UIDNext" field.
func (*MailboxMutation) SetUIDValidity ¶
func (m *MailboxMutation) SetUIDValidity(i int)
SetUIDValidity sets the "UIDValidity" field.
func (*MailboxMutation) Subscribed ¶
func (m *MailboxMutation) Subscribed() (r bool, exists bool)
Subscribed returns the value of the "Subscribed" field in the mutation.
func (MailboxMutation) Tx ¶
func (m MailboxMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MailboxMutation) Type ¶
func (m *MailboxMutation) Type() string
Type returns the node type of this mutation (Mailbox).
func (*MailboxMutation) UIDNext ¶
func (m *MailboxMutation) UIDNext() (r int, exists bool)
UIDNext returns the value of the "UIDNext" field in the mutation.
func (*MailboxMutation) UIDValidity ¶
func (m *MailboxMutation) UIDValidity() (r int, exists bool)
UIDValidity returns the value of the "UIDValidity" field in the mutation.
func (*MailboxMutation) UIDsCleared ¶
func (m *MailboxMutation) UIDsCleared() bool
UIDsCleared reports if the "UIDs" edge to the UID entity was cleared.
func (*MailboxMutation) UIDsIDs ¶
func (m *MailboxMutation) UIDsIDs() (ids []int)
UIDsIDs returns the "UIDs" edge IDs in the mutation.
func (*MailboxMutation) Where ¶
func (m *MailboxMutation) Where(ps ...predicate.Mailbox)
Where appends a list predicates to the MailboxMutation builder.
type MailboxPermFlag ¶
type MailboxPermFlag struct { // ID of the ent. ID int `json:"id,omitempty"` // Value holds the value of the "Value" field. Value string `json:"Value,omitempty"` // contains filtered or unexported fields }
MailboxPermFlag is the model entity for the MailboxPermFlag schema.
func (*MailboxPermFlag) String ¶
func (mpf *MailboxPermFlag) String() string
String implements the fmt.Stringer.
func (*MailboxPermFlag) Unwrap ¶
func (mpf *MailboxPermFlag) Unwrap() *MailboxPermFlag
Unwrap unwraps the MailboxPermFlag entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*MailboxPermFlag) Update ¶
func (mpf *MailboxPermFlag) Update() *MailboxPermFlagUpdateOne
Update returns a builder for updating this MailboxPermFlag. Note that you need to call MailboxPermFlag.Unwrap() before calling this method if this MailboxPermFlag was returned from a transaction, and the transaction was committed or rolled back.
type MailboxPermFlagClient ¶
type MailboxPermFlagClient struct {
// contains filtered or unexported fields
}
MailboxPermFlagClient is a client for the MailboxPermFlag schema.
func NewMailboxPermFlagClient ¶
func NewMailboxPermFlagClient(c config) *MailboxPermFlagClient
NewMailboxPermFlagClient returns a client for the MailboxPermFlag from the given config.
func (*MailboxPermFlagClient) Create ¶
func (c *MailboxPermFlagClient) Create() *MailboxPermFlagCreate
Create returns a create builder for MailboxPermFlag.
func (*MailboxPermFlagClient) CreateBulk ¶
func (c *MailboxPermFlagClient) CreateBulk(builders ...*MailboxPermFlagCreate) *MailboxPermFlagCreateBulk
CreateBulk returns a builder for creating a bulk of MailboxPermFlag entities.
func (*MailboxPermFlagClient) Delete ¶
func (c *MailboxPermFlagClient) Delete() *MailboxPermFlagDelete
Delete returns a delete builder for MailboxPermFlag.
func (*MailboxPermFlagClient) DeleteOne ¶
func (c *MailboxPermFlagClient) DeleteOne(mpf *MailboxPermFlag) *MailboxPermFlagDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*MailboxPermFlagClient) DeleteOneID ¶
func (c *MailboxPermFlagClient) DeleteOneID(id int) *MailboxPermFlagDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*MailboxPermFlagClient) Get ¶
func (c *MailboxPermFlagClient) Get(ctx context.Context, id int) (*MailboxPermFlag, error)
Get returns a MailboxPermFlag entity by its id.
func (*MailboxPermFlagClient) GetX ¶
func (c *MailboxPermFlagClient) GetX(ctx context.Context, id int) *MailboxPermFlag
GetX is like Get, but panics if an error occurs.
func (*MailboxPermFlagClient) Hooks ¶
func (c *MailboxPermFlagClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MailboxPermFlagClient) Query ¶
func (c *MailboxPermFlagClient) Query() *MailboxPermFlagQuery
Query returns a query builder for MailboxPermFlag.
func (*MailboxPermFlagClient) Update ¶
func (c *MailboxPermFlagClient) Update() *MailboxPermFlagUpdate
Update returns an update builder for MailboxPermFlag.
func (*MailboxPermFlagClient) UpdateOne ¶
func (c *MailboxPermFlagClient) UpdateOne(mpf *MailboxPermFlag) *MailboxPermFlagUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MailboxPermFlagClient) UpdateOneID ¶
func (c *MailboxPermFlagClient) UpdateOneID(id int) *MailboxPermFlagUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MailboxPermFlagClient) Use ¶
func (c *MailboxPermFlagClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `mailboxpermflag.Hooks(f(g(h())))`.
type MailboxPermFlagCreate ¶
type MailboxPermFlagCreate struct {
// contains filtered or unexported fields
}
MailboxPermFlagCreate is the builder for creating a MailboxPermFlag entity.
func (*MailboxPermFlagCreate) Exec ¶
func (mpfc *MailboxPermFlagCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxPermFlagCreate) ExecX ¶
func (mpfc *MailboxPermFlagCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxPermFlagCreate) Mutation ¶
func (mpfc *MailboxPermFlagCreate) Mutation() *MailboxPermFlagMutation
Mutation returns the MailboxPermFlagMutation object of the builder.
func (*MailboxPermFlagCreate) Save ¶
func (mpfc *MailboxPermFlagCreate) Save(ctx context.Context) (*MailboxPermFlag, error)
Save creates the MailboxPermFlag in the database.
func (*MailboxPermFlagCreate) SaveX ¶
func (mpfc *MailboxPermFlagCreate) SaveX(ctx context.Context) *MailboxPermFlag
SaveX calls Save and panics if Save returns an error.
func (*MailboxPermFlagCreate) SetValue ¶
func (mpfc *MailboxPermFlagCreate) SetValue(s string) *MailboxPermFlagCreate
SetValue sets the "Value" field.
type MailboxPermFlagCreateBulk ¶
type MailboxPermFlagCreateBulk struct {
// contains filtered or unexported fields
}
MailboxPermFlagCreateBulk is the builder for creating many MailboxPermFlag entities in bulk.
func (*MailboxPermFlagCreateBulk) Exec ¶
func (mpfcb *MailboxPermFlagCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxPermFlagCreateBulk) ExecX ¶
func (mpfcb *MailboxPermFlagCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxPermFlagCreateBulk) Save ¶
func (mpfcb *MailboxPermFlagCreateBulk) Save(ctx context.Context) ([]*MailboxPermFlag, error)
Save creates the MailboxPermFlag entities in the database.
func (*MailboxPermFlagCreateBulk) SaveX ¶
func (mpfcb *MailboxPermFlagCreateBulk) SaveX(ctx context.Context) []*MailboxPermFlag
SaveX is like Save, but panics if an error occurs.
type MailboxPermFlagDelete ¶
type MailboxPermFlagDelete struct {
// contains filtered or unexported fields
}
MailboxPermFlagDelete is the builder for deleting a MailboxPermFlag entity.
func (*MailboxPermFlagDelete) Exec ¶
func (mpfd *MailboxPermFlagDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MailboxPermFlagDelete) ExecX ¶
func (mpfd *MailboxPermFlagDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MailboxPermFlagDelete) Where ¶
func (mpfd *MailboxPermFlagDelete) Where(ps ...predicate.MailboxPermFlag) *MailboxPermFlagDelete
Where appends a list predicates to the MailboxPermFlagDelete builder.
type MailboxPermFlagDeleteOne ¶
type MailboxPermFlagDeleteOne struct {
// contains filtered or unexported fields
}
MailboxPermFlagDeleteOne is the builder for deleting a single MailboxPermFlag entity.
func (*MailboxPermFlagDeleteOne) Exec ¶
func (mpfdo *MailboxPermFlagDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MailboxPermFlagDeleteOne) ExecX ¶
func (mpfdo *MailboxPermFlagDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MailboxPermFlagGroupBy ¶
type MailboxPermFlagGroupBy struct {
// contains filtered or unexported fields
}
MailboxPermFlagGroupBy is the group-by builder for MailboxPermFlag entities.
func (*MailboxPermFlagGroupBy) Aggregate ¶
func (mpfgb *MailboxPermFlagGroupBy) Aggregate(fns ...AggregateFunc) *MailboxPermFlagGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MailboxPermFlagGroupBy) Bool ¶
func (mpfgb *MailboxPermFlagGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) BoolX ¶
func (mpfgb *MailboxPermFlagGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) Bools ¶
func (mpfgb *MailboxPermFlagGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) BoolsX ¶
func (mpfgb *MailboxPermFlagGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) Float64 ¶
func (mpfgb *MailboxPermFlagGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) Float64X ¶
func (mpfgb *MailboxPermFlagGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) Float64s ¶
func (mpfgb *MailboxPermFlagGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) Float64sX ¶
func (mpfgb *MailboxPermFlagGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) Int ¶
func (mpfgb *MailboxPermFlagGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) IntX ¶
func (mpfgb *MailboxPermFlagGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) Ints ¶
func (mpfgb *MailboxPermFlagGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) IntsX ¶
func (mpfgb *MailboxPermFlagGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) Scan ¶
func (mpfgb *MailboxPermFlagGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*MailboxPermFlagGroupBy) ScanX ¶
func (mpfgb *MailboxPermFlagGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxPermFlagGroupBy) String ¶
func (mpfgb *MailboxPermFlagGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MailboxPermFlagGroupBy) StringX ¶
func (mpfgb *MailboxPermFlagGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxPermFlagMutation ¶
type MailboxPermFlagMutation struct {
// contains filtered or unexported fields
}
MailboxPermFlagMutation represents an operation that mutates the MailboxPermFlag nodes in the graph.
func (*MailboxPermFlagMutation) AddField ¶
func (m *MailboxPermFlagMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxPermFlagMutation) AddedEdges ¶
func (m *MailboxPermFlagMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MailboxPermFlagMutation) AddedField ¶
func (m *MailboxPermFlagMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxPermFlagMutation) AddedFields ¶
func (m *MailboxPermFlagMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MailboxPermFlagMutation) AddedIDs ¶
func (m *MailboxPermFlagMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MailboxPermFlagMutation) ClearEdge ¶
func (m *MailboxPermFlagMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*MailboxPermFlagMutation) ClearField ¶
func (m *MailboxPermFlagMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxPermFlagMutation) ClearedEdges ¶
func (m *MailboxPermFlagMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MailboxPermFlagMutation) ClearedFields ¶
func (m *MailboxPermFlagMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MailboxPermFlagMutation) Client ¶
func (m MailboxPermFlagMutation) 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 (*MailboxPermFlagMutation) EdgeCleared ¶
func (m *MailboxPermFlagMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MailboxPermFlagMutation) Field ¶
func (m *MailboxPermFlagMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MailboxPermFlagMutation) FieldCleared ¶
func (m *MailboxPermFlagMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MailboxPermFlagMutation) Fields ¶
func (m *MailboxPermFlagMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*MailboxPermFlagMutation) ID ¶
func (m *MailboxPermFlagMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*MailboxPermFlagMutation) IDs ¶
func (m *MailboxPermFlagMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*MailboxPermFlagMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*MailboxPermFlagMutation) OldValue ¶
func (m *MailboxPermFlagMutation) OldValue(ctx context.Context) (v string, err error)
OldValue returns the old "Value" field's value of the MailboxPermFlag entity. If the MailboxPermFlag object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MailboxPermFlagMutation) Op ¶
func (m *MailboxPermFlagMutation) Op() Op
Op returns the operation name.
func (*MailboxPermFlagMutation) RemovedEdges ¶
func (m *MailboxPermFlagMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MailboxPermFlagMutation) RemovedIDs ¶
func (m *MailboxPermFlagMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*MailboxPermFlagMutation) ResetEdge ¶
func (m *MailboxPermFlagMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*MailboxPermFlagMutation) ResetField ¶
func (m *MailboxPermFlagMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*MailboxPermFlagMutation) ResetValue ¶
func (m *MailboxPermFlagMutation) ResetValue()
ResetValue resets all changes to the "Value" field.
func (*MailboxPermFlagMutation) SetField ¶
func (m *MailboxPermFlagMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MailboxPermFlagMutation) SetValue ¶
func (m *MailboxPermFlagMutation) SetValue(s string)
SetValue sets the "Value" field.
func (MailboxPermFlagMutation) Tx ¶
func (m MailboxPermFlagMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MailboxPermFlagMutation) Type ¶
func (m *MailboxPermFlagMutation) Type() string
Type returns the node type of this mutation (MailboxPermFlag).
func (*MailboxPermFlagMutation) Value ¶
func (m *MailboxPermFlagMutation) Value() (r string, exists bool)
Value returns the value of the "Value" field in the mutation.
func (*MailboxPermFlagMutation) Where ¶
func (m *MailboxPermFlagMutation) Where(ps ...predicate.MailboxPermFlag)
Where appends a list predicates to the MailboxPermFlagMutation builder.
type MailboxPermFlagQuery ¶
type MailboxPermFlagQuery struct {
// contains filtered or unexported fields
}
MailboxPermFlagQuery is the builder for querying MailboxPermFlag entities.
func (*MailboxPermFlagQuery) All ¶
func (mpfq *MailboxPermFlagQuery) All(ctx context.Context) ([]*MailboxPermFlag, error)
All executes the query and returns a list of MailboxPermFlags.
func (*MailboxPermFlagQuery) AllX ¶
func (mpfq *MailboxPermFlagQuery) AllX(ctx context.Context) []*MailboxPermFlag
AllX is like All, but panics if an error occurs.
func (*MailboxPermFlagQuery) Clone ¶
func (mpfq *MailboxPermFlagQuery) Clone() *MailboxPermFlagQuery
Clone returns a duplicate of the MailboxPermFlagQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MailboxPermFlagQuery) Count ¶
func (mpfq *MailboxPermFlagQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MailboxPermFlagQuery) CountX ¶
func (mpfq *MailboxPermFlagQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MailboxPermFlagQuery) Exist ¶
func (mpfq *MailboxPermFlagQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MailboxPermFlagQuery) ExistX ¶
func (mpfq *MailboxPermFlagQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MailboxPermFlagQuery) First ¶
func (mpfq *MailboxPermFlagQuery) First(ctx context.Context) (*MailboxPermFlag, error)
First returns the first MailboxPermFlag entity from the query. Returns a *NotFoundError when no MailboxPermFlag was found.
func (*MailboxPermFlagQuery) FirstID ¶
func (mpfq *MailboxPermFlagQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first MailboxPermFlag ID from the query. Returns a *NotFoundError when no MailboxPermFlag ID was found.
func (*MailboxPermFlagQuery) FirstIDX ¶
func (mpfq *MailboxPermFlagQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*MailboxPermFlagQuery) FirstX ¶
func (mpfq *MailboxPermFlagQuery) FirstX(ctx context.Context) *MailboxPermFlag
FirstX is like First, but panics if an error occurs.
func (*MailboxPermFlagQuery) GroupBy ¶
func (mpfq *MailboxPermFlagQuery) GroupBy(field string, fields ...string) *MailboxPermFlagGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Value string `json:"Value,omitempty"` Count int `json:"count,omitempty"` } client.MailboxPermFlag.Query(). GroupBy(mailboxpermflag.FieldValue). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MailboxPermFlagQuery) IDs ¶
func (mpfq *MailboxPermFlagQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of MailboxPermFlag IDs.
func (*MailboxPermFlagQuery) IDsX ¶
func (mpfq *MailboxPermFlagQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*MailboxPermFlagQuery) Limit ¶
func (mpfq *MailboxPermFlagQuery) Limit(limit int) *MailboxPermFlagQuery
Limit adds a limit step to the query.
func (*MailboxPermFlagQuery) Offset ¶
func (mpfq *MailboxPermFlagQuery) Offset(offset int) *MailboxPermFlagQuery
Offset adds an offset step to the query.
func (*MailboxPermFlagQuery) Only ¶
func (mpfq *MailboxPermFlagQuery) Only(ctx context.Context) (*MailboxPermFlag, error)
Only returns a single MailboxPermFlag entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one MailboxPermFlag entity is found. Returns a *NotFoundError when no MailboxPermFlag entities are found.
func (*MailboxPermFlagQuery) OnlyID ¶
func (mpfq *MailboxPermFlagQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only MailboxPermFlag ID in the query. Returns a *NotSingularError when more than one MailboxPermFlag ID is found. Returns a *NotFoundError when no entities are found.
func (*MailboxPermFlagQuery) OnlyIDX ¶
func (mpfq *MailboxPermFlagQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MailboxPermFlagQuery) OnlyX ¶
func (mpfq *MailboxPermFlagQuery) OnlyX(ctx context.Context) *MailboxPermFlag
OnlyX is like Only, but panics if an error occurs.
func (*MailboxPermFlagQuery) Order ¶
func (mpfq *MailboxPermFlagQuery) Order(o ...OrderFunc) *MailboxPermFlagQuery
Order adds an order step to the query.
func (*MailboxPermFlagQuery) Select ¶
func (mpfq *MailboxPermFlagQuery) Select(fields ...string) *MailboxPermFlagSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Value string `json:"Value,omitempty"` } client.MailboxPermFlag.Query(). Select(mailboxpermflag.FieldValue). Scan(ctx, &v)
func (*MailboxPermFlagQuery) Unique ¶
func (mpfq *MailboxPermFlagQuery) Unique(unique bool) *MailboxPermFlagQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*MailboxPermFlagQuery) Where ¶
func (mpfq *MailboxPermFlagQuery) Where(ps ...predicate.MailboxPermFlag) *MailboxPermFlagQuery
Where adds a new predicate for the MailboxPermFlagQuery builder.
type MailboxPermFlagSelect ¶
type MailboxPermFlagSelect struct { *MailboxPermFlagQuery // contains filtered or unexported fields }
MailboxPermFlagSelect is the builder for selecting fields of MailboxPermFlag entities.
func (*MailboxPermFlagSelect) Bool ¶
func (mpfs *MailboxPermFlagSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) BoolX ¶
func (mpfs *MailboxPermFlagSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxPermFlagSelect) Bools ¶
func (mpfs *MailboxPermFlagSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) BoolsX ¶
func (mpfs *MailboxPermFlagSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxPermFlagSelect) Float64 ¶
func (mpfs *MailboxPermFlagSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) Float64X ¶
func (mpfs *MailboxPermFlagSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxPermFlagSelect) Float64s ¶
func (mpfs *MailboxPermFlagSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) Float64sX ¶
func (mpfs *MailboxPermFlagSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxPermFlagSelect) Int ¶
func (mpfs *MailboxPermFlagSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) IntX ¶
func (mpfs *MailboxPermFlagSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxPermFlagSelect) Ints ¶
func (mpfs *MailboxPermFlagSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) IntsX ¶
func (mpfs *MailboxPermFlagSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxPermFlagSelect) Scan ¶
func (mpfs *MailboxPermFlagSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*MailboxPermFlagSelect) ScanX ¶
func (mpfs *MailboxPermFlagSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxPermFlagSelect) String ¶
func (mpfs *MailboxPermFlagSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*MailboxPermFlagSelect) StringX ¶
func (mpfs *MailboxPermFlagSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxPermFlagUpdate ¶
type MailboxPermFlagUpdate struct {
// contains filtered or unexported fields
}
MailboxPermFlagUpdate is the builder for updating MailboxPermFlag entities.
func (*MailboxPermFlagUpdate) Exec ¶
func (mpfu *MailboxPermFlagUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxPermFlagUpdate) ExecX ¶
func (mpfu *MailboxPermFlagUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxPermFlagUpdate) Mutation ¶
func (mpfu *MailboxPermFlagUpdate) Mutation() *MailboxPermFlagMutation
Mutation returns the MailboxPermFlagMutation object of the builder.
func (*MailboxPermFlagUpdate) Save ¶
func (mpfu *MailboxPermFlagUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MailboxPermFlagUpdate) SaveX ¶
func (mpfu *MailboxPermFlagUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MailboxPermFlagUpdate) SetValue ¶
func (mpfu *MailboxPermFlagUpdate) SetValue(s string) *MailboxPermFlagUpdate
SetValue sets the "Value" field.
func (*MailboxPermFlagUpdate) Where ¶
func (mpfu *MailboxPermFlagUpdate) Where(ps ...predicate.MailboxPermFlag) *MailboxPermFlagUpdate
Where appends a list predicates to the MailboxPermFlagUpdate builder.
type MailboxPermFlagUpdateOne ¶
type MailboxPermFlagUpdateOne struct {
// contains filtered or unexported fields
}
MailboxPermFlagUpdateOne is the builder for updating a single MailboxPermFlag entity.
func (*MailboxPermFlagUpdateOne) Exec ¶
func (mpfuo *MailboxPermFlagUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MailboxPermFlagUpdateOne) ExecX ¶
func (mpfuo *MailboxPermFlagUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxPermFlagUpdateOne) Mutation ¶
func (mpfuo *MailboxPermFlagUpdateOne) Mutation() *MailboxPermFlagMutation
Mutation returns the MailboxPermFlagMutation object of the builder.
func (*MailboxPermFlagUpdateOne) Save ¶
func (mpfuo *MailboxPermFlagUpdateOne) Save(ctx context.Context) (*MailboxPermFlag, error)
Save executes the query and returns the updated MailboxPermFlag entity.
func (*MailboxPermFlagUpdateOne) SaveX ¶
func (mpfuo *MailboxPermFlagUpdateOne) SaveX(ctx context.Context) *MailboxPermFlag
SaveX is like Save, but panics if an error occurs.
func (*MailboxPermFlagUpdateOne) Select ¶
func (mpfuo *MailboxPermFlagUpdateOne) Select(field string, fields ...string) *MailboxPermFlagUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MailboxPermFlagUpdateOne) SetValue ¶
func (mpfuo *MailboxPermFlagUpdateOne) SetValue(s string) *MailboxPermFlagUpdateOne
SetValue sets the "Value" field.
type MailboxPermFlags ¶
type MailboxPermFlags []*MailboxPermFlag
MailboxPermFlags is a parsable slice of MailboxPermFlag.
type MailboxQuery ¶
type MailboxQuery struct {
// contains filtered or unexported fields
}
MailboxQuery is the builder for querying Mailbox entities.
func (*MailboxQuery) All ¶
func (mq *MailboxQuery) All(ctx context.Context) ([]*Mailbox, error)
All executes the query and returns a list of Mailboxes.
func (*MailboxQuery) AllX ¶
func (mq *MailboxQuery) AllX(ctx context.Context) []*Mailbox
AllX is like All, but panics if an error occurs.
func (*MailboxQuery) Clone ¶
func (mq *MailboxQuery) Clone() *MailboxQuery
Clone returns a duplicate of the MailboxQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MailboxQuery) Count ¶
func (mq *MailboxQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MailboxQuery) CountX ¶
func (mq *MailboxQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MailboxQuery) Exist ¶
func (mq *MailboxQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MailboxQuery) ExistX ¶
func (mq *MailboxQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MailboxQuery) First ¶
func (mq *MailboxQuery) First(ctx context.Context) (*Mailbox, error)
First returns the first Mailbox entity from the query. Returns a *NotFoundError when no Mailbox was found.
func (*MailboxQuery) FirstID ¶
func (mq *MailboxQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Mailbox ID from the query. Returns a *NotFoundError when no Mailbox ID was found.
func (*MailboxQuery) FirstIDX ¶
func (mq *MailboxQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*MailboxQuery) FirstX ¶
func (mq *MailboxQuery) FirstX(ctx context.Context) *Mailbox
FirstX is like First, but panics if an error occurs.
func (*MailboxQuery) GroupBy ¶
func (mq *MailboxQuery) GroupBy(field string, fields ...string) *MailboxGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { MailboxID string `json:"MailboxID,omitempty"` Count int `json:"count,omitempty"` } client.Mailbox.Query(). GroupBy(mailbox.FieldMailboxID). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MailboxQuery) IDs ¶
func (mq *MailboxQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of Mailbox IDs.
func (*MailboxQuery) IDsX ¶
func (mq *MailboxQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*MailboxQuery) Limit ¶
func (mq *MailboxQuery) Limit(limit int) *MailboxQuery
Limit adds a limit step to the query.
func (*MailboxQuery) Offset ¶
func (mq *MailboxQuery) Offset(offset int) *MailboxQuery
Offset adds an offset step to the query.
func (*MailboxQuery) Only ¶
func (mq *MailboxQuery) Only(ctx context.Context) (*Mailbox, error)
Only returns a single Mailbox entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Mailbox entity is found. Returns a *NotFoundError when no Mailbox entities are found.
func (*MailboxQuery) OnlyID ¶
func (mq *MailboxQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Mailbox ID in the query. Returns a *NotSingularError when more than one Mailbox ID is found. Returns a *NotFoundError when no entities are found.
func (*MailboxQuery) OnlyIDX ¶
func (mq *MailboxQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MailboxQuery) OnlyX ¶
func (mq *MailboxQuery) OnlyX(ctx context.Context) *Mailbox
OnlyX is like Only, but panics if an error occurs.
func (*MailboxQuery) Order ¶
func (mq *MailboxQuery) Order(o ...OrderFunc) *MailboxQuery
Order adds an order step to the query.
func (*MailboxQuery) QueryAttributes ¶
func (mq *MailboxQuery) QueryAttributes() *MailboxAttrQuery
QueryAttributes chains the current query on the "attributes" edge.
func (*MailboxQuery) QueryFlags ¶
func (mq *MailboxQuery) QueryFlags() *MailboxFlagQuery
QueryFlags chains the current query on the "flags" edge.
func (*MailboxQuery) QueryPermanentFlags ¶
func (mq *MailboxQuery) QueryPermanentFlags() *MailboxPermFlagQuery
QueryPermanentFlags chains the current query on the "permanent_flags" edge.
func (*MailboxQuery) QueryUIDs ¶
func (mq *MailboxQuery) QueryUIDs() *UIDQuery
QueryUIDs chains the current query on the "UIDs" edge.
func (*MailboxQuery) Select ¶
func (mq *MailboxQuery) Select(fields ...string) *MailboxSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { MailboxID string `json:"MailboxID,omitempty"` } client.Mailbox.Query(). Select(mailbox.FieldMailboxID). Scan(ctx, &v)
func (*MailboxQuery) Unique ¶
func (mq *MailboxQuery) Unique(unique bool) *MailboxQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*MailboxQuery) Where ¶
func (mq *MailboxQuery) Where(ps ...predicate.Mailbox) *MailboxQuery
Where adds a new predicate for the MailboxQuery builder.
func (*MailboxQuery) WithAttributes ¶
func (mq *MailboxQuery) WithAttributes(opts ...func(*MailboxAttrQuery)) *MailboxQuery
WithAttributes tells the query-builder to eager-load the nodes that are connected to the "attributes" edge. The optional arguments are used to configure the query builder of the edge.
func (*MailboxQuery) WithFlags ¶
func (mq *MailboxQuery) WithFlags(opts ...func(*MailboxFlagQuery)) *MailboxQuery
WithFlags tells the query-builder to eager-load the nodes that are connected to the "flags" edge. The optional arguments are used to configure the query builder of the edge.
func (*MailboxQuery) WithPermanentFlags ¶
func (mq *MailboxQuery) WithPermanentFlags(opts ...func(*MailboxPermFlagQuery)) *MailboxQuery
WithPermanentFlags tells the query-builder to eager-load the nodes that are connected to the "permanent_flags" edge. The optional arguments are used to configure the query builder of the edge.
func (*MailboxQuery) WithUIDs ¶
func (mq *MailboxQuery) WithUIDs(opts ...func(*UIDQuery)) *MailboxQuery
WithUIDs tells the query-builder to eager-load the nodes that are connected to the "UIDs" edge. The optional arguments are used to configure the query builder of the edge.
type MailboxSelect ¶
type MailboxSelect struct { *MailboxQuery // contains filtered or unexported fields }
MailboxSelect is the builder for selecting fields of Mailbox entities.
func (*MailboxSelect) Bool ¶
func (ms *MailboxSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) BoolX ¶
func (ms *MailboxSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MailboxSelect) Bools ¶
func (ms *MailboxSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) BoolsX ¶
func (ms *MailboxSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MailboxSelect) Float64 ¶
func (ms *MailboxSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) Float64X ¶
func (ms *MailboxSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MailboxSelect) Float64s ¶
func (ms *MailboxSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) Float64sX ¶
func (ms *MailboxSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MailboxSelect) Int ¶
func (ms *MailboxSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) IntX ¶
func (ms *MailboxSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MailboxSelect) Ints ¶
func (ms *MailboxSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) IntsX ¶
func (ms *MailboxSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MailboxSelect) Scan ¶
func (ms *MailboxSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*MailboxSelect) ScanX ¶
func (ms *MailboxSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MailboxSelect) String ¶
func (ms *MailboxSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*MailboxSelect) StringX ¶
func (ms *MailboxSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MailboxUpdate ¶
type MailboxUpdate struct {
// contains filtered or unexported fields
}
MailboxUpdate is the builder for updating Mailbox entities.
func (*MailboxUpdate) AddAttributeIDs ¶
func (mu *MailboxUpdate) AddAttributeIDs(ids ...int) *MailboxUpdate
AddAttributeIDs adds the "attributes" edge to the MailboxAttr entity by IDs.
func (*MailboxUpdate) AddAttributes ¶
func (mu *MailboxUpdate) AddAttributes(m ...*MailboxAttr) *MailboxUpdate
AddAttributes adds the "attributes" edges to the MailboxAttr entity.
func (*MailboxUpdate) AddFlagIDs ¶
func (mu *MailboxUpdate) AddFlagIDs(ids ...int) *MailboxUpdate
AddFlagIDs adds the "flags" edge to the MailboxFlag entity by IDs.
func (*MailboxUpdate) AddFlags ¶
func (mu *MailboxUpdate) AddFlags(m ...*MailboxFlag) *MailboxUpdate
AddFlags adds the "flags" edges to the MailboxFlag entity.
func (*MailboxUpdate) AddPermanentFlagIDs ¶
func (mu *MailboxUpdate) AddPermanentFlagIDs(ids ...int) *MailboxUpdate
AddPermanentFlagIDs adds the "permanent_flags" edge to the MailboxPermFlag entity by IDs.
func (*MailboxUpdate) AddPermanentFlags ¶
func (mu *MailboxUpdate) AddPermanentFlags(m ...*MailboxPermFlag) *MailboxUpdate
AddPermanentFlags adds the "permanent_flags" edges to the MailboxPermFlag entity.
func (*MailboxUpdate) AddUIDIDs ¶
func (mu *MailboxUpdate) AddUIDIDs(ids ...int) *MailboxUpdate
AddUIDIDs adds the "UIDs" edge to the UID entity by IDs.
func (*MailboxUpdate) AddUIDNext ¶
func (mu *MailboxUpdate) AddUIDNext(i int) *MailboxUpdate
AddUIDNext adds i to the "UIDNext" field.
func (*MailboxUpdate) AddUIDValidity ¶
func (mu *MailboxUpdate) AddUIDValidity(i int) *MailboxUpdate
AddUIDValidity adds i to the "UIDValidity" field.
func (*MailboxUpdate) AddUIDs ¶
func (mu *MailboxUpdate) AddUIDs(u ...*UID) *MailboxUpdate
AddUIDs adds the "UIDs" edges to the UID entity.
func (*MailboxUpdate) ClearAttributes ¶
func (mu *MailboxUpdate) ClearAttributes() *MailboxUpdate
ClearAttributes clears all "attributes" edges to the MailboxAttr entity.
func (*MailboxUpdate) ClearFlags ¶
func (mu *MailboxUpdate) ClearFlags() *MailboxUpdate
ClearFlags clears all "flags" edges to the MailboxFlag entity.
func (*MailboxUpdate) ClearPermanentFlags ¶
func (mu *MailboxUpdate) ClearPermanentFlags() *MailboxUpdate
ClearPermanentFlags clears all "permanent_flags" edges to the MailboxPermFlag entity.
func (*MailboxUpdate) ClearUIDs ¶
func (mu *MailboxUpdate) ClearUIDs() *MailboxUpdate
ClearUIDs clears all "UIDs" edges to the UID entity.
func (*MailboxUpdate) Exec ¶
func (mu *MailboxUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MailboxUpdate) ExecX ¶
func (mu *MailboxUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxUpdate) Mutation ¶
func (mu *MailboxUpdate) Mutation() *MailboxMutation
Mutation returns the MailboxMutation object of the builder.
func (*MailboxUpdate) RemoveAttributeIDs ¶
func (mu *MailboxUpdate) RemoveAttributeIDs(ids ...int) *MailboxUpdate
RemoveAttributeIDs removes the "attributes" edge to MailboxAttr entities by IDs.
func (*MailboxUpdate) RemoveAttributes ¶
func (mu *MailboxUpdate) RemoveAttributes(m ...*MailboxAttr) *MailboxUpdate
RemoveAttributes removes "attributes" edges to MailboxAttr entities.
func (*MailboxUpdate) RemoveFlagIDs ¶
func (mu *MailboxUpdate) RemoveFlagIDs(ids ...int) *MailboxUpdate
RemoveFlagIDs removes the "flags" edge to MailboxFlag entities by IDs.
func (*MailboxUpdate) RemoveFlags ¶
func (mu *MailboxUpdate) RemoveFlags(m ...*MailboxFlag) *MailboxUpdate
RemoveFlags removes "flags" edges to MailboxFlag entities.
func (*MailboxUpdate) RemovePermanentFlagIDs ¶
func (mu *MailboxUpdate) RemovePermanentFlagIDs(ids ...int) *MailboxUpdate
RemovePermanentFlagIDs removes the "permanent_flags" edge to MailboxPermFlag entities by IDs.
func (*MailboxUpdate) RemovePermanentFlags ¶
func (mu *MailboxUpdate) RemovePermanentFlags(m ...*MailboxPermFlag) *MailboxUpdate
RemovePermanentFlags removes "permanent_flags" edges to MailboxPermFlag entities.
func (*MailboxUpdate) RemoveUIDIDs ¶
func (mu *MailboxUpdate) RemoveUIDIDs(ids ...int) *MailboxUpdate
RemoveUIDIDs removes the "UIDs" edge to UID entities by IDs.
func (*MailboxUpdate) RemoveUIDs ¶
func (mu *MailboxUpdate) RemoveUIDs(u ...*UID) *MailboxUpdate
RemoveUIDs removes "UIDs" edges to UID entities.
func (*MailboxUpdate) Save ¶
func (mu *MailboxUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MailboxUpdate) SaveX ¶
func (mu *MailboxUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MailboxUpdate) SetMailboxID ¶
func (mu *MailboxUpdate) SetMailboxID(s string) *MailboxUpdate
SetMailboxID sets the "MailboxID" field.
func (*MailboxUpdate) SetName ¶
func (mu *MailboxUpdate) SetName(s string) *MailboxUpdate
SetName sets the "Name" field.
func (*MailboxUpdate) SetNillableSubscribed ¶
func (mu *MailboxUpdate) SetNillableSubscribed(b *bool) *MailboxUpdate
SetNillableSubscribed sets the "Subscribed" field if the given value is not nil.
func (*MailboxUpdate) SetNillableUIDNext ¶
func (mu *MailboxUpdate) SetNillableUIDNext(i *int) *MailboxUpdate
SetNillableUIDNext sets the "UIDNext" field if the given value is not nil.
func (*MailboxUpdate) SetNillableUIDValidity ¶
func (mu *MailboxUpdate) SetNillableUIDValidity(i *int) *MailboxUpdate
SetNillableUIDValidity sets the "UIDValidity" field if the given value is not nil.
func (*MailboxUpdate) SetSubscribed ¶
func (mu *MailboxUpdate) SetSubscribed(b bool) *MailboxUpdate
SetSubscribed sets the "Subscribed" field.
func (*MailboxUpdate) SetUIDNext ¶
func (mu *MailboxUpdate) SetUIDNext(i int) *MailboxUpdate
SetUIDNext sets the "UIDNext" field.
func (*MailboxUpdate) SetUIDValidity ¶
func (mu *MailboxUpdate) SetUIDValidity(i int) *MailboxUpdate
SetUIDValidity sets the "UIDValidity" field.
func (*MailboxUpdate) Where ¶
func (mu *MailboxUpdate) Where(ps ...predicate.Mailbox) *MailboxUpdate
Where appends a list predicates to the MailboxUpdate builder.
type MailboxUpdateOne ¶
type MailboxUpdateOne struct {
// contains filtered or unexported fields
}
MailboxUpdateOne is the builder for updating a single Mailbox entity.
func (*MailboxUpdateOne) AddAttributeIDs ¶
func (muo *MailboxUpdateOne) AddAttributeIDs(ids ...int) *MailboxUpdateOne
AddAttributeIDs adds the "attributes" edge to the MailboxAttr entity by IDs.
func (*MailboxUpdateOne) AddAttributes ¶
func (muo *MailboxUpdateOne) AddAttributes(m ...*MailboxAttr) *MailboxUpdateOne
AddAttributes adds the "attributes" edges to the MailboxAttr entity.
func (*MailboxUpdateOne) AddFlagIDs ¶
func (muo *MailboxUpdateOne) AddFlagIDs(ids ...int) *MailboxUpdateOne
AddFlagIDs adds the "flags" edge to the MailboxFlag entity by IDs.
func (*MailboxUpdateOne) AddFlags ¶
func (muo *MailboxUpdateOne) AddFlags(m ...*MailboxFlag) *MailboxUpdateOne
AddFlags adds the "flags" edges to the MailboxFlag entity.
func (*MailboxUpdateOne) AddPermanentFlagIDs ¶
func (muo *MailboxUpdateOne) AddPermanentFlagIDs(ids ...int) *MailboxUpdateOne
AddPermanentFlagIDs adds the "permanent_flags" edge to the MailboxPermFlag entity by IDs.
func (*MailboxUpdateOne) AddPermanentFlags ¶
func (muo *MailboxUpdateOne) AddPermanentFlags(m ...*MailboxPermFlag) *MailboxUpdateOne
AddPermanentFlags adds the "permanent_flags" edges to the MailboxPermFlag entity.
func (*MailboxUpdateOne) AddUIDIDs ¶
func (muo *MailboxUpdateOne) AddUIDIDs(ids ...int) *MailboxUpdateOne
AddUIDIDs adds the "UIDs" edge to the UID entity by IDs.
func (*MailboxUpdateOne) AddUIDNext ¶
func (muo *MailboxUpdateOne) AddUIDNext(i int) *MailboxUpdateOne
AddUIDNext adds i to the "UIDNext" field.
func (*MailboxUpdateOne) AddUIDValidity ¶
func (muo *MailboxUpdateOne) AddUIDValidity(i int) *MailboxUpdateOne
AddUIDValidity adds i to the "UIDValidity" field.
func (*MailboxUpdateOne) AddUIDs ¶
func (muo *MailboxUpdateOne) AddUIDs(u ...*UID) *MailboxUpdateOne
AddUIDs adds the "UIDs" edges to the UID entity.
func (*MailboxUpdateOne) ClearAttributes ¶
func (muo *MailboxUpdateOne) ClearAttributes() *MailboxUpdateOne
ClearAttributes clears all "attributes" edges to the MailboxAttr entity.
func (*MailboxUpdateOne) ClearFlags ¶
func (muo *MailboxUpdateOne) ClearFlags() *MailboxUpdateOne
ClearFlags clears all "flags" edges to the MailboxFlag entity.
func (*MailboxUpdateOne) ClearPermanentFlags ¶
func (muo *MailboxUpdateOne) ClearPermanentFlags() *MailboxUpdateOne
ClearPermanentFlags clears all "permanent_flags" edges to the MailboxPermFlag entity.
func (*MailboxUpdateOne) ClearUIDs ¶
func (muo *MailboxUpdateOne) ClearUIDs() *MailboxUpdateOne
ClearUIDs clears all "UIDs" edges to the UID entity.
func (*MailboxUpdateOne) Exec ¶
func (muo *MailboxUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MailboxUpdateOne) ExecX ¶
func (muo *MailboxUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MailboxUpdateOne) Mutation ¶
func (muo *MailboxUpdateOne) Mutation() *MailboxMutation
Mutation returns the MailboxMutation object of the builder.
func (*MailboxUpdateOne) RemoveAttributeIDs ¶
func (muo *MailboxUpdateOne) RemoveAttributeIDs(ids ...int) *MailboxUpdateOne
RemoveAttributeIDs removes the "attributes" edge to MailboxAttr entities by IDs.
func (*MailboxUpdateOne) RemoveAttributes ¶
func (muo *MailboxUpdateOne) RemoveAttributes(m ...*MailboxAttr) *MailboxUpdateOne
RemoveAttributes removes "attributes" edges to MailboxAttr entities.
func (*MailboxUpdateOne) RemoveFlagIDs ¶
func (muo *MailboxUpdateOne) RemoveFlagIDs(ids ...int) *MailboxUpdateOne
RemoveFlagIDs removes the "flags" edge to MailboxFlag entities by IDs.
func (*MailboxUpdateOne) RemoveFlags ¶
func (muo *MailboxUpdateOne) RemoveFlags(m ...*MailboxFlag) *MailboxUpdateOne
RemoveFlags removes "flags" edges to MailboxFlag entities.
func (*MailboxUpdateOne) RemovePermanentFlagIDs ¶
func (muo *MailboxUpdateOne) RemovePermanentFlagIDs(ids ...int) *MailboxUpdateOne
RemovePermanentFlagIDs removes the "permanent_flags" edge to MailboxPermFlag entities by IDs.
func (*MailboxUpdateOne) RemovePermanentFlags ¶
func (muo *MailboxUpdateOne) RemovePermanentFlags(m ...*MailboxPermFlag) *MailboxUpdateOne
RemovePermanentFlags removes "permanent_flags" edges to MailboxPermFlag entities.
func (*MailboxUpdateOne) RemoveUIDIDs ¶
func (muo *MailboxUpdateOne) RemoveUIDIDs(ids ...int) *MailboxUpdateOne
RemoveUIDIDs removes the "UIDs" edge to UID entities by IDs.
func (*MailboxUpdateOne) RemoveUIDs ¶
func (muo *MailboxUpdateOne) RemoveUIDs(u ...*UID) *MailboxUpdateOne
RemoveUIDs removes "UIDs" edges to UID entities.
func (*MailboxUpdateOne) Save ¶
func (muo *MailboxUpdateOne) Save(ctx context.Context) (*Mailbox, error)
Save executes the query and returns the updated Mailbox entity.
func (*MailboxUpdateOne) SaveX ¶
func (muo *MailboxUpdateOne) SaveX(ctx context.Context) *Mailbox
SaveX is like Save, but panics if an error occurs.
func (*MailboxUpdateOne) Select ¶
func (muo *MailboxUpdateOne) Select(field string, fields ...string) *MailboxUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MailboxUpdateOne) SetMailboxID ¶
func (muo *MailboxUpdateOne) SetMailboxID(s string) *MailboxUpdateOne
SetMailboxID sets the "MailboxID" field.
func (*MailboxUpdateOne) SetName ¶
func (muo *MailboxUpdateOne) SetName(s string) *MailboxUpdateOne
SetName sets the "Name" field.
func (*MailboxUpdateOne) SetNillableSubscribed ¶
func (muo *MailboxUpdateOne) SetNillableSubscribed(b *bool) *MailboxUpdateOne
SetNillableSubscribed sets the "Subscribed" field if the given value is not nil.
func (*MailboxUpdateOne) SetNillableUIDNext ¶
func (muo *MailboxUpdateOne) SetNillableUIDNext(i *int) *MailboxUpdateOne
SetNillableUIDNext sets the "UIDNext" field if the given value is not nil.
func (*MailboxUpdateOne) SetNillableUIDValidity ¶
func (muo *MailboxUpdateOne) SetNillableUIDValidity(i *int) *MailboxUpdateOne
SetNillableUIDValidity sets the "UIDValidity" field if the given value is not nil.
func (*MailboxUpdateOne) SetSubscribed ¶
func (muo *MailboxUpdateOne) SetSubscribed(b bool) *MailboxUpdateOne
SetSubscribed sets the "Subscribed" field.
func (*MailboxUpdateOne) SetUIDNext ¶
func (muo *MailboxUpdateOne) SetUIDNext(i int) *MailboxUpdateOne
SetUIDNext sets the "UIDNext" field.
func (*MailboxUpdateOne) SetUIDValidity ¶
func (muo *MailboxUpdateOne) SetUIDValidity(i int) *MailboxUpdateOne
SetUIDValidity sets the "UIDValidity" field.
type Message ¶
type Message struct { // ID of the ent. ID int `json:"id,omitempty"` // MessageID holds the value of the "MessageID" field. MessageID string `json:"MessageID,omitempty"` // InternalID holds the value of the "InternalID" field. InternalID string `json:"InternalID,omitempty"` // Date holds the value of the "Date" field. Date time.Time `json:"Date,omitempty"` // Size holds the value of the "Size" field. Size int `json:"Size,omitempty"` // Body holds the value of the "Body" field. Body string `json:"Body,omitempty"` // BodyStructure holds the value of the "BodyStructure" field. BodyStructure string `json:"BodyStructure,omitempty"` // Envelope holds the value of the "Envelope" field. Envelope string `json:"Envelope,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the MessageQuery when eager-loading is set. Edges MessageEdges `json:"edges"` // contains filtered or unexported fields }
Message is the model entity for the Message schema.
func (*Message) QueryFlags ¶
func (m *Message) QueryFlags() *MessageFlagQuery
QueryFlags queries the "flags" edge of the Message entity.
func (*Message) Unwrap ¶
Unwrap unwraps the Message entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*Message) Update ¶
func (m *Message) Update() *MessageUpdateOne
Update returns a builder for updating this Message. Note that you need to call Message.Unwrap() before calling this method if this Message was returned from a transaction, and the transaction was committed or rolled back.
type MessageClient ¶
type MessageClient struct {
// contains filtered or unexported fields
}
MessageClient is a client for the Message schema.
func NewMessageClient ¶
func NewMessageClient(c config) *MessageClient
NewMessageClient returns a client for the Message from the given config.
func (*MessageClient) Create ¶
func (c *MessageClient) Create() *MessageCreate
Create returns a create builder for Message.
func (*MessageClient) CreateBulk ¶
func (c *MessageClient) CreateBulk(builders ...*MessageCreate) *MessageCreateBulk
CreateBulk returns a builder for creating a bulk of Message entities.
func (*MessageClient) Delete ¶
func (c *MessageClient) Delete() *MessageDelete
Delete returns a delete builder for Message.
func (*MessageClient) DeleteOne ¶
func (c *MessageClient) DeleteOne(m *Message) *MessageDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*MessageClient) DeleteOneID ¶
func (c *MessageClient) DeleteOneID(id int) *MessageDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*MessageClient) GetX ¶
func (c *MessageClient) GetX(ctx context.Context, id int) *Message
GetX is like Get, but panics if an error occurs.
func (*MessageClient) Hooks ¶
func (c *MessageClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MessageClient) Query ¶
func (c *MessageClient) Query() *MessageQuery
Query returns a query builder for Message.
func (*MessageClient) QueryFlags ¶
func (c *MessageClient) QueryFlags(m *Message) *MessageFlagQuery
QueryFlags queries the flags edge of a Message.
func (*MessageClient) QueryUIDs ¶
func (c *MessageClient) QueryUIDs(m *Message) *UIDQuery
QueryUIDs queries the UIDs edge of a Message.
func (*MessageClient) Update ¶
func (c *MessageClient) Update() *MessageUpdate
Update returns an update builder for Message.
func (*MessageClient) UpdateOne ¶
func (c *MessageClient) UpdateOne(m *Message) *MessageUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MessageClient) UpdateOneID ¶
func (c *MessageClient) UpdateOneID(id int) *MessageUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MessageClient) Use ¶
func (c *MessageClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `message.Hooks(f(g(h())))`.
type MessageCreate ¶
type MessageCreate struct {
// contains filtered or unexported fields
}
MessageCreate is the builder for creating a Message entity.
func (*MessageCreate) AddFlagIDs ¶
func (mc *MessageCreate) AddFlagIDs(ids ...int) *MessageCreate
AddFlagIDs adds the "flags" edge to the MessageFlag entity by IDs.
func (*MessageCreate) AddFlags ¶
func (mc *MessageCreate) AddFlags(m ...*MessageFlag) *MessageCreate
AddFlags adds the "flags" edges to the MessageFlag entity.
func (*MessageCreate) AddUIDIDs ¶
func (mc *MessageCreate) AddUIDIDs(ids ...int) *MessageCreate
AddUIDIDs adds the "UIDs" edge to the UID entity by IDs.
func (*MessageCreate) AddUIDs ¶
func (mc *MessageCreate) AddUIDs(u ...*UID) *MessageCreate
AddUIDs adds the "UIDs" edges to the UID entity.
func (*MessageCreate) Exec ¶
func (mc *MessageCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MessageCreate) ExecX ¶
func (mc *MessageCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageCreate) Mutation ¶
func (mc *MessageCreate) Mutation() *MessageMutation
Mutation returns the MessageMutation object of the builder.
func (*MessageCreate) Save ¶
func (mc *MessageCreate) Save(ctx context.Context) (*Message, error)
Save creates the Message in the database.
func (*MessageCreate) SaveX ¶
func (mc *MessageCreate) SaveX(ctx context.Context) *Message
SaveX calls Save and panics if Save returns an error.
func (*MessageCreate) SetBody ¶
func (mc *MessageCreate) SetBody(s string) *MessageCreate
SetBody sets the "Body" field.
func (*MessageCreate) SetBodyStructure ¶
func (mc *MessageCreate) SetBodyStructure(s string) *MessageCreate
SetBodyStructure sets the "BodyStructure" field.
func (*MessageCreate) SetDate ¶
func (mc *MessageCreate) SetDate(t time.Time) *MessageCreate
SetDate sets the "Date" field.
func (*MessageCreate) SetEnvelope ¶
func (mc *MessageCreate) SetEnvelope(s string) *MessageCreate
SetEnvelope sets the "Envelope" field.
func (*MessageCreate) SetInternalID ¶
func (mc *MessageCreate) SetInternalID(s string) *MessageCreate
SetInternalID sets the "InternalID" field.
func (*MessageCreate) SetMessageID ¶
func (mc *MessageCreate) SetMessageID(s string) *MessageCreate
SetMessageID sets the "MessageID" field.
func (*MessageCreate) SetSize ¶
func (mc *MessageCreate) SetSize(i int) *MessageCreate
SetSize sets the "Size" field.
type MessageCreateBulk ¶
type MessageCreateBulk struct {
// contains filtered or unexported fields
}
MessageCreateBulk is the builder for creating many Message entities in bulk.
func (*MessageCreateBulk) Exec ¶
func (mcb *MessageCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MessageCreateBulk) ExecX ¶
func (mcb *MessageCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MessageDelete ¶
type MessageDelete struct {
// contains filtered or unexported fields
}
MessageDelete is the builder for deleting a Message entity.
func (*MessageDelete) Exec ¶
func (md *MessageDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MessageDelete) ExecX ¶
func (md *MessageDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MessageDelete) Where ¶
func (md *MessageDelete) Where(ps ...predicate.Message) *MessageDelete
Where appends a list predicates to the MessageDelete builder.
type MessageDeleteOne ¶
type MessageDeleteOne struct {
// contains filtered or unexported fields
}
MessageDeleteOne is the builder for deleting a single Message entity.
func (*MessageDeleteOne) Exec ¶
func (mdo *MessageDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MessageDeleteOne) ExecX ¶
func (mdo *MessageDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MessageEdges ¶
type MessageEdges struct { // Flags holds the value of the flags edge. Flags []*MessageFlag `json:"flags,omitempty"` // UIDs holds the value of the UIDs edge. UIDs []*UID `json:"UIDs,omitempty"` // contains filtered or unexported fields }
MessageEdges holds the relations/edges for other nodes in the graph.
func (MessageEdges) FlagsOrErr ¶
func (e MessageEdges) FlagsOrErr() ([]*MessageFlag, error)
FlagsOrErr returns the Flags value or an error if the edge was not loaded in eager-loading.
func (MessageEdges) UIDsOrErr ¶
func (e MessageEdges) UIDsOrErr() ([]*UID, error)
UIDsOrErr returns the UIDs value or an error if the edge was not loaded in eager-loading.
type MessageFlag ¶
type MessageFlag struct { // ID of the ent. ID int `json:"id,omitempty"` // Value holds the value of the "Value" field. Value string `json:"Value,omitempty"` // contains filtered or unexported fields }
MessageFlag is the model entity for the MessageFlag schema.
func (*MessageFlag) String ¶
func (mf *MessageFlag) String() string
String implements the fmt.Stringer.
func (*MessageFlag) Unwrap ¶
func (mf *MessageFlag) Unwrap() *MessageFlag
Unwrap unwraps the MessageFlag entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*MessageFlag) Update ¶
func (mf *MessageFlag) Update() *MessageFlagUpdateOne
Update returns a builder for updating this MessageFlag. Note that you need to call MessageFlag.Unwrap() before calling this method if this MessageFlag was returned from a transaction, and the transaction was committed or rolled back.
type MessageFlagClient ¶
type MessageFlagClient struct {
// contains filtered or unexported fields
}
MessageFlagClient is a client for the MessageFlag schema.
func NewMessageFlagClient ¶
func NewMessageFlagClient(c config) *MessageFlagClient
NewMessageFlagClient returns a client for the MessageFlag from the given config.
func (*MessageFlagClient) Create ¶
func (c *MessageFlagClient) Create() *MessageFlagCreate
Create returns a create builder for MessageFlag.
func (*MessageFlagClient) CreateBulk ¶
func (c *MessageFlagClient) CreateBulk(builders ...*MessageFlagCreate) *MessageFlagCreateBulk
CreateBulk returns a builder for creating a bulk of MessageFlag entities.
func (*MessageFlagClient) Delete ¶
func (c *MessageFlagClient) Delete() *MessageFlagDelete
Delete returns a delete builder for MessageFlag.
func (*MessageFlagClient) DeleteOne ¶
func (c *MessageFlagClient) DeleteOne(mf *MessageFlag) *MessageFlagDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*MessageFlagClient) DeleteOneID ¶
func (c *MessageFlagClient) DeleteOneID(id int) *MessageFlagDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*MessageFlagClient) Get ¶
func (c *MessageFlagClient) Get(ctx context.Context, id int) (*MessageFlag, error)
Get returns a MessageFlag entity by its id.
func (*MessageFlagClient) GetX ¶
func (c *MessageFlagClient) GetX(ctx context.Context, id int) *MessageFlag
GetX is like Get, but panics if an error occurs.
func (*MessageFlagClient) Hooks ¶
func (c *MessageFlagClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MessageFlagClient) Query ¶
func (c *MessageFlagClient) Query() *MessageFlagQuery
Query returns a query builder for MessageFlag.
func (*MessageFlagClient) Update ¶
func (c *MessageFlagClient) Update() *MessageFlagUpdate
Update returns an update builder for MessageFlag.
func (*MessageFlagClient) UpdateOne ¶
func (c *MessageFlagClient) UpdateOne(mf *MessageFlag) *MessageFlagUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MessageFlagClient) UpdateOneID ¶
func (c *MessageFlagClient) UpdateOneID(id int) *MessageFlagUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MessageFlagClient) Use ¶
func (c *MessageFlagClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `messageflag.Hooks(f(g(h())))`.
type MessageFlagCreate ¶
type MessageFlagCreate struct {
// contains filtered or unexported fields
}
MessageFlagCreate is the builder for creating a MessageFlag entity.
func (*MessageFlagCreate) Exec ¶
func (mfc *MessageFlagCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MessageFlagCreate) ExecX ¶
func (mfc *MessageFlagCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageFlagCreate) Mutation ¶
func (mfc *MessageFlagCreate) Mutation() *MessageFlagMutation
Mutation returns the MessageFlagMutation object of the builder.
func (*MessageFlagCreate) Save ¶
func (mfc *MessageFlagCreate) Save(ctx context.Context) (*MessageFlag, error)
Save creates the MessageFlag in the database.
func (*MessageFlagCreate) SaveX ¶
func (mfc *MessageFlagCreate) SaveX(ctx context.Context) *MessageFlag
SaveX calls Save and panics if Save returns an error.
func (*MessageFlagCreate) SetValue ¶
func (mfc *MessageFlagCreate) SetValue(s string) *MessageFlagCreate
SetValue sets the "Value" field.
type MessageFlagCreateBulk ¶
type MessageFlagCreateBulk struct {
// contains filtered or unexported fields
}
MessageFlagCreateBulk is the builder for creating many MessageFlag entities in bulk.
func (*MessageFlagCreateBulk) Exec ¶
func (mfcb *MessageFlagCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MessageFlagCreateBulk) ExecX ¶
func (mfcb *MessageFlagCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageFlagCreateBulk) Save ¶
func (mfcb *MessageFlagCreateBulk) Save(ctx context.Context) ([]*MessageFlag, error)
Save creates the MessageFlag entities in the database.
func (*MessageFlagCreateBulk) SaveX ¶
func (mfcb *MessageFlagCreateBulk) SaveX(ctx context.Context) []*MessageFlag
SaveX is like Save, but panics if an error occurs.
type MessageFlagDelete ¶
type MessageFlagDelete struct {
// contains filtered or unexported fields
}
MessageFlagDelete is the builder for deleting a MessageFlag entity.
func (*MessageFlagDelete) Exec ¶
func (mfd *MessageFlagDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MessageFlagDelete) ExecX ¶
func (mfd *MessageFlagDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MessageFlagDelete) Where ¶
func (mfd *MessageFlagDelete) Where(ps ...predicate.MessageFlag) *MessageFlagDelete
Where appends a list predicates to the MessageFlagDelete builder.
type MessageFlagDeleteOne ¶
type MessageFlagDeleteOne struct {
// contains filtered or unexported fields
}
MessageFlagDeleteOne is the builder for deleting a single MessageFlag entity.
func (*MessageFlagDeleteOne) Exec ¶
func (mfdo *MessageFlagDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MessageFlagDeleteOne) ExecX ¶
func (mfdo *MessageFlagDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type MessageFlagGroupBy ¶
type MessageFlagGroupBy struct {
// contains filtered or unexported fields
}
MessageFlagGroupBy is the group-by builder for MessageFlag entities.
func (*MessageFlagGroupBy) Aggregate ¶
func (mfgb *MessageFlagGroupBy) Aggregate(fns ...AggregateFunc) *MessageFlagGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MessageFlagGroupBy) Bool ¶
func (mfgb *MessageFlagGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) BoolX ¶
func (mfgb *MessageFlagGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MessageFlagGroupBy) Bools ¶
func (mfgb *MessageFlagGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) BoolsX ¶
func (mfgb *MessageFlagGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MessageFlagGroupBy) Float64 ¶
func (mfgb *MessageFlagGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) Float64X ¶
func (mfgb *MessageFlagGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MessageFlagGroupBy) Float64s ¶
func (mfgb *MessageFlagGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) Float64sX ¶
func (mfgb *MessageFlagGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MessageFlagGroupBy) Int ¶
func (mfgb *MessageFlagGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) IntX ¶
func (mfgb *MessageFlagGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MessageFlagGroupBy) Ints ¶
func (mfgb *MessageFlagGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) IntsX ¶
func (mfgb *MessageFlagGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MessageFlagGroupBy) Scan ¶
func (mfgb *MessageFlagGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*MessageFlagGroupBy) ScanX ¶
func (mfgb *MessageFlagGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MessageFlagGroupBy) String ¶
func (mfgb *MessageFlagGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageFlagGroupBy) StringX ¶
func (mfgb *MessageFlagGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MessageFlagMutation ¶
type MessageFlagMutation struct {
// contains filtered or unexported fields
}
MessageFlagMutation represents an operation that mutates the MessageFlag nodes in the graph.
func (*MessageFlagMutation) AddField ¶
func (m *MessageFlagMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MessageFlagMutation) AddedEdges ¶
func (m *MessageFlagMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MessageFlagMutation) AddedField ¶
func (m *MessageFlagMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MessageFlagMutation) AddedFields ¶
func (m *MessageFlagMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MessageFlagMutation) AddedIDs ¶
func (m *MessageFlagMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MessageFlagMutation) ClearEdge ¶
func (m *MessageFlagMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*MessageFlagMutation) ClearField ¶
func (m *MessageFlagMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*MessageFlagMutation) ClearedEdges ¶
func (m *MessageFlagMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MessageFlagMutation) ClearedFields ¶
func (m *MessageFlagMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MessageFlagMutation) Client ¶
func (m MessageFlagMutation) 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 (*MessageFlagMutation) EdgeCleared ¶
func (m *MessageFlagMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MessageFlagMutation) Field ¶
func (m *MessageFlagMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MessageFlagMutation) FieldCleared ¶
func (m *MessageFlagMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MessageFlagMutation) Fields ¶
func (m *MessageFlagMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*MessageFlagMutation) ID ¶
func (m *MessageFlagMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*MessageFlagMutation) IDs ¶
func (m *MessageFlagMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*MessageFlagMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*MessageFlagMutation) OldValue ¶
func (m *MessageFlagMutation) OldValue(ctx context.Context) (v string, err error)
OldValue returns the old "Value" field's value of the MessageFlag entity. If the MessageFlag object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageFlagMutation) Op ¶
func (m *MessageFlagMutation) Op() Op
Op returns the operation name.
func (*MessageFlagMutation) RemovedEdges ¶
func (m *MessageFlagMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MessageFlagMutation) RemovedIDs ¶
func (m *MessageFlagMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*MessageFlagMutation) ResetEdge ¶
func (m *MessageFlagMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*MessageFlagMutation) ResetField ¶
func (m *MessageFlagMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*MessageFlagMutation) ResetValue ¶
func (m *MessageFlagMutation) ResetValue()
ResetValue resets all changes to the "Value" field.
func (*MessageFlagMutation) SetField ¶
func (m *MessageFlagMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MessageFlagMutation) SetValue ¶
func (m *MessageFlagMutation) SetValue(s string)
SetValue sets the "Value" field.
func (MessageFlagMutation) Tx ¶
func (m MessageFlagMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MessageFlagMutation) Type ¶
func (m *MessageFlagMutation) Type() string
Type returns the node type of this mutation (MessageFlag).
func (*MessageFlagMutation) Value ¶
func (m *MessageFlagMutation) Value() (r string, exists bool)
Value returns the value of the "Value" field in the mutation.
func (*MessageFlagMutation) Where ¶
func (m *MessageFlagMutation) Where(ps ...predicate.MessageFlag)
Where appends a list predicates to the MessageFlagMutation builder.
type MessageFlagQuery ¶
type MessageFlagQuery struct {
// contains filtered or unexported fields
}
MessageFlagQuery is the builder for querying MessageFlag entities.
func (*MessageFlagQuery) All ¶
func (mfq *MessageFlagQuery) All(ctx context.Context) ([]*MessageFlag, error)
All executes the query and returns a list of MessageFlags.
func (*MessageFlagQuery) AllX ¶
func (mfq *MessageFlagQuery) AllX(ctx context.Context) []*MessageFlag
AllX is like All, but panics if an error occurs.
func (*MessageFlagQuery) Clone ¶
func (mfq *MessageFlagQuery) Clone() *MessageFlagQuery
Clone returns a duplicate of the MessageFlagQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MessageFlagQuery) Count ¶
func (mfq *MessageFlagQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MessageFlagQuery) CountX ¶
func (mfq *MessageFlagQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MessageFlagQuery) Exist ¶
func (mfq *MessageFlagQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MessageFlagQuery) ExistX ¶
func (mfq *MessageFlagQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MessageFlagQuery) First ¶
func (mfq *MessageFlagQuery) First(ctx context.Context) (*MessageFlag, error)
First returns the first MessageFlag entity from the query. Returns a *NotFoundError when no MessageFlag was found.
func (*MessageFlagQuery) FirstID ¶
func (mfq *MessageFlagQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first MessageFlag ID from the query. Returns a *NotFoundError when no MessageFlag ID was found.
func (*MessageFlagQuery) FirstIDX ¶
func (mfq *MessageFlagQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*MessageFlagQuery) FirstX ¶
func (mfq *MessageFlagQuery) FirstX(ctx context.Context) *MessageFlag
FirstX is like First, but panics if an error occurs.
func (*MessageFlagQuery) GroupBy ¶
func (mfq *MessageFlagQuery) GroupBy(field string, fields ...string) *MessageFlagGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Value string `json:"Value,omitempty"` Count int `json:"count,omitempty"` } client.MessageFlag.Query(). GroupBy(messageflag.FieldValue). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MessageFlagQuery) IDs ¶
func (mfq *MessageFlagQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of MessageFlag IDs.
func (*MessageFlagQuery) IDsX ¶
func (mfq *MessageFlagQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*MessageFlagQuery) Limit ¶
func (mfq *MessageFlagQuery) Limit(limit int) *MessageFlagQuery
Limit adds a limit step to the query.
func (*MessageFlagQuery) Offset ¶
func (mfq *MessageFlagQuery) Offset(offset int) *MessageFlagQuery
Offset adds an offset step to the query.
func (*MessageFlagQuery) Only ¶
func (mfq *MessageFlagQuery) Only(ctx context.Context) (*MessageFlag, error)
Only returns a single MessageFlag entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one MessageFlag entity is found. Returns a *NotFoundError when no MessageFlag entities are found.
func (*MessageFlagQuery) OnlyID ¶
func (mfq *MessageFlagQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only MessageFlag ID in the query. Returns a *NotSingularError when more than one MessageFlag ID is found. Returns a *NotFoundError when no entities are found.
func (*MessageFlagQuery) OnlyIDX ¶
func (mfq *MessageFlagQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MessageFlagQuery) OnlyX ¶
func (mfq *MessageFlagQuery) OnlyX(ctx context.Context) *MessageFlag
OnlyX is like Only, but panics if an error occurs.
func (*MessageFlagQuery) Order ¶
func (mfq *MessageFlagQuery) Order(o ...OrderFunc) *MessageFlagQuery
Order adds an order step to the query.
func (*MessageFlagQuery) Select ¶
func (mfq *MessageFlagQuery) Select(fields ...string) *MessageFlagSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Value string `json:"Value,omitempty"` } client.MessageFlag.Query(). Select(messageflag.FieldValue). Scan(ctx, &v)
func (*MessageFlagQuery) Unique ¶
func (mfq *MessageFlagQuery) Unique(unique bool) *MessageFlagQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*MessageFlagQuery) Where ¶
func (mfq *MessageFlagQuery) Where(ps ...predicate.MessageFlag) *MessageFlagQuery
Where adds a new predicate for the MessageFlagQuery builder.
type MessageFlagSelect ¶
type MessageFlagSelect struct { *MessageFlagQuery // contains filtered or unexported fields }
MessageFlagSelect is the builder for selecting fields of MessageFlag entities.
func (*MessageFlagSelect) Bool ¶
func (mfs *MessageFlagSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) BoolX ¶
func (mfs *MessageFlagSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MessageFlagSelect) Bools ¶
func (mfs *MessageFlagSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) BoolsX ¶
func (mfs *MessageFlagSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MessageFlagSelect) Float64 ¶
func (mfs *MessageFlagSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) Float64X ¶
func (mfs *MessageFlagSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MessageFlagSelect) Float64s ¶
func (mfs *MessageFlagSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) Float64sX ¶
func (mfs *MessageFlagSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MessageFlagSelect) Int ¶
func (mfs *MessageFlagSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) IntX ¶
func (mfs *MessageFlagSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MessageFlagSelect) Ints ¶
func (mfs *MessageFlagSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) IntsX ¶
func (mfs *MessageFlagSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MessageFlagSelect) Scan ¶
func (mfs *MessageFlagSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*MessageFlagSelect) ScanX ¶
func (mfs *MessageFlagSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MessageFlagSelect) String ¶
func (mfs *MessageFlagSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*MessageFlagSelect) StringX ¶
func (mfs *MessageFlagSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MessageFlagUpdate ¶
type MessageFlagUpdate struct {
// contains filtered or unexported fields
}
MessageFlagUpdate is the builder for updating MessageFlag entities.
func (*MessageFlagUpdate) Exec ¶
func (mfu *MessageFlagUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MessageFlagUpdate) ExecX ¶
func (mfu *MessageFlagUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageFlagUpdate) Mutation ¶
func (mfu *MessageFlagUpdate) Mutation() *MessageFlagMutation
Mutation returns the MessageFlagMutation object of the builder.
func (*MessageFlagUpdate) Save ¶
func (mfu *MessageFlagUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MessageFlagUpdate) SaveX ¶
func (mfu *MessageFlagUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MessageFlagUpdate) SetValue ¶
func (mfu *MessageFlagUpdate) SetValue(s string) *MessageFlagUpdate
SetValue sets the "Value" field.
func (*MessageFlagUpdate) Where ¶
func (mfu *MessageFlagUpdate) Where(ps ...predicate.MessageFlag) *MessageFlagUpdate
Where appends a list predicates to the MessageFlagUpdate builder.
type MessageFlagUpdateOne ¶
type MessageFlagUpdateOne struct {
// contains filtered or unexported fields
}
MessageFlagUpdateOne is the builder for updating a single MessageFlag entity.
func (*MessageFlagUpdateOne) Exec ¶
func (mfuo *MessageFlagUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MessageFlagUpdateOne) ExecX ¶
func (mfuo *MessageFlagUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageFlagUpdateOne) Mutation ¶
func (mfuo *MessageFlagUpdateOne) Mutation() *MessageFlagMutation
Mutation returns the MessageFlagMutation object of the builder.
func (*MessageFlagUpdateOne) Save ¶
func (mfuo *MessageFlagUpdateOne) Save(ctx context.Context) (*MessageFlag, error)
Save executes the query and returns the updated MessageFlag entity.
func (*MessageFlagUpdateOne) SaveX ¶
func (mfuo *MessageFlagUpdateOne) SaveX(ctx context.Context) *MessageFlag
SaveX is like Save, but panics if an error occurs.
func (*MessageFlagUpdateOne) Select ¶
func (mfuo *MessageFlagUpdateOne) Select(field string, fields ...string) *MessageFlagUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MessageFlagUpdateOne) SetValue ¶
func (mfuo *MessageFlagUpdateOne) SetValue(s string) *MessageFlagUpdateOne
SetValue sets the "Value" field.
type MessageFlags ¶
type MessageFlags []*MessageFlag
MessageFlags is a parsable slice of MessageFlag.
type MessageGroupBy ¶
type MessageGroupBy struct {
// contains filtered or unexported fields
}
MessageGroupBy is the group-by builder for Message entities.
func (*MessageGroupBy) Aggregate ¶
func (mgb *MessageGroupBy) Aggregate(fns ...AggregateFunc) *MessageGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MessageGroupBy) Bool ¶
func (mgb *MessageGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) BoolX ¶
func (mgb *MessageGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MessageGroupBy) Bools ¶
func (mgb *MessageGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) BoolsX ¶
func (mgb *MessageGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MessageGroupBy) Float64 ¶
func (mgb *MessageGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) Float64X ¶
func (mgb *MessageGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MessageGroupBy) Float64s ¶
func (mgb *MessageGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) Float64sX ¶
func (mgb *MessageGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MessageGroupBy) Int ¶
func (mgb *MessageGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) IntX ¶
func (mgb *MessageGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MessageGroupBy) Ints ¶
func (mgb *MessageGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) IntsX ¶
func (mgb *MessageGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MessageGroupBy) Scan ¶
func (mgb *MessageGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*MessageGroupBy) ScanX ¶
func (mgb *MessageGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MessageGroupBy) String ¶
func (mgb *MessageGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*MessageGroupBy) StringX ¶
func (mgb *MessageGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MessageMutation ¶
type MessageMutation struct {
// contains filtered or unexported fields
}
MessageMutation represents an operation that mutates the Message nodes in the graph.
func (*MessageMutation) AddField ¶
func (m *MessageMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MessageMutation) AddFlagIDs ¶
func (m *MessageMutation) AddFlagIDs(ids ...int)
AddFlagIDs adds the "flags" edge to the MessageFlag entity by ids.
func (*MessageMutation) AddSize ¶
func (m *MessageMutation) AddSize(i int)
AddSize adds i to the "Size" field.
func (*MessageMutation) AddUIDIDs ¶
func (m *MessageMutation) AddUIDIDs(ids ...int)
AddUIDIDs adds the "UIDs" edge to the UID entity by ids.
func (*MessageMutation) AddedEdges ¶
func (m *MessageMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MessageMutation) AddedField ¶
func (m *MessageMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MessageMutation) AddedFields ¶
func (m *MessageMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MessageMutation) AddedIDs ¶
func (m *MessageMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MessageMutation) AddedSize ¶
func (m *MessageMutation) AddedSize() (r int, exists bool)
AddedSize returns the value that was added to the "Size" field in this mutation.
func (*MessageMutation) Body ¶
func (m *MessageMutation) Body() (r string, exists bool)
Body returns the value of the "Body" field in the mutation.
func (*MessageMutation) BodyStructure ¶
func (m *MessageMutation) BodyStructure() (r string, exists bool)
BodyStructure returns the value of the "BodyStructure" field in the mutation.
func (*MessageMutation) ClearEdge ¶
func (m *MessageMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*MessageMutation) ClearField ¶
func (m *MessageMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*MessageMutation) ClearFlags ¶
func (m *MessageMutation) ClearFlags()
ClearFlags clears the "flags" edge to the MessageFlag entity.
func (*MessageMutation) ClearUIDs ¶
func (m *MessageMutation) ClearUIDs()
ClearUIDs clears the "UIDs" edge to the UID entity.
func (*MessageMutation) ClearedEdges ¶
func (m *MessageMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MessageMutation) ClearedFields ¶
func (m *MessageMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MessageMutation) Client ¶
func (m MessageMutation) 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 (*MessageMutation) Date ¶
func (m *MessageMutation) Date() (r time.Time, exists bool)
Date returns the value of the "Date" field in the mutation.
func (*MessageMutation) EdgeCleared ¶
func (m *MessageMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MessageMutation) Envelope ¶
func (m *MessageMutation) Envelope() (r string, exists bool)
Envelope returns the value of the "Envelope" field in the mutation.
func (*MessageMutation) Field ¶
func (m *MessageMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*MessageMutation) FieldCleared ¶
func (m *MessageMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MessageMutation) Fields ¶
func (m *MessageMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*MessageMutation) FlagsCleared ¶
func (m *MessageMutation) FlagsCleared() bool
FlagsCleared reports if the "flags" edge to the MessageFlag entity was cleared.
func (*MessageMutation) FlagsIDs ¶
func (m *MessageMutation) FlagsIDs() (ids []int)
FlagsIDs returns the "flags" edge IDs in the mutation.
func (*MessageMutation) ID ¶
func (m *MessageMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*MessageMutation) IDs ¶
func (m *MessageMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*MessageMutation) InternalID ¶
func (m *MessageMutation) InternalID() (r string, exists bool)
InternalID returns the value of the "InternalID" field in the mutation.
func (*MessageMutation) MessageID ¶
func (m *MessageMutation) MessageID() (r string, exists bool)
MessageID returns the value of the "MessageID" field in the mutation.
func (*MessageMutation) OldBody ¶
func (m *MessageMutation) OldBody(ctx context.Context) (v string, err error)
OldBody returns the old "Body" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) OldBodyStructure ¶
func (m *MessageMutation) OldBodyStructure(ctx context.Context) (v string, err error)
OldBodyStructure returns the old "BodyStructure" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) OldDate ¶
OldDate returns the old "Date" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) OldEnvelope ¶
func (m *MessageMutation) OldEnvelope(ctx context.Context) (v string, err error)
OldEnvelope returns the old "Envelope" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*MessageMutation) OldInternalID ¶
func (m *MessageMutation) OldInternalID(ctx context.Context) (v string, err error)
OldInternalID returns the old "InternalID" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) OldMessageID ¶
func (m *MessageMutation) OldMessageID(ctx context.Context) (v string, err error)
OldMessageID returns the old "MessageID" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) OldSize ¶
func (m *MessageMutation) OldSize(ctx context.Context) (v int, err error)
OldSize returns the old "Size" field's value of the Message entity. If the Message object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*MessageMutation) RemoveFlagIDs ¶
func (m *MessageMutation) RemoveFlagIDs(ids ...int)
RemoveFlagIDs removes the "flags" edge to the MessageFlag entity by IDs.
func (*MessageMutation) RemoveUIDIDs ¶
func (m *MessageMutation) RemoveUIDIDs(ids ...int)
RemoveUIDIDs removes the "UIDs" edge to the UID entity by IDs.
func (*MessageMutation) RemovedEdges ¶
func (m *MessageMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MessageMutation) RemovedFlagsIDs ¶
func (m *MessageMutation) RemovedFlagsIDs() (ids []int)
RemovedFlags returns the removed IDs of the "flags" edge to the MessageFlag entity.
func (*MessageMutation) RemovedIDs ¶
func (m *MessageMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*MessageMutation) RemovedUIDsIDs ¶
func (m *MessageMutation) RemovedUIDsIDs() (ids []int)
RemovedUIDs returns the removed IDs of the "UIDs" edge to the UID entity.
func (*MessageMutation) ResetBody ¶
func (m *MessageMutation) ResetBody()
ResetBody resets all changes to the "Body" field.
func (*MessageMutation) ResetBodyStructure ¶
func (m *MessageMutation) ResetBodyStructure()
ResetBodyStructure resets all changes to the "BodyStructure" field.
func (*MessageMutation) ResetDate ¶
func (m *MessageMutation) ResetDate()
ResetDate resets all changes to the "Date" field.
func (*MessageMutation) ResetEdge ¶
func (m *MessageMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*MessageMutation) ResetEnvelope ¶
func (m *MessageMutation) ResetEnvelope()
ResetEnvelope resets all changes to the "Envelope" field.
func (*MessageMutation) ResetField ¶
func (m *MessageMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*MessageMutation) ResetFlags ¶
func (m *MessageMutation) ResetFlags()
ResetFlags resets all changes to the "flags" edge.
func (*MessageMutation) ResetInternalID ¶
func (m *MessageMutation) ResetInternalID()
ResetInternalID resets all changes to the "InternalID" field.
func (*MessageMutation) ResetMessageID ¶
func (m *MessageMutation) ResetMessageID()
ResetMessageID resets all changes to the "MessageID" field.
func (*MessageMutation) ResetSize ¶
func (m *MessageMutation) ResetSize()
ResetSize resets all changes to the "Size" field.
func (*MessageMutation) ResetUIDs ¶
func (m *MessageMutation) ResetUIDs()
ResetUIDs resets all changes to the "UIDs" edge.
func (*MessageMutation) SetBody ¶
func (m *MessageMutation) SetBody(s string)
SetBody sets the "Body" field.
func (*MessageMutation) SetBodyStructure ¶
func (m *MessageMutation) SetBodyStructure(s string)
SetBodyStructure sets the "BodyStructure" field.
func (*MessageMutation) SetDate ¶
func (m *MessageMutation) SetDate(t time.Time)
SetDate sets the "Date" field.
func (*MessageMutation) SetEnvelope ¶
func (m *MessageMutation) SetEnvelope(s string)
SetEnvelope sets the "Envelope" field.
func (*MessageMutation) SetField ¶
func (m *MessageMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*MessageMutation) SetInternalID ¶
func (m *MessageMutation) SetInternalID(s string)
SetInternalID sets the "InternalID" field.
func (*MessageMutation) SetMessageID ¶
func (m *MessageMutation) SetMessageID(s string)
SetMessageID sets the "MessageID" field.
func (*MessageMutation) SetSize ¶
func (m *MessageMutation) SetSize(i int)
SetSize sets the "Size" field.
func (*MessageMutation) Size ¶
func (m *MessageMutation) Size() (r int, exists bool)
Size returns the value of the "Size" field in the mutation.
func (MessageMutation) Tx ¶
func (m MessageMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MessageMutation) Type ¶
func (m *MessageMutation) Type() string
Type returns the node type of this mutation (Message).
func (*MessageMutation) UIDsCleared ¶
func (m *MessageMutation) UIDsCleared() bool
UIDsCleared reports if the "UIDs" edge to the UID entity was cleared.
func (*MessageMutation) UIDsIDs ¶
func (m *MessageMutation) UIDsIDs() (ids []int)
UIDsIDs returns the "UIDs" edge IDs in the mutation.
func (*MessageMutation) Where ¶
func (m *MessageMutation) Where(ps ...predicate.Message)
Where appends a list predicates to the MessageMutation builder.
type MessageQuery ¶
type MessageQuery struct {
// contains filtered or unexported fields
}
MessageQuery is the builder for querying Message entities.
func (*MessageQuery) All ¶
func (mq *MessageQuery) All(ctx context.Context) ([]*Message, error)
All executes the query and returns a list of Messages.
func (*MessageQuery) AllX ¶
func (mq *MessageQuery) AllX(ctx context.Context) []*Message
AllX is like All, but panics if an error occurs.
func (*MessageQuery) Clone ¶
func (mq *MessageQuery) Clone() *MessageQuery
Clone returns a duplicate of the MessageQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MessageQuery) Count ¶
func (mq *MessageQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MessageQuery) CountX ¶
func (mq *MessageQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MessageQuery) Exist ¶
func (mq *MessageQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MessageQuery) ExistX ¶
func (mq *MessageQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MessageQuery) First ¶
func (mq *MessageQuery) First(ctx context.Context) (*Message, error)
First returns the first Message entity from the query. Returns a *NotFoundError when no Message was found.
func (*MessageQuery) FirstID ¶
func (mq *MessageQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Message ID from the query. Returns a *NotFoundError when no Message ID was found.
func (*MessageQuery) FirstIDX ¶
func (mq *MessageQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*MessageQuery) FirstX ¶
func (mq *MessageQuery) FirstX(ctx context.Context) *Message
FirstX is like First, but panics if an error occurs.
func (*MessageQuery) GroupBy ¶
func (mq *MessageQuery) GroupBy(field string, fields ...string) *MessageGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { MessageID string `json:"MessageID,omitempty"` Count int `json:"count,omitempty"` } client.Message.Query(). GroupBy(message.FieldMessageID). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MessageQuery) IDs ¶
func (mq *MessageQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of Message IDs.
func (*MessageQuery) IDsX ¶
func (mq *MessageQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*MessageQuery) Limit ¶
func (mq *MessageQuery) Limit(limit int) *MessageQuery
Limit adds a limit step to the query.
func (*MessageQuery) Offset ¶
func (mq *MessageQuery) Offset(offset int) *MessageQuery
Offset adds an offset step to the query.
func (*MessageQuery) Only ¶
func (mq *MessageQuery) Only(ctx context.Context) (*Message, error)
Only returns a single Message entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Message entity is found. Returns a *NotFoundError when no Message entities are found.
func (*MessageQuery) OnlyID ¶
func (mq *MessageQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Message ID in the query. Returns a *NotSingularError when more than one Message ID is found. Returns a *NotFoundError when no entities are found.
func (*MessageQuery) OnlyIDX ¶
func (mq *MessageQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MessageQuery) OnlyX ¶
func (mq *MessageQuery) OnlyX(ctx context.Context) *Message
OnlyX is like Only, but panics if an error occurs.
func (*MessageQuery) Order ¶
func (mq *MessageQuery) Order(o ...OrderFunc) *MessageQuery
Order adds an order step to the query.
func (*MessageQuery) QueryFlags ¶
func (mq *MessageQuery) QueryFlags() *MessageFlagQuery
QueryFlags chains the current query on the "flags" edge.
func (*MessageQuery) QueryUIDs ¶
func (mq *MessageQuery) QueryUIDs() *UIDQuery
QueryUIDs chains the current query on the "UIDs" edge.
func (*MessageQuery) Select ¶
func (mq *MessageQuery) Select(fields ...string) *MessageSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { MessageID string `json:"MessageID,omitempty"` } client.Message.Query(). Select(message.FieldMessageID). Scan(ctx, &v)
func (*MessageQuery) Unique ¶
func (mq *MessageQuery) Unique(unique bool) *MessageQuery
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*MessageQuery) Where ¶
func (mq *MessageQuery) Where(ps ...predicate.Message) *MessageQuery
Where adds a new predicate for the MessageQuery builder.
func (*MessageQuery) WithFlags ¶
func (mq *MessageQuery) WithFlags(opts ...func(*MessageFlagQuery)) *MessageQuery
WithFlags tells the query-builder to eager-load the nodes that are connected to the "flags" edge. The optional arguments are used to configure the query builder of the edge.
func (*MessageQuery) WithUIDs ¶
func (mq *MessageQuery) WithUIDs(opts ...func(*UIDQuery)) *MessageQuery
WithUIDs tells the query-builder to eager-load the nodes that are connected to the "UIDs" edge. The optional arguments are used to configure the query builder of the edge.
type MessageSelect ¶
type MessageSelect struct { *MessageQuery // contains filtered or unexported fields }
MessageSelect is the builder for selecting fields of Message entities.
func (*MessageSelect) Bool ¶
func (ms *MessageSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MessageSelect) BoolX ¶
func (ms *MessageSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*MessageSelect) Bools ¶
func (ms *MessageSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MessageSelect) BoolsX ¶
func (ms *MessageSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*MessageSelect) Float64 ¶
func (ms *MessageSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MessageSelect) Float64X ¶
func (ms *MessageSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*MessageSelect) Float64s ¶
func (ms *MessageSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MessageSelect) Float64sX ¶
func (ms *MessageSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*MessageSelect) Int ¶
func (ms *MessageSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MessageSelect) IntX ¶
func (ms *MessageSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*MessageSelect) Ints ¶
func (ms *MessageSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MessageSelect) IntsX ¶
func (ms *MessageSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*MessageSelect) Scan ¶
func (ms *MessageSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*MessageSelect) ScanX ¶
func (ms *MessageSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*MessageSelect) String ¶
func (ms *MessageSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*MessageSelect) StringX ¶
func (ms *MessageSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type MessageUpdate ¶
type MessageUpdate struct {
// contains filtered or unexported fields
}
MessageUpdate is the builder for updating Message entities.
func (*MessageUpdate) AddFlagIDs ¶
func (mu *MessageUpdate) AddFlagIDs(ids ...int) *MessageUpdate
AddFlagIDs adds the "flags" edge to the MessageFlag entity by IDs.
func (*MessageUpdate) AddFlags ¶
func (mu *MessageUpdate) AddFlags(m ...*MessageFlag) *MessageUpdate
AddFlags adds the "flags" edges to the MessageFlag entity.
func (*MessageUpdate) AddSize ¶
func (mu *MessageUpdate) AddSize(i int) *MessageUpdate
AddSize adds i to the "Size" field.
func (*MessageUpdate) AddUIDIDs ¶
func (mu *MessageUpdate) AddUIDIDs(ids ...int) *MessageUpdate
AddUIDIDs adds the "UIDs" edge to the UID entity by IDs.
func (*MessageUpdate) AddUIDs ¶
func (mu *MessageUpdate) AddUIDs(u ...*UID) *MessageUpdate
AddUIDs adds the "UIDs" edges to the UID entity.
func (*MessageUpdate) ClearFlags ¶
func (mu *MessageUpdate) ClearFlags() *MessageUpdate
ClearFlags clears all "flags" edges to the MessageFlag entity.
func (*MessageUpdate) ClearUIDs ¶
func (mu *MessageUpdate) ClearUIDs() *MessageUpdate
ClearUIDs clears all "UIDs" edges to the UID entity.
func (*MessageUpdate) Exec ¶
func (mu *MessageUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MessageUpdate) ExecX ¶
func (mu *MessageUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageUpdate) Mutation ¶
func (mu *MessageUpdate) Mutation() *MessageMutation
Mutation returns the MessageMutation object of the builder.
func (*MessageUpdate) RemoveFlagIDs ¶
func (mu *MessageUpdate) RemoveFlagIDs(ids ...int) *MessageUpdate
RemoveFlagIDs removes the "flags" edge to MessageFlag entities by IDs.
func (*MessageUpdate) RemoveFlags ¶
func (mu *MessageUpdate) RemoveFlags(m ...*MessageFlag) *MessageUpdate
RemoveFlags removes "flags" edges to MessageFlag entities.
func (*MessageUpdate) RemoveUIDIDs ¶
func (mu *MessageUpdate) RemoveUIDIDs(ids ...int) *MessageUpdate
RemoveUIDIDs removes the "UIDs" edge to UID entities by IDs.
func (*MessageUpdate) RemoveUIDs ¶
func (mu *MessageUpdate) RemoveUIDs(u ...*UID) *MessageUpdate
RemoveUIDs removes "UIDs" edges to UID entities.
func (*MessageUpdate) Save ¶
func (mu *MessageUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MessageUpdate) SaveX ¶
func (mu *MessageUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MessageUpdate) SetBody ¶
func (mu *MessageUpdate) SetBody(s string) *MessageUpdate
SetBody sets the "Body" field.
func (*MessageUpdate) SetBodyStructure ¶
func (mu *MessageUpdate) SetBodyStructure(s string) *MessageUpdate
SetBodyStructure sets the "BodyStructure" field.
func (*MessageUpdate) SetDate ¶
func (mu *MessageUpdate) SetDate(t time.Time) *MessageUpdate
SetDate sets the "Date" field.
func (*MessageUpdate) SetEnvelope ¶
func (mu *MessageUpdate) SetEnvelope(s string) *MessageUpdate
SetEnvelope sets the "Envelope" field.
func (*MessageUpdate) SetInternalID ¶
func (mu *MessageUpdate) SetInternalID(s string) *MessageUpdate
SetInternalID sets the "InternalID" field.
func (*MessageUpdate) SetMessageID ¶
func (mu *MessageUpdate) SetMessageID(s string) *MessageUpdate
SetMessageID sets the "MessageID" field.
func (*MessageUpdate) SetSize ¶
func (mu *MessageUpdate) SetSize(i int) *MessageUpdate
SetSize sets the "Size" field.
func (*MessageUpdate) Where ¶
func (mu *MessageUpdate) Where(ps ...predicate.Message) *MessageUpdate
Where appends a list predicates to the MessageUpdate builder.
type MessageUpdateOne ¶
type MessageUpdateOne struct {
// contains filtered or unexported fields
}
MessageUpdateOne is the builder for updating a single Message entity.
func (*MessageUpdateOne) AddFlagIDs ¶
func (muo *MessageUpdateOne) AddFlagIDs(ids ...int) *MessageUpdateOne
AddFlagIDs adds the "flags" edge to the MessageFlag entity by IDs.
func (*MessageUpdateOne) AddFlags ¶
func (muo *MessageUpdateOne) AddFlags(m ...*MessageFlag) *MessageUpdateOne
AddFlags adds the "flags" edges to the MessageFlag entity.
func (*MessageUpdateOne) AddSize ¶
func (muo *MessageUpdateOne) AddSize(i int) *MessageUpdateOne
AddSize adds i to the "Size" field.
func (*MessageUpdateOne) AddUIDIDs ¶
func (muo *MessageUpdateOne) AddUIDIDs(ids ...int) *MessageUpdateOne
AddUIDIDs adds the "UIDs" edge to the UID entity by IDs.
func (*MessageUpdateOne) AddUIDs ¶
func (muo *MessageUpdateOne) AddUIDs(u ...*UID) *MessageUpdateOne
AddUIDs adds the "UIDs" edges to the UID entity.
func (*MessageUpdateOne) ClearFlags ¶
func (muo *MessageUpdateOne) ClearFlags() *MessageUpdateOne
ClearFlags clears all "flags" edges to the MessageFlag entity.
func (*MessageUpdateOne) ClearUIDs ¶
func (muo *MessageUpdateOne) ClearUIDs() *MessageUpdateOne
ClearUIDs clears all "UIDs" edges to the UID entity.
func (*MessageUpdateOne) Exec ¶
func (muo *MessageUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MessageUpdateOne) ExecX ¶
func (muo *MessageUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MessageUpdateOne) Mutation ¶
func (muo *MessageUpdateOne) Mutation() *MessageMutation
Mutation returns the MessageMutation object of the builder.
func (*MessageUpdateOne) RemoveFlagIDs ¶
func (muo *MessageUpdateOne) RemoveFlagIDs(ids ...int) *MessageUpdateOne
RemoveFlagIDs removes the "flags" edge to MessageFlag entities by IDs.
func (*MessageUpdateOne) RemoveFlags ¶
func (muo *MessageUpdateOne) RemoveFlags(m ...*MessageFlag) *MessageUpdateOne
RemoveFlags removes "flags" edges to MessageFlag entities.
func (*MessageUpdateOne) RemoveUIDIDs ¶
func (muo *MessageUpdateOne) RemoveUIDIDs(ids ...int) *MessageUpdateOne
RemoveUIDIDs removes the "UIDs" edge to UID entities by IDs.
func (*MessageUpdateOne) RemoveUIDs ¶
func (muo *MessageUpdateOne) RemoveUIDs(u ...*UID) *MessageUpdateOne
RemoveUIDs removes "UIDs" edges to UID entities.
func (*MessageUpdateOne) Save ¶
func (muo *MessageUpdateOne) Save(ctx context.Context) (*Message, error)
Save executes the query and returns the updated Message entity.
func (*MessageUpdateOne) SaveX ¶
func (muo *MessageUpdateOne) SaveX(ctx context.Context) *Message
SaveX is like Save, but panics if an error occurs.
func (*MessageUpdateOne) Select ¶
func (muo *MessageUpdateOne) Select(field string, fields ...string) *MessageUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MessageUpdateOne) SetBody ¶
func (muo *MessageUpdateOne) SetBody(s string) *MessageUpdateOne
SetBody sets the "Body" field.
func (*MessageUpdateOne) SetBodyStructure ¶
func (muo *MessageUpdateOne) SetBodyStructure(s string) *MessageUpdateOne
SetBodyStructure sets the "BodyStructure" field.
func (*MessageUpdateOne) SetDate ¶
func (muo *MessageUpdateOne) SetDate(t time.Time) *MessageUpdateOne
SetDate sets the "Date" field.
func (*MessageUpdateOne) SetEnvelope ¶
func (muo *MessageUpdateOne) SetEnvelope(s string) *MessageUpdateOne
SetEnvelope sets the "Envelope" field.
func (*MessageUpdateOne) SetInternalID ¶
func (muo *MessageUpdateOne) SetInternalID(s string) *MessageUpdateOne
SetInternalID sets the "InternalID" field.
func (*MessageUpdateOne) SetMessageID ¶
func (muo *MessageUpdateOne) SetMessageID(s string) *MessageUpdateOne
SetMessageID sets the "MessageID" field.
func (*MessageUpdateOne) SetSize ¶
func (muo *MessageUpdateOne) SetSize(i int) *MessageUpdateOne
SetSize sets the "Size" field.
type MutateFunc ¶
type MutateFunc = ent.MutateFunc
ent aliases to avoid import conflicts in user's code.
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 RollbackFunc ¶
The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.
type RollbackHook ¶
type RollbackHook func(Rollbacker) Rollbacker
RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:
hook := func(next ent.Rollbacker) ent.Rollbacker { return ent.RollbackFunc(func(ctx context.Context, tx *ent.Tx) error { // Do some stuff before. if err := next.Rollback(ctx, tx); err != nil { return err } // Do some stuff after. return nil }) }
type Rollbacker ¶
Rollbacker is the interface that wraps the Rollback method.
type Tx ¶
type Tx struct { // Mailbox is the client for interacting with the Mailbox builders. Mailbox *MailboxClient // MailboxAttr is the client for interacting with the MailboxAttr builders. MailboxAttr *MailboxAttrClient // MailboxFlag is the client for interacting with the MailboxFlag builders. MailboxFlag *MailboxFlagClient // MailboxPermFlag is the client for interacting with the MailboxPermFlag builders. MailboxPermFlag *MailboxPermFlagClient // Message is the client for interacting with the Message builders. Message *MessageClient // MessageFlag is the client for interacting with the MessageFlag builders. MessageFlag *MessageFlagClient // UID is the client for interacting with the UID builders. UID *UIDClient // contains filtered or unexported fields }
Tx is a transactional client that is created by calling Client.Tx().
func TxFromContext ¶
TxFromContext returns a Tx stored inside a context, or nil if there isn't one.
func (*Tx) OnRollback ¶
func (tx *Tx) OnRollback(f RollbackHook)
OnRollback adds a hook to call on rollback.
type UID ¶
type UID struct { // ID of the ent. ID int `json:"id,omitempty"` // UID holds the value of the "UID" field. UID int `json:"UID,omitempty"` // Deleted holds the value of the "Deleted" field. Deleted bool `json:"Deleted,omitempty"` // Recent holds the value of the "Recent" field. Recent bool `json:"Recent,omitempty"` // InDeletionPool holds the value of the "InDeletionPool" field. InDeletionPool bool `json:"InDeletionPool,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the UIDQuery when eager-loading is set. Edges UIDEdges `json:"edges"` // contains filtered or unexported fields }
UID is the model entity for the UID schema.
func (*UID) QueryMailbox ¶
func (u *UID) QueryMailbox() *MailboxQuery
QueryMailbox queries the "mailbox" edge of the UID entity.
func (*UID) QueryMessage ¶
func (u *UID) QueryMessage() *MessageQuery
QueryMessage queries the "message" edge of the UID entity.
func (*UID) Unwrap ¶
Unwrap unwraps the UID entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*UID) Update ¶
func (u *UID) Update() *UIDUpdateOne
Update returns a builder for updating this UID. Note that you need to call UID.Unwrap() before calling this method if this UID was returned from a transaction, and the transaction was committed or rolled back.
type UIDClient ¶
type UIDClient struct {
// contains filtered or unexported fields
}
UIDClient is a client for the UID schema.
func NewUIDClient ¶
func NewUIDClient(c config) *UIDClient
NewUIDClient returns a client for the UID from the given config.
func (*UIDClient) CreateBulk ¶
func (c *UIDClient) CreateBulk(builders ...*UIDCreate) *UIDCreateBulk
CreateBulk returns a builder for creating a bulk of UID entities.
func (*UIDClient) DeleteOne ¶
func (c *UIDClient) DeleteOne(u *UID) *UIDDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*UIDClient) DeleteOneID ¶
func (c *UIDClient) DeleteOneID(id int) *UIDDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*UIDClient) QueryMailbox ¶
func (c *UIDClient) QueryMailbox(u *UID) *MailboxQuery
QueryMailbox queries the mailbox edge of a UID.
func (*UIDClient) QueryMessage ¶
func (c *UIDClient) QueryMessage(u *UID) *MessageQuery
QueryMessage queries the message edge of a UID.
func (*UIDClient) UpdateOne ¶
func (c *UIDClient) UpdateOne(u *UID) *UIDUpdateOne
UpdateOne returns an update builder for the given entity.
func (*UIDClient) UpdateOneID ¶
func (c *UIDClient) UpdateOneID(id int) *UIDUpdateOne
UpdateOneID returns an update builder for the given id.
type UIDCreate ¶
type UIDCreate struct {
// contains filtered or unexported fields
}
UIDCreate is the builder for creating a UID entity.
func (*UIDCreate) Mutation ¶
func (uc *UIDCreate) Mutation() *UIDMutation
Mutation returns the UIDMutation object of the builder.
func (*UIDCreate) SetDeleted ¶
SetDeleted sets the "Deleted" field.
func (*UIDCreate) SetInDeletionPool ¶
SetInDeletionPool sets the "InDeletionPool" field.
func (*UIDCreate) SetMailbox ¶
SetMailbox sets the "mailbox" edge to the Mailbox entity.
func (*UIDCreate) SetMailboxID ¶
SetMailboxID sets the "mailbox" edge to the Mailbox entity by ID.
func (*UIDCreate) SetMessage ¶
SetMessage sets the "message" edge to the Message entity.
func (*UIDCreate) SetMessageID ¶
SetMessageID sets the "message" edge to the Message entity by ID.
func (*UIDCreate) SetNillableDeleted ¶
SetNillableDeleted sets the "Deleted" field if the given value is not nil.
func (*UIDCreate) SetNillableInDeletionPool ¶
SetNillableInDeletionPool sets the "InDeletionPool" field if the given value is not nil.
func (*UIDCreate) SetNillableMailboxID ¶
SetNillableMailboxID sets the "mailbox" edge to the Mailbox entity by ID if the given value is not nil.
func (*UIDCreate) SetNillableMessageID ¶
SetNillableMessageID sets the "message" edge to the Message entity by ID if the given value is not nil.
func (*UIDCreate) SetNillableRecent ¶
SetNillableRecent sets the "Recent" field if the given value is not nil.
type UIDCreateBulk ¶
type UIDCreateBulk struct {
// contains filtered or unexported fields
}
UIDCreateBulk is the builder for creating many UID entities in bulk.
func (*UIDCreateBulk) Exec ¶
func (ucb *UIDCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*UIDCreateBulk) ExecX ¶
func (ucb *UIDCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type UIDDelete ¶
type UIDDelete struct {
// contains filtered or unexported fields
}
UIDDelete is the builder for deleting a UID entity.
func (*UIDDelete) Exec ¶
Exec executes the deletion query and returns how many vertices were deleted.
type UIDDeleteOne ¶
type UIDDeleteOne struct {
// contains filtered or unexported fields
}
UIDDeleteOne is the builder for deleting a single UID entity.
func (*UIDDeleteOne) Exec ¶
func (udo *UIDDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*UIDDeleteOne) ExecX ¶
func (udo *UIDDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type UIDEdges ¶
type UIDEdges struct { // Message holds the value of the message edge. Message *Message `json:"message,omitempty"` // Mailbox holds the value of the mailbox edge. Mailbox *Mailbox `json:"mailbox,omitempty"` // contains filtered or unexported fields }
UIDEdges holds the relations/edges for other nodes in the graph.
func (UIDEdges) MailboxOrErr ¶
MailboxOrErr returns the Mailbox value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (UIDEdges) MessageOrErr ¶
MessageOrErr returns the Message value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type UIDGroupBy ¶
type UIDGroupBy struct {
// contains filtered or unexported fields
}
UIDGroupBy is the group-by builder for UID entities.
func (*UIDGroupBy) Aggregate ¶
func (ugb *UIDGroupBy) Aggregate(fns ...AggregateFunc) *UIDGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*UIDGroupBy) Bool ¶
func (ugb *UIDGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) BoolX ¶
func (ugb *UIDGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*UIDGroupBy) Bools ¶
func (ugb *UIDGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) BoolsX ¶
func (ugb *UIDGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*UIDGroupBy) Float64 ¶
func (ugb *UIDGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) Float64X ¶
func (ugb *UIDGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*UIDGroupBy) Float64s ¶
func (ugb *UIDGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) Float64sX ¶
func (ugb *UIDGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*UIDGroupBy) Int ¶
func (ugb *UIDGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) IntX ¶
func (ugb *UIDGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*UIDGroupBy) Ints ¶
func (ugb *UIDGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) IntsX ¶
func (ugb *UIDGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*UIDGroupBy) Scan ¶
func (ugb *UIDGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*UIDGroupBy) ScanX ¶
func (ugb *UIDGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*UIDGroupBy) String ¶
func (ugb *UIDGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UIDGroupBy) StringX ¶
func (ugb *UIDGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type UIDMutation ¶
type UIDMutation struct {
// contains filtered or unexported fields
}
UIDMutation represents an operation that mutates the UID nodes in the graph.
func (*UIDMutation) AddField ¶
func (m *UIDMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UIDMutation) AddedEdges ¶
func (m *UIDMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*UIDMutation) AddedField ¶
func (m *UIDMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UIDMutation) AddedFields ¶
func (m *UIDMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*UIDMutation) AddedIDs ¶
func (m *UIDMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*UIDMutation) AddedUID ¶
func (m *UIDMutation) AddedUID() (r int, exists bool)
AddedUID returns the value that was added to the "UID" field in this mutation.
func (*UIDMutation) ClearEdge ¶
func (m *UIDMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*UIDMutation) ClearField ¶
func (m *UIDMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*UIDMutation) ClearMailbox ¶
func (m *UIDMutation) ClearMailbox()
ClearMailbox clears the "mailbox" edge to the Mailbox entity.
func (*UIDMutation) ClearMessage ¶
func (m *UIDMutation) ClearMessage()
ClearMessage clears the "message" edge to the Message entity.
func (*UIDMutation) ClearedEdges ¶
func (m *UIDMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*UIDMutation) ClearedFields ¶
func (m *UIDMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (UIDMutation) Client ¶
func (m UIDMutation) 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 (*UIDMutation) Deleted ¶
func (m *UIDMutation) Deleted() (r bool, exists bool)
Deleted returns the value of the "Deleted" field in the mutation.
func (*UIDMutation) EdgeCleared ¶
func (m *UIDMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*UIDMutation) Field ¶
func (m *UIDMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UIDMutation) FieldCleared ¶
func (m *UIDMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*UIDMutation) Fields ¶
func (m *UIDMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*UIDMutation) ID ¶
func (m *UIDMutation) ID() (id int, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*UIDMutation) IDs ¶
func (m *UIDMutation) IDs(ctx context.Context) ([]int, error)
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*UIDMutation) InDeletionPool ¶
func (m *UIDMutation) InDeletionPool() (r bool, exists bool)
InDeletionPool returns the value of the "InDeletionPool" field in the mutation.
func (*UIDMutation) MailboxCleared ¶
func (m *UIDMutation) MailboxCleared() bool
MailboxCleared reports if the "mailbox" edge to the Mailbox entity was cleared.
func (*UIDMutation) MailboxID ¶
func (m *UIDMutation) MailboxID() (id int, exists bool)
MailboxID returns the "mailbox" edge ID in the mutation.
func (*UIDMutation) MailboxIDs ¶
func (m *UIDMutation) MailboxIDs() (ids []int)
MailboxIDs returns the "mailbox" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use MailboxID instead. It exists only for internal usage by the builders.
func (*UIDMutation) MessageCleared ¶
func (m *UIDMutation) MessageCleared() bool
MessageCleared reports if the "message" edge to the Message entity was cleared.
func (*UIDMutation) MessageID ¶
func (m *UIDMutation) MessageID() (id int, exists bool)
MessageID returns the "message" edge ID in the mutation.
func (*UIDMutation) MessageIDs ¶
func (m *UIDMutation) MessageIDs() (ids []int)
MessageIDs returns the "message" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use MessageID instead. It exists only for internal usage by the builders.
func (*UIDMutation) OldDeleted ¶
func (m *UIDMutation) OldDeleted(ctx context.Context) (v bool, err error)
OldDeleted returns the old "Deleted" field's value of the UID entity. If the UID object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UIDMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*UIDMutation) OldInDeletionPool ¶
func (m *UIDMutation) OldInDeletionPool(ctx context.Context) (v bool, err error)
OldInDeletionPool returns the old "InDeletionPool" field's value of the UID entity. If the UID object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UIDMutation) OldRecent ¶
func (m *UIDMutation) OldRecent(ctx context.Context) (v bool, err error)
OldRecent returns the old "Recent" field's value of the UID entity. If the UID object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UIDMutation) OldUID ¶
func (m *UIDMutation) OldUID(ctx context.Context) (v int, err error)
OldUID returns the old "UID" field's value of the UID entity. If the UID object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UIDMutation) Recent ¶
func (m *UIDMutation) Recent() (r bool, exists bool)
Recent returns the value of the "Recent" field in the mutation.
func (*UIDMutation) RemovedEdges ¶
func (m *UIDMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*UIDMutation) RemovedIDs ¶
func (m *UIDMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*UIDMutation) ResetDeleted ¶
func (m *UIDMutation) ResetDeleted()
ResetDeleted resets all changes to the "Deleted" field.
func (*UIDMutation) ResetEdge ¶
func (m *UIDMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*UIDMutation) ResetField ¶
func (m *UIDMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*UIDMutation) ResetInDeletionPool ¶
func (m *UIDMutation) ResetInDeletionPool()
ResetInDeletionPool resets all changes to the "InDeletionPool" field.
func (*UIDMutation) ResetMailbox ¶
func (m *UIDMutation) ResetMailbox()
ResetMailbox resets all changes to the "mailbox" edge.
func (*UIDMutation) ResetMessage ¶
func (m *UIDMutation) ResetMessage()
ResetMessage resets all changes to the "message" edge.
func (*UIDMutation) ResetRecent ¶
func (m *UIDMutation) ResetRecent()
ResetRecent resets all changes to the "Recent" field.
func (*UIDMutation) ResetUID ¶
func (m *UIDMutation) ResetUID()
ResetUID resets all changes to the "UID" field.
func (*UIDMutation) SetDeleted ¶
func (m *UIDMutation) SetDeleted(b bool)
SetDeleted sets the "Deleted" field.
func (*UIDMutation) SetField ¶
func (m *UIDMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UIDMutation) SetInDeletionPool ¶
func (m *UIDMutation) SetInDeletionPool(b bool)
SetInDeletionPool sets the "InDeletionPool" field.
func (*UIDMutation) SetMailboxID ¶
func (m *UIDMutation) SetMailboxID(id int)
SetMailboxID sets the "mailbox" edge to the Mailbox entity by id.
func (*UIDMutation) SetMessageID ¶
func (m *UIDMutation) SetMessageID(id int)
SetMessageID sets the "message" edge to the Message entity by id.
func (*UIDMutation) SetRecent ¶
func (m *UIDMutation) SetRecent(b bool)
SetRecent sets the "Recent" field.
func (UIDMutation) Tx ¶
func (m UIDMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*UIDMutation) Type ¶
func (m *UIDMutation) Type() string
Type returns the node type of this mutation (UID).
func (*UIDMutation) UID ¶
func (m *UIDMutation) UID() (r int, exists bool)
UID returns the value of the "UID" field in the mutation.
func (*UIDMutation) Where ¶
func (m *UIDMutation) Where(ps ...predicate.UID)
Where appends a list predicates to the UIDMutation builder.
type UIDQuery ¶
type UIDQuery struct {
// contains filtered or unexported fields
}
UIDQuery is the builder for querying UID entities.
func (*UIDQuery) Clone ¶
Clone returns a duplicate of the UIDQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*UIDQuery) First ¶
First returns the first UID entity from the query. Returns a *NotFoundError when no UID was found.
func (*UIDQuery) FirstID ¶
FirstID returns the first UID ID from the query. Returns a *NotFoundError when no UID ID was found.
func (*UIDQuery) GroupBy ¶
func (uq *UIDQuery) GroupBy(field string, fields ...string) *UIDGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { UID int `json:"UID,omitempty"` Count int `json:"count,omitempty"` } client.UID.Query(). GroupBy(uid.FieldUID). Aggregate(ent.Count()). Scan(ctx, &v)
func (*UIDQuery) Only ¶
Only returns a single UID entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one UID entity is found. Returns a *NotFoundError when no UID entities are found.
func (*UIDQuery) OnlyID ¶
OnlyID is like Only, but returns the only UID ID in the query. Returns a *NotSingularError when more than one UID ID is found. Returns a *NotFoundError when no entities are found.
func (*UIDQuery) QueryMailbox ¶
func (uq *UIDQuery) QueryMailbox() *MailboxQuery
QueryMailbox chains the current query on the "mailbox" edge.
func (*UIDQuery) QueryMessage ¶
func (uq *UIDQuery) QueryMessage() *MessageQuery
QueryMessage chains the current query on the "message" edge.
func (*UIDQuery) Select ¶
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { UID int `json:"UID,omitempty"` } client.UID.Query(). Select(uid.FieldUID). Scan(ctx, &v)
func (*UIDQuery) Unique ¶
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*UIDQuery) WithMailbox ¶
func (uq *UIDQuery) WithMailbox(opts ...func(*MailboxQuery)) *UIDQuery
WithMailbox tells the query-builder to eager-load the nodes that are connected to the "mailbox" edge. The optional arguments are used to configure the query builder of the edge.
func (*UIDQuery) WithMessage ¶
func (uq *UIDQuery) WithMessage(opts ...func(*MessageQuery)) *UIDQuery
WithMessage tells the query-builder to eager-load the nodes that are connected to the "message" edge. The optional arguments are used to configure the query builder of the edge.
type UIDSelect ¶
type UIDSelect struct { *UIDQuery // contains filtered or unexported fields }
UIDSelect is the builder for selecting fields of UID entities.
func (*UIDSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*UIDSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*UIDSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*UIDSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*UIDSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*UIDSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*UIDSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type UIDUpdate ¶
type UIDUpdate struct {
// contains filtered or unexported fields
}
UIDUpdate is the builder for updating UID entities.
func (*UIDUpdate) ClearMailbox ¶
ClearMailbox clears the "mailbox" edge to the Mailbox entity.
func (*UIDUpdate) ClearMessage ¶
ClearMessage clears the "message" edge to the Message entity.
func (*UIDUpdate) Mutation ¶
func (uu *UIDUpdate) Mutation() *UIDMutation
Mutation returns the UIDMutation object of the builder.
func (*UIDUpdate) Save ¶
Save executes the query and returns the number of nodes affected by the update operation.
func (*UIDUpdate) SetDeleted ¶
SetDeleted sets the "Deleted" field.
func (*UIDUpdate) SetInDeletionPool ¶
SetInDeletionPool sets the "InDeletionPool" field.
func (*UIDUpdate) SetMailbox ¶
SetMailbox sets the "mailbox" edge to the Mailbox entity.
func (*UIDUpdate) SetMailboxID ¶
SetMailboxID sets the "mailbox" edge to the Mailbox entity by ID.
func (*UIDUpdate) SetMessage ¶
SetMessage sets the "message" edge to the Message entity.
func (*UIDUpdate) SetMessageID ¶
SetMessageID sets the "message" edge to the Message entity by ID.
func (*UIDUpdate) SetNillableDeleted ¶
SetNillableDeleted sets the "Deleted" field if the given value is not nil.
func (*UIDUpdate) SetNillableInDeletionPool ¶
SetNillableInDeletionPool sets the "InDeletionPool" field if the given value is not nil.
func (*UIDUpdate) SetNillableMailboxID ¶
SetNillableMailboxID sets the "mailbox" edge to the Mailbox entity by ID if the given value is not nil.
func (*UIDUpdate) SetNillableMessageID ¶
SetNillableMessageID sets the "message" edge to the Message entity by ID if the given value is not nil.
func (*UIDUpdate) SetNillableRecent ¶
SetNillableRecent sets the "Recent" field if the given value is not nil.
type UIDUpdateOne ¶
type UIDUpdateOne struct {
// contains filtered or unexported fields
}
UIDUpdateOne is the builder for updating a single UID entity.
func (*UIDUpdateOne) AddUID ¶
func (uuo *UIDUpdateOne) AddUID(i int) *UIDUpdateOne
AddUID adds i to the "UID" field.
func (*UIDUpdateOne) ClearMailbox ¶
func (uuo *UIDUpdateOne) ClearMailbox() *UIDUpdateOne
ClearMailbox clears the "mailbox" edge to the Mailbox entity.
func (*UIDUpdateOne) ClearMessage ¶
func (uuo *UIDUpdateOne) ClearMessage() *UIDUpdateOne
ClearMessage clears the "message" edge to the Message entity.
func (*UIDUpdateOne) Exec ¶
func (uuo *UIDUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*UIDUpdateOne) ExecX ¶
func (uuo *UIDUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UIDUpdateOne) Mutation ¶
func (uuo *UIDUpdateOne) Mutation() *UIDMutation
Mutation returns the UIDMutation object of the builder.
func (*UIDUpdateOne) Save ¶
func (uuo *UIDUpdateOne) Save(ctx context.Context) (*UID, error)
Save executes the query and returns the updated UID entity.
func (*UIDUpdateOne) SaveX ¶
func (uuo *UIDUpdateOne) SaveX(ctx context.Context) *UID
SaveX is like Save, but panics if an error occurs.
func (*UIDUpdateOne) Select ¶
func (uuo *UIDUpdateOne) Select(field string, fields ...string) *UIDUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*UIDUpdateOne) SetDeleted ¶
func (uuo *UIDUpdateOne) SetDeleted(b bool) *UIDUpdateOne
SetDeleted sets the "Deleted" field.
func (*UIDUpdateOne) SetInDeletionPool ¶
func (uuo *UIDUpdateOne) SetInDeletionPool(b bool) *UIDUpdateOne
SetInDeletionPool sets the "InDeletionPool" field.
func (*UIDUpdateOne) SetMailbox ¶
func (uuo *UIDUpdateOne) SetMailbox(m *Mailbox) *UIDUpdateOne
SetMailbox sets the "mailbox" edge to the Mailbox entity.
func (*UIDUpdateOne) SetMailboxID ¶
func (uuo *UIDUpdateOne) SetMailboxID(id int) *UIDUpdateOne
SetMailboxID sets the "mailbox" edge to the Mailbox entity by ID.
func (*UIDUpdateOne) SetMessage ¶
func (uuo *UIDUpdateOne) SetMessage(m *Message) *UIDUpdateOne
SetMessage sets the "message" edge to the Message entity.
func (*UIDUpdateOne) SetMessageID ¶
func (uuo *UIDUpdateOne) SetMessageID(id int) *UIDUpdateOne
SetMessageID sets the "message" edge to the Message entity by ID.
func (*UIDUpdateOne) SetNillableDeleted ¶
func (uuo *UIDUpdateOne) SetNillableDeleted(b *bool) *UIDUpdateOne
SetNillableDeleted sets the "Deleted" field if the given value is not nil.
func (*UIDUpdateOne) SetNillableInDeletionPool ¶
func (uuo *UIDUpdateOne) SetNillableInDeletionPool(b *bool) *UIDUpdateOne
SetNillableInDeletionPool sets the "InDeletionPool" field if the given value is not nil.
func (*UIDUpdateOne) SetNillableMailboxID ¶
func (uuo *UIDUpdateOne) SetNillableMailboxID(id *int) *UIDUpdateOne
SetNillableMailboxID sets the "mailbox" edge to the Mailbox entity by ID if the given value is not nil.
func (*UIDUpdateOne) SetNillableMessageID ¶
func (uuo *UIDUpdateOne) SetNillableMessageID(id *int) *UIDUpdateOne
SetNillableMessageID sets the "message" edge to the Message entity by ID if the given value is not nil.
func (*UIDUpdateOne) SetNillableRecent ¶
func (uuo *UIDUpdateOne) SetNillableRecent(b *bool) *UIDUpdateOne
SetNillableRecent sets the "Recent" field if the given value is not nil.
func (*UIDUpdateOne) SetRecent ¶
func (uuo *UIDUpdateOne) SetRecent(b bool) *UIDUpdateOne
SetRecent sets the "Recent" field.
func (*UIDUpdateOne) SetUID ¶
func (uuo *UIDUpdateOne) SetUID(i int) *UIDUpdateOne
SetUID sets the "UID" field.
type ValidationError ¶
type ValidationError struct { Name string // Field or edge name. // contains filtered or unexported fields }
ValidationError returns when validating a field or edge fails.
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
Error implements the error interface.
func (*ValidationError) Unwrap ¶
func (e *ValidationError) Unwrap() error
Unwrap implements the errors.Wrapper interface.
Source Files ¶
- client.go
- config.go
- context.go
- ent.go
- generate.go
- mailbox.go
- mailbox_create.go
- mailbox_delete.go
- mailbox_query.go
- mailbox_update.go
- mailboxattr.go
- mailboxattr_create.go
- mailboxattr_delete.go
- mailboxattr_query.go
- mailboxattr_update.go
- mailboxflag.go
- mailboxflag_create.go
- mailboxflag_delete.go
- mailboxflag_query.go
- mailboxflag_update.go
- mailboxpermflag.go
- mailboxpermflag_create.go
- mailboxpermflag_delete.go
- mailboxpermflag_query.go
- mailboxpermflag_update.go
- message.go
- message_create.go
- message_delete.go
- message_query.go
- message_update.go
- messageflag.go
- messageflag_create.go
- messageflag_delete.go
- messageflag_query.go
- messageflag_update.go
- mutation.go
- runtime.go
- tx.go
- uid.go
- uid_create.go
- uid_delete.go
- uid_query.go
- uid_update.go