Documentation
¶
Index ¶
- Constants
- Variables
- func Asc(fields ...string) func(*sql.Selector)
- func Desc(fields ...string) func(*sql.Selector)
- 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 Attachment
- type AttachmentClient
- func (c *AttachmentClient) Create() *AttachmentCreate
- func (c *AttachmentClient) CreateBulk(builders ...*AttachmentCreate) *AttachmentCreateBulk
- func (c *AttachmentClient) Delete() *AttachmentDelete
- func (c *AttachmentClient) DeleteOne(a *Attachment) *AttachmentDeleteOne
- func (c *AttachmentClient) DeleteOneID(id uuid.UUID) *AttachmentDeleteOne
- func (c *AttachmentClient) Get(ctx context.Context, id uuid.UUID) (*Attachment, error)
- func (c *AttachmentClient) GetX(ctx context.Context, id uuid.UUID) *Attachment
- func (c *AttachmentClient) Hooks() []Hook
- func (c *AttachmentClient) Intercept(interceptors ...Interceptor)
- func (c *AttachmentClient) Interceptors() []Interceptor
- func (c *AttachmentClient) MapCreateBulk(slice any, setFunc func(*AttachmentCreate, int)) *AttachmentCreateBulk
- func (c *AttachmentClient) Query() *AttachmentQuery
- func (c *AttachmentClient) QueryAuthor(a *Attachment) *UserQuery
- func (c *AttachmentClient) Update() *AttachmentUpdate
- func (c *AttachmentClient) UpdateOne(a *Attachment) *AttachmentUpdateOne
- func (c *AttachmentClient) UpdateOneID(id uuid.UUID) *AttachmentUpdateOne
- func (c *AttachmentClient) Use(hooks ...Hook)
- type AttachmentCreate
- func (ac *AttachmentCreate) Exec(ctx context.Context) error
- func (ac *AttachmentCreate) ExecX(ctx context.Context)
- func (ac *AttachmentCreate) Mutation() *AttachmentMutation
- func (ac *AttachmentCreate) OnConflict(opts ...sql.ConflictOption) *AttachmentUpsertOne
- func (ac *AttachmentCreate) OnConflictColumns(columns ...string) *AttachmentUpsertOne
- func (ac *AttachmentCreate) Save(ctx context.Context) (*Attachment, error)
- func (ac *AttachmentCreate) SaveX(ctx context.Context) *Attachment
- func (ac *AttachmentCreate) SetAuthor(u *User) *AttachmentCreate
- func (ac *AttachmentCreate) SetAuthorID(id uuid.UUID) *AttachmentCreate
- func (ac *AttachmentCreate) SetBlurhash(s string) *AttachmentCreate
- func (ac *AttachmentCreate) SetCreatedAt(t time.Time) *AttachmentCreate
- func (ac *AttachmentCreate) SetDescription(s string) *AttachmentCreate
- func (ac *AttachmentCreate) SetExtensions(v versia.Extensions) *AttachmentCreate
- func (ac *AttachmentCreate) SetFps(i int) *AttachmentCreate
- func (ac *AttachmentCreate) SetHeight(i int) *AttachmentCreate
- func (ac *AttachmentCreate) SetID(u uuid.UUID) *AttachmentCreate
- func (ac *AttachmentCreate) SetIsRemote(b bool) *AttachmentCreate
- func (ac *AttachmentCreate) SetMimeType(s string) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableBlurhash(s *string) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableCreatedAt(t *time.Time) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableFps(i *int) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableHeight(i *int) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableID(u *uuid.UUID) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableUpdatedAt(t *time.Time) *AttachmentCreate
- func (ac *AttachmentCreate) SetNillableWidth(i *int) *AttachmentCreate
- func (ac *AttachmentCreate) SetSha256(b []byte) *AttachmentCreate
- func (ac *AttachmentCreate) SetSize(i int) *AttachmentCreate
- func (ac *AttachmentCreate) SetURI(s string) *AttachmentCreate
- func (ac *AttachmentCreate) SetUpdatedAt(t time.Time) *AttachmentCreate
- func (ac *AttachmentCreate) SetWidth(i int) *AttachmentCreate
- type AttachmentCreateBulk
- func (acb *AttachmentCreateBulk) Exec(ctx context.Context) error
- func (acb *AttachmentCreateBulk) ExecX(ctx context.Context)
- func (acb *AttachmentCreateBulk) OnConflict(opts ...sql.ConflictOption) *AttachmentUpsertBulk
- func (acb *AttachmentCreateBulk) OnConflictColumns(columns ...string) *AttachmentUpsertBulk
- func (acb *AttachmentCreateBulk) Save(ctx context.Context) ([]*Attachment, error)
- func (acb *AttachmentCreateBulk) SaveX(ctx context.Context) []*Attachment
- type AttachmentDelete
- type AttachmentDeleteOne
- type AttachmentEdges
- type AttachmentGroupBy
- func (agb *AttachmentGroupBy) Aggregate(fns ...AggregateFunc) *AttachmentGroupBy
- func (s *AttachmentGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *AttachmentGroupBy) BoolX(ctx context.Context) bool
- func (s *AttachmentGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *AttachmentGroupBy) BoolsX(ctx context.Context) []bool
- func (s *AttachmentGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *AttachmentGroupBy) Float64X(ctx context.Context) float64
- func (s *AttachmentGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *AttachmentGroupBy) Float64sX(ctx context.Context) []float64
- func (s *AttachmentGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *AttachmentGroupBy) IntX(ctx context.Context) int
- func (s *AttachmentGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *AttachmentGroupBy) IntsX(ctx context.Context) []int
- func (agb *AttachmentGroupBy) Scan(ctx context.Context, v any) error
- func (s *AttachmentGroupBy) ScanX(ctx context.Context, v any)
- func (s *AttachmentGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *AttachmentGroupBy) StringX(ctx context.Context) string
- func (s *AttachmentGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *AttachmentGroupBy) StringsX(ctx context.Context) []string
- type AttachmentMutation
- func (m *AttachmentMutation) AddField(name string, value ent.Value) error
- func (m *AttachmentMutation) AddFps(i int)
- func (m *AttachmentMutation) AddHeight(i int)
- func (m *AttachmentMutation) AddSize(i int)
- func (m *AttachmentMutation) AddWidth(i int)
- func (m *AttachmentMutation) AddedEdges() []string
- func (m *AttachmentMutation) AddedField(name string) (ent.Value, bool)
- func (m *AttachmentMutation) AddedFields() []string
- func (m *AttachmentMutation) AddedFps() (r int, exists bool)
- func (m *AttachmentMutation) AddedHeight() (r int, exists bool)
- func (m *AttachmentMutation) AddedIDs(name string) []ent.Value
- func (m *AttachmentMutation) AddedSize() (r int, exists bool)
- func (m *AttachmentMutation) AddedWidth() (r int, exists bool)
- func (m *AttachmentMutation) AuthorCleared() bool
- func (m *AttachmentMutation) AuthorID() (id uuid.UUID, exists bool)
- func (m *AttachmentMutation) AuthorIDs() (ids []uuid.UUID)
- func (m *AttachmentMutation) Blurhash() (r string, exists bool)
- func (m *AttachmentMutation) BlurhashCleared() bool
- func (m *AttachmentMutation) ClearAuthor()
- func (m *AttachmentMutation) ClearBlurhash()
- func (m *AttachmentMutation) ClearEdge(name string) error
- func (m *AttachmentMutation) ClearField(name string) error
- func (m *AttachmentMutation) ClearFps()
- func (m *AttachmentMutation) ClearHeight()
- func (m *AttachmentMutation) ClearWidth()
- func (m *AttachmentMutation) ClearedEdges() []string
- func (m *AttachmentMutation) ClearedFields() []string
- func (m AttachmentMutation) Client() *Client
- func (m *AttachmentMutation) CreatedAt() (r time.Time, exists bool)
- func (m *AttachmentMutation) Description() (r string, exists bool)
- func (m *AttachmentMutation) EdgeCleared(name string) bool
- func (m *AttachmentMutation) Extensions() (r versia.Extensions, exists bool)
- func (m *AttachmentMutation) Field(name string) (ent.Value, bool)
- func (m *AttachmentMutation) FieldCleared(name string) bool
- func (m *AttachmentMutation) Fields() []string
- func (m *AttachmentMutation) Fps() (r int, exists bool)
- func (m *AttachmentMutation) FpsCleared() bool
- func (m *AttachmentMutation) Height() (r int, exists bool)
- func (m *AttachmentMutation) HeightCleared() bool
- func (m *AttachmentMutation) ID() (id uuid.UUID, exists bool)
- func (m *AttachmentMutation) IDs(ctx context.Context) ([]uuid.UUID, error)
- func (m *AttachmentMutation) IsRemote() (r bool, exists bool)
- func (m *AttachmentMutation) MimeType() (r string, exists bool)
- func (m *AttachmentMutation) OldBlurhash(ctx context.Context) (v *string, err error)
- func (m *AttachmentMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)
- func (m *AttachmentMutation) OldDescription(ctx context.Context) (v string, err error)
- func (m *AttachmentMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
- func (m *AttachmentMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *AttachmentMutation) OldFps(ctx context.Context) (v *int, err error)
- func (m *AttachmentMutation) OldHeight(ctx context.Context) (v *int, err error)
- func (m *AttachmentMutation) OldIsRemote(ctx context.Context) (v bool, err error)
- func (m *AttachmentMutation) OldMimeType(ctx context.Context) (v string, err error)
- func (m *AttachmentMutation) OldSha256(ctx context.Context) (v []byte, err error)
- func (m *AttachmentMutation) OldSize(ctx context.Context) (v int, err error)
- func (m *AttachmentMutation) OldURI(ctx context.Context) (v string, err error)
- func (m *AttachmentMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)
- func (m *AttachmentMutation) OldWidth(ctx context.Context) (v *int, err error)
- func (m *AttachmentMutation) Op() Op
- func (m *AttachmentMutation) RemovedEdges() []string
- func (m *AttachmentMutation) RemovedIDs(name string) []ent.Value
- func (m *AttachmentMutation) ResetAuthor()
- func (m *AttachmentMutation) ResetBlurhash()
- func (m *AttachmentMutation) ResetCreatedAt()
- func (m *AttachmentMutation) ResetDescription()
- func (m *AttachmentMutation) ResetEdge(name string) error
- func (m *AttachmentMutation) ResetExtensions()
- func (m *AttachmentMutation) ResetField(name string) error
- func (m *AttachmentMutation) ResetFps()
- func (m *AttachmentMutation) ResetHeight()
- func (m *AttachmentMutation) ResetIsRemote()
- func (m *AttachmentMutation) ResetMimeType()
- func (m *AttachmentMutation) ResetSha256()
- func (m *AttachmentMutation) ResetSize()
- func (m *AttachmentMutation) ResetURI()
- func (m *AttachmentMutation) ResetUpdatedAt()
- func (m *AttachmentMutation) ResetWidth()
- func (m *AttachmentMutation) SetAuthorID(id uuid.UUID)
- func (m *AttachmentMutation) SetBlurhash(s string)
- func (m *AttachmentMutation) SetCreatedAt(t time.Time)
- func (m *AttachmentMutation) SetDescription(s string)
- func (m *AttachmentMutation) SetExtensions(v versia.Extensions)
- func (m *AttachmentMutation) SetField(name string, value ent.Value) error
- func (m *AttachmentMutation) SetFps(i int)
- func (m *AttachmentMutation) SetHeight(i int)
- func (m *AttachmentMutation) SetID(id uuid.UUID)
- func (m *AttachmentMutation) SetIsRemote(b bool)
- func (m *AttachmentMutation) SetMimeType(s string)
- func (m *AttachmentMutation) SetOp(op Op)
- func (m *AttachmentMutation) SetSha256(b []byte)
- func (m *AttachmentMutation) SetSize(i int)
- func (m *AttachmentMutation) SetURI(s string)
- func (m *AttachmentMutation) SetUpdatedAt(t time.Time)
- func (m *AttachmentMutation) SetWidth(i int)
- func (m *AttachmentMutation) Sha256() (r []byte, exists bool)
- func (m *AttachmentMutation) Size() (r int, exists bool)
- func (m AttachmentMutation) Tx() (*Tx, error)
- func (m *AttachmentMutation) Type() string
- func (m *AttachmentMutation) URI() (r string, exists bool)
- func (m *AttachmentMutation) UpdatedAt() (r time.Time, exists bool)
- func (m *AttachmentMutation) Where(ps ...predicate.Attachment)
- func (m *AttachmentMutation) WhereP(ps ...func(*sql.Selector))
- func (m *AttachmentMutation) Width() (r int, exists bool)
- func (m *AttachmentMutation) WidthCleared() bool
- type AttachmentQuery
- func (aq *AttachmentQuery) Aggregate(fns ...AggregateFunc) *AttachmentSelect
- func (aq *AttachmentQuery) All(ctx context.Context) ([]*Attachment, error)
- func (aq *AttachmentQuery) AllX(ctx context.Context) []*Attachment
- func (aq *AttachmentQuery) Clone() *AttachmentQuery
- func (aq *AttachmentQuery) Count(ctx context.Context) (int, error)
- func (aq *AttachmentQuery) CountX(ctx context.Context) int
- func (aq *AttachmentQuery) Exist(ctx context.Context) (bool, error)
- func (aq *AttachmentQuery) ExistX(ctx context.Context) bool
- func (aq *AttachmentQuery) First(ctx context.Context) (*Attachment, error)
- func (aq *AttachmentQuery) FirstID(ctx context.Context) (id uuid.UUID, err error)
- func (aq *AttachmentQuery) FirstIDX(ctx context.Context) uuid.UUID
- func (aq *AttachmentQuery) FirstX(ctx context.Context) *Attachment
- func (aq *AttachmentQuery) GroupBy(field string, fields ...string) *AttachmentGroupBy
- func (aq *AttachmentQuery) IDs(ctx context.Context) (ids []uuid.UUID, err error)
- func (aq *AttachmentQuery) IDsX(ctx context.Context) []uuid.UUID
- func (aq *AttachmentQuery) Limit(limit int) *AttachmentQuery
- func (aq *AttachmentQuery) Offset(offset int) *AttachmentQuery
- func (aq *AttachmentQuery) Only(ctx context.Context) (*Attachment, error)
- func (aq *AttachmentQuery) OnlyID(ctx context.Context) (id uuid.UUID, err error)
- func (aq *AttachmentQuery) OnlyIDX(ctx context.Context) uuid.UUID
- func (aq *AttachmentQuery) OnlyX(ctx context.Context) *Attachment
- func (aq *AttachmentQuery) Order(o ...attachment.OrderOption) *AttachmentQuery
- func (aq *AttachmentQuery) QueryAuthor() *UserQuery
- func (aq *AttachmentQuery) Select(fields ...string) *AttachmentSelect
- func (aq *AttachmentQuery) Unique(unique bool) *AttachmentQuery
- func (aq *AttachmentQuery) Where(ps ...predicate.Attachment) *AttachmentQuery
- func (aq *AttachmentQuery) WithAuthor(opts ...func(*UserQuery)) *AttachmentQuery
- type AttachmentSelect
- func (as *AttachmentSelect) Aggregate(fns ...AggregateFunc) *AttachmentSelect
- func (s *AttachmentSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *AttachmentSelect) BoolX(ctx context.Context) bool
- func (s *AttachmentSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *AttachmentSelect) BoolsX(ctx context.Context) []bool
- func (s *AttachmentSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *AttachmentSelect) Float64X(ctx context.Context) float64
- func (s *AttachmentSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *AttachmentSelect) Float64sX(ctx context.Context) []float64
- func (s *AttachmentSelect) Int(ctx context.Context) (_ int, err error)
- func (s *AttachmentSelect) IntX(ctx context.Context) int
- func (s *AttachmentSelect) Ints(ctx context.Context) ([]int, error)
- func (s *AttachmentSelect) IntsX(ctx context.Context) []int
- func (as *AttachmentSelect) Scan(ctx context.Context, v any) error
- func (s *AttachmentSelect) ScanX(ctx context.Context, v any)
- func (s *AttachmentSelect) String(ctx context.Context) (_ string, err error)
- func (s *AttachmentSelect) StringX(ctx context.Context) string
- func (s *AttachmentSelect) Strings(ctx context.Context) ([]string, error)
- func (s *AttachmentSelect) StringsX(ctx context.Context) []string
- type AttachmentUpdate
- func (au *AttachmentUpdate) AddFps(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) AddHeight(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) AddSize(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) AddWidth(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) ClearAuthor() *AttachmentUpdate
- func (au *AttachmentUpdate) ClearBlurhash() *AttachmentUpdate
- func (au *AttachmentUpdate) ClearFps() *AttachmentUpdate
- func (au *AttachmentUpdate) ClearHeight() *AttachmentUpdate
- func (au *AttachmentUpdate) ClearWidth() *AttachmentUpdate
- func (au *AttachmentUpdate) Exec(ctx context.Context) error
- func (au *AttachmentUpdate) ExecX(ctx context.Context)
- func (au *AttachmentUpdate) Mutation() *AttachmentMutation
- func (au *AttachmentUpdate) Save(ctx context.Context) (int, error)
- func (au *AttachmentUpdate) SaveX(ctx context.Context) int
- func (au *AttachmentUpdate) SetAuthor(u *User) *AttachmentUpdate
- func (au *AttachmentUpdate) SetAuthorID(id uuid.UUID) *AttachmentUpdate
- func (au *AttachmentUpdate) SetBlurhash(s string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetDescription(s string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetExtensions(v versia.Extensions) *AttachmentUpdate
- func (au *AttachmentUpdate) SetFps(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetHeight(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetIsRemote(b bool) *AttachmentUpdate
- func (au *AttachmentUpdate) SetMimeType(s string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableBlurhash(s *string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableDescription(s *string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableFps(i *int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableHeight(i *int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableIsRemote(b *bool) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableMimeType(s *string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableSize(i *int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableURI(s *string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetNillableWidth(i *int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetSha256(b []byte) *AttachmentUpdate
- func (au *AttachmentUpdate) SetSize(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) SetURI(s string) *AttachmentUpdate
- func (au *AttachmentUpdate) SetUpdatedAt(t time.Time) *AttachmentUpdate
- func (au *AttachmentUpdate) SetWidth(i int) *AttachmentUpdate
- func (au *AttachmentUpdate) Where(ps ...predicate.Attachment) *AttachmentUpdate
- type AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) AddFps(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) AddHeight(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) AddSize(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) AddWidth(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) ClearAuthor() *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) ClearBlurhash() *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) ClearFps() *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) ClearHeight() *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) ClearWidth() *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) Exec(ctx context.Context) error
- func (auo *AttachmentUpdateOne) ExecX(ctx context.Context)
- func (auo *AttachmentUpdateOne) Mutation() *AttachmentMutation
- func (auo *AttachmentUpdateOne) Save(ctx context.Context) (*Attachment, error)
- func (auo *AttachmentUpdateOne) SaveX(ctx context.Context) *Attachment
- func (auo *AttachmentUpdateOne) Select(field string, fields ...string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetAuthor(u *User) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetAuthorID(id uuid.UUID) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetBlurhash(s string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetDescription(s string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetExtensions(v versia.Extensions) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetFps(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetHeight(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetIsRemote(b bool) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetMimeType(s string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableBlurhash(s *string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableDescription(s *string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableFps(i *int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableHeight(i *int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableIsRemote(b *bool) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableMimeType(s *string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableSize(i *int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableURI(s *string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetNillableWidth(i *int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetSha256(b []byte) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetSize(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetURI(s string) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetUpdatedAt(t time.Time) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) SetWidth(i int) *AttachmentUpdateOne
- func (auo *AttachmentUpdateOne) Where(ps ...predicate.Attachment) *AttachmentUpdateOne
- type AttachmentUpsert
- func (u *AttachmentUpsert) AddFps(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) AddHeight(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) AddSize(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) AddWidth(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) ClearBlurhash() *AttachmentUpsert
- func (u *AttachmentUpsert) ClearFps() *AttachmentUpsert
- func (u *AttachmentUpsert) ClearHeight() *AttachmentUpsert
- func (u *AttachmentUpsert) ClearWidth() *AttachmentUpsert
- func (u *AttachmentUpsert) SetBlurhash(v string) *AttachmentUpsert
- func (u *AttachmentUpsert) SetDescription(v string) *AttachmentUpsert
- func (u *AttachmentUpsert) SetExtensions(v versia.Extensions) *AttachmentUpsert
- func (u *AttachmentUpsert) SetFps(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) SetHeight(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) SetIsRemote(v bool) *AttachmentUpsert
- func (u *AttachmentUpsert) SetMimeType(v string) *AttachmentUpsert
- func (u *AttachmentUpsert) SetSha256(v []byte) *AttachmentUpsert
- func (u *AttachmentUpsert) SetSize(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) SetURI(v string) *AttachmentUpsert
- func (u *AttachmentUpsert) SetUpdatedAt(v time.Time) *AttachmentUpsert
- func (u *AttachmentUpsert) SetWidth(v int) *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateBlurhash() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateDescription() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateExtensions() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateFps() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateHeight() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateIsRemote() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateMimeType() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateSha256() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateSize() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateURI() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateUpdatedAt() *AttachmentUpsert
- func (u *AttachmentUpsert) UpdateWidth() *AttachmentUpsert
- type AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) AddFps(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) AddHeight(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) AddSize(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) AddWidth(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) ClearBlurhash() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) ClearFps() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) ClearHeight() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) ClearWidth() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) DoNothing() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) Exec(ctx context.Context) error
- func (u *AttachmentUpsertBulk) ExecX(ctx context.Context)
- func (u *AttachmentUpsertBulk) Ignore() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetBlurhash(v string) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetDescription(v string) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetExtensions(v versia.Extensions) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetFps(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetHeight(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetIsRemote(v bool) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetMimeType(v string) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetSha256(v []byte) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetSize(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetURI(v string) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetUpdatedAt(v time.Time) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) SetWidth(v int) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) Update(set func(*AttachmentUpsert)) *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateBlurhash() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateDescription() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateExtensions() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateFps() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateHeight() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateIsRemote() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateMimeType() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateNewValues() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateSha256() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateSize() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateURI() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateUpdatedAt() *AttachmentUpsertBulk
- func (u *AttachmentUpsertBulk) UpdateWidth() *AttachmentUpsertBulk
- type AttachmentUpsertOne
- func (u *AttachmentUpsertOne) AddFps(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) AddHeight(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) AddSize(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) AddWidth(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) ClearBlurhash() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) ClearFps() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) ClearHeight() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) ClearWidth() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) DoNothing() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) Exec(ctx context.Context) error
- func (u *AttachmentUpsertOne) ExecX(ctx context.Context)
- func (u *AttachmentUpsertOne) ID(ctx context.Context) (id uuid.UUID, err error)
- func (u *AttachmentUpsertOne) IDX(ctx context.Context) uuid.UUID
- func (u *AttachmentUpsertOne) Ignore() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetBlurhash(v string) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetDescription(v string) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetExtensions(v versia.Extensions) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetFps(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetHeight(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetIsRemote(v bool) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetMimeType(v string) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetSha256(v []byte) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetSize(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetURI(v string) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetUpdatedAt(v time.Time) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) SetWidth(v int) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) Update(set func(*AttachmentUpsert)) *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateBlurhash() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateDescription() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateExtensions() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateFps() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateHeight() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateIsRemote() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateMimeType() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateNewValues() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateSha256() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateSize() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateURI() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateUpdatedAt() *AttachmentUpsertOne
- func (u *AttachmentUpsertOne) UpdateWidth() *AttachmentUpsertOne
- type Attachments
- type Client
- func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)
- func (c *Client) Close() error
- func (c *Client) Debug() *Client
- func (c *Client) GetClient() *sql.Driver
- func (c *Client) Intercept(interceptors ...Interceptor)
- func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)
- func (c *Client) Ping() error
- func (c *Client) Tx(ctx context.Context) (*Tx, error)
- func (c *Client) Use(hooks ...Hook)
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type Follow
- type FollowClient
- func (c *FollowClient) Create() *FollowCreate
- func (c *FollowClient) CreateBulk(builders ...*FollowCreate) *FollowCreateBulk
- func (c *FollowClient) Delete() *FollowDelete
- func (c *FollowClient) DeleteOne(f *Follow) *FollowDeleteOne
- func (c *FollowClient) DeleteOneID(id uuid.UUID) *FollowDeleteOne
- func (c *FollowClient) Get(ctx context.Context, id uuid.UUID) (*Follow, error)
- func (c *FollowClient) GetX(ctx context.Context, id uuid.UUID) *Follow
- func (c *FollowClient) Hooks() []Hook
- func (c *FollowClient) Intercept(interceptors ...Interceptor)
- func (c *FollowClient) Interceptors() []Interceptor
- func (c *FollowClient) MapCreateBulk(slice any, setFunc func(*FollowCreate, int)) *FollowCreateBulk
- func (c *FollowClient) Query() *FollowQuery
- func (c *FollowClient) QueryFollowee(f *Follow) *UserQuery
- func (c *FollowClient) QueryFollower(f *Follow) *UserQuery
- func (c *FollowClient) Update() *FollowUpdate
- func (c *FollowClient) UpdateOne(f *Follow) *FollowUpdateOne
- func (c *FollowClient) UpdateOneID(id uuid.UUID) *FollowUpdateOne
- func (c *FollowClient) Use(hooks ...Hook)
- type FollowCreate
- func (fc *FollowCreate) Exec(ctx context.Context) error
- func (fc *FollowCreate) ExecX(ctx context.Context)
- func (fc *FollowCreate) Mutation() *FollowMutation
- func (fc *FollowCreate) OnConflict(opts ...sql.ConflictOption) *FollowUpsertOne
- func (fc *FollowCreate) OnConflictColumns(columns ...string) *FollowUpsertOne
- func (fc *FollowCreate) Save(ctx context.Context) (*Follow, error)
- func (fc *FollowCreate) SaveX(ctx context.Context) *Follow
- func (fc *FollowCreate) SetCreatedAt(t time.Time) *FollowCreate
- func (fc *FollowCreate) SetExtensions(v versia.Extensions) *FollowCreate
- func (fc *FollowCreate) SetFollowee(u *User) *FollowCreate
- func (fc *FollowCreate) SetFolloweeID(id uuid.UUID) *FollowCreate
- func (fc *FollowCreate) SetFollower(u *User) *FollowCreate
- func (fc *FollowCreate) SetFollowerID(id uuid.UUID) *FollowCreate
- func (fc *FollowCreate) SetID(u uuid.UUID) *FollowCreate
- func (fc *FollowCreate) SetIsRemote(b bool) *FollowCreate
- func (fc *FollowCreate) SetNillableCreatedAt(t *time.Time) *FollowCreate
- func (fc *FollowCreate) SetNillableID(u *uuid.UUID) *FollowCreate
- func (fc *FollowCreate) SetNillableStatus(f *follow.Status) *FollowCreate
- func (fc *FollowCreate) SetNillableUpdatedAt(t *time.Time) *FollowCreate
- func (fc *FollowCreate) SetStatus(f follow.Status) *FollowCreate
- func (fc *FollowCreate) SetURI(s string) *FollowCreate
- func (fc *FollowCreate) SetUpdatedAt(t time.Time) *FollowCreate
- type FollowCreateBulk
- func (fcb *FollowCreateBulk) Exec(ctx context.Context) error
- func (fcb *FollowCreateBulk) ExecX(ctx context.Context)
- func (fcb *FollowCreateBulk) OnConflict(opts ...sql.ConflictOption) *FollowUpsertBulk
- func (fcb *FollowCreateBulk) OnConflictColumns(columns ...string) *FollowUpsertBulk
- func (fcb *FollowCreateBulk) Save(ctx context.Context) ([]*Follow, error)
- func (fcb *FollowCreateBulk) SaveX(ctx context.Context) []*Follow
- type FollowDelete
- type FollowDeleteOne
- type FollowEdges
- type FollowGroupBy
- func (fgb *FollowGroupBy) Aggregate(fns ...AggregateFunc) *FollowGroupBy
- func (s *FollowGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *FollowGroupBy) BoolX(ctx context.Context) bool
- func (s *FollowGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *FollowGroupBy) BoolsX(ctx context.Context) []bool
- func (s *FollowGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *FollowGroupBy) Float64X(ctx context.Context) float64
- func (s *FollowGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *FollowGroupBy) Float64sX(ctx context.Context) []float64
- func (s *FollowGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *FollowGroupBy) IntX(ctx context.Context) int
- func (s *FollowGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *FollowGroupBy) IntsX(ctx context.Context) []int
- func (fgb *FollowGroupBy) Scan(ctx context.Context, v any) error
- func (s *FollowGroupBy) ScanX(ctx context.Context, v any)
- func (s *FollowGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *FollowGroupBy) StringX(ctx context.Context) string
- func (s *FollowGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *FollowGroupBy) StringsX(ctx context.Context) []string
- type FollowMutation
- func (m *FollowMutation) AddField(name string, value ent.Value) error
- func (m *FollowMutation) AddedEdges() []string
- func (m *FollowMutation) AddedField(name string) (ent.Value, bool)
- func (m *FollowMutation) AddedFields() []string
- func (m *FollowMutation) AddedIDs(name string) []ent.Value
- func (m *FollowMutation) ClearEdge(name string) error
- func (m *FollowMutation) ClearField(name string) error
- func (m *FollowMutation) ClearFollowee()
- func (m *FollowMutation) ClearFollower()
- func (m *FollowMutation) ClearedEdges() []string
- func (m *FollowMutation) ClearedFields() []string
- func (m FollowMutation) Client() *Client
- func (m *FollowMutation) CreatedAt() (r time.Time, exists bool)
- func (m *FollowMutation) EdgeCleared(name string) bool
- func (m *FollowMutation) Extensions() (r versia.Extensions, exists bool)
- func (m *FollowMutation) Field(name string) (ent.Value, bool)
- func (m *FollowMutation) FieldCleared(name string) bool
- func (m *FollowMutation) Fields() []string
- func (m *FollowMutation) FolloweeCleared() bool
- func (m *FollowMutation) FolloweeID() (id uuid.UUID, exists bool)
- func (m *FollowMutation) FolloweeIDs() (ids []uuid.UUID)
- func (m *FollowMutation) FollowerCleared() bool
- func (m *FollowMutation) FollowerID() (id uuid.UUID, exists bool)
- func (m *FollowMutation) FollowerIDs() (ids []uuid.UUID)
- func (m *FollowMutation) ID() (id uuid.UUID, exists bool)
- func (m *FollowMutation) IDs(ctx context.Context) ([]uuid.UUID, error)
- func (m *FollowMutation) IsRemote() (r bool, exists bool)
- func (m *FollowMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)
- func (m *FollowMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
- func (m *FollowMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *FollowMutation) OldIsRemote(ctx context.Context) (v bool, err error)
- func (m *FollowMutation) OldStatus(ctx context.Context) (v follow.Status, err error)
- func (m *FollowMutation) OldURI(ctx context.Context) (v string, err error)
- func (m *FollowMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)
- func (m *FollowMutation) Op() Op
- func (m *FollowMutation) RemovedEdges() []string
- func (m *FollowMutation) RemovedIDs(name string) []ent.Value
- func (m *FollowMutation) ResetCreatedAt()
- func (m *FollowMutation) ResetEdge(name string) error
- func (m *FollowMutation) ResetExtensions()
- func (m *FollowMutation) ResetField(name string) error
- func (m *FollowMutation) ResetFollowee()
- func (m *FollowMutation) ResetFollower()
- func (m *FollowMutation) ResetIsRemote()
- func (m *FollowMutation) ResetStatus()
- func (m *FollowMutation) ResetURI()
- func (m *FollowMutation) ResetUpdatedAt()
- func (m *FollowMutation) SetCreatedAt(t time.Time)
- func (m *FollowMutation) SetExtensions(v versia.Extensions)
- func (m *FollowMutation) SetField(name string, value ent.Value) error
- func (m *FollowMutation) SetFolloweeID(id uuid.UUID)
- func (m *FollowMutation) SetFollowerID(id uuid.UUID)
- func (m *FollowMutation) SetID(id uuid.UUID)
- func (m *FollowMutation) SetIsRemote(b bool)
- func (m *FollowMutation) SetOp(op Op)
- func (m *FollowMutation) SetStatus(f follow.Status)
- func (m *FollowMutation) SetURI(s string)
- func (m *FollowMutation) SetUpdatedAt(t time.Time)
- func (m *FollowMutation) Status() (r follow.Status, exists bool)
- func (m FollowMutation) Tx() (*Tx, error)
- func (m *FollowMutation) Type() string
- func (m *FollowMutation) URI() (r string, exists bool)
- func (m *FollowMutation) UpdatedAt() (r time.Time, exists bool)
- func (m *FollowMutation) Where(ps ...predicate.Follow)
- func (m *FollowMutation) WhereP(ps ...func(*sql.Selector))
- type FollowQuery
- func (fq *FollowQuery) Aggregate(fns ...AggregateFunc) *FollowSelect
- func (fq *FollowQuery) All(ctx context.Context) ([]*Follow, error)
- func (fq *FollowQuery) AllX(ctx context.Context) []*Follow
- func (fq *FollowQuery) Clone() *FollowQuery
- func (fq *FollowQuery) Count(ctx context.Context) (int, error)
- func (fq *FollowQuery) CountX(ctx context.Context) int
- func (fq *FollowQuery) Exist(ctx context.Context) (bool, error)
- func (fq *FollowQuery) ExistX(ctx context.Context) bool
- func (fq *FollowQuery) First(ctx context.Context) (*Follow, error)
- func (fq *FollowQuery) FirstID(ctx context.Context) (id uuid.UUID, err error)
- func (fq *FollowQuery) FirstIDX(ctx context.Context) uuid.UUID
- func (fq *FollowQuery) FirstX(ctx context.Context) *Follow
- func (fq *FollowQuery) GroupBy(field string, fields ...string) *FollowGroupBy
- func (fq *FollowQuery) IDs(ctx context.Context) (ids []uuid.UUID, err error)
- func (fq *FollowQuery) IDsX(ctx context.Context) []uuid.UUID
- func (fq *FollowQuery) Limit(limit int) *FollowQuery
- func (fq *FollowQuery) Offset(offset int) *FollowQuery
- func (fq *FollowQuery) Only(ctx context.Context) (*Follow, error)
- func (fq *FollowQuery) OnlyID(ctx context.Context) (id uuid.UUID, err error)
- func (fq *FollowQuery) OnlyIDX(ctx context.Context) uuid.UUID
- func (fq *FollowQuery) OnlyX(ctx context.Context) *Follow
- func (fq *FollowQuery) Order(o ...follow.OrderOption) *FollowQuery
- func (fq *FollowQuery) QueryFollowee() *UserQuery
- func (fq *FollowQuery) QueryFollower() *UserQuery
- func (fq *FollowQuery) Select(fields ...string) *FollowSelect
- func (fq *FollowQuery) Unique(unique bool) *FollowQuery
- func (fq *FollowQuery) Where(ps ...predicate.Follow) *FollowQuery
- func (fq *FollowQuery) WithFollowee(opts ...func(*UserQuery)) *FollowQuery
- func (fq *FollowQuery) WithFollower(opts ...func(*UserQuery)) *FollowQuery
- type FollowSelect
- func (fs *FollowSelect) Aggregate(fns ...AggregateFunc) *FollowSelect
- func (s *FollowSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *FollowSelect) BoolX(ctx context.Context) bool
- func (s *FollowSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *FollowSelect) BoolsX(ctx context.Context) []bool
- func (s *FollowSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *FollowSelect) Float64X(ctx context.Context) float64
- func (s *FollowSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *FollowSelect) Float64sX(ctx context.Context) []float64
- func (s *FollowSelect) Int(ctx context.Context) (_ int, err error)
- func (s *FollowSelect) IntX(ctx context.Context) int
- func (s *FollowSelect) Ints(ctx context.Context) ([]int, error)
- func (s *FollowSelect) IntsX(ctx context.Context) []int
- func (fs *FollowSelect) Scan(ctx context.Context, v any) error
- func (s *FollowSelect) ScanX(ctx context.Context, v any)
- func (s *FollowSelect) String(ctx context.Context) (_ string, err error)
- func (s *FollowSelect) StringX(ctx context.Context) string
- func (s *FollowSelect) Strings(ctx context.Context) ([]string, error)
- func (s *FollowSelect) StringsX(ctx context.Context) []string
- type FollowUpdate
- func (fu *FollowUpdate) ClearFollowee() *FollowUpdate
- func (fu *FollowUpdate) ClearFollower() *FollowUpdate
- func (fu *FollowUpdate) Exec(ctx context.Context) error
- func (fu *FollowUpdate) ExecX(ctx context.Context)
- func (fu *FollowUpdate) Mutation() *FollowMutation
- func (fu *FollowUpdate) Save(ctx context.Context) (int, error)
- func (fu *FollowUpdate) SaveX(ctx context.Context) int
- func (fu *FollowUpdate) SetExtensions(v versia.Extensions) *FollowUpdate
- func (fu *FollowUpdate) SetFollowee(u *User) *FollowUpdate
- func (fu *FollowUpdate) SetFolloweeID(id uuid.UUID) *FollowUpdate
- func (fu *FollowUpdate) SetFollower(u *User) *FollowUpdate
- func (fu *FollowUpdate) SetFollowerID(id uuid.UUID) *FollowUpdate
- func (fu *FollowUpdate) SetIsRemote(b bool) *FollowUpdate
- func (fu *FollowUpdate) SetNillableIsRemote(b *bool) *FollowUpdate
- func (fu *FollowUpdate) SetNillableStatus(f *follow.Status) *FollowUpdate
- func (fu *FollowUpdate) SetNillableURI(s *string) *FollowUpdate
- func (fu *FollowUpdate) SetStatus(f follow.Status) *FollowUpdate
- func (fu *FollowUpdate) SetURI(s string) *FollowUpdate
- func (fu *FollowUpdate) SetUpdatedAt(t time.Time) *FollowUpdate
- func (fu *FollowUpdate) Where(ps ...predicate.Follow) *FollowUpdate
- type FollowUpdateOne
- func (fuo *FollowUpdateOne) ClearFollowee() *FollowUpdateOne
- func (fuo *FollowUpdateOne) ClearFollower() *FollowUpdateOne
- func (fuo *FollowUpdateOne) Exec(ctx context.Context) error
- func (fuo *FollowUpdateOne) ExecX(ctx context.Context)
- func (fuo *FollowUpdateOne) Mutation() *FollowMutation
- func (fuo *FollowUpdateOne) Save(ctx context.Context) (*Follow, error)
- func (fuo *FollowUpdateOne) SaveX(ctx context.Context) *Follow
- func (fuo *FollowUpdateOne) Select(field string, fields ...string) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetExtensions(v versia.Extensions) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetFollowee(u *User) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetFolloweeID(id uuid.UUID) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetFollower(u *User) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetFollowerID(id uuid.UUID) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetIsRemote(b bool) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetNillableIsRemote(b *bool) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetNillableStatus(f *follow.Status) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetNillableURI(s *string) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetStatus(f follow.Status) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetURI(s string) *FollowUpdateOne
- func (fuo *FollowUpdateOne) SetUpdatedAt(t time.Time) *FollowUpdateOne
- func (fuo *FollowUpdateOne) Where(ps ...predicate.Follow) *FollowUpdateOne
- type FollowUpsert
- func (u *FollowUpsert) SetExtensions(v versia.Extensions) *FollowUpsert
- func (u *FollowUpsert) SetIsRemote(v bool) *FollowUpsert
- func (u *FollowUpsert) SetStatus(v follow.Status) *FollowUpsert
- func (u *FollowUpsert) SetURI(v string) *FollowUpsert
- func (u *FollowUpsert) SetUpdatedAt(v time.Time) *FollowUpsert
- func (u *FollowUpsert) UpdateExtensions() *FollowUpsert
- func (u *FollowUpsert) UpdateIsRemote() *FollowUpsert
- func (u *FollowUpsert) UpdateStatus() *FollowUpsert
- func (u *FollowUpsert) UpdateURI() *FollowUpsert
- func (u *FollowUpsert) UpdateUpdatedAt() *FollowUpsert
- type FollowUpsertBulk
- func (u *FollowUpsertBulk) DoNothing() *FollowUpsertBulk
- func (u *FollowUpsertBulk) Exec(ctx context.Context) error
- func (u *FollowUpsertBulk) ExecX(ctx context.Context)
- func (u *FollowUpsertBulk) Ignore() *FollowUpsertBulk
- func (u *FollowUpsertBulk) SetExtensions(v versia.Extensions) *FollowUpsertBulk
- func (u *FollowUpsertBulk) SetIsRemote(v bool) *FollowUpsertBulk
- func (u *FollowUpsertBulk) SetStatus(v follow.Status) *FollowUpsertBulk
- func (u *FollowUpsertBulk) SetURI(v string) *FollowUpsertBulk
- func (u *FollowUpsertBulk) SetUpdatedAt(v time.Time) *FollowUpsertBulk
- func (u *FollowUpsertBulk) Update(set func(*FollowUpsert)) *FollowUpsertBulk
- func (u *FollowUpsertBulk) UpdateExtensions() *FollowUpsertBulk
- func (u *FollowUpsertBulk) UpdateIsRemote() *FollowUpsertBulk
- func (u *FollowUpsertBulk) UpdateNewValues() *FollowUpsertBulk
- func (u *FollowUpsertBulk) UpdateStatus() *FollowUpsertBulk
- func (u *FollowUpsertBulk) UpdateURI() *FollowUpsertBulk
- func (u *FollowUpsertBulk) UpdateUpdatedAt() *FollowUpsertBulk
- type FollowUpsertOne
- func (u *FollowUpsertOne) DoNothing() *FollowUpsertOne
- func (u *FollowUpsertOne) Exec(ctx context.Context) error
- func (u *FollowUpsertOne) ExecX(ctx context.Context)
- func (u *FollowUpsertOne) ID(ctx context.Context) (id uuid.UUID, err error)
- func (u *FollowUpsertOne) IDX(ctx context.Context) uuid.UUID
- func (u *FollowUpsertOne) Ignore() *FollowUpsertOne
- func (u *FollowUpsertOne) SetExtensions(v versia.Extensions) *FollowUpsertOne
- func (u *FollowUpsertOne) SetIsRemote(v bool) *FollowUpsertOne
- func (u *FollowUpsertOne) SetStatus(v follow.Status) *FollowUpsertOne
- func (u *FollowUpsertOne) SetURI(v string) *FollowUpsertOne
- func (u *FollowUpsertOne) SetUpdatedAt(v time.Time) *FollowUpsertOne
- func (u *FollowUpsertOne) Update(set func(*FollowUpsert)) *FollowUpsertOne
- func (u *FollowUpsertOne) UpdateExtensions() *FollowUpsertOne
- func (u *FollowUpsertOne) UpdateIsRemote() *FollowUpsertOne
- func (u *FollowUpsertOne) UpdateNewValues() *FollowUpsertOne
- func (u *FollowUpsertOne) UpdateStatus() *FollowUpsertOne
- func (u *FollowUpsertOne) UpdateURI() *FollowUpsertOne
- func (u *FollowUpsertOne) UpdateUpdatedAt() *FollowUpsertOne
- type Follows
- type Hook
- type Image
- type ImageClient
- func (c *ImageClient) Create() *ImageCreate
- func (c *ImageClient) CreateBulk(builders ...*ImageCreate) *ImageCreateBulk
- func (c *ImageClient) Delete() *ImageDelete
- func (c *ImageClient) DeleteOne(i *Image) *ImageDeleteOne
- func (c *ImageClient) DeleteOneID(id int) *ImageDeleteOne
- func (c *ImageClient) Get(ctx context.Context, id int) (*Image, error)
- func (c *ImageClient) GetX(ctx context.Context, id int) *Image
- func (c *ImageClient) Hooks() []Hook
- func (c *ImageClient) Intercept(interceptors ...Interceptor)
- func (c *ImageClient) Interceptors() []Interceptor
- func (c *ImageClient) MapCreateBulk(slice any, setFunc func(*ImageCreate, int)) *ImageCreateBulk
- func (c *ImageClient) Query() *ImageQuery
- func (c *ImageClient) Update() *ImageUpdate
- func (c *ImageClient) UpdateOne(i *Image) *ImageUpdateOne
- func (c *ImageClient) UpdateOneID(id int) *ImageUpdateOne
- func (c *ImageClient) Use(hooks ...Hook)
- type ImageCreate
- func (ic *ImageCreate) Exec(ctx context.Context) error
- func (ic *ImageCreate) ExecX(ctx context.Context)
- func (ic *ImageCreate) Mutation() *ImageMutation
- func (ic *ImageCreate) OnConflict(opts ...sql.ConflictOption) *ImageUpsertOne
- func (ic *ImageCreate) OnConflictColumns(columns ...string) *ImageUpsertOne
- func (ic *ImageCreate) Save(ctx context.Context) (*Image, error)
- func (ic *ImageCreate) SaveX(ctx context.Context) *Image
- func (ic *ImageCreate) SetMimeType(s string) *ImageCreate
- func (ic *ImageCreate) SetURL(s string) *ImageCreate
- type ImageCreateBulk
- func (icb *ImageCreateBulk) Exec(ctx context.Context) error
- func (icb *ImageCreateBulk) ExecX(ctx context.Context)
- func (icb *ImageCreateBulk) OnConflict(opts ...sql.ConflictOption) *ImageUpsertBulk
- func (icb *ImageCreateBulk) OnConflictColumns(columns ...string) *ImageUpsertBulk
- func (icb *ImageCreateBulk) Save(ctx context.Context) ([]*Image, error)
- func (icb *ImageCreateBulk) SaveX(ctx context.Context) []*Image
- type ImageDelete
- type ImageDeleteOne
- type ImageGroupBy
- func (igb *ImageGroupBy) Aggregate(fns ...AggregateFunc) *ImageGroupBy
- func (s *ImageGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *ImageGroupBy) BoolX(ctx context.Context) bool
- func (s *ImageGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *ImageGroupBy) BoolsX(ctx context.Context) []bool
- func (s *ImageGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *ImageGroupBy) Float64X(ctx context.Context) float64
- func (s *ImageGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *ImageGroupBy) Float64sX(ctx context.Context) []float64
- func (s *ImageGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *ImageGroupBy) IntX(ctx context.Context) int
- func (s *ImageGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *ImageGroupBy) IntsX(ctx context.Context) []int
- func (igb *ImageGroupBy) Scan(ctx context.Context, v any) error
- func (s *ImageGroupBy) ScanX(ctx context.Context, v any)
- func (s *ImageGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *ImageGroupBy) StringX(ctx context.Context) string
- func (s *ImageGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *ImageGroupBy) StringsX(ctx context.Context) []string
- type ImageMutation
- func (m *ImageMutation) AddField(name string, value ent.Value) error
- func (m *ImageMutation) AddedEdges() []string
- func (m *ImageMutation) AddedField(name string) (ent.Value, bool)
- func (m *ImageMutation) AddedFields() []string
- func (m *ImageMutation) AddedIDs(name string) []ent.Value
- func (m *ImageMutation) ClearEdge(name string) error
- func (m *ImageMutation) ClearField(name string) error
- func (m *ImageMutation) ClearedEdges() []string
- func (m *ImageMutation) ClearedFields() []string
- func (m ImageMutation) Client() *Client
- func (m *ImageMutation) EdgeCleared(name string) bool
- func (m *ImageMutation) Field(name string) (ent.Value, bool)
- func (m *ImageMutation) FieldCleared(name string) bool
- func (m *ImageMutation) Fields() []string
- func (m *ImageMutation) ID() (id int, exists bool)
- func (m *ImageMutation) IDs(ctx context.Context) ([]int, error)
- func (m *ImageMutation) MimeType() (r string, exists bool)
- func (m *ImageMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ImageMutation) OldMimeType(ctx context.Context) (v string, err error)
- func (m *ImageMutation) OldURL(ctx context.Context) (v string, err error)
- func (m *ImageMutation) Op() Op
- func (m *ImageMutation) RemovedEdges() []string
- func (m *ImageMutation) RemovedIDs(name string) []ent.Value
- func (m *ImageMutation) ResetEdge(name string) error
- func (m *ImageMutation) ResetField(name string) error
- func (m *ImageMutation) ResetMimeType()
- func (m *ImageMutation) ResetURL()
- func (m *ImageMutation) SetField(name string, value ent.Value) error
- func (m *ImageMutation) SetMimeType(s string)
- func (m *ImageMutation) SetOp(op Op)
- func (m *ImageMutation) SetURL(s string)
- func (m ImageMutation) Tx() (*Tx, error)
- func (m *ImageMutation) Type() string
- func (m *ImageMutation) URL() (r string, exists bool)
- func (m *ImageMutation) Where(ps ...predicate.Image)
- func (m *ImageMutation) WhereP(ps ...func(*sql.Selector))
- type ImageQuery
- func (iq *ImageQuery) Aggregate(fns ...AggregateFunc) *ImageSelect
- func (iq *ImageQuery) All(ctx context.Context) ([]*Image, error)
- func (iq *ImageQuery) AllX(ctx context.Context) []*Image
- func (iq *ImageQuery) Clone() *ImageQuery
- func (iq *ImageQuery) Count(ctx context.Context) (int, error)
- func (iq *ImageQuery) CountX(ctx context.Context) int
- func (iq *ImageQuery) Exist(ctx context.Context) (bool, error)
- func (iq *ImageQuery) ExistX(ctx context.Context) bool
- func (iq *ImageQuery) First(ctx context.Context) (*Image, error)
- func (iq *ImageQuery) FirstID(ctx context.Context) (id int, err error)
- func (iq *ImageQuery) FirstIDX(ctx context.Context) int
- func (iq *ImageQuery) FirstX(ctx context.Context) *Image
- func (iq *ImageQuery) GroupBy(field string, fields ...string) *ImageGroupBy
- func (iq *ImageQuery) IDs(ctx context.Context) (ids []int, err error)
- func (iq *ImageQuery) IDsX(ctx context.Context) []int
- func (iq *ImageQuery) Limit(limit int) *ImageQuery
- func (iq *ImageQuery) Offset(offset int) *ImageQuery
- func (iq *ImageQuery) Only(ctx context.Context) (*Image, error)
- func (iq *ImageQuery) OnlyID(ctx context.Context) (id int, err error)
- func (iq *ImageQuery) OnlyIDX(ctx context.Context) int
- func (iq *ImageQuery) OnlyX(ctx context.Context) *Image
- func (iq *ImageQuery) Order(o ...image.OrderOption) *ImageQuery
- func (iq *ImageQuery) Select(fields ...string) *ImageSelect
- func (iq *ImageQuery) Unique(unique bool) *ImageQuery
- func (iq *ImageQuery) Where(ps ...predicate.Image) *ImageQuery
- type ImageSelect
- func (is *ImageSelect) Aggregate(fns ...AggregateFunc) *ImageSelect
- func (s *ImageSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *ImageSelect) BoolX(ctx context.Context) bool
- func (s *ImageSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *ImageSelect) BoolsX(ctx context.Context) []bool
- func (s *ImageSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *ImageSelect) Float64X(ctx context.Context) float64
- func (s *ImageSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *ImageSelect) Float64sX(ctx context.Context) []float64
- func (s *ImageSelect) Int(ctx context.Context) (_ int, err error)
- func (s *ImageSelect) IntX(ctx context.Context) int
- func (s *ImageSelect) Ints(ctx context.Context) ([]int, error)
- func (s *ImageSelect) IntsX(ctx context.Context) []int
- func (is *ImageSelect) Scan(ctx context.Context, v any) error
- func (s *ImageSelect) ScanX(ctx context.Context, v any)
- func (s *ImageSelect) String(ctx context.Context) (_ string, err error)
- func (s *ImageSelect) StringX(ctx context.Context) string
- func (s *ImageSelect) Strings(ctx context.Context) ([]string, error)
- func (s *ImageSelect) StringsX(ctx context.Context) []string
- type ImageUpdate
- func (iu *ImageUpdate) Exec(ctx context.Context) error
- func (iu *ImageUpdate) ExecX(ctx context.Context)
- func (iu *ImageUpdate) Mutation() *ImageMutation
- func (iu *ImageUpdate) Save(ctx context.Context) (int, error)
- func (iu *ImageUpdate) SaveX(ctx context.Context) int
- func (iu *ImageUpdate) SetMimeType(s string) *ImageUpdate
- func (iu *ImageUpdate) SetNillableMimeType(s *string) *ImageUpdate
- func (iu *ImageUpdate) SetNillableURL(s *string) *ImageUpdate
- func (iu *ImageUpdate) SetURL(s string) *ImageUpdate
- func (iu *ImageUpdate) Where(ps ...predicate.Image) *ImageUpdate
- type ImageUpdateOne
- func (iuo *ImageUpdateOne) Exec(ctx context.Context) error
- func (iuo *ImageUpdateOne) ExecX(ctx context.Context)
- func (iuo *ImageUpdateOne) Mutation() *ImageMutation
- func (iuo *ImageUpdateOne) Save(ctx context.Context) (*Image, error)
- func (iuo *ImageUpdateOne) SaveX(ctx context.Context) *Image
- func (iuo *ImageUpdateOne) Select(field string, fields ...string) *ImageUpdateOne
- func (iuo *ImageUpdateOne) SetMimeType(s string) *ImageUpdateOne
- func (iuo *ImageUpdateOne) SetNillableMimeType(s *string) *ImageUpdateOne
- func (iuo *ImageUpdateOne) SetNillableURL(s *string) *ImageUpdateOne
- func (iuo *ImageUpdateOne) SetURL(s string) *ImageUpdateOne
- func (iuo *ImageUpdateOne) Where(ps ...predicate.Image) *ImageUpdateOne
- type ImageUpsert
- type ImageUpsertBulk
- func (u *ImageUpsertBulk) DoNothing() *ImageUpsertBulk
- func (u *ImageUpsertBulk) Exec(ctx context.Context) error
- func (u *ImageUpsertBulk) ExecX(ctx context.Context)
- func (u *ImageUpsertBulk) Ignore() *ImageUpsertBulk
- func (u *ImageUpsertBulk) SetMimeType(v string) *ImageUpsertBulk
- func (u *ImageUpsertBulk) SetURL(v string) *ImageUpsertBulk
- func (u *ImageUpsertBulk) Update(set func(*ImageUpsert)) *ImageUpsertBulk
- func (u *ImageUpsertBulk) UpdateMimeType() *ImageUpsertBulk
- func (u *ImageUpsertBulk) UpdateNewValues() *ImageUpsertBulk
- func (u *ImageUpsertBulk) UpdateURL() *ImageUpsertBulk
- type ImageUpsertOne
- func (u *ImageUpsertOne) DoNothing() *ImageUpsertOne
- func (u *ImageUpsertOne) Exec(ctx context.Context) error
- func (u *ImageUpsertOne) ExecX(ctx context.Context)
- func (u *ImageUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *ImageUpsertOne) IDX(ctx context.Context) int
- func (u *ImageUpsertOne) Ignore() *ImageUpsertOne
- func (u *ImageUpsertOne) SetMimeType(v string) *ImageUpsertOne
- func (u *ImageUpsertOne) SetURL(v string) *ImageUpsertOne
- func (u *ImageUpsertOne) Update(set func(*ImageUpsert)) *ImageUpsertOne
- func (u *ImageUpsertOne) UpdateMimeType() *ImageUpsertOne
- func (u *ImageUpsertOne) UpdateNewValues() *ImageUpsertOne
- func (u *ImageUpsertOne) UpdateURL() *ImageUpsertOne
- type Images
- type InstanceMetadata
- func (im *InstanceMetadata) QueryAdmins() *UserQuery
- func (im *InstanceMetadata) QueryModerators() *UserQuery
- func (im *InstanceMetadata) QueryUsers() *UserQuery
- func (im *InstanceMetadata) String() string
- func (im *InstanceMetadata) Unwrap() *InstanceMetadata
- func (im *InstanceMetadata) Update() *InstanceMetadataUpdateOne
- func (im *InstanceMetadata) Value(name string) (ent.Value, error)
- type InstanceMetadataClient
- func (c *InstanceMetadataClient) Create() *InstanceMetadataCreate
- func (c *InstanceMetadataClient) CreateBulk(builders ...*InstanceMetadataCreate) *InstanceMetadataCreateBulk
- func (c *InstanceMetadataClient) Delete() *InstanceMetadataDelete
- func (c *InstanceMetadataClient) DeleteOne(im *InstanceMetadata) *InstanceMetadataDeleteOne
- func (c *InstanceMetadataClient) DeleteOneID(id uuid.UUID) *InstanceMetadataDeleteOne
- func (c *InstanceMetadataClient) Get(ctx context.Context, id uuid.UUID) (*InstanceMetadata, error)
- func (c *InstanceMetadataClient) GetX(ctx context.Context, id uuid.UUID) *InstanceMetadata
- func (c *InstanceMetadataClient) Hooks() []Hook
- func (c *InstanceMetadataClient) Intercept(interceptors ...Interceptor)
- func (c *InstanceMetadataClient) Interceptors() []Interceptor
- func (c *InstanceMetadataClient) MapCreateBulk(slice any, setFunc func(*InstanceMetadataCreate, int)) *InstanceMetadataCreateBulk
- func (c *InstanceMetadataClient) Query() *InstanceMetadataQuery
- func (c *InstanceMetadataClient) QueryAdmins(im *InstanceMetadata) *UserQuery
- func (c *InstanceMetadataClient) QueryModerators(im *InstanceMetadata) *UserQuery
- func (c *InstanceMetadataClient) QueryUsers(im *InstanceMetadata) *UserQuery
- func (c *InstanceMetadataClient) Update() *InstanceMetadataUpdate
- func (c *InstanceMetadataClient) UpdateOne(im *InstanceMetadata) *InstanceMetadataUpdateOne
- func (c *InstanceMetadataClient) UpdateOneID(id uuid.UUID) *InstanceMetadataUpdateOne
- func (c *InstanceMetadataClient) Use(hooks ...Hook)
- type InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) AddAdminIDs(ids ...uuid.UUID) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) AddAdmins(u ...*User) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) AddModeratorIDs(ids ...uuid.UUID) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) AddModerators(u ...*User) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) AddUserIDs(ids ...uuid.UUID) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) AddUsers(u ...*User) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) Exec(ctx context.Context) error
- func (imc *InstanceMetadataCreate) ExecX(ctx context.Context)
- func (imc *InstanceMetadataCreate) Mutation() *InstanceMetadataMutation
- func (imc *InstanceMetadataCreate) OnConflict(opts ...sql.ConflictOption) *InstanceMetadataUpsertOne
- func (imc *InstanceMetadataCreate) OnConflictColumns(columns ...string) *InstanceMetadataUpsertOne
- func (imc *InstanceMetadataCreate) Save(ctx context.Context) (*InstanceMetadata, error)
- func (imc *InstanceMetadataCreate) SaveX(ctx context.Context) *InstanceMetadata
- func (imc *InstanceMetadataCreate) SetAdminsURI(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetBannerEndpoint(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetBannerMimeType(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetCreatedAt(t time.Time) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetDescription(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetExtensions(v versia.Extensions) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetHost(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetID(u uuid.UUID) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetIsRemote(b bool) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetLogoEndpoint(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetLogoMimeType(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetModeratorsURI(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetName(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableAdminsURI(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableBannerEndpoint(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableBannerMimeType(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableCreatedAt(t *time.Time) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableDescription(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableID(u *uuid.UUID) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableLogoEndpoint(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableLogoMimeType(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableModeratorsURI(s *string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetNillableUpdatedAt(t *time.Time) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetPrivateKey(b []byte) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetPublicKey(b []byte) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetPublicKeyAlgorithm(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetSharedInboxURI(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetSoftwareName(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetSoftwareVersion(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetSupportedExtensions(s []string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetSupportedVersions(s []string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetURI(s string) *InstanceMetadataCreate
- func (imc *InstanceMetadataCreate) SetUpdatedAt(t time.Time) *InstanceMetadataCreate
- type InstanceMetadataCreateBulk
- func (imcb *InstanceMetadataCreateBulk) Exec(ctx context.Context) error
- func (imcb *InstanceMetadataCreateBulk) ExecX(ctx context.Context)
- func (imcb *InstanceMetadataCreateBulk) OnConflict(opts ...sql.ConflictOption) *InstanceMetadataUpsertBulk
- func (imcb *InstanceMetadataCreateBulk) OnConflictColumns(columns ...string) *InstanceMetadataUpsertBulk
- func (imcb *InstanceMetadataCreateBulk) Save(ctx context.Context) ([]*InstanceMetadata, error)
- func (imcb *InstanceMetadataCreateBulk) SaveX(ctx context.Context) []*InstanceMetadata
- type InstanceMetadataDelete
- type InstanceMetadataDeleteOne
- type InstanceMetadataEdges
- type InstanceMetadataGroupBy
- func (imgb *InstanceMetadataGroupBy) Aggregate(fns ...AggregateFunc) *InstanceMetadataGroupBy
- func (s *InstanceMetadataGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *InstanceMetadataGroupBy) BoolX(ctx context.Context) bool
- func (s *InstanceMetadataGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *InstanceMetadataGroupBy) BoolsX(ctx context.Context) []bool
- func (s *InstanceMetadataGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *InstanceMetadataGroupBy) Float64X(ctx context.Context) float64
- func (s *InstanceMetadataGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *InstanceMetadataGroupBy) Float64sX(ctx context.Context) []float64
- func (s *InstanceMetadataGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *InstanceMetadataGroupBy) IntX(ctx context.Context) int
- func (s *InstanceMetadataGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *InstanceMetadataGroupBy) IntsX(ctx context.Context) []int
- func (imgb *InstanceMetadataGroupBy) Scan(ctx context.Context, v any) error
- func (s *InstanceMetadataGroupBy) ScanX(ctx context.Context, v any)
- func (s *InstanceMetadataGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *InstanceMetadataGroupBy) StringX(ctx context.Context) string
- func (s *InstanceMetadataGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *InstanceMetadataGroupBy) StringsX(ctx context.Context) []string
- type InstanceMetadataMutation
- func (m *InstanceMetadataMutation) AddAdminIDs(ids ...uuid.UUID)
- func (m *InstanceMetadataMutation) AddField(name string, value ent.Value) error
- func (m *InstanceMetadataMutation) AddModeratorIDs(ids ...uuid.UUID)
- func (m *InstanceMetadataMutation) AddUserIDs(ids ...uuid.UUID)
- func (m *InstanceMetadataMutation) AddedEdges() []string
- func (m *InstanceMetadataMutation) AddedField(name string) (ent.Value, bool)
- func (m *InstanceMetadataMutation) AddedFields() []string
- func (m *InstanceMetadataMutation) AddedIDs(name string) []ent.Value
- func (m *InstanceMetadataMutation) AdminsCleared() bool
- func (m *InstanceMetadataMutation) AdminsIDs() (ids []uuid.UUID)
- func (m *InstanceMetadataMutation) AdminsURI() (r string, exists bool)
- func (m *InstanceMetadataMutation) AdminsURICleared() bool
- func (m *InstanceMetadataMutation) AppendSupportedExtensions(s []string)
- func (m *InstanceMetadataMutation) AppendSupportedVersions(s []string)
- func (m *InstanceMetadataMutation) AppendedSupportedExtensions() ([]string, bool)
- func (m *InstanceMetadataMutation) AppendedSupportedVersions() ([]string, bool)
- func (m *InstanceMetadataMutation) BannerEndpoint() (r string, exists bool)
- func (m *InstanceMetadataMutation) BannerEndpointCleared() bool
- func (m *InstanceMetadataMutation) BannerMimeType() (r string, exists bool)
- func (m *InstanceMetadataMutation) BannerMimeTypeCleared() bool
- func (m *InstanceMetadataMutation) ClearAdmins()
- func (m *InstanceMetadataMutation) ClearAdminsURI()
- func (m *InstanceMetadataMutation) ClearBannerEndpoint()
- func (m *InstanceMetadataMutation) ClearBannerMimeType()
- func (m *InstanceMetadataMutation) ClearDescription()
- func (m *InstanceMetadataMutation) ClearEdge(name string) error
- func (m *InstanceMetadataMutation) ClearField(name string) error
- func (m *InstanceMetadataMutation) ClearLogoEndpoint()
- func (m *InstanceMetadataMutation) ClearLogoMimeType()
- func (m *InstanceMetadataMutation) ClearModerators()
- func (m *InstanceMetadataMutation) ClearModeratorsURI()
- func (m *InstanceMetadataMutation) ClearPrivateKey()
- func (m *InstanceMetadataMutation) ClearUsers()
- func (m *InstanceMetadataMutation) ClearedEdges() []string
- func (m *InstanceMetadataMutation) ClearedFields() []string
- func (m InstanceMetadataMutation) Client() *Client
- func (m *InstanceMetadataMutation) CreatedAt() (r time.Time, exists bool)
- func (m *InstanceMetadataMutation) Description() (r string, exists bool)
- func (m *InstanceMetadataMutation) DescriptionCleared() bool
- func (m *InstanceMetadataMutation) EdgeCleared(name string) bool
- func (m *InstanceMetadataMutation) Extensions() (r versia.Extensions, exists bool)
- func (m *InstanceMetadataMutation) Field(name string) (ent.Value, bool)
- func (m *InstanceMetadataMutation) FieldCleared(name string) bool
- func (m *InstanceMetadataMutation) Fields() []string
- func (m *InstanceMetadataMutation) Host() (r string, exists bool)
- func (m *InstanceMetadataMutation) ID() (id uuid.UUID, exists bool)
- func (m *InstanceMetadataMutation) IDs(ctx context.Context) ([]uuid.UUID, error)
- func (m *InstanceMetadataMutation) IsRemote() (r bool, exists bool)
- func (m *InstanceMetadataMutation) LogoEndpoint() (r string, exists bool)
- func (m *InstanceMetadataMutation) LogoEndpointCleared() bool
- func (m *InstanceMetadataMutation) LogoMimeType() (r string, exists bool)
- func (m *InstanceMetadataMutation) LogoMimeTypeCleared() bool
- func (m *InstanceMetadataMutation) ModeratorsCleared() bool
- func (m *InstanceMetadataMutation) ModeratorsIDs() (ids []uuid.UUID)
- func (m *InstanceMetadataMutation) ModeratorsURI() (r string, exists bool)
- func (m *InstanceMetadataMutation) ModeratorsURICleared() bool
- func (m *InstanceMetadataMutation) Name() (r string, exists bool)
- func (m *InstanceMetadataMutation) OldAdminsURI(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldBannerEndpoint(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldBannerMimeType(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)
- func (m *InstanceMetadataMutation) OldDescription(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
- func (m *InstanceMetadataMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *InstanceMetadataMutation) OldHost(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldIsRemote(ctx context.Context) (v bool, err error)
- func (m *InstanceMetadataMutation) OldLogoEndpoint(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldLogoMimeType(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldModeratorsURI(ctx context.Context) (v *string, err error)
- func (m *InstanceMetadataMutation) OldName(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldPrivateKey(ctx context.Context) (v []byte, err error)
- func (m *InstanceMetadataMutation) OldPublicKey(ctx context.Context) (v []byte, err error)
- func (m *InstanceMetadataMutation) OldPublicKeyAlgorithm(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldSharedInboxURI(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldSoftwareName(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldSoftwareVersion(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldSupportedExtensions(ctx context.Context) (v []string, err error)
- func (m *InstanceMetadataMutation) OldSupportedVersions(ctx context.Context) (v []string, err error)
- func (m *InstanceMetadataMutation) OldURI(ctx context.Context) (v string, err error)
- func (m *InstanceMetadataMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)
- func (m *InstanceMetadataMutation) Op() Op
- func (m *InstanceMetadataMutation) PrivateKey() (r []byte, exists bool)
- func (m *InstanceMetadataMutation) PrivateKeyCleared() bool
- func (m *InstanceMetadataMutation) PublicKey() (r []byte, exists bool)
- func (m *InstanceMetadataMutation) PublicKeyAlgorithm() (r string, exists bool)
- func (m *InstanceMetadataMutation) RemoveAdminIDs(ids ...uuid.UUID)
- func (m *InstanceMetadataMutation) RemoveModeratorIDs(ids ...uuid.UUID)
- func (m *InstanceMetadataMutation) RemoveUserIDs(ids ...uuid.UUID)
- func (m *InstanceMetadataMutation) RemovedAdminsIDs() (ids []uuid.UUID)
- func (m *InstanceMetadataMutation) RemovedEdges() []string
- func (m *InstanceMetadataMutation) RemovedIDs(name string) []ent.Value
- func (m *InstanceMetadataMutation) RemovedModeratorsIDs() (ids []uuid.UUID)
- func (m *InstanceMetadataMutation) RemovedUsersIDs() (ids []uuid.UUID)
- func (m *InstanceMetadataMutation) ResetAdmins()
- func (m *InstanceMetadataMutation) ResetAdminsURI()
- func (m *InstanceMetadataMutation) ResetBannerEndpoint()
- func (m *InstanceMetadataMutation) ResetBannerMimeType()
- func (m *InstanceMetadataMutation) ResetCreatedAt()
- func (m *InstanceMetadataMutation) ResetDescription()
- func (m *InstanceMetadataMutation) ResetEdge(name string) error
- func (m *InstanceMetadataMutation) ResetExtensions()
- func (m *InstanceMetadataMutation) ResetField(name string) error
- func (m *InstanceMetadataMutation) ResetHost()
- func (m *InstanceMetadataMutation) ResetIsRemote()
- func (m *InstanceMetadataMutation) ResetLogoEndpoint()
- func (m *InstanceMetadataMutation) ResetLogoMimeType()
- func (m *InstanceMetadataMutation) ResetModerators()
- func (m *InstanceMetadataMutation) ResetModeratorsURI()
- func (m *InstanceMetadataMutation) ResetName()
- func (m *InstanceMetadataMutation) ResetPrivateKey()
- func (m *InstanceMetadataMutation) ResetPublicKey()
- func (m *InstanceMetadataMutation) ResetPublicKeyAlgorithm()
- func (m *InstanceMetadataMutation) ResetSharedInboxURI()
- func (m *InstanceMetadataMutation) ResetSoftwareName()
- func (m *InstanceMetadataMutation) ResetSoftwareVersion()
- func (m *InstanceMetadataMutation) ResetSupportedExtensions()
- func (m *InstanceMetadataMutation) ResetSupportedVersions()
- func (m *InstanceMetadataMutation) ResetURI()
- func (m *InstanceMetadataMutation) ResetUpdatedAt()
- func (m *InstanceMetadataMutation) ResetUsers()
- func (m *InstanceMetadataMutation) SetAdminsURI(s string)
- func (m *InstanceMetadataMutation) SetBannerEndpoint(s string)
- func (m *InstanceMetadataMutation) SetBannerMimeType(s string)
- func (m *InstanceMetadataMutation) SetCreatedAt(t time.Time)
- func (m *InstanceMetadataMutation) SetDescription(s string)
- func (m *InstanceMetadataMutation) SetExtensions(v versia.Extensions)
- func (m *InstanceMetadataMutation) SetField(name string, value ent.Value) error
- func (m *InstanceMetadataMutation) SetHost(s string)
- func (m *InstanceMetadataMutation) SetID(id uuid.UUID)
- func (m *InstanceMetadataMutation) SetIsRemote(b bool)
- func (m *InstanceMetadataMutation) SetLogoEndpoint(s string)
- func (m *InstanceMetadataMutation) SetLogoMimeType(s string)
- func (m *InstanceMetadataMutation) SetModeratorsURI(s string)
- func (m *InstanceMetadataMutation) SetName(s string)
- func (m *InstanceMetadataMutation) SetOp(op Op)
- func (m *InstanceMetadataMutation) SetPrivateKey(b []byte)
- func (m *InstanceMetadataMutation) SetPublicKey(b []byte)
- func (m *InstanceMetadataMutation) SetPublicKeyAlgorithm(s string)
- func (m *InstanceMetadataMutation) SetSharedInboxURI(s string)
- func (m *InstanceMetadataMutation) SetSoftwareName(s string)
- func (m *InstanceMetadataMutation) SetSoftwareVersion(s string)
- func (m *InstanceMetadataMutation) SetSupportedExtensions(s []string)
- func (m *InstanceMetadataMutation) SetSupportedVersions(s []string)
- func (m *InstanceMetadataMutation) SetURI(s string)
- func (m *InstanceMetadataMutation) SetUpdatedAt(t time.Time)
- func (m *InstanceMetadataMutation) SharedInboxURI() (r string, exists bool)
- func (m *InstanceMetadataMutation) SoftwareName() (r string, exists bool)
- func (m *InstanceMetadataMutation) SoftwareVersion() (r string, exists bool)
- func (m *InstanceMetadataMutation) SupportedExtensions() (r []string, exists bool)
- func (m *InstanceMetadataMutation) SupportedVersions() (r []string, exists bool)
- func (m InstanceMetadataMutation) Tx() (*Tx, error)
- func (m *InstanceMetadataMutation) Type() string
- func (m *InstanceMetadataMutation) URI() (r string, exists bool)
- func (m *InstanceMetadataMutation) UpdatedAt() (r time.Time, exists bool)
- func (m *InstanceMetadataMutation) UsersCleared() bool
- func (m *InstanceMetadataMutation) UsersIDs() (ids []uuid.UUID)
- func (m *InstanceMetadataMutation) Where(ps ...predicate.InstanceMetadata)
- func (m *InstanceMetadataMutation) WhereP(ps ...func(*sql.Selector))
- type InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) Aggregate(fns ...AggregateFunc) *InstanceMetadataSelect
- func (imq *InstanceMetadataQuery) All(ctx context.Context) ([]*InstanceMetadata, error)
- func (imq *InstanceMetadataQuery) AllX(ctx context.Context) []*InstanceMetadata
- func (imq *InstanceMetadataQuery) Clone() *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) Count(ctx context.Context) (int, error)
- func (imq *InstanceMetadataQuery) CountX(ctx context.Context) int
- func (imq *InstanceMetadataQuery) Exist(ctx context.Context) (bool, error)
- func (imq *InstanceMetadataQuery) ExistX(ctx context.Context) bool
- func (imq *InstanceMetadataQuery) First(ctx context.Context) (*InstanceMetadata, error)
- func (imq *InstanceMetadataQuery) FirstID(ctx context.Context) (id uuid.UUID, err error)
- func (imq *InstanceMetadataQuery) FirstIDX(ctx context.Context) uuid.UUID
- func (imq *InstanceMetadataQuery) FirstX(ctx context.Context) *InstanceMetadata
- func (imq *InstanceMetadataQuery) GroupBy(field string, fields ...string) *InstanceMetadataGroupBy
- func (imq *InstanceMetadataQuery) IDs(ctx context.Context) (ids []uuid.UUID, err error)
- func (imq *InstanceMetadataQuery) IDsX(ctx context.Context) []uuid.UUID
- func (imq *InstanceMetadataQuery) Limit(limit int) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) Offset(offset int) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) Only(ctx context.Context) (*InstanceMetadata, error)
- func (imq *InstanceMetadataQuery) OnlyID(ctx context.Context) (id uuid.UUID, err error)
- func (imq *InstanceMetadataQuery) OnlyIDX(ctx context.Context) uuid.UUID
- func (imq *InstanceMetadataQuery) OnlyX(ctx context.Context) *InstanceMetadata
- func (imq *InstanceMetadataQuery) Order(o ...instancemetadata.OrderOption) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) QueryAdmins() *UserQuery
- func (imq *InstanceMetadataQuery) QueryModerators() *UserQuery
- func (imq *InstanceMetadataQuery) QueryUsers() *UserQuery
- func (imq *InstanceMetadataQuery) Select(fields ...string) *InstanceMetadataSelect
- func (imq *InstanceMetadataQuery) Unique(unique bool) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) WithAdmins(opts ...func(*UserQuery)) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) WithModerators(opts ...func(*UserQuery)) *InstanceMetadataQuery
- func (imq *InstanceMetadataQuery) WithUsers(opts ...func(*UserQuery)) *InstanceMetadataQuery
- type InstanceMetadataSelect
- func (ims *InstanceMetadataSelect) Aggregate(fns ...AggregateFunc) *InstanceMetadataSelect
- func (s *InstanceMetadataSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *InstanceMetadataSelect) BoolX(ctx context.Context) bool
- func (s *InstanceMetadataSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *InstanceMetadataSelect) BoolsX(ctx context.Context) []bool
- func (s *InstanceMetadataSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *InstanceMetadataSelect) Float64X(ctx context.Context) float64
- func (s *InstanceMetadataSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *InstanceMetadataSelect) Float64sX(ctx context.Context) []float64
- func (s *InstanceMetadataSelect) Int(ctx context.Context) (_ int, err error)
- func (s *InstanceMetadataSelect) IntX(ctx context.Context) int
- func (s *InstanceMetadataSelect) Ints(ctx context.Context) ([]int, error)
- func (s *InstanceMetadataSelect) IntsX(ctx context.Context) []int
- func (ims *InstanceMetadataSelect) Scan(ctx context.Context, v any) error
- func (s *InstanceMetadataSelect) ScanX(ctx context.Context, v any)
- func (s *InstanceMetadataSelect) String(ctx context.Context) (_ string, err error)
- func (s *InstanceMetadataSelect) StringX(ctx context.Context) string
- func (s *InstanceMetadataSelect) Strings(ctx context.Context) ([]string, error)
- func (s *InstanceMetadataSelect) StringsX(ctx context.Context) []string
- type InstanceMetadataSlice
- type InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AddAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AddAdmins(u ...*User) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AddModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AddModerators(u ...*User) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AddUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AddUsers(u ...*User) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AppendSupportedExtensions(s []string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) AppendSupportedVersions(s []string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearAdmins() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearAdminsURI() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearBannerEndpoint() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearBannerMimeType() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearDescription() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearLogoEndpoint() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearLogoMimeType() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearModerators() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearModeratorsURI() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearPrivateKey() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) ClearUsers() *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) Exec(ctx context.Context) error
- func (imu *InstanceMetadataUpdate) ExecX(ctx context.Context)
- func (imu *InstanceMetadataUpdate) Mutation() *InstanceMetadataMutation
- func (imu *InstanceMetadataUpdate) RemoveAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) RemoveAdmins(u ...*User) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) RemoveModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) RemoveModerators(u ...*User) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) RemoveUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) RemoveUsers(u ...*User) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) Save(ctx context.Context) (int, error)
- func (imu *InstanceMetadataUpdate) SaveX(ctx context.Context) int
- func (imu *InstanceMetadataUpdate) SetAdminsURI(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetBannerEndpoint(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetBannerMimeType(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetDescription(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetExtensions(v versia.Extensions) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetHost(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetIsRemote(b bool) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetLogoEndpoint(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetLogoMimeType(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetModeratorsURI(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetName(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableAdminsURI(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableBannerEndpoint(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableBannerMimeType(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableDescription(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableHost(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableIsRemote(b *bool) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableLogoEndpoint(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableLogoMimeType(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableModeratorsURI(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableName(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillablePublicKeyAlgorithm(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableSharedInboxURI(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableSoftwareName(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableSoftwareVersion(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetNillableURI(s *string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetPrivateKey(b []byte) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetPublicKey(b []byte) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetPublicKeyAlgorithm(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetSharedInboxURI(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetSoftwareName(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetSoftwareVersion(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetSupportedExtensions(s []string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetSupportedVersions(s []string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetURI(s string) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) SetUpdatedAt(t time.Time) *InstanceMetadataUpdate
- func (imu *InstanceMetadataUpdate) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataUpdate
- type InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AddAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AddAdmins(u ...*User) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AddModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AddModerators(u ...*User) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AddUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AddUsers(u ...*User) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AppendSupportedExtensions(s []string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) AppendSupportedVersions(s []string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearAdmins() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearAdminsURI() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearBannerEndpoint() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearBannerMimeType() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearDescription() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearLogoEndpoint() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearLogoMimeType() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearModerators() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearModeratorsURI() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearPrivateKey() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) ClearUsers() *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) Exec(ctx context.Context) error
- func (imuo *InstanceMetadataUpdateOne) ExecX(ctx context.Context)
- func (imuo *InstanceMetadataUpdateOne) Mutation() *InstanceMetadataMutation
- func (imuo *InstanceMetadataUpdateOne) RemoveAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) RemoveAdmins(u ...*User) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) RemoveModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) RemoveModerators(u ...*User) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) RemoveUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) RemoveUsers(u ...*User) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) Save(ctx context.Context) (*InstanceMetadata, error)
- func (imuo *InstanceMetadataUpdateOne) SaveX(ctx context.Context) *InstanceMetadata
- func (imuo *InstanceMetadataUpdateOne) Select(field string, fields ...string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetAdminsURI(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetBannerEndpoint(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetBannerMimeType(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetDescription(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetExtensions(v versia.Extensions) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetHost(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetIsRemote(b bool) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetLogoEndpoint(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetLogoMimeType(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetModeratorsURI(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetName(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableAdminsURI(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableBannerEndpoint(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableBannerMimeType(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableDescription(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableHost(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableIsRemote(b *bool) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableLogoEndpoint(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableLogoMimeType(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableModeratorsURI(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableName(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillablePublicKeyAlgorithm(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableSharedInboxURI(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableSoftwareName(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableSoftwareVersion(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetNillableURI(s *string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetPrivateKey(b []byte) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetPublicKey(b []byte) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetPublicKeyAlgorithm(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetSharedInboxURI(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetSoftwareName(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetSoftwareVersion(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetSupportedExtensions(s []string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetSupportedVersions(s []string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetURI(s string) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) SetUpdatedAt(t time.Time) *InstanceMetadataUpdateOne
- func (imuo *InstanceMetadataUpdateOne) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataUpdateOne
- type InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearAdminsURI() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearBannerEndpoint() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearBannerMimeType() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearDescription() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearLogoEndpoint() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearLogoMimeType() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearModeratorsURI() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) ClearPrivateKey() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetAdminsURI(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetBannerEndpoint(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetBannerMimeType(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetDescription(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetExtensions(v versia.Extensions) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetHost(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetIsRemote(v bool) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetLogoEndpoint(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetLogoMimeType(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetModeratorsURI(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetName(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetPrivateKey(v []byte) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetPublicKey(v []byte) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetPublicKeyAlgorithm(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetSharedInboxURI(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetSoftwareName(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetSoftwareVersion(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetSupportedExtensions(v []string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetSupportedVersions(v []string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetURI(v string) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) SetUpdatedAt(v time.Time) *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateAdminsURI() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateBannerEndpoint() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateBannerMimeType() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateDescription() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateExtensions() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateHost() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateIsRemote() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateLogoEndpoint() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateLogoMimeType() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateModeratorsURI() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateName() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdatePrivateKey() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdatePublicKey() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdatePublicKeyAlgorithm() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateSharedInboxURI() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateSoftwareName() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateSoftwareVersion() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateSupportedExtensions() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateSupportedVersions() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateURI() *InstanceMetadataUpsert
- func (u *InstanceMetadataUpsert) UpdateUpdatedAt() *InstanceMetadataUpsert
- type InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearAdminsURI() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearBannerEndpoint() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearBannerMimeType() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearDescription() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearLogoEndpoint() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearLogoMimeType() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearModeratorsURI() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) ClearPrivateKey() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) DoNothing() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) Exec(ctx context.Context) error
- func (u *InstanceMetadataUpsertBulk) ExecX(ctx context.Context)
- func (u *InstanceMetadataUpsertBulk) Ignore() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetAdminsURI(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetBannerEndpoint(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetBannerMimeType(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetDescription(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetExtensions(v versia.Extensions) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetHost(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetIsRemote(v bool) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetLogoEndpoint(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetLogoMimeType(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetModeratorsURI(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetName(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetPrivateKey(v []byte) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetPublicKey(v []byte) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetPublicKeyAlgorithm(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetSharedInboxURI(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetSoftwareName(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetSoftwareVersion(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetSupportedExtensions(v []string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetSupportedVersions(v []string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetURI(v string) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) SetUpdatedAt(v time.Time) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) Update(set func(*InstanceMetadataUpsert)) *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateAdminsURI() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateBannerEndpoint() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateBannerMimeType() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateDescription() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateExtensions() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateHost() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateIsRemote() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateLogoEndpoint() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateLogoMimeType() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateModeratorsURI() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateName() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateNewValues() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdatePrivateKey() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdatePublicKey() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdatePublicKeyAlgorithm() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateSharedInboxURI() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateSoftwareName() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateSoftwareVersion() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateSupportedExtensions() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateSupportedVersions() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateURI() *InstanceMetadataUpsertBulk
- func (u *InstanceMetadataUpsertBulk) UpdateUpdatedAt() *InstanceMetadataUpsertBulk
- type InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearAdminsURI() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearBannerEndpoint() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearBannerMimeType() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearDescription() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearLogoEndpoint() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearLogoMimeType() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearModeratorsURI() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) ClearPrivateKey() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) DoNothing() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) Exec(ctx context.Context) error
- func (u *InstanceMetadataUpsertOne) ExecX(ctx context.Context)
- func (u *InstanceMetadataUpsertOne) ID(ctx context.Context) (id uuid.UUID, err error)
- func (u *InstanceMetadataUpsertOne) IDX(ctx context.Context) uuid.UUID
- func (u *InstanceMetadataUpsertOne) Ignore() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetAdminsURI(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetBannerEndpoint(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetBannerMimeType(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetDescription(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetExtensions(v versia.Extensions) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetHost(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetIsRemote(v bool) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetLogoEndpoint(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetLogoMimeType(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetModeratorsURI(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetName(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetPrivateKey(v []byte) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetPublicKey(v []byte) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetPublicKeyAlgorithm(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetSharedInboxURI(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetSoftwareName(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetSoftwareVersion(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetSupportedExtensions(v []string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetSupportedVersions(v []string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetURI(v string) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) SetUpdatedAt(v time.Time) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) Update(set func(*InstanceMetadataUpsert)) *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateAdminsURI() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateBannerEndpoint() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateBannerMimeType() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateDescription() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateExtensions() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateHost() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateIsRemote() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateLogoEndpoint() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateLogoMimeType() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateModeratorsURI() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateName() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateNewValues() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdatePrivateKey() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdatePublicKey() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdatePublicKeyAlgorithm() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateSharedInboxURI() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateSoftwareName() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateSoftwareVersion() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateSupportedExtensions() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateSupportedVersions() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateURI() *InstanceMetadataUpsertOne
- func (u *InstanceMetadataUpsertOne) UpdateUpdatedAt() *InstanceMetadataUpsertOne
- type InterceptFunc
- type Interceptor
- type MutateFunc
- type Mutation
- type Mutator
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Note
- type NoteClient
- func (c *NoteClient) Create() *NoteCreate
- func (c *NoteClient) CreateBulk(builders ...*NoteCreate) *NoteCreateBulk
- func (c *NoteClient) Delete() *NoteDelete
- func (c *NoteClient) DeleteOne(n *Note) *NoteDeleteOne
- func (c *NoteClient) DeleteOneID(id uuid.UUID) *NoteDeleteOne
- func (c *NoteClient) Get(ctx context.Context, id uuid.UUID) (*Note, error)
- func (c *NoteClient) GetX(ctx context.Context, id uuid.UUID) *Note
- func (c *NoteClient) Hooks() []Hook
- func (c *NoteClient) Intercept(interceptors ...Interceptor)
- func (c *NoteClient) Interceptors() []Interceptor
- func (c *NoteClient) MapCreateBulk(slice any, setFunc func(*NoteCreate, int)) *NoteCreateBulk
- func (c *NoteClient) Query() *NoteQuery
- func (c *NoteClient) QueryAttachments(n *Note) *AttachmentQuery
- func (c *NoteClient) QueryAuthor(n *Note) *UserQuery
- func (c *NoteClient) QueryMentions(n *Note) *UserQuery
- func (c *NoteClient) Update() *NoteUpdate
- func (c *NoteClient) UpdateOne(n *Note) *NoteUpdateOne
- func (c *NoteClient) UpdateOneID(id uuid.UUID) *NoteUpdateOne
- func (c *NoteClient) Use(hooks ...Hook)
- type NoteCreate
- func (nc *NoteCreate) AddAttachmentIDs(ids ...uuid.UUID) *NoteCreate
- func (nc *NoteCreate) AddAttachments(a ...*Attachment) *NoteCreate
- func (nc *NoteCreate) AddMentionIDs(ids ...uuid.UUID) *NoteCreate
- func (nc *NoteCreate) AddMentions(u ...*User) *NoteCreate
- func (nc *NoteCreate) Exec(ctx context.Context) error
- func (nc *NoteCreate) ExecX(ctx context.Context)
- func (nc *NoteCreate) Mutation() *NoteMutation
- func (nc *NoteCreate) OnConflict(opts ...sql.ConflictOption) *NoteUpsertOne
- func (nc *NoteCreate) OnConflictColumns(columns ...string) *NoteUpsertOne
- func (nc *NoteCreate) Save(ctx context.Context) (*Note, error)
- func (nc *NoteCreate) SaveX(ctx context.Context) *Note
- func (nc *NoteCreate) SetAuthor(u *User) *NoteCreate
- func (nc *NoteCreate) SetAuthorID(id uuid.UUID) *NoteCreate
- func (nc *NoteCreate) SetContent(s string) *NoteCreate
- func (nc *NoteCreate) SetCreatedAt(t time.Time) *NoteCreate
- func (nc *NoteCreate) SetExtensions(v versia.Extensions) *NoteCreate
- func (nc *NoteCreate) SetID(u uuid.UUID) *NoteCreate
- func (nc *NoteCreate) SetIsRemote(b bool) *NoteCreate
- func (nc *NoteCreate) SetIsSensitive(b bool) *NoteCreate
- func (nc *NoteCreate) SetNillableCreatedAt(t *time.Time) *NoteCreate
- func (nc *NoteCreate) SetNillableID(u *uuid.UUID) *NoteCreate
- func (nc *NoteCreate) SetNillableIsSensitive(b *bool) *NoteCreate
- func (nc *NoteCreate) SetNillableSubject(s *string) *NoteCreate
- func (nc *NoteCreate) SetNillableUpdatedAt(t *time.Time) *NoteCreate
- func (nc *NoteCreate) SetNillableVisibility(n *note.Visibility) *NoteCreate
- func (nc *NoteCreate) SetSubject(s string) *NoteCreate
- func (nc *NoteCreate) SetURI(s string) *NoteCreate
- func (nc *NoteCreate) SetUpdatedAt(t time.Time) *NoteCreate
- func (nc *NoteCreate) SetVisibility(n note.Visibility) *NoteCreate
- type NoteCreateBulk
- func (ncb *NoteCreateBulk) Exec(ctx context.Context) error
- func (ncb *NoteCreateBulk) ExecX(ctx context.Context)
- func (ncb *NoteCreateBulk) OnConflict(opts ...sql.ConflictOption) *NoteUpsertBulk
- func (ncb *NoteCreateBulk) OnConflictColumns(columns ...string) *NoteUpsertBulk
- func (ncb *NoteCreateBulk) Save(ctx context.Context) ([]*Note, error)
- func (ncb *NoteCreateBulk) SaveX(ctx context.Context) []*Note
- type NoteDelete
- type NoteDeleteOne
- type NoteEdges
- type NoteGroupBy
- func (ngb *NoteGroupBy) Aggregate(fns ...AggregateFunc) *NoteGroupBy
- func (s *NoteGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *NoteGroupBy) BoolX(ctx context.Context) bool
- func (s *NoteGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *NoteGroupBy) BoolsX(ctx context.Context) []bool
- func (s *NoteGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *NoteGroupBy) Float64X(ctx context.Context) float64
- func (s *NoteGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *NoteGroupBy) Float64sX(ctx context.Context) []float64
- func (s *NoteGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *NoteGroupBy) IntX(ctx context.Context) int
- func (s *NoteGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *NoteGroupBy) IntsX(ctx context.Context) []int
- func (ngb *NoteGroupBy) Scan(ctx context.Context, v any) error
- func (s *NoteGroupBy) ScanX(ctx context.Context, v any)
- func (s *NoteGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *NoteGroupBy) StringX(ctx context.Context) string
- func (s *NoteGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *NoteGroupBy) StringsX(ctx context.Context) []string
- type NoteMutation
- func (m *NoteMutation) AddAttachmentIDs(ids ...uuid.UUID)
- func (m *NoteMutation) AddField(name string, value ent.Value) error
- func (m *NoteMutation) AddMentionIDs(ids ...uuid.UUID)
- func (m *NoteMutation) AddedEdges() []string
- func (m *NoteMutation) AddedField(name string) (ent.Value, bool)
- func (m *NoteMutation) AddedFields() []string
- func (m *NoteMutation) AddedIDs(name string) []ent.Value
- func (m *NoteMutation) AttachmentsCleared() bool
- func (m *NoteMutation) AttachmentsIDs() (ids []uuid.UUID)
- func (m *NoteMutation) AuthorCleared() bool
- func (m *NoteMutation) AuthorID() (id uuid.UUID, exists bool)
- func (m *NoteMutation) AuthorIDs() (ids []uuid.UUID)
- func (m *NoteMutation) ClearAttachments()
- func (m *NoteMutation) ClearAuthor()
- func (m *NoteMutation) ClearEdge(name string) error
- func (m *NoteMutation) ClearField(name string) error
- func (m *NoteMutation) ClearMentions()
- func (m *NoteMutation) ClearSubject()
- func (m *NoteMutation) ClearedEdges() []string
- func (m *NoteMutation) ClearedFields() []string
- func (m NoteMutation) Client() *Client
- func (m *NoteMutation) Content() (r string, exists bool)
- func (m *NoteMutation) CreatedAt() (r time.Time, exists bool)
- func (m *NoteMutation) EdgeCleared(name string) bool
- func (m *NoteMutation) Extensions() (r versia.Extensions, exists bool)
- func (m *NoteMutation) Field(name string) (ent.Value, bool)
- func (m *NoteMutation) FieldCleared(name string) bool
- func (m *NoteMutation) Fields() []string
- func (m *NoteMutation) ID() (id uuid.UUID, exists bool)
- func (m *NoteMutation) IDs(ctx context.Context) ([]uuid.UUID, error)
- func (m *NoteMutation) IsRemote() (r bool, exists bool)
- func (m *NoteMutation) IsSensitive() (r bool, exists bool)
- func (m *NoteMutation) MentionsCleared() bool
- func (m *NoteMutation) MentionsIDs() (ids []uuid.UUID)
- func (m *NoteMutation) OldContent(ctx context.Context) (v string, err error)
- func (m *NoteMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)
- func (m *NoteMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
- func (m *NoteMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *NoteMutation) OldIsRemote(ctx context.Context) (v bool, err error)
- func (m *NoteMutation) OldIsSensitive(ctx context.Context) (v bool, err error)
- func (m *NoteMutation) OldSubject(ctx context.Context) (v *string, err error)
- func (m *NoteMutation) OldURI(ctx context.Context) (v string, err error)
- func (m *NoteMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)
- func (m *NoteMutation) OldVisibility(ctx context.Context) (v note.Visibility, err error)
- func (m *NoteMutation) Op() Op
- func (m *NoteMutation) RemoveAttachmentIDs(ids ...uuid.UUID)
- func (m *NoteMutation) RemoveMentionIDs(ids ...uuid.UUID)
- func (m *NoteMutation) RemovedAttachmentsIDs() (ids []uuid.UUID)
- func (m *NoteMutation) RemovedEdges() []string
- func (m *NoteMutation) RemovedIDs(name string) []ent.Value
- func (m *NoteMutation) RemovedMentionsIDs() (ids []uuid.UUID)
- func (m *NoteMutation) ResetAttachments()
- func (m *NoteMutation) ResetAuthor()
- func (m *NoteMutation) ResetContent()
- func (m *NoteMutation) ResetCreatedAt()
- func (m *NoteMutation) ResetEdge(name string) error
- func (m *NoteMutation) ResetExtensions()
- func (m *NoteMutation) ResetField(name string) error
- func (m *NoteMutation) ResetIsRemote()
- func (m *NoteMutation) ResetIsSensitive()
- func (m *NoteMutation) ResetMentions()
- func (m *NoteMutation) ResetSubject()
- func (m *NoteMutation) ResetURI()
- func (m *NoteMutation) ResetUpdatedAt()
- func (m *NoteMutation) ResetVisibility()
- func (m *NoteMutation) SetAuthorID(id uuid.UUID)
- func (m *NoteMutation) SetContent(s string)
- func (m *NoteMutation) SetCreatedAt(t time.Time)
- func (m *NoteMutation) SetExtensions(v versia.Extensions)
- func (m *NoteMutation) SetField(name string, value ent.Value) error
- func (m *NoteMutation) SetID(id uuid.UUID)
- func (m *NoteMutation) SetIsRemote(b bool)
- func (m *NoteMutation) SetIsSensitive(b bool)
- func (m *NoteMutation) SetOp(op Op)
- func (m *NoteMutation) SetSubject(s string)
- func (m *NoteMutation) SetURI(s string)
- func (m *NoteMutation) SetUpdatedAt(t time.Time)
- func (m *NoteMutation) SetVisibility(n note.Visibility)
- func (m *NoteMutation) Subject() (r string, exists bool)
- func (m *NoteMutation) SubjectCleared() bool
- func (m NoteMutation) Tx() (*Tx, error)
- func (m *NoteMutation) Type() string
- func (m *NoteMutation) URI() (r string, exists bool)
- func (m *NoteMutation) UpdatedAt() (r time.Time, exists bool)
- func (m *NoteMutation) Visibility() (r note.Visibility, exists bool)
- func (m *NoteMutation) Where(ps ...predicate.Note)
- func (m *NoteMutation) WhereP(ps ...func(*sql.Selector))
- type NoteQuery
- func (nq *NoteQuery) Aggregate(fns ...AggregateFunc) *NoteSelect
- func (nq *NoteQuery) All(ctx context.Context) ([]*Note, error)
- func (nq *NoteQuery) AllX(ctx context.Context) []*Note
- func (nq *NoteQuery) Clone() *NoteQuery
- func (nq *NoteQuery) Count(ctx context.Context) (int, error)
- func (nq *NoteQuery) CountX(ctx context.Context) int
- func (nq *NoteQuery) Exist(ctx context.Context) (bool, error)
- func (nq *NoteQuery) ExistX(ctx context.Context) bool
- func (nq *NoteQuery) First(ctx context.Context) (*Note, error)
- func (nq *NoteQuery) FirstID(ctx context.Context) (id uuid.UUID, err error)
- func (nq *NoteQuery) FirstIDX(ctx context.Context) uuid.UUID
- func (nq *NoteQuery) FirstX(ctx context.Context) *Note
- func (nq *NoteQuery) GroupBy(field string, fields ...string) *NoteGroupBy
- func (nq *NoteQuery) IDs(ctx context.Context) (ids []uuid.UUID, err error)
- func (nq *NoteQuery) IDsX(ctx context.Context) []uuid.UUID
- func (nq *NoteQuery) Limit(limit int) *NoteQuery
- func (nq *NoteQuery) Offset(offset int) *NoteQuery
- func (nq *NoteQuery) Only(ctx context.Context) (*Note, error)
- func (nq *NoteQuery) OnlyID(ctx context.Context) (id uuid.UUID, err error)
- func (nq *NoteQuery) OnlyIDX(ctx context.Context) uuid.UUID
- func (nq *NoteQuery) OnlyX(ctx context.Context) *Note
- func (nq *NoteQuery) Order(o ...note.OrderOption) *NoteQuery
- func (nq *NoteQuery) QueryAttachments() *AttachmentQuery
- func (nq *NoteQuery) QueryAuthor() *UserQuery
- func (nq *NoteQuery) QueryMentions() *UserQuery
- func (nq *NoteQuery) Select(fields ...string) *NoteSelect
- func (nq *NoteQuery) Unique(unique bool) *NoteQuery
- func (nq *NoteQuery) Where(ps ...predicate.Note) *NoteQuery
- func (nq *NoteQuery) WithAttachments(opts ...func(*AttachmentQuery)) *NoteQuery
- func (nq *NoteQuery) WithAuthor(opts ...func(*UserQuery)) *NoteQuery
- func (nq *NoteQuery) WithMentions(opts ...func(*UserQuery)) *NoteQuery
- type NoteSelect
- func (ns *NoteSelect) Aggregate(fns ...AggregateFunc) *NoteSelect
- func (s *NoteSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *NoteSelect) BoolX(ctx context.Context) bool
- func (s *NoteSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *NoteSelect) BoolsX(ctx context.Context) []bool
- func (s *NoteSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *NoteSelect) Float64X(ctx context.Context) float64
- func (s *NoteSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *NoteSelect) Float64sX(ctx context.Context) []float64
- func (s *NoteSelect) Int(ctx context.Context) (_ int, err error)
- func (s *NoteSelect) IntX(ctx context.Context) int
- func (s *NoteSelect) Ints(ctx context.Context) ([]int, error)
- func (s *NoteSelect) IntsX(ctx context.Context) []int
- func (ns *NoteSelect) Scan(ctx context.Context, v any) error
- func (s *NoteSelect) ScanX(ctx context.Context, v any)
- func (s *NoteSelect) String(ctx context.Context) (_ string, err error)
- func (s *NoteSelect) StringX(ctx context.Context) string
- func (s *NoteSelect) Strings(ctx context.Context) ([]string, error)
- func (s *NoteSelect) StringsX(ctx context.Context) []string
- type NoteUpdate
- func (nu *NoteUpdate) AddAttachmentIDs(ids ...uuid.UUID) *NoteUpdate
- func (nu *NoteUpdate) AddAttachments(a ...*Attachment) *NoteUpdate
- func (nu *NoteUpdate) AddMentionIDs(ids ...uuid.UUID) *NoteUpdate
- func (nu *NoteUpdate) AddMentions(u ...*User) *NoteUpdate
- func (nu *NoteUpdate) ClearAttachments() *NoteUpdate
- func (nu *NoteUpdate) ClearAuthor() *NoteUpdate
- func (nu *NoteUpdate) ClearMentions() *NoteUpdate
- func (nu *NoteUpdate) ClearSubject() *NoteUpdate
- func (nu *NoteUpdate) Exec(ctx context.Context) error
- func (nu *NoteUpdate) ExecX(ctx context.Context)
- func (nu *NoteUpdate) Mutation() *NoteMutation
- func (nu *NoteUpdate) RemoveAttachmentIDs(ids ...uuid.UUID) *NoteUpdate
- func (nu *NoteUpdate) RemoveAttachments(a ...*Attachment) *NoteUpdate
- func (nu *NoteUpdate) RemoveMentionIDs(ids ...uuid.UUID) *NoteUpdate
- func (nu *NoteUpdate) RemoveMentions(u ...*User) *NoteUpdate
- func (nu *NoteUpdate) Save(ctx context.Context) (int, error)
- func (nu *NoteUpdate) SaveX(ctx context.Context) int
- func (nu *NoteUpdate) SetAuthor(u *User) *NoteUpdate
- func (nu *NoteUpdate) SetAuthorID(id uuid.UUID) *NoteUpdate
- func (nu *NoteUpdate) SetContent(s string) *NoteUpdate
- func (nu *NoteUpdate) SetExtensions(v versia.Extensions) *NoteUpdate
- func (nu *NoteUpdate) SetIsRemote(b bool) *NoteUpdate
- func (nu *NoteUpdate) SetIsSensitive(b bool) *NoteUpdate
- func (nu *NoteUpdate) SetNillableContent(s *string) *NoteUpdate
- func (nu *NoteUpdate) SetNillableIsRemote(b *bool) *NoteUpdate
- func (nu *NoteUpdate) SetNillableIsSensitive(b *bool) *NoteUpdate
- func (nu *NoteUpdate) SetNillableSubject(s *string) *NoteUpdate
- func (nu *NoteUpdate) SetNillableURI(s *string) *NoteUpdate
- func (nu *NoteUpdate) SetNillableVisibility(n *note.Visibility) *NoteUpdate
- func (nu *NoteUpdate) SetSubject(s string) *NoteUpdate
- func (nu *NoteUpdate) SetURI(s string) *NoteUpdate
- func (nu *NoteUpdate) SetUpdatedAt(t time.Time) *NoteUpdate
- func (nu *NoteUpdate) SetVisibility(n note.Visibility) *NoteUpdate
- func (nu *NoteUpdate) Where(ps ...predicate.Note) *NoteUpdate
- type NoteUpdateOne
- func (nuo *NoteUpdateOne) AddAttachmentIDs(ids ...uuid.UUID) *NoteUpdateOne
- func (nuo *NoteUpdateOne) AddAttachments(a ...*Attachment) *NoteUpdateOne
- func (nuo *NoteUpdateOne) AddMentionIDs(ids ...uuid.UUID) *NoteUpdateOne
- func (nuo *NoteUpdateOne) AddMentions(u ...*User) *NoteUpdateOne
- func (nuo *NoteUpdateOne) ClearAttachments() *NoteUpdateOne
- func (nuo *NoteUpdateOne) ClearAuthor() *NoteUpdateOne
- func (nuo *NoteUpdateOne) ClearMentions() *NoteUpdateOne
- func (nuo *NoteUpdateOne) ClearSubject() *NoteUpdateOne
- func (nuo *NoteUpdateOne) Exec(ctx context.Context) error
- func (nuo *NoteUpdateOne) ExecX(ctx context.Context)
- func (nuo *NoteUpdateOne) Mutation() *NoteMutation
- func (nuo *NoteUpdateOne) RemoveAttachmentIDs(ids ...uuid.UUID) *NoteUpdateOne
- func (nuo *NoteUpdateOne) RemoveAttachments(a ...*Attachment) *NoteUpdateOne
- func (nuo *NoteUpdateOne) RemoveMentionIDs(ids ...uuid.UUID) *NoteUpdateOne
- func (nuo *NoteUpdateOne) RemoveMentions(u ...*User) *NoteUpdateOne
- func (nuo *NoteUpdateOne) Save(ctx context.Context) (*Note, error)
- func (nuo *NoteUpdateOne) SaveX(ctx context.Context) *Note
- func (nuo *NoteUpdateOne) Select(field string, fields ...string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetAuthor(u *User) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetAuthorID(id uuid.UUID) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetContent(s string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetExtensions(v versia.Extensions) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetIsRemote(b bool) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetIsSensitive(b bool) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetNillableContent(s *string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetNillableIsRemote(b *bool) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetNillableIsSensitive(b *bool) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetNillableSubject(s *string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetNillableURI(s *string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetNillableVisibility(n *note.Visibility) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetSubject(s string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetURI(s string) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetUpdatedAt(t time.Time) *NoteUpdateOne
- func (nuo *NoteUpdateOne) SetVisibility(n note.Visibility) *NoteUpdateOne
- func (nuo *NoteUpdateOne) Where(ps ...predicate.Note) *NoteUpdateOne
- type NoteUpsert
- func (u *NoteUpsert) ClearSubject() *NoteUpsert
- func (u *NoteUpsert) SetContent(v string) *NoteUpsert
- func (u *NoteUpsert) SetExtensions(v versia.Extensions) *NoteUpsert
- func (u *NoteUpsert) SetIsRemote(v bool) *NoteUpsert
- func (u *NoteUpsert) SetIsSensitive(v bool) *NoteUpsert
- func (u *NoteUpsert) SetSubject(v string) *NoteUpsert
- func (u *NoteUpsert) SetURI(v string) *NoteUpsert
- func (u *NoteUpsert) SetUpdatedAt(v time.Time) *NoteUpsert
- func (u *NoteUpsert) SetVisibility(v note.Visibility) *NoteUpsert
- func (u *NoteUpsert) UpdateContent() *NoteUpsert
- func (u *NoteUpsert) UpdateExtensions() *NoteUpsert
- func (u *NoteUpsert) UpdateIsRemote() *NoteUpsert
- func (u *NoteUpsert) UpdateIsSensitive() *NoteUpsert
- func (u *NoteUpsert) UpdateSubject() *NoteUpsert
- func (u *NoteUpsert) UpdateURI() *NoteUpsert
- func (u *NoteUpsert) UpdateUpdatedAt() *NoteUpsert
- func (u *NoteUpsert) UpdateVisibility() *NoteUpsert
- type NoteUpsertBulk
- func (u *NoteUpsertBulk) ClearSubject() *NoteUpsertBulk
- func (u *NoteUpsertBulk) DoNothing() *NoteUpsertBulk
- func (u *NoteUpsertBulk) Exec(ctx context.Context) error
- func (u *NoteUpsertBulk) ExecX(ctx context.Context)
- func (u *NoteUpsertBulk) Ignore() *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetContent(v string) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetExtensions(v versia.Extensions) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetIsRemote(v bool) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetIsSensitive(v bool) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetSubject(v string) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetURI(v string) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetUpdatedAt(v time.Time) *NoteUpsertBulk
- func (u *NoteUpsertBulk) SetVisibility(v note.Visibility) *NoteUpsertBulk
- func (u *NoteUpsertBulk) Update(set func(*NoteUpsert)) *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateContent() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateExtensions() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateIsRemote() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateIsSensitive() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateNewValues() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateSubject() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateURI() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateUpdatedAt() *NoteUpsertBulk
- func (u *NoteUpsertBulk) UpdateVisibility() *NoteUpsertBulk
- type NoteUpsertOne
- func (u *NoteUpsertOne) ClearSubject() *NoteUpsertOne
- func (u *NoteUpsertOne) DoNothing() *NoteUpsertOne
- func (u *NoteUpsertOne) Exec(ctx context.Context) error
- func (u *NoteUpsertOne) ExecX(ctx context.Context)
- func (u *NoteUpsertOne) ID(ctx context.Context) (id uuid.UUID, err error)
- func (u *NoteUpsertOne) IDX(ctx context.Context) uuid.UUID
- func (u *NoteUpsertOne) Ignore() *NoteUpsertOne
- func (u *NoteUpsertOne) SetContent(v string) *NoteUpsertOne
- func (u *NoteUpsertOne) SetExtensions(v versia.Extensions) *NoteUpsertOne
- func (u *NoteUpsertOne) SetIsRemote(v bool) *NoteUpsertOne
- func (u *NoteUpsertOne) SetIsSensitive(v bool) *NoteUpsertOne
- func (u *NoteUpsertOne) SetSubject(v string) *NoteUpsertOne
- func (u *NoteUpsertOne) SetURI(v string) *NoteUpsertOne
- func (u *NoteUpsertOne) SetUpdatedAt(v time.Time) *NoteUpsertOne
- func (u *NoteUpsertOne) SetVisibility(v note.Visibility) *NoteUpsertOne
- func (u *NoteUpsertOne) Update(set func(*NoteUpsert)) *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateContent() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateExtensions() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateIsRemote() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateIsSensitive() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateNewValues() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateSubject() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateURI() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateUpdatedAt() *NoteUpsertOne
- func (u *NoteUpsertOne) UpdateVisibility() *NoteUpsertOne
- type Notes
- type Op
- type Option
- type OrderFunc
- type Policy
- type Querier
- type QuerierFunc
- type Query
- type QueryContext
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type TraverseFunc
- type Traverser
- type Tx
- type User
- func (u *User) QueryAdministeredServers() *InstanceMetadataQuery
- func (u *User) QueryAuthoredNotes() *NoteQuery
- func (u *User) QueryAvatarImage() *ImageQuery
- func (u *User) QueryHeaderImage() *ImageQuery
- func (u *User) QueryMentionedNotes() *NoteQuery
- func (u *User) QueryModeratedServers() *InstanceMetadataQuery
- func (u *User) QueryServers() *InstanceMetadataQuery
- func (u *User) String() string
- func (u *User) Unwrap() *User
- func (u *User) Update() *UserUpdateOne
- func (u *User) Value(name string) (ent.Value, error)
- type UserClient
- func (c *UserClient) Create() *UserCreate
- func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
- func (c *UserClient) Delete() *UserDelete
- func (c *UserClient) DeleteOne(u *User) *UserDeleteOne
- func (c *UserClient) DeleteOneID(id uuid.UUID) *UserDeleteOne
- func (c *UserClient) Get(ctx context.Context, id uuid.UUID) (*User, error)
- func (c *UserClient) GetX(ctx context.Context, id uuid.UUID) *User
- func (c *UserClient) Hooks() []Hook
- func (c *UserClient) Intercept(interceptors ...Interceptor)
- func (c *UserClient) Interceptors() []Interceptor
- func (c *UserClient) MapCreateBulk(slice any, setFunc func(*UserCreate, int)) *UserCreateBulk
- func (c *UserClient) Query() *UserQuery
- func (c *UserClient) QueryAdministeredServers(u *User) *InstanceMetadataQuery
- func (c *UserClient) QueryAuthoredNotes(u *User) *NoteQuery
- func (c *UserClient) QueryAvatarImage(u *User) *ImageQuery
- func (c *UserClient) QueryHeaderImage(u *User) *ImageQuery
- func (c *UserClient) QueryMentionedNotes(u *User) *NoteQuery
- func (c *UserClient) QueryModeratedServers(u *User) *InstanceMetadataQuery
- func (c *UserClient) QueryServers(u *User) *InstanceMetadataQuery
- func (c *UserClient) Update() *UserUpdate
- func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
- func (c *UserClient) UpdateOneID(id uuid.UUID) *UserUpdateOne
- func (c *UserClient) Use(hooks ...Hook)
- type UserCreate
- func (uc *UserCreate) AddAdministeredServerIDs(ids ...uuid.UUID) *UserCreate
- func (uc *UserCreate) AddAdministeredServers(i ...*InstanceMetadata) *UserCreate
- func (uc *UserCreate) AddAuthoredNoteIDs(ids ...uuid.UUID) *UserCreate
- func (uc *UserCreate) AddAuthoredNotes(n ...*Note) *UserCreate
- func (uc *UserCreate) AddMentionedNoteIDs(ids ...uuid.UUID) *UserCreate
- func (uc *UserCreate) AddMentionedNotes(n ...*Note) *UserCreate
- func (uc *UserCreate) AddModeratedServerIDs(ids ...uuid.UUID) *UserCreate
- func (uc *UserCreate) AddModeratedServers(i ...*InstanceMetadata) *UserCreate
- func (uc *UserCreate) AddServerIDs(ids ...uuid.UUID) *UserCreate
- func (uc *UserCreate) AddServers(i ...*InstanceMetadata) *UserCreate
- func (uc *UserCreate) Exec(ctx context.Context) error
- func (uc *UserCreate) ExecX(ctx context.Context)
- func (uc *UserCreate) Mutation() *UserMutation
- func (uc *UserCreate) OnConflict(opts ...sql.ConflictOption) *UserUpsertOne
- func (uc *UserCreate) OnConflictColumns(columns ...string) *UserUpsertOne
- func (uc *UserCreate) Save(ctx context.Context) (*User, error)
- func (uc *UserCreate) SaveX(ctx context.Context) *User
- func (uc *UserCreate) SetAvatarImage(i *Image) *UserCreate
- func (uc *UserCreate) SetAvatarImageID(id int) *UserCreate
- func (uc *UserCreate) SetBiography(s string) *UserCreate
- func (uc *UserCreate) SetCreatedAt(t time.Time) *UserCreate
- func (uc *UserCreate) SetDisplayName(s string) *UserCreate
- func (uc *UserCreate) SetExtensions(v versia.Extensions) *UserCreate
- func (uc *UserCreate) SetFeatured(s string) *UserCreate
- func (uc *UserCreate) SetFields(vf []versia.UserField) *UserCreate
- func (uc *UserCreate) SetFollowers(s string) *UserCreate
- func (uc *UserCreate) SetFollowing(s string) *UserCreate
- func (uc *UserCreate) SetHeaderImage(i *Image) *UserCreate
- func (uc *UserCreate) SetHeaderImageID(id int) *UserCreate
- func (uc *UserCreate) SetID(u uuid.UUID) *UserCreate
- func (uc *UserCreate) SetInbox(s string) *UserCreate
- func (uc *UserCreate) SetIndexable(b bool) *UserCreate
- func (uc *UserCreate) SetIsRemote(b bool) *UserCreate
- func (uc *UserCreate) SetNillableAvatarImageID(id *int) *UserCreate
- func (uc *UserCreate) SetNillableBiography(s *string) *UserCreate
- func (uc *UserCreate) SetNillableCreatedAt(t *time.Time) *UserCreate
- func (uc *UserCreate) SetNillableDisplayName(s *string) *UserCreate
- func (uc *UserCreate) SetNillableHeaderImageID(id *int) *UserCreate
- func (uc *UserCreate) SetNillableID(u *uuid.UUID) *UserCreate
- func (uc *UserCreate) SetNillableIndexable(b *bool) *UserCreate
- func (uc *UserCreate) SetNillablePrivacyLevel(ul *user.PrivacyLevel) *UserCreate
- func (uc *UserCreate) SetNillableUpdatedAt(t *time.Time) *UserCreate
- func (uc *UserCreate) SetOutbox(s string) *UserCreate
- func (uc *UserCreate) SetPasswordHash(b []byte) *UserCreate
- func (uc *UserCreate) SetPrivacyLevel(ul user.PrivacyLevel) *UserCreate
- func (uc *UserCreate) SetPrivateKey(b []byte) *UserCreate
- func (uc *UserCreate) SetPublicKey(b []byte) *UserCreate
- func (uc *UserCreate) SetPublicKeyActor(s string) *UserCreate
- func (uc *UserCreate) SetPublicKeyAlgorithm(s string) *UserCreate
- func (uc *UserCreate) SetURI(s string) *UserCreate
- func (uc *UserCreate) SetUpdatedAt(t time.Time) *UserCreate
- func (uc *UserCreate) SetUsername(s string) *UserCreate
- type UserCreateBulk
- func (ucb *UserCreateBulk) Exec(ctx context.Context) error
- func (ucb *UserCreateBulk) ExecX(ctx context.Context)
- func (ucb *UserCreateBulk) OnConflict(opts ...sql.ConflictOption) *UserUpsertBulk
- func (ucb *UserCreateBulk) OnConflictColumns(columns ...string) *UserUpsertBulk
- func (ucb *UserCreateBulk) Save(ctx context.Context) ([]*User, error)
- func (ucb *UserCreateBulk) SaveX(ctx context.Context) []*User
- type UserDelete
- type UserDeleteOne
- type UserEdges
- func (e UserEdges) AdministeredServersOrErr() ([]*InstanceMetadata, error)
- func (e UserEdges) AuthoredNotesOrErr() ([]*Note, error)
- func (e UserEdges) AvatarImageOrErr() (*Image, error)
- func (e UserEdges) HeaderImageOrErr() (*Image, error)
- func (e UserEdges) MentionedNotesOrErr() ([]*Note, error)
- func (e UserEdges) ModeratedServersOrErr() ([]*InstanceMetadata, error)
- func (e UserEdges) ServersOrErr() ([]*InstanceMetadata, error)
- type UserGroupBy
- func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
- func (s *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *UserGroupBy) BoolX(ctx context.Context) bool
- func (s *UserGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *UserGroupBy) BoolsX(ctx context.Context) []bool
- func (s *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *UserGroupBy) Float64X(ctx context.Context) float64
- func (s *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *UserGroupBy) Float64sX(ctx context.Context) []float64
- func (s *UserGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *UserGroupBy) IntX(ctx context.Context) int
- func (s *UserGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *UserGroupBy) IntsX(ctx context.Context) []int
- func (ugb *UserGroupBy) Scan(ctx context.Context, v any) error
- func (s *UserGroupBy) ScanX(ctx context.Context, v any)
- func (s *UserGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *UserGroupBy) StringX(ctx context.Context) string
- func (s *UserGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *UserGroupBy) StringsX(ctx context.Context) []string
- type UserMutation
- func (m *UserMutation) AddAdministeredServerIDs(ids ...uuid.UUID)
- func (m *UserMutation) AddAuthoredNoteIDs(ids ...uuid.UUID)
- func (m *UserMutation) AddField(name string, value ent.Value) error
- func (m *UserMutation) AddMentionedNoteIDs(ids ...uuid.UUID)
- func (m *UserMutation) AddModeratedServerIDs(ids ...uuid.UUID)
- func (m *UserMutation) AddServerIDs(ids ...uuid.UUID)
- func (m *UserMutation) AddedEdges() []string
- func (m *UserMutation) AddedField(name string) (ent.Value, bool)
- func (m *UserMutation) AddedFields() []string
- func (m *UserMutation) AddedIDs(name string) []ent.Value
- func (m *UserMutation) AdministeredServersCleared() bool
- func (m *UserMutation) AdministeredServersIDs() (ids []uuid.UUID)
- func (m *UserMutation) AppendFields(vf []versia.UserField)
- func (m *UserMutation) AppendedFields() ([]versia.UserField, bool)
- func (m *UserMutation) AuthoredNotesCleared() bool
- func (m *UserMutation) AuthoredNotesIDs() (ids []uuid.UUID)
- func (m *UserMutation) AvatarImageCleared() bool
- func (m *UserMutation) AvatarImageID() (id int, exists bool)
- func (m *UserMutation) AvatarImageIDs() (ids []int)
- func (m *UserMutation) Biography() (r string, exists bool)
- func (m *UserMutation) BiographyCleared() bool
- func (m *UserMutation) ClearAdministeredServers()
- func (m *UserMutation) ClearAuthoredNotes()
- func (m *UserMutation) ClearAvatarImage()
- func (m *UserMutation) ClearBiography()
- func (m *UserMutation) ClearDisplayName()
- func (m *UserMutation) ClearEdge(name string) error
- func (m *UserMutation) ClearField(name string) error
- func (m *UserMutation) ClearHeaderImage()
- func (m *UserMutation) ClearMentionedNotes()
- func (m *UserMutation) ClearModeratedServers()
- func (m *UserMutation) ClearPasswordHash()
- func (m *UserMutation) ClearPrivateKey()
- func (m *UserMutation) ClearServers()
- func (m *UserMutation) ClearedEdges() []string
- func (m *UserMutation) ClearedFields() []string
- func (m UserMutation) Client() *Client
- func (m *UserMutation) CreatedAt() (r time.Time, exists bool)
- func (m *UserMutation) DisplayName() (r string, exists bool)
- func (m *UserMutation) DisplayNameCleared() bool
- func (m *UserMutation) EdgeCleared(name string) bool
- func (m *UserMutation) Extensions() (r versia.Extensions, exists bool)
- func (m *UserMutation) Featured() (r string, exists bool)
- func (m *UserMutation) Field(name string) (ent.Value, bool)
- func (m *UserMutation) FieldCleared(name string) bool
- func (m *UserMutation) Fields() []string
- func (m *UserMutation) Followers() (r string, exists bool)
- func (m *UserMutation) Following() (r string, exists bool)
- func (m *UserMutation) GetFields() (r []versia.UserField, exists bool)
- func (m *UserMutation) HeaderImageCleared() bool
- func (m *UserMutation) HeaderImageID() (id int, exists bool)
- func (m *UserMutation) HeaderImageIDs() (ids []int)
- func (m *UserMutation) ID() (id uuid.UUID, exists bool)
- func (m *UserMutation) IDs(ctx context.Context) ([]uuid.UUID, error)
- func (m *UserMutation) Inbox() (r string, exists bool)
- func (m *UserMutation) Indexable() (r bool, exists bool)
- func (m *UserMutation) IsRemote() (r bool, exists bool)
- func (m *UserMutation) MentionedNotesCleared() bool
- func (m *UserMutation) MentionedNotesIDs() (ids []uuid.UUID)
- func (m *UserMutation) ModeratedServersCleared() bool
- func (m *UserMutation) ModeratedServersIDs() (ids []uuid.UUID)
- func (m *UserMutation) OldBiography(ctx context.Context) (v *string, err error)
- func (m *UserMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)
- func (m *UserMutation) OldDisplayName(ctx context.Context) (v *string, err error)
- func (m *UserMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
- func (m *UserMutation) OldFeatured(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *UserMutation) OldFields(ctx context.Context) (v []versia.UserField, err error)
- func (m *UserMutation) OldFollowers(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldFollowing(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldInbox(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldIndexable(ctx context.Context) (v bool, err error)
- func (m *UserMutation) OldIsRemote(ctx context.Context) (v bool, err error)
- func (m *UserMutation) OldOutbox(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldPasswordHash(ctx context.Context) (v *[]byte, err error)
- func (m *UserMutation) OldPrivacyLevel(ctx context.Context) (v user.PrivacyLevel, err error)
- func (m *UserMutation) OldPrivateKey(ctx context.Context) (v []byte, err error)
- func (m *UserMutation) OldPublicKey(ctx context.Context) (v []byte, err error)
- func (m *UserMutation) OldPublicKeyActor(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldPublicKeyAlgorithm(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldURI(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)
- func (m *UserMutation) OldUsername(ctx context.Context) (v string, err error)
- func (m *UserMutation) Op() Op
- func (m *UserMutation) Outbox() (r string, exists bool)
- func (m *UserMutation) PasswordHash() (r []byte, exists bool)
- func (m *UserMutation) PasswordHashCleared() bool
- func (m *UserMutation) PrivacyLevel() (r user.PrivacyLevel, exists bool)
- func (m *UserMutation) PrivateKey() (r []byte, exists bool)
- func (m *UserMutation) PrivateKeyCleared() bool
- func (m *UserMutation) PublicKey() (r []byte, exists bool)
- func (m *UserMutation) PublicKeyActor() (r string, exists bool)
- func (m *UserMutation) PublicKeyAlgorithm() (r string, exists bool)
- func (m *UserMutation) RemoveAdministeredServerIDs(ids ...uuid.UUID)
- func (m *UserMutation) RemoveAuthoredNoteIDs(ids ...uuid.UUID)
- func (m *UserMutation) RemoveMentionedNoteIDs(ids ...uuid.UUID)
- func (m *UserMutation) RemoveModeratedServerIDs(ids ...uuid.UUID)
- func (m *UserMutation) RemoveServerIDs(ids ...uuid.UUID)
- func (m *UserMutation) RemovedAdministeredServersIDs() (ids []uuid.UUID)
- func (m *UserMutation) RemovedAuthoredNotesIDs() (ids []uuid.UUID)
- func (m *UserMutation) RemovedEdges() []string
- func (m *UserMutation) RemovedIDs(name string) []ent.Value
- func (m *UserMutation) RemovedMentionedNotesIDs() (ids []uuid.UUID)
- func (m *UserMutation) RemovedModeratedServersIDs() (ids []uuid.UUID)
- func (m *UserMutation) RemovedServersIDs() (ids []uuid.UUID)
- func (m *UserMutation) ResetAdministeredServers()
- func (m *UserMutation) ResetAuthoredNotes()
- func (m *UserMutation) ResetAvatarImage()
- func (m *UserMutation) ResetBiography()
- func (m *UserMutation) ResetCreatedAt()
- func (m *UserMutation) ResetDisplayName()
- func (m *UserMutation) ResetEdge(name string) error
- func (m *UserMutation) ResetExtensions()
- func (m *UserMutation) ResetFeatured()
- func (m *UserMutation) ResetField(name string) error
- func (m *UserMutation) ResetFields()
- func (m *UserMutation) ResetFollowers()
- func (m *UserMutation) ResetFollowing()
- func (m *UserMutation) ResetHeaderImage()
- func (m *UserMutation) ResetInbox()
- func (m *UserMutation) ResetIndexable()
- func (m *UserMutation) ResetIsRemote()
- func (m *UserMutation) ResetMentionedNotes()
- func (m *UserMutation) ResetModeratedServers()
- func (m *UserMutation) ResetOutbox()
- func (m *UserMutation) ResetPasswordHash()
- func (m *UserMutation) ResetPrivacyLevel()
- func (m *UserMutation) ResetPrivateKey()
- func (m *UserMutation) ResetPublicKey()
- func (m *UserMutation) ResetPublicKeyActor()
- func (m *UserMutation) ResetPublicKeyAlgorithm()
- func (m *UserMutation) ResetServers()
- func (m *UserMutation) ResetURI()
- func (m *UserMutation) ResetUpdatedAt()
- func (m *UserMutation) ResetUsername()
- func (m *UserMutation) ServersCleared() bool
- func (m *UserMutation) ServersIDs() (ids []uuid.UUID)
- func (m *UserMutation) SetAvatarImageID(id int)
- func (m *UserMutation) SetBiography(s string)
- func (m *UserMutation) SetCreatedAt(t time.Time)
- func (m *UserMutation) SetDisplayName(s string)
- func (m *UserMutation) SetExtensions(v versia.Extensions)
- func (m *UserMutation) SetFeatured(s string)
- func (m *UserMutation) SetField(name string, value ent.Value) error
- func (m *UserMutation) SetFields(vf []versia.UserField)
- func (m *UserMutation) SetFollowers(s string)
- func (m *UserMutation) SetFollowing(s string)
- func (m *UserMutation) SetHeaderImageID(id int)
- func (m *UserMutation) SetID(id uuid.UUID)
- func (m *UserMutation) SetInbox(s string)
- func (m *UserMutation) SetIndexable(b bool)
- func (m *UserMutation) SetIsRemote(b bool)
- func (m *UserMutation) SetOp(op Op)
- func (m *UserMutation) SetOutbox(s string)
- func (m *UserMutation) SetPasswordHash(b []byte)
- func (m *UserMutation) SetPrivacyLevel(ul user.PrivacyLevel)
- func (m *UserMutation) SetPrivateKey(b []byte)
- func (m *UserMutation) SetPublicKey(b []byte)
- func (m *UserMutation) SetPublicKeyActor(s string)
- func (m *UserMutation) SetPublicKeyAlgorithm(s string)
- func (m *UserMutation) SetURI(s string)
- func (m *UserMutation) SetUpdatedAt(t time.Time)
- func (m *UserMutation) SetUsername(s string)
- func (m UserMutation) Tx() (*Tx, error)
- func (m *UserMutation) Type() string
- func (m *UserMutation) URI() (r string, exists bool)
- func (m *UserMutation) UpdatedAt() (r time.Time, exists bool)
- func (m *UserMutation) Username() (r string, exists bool)
- func (m *UserMutation) Where(ps ...predicate.User)
- func (m *UserMutation) WhereP(ps ...func(*sql.Selector))
- type UserQuery
- func (uq *UserQuery) Aggregate(fns ...AggregateFunc) *UserSelect
- func (uq *UserQuery) All(ctx context.Context) ([]*User, error)
- func (uq *UserQuery) AllX(ctx context.Context) []*User
- func (uq *UserQuery) Clone() *UserQuery
- func (uq *UserQuery) Count(ctx context.Context) (int, error)
- func (uq *UserQuery) CountX(ctx context.Context) int
- func (uq *UserQuery) Exist(ctx context.Context) (bool, error)
- func (uq *UserQuery) ExistX(ctx context.Context) bool
- func (uq *UserQuery) First(ctx context.Context) (*User, error)
- func (uq *UserQuery) FirstID(ctx context.Context) (id uuid.UUID, err error)
- func (uq *UserQuery) FirstIDX(ctx context.Context) uuid.UUID
- func (uq *UserQuery) FirstX(ctx context.Context) *User
- func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
- func (uq *UserQuery) IDs(ctx context.Context) (ids []uuid.UUID, err error)
- func (uq *UserQuery) IDsX(ctx context.Context) []uuid.UUID
- func (uq *UserQuery) Limit(limit int) *UserQuery
- func (uq *UserQuery) Offset(offset int) *UserQuery
- func (uq *UserQuery) Only(ctx context.Context) (*User, error)
- func (uq *UserQuery) OnlyID(ctx context.Context) (id uuid.UUID, err error)
- func (uq *UserQuery) OnlyIDX(ctx context.Context) uuid.UUID
- func (uq *UserQuery) OnlyX(ctx context.Context) *User
- func (uq *UserQuery) Order(o ...user.OrderOption) *UserQuery
- func (uq *UserQuery) QueryAdministeredServers() *InstanceMetadataQuery
- func (uq *UserQuery) QueryAuthoredNotes() *NoteQuery
- func (uq *UserQuery) QueryAvatarImage() *ImageQuery
- func (uq *UserQuery) QueryHeaderImage() *ImageQuery
- func (uq *UserQuery) QueryMentionedNotes() *NoteQuery
- func (uq *UserQuery) QueryModeratedServers() *InstanceMetadataQuery
- func (uq *UserQuery) QueryServers() *InstanceMetadataQuery
- func (uq *UserQuery) Select(fields ...string) *UserSelect
- func (uq *UserQuery) Unique(unique bool) *UserQuery
- func (uq *UserQuery) Where(ps ...predicate.User) *UserQuery
- func (uq *UserQuery) WithAdministeredServers(opts ...func(*InstanceMetadataQuery)) *UserQuery
- func (uq *UserQuery) WithAuthoredNotes(opts ...func(*NoteQuery)) *UserQuery
- func (uq *UserQuery) WithAvatarImage(opts ...func(*ImageQuery)) *UserQuery
- func (uq *UserQuery) WithHeaderImage(opts ...func(*ImageQuery)) *UserQuery
- func (uq *UserQuery) WithMentionedNotes(opts ...func(*NoteQuery)) *UserQuery
- func (uq *UserQuery) WithModeratedServers(opts ...func(*InstanceMetadataQuery)) *UserQuery
- func (uq *UserQuery) WithServers(opts ...func(*InstanceMetadataQuery)) *UserQuery
- type UserSelect
- func (us *UserSelect) Aggregate(fns ...AggregateFunc) *UserSelect
- func (s *UserSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *UserSelect) BoolX(ctx context.Context) bool
- func (s *UserSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *UserSelect) BoolsX(ctx context.Context) []bool
- func (s *UserSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *UserSelect) Float64X(ctx context.Context) float64
- func (s *UserSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *UserSelect) Float64sX(ctx context.Context) []float64
- func (s *UserSelect) Int(ctx context.Context) (_ int, err error)
- func (s *UserSelect) IntX(ctx context.Context) int
- func (s *UserSelect) Ints(ctx context.Context) ([]int, error)
- func (s *UserSelect) IntsX(ctx context.Context) []int
- func (us *UserSelect) Scan(ctx context.Context, v any) error
- func (s *UserSelect) ScanX(ctx context.Context, v any)
- func (s *UserSelect) String(ctx context.Context) (_ string, err error)
- func (s *UserSelect) StringX(ctx context.Context) string
- func (s *UserSelect) Strings(ctx context.Context) ([]string, error)
- func (s *UserSelect) StringsX(ctx context.Context) []string
- type UserUpdate
- func (uu *UserUpdate) AddAdministeredServerIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) AddAdministeredServers(i ...*InstanceMetadata) *UserUpdate
- func (uu *UserUpdate) AddAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) AddAuthoredNotes(n ...*Note) *UserUpdate
- func (uu *UserUpdate) AddMentionedNoteIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) AddMentionedNotes(n ...*Note) *UserUpdate
- func (uu *UserUpdate) AddModeratedServerIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) AddModeratedServers(i ...*InstanceMetadata) *UserUpdate
- func (uu *UserUpdate) AddServerIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) AddServers(i ...*InstanceMetadata) *UserUpdate
- func (uu *UserUpdate) AppendFields(vf []versia.UserField) *UserUpdate
- func (uu *UserUpdate) ClearAdministeredServers() *UserUpdate
- func (uu *UserUpdate) ClearAuthoredNotes() *UserUpdate
- func (uu *UserUpdate) ClearAvatarImage() *UserUpdate
- func (uu *UserUpdate) ClearBiography() *UserUpdate
- func (uu *UserUpdate) ClearDisplayName() *UserUpdate
- func (uu *UserUpdate) ClearHeaderImage() *UserUpdate
- func (uu *UserUpdate) ClearMentionedNotes() *UserUpdate
- func (uu *UserUpdate) ClearModeratedServers() *UserUpdate
- func (uu *UserUpdate) ClearPasswordHash() *UserUpdate
- func (uu *UserUpdate) ClearPrivateKey() *UserUpdate
- func (uu *UserUpdate) ClearServers() *UserUpdate
- func (uu *UserUpdate) Exec(ctx context.Context) error
- func (uu *UserUpdate) ExecX(ctx context.Context)
- func (uu *UserUpdate) Mutation() *UserMutation
- func (uu *UserUpdate) RemoveAdministeredServerIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) RemoveAdministeredServers(i ...*InstanceMetadata) *UserUpdate
- func (uu *UserUpdate) RemoveAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) RemoveAuthoredNotes(n ...*Note) *UserUpdate
- func (uu *UserUpdate) RemoveMentionedNoteIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) RemoveMentionedNotes(n ...*Note) *UserUpdate
- func (uu *UserUpdate) RemoveModeratedServerIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) RemoveModeratedServers(i ...*InstanceMetadata) *UserUpdate
- func (uu *UserUpdate) RemoveServerIDs(ids ...uuid.UUID) *UserUpdate
- func (uu *UserUpdate) RemoveServers(i ...*InstanceMetadata) *UserUpdate
- func (uu *UserUpdate) Save(ctx context.Context) (int, error)
- func (uu *UserUpdate) SaveX(ctx context.Context) int
- func (uu *UserUpdate) SetAvatarImage(i *Image) *UserUpdate
- func (uu *UserUpdate) SetAvatarImageID(id int) *UserUpdate
- func (uu *UserUpdate) SetBiography(s string) *UserUpdate
- func (uu *UserUpdate) SetDisplayName(s string) *UserUpdate
- func (uu *UserUpdate) SetExtensions(v versia.Extensions) *UserUpdate
- func (uu *UserUpdate) SetFeatured(s string) *UserUpdate
- func (uu *UserUpdate) SetFields(vf []versia.UserField) *UserUpdate
- func (uu *UserUpdate) SetFollowers(s string) *UserUpdate
- func (uu *UserUpdate) SetFollowing(s string) *UserUpdate
- func (uu *UserUpdate) SetHeaderImage(i *Image) *UserUpdate
- func (uu *UserUpdate) SetHeaderImageID(id int) *UserUpdate
- func (uu *UserUpdate) SetInbox(s string) *UserUpdate
- func (uu *UserUpdate) SetIndexable(b bool) *UserUpdate
- func (uu *UserUpdate) SetIsRemote(b bool) *UserUpdate
- func (uu *UserUpdate) SetNillableAvatarImageID(id *int) *UserUpdate
- func (uu *UserUpdate) SetNillableBiography(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableDisplayName(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableFeatured(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableFollowers(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableFollowing(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableHeaderImageID(id *int) *UserUpdate
- func (uu *UserUpdate) SetNillableInbox(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableIndexable(b *bool) *UserUpdate
- func (uu *UserUpdate) SetNillableIsRemote(b *bool) *UserUpdate
- func (uu *UserUpdate) SetNillableOutbox(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillablePrivacyLevel(ul *user.PrivacyLevel) *UserUpdate
- func (uu *UserUpdate) SetNillablePublicKeyActor(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillablePublicKeyAlgorithm(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableURI(s *string) *UserUpdate
- func (uu *UserUpdate) SetNillableUsername(s *string) *UserUpdate
- func (uu *UserUpdate) SetOutbox(s string) *UserUpdate
- func (uu *UserUpdate) SetPasswordHash(b []byte) *UserUpdate
- func (uu *UserUpdate) SetPrivacyLevel(ul user.PrivacyLevel) *UserUpdate
- func (uu *UserUpdate) SetPrivateKey(b []byte) *UserUpdate
- func (uu *UserUpdate) SetPublicKey(b []byte) *UserUpdate
- func (uu *UserUpdate) SetPublicKeyActor(s string) *UserUpdate
- func (uu *UserUpdate) SetPublicKeyAlgorithm(s string) *UserUpdate
- func (uu *UserUpdate) SetURI(s string) *UserUpdate
- func (uu *UserUpdate) SetUpdatedAt(t time.Time) *UserUpdate
- func (uu *UserUpdate) SetUsername(s string) *UserUpdate
- func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
- type UserUpdateOne
- func (uuo *UserUpdateOne) AddAdministeredServerIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) AddAdministeredServers(i ...*InstanceMetadata) *UserUpdateOne
- func (uuo *UserUpdateOne) AddAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) AddAuthoredNotes(n ...*Note) *UserUpdateOne
- func (uuo *UserUpdateOne) AddMentionedNoteIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) AddMentionedNotes(n ...*Note) *UserUpdateOne
- func (uuo *UserUpdateOne) AddModeratedServerIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) AddModeratedServers(i ...*InstanceMetadata) *UserUpdateOne
- func (uuo *UserUpdateOne) AddServerIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) AddServers(i ...*InstanceMetadata) *UserUpdateOne
- func (uuo *UserUpdateOne) AppendFields(vf []versia.UserField) *UserUpdateOne
- func (uuo *UserUpdateOne) ClearAdministeredServers() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearAuthoredNotes() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearAvatarImage() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearBiography() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearDisplayName() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearHeaderImage() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearMentionedNotes() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearModeratedServers() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearPasswordHash() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearPrivateKey() *UserUpdateOne
- func (uuo *UserUpdateOne) ClearServers() *UserUpdateOne
- func (uuo *UserUpdateOne) Exec(ctx context.Context) error
- func (uuo *UserUpdateOne) ExecX(ctx context.Context)
- func (uuo *UserUpdateOne) Mutation() *UserMutation
- func (uuo *UserUpdateOne) RemoveAdministeredServerIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveAdministeredServers(i ...*InstanceMetadata) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveAuthoredNotes(n ...*Note) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveMentionedNoteIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveMentionedNotes(n ...*Note) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveModeratedServerIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveModeratedServers(i ...*InstanceMetadata) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveServerIDs(ids ...uuid.UUID) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveServers(i ...*InstanceMetadata) *UserUpdateOne
- func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
- func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
- func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetAvatarImage(i *Image) *UserUpdateOne
- func (uuo *UserUpdateOne) SetAvatarImageID(id int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetBiography(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetDisplayName(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetExtensions(v versia.Extensions) *UserUpdateOne
- func (uuo *UserUpdateOne) SetFeatured(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetFields(vf []versia.UserField) *UserUpdateOne
- func (uuo *UserUpdateOne) SetFollowers(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetFollowing(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetHeaderImage(i *Image) *UserUpdateOne
- func (uuo *UserUpdateOne) SetHeaderImageID(id int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetInbox(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetIndexable(b bool) *UserUpdateOne
- func (uuo *UserUpdateOne) SetIsRemote(b bool) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableAvatarImageID(id *int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableBiography(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableDisplayName(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableFeatured(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableFollowers(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableFollowing(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableHeaderImageID(id *int) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableInbox(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableIndexable(b *bool) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableIsRemote(b *bool) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableOutbox(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillablePrivacyLevel(ul *user.PrivacyLevel) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillablePublicKeyActor(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillablePublicKeyAlgorithm(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableURI(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetNillableUsername(s *string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetOutbox(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPasswordHash(b []byte) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPrivacyLevel(ul user.PrivacyLevel) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPrivateKey(b []byte) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPublicKey(b []byte) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPublicKeyActor(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetPublicKeyAlgorithm(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetURI(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetUpdatedAt(t time.Time) *UserUpdateOne
- func (uuo *UserUpdateOne) SetUsername(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) Where(ps ...predicate.User) *UserUpdateOne
- type UserUpsert
- func (u *UserUpsert) ClearBiography() *UserUpsert
- func (u *UserUpsert) ClearDisplayName() *UserUpsert
- func (u *UserUpsert) ClearPasswordHash() *UserUpsert
- func (u *UserUpsert) ClearPrivateKey() *UserUpsert
- func (u *UserUpsert) SetBiography(v string) *UserUpsert
- func (u *UserUpsert) SetDisplayName(v string) *UserUpsert
- func (u *UserUpsert) SetExtensions(v versia.Extensions) *UserUpsert
- func (u *UserUpsert) SetFeatured(v string) *UserUpsert
- func (u *UserUpsert) SetFields(v []versia.UserField) *UserUpsert
- func (u *UserUpsert) SetFollowers(v string) *UserUpsert
- func (u *UserUpsert) SetFollowing(v string) *UserUpsert
- func (u *UserUpsert) SetInbox(v string) *UserUpsert
- func (u *UserUpsert) SetIndexable(v bool) *UserUpsert
- func (u *UserUpsert) SetIsRemote(v bool) *UserUpsert
- func (u *UserUpsert) SetOutbox(v string) *UserUpsert
- func (u *UserUpsert) SetPasswordHash(v []byte) *UserUpsert
- func (u *UserUpsert) SetPrivacyLevel(v user.PrivacyLevel) *UserUpsert
- func (u *UserUpsert) SetPrivateKey(v []byte) *UserUpsert
- func (u *UserUpsert) SetPublicKey(v []byte) *UserUpsert
- func (u *UserUpsert) SetPublicKeyActor(v string) *UserUpsert
- func (u *UserUpsert) SetPublicKeyAlgorithm(v string) *UserUpsert
- func (u *UserUpsert) SetURI(v string) *UserUpsert
- func (u *UserUpsert) SetUpdatedAt(v time.Time) *UserUpsert
- func (u *UserUpsert) SetUsername(v string) *UserUpsert
- func (u *UserUpsert) UpdateBiography() *UserUpsert
- func (u *UserUpsert) UpdateDisplayName() *UserUpsert
- func (u *UserUpsert) UpdateExtensions() *UserUpsert
- func (u *UserUpsert) UpdateFeatured() *UserUpsert
- func (u *UserUpsert) UpdateFields() *UserUpsert
- func (u *UserUpsert) UpdateFollowers() *UserUpsert
- func (u *UserUpsert) UpdateFollowing() *UserUpsert
- func (u *UserUpsert) UpdateInbox() *UserUpsert
- func (u *UserUpsert) UpdateIndexable() *UserUpsert
- func (u *UserUpsert) UpdateIsRemote() *UserUpsert
- func (u *UserUpsert) UpdateOutbox() *UserUpsert
- func (u *UserUpsert) UpdatePasswordHash() *UserUpsert
- func (u *UserUpsert) UpdatePrivacyLevel() *UserUpsert
- func (u *UserUpsert) UpdatePrivateKey() *UserUpsert
- func (u *UserUpsert) UpdatePublicKey() *UserUpsert
- func (u *UserUpsert) UpdatePublicKeyActor() *UserUpsert
- func (u *UserUpsert) UpdatePublicKeyAlgorithm() *UserUpsert
- func (u *UserUpsert) UpdateURI() *UserUpsert
- func (u *UserUpsert) UpdateUpdatedAt() *UserUpsert
- func (u *UserUpsert) UpdateUsername() *UserUpsert
- type UserUpsertBulk
- func (u *UserUpsertBulk) ClearBiography() *UserUpsertBulk
- func (u *UserUpsertBulk) ClearDisplayName() *UserUpsertBulk
- func (u *UserUpsertBulk) ClearPasswordHash() *UserUpsertBulk
- func (u *UserUpsertBulk) ClearPrivateKey() *UserUpsertBulk
- func (u *UserUpsertBulk) DoNothing() *UserUpsertBulk
- func (u *UserUpsertBulk) Exec(ctx context.Context) error
- func (u *UserUpsertBulk) ExecX(ctx context.Context)
- func (u *UserUpsertBulk) Ignore() *UserUpsertBulk
- func (u *UserUpsertBulk) SetBiography(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetDisplayName(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetExtensions(v versia.Extensions) *UserUpsertBulk
- func (u *UserUpsertBulk) SetFeatured(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetFields(v []versia.UserField) *UserUpsertBulk
- func (u *UserUpsertBulk) SetFollowers(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetFollowing(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetInbox(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetIndexable(v bool) *UserUpsertBulk
- func (u *UserUpsertBulk) SetIsRemote(v bool) *UserUpsertBulk
- func (u *UserUpsertBulk) SetOutbox(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetPasswordHash(v []byte) *UserUpsertBulk
- func (u *UserUpsertBulk) SetPrivacyLevel(v user.PrivacyLevel) *UserUpsertBulk
- func (u *UserUpsertBulk) SetPrivateKey(v []byte) *UserUpsertBulk
- func (u *UserUpsertBulk) SetPublicKey(v []byte) *UserUpsertBulk
- func (u *UserUpsertBulk) SetPublicKeyActor(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetPublicKeyAlgorithm(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetURI(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetUpdatedAt(v time.Time) *UserUpsertBulk
- func (u *UserUpsertBulk) SetUsername(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) Update(set func(*UserUpsert)) *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateBiography() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateDisplayName() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateExtensions() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateFeatured() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateFields() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateFollowers() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateFollowing() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateInbox() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateIndexable() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateIsRemote() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateNewValues() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateOutbox() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdatePasswordHash() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdatePrivacyLevel() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdatePrivateKey() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdatePublicKey() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdatePublicKeyActor() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdatePublicKeyAlgorithm() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateURI() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateUpdatedAt() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateUsername() *UserUpsertBulk
- type UserUpsertOne
- func (u *UserUpsertOne) ClearBiography() *UserUpsertOne
- func (u *UserUpsertOne) ClearDisplayName() *UserUpsertOne
- func (u *UserUpsertOne) ClearPasswordHash() *UserUpsertOne
- func (u *UserUpsertOne) ClearPrivateKey() *UserUpsertOne
- func (u *UserUpsertOne) DoNothing() *UserUpsertOne
- func (u *UserUpsertOne) Exec(ctx context.Context) error
- func (u *UserUpsertOne) ExecX(ctx context.Context)
- func (u *UserUpsertOne) ID(ctx context.Context) (id uuid.UUID, err error)
- func (u *UserUpsertOne) IDX(ctx context.Context) uuid.UUID
- func (u *UserUpsertOne) Ignore() *UserUpsertOne
- func (u *UserUpsertOne) SetBiography(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetDisplayName(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetExtensions(v versia.Extensions) *UserUpsertOne
- func (u *UserUpsertOne) SetFeatured(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetFields(v []versia.UserField) *UserUpsertOne
- func (u *UserUpsertOne) SetFollowers(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetFollowing(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetInbox(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetIndexable(v bool) *UserUpsertOne
- func (u *UserUpsertOne) SetIsRemote(v bool) *UserUpsertOne
- func (u *UserUpsertOne) SetOutbox(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetPasswordHash(v []byte) *UserUpsertOne
- func (u *UserUpsertOne) SetPrivacyLevel(v user.PrivacyLevel) *UserUpsertOne
- func (u *UserUpsertOne) SetPrivateKey(v []byte) *UserUpsertOne
- func (u *UserUpsertOne) SetPublicKey(v []byte) *UserUpsertOne
- func (u *UserUpsertOne) SetPublicKeyActor(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetPublicKeyAlgorithm(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetURI(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetUpdatedAt(v time.Time) *UserUpsertOne
- func (u *UserUpsertOne) SetUsername(v string) *UserUpsertOne
- func (u *UserUpsertOne) Update(set func(*UserUpsert)) *UserUpsertOne
- func (u *UserUpsertOne) UpdateBiography() *UserUpsertOne
- func (u *UserUpsertOne) UpdateDisplayName() *UserUpsertOne
- func (u *UserUpsertOne) UpdateExtensions() *UserUpsertOne
- func (u *UserUpsertOne) UpdateFeatured() *UserUpsertOne
- func (u *UserUpsertOne) UpdateFields() *UserUpsertOne
- func (u *UserUpsertOne) UpdateFollowers() *UserUpsertOne
- func (u *UserUpsertOne) UpdateFollowing() *UserUpsertOne
- func (u *UserUpsertOne) UpdateInbox() *UserUpsertOne
- func (u *UserUpsertOne) UpdateIndexable() *UserUpsertOne
- func (u *UserUpsertOne) UpdateIsRemote() *UserUpsertOne
- func (u *UserUpsertOne) UpdateNewValues() *UserUpsertOne
- func (u *UserUpsertOne) UpdateOutbox() *UserUpsertOne
- func (u *UserUpsertOne) UpdatePasswordHash() *UserUpsertOne
- func (u *UserUpsertOne) UpdatePrivacyLevel() *UserUpsertOne
- func (u *UserUpsertOne) UpdatePrivateKey() *UserUpsertOne
- func (u *UserUpsertOne) UpdatePublicKey() *UserUpsertOne
- func (u *UserUpsertOne) UpdatePublicKeyActor() *UserUpsertOne
- func (u *UserUpsertOne) UpdatePublicKeyAlgorithm() *UserUpsertOne
- func (u *UserUpsertOne) UpdateURI() *UserUpsertOne
- func (u *UserUpsertOne) UpdateUpdatedAt() *UserUpsertOne
- func (u *UserUpsertOne) UpdateUsername() *UserUpsertOne
- type Users
- type ValidationError
- type Value
Constants ¶
const ( // Operation types. OpCreate = ent.OpCreate OpDelete = ent.OpDelete OpDeleteOne = ent.OpDeleteOne OpUpdate = ent.OpUpdate OpUpdateOne = ent.OpUpdateOne // Node types. TypeAttachment = "Attachment" TypeFollow = "Follow" TypeImage = "Image" TypeInstanceMetadata = "InstanceMetadata" TypeNote = "Note" TypeUser = "User" )
Variables ¶
var ErrTxStarted = errors.New("ent: cannot start a transaction within a transaction")
ErrTxStarted is returned when trying to start a new transaction from a transactional client.
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 Attachment ¶
type Attachment struct { // ID of the ent. ID uuid.UUID `json:"id,omitempty"` // IsRemote holds the value of the "isRemote" field. IsRemote bool `json:"isRemote,omitempty"` // URI holds the value of the "uri" field. URI string `json:"uri,omitempty"` // Extensions holds the value of the "extensions" field. Extensions versia.Extensions `json:"extensions,omitempty"` // CreatedAt holds the value of the "created_at" field. CreatedAt time.Time `json:"created_at,omitempty"` // UpdatedAt holds the value of the "updated_at" field. UpdatedAt time.Time `json:"updated_at,omitempty"` // Description holds the value of the "description" field. Description string `json:"description,omitempty"` // Sha256 holds the value of the "sha256" field. Sha256 []byte `json:"sha256,omitempty"` // Size holds the value of the "size" field. Size int `json:"size,omitempty"` // Blurhash holds the value of the "blurhash" field. Blurhash *string `json:"blurhash,omitempty"` // Height holds the value of the "height" field. Height *int `json:"height,omitempty"` // Width holds the value of the "width" field. Width *int `json:"width,omitempty"` // Fps holds the value of the "fps" field. Fps *int `json:"fps,omitempty"` // MimeType holds the value of the "mimeType" field. MimeType string `json:"mimeType,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the AttachmentQuery when eager-loading is set. Edges AttachmentEdges `json:"edges"` // contains filtered or unexported fields }
Attachment is the model entity for the Attachment schema.
func (*Attachment) QueryAuthor ¶
func (a *Attachment) QueryAuthor() *UserQuery
QueryAuthor queries the "author" edge of the Attachment entity.
func (*Attachment) String ¶
func (a *Attachment) String() string
String implements the fmt.Stringer.
func (*Attachment) Unwrap ¶
func (a *Attachment) Unwrap() *Attachment
Unwrap unwraps the Attachment 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 (*Attachment) Update ¶
func (a *Attachment) Update() *AttachmentUpdateOne
Update returns a builder for updating this Attachment. Note that you need to call Attachment.Unwrap() before calling this method if this Attachment was returned from a transaction, and the transaction was committed or rolled back.
type AttachmentClient ¶
type AttachmentClient struct {
// contains filtered or unexported fields
}
AttachmentClient is a client for the Attachment schema.
func NewAttachmentClient ¶
func NewAttachmentClient(c config) *AttachmentClient
NewAttachmentClient returns a client for the Attachment from the given config.
func (*AttachmentClient) Create ¶
func (c *AttachmentClient) Create() *AttachmentCreate
Create returns a builder for creating a Attachment entity.
func (*AttachmentClient) CreateBulk ¶
func (c *AttachmentClient) CreateBulk(builders ...*AttachmentCreate) *AttachmentCreateBulk
CreateBulk returns a builder for creating a bulk of Attachment entities.
func (*AttachmentClient) Delete ¶
func (c *AttachmentClient) Delete() *AttachmentDelete
Delete returns a delete builder for Attachment.
func (*AttachmentClient) DeleteOne ¶
func (c *AttachmentClient) DeleteOne(a *Attachment) *AttachmentDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*AttachmentClient) DeleteOneID ¶
func (c *AttachmentClient) DeleteOneID(id uuid.UUID) *AttachmentDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*AttachmentClient) Get ¶
func (c *AttachmentClient) Get(ctx context.Context, id uuid.UUID) (*Attachment, error)
Get returns a Attachment entity by its id.
func (*AttachmentClient) GetX ¶
func (c *AttachmentClient) GetX(ctx context.Context, id uuid.UUID) *Attachment
GetX is like Get, but panics if an error occurs.
func (*AttachmentClient) Hooks ¶
func (c *AttachmentClient) Hooks() []Hook
Hooks returns the client hooks.
func (*AttachmentClient) Intercept ¶
func (c *AttachmentClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `attachment.Intercept(f(g(h())))`.
func (*AttachmentClient) Interceptors ¶
func (c *AttachmentClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*AttachmentClient) MapCreateBulk ¶
func (c *AttachmentClient) MapCreateBulk(slice any, setFunc func(*AttachmentCreate, int)) *AttachmentCreateBulk
MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.
func (*AttachmentClient) Query ¶
func (c *AttachmentClient) Query() *AttachmentQuery
Query returns a query builder for Attachment.
func (*AttachmentClient) QueryAuthor ¶
func (c *AttachmentClient) QueryAuthor(a *Attachment) *UserQuery
QueryAuthor queries the author edge of a Attachment.
func (*AttachmentClient) Update ¶
func (c *AttachmentClient) Update() *AttachmentUpdate
Update returns an update builder for Attachment.
func (*AttachmentClient) UpdateOne ¶
func (c *AttachmentClient) UpdateOne(a *Attachment) *AttachmentUpdateOne
UpdateOne returns an update builder for the given entity.
func (*AttachmentClient) UpdateOneID ¶
func (c *AttachmentClient) UpdateOneID(id uuid.UUID) *AttachmentUpdateOne
UpdateOneID returns an update builder for the given id.
func (*AttachmentClient) Use ¶
func (c *AttachmentClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `attachment.Hooks(f(g(h())))`.
type AttachmentCreate ¶
type AttachmentCreate struct {
// contains filtered or unexported fields
}
AttachmentCreate is the builder for creating a Attachment entity.
func (*AttachmentCreate) Exec ¶
func (ac *AttachmentCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*AttachmentCreate) ExecX ¶
func (ac *AttachmentCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentCreate) Mutation ¶
func (ac *AttachmentCreate) Mutation() *AttachmentMutation
Mutation returns the AttachmentMutation object of the builder.
func (*AttachmentCreate) OnConflict ¶
func (ac *AttachmentCreate) OnConflict(opts ...sql.ConflictOption) *AttachmentUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Attachment.Create(). SetIsRemote(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.AttachmentUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*AttachmentCreate) OnConflictColumns ¶
func (ac *AttachmentCreate) OnConflictColumns(columns ...string) *AttachmentUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Attachment.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*AttachmentCreate) Save ¶
func (ac *AttachmentCreate) Save(ctx context.Context) (*Attachment, error)
Save creates the Attachment in the database.
func (*AttachmentCreate) SaveX ¶
func (ac *AttachmentCreate) SaveX(ctx context.Context) *Attachment
SaveX calls Save and panics if Save returns an error.
func (*AttachmentCreate) SetAuthor ¶
func (ac *AttachmentCreate) SetAuthor(u *User) *AttachmentCreate
SetAuthor sets the "author" edge to the User entity.
func (*AttachmentCreate) SetAuthorID ¶
func (ac *AttachmentCreate) SetAuthorID(id uuid.UUID) *AttachmentCreate
SetAuthorID sets the "author" edge to the User entity by ID.
func (*AttachmentCreate) SetBlurhash ¶
func (ac *AttachmentCreate) SetBlurhash(s string) *AttachmentCreate
SetBlurhash sets the "blurhash" field.
func (*AttachmentCreate) SetCreatedAt ¶
func (ac *AttachmentCreate) SetCreatedAt(t time.Time) *AttachmentCreate
SetCreatedAt sets the "created_at" field.
func (*AttachmentCreate) SetDescription ¶
func (ac *AttachmentCreate) SetDescription(s string) *AttachmentCreate
SetDescription sets the "description" field.
func (*AttachmentCreate) SetExtensions ¶
func (ac *AttachmentCreate) SetExtensions(v versia.Extensions) *AttachmentCreate
SetExtensions sets the "extensions" field.
func (*AttachmentCreate) SetFps ¶
func (ac *AttachmentCreate) SetFps(i int) *AttachmentCreate
SetFps sets the "fps" field.
func (*AttachmentCreate) SetHeight ¶
func (ac *AttachmentCreate) SetHeight(i int) *AttachmentCreate
SetHeight sets the "height" field.
func (*AttachmentCreate) SetID ¶
func (ac *AttachmentCreate) SetID(u uuid.UUID) *AttachmentCreate
SetID sets the "id" field.
func (*AttachmentCreate) SetIsRemote ¶
func (ac *AttachmentCreate) SetIsRemote(b bool) *AttachmentCreate
SetIsRemote sets the "isRemote" field.
func (*AttachmentCreate) SetMimeType ¶
func (ac *AttachmentCreate) SetMimeType(s string) *AttachmentCreate
SetMimeType sets the "mimeType" field.
func (*AttachmentCreate) SetNillableBlurhash ¶
func (ac *AttachmentCreate) SetNillableBlurhash(s *string) *AttachmentCreate
SetNillableBlurhash sets the "blurhash" field if the given value is not nil.
func (*AttachmentCreate) SetNillableCreatedAt ¶
func (ac *AttachmentCreate) SetNillableCreatedAt(t *time.Time) *AttachmentCreate
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*AttachmentCreate) SetNillableFps ¶
func (ac *AttachmentCreate) SetNillableFps(i *int) *AttachmentCreate
SetNillableFps sets the "fps" field if the given value is not nil.
func (*AttachmentCreate) SetNillableHeight ¶
func (ac *AttachmentCreate) SetNillableHeight(i *int) *AttachmentCreate
SetNillableHeight sets the "height" field if the given value is not nil.
func (*AttachmentCreate) SetNillableID ¶
func (ac *AttachmentCreate) SetNillableID(u *uuid.UUID) *AttachmentCreate
SetNillableID sets the "id" field if the given value is not nil.
func (*AttachmentCreate) SetNillableUpdatedAt ¶
func (ac *AttachmentCreate) SetNillableUpdatedAt(t *time.Time) *AttachmentCreate
SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.
func (*AttachmentCreate) SetNillableWidth ¶
func (ac *AttachmentCreate) SetNillableWidth(i *int) *AttachmentCreate
SetNillableWidth sets the "width" field if the given value is not nil.
func (*AttachmentCreate) SetSha256 ¶
func (ac *AttachmentCreate) SetSha256(b []byte) *AttachmentCreate
SetSha256 sets the "sha256" field.
func (*AttachmentCreate) SetSize ¶
func (ac *AttachmentCreate) SetSize(i int) *AttachmentCreate
SetSize sets the "size" field.
func (*AttachmentCreate) SetURI ¶
func (ac *AttachmentCreate) SetURI(s string) *AttachmentCreate
SetURI sets the "uri" field.
func (*AttachmentCreate) SetUpdatedAt ¶
func (ac *AttachmentCreate) SetUpdatedAt(t time.Time) *AttachmentCreate
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentCreate) SetWidth ¶
func (ac *AttachmentCreate) SetWidth(i int) *AttachmentCreate
SetWidth sets the "width" field.
type AttachmentCreateBulk ¶
type AttachmentCreateBulk struct {
// contains filtered or unexported fields
}
AttachmentCreateBulk is the builder for creating many Attachment entities in bulk.
func (*AttachmentCreateBulk) Exec ¶
func (acb *AttachmentCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*AttachmentCreateBulk) ExecX ¶
func (acb *AttachmentCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentCreateBulk) OnConflict ¶
func (acb *AttachmentCreateBulk) OnConflict(opts ...sql.ConflictOption) *AttachmentUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Attachment.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.AttachmentUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*AttachmentCreateBulk) OnConflictColumns ¶
func (acb *AttachmentCreateBulk) OnConflictColumns(columns ...string) *AttachmentUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Attachment.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*AttachmentCreateBulk) Save ¶
func (acb *AttachmentCreateBulk) Save(ctx context.Context) ([]*Attachment, error)
Save creates the Attachment entities in the database.
func (*AttachmentCreateBulk) SaveX ¶
func (acb *AttachmentCreateBulk) SaveX(ctx context.Context) []*Attachment
SaveX is like Save, but panics if an error occurs.
type AttachmentDelete ¶
type AttachmentDelete struct {
// contains filtered or unexported fields
}
AttachmentDelete is the builder for deleting a Attachment entity.
func (*AttachmentDelete) Exec ¶
func (ad *AttachmentDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*AttachmentDelete) ExecX ¶
func (ad *AttachmentDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentDelete) Where ¶
func (ad *AttachmentDelete) Where(ps ...predicate.Attachment) *AttachmentDelete
Where appends a list predicates to the AttachmentDelete builder.
type AttachmentDeleteOne ¶
type AttachmentDeleteOne struct {
// contains filtered or unexported fields
}
AttachmentDeleteOne is the builder for deleting a single Attachment entity.
func (*AttachmentDeleteOne) Exec ¶
func (ado *AttachmentDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*AttachmentDeleteOne) ExecX ¶
func (ado *AttachmentDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentDeleteOne) Where ¶
func (ado *AttachmentDeleteOne) Where(ps ...predicate.Attachment) *AttachmentDeleteOne
Where appends a list predicates to the AttachmentDelete builder.
type AttachmentEdges ¶
type AttachmentEdges struct { // Author holds the value of the author edge. Author *User `json:"author,omitempty"` // contains filtered or unexported fields }
AttachmentEdges holds the relations/edges for other nodes in the graph.
func (AttachmentEdges) AuthorOrErr ¶
func (e AttachmentEdges) AuthorOrErr() (*User, error)
AuthorOrErr returns the Author value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type AttachmentGroupBy ¶
type AttachmentGroupBy struct {
// contains filtered or unexported fields
}
AttachmentGroupBy is the group-by builder for Attachment entities.
func (*AttachmentGroupBy) Aggregate ¶
func (agb *AttachmentGroupBy) Aggregate(fns ...AggregateFunc) *AttachmentGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*AttachmentGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*AttachmentGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*AttachmentGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*AttachmentGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*AttachmentGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*AttachmentGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*AttachmentGroupBy) Scan ¶
func (agb *AttachmentGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*AttachmentGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type AttachmentMutation ¶
type AttachmentMutation struct {
// contains filtered or unexported fields
}
AttachmentMutation represents an operation that mutates the Attachment nodes in the graph.
func (*AttachmentMutation) AddField ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) AddFps ¶
func (m *AttachmentMutation) AddFps(i int)
AddFps adds i to the "fps" field.
func (*AttachmentMutation) AddHeight ¶
func (m *AttachmentMutation) AddHeight(i int)
AddHeight adds i to the "height" field.
func (*AttachmentMutation) AddSize ¶
func (m *AttachmentMutation) AddSize(i int)
AddSize adds i to the "size" field.
func (*AttachmentMutation) AddWidth ¶
func (m *AttachmentMutation) AddWidth(i int)
AddWidth adds i to the "width" field.
func (*AttachmentMutation) AddedEdges ¶
func (m *AttachmentMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*AttachmentMutation) AddedField ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) AddedFields ¶
func (m *AttachmentMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*AttachmentMutation) AddedFps ¶
func (m *AttachmentMutation) AddedFps() (r int, exists bool)
AddedFps returns the value that was added to the "fps" field in this mutation.
func (*AttachmentMutation) AddedHeight ¶
func (m *AttachmentMutation) AddedHeight() (r int, exists bool)
AddedHeight returns the value that was added to the "height" field in this mutation.
func (*AttachmentMutation) AddedIDs ¶
func (m *AttachmentMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*AttachmentMutation) AddedSize ¶
func (m *AttachmentMutation) AddedSize() (r int, exists bool)
AddedSize returns the value that was added to the "size" field in this mutation.
func (*AttachmentMutation) AddedWidth ¶
func (m *AttachmentMutation) AddedWidth() (r int, exists bool)
AddedWidth returns the value that was added to the "width" field in this mutation.
func (*AttachmentMutation) AuthorCleared ¶
func (m *AttachmentMutation) AuthorCleared() bool
AuthorCleared reports if the "author" edge to the User entity was cleared.
func (*AttachmentMutation) AuthorID ¶
func (m *AttachmentMutation) AuthorID() (id uuid.UUID, exists bool)
AuthorID returns the "author" edge ID in the mutation.
func (*AttachmentMutation) AuthorIDs ¶
func (m *AttachmentMutation) AuthorIDs() (ids []uuid.UUID)
AuthorIDs returns the "author" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AuthorID instead. It exists only for internal usage by the builders.
func (*AttachmentMutation) Blurhash ¶
func (m *AttachmentMutation) Blurhash() (r string, exists bool)
Blurhash returns the value of the "blurhash" field in the mutation.
func (*AttachmentMutation) BlurhashCleared ¶
func (m *AttachmentMutation) BlurhashCleared() bool
BlurhashCleared returns if the "blurhash" field was cleared in this mutation.
func (*AttachmentMutation) ClearAuthor ¶
func (m *AttachmentMutation) ClearAuthor()
ClearAuthor clears the "author" edge to the User entity.
func (*AttachmentMutation) ClearBlurhash ¶
func (m *AttachmentMutation) ClearBlurhash()
ClearBlurhash clears the value of the "blurhash" field.
func (*AttachmentMutation) ClearEdge ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) ClearField ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) ClearFps ¶
func (m *AttachmentMutation) ClearFps()
ClearFps clears the value of the "fps" field.
func (*AttachmentMutation) ClearHeight ¶
func (m *AttachmentMutation) ClearHeight()
ClearHeight clears the value of the "height" field.
func (*AttachmentMutation) ClearWidth ¶
func (m *AttachmentMutation) ClearWidth()
ClearWidth clears the value of the "width" field.
func (*AttachmentMutation) ClearedEdges ¶
func (m *AttachmentMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*AttachmentMutation) ClearedFields ¶
func (m *AttachmentMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (AttachmentMutation) Client ¶
func (m AttachmentMutation) 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 (*AttachmentMutation) CreatedAt ¶
func (m *AttachmentMutation) CreatedAt() (r time.Time, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*AttachmentMutation) Description ¶
func (m *AttachmentMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*AttachmentMutation) EdgeCleared ¶
func (m *AttachmentMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*AttachmentMutation) Extensions ¶
func (m *AttachmentMutation) Extensions() (r versia.Extensions, exists bool)
Extensions returns the value of the "extensions" field in the mutation.
func (*AttachmentMutation) Field ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) FieldCleared ¶
func (m *AttachmentMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*AttachmentMutation) Fields ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) Fps ¶
func (m *AttachmentMutation) Fps() (r int, exists bool)
Fps returns the value of the "fps" field in the mutation.
func (*AttachmentMutation) FpsCleared ¶
func (m *AttachmentMutation) FpsCleared() bool
FpsCleared returns if the "fps" field was cleared in this mutation.
func (*AttachmentMutation) Height ¶
func (m *AttachmentMutation) Height() (r int, exists bool)
Height returns the value of the "height" field in the mutation.
func (*AttachmentMutation) HeightCleared ¶
func (m *AttachmentMutation) HeightCleared() bool
HeightCleared returns if the "height" field was cleared in this mutation.
func (*AttachmentMutation) ID ¶
func (m *AttachmentMutation) ID() (id uuid.UUID, 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 (*AttachmentMutation) IDs ¶
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 (*AttachmentMutation) IsRemote ¶
func (m *AttachmentMutation) IsRemote() (r bool, exists bool)
IsRemote returns the value of the "isRemote" field in the mutation.
func (*AttachmentMutation) MimeType ¶
func (m *AttachmentMutation) MimeType() (r string, exists bool)
MimeType returns the value of the "mimeType" field in the mutation.
func (*AttachmentMutation) OldBlurhash ¶
func (m *AttachmentMutation) OldBlurhash(ctx context.Context) (v *string, err error)
OldBlurhash returns the old "blurhash" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldCreatedAt ¶
OldCreatedAt returns the old "created_at" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldDescription ¶
func (m *AttachmentMutation) OldDescription(ctx context.Context) (v string, err error)
OldDescription returns the old "description" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldExtensions ¶
func (m *AttachmentMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
OldExtensions returns the old "extensions" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) 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 (*AttachmentMutation) OldFps ¶
func (m *AttachmentMutation) OldFps(ctx context.Context) (v *int, err error)
OldFps returns the old "fps" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldHeight ¶
func (m *AttachmentMutation) OldHeight(ctx context.Context) (v *int, err error)
OldHeight returns the old "height" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldIsRemote ¶
func (m *AttachmentMutation) OldIsRemote(ctx context.Context) (v bool, err error)
OldIsRemote returns the old "isRemote" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldMimeType ¶
func (m *AttachmentMutation) OldMimeType(ctx context.Context) (v string, err error)
OldMimeType returns the old "mimeType" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldSha256 ¶
func (m *AttachmentMutation) OldSha256(ctx context.Context) (v []byte, err error)
OldSha256 returns the old "sha256" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldSize ¶
func (m *AttachmentMutation) OldSize(ctx context.Context) (v int, err error)
OldSize returns the old "size" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldURI ¶
func (m *AttachmentMutation) OldURI(ctx context.Context) (v string, err error)
OldURI returns the old "uri" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldUpdatedAt ¶
OldUpdatedAt returns the old "updated_at" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) OldWidth ¶
func (m *AttachmentMutation) OldWidth(ctx context.Context) (v *int, err error)
OldWidth returns the old "width" field's value of the Attachment entity. If the Attachment 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 (*AttachmentMutation) RemovedEdges ¶
func (m *AttachmentMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*AttachmentMutation) RemovedIDs ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) ResetAuthor ¶
func (m *AttachmentMutation) ResetAuthor()
ResetAuthor resets all changes to the "author" edge.
func (*AttachmentMutation) ResetBlurhash ¶
func (m *AttachmentMutation) ResetBlurhash()
ResetBlurhash resets all changes to the "blurhash" field.
func (*AttachmentMutation) ResetCreatedAt ¶
func (m *AttachmentMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*AttachmentMutation) ResetDescription ¶
func (m *AttachmentMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*AttachmentMutation) ResetEdge ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) ResetExtensions ¶
func (m *AttachmentMutation) ResetExtensions()
ResetExtensions resets all changes to the "extensions" field.
func (*AttachmentMutation) ResetField ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) ResetFps ¶
func (m *AttachmentMutation) ResetFps()
ResetFps resets all changes to the "fps" field.
func (*AttachmentMutation) ResetHeight ¶
func (m *AttachmentMutation) ResetHeight()
ResetHeight resets all changes to the "height" field.
func (*AttachmentMutation) ResetIsRemote ¶
func (m *AttachmentMutation) ResetIsRemote()
ResetIsRemote resets all changes to the "isRemote" field.
func (*AttachmentMutation) ResetMimeType ¶
func (m *AttachmentMutation) ResetMimeType()
ResetMimeType resets all changes to the "mimeType" field.
func (*AttachmentMutation) ResetSha256 ¶
func (m *AttachmentMutation) ResetSha256()
ResetSha256 resets all changes to the "sha256" field.
func (*AttachmentMutation) ResetSize ¶
func (m *AttachmentMutation) ResetSize()
ResetSize resets all changes to the "size" field.
func (*AttachmentMutation) ResetURI ¶
func (m *AttachmentMutation) ResetURI()
ResetURI resets all changes to the "uri" field.
func (*AttachmentMutation) ResetUpdatedAt ¶
func (m *AttachmentMutation) ResetUpdatedAt()
ResetUpdatedAt resets all changes to the "updated_at" field.
func (*AttachmentMutation) ResetWidth ¶
func (m *AttachmentMutation) ResetWidth()
ResetWidth resets all changes to the "width" field.
func (*AttachmentMutation) SetAuthorID ¶
func (m *AttachmentMutation) SetAuthorID(id uuid.UUID)
SetAuthorID sets the "author" edge to the User entity by id.
func (*AttachmentMutation) SetBlurhash ¶
func (m *AttachmentMutation) SetBlurhash(s string)
SetBlurhash sets the "blurhash" field.
func (*AttachmentMutation) SetCreatedAt ¶
func (m *AttachmentMutation) SetCreatedAt(t time.Time)
SetCreatedAt sets the "created_at" field.
func (*AttachmentMutation) SetDescription ¶
func (m *AttachmentMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*AttachmentMutation) SetExtensions ¶
func (m *AttachmentMutation) SetExtensions(v versia.Extensions)
SetExtensions sets the "extensions" field.
func (*AttachmentMutation) SetField ¶
func (m *AttachmentMutation) 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 (*AttachmentMutation) SetFps ¶
func (m *AttachmentMutation) SetFps(i int)
SetFps sets the "fps" field.
func (*AttachmentMutation) SetHeight ¶
func (m *AttachmentMutation) SetHeight(i int)
SetHeight sets the "height" field.
func (*AttachmentMutation) SetID ¶
func (m *AttachmentMutation) SetID(id uuid.UUID)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Attachment entities.
func (*AttachmentMutation) SetIsRemote ¶
func (m *AttachmentMutation) SetIsRemote(b bool)
SetIsRemote sets the "isRemote" field.
func (*AttachmentMutation) SetMimeType ¶
func (m *AttachmentMutation) SetMimeType(s string)
SetMimeType sets the "mimeType" field.
func (*AttachmentMutation) SetOp ¶
func (m *AttachmentMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*AttachmentMutation) SetSha256 ¶
func (m *AttachmentMutation) SetSha256(b []byte)
SetSha256 sets the "sha256" field.
func (*AttachmentMutation) SetSize ¶
func (m *AttachmentMutation) SetSize(i int)
SetSize sets the "size" field.
func (*AttachmentMutation) SetURI ¶
func (m *AttachmentMutation) SetURI(s string)
SetURI sets the "uri" field.
func (*AttachmentMutation) SetUpdatedAt ¶
func (m *AttachmentMutation) SetUpdatedAt(t time.Time)
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentMutation) SetWidth ¶
func (m *AttachmentMutation) SetWidth(i int)
SetWidth sets the "width" field.
func (*AttachmentMutation) Sha256 ¶
func (m *AttachmentMutation) Sha256() (r []byte, exists bool)
Sha256 returns the value of the "sha256" field in the mutation.
func (*AttachmentMutation) Size ¶
func (m *AttachmentMutation) Size() (r int, exists bool)
Size returns the value of the "size" field in the mutation.
func (AttachmentMutation) Tx ¶
func (m AttachmentMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*AttachmentMutation) Type ¶
func (m *AttachmentMutation) Type() string
Type returns the node type of this mutation (Attachment).
func (*AttachmentMutation) URI ¶
func (m *AttachmentMutation) URI() (r string, exists bool)
URI returns the value of the "uri" field in the mutation.
func (*AttachmentMutation) UpdatedAt ¶
func (m *AttachmentMutation) UpdatedAt() (r time.Time, exists bool)
UpdatedAt returns the value of the "updated_at" field in the mutation.
func (*AttachmentMutation) Where ¶
func (m *AttachmentMutation) Where(ps ...predicate.Attachment)
Where appends a list predicates to the AttachmentMutation builder.
func (*AttachmentMutation) WhereP ¶
func (m *AttachmentMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the AttachmentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
func (*AttachmentMutation) Width ¶
func (m *AttachmentMutation) Width() (r int, exists bool)
Width returns the value of the "width" field in the mutation.
func (*AttachmentMutation) WidthCleared ¶
func (m *AttachmentMutation) WidthCleared() bool
WidthCleared returns if the "width" field was cleared in this mutation.
type AttachmentQuery ¶
type AttachmentQuery struct {
// contains filtered or unexported fields
}
AttachmentQuery is the builder for querying Attachment entities.
func (*AttachmentQuery) Aggregate ¶
func (aq *AttachmentQuery) Aggregate(fns ...AggregateFunc) *AttachmentSelect
Aggregate returns a AttachmentSelect configured with the given aggregations.
func (*AttachmentQuery) All ¶
func (aq *AttachmentQuery) All(ctx context.Context) ([]*Attachment, error)
All executes the query and returns a list of Attachments.
func (*AttachmentQuery) AllX ¶
func (aq *AttachmentQuery) AllX(ctx context.Context) []*Attachment
AllX is like All, but panics if an error occurs.
func (*AttachmentQuery) Clone ¶
func (aq *AttachmentQuery) Clone() *AttachmentQuery
Clone returns a duplicate of the AttachmentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*AttachmentQuery) Count ¶
func (aq *AttachmentQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*AttachmentQuery) CountX ¶
func (aq *AttachmentQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*AttachmentQuery) Exist ¶
func (aq *AttachmentQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*AttachmentQuery) ExistX ¶
func (aq *AttachmentQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*AttachmentQuery) First ¶
func (aq *AttachmentQuery) First(ctx context.Context) (*Attachment, error)
First returns the first Attachment entity from the query. Returns a *NotFoundError when no Attachment was found.
func (*AttachmentQuery) FirstID ¶
FirstID returns the first Attachment ID from the query. Returns a *NotFoundError when no Attachment ID was found.
func (*AttachmentQuery) FirstIDX ¶
func (aq *AttachmentQuery) FirstIDX(ctx context.Context) uuid.UUID
FirstIDX is like FirstID, but panics if an error occurs.
func (*AttachmentQuery) FirstX ¶
func (aq *AttachmentQuery) FirstX(ctx context.Context) *Attachment
FirstX is like First, but panics if an error occurs.
func (*AttachmentQuery) GroupBy ¶
func (aq *AttachmentQuery) GroupBy(field string, fields ...string) *AttachmentGroupBy
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 { IsRemote bool `json:"isRemote,omitempty"` Count int `json:"count,omitempty"` } client.Attachment.Query(). GroupBy(attachment.FieldIsRemote). Aggregate(ent.Count()). Scan(ctx, &v)
func (*AttachmentQuery) IDsX ¶
func (aq *AttachmentQuery) IDsX(ctx context.Context) []uuid.UUID
IDsX is like IDs, but panics if an error occurs.
func (*AttachmentQuery) Limit ¶
func (aq *AttachmentQuery) Limit(limit int) *AttachmentQuery
Limit the number of records to be returned by this query.
func (*AttachmentQuery) Offset ¶
func (aq *AttachmentQuery) Offset(offset int) *AttachmentQuery
Offset to start from.
func (*AttachmentQuery) Only ¶
func (aq *AttachmentQuery) Only(ctx context.Context) (*Attachment, error)
Only returns a single Attachment entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Attachment entity is found. Returns a *NotFoundError when no Attachment entities are found.
func (*AttachmentQuery) OnlyID ¶
OnlyID is like Only, but returns the only Attachment ID in the query. Returns a *NotSingularError when more than one Attachment ID is found. Returns a *NotFoundError when no entities are found.
func (*AttachmentQuery) OnlyIDX ¶
func (aq *AttachmentQuery) OnlyIDX(ctx context.Context) uuid.UUID
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*AttachmentQuery) OnlyX ¶
func (aq *AttachmentQuery) OnlyX(ctx context.Context) *Attachment
OnlyX is like Only, but panics if an error occurs.
func (*AttachmentQuery) Order ¶
func (aq *AttachmentQuery) Order(o ...attachment.OrderOption) *AttachmentQuery
Order specifies how the records should be ordered.
func (*AttachmentQuery) QueryAuthor ¶
func (aq *AttachmentQuery) QueryAuthor() *UserQuery
QueryAuthor chains the current query on the "author" edge.
func (*AttachmentQuery) Select ¶
func (aq *AttachmentQuery) Select(fields ...string) *AttachmentSelect
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 { IsRemote bool `json:"isRemote,omitempty"` } client.Attachment.Query(). Select(attachment.FieldIsRemote). Scan(ctx, &v)
func (*AttachmentQuery) Unique ¶
func (aq *AttachmentQuery) Unique(unique bool) *AttachmentQuery
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 (*AttachmentQuery) Where ¶
func (aq *AttachmentQuery) Where(ps ...predicate.Attachment) *AttachmentQuery
Where adds a new predicate for the AttachmentQuery builder.
func (*AttachmentQuery) WithAuthor ¶
func (aq *AttachmentQuery) WithAuthor(opts ...func(*UserQuery)) *AttachmentQuery
WithAuthor tells the query-builder to eager-load the nodes that are connected to the "author" edge. The optional arguments are used to configure the query builder of the edge.
type AttachmentSelect ¶
type AttachmentSelect struct { *AttachmentQuery // contains filtered or unexported fields }
AttachmentSelect is the builder for selecting fields of Attachment entities.
func (*AttachmentSelect) Aggregate ¶
func (as *AttachmentSelect) Aggregate(fns ...AggregateFunc) *AttachmentSelect
Aggregate adds the given aggregation functions to the selector query.
func (*AttachmentSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*AttachmentSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*AttachmentSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*AttachmentSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*AttachmentSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*AttachmentSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*AttachmentSelect) Scan ¶
func (as *AttachmentSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*AttachmentSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type AttachmentUpdate ¶
type AttachmentUpdate struct {
// contains filtered or unexported fields
}
AttachmentUpdate is the builder for updating Attachment entities.
func (*AttachmentUpdate) AddFps ¶
func (au *AttachmentUpdate) AddFps(i int) *AttachmentUpdate
AddFps adds i to the "fps" field.
func (*AttachmentUpdate) AddHeight ¶
func (au *AttachmentUpdate) AddHeight(i int) *AttachmentUpdate
AddHeight adds i to the "height" field.
func (*AttachmentUpdate) AddSize ¶
func (au *AttachmentUpdate) AddSize(i int) *AttachmentUpdate
AddSize adds i to the "size" field.
func (*AttachmentUpdate) AddWidth ¶
func (au *AttachmentUpdate) AddWidth(i int) *AttachmentUpdate
AddWidth adds i to the "width" field.
func (*AttachmentUpdate) ClearAuthor ¶
func (au *AttachmentUpdate) ClearAuthor() *AttachmentUpdate
ClearAuthor clears the "author" edge to the User entity.
func (*AttachmentUpdate) ClearBlurhash ¶
func (au *AttachmentUpdate) ClearBlurhash() *AttachmentUpdate
ClearBlurhash clears the value of the "blurhash" field.
func (*AttachmentUpdate) ClearFps ¶
func (au *AttachmentUpdate) ClearFps() *AttachmentUpdate
ClearFps clears the value of the "fps" field.
func (*AttachmentUpdate) ClearHeight ¶
func (au *AttachmentUpdate) ClearHeight() *AttachmentUpdate
ClearHeight clears the value of the "height" field.
func (*AttachmentUpdate) ClearWidth ¶
func (au *AttachmentUpdate) ClearWidth() *AttachmentUpdate
ClearWidth clears the value of the "width" field.
func (*AttachmentUpdate) Exec ¶
func (au *AttachmentUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*AttachmentUpdate) ExecX ¶
func (au *AttachmentUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentUpdate) Mutation ¶
func (au *AttachmentUpdate) Mutation() *AttachmentMutation
Mutation returns the AttachmentMutation object of the builder.
func (*AttachmentUpdate) Save ¶
func (au *AttachmentUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*AttachmentUpdate) SaveX ¶
func (au *AttachmentUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*AttachmentUpdate) SetAuthor ¶
func (au *AttachmentUpdate) SetAuthor(u *User) *AttachmentUpdate
SetAuthor sets the "author" edge to the User entity.
func (*AttachmentUpdate) SetAuthorID ¶
func (au *AttachmentUpdate) SetAuthorID(id uuid.UUID) *AttachmentUpdate
SetAuthorID sets the "author" edge to the User entity by ID.
func (*AttachmentUpdate) SetBlurhash ¶
func (au *AttachmentUpdate) SetBlurhash(s string) *AttachmentUpdate
SetBlurhash sets the "blurhash" field.
func (*AttachmentUpdate) SetDescription ¶
func (au *AttachmentUpdate) SetDescription(s string) *AttachmentUpdate
SetDescription sets the "description" field.
func (*AttachmentUpdate) SetExtensions ¶
func (au *AttachmentUpdate) SetExtensions(v versia.Extensions) *AttachmentUpdate
SetExtensions sets the "extensions" field.
func (*AttachmentUpdate) SetFps ¶
func (au *AttachmentUpdate) SetFps(i int) *AttachmentUpdate
SetFps sets the "fps" field.
func (*AttachmentUpdate) SetHeight ¶
func (au *AttachmentUpdate) SetHeight(i int) *AttachmentUpdate
SetHeight sets the "height" field.
func (*AttachmentUpdate) SetIsRemote ¶
func (au *AttachmentUpdate) SetIsRemote(b bool) *AttachmentUpdate
SetIsRemote sets the "isRemote" field.
func (*AttachmentUpdate) SetMimeType ¶
func (au *AttachmentUpdate) SetMimeType(s string) *AttachmentUpdate
SetMimeType sets the "mimeType" field.
func (*AttachmentUpdate) SetNillableBlurhash ¶
func (au *AttachmentUpdate) SetNillableBlurhash(s *string) *AttachmentUpdate
SetNillableBlurhash sets the "blurhash" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableDescription ¶
func (au *AttachmentUpdate) SetNillableDescription(s *string) *AttachmentUpdate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableFps ¶
func (au *AttachmentUpdate) SetNillableFps(i *int) *AttachmentUpdate
SetNillableFps sets the "fps" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableHeight ¶
func (au *AttachmentUpdate) SetNillableHeight(i *int) *AttachmentUpdate
SetNillableHeight sets the "height" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableIsRemote ¶
func (au *AttachmentUpdate) SetNillableIsRemote(b *bool) *AttachmentUpdate
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableMimeType ¶
func (au *AttachmentUpdate) SetNillableMimeType(s *string) *AttachmentUpdate
SetNillableMimeType sets the "mimeType" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableSize ¶
func (au *AttachmentUpdate) SetNillableSize(i *int) *AttachmentUpdate
SetNillableSize sets the "size" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableURI ¶
func (au *AttachmentUpdate) SetNillableURI(s *string) *AttachmentUpdate
SetNillableURI sets the "uri" field if the given value is not nil.
func (*AttachmentUpdate) SetNillableWidth ¶
func (au *AttachmentUpdate) SetNillableWidth(i *int) *AttachmentUpdate
SetNillableWidth sets the "width" field if the given value is not nil.
func (*AttachmentUpdate) SetSha256 ¶
func (au *AttachmentUpdate) SetSha256(b []byte) *AttachmentUpdate
SetSha256 sets the "sha256" field.
func (*AttachmentUpdate) SetSize ¶
func (au *AttachmentUpdate) SetSize(i int) *AttachmentUpdate
SetSize sets the "size" field.
func (*AttachmentUpdate) SetURI ¶
func (au *AttachmentUpdate) SetURI(s string) *AttachmentUpdate
SetURI sets the "uri" field.
func (*AttachmentUpdate) SetUpdatedAt ¶
func (au *AttachmentUpdate) SetUpdatedAt(t time.Time) *AttachmentUpdate
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentUpdate) SetWidth ¶
func (au *AttachmentUpdate) SetWidth(i int) *AttachmentUpdate
SetWidth sets the "width" field.
func (*AttachmentUpdate) Where ¶
func (au *AttachmentUpdate) Where(ps ...predicate.Attachment) *AttachmentUpdate
Where appends a list predicates to the AttachmentUpdate builder.
type AttachmentUpdateOne ¶
type AttachmentUpdateOne struct {
// contains filtered or unexported fields
}
AttachmentUpdateOne is the builder for updating a single Attachment entity.
func (*AttachmentUpdateOne) AddFps ¶
func (auo *AttachmentUpdateOne) AddFps(i int) *AttachmentUpdateOne
AddFps adds i to the "fps" field.
func (*AttachmentUpdateOne) AddHeight ¶
func (auo *AttachmentUpdateOne) AddHeight(i int) *AttachmentUpdateOne
AddHeight adds i to the "height" field.
func (*AttachmentUpdateOne) AddSize ¶
func (auo *AttachmentUpdateOne) AddSize(i int) *AttachmentUpdateOne
AddSize adds i to the "size" field.
func (*AttachmentUpdateOne) AddWidth ¶
func (auo *AttachmentUpdateOne) AddWidth(i int) *AttachmentUpdateOne
AddWidth adds i to the "width" field.
func (*AttachmentUpdateOne) ClearAuthor ¶
func (auo *AttachmentUpdateOne) ClearAuthor() *AttachmentUpdateOne
ClearAuthor clears the "author" edge to the User entity.
func (*AttachmentUpdateOne) ClearBlurhash ¶
func (auo *AttachmentUpdateOne) ClearBlurhash() *AttachmentUpdateOne
ClearBlurhash clears the value of the "blurhash" field.
func (*AttachmentUpdateOne) ClearFps ¶
func (auo *AttachmentUpdateOne) ClearFps() *AttachmentUpdateOne
ClearFps clears the value of the "fps" field.
func (*AttachmentUpdateOne) ClearHeight ¶
func (auo *AttachmentUpdateOne) ClearHeight() *AttachmentUpdateOne
ClearHeight clears the value of the "height" field.
func (*AttachmentUpdateOne) ClearWidth ¶
func (auo *AttachmentUpdateOne) ClearWidth() *AttachmentUpdateOne
ClearWidth clears the value of the "width" field.
func (*AttachmentUpdateOne) Exec ¶
func (auo *AttachmentUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*AttachmentUpdateOne) ExecX ¶
func (auo *AttachmentUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentUpdateOne) Mutation ¶
func (auo *AttachmentUpdateOne) Mutation() *AttachmentMutation
Mutation returns the AttachmentMutation object of the builder.
func (*AttachmentUpdateOne) Save ¶
func (auo *AttachmentUpdateOne) Save(ctx context.Context) (*Attachment, error)
Save executes the query and returns the updated Attachment entity.
func (*AttachmentUpdateOne) SaveX ¶
func (auo *AttachmentUpdateOne) SaveX(ctx context.Context) *Attachment
SaveX is like Save, but panics if an error occurs.
func (*AttachmentUpdateOne) Select ¶
func (auo *AttachmentUpdateOne) Select(field string, fields ...string) *AttachmentUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*AttachmentUpdateOne) SetAuthor ¶
func (auo *AttachmentUpdateOne) SetAuthor(u *User) *AttachmentUpdateOne
SetAuthor sets the "author" edge to the User entity.
func (*AttachmentUpdateOne) SetAuthorID ¶
func (auo *AttachmentUpdateOne) SetAuthorID(id uuid.UUID) *AttachmentUpdateOne
SetAuthorID sets the "author" edge to the User entity by ID.
func (*AttachmentUpdateOne) SetBlurhash ¶
func (auo *AttachmentUpdateOne) SetBlurhash(s string) *AttachmentUpdateOne
SetBlurhash sets the "blurhash" field.
func (*AttachmentUpdateOne) SetDescription ¶
func (auo *AttachmentUpdateOne) SetDescription(s string) *AttachmentUpdateOne
SetDescription sets the "description" field.
func (*AttachmentUpdateOne) SetExtensions ¶
func (auo *AttachmentUpdateOne) SetExtensions(v versia.Extensions) *AttachmentUpdateOne
SetExtensions sets the "extensions" field.
func (*AttachmentUpdateOne) SetFps ¶
func (auo *AttachmentUpdateOne) SetFps(i int) *AttachmentUpdateOne
SetFps sets the "fps" field.
func (*AttachmentUpdateOne) SetHeight ¶
func (auo *AttachmentUpdateOne) SetHeight(i int) *AttachmentUpdateOne
SetHeight sets the "height" field.
func (*AttachmentUpdateOne) SetIsRemote ¶
func (auo *AttachmentUpdateOne) SetIsRemote(b bool) *AttachmentUpdateOne
SetIsRemote sets the "isRemote" field.
func (*AttachmentUpdateOne) SetMimeType ¶
func (auo *AttachmentUpdateOne) SetMimeType(s string) *AttachmentUpdateOne
SetMimeType sets the "mimeType" field.
func (*AttachmentUpdateOne) SetNillableBlurhash ¶
func (auo *AttachmentUpdateOne) SetNillableBlurhash(s *string) *AttachmentUpdateOne
SetNillableBlurhash sets the "blurhash" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableDescription ¶
func (auo *AttachmentUpdateOne) SetNillableDescription(s *string) *AttachmentUpdateOne
SetNillableDescription sets the "description" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableFps ¶
func (auo *AttachmentUpdateOne) SetNillableFps(i *int) *AttachmentUpdateOne
SetNillableFps sets the "fps" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableHeight ¶
func (auo *AttachmentUpdateOne) SetNillableHeight(i *int) *AttachmentUpdateOne
SetNillableHeight sets the "height" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableIsRemote ¶
func (auo *AttachmentUpdateOne) SetNillableIsRemote(b *bool) *AttachmentUpdateOne
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableMimeType ¶
func (auo *AttachmentUpdateOne) SetNillableMimeType(s *string) *AttachmentUpdateOne
SetNillableMimeType sets the "mimeType" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableSize ¶
func (auo *AttachmentUpdateOne) SetNillableSize(i *int) *AttachmentUpdateOne
SetNillableSize sets the "size" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableURI ¶
func (auo *AttachmentUpdateOne) SetNillableURI(s *string) *AttachmentUpdateOne
SetNillableURI sets the "uri" field if the given value is not nil.
func (*AttachmentUpdateOne) SetNillableWidth ¶
func (auo *AttachmentUpdateOne) SetNillableWidth(i *int) *AttachmentUpdateOne
SetNillableWidth sets the "width" field if the given value is not nil.
func (*AttachmentUpdateOne) SetSha256 ¶
func (auo *AttachmentUpdateOne) SetSha256(b []byte) *AttachmentUpdateOne
SetSha256 sets the "sha256" field.
func (*AttachmentUpdateOne) SetSize ¶
func (auo *AttachmentUpdateOne) SetSize(i int) *AttachmentUpdateOne
SetSize sets the "size" field.
func (*AttachmentUpdateOne) SetURI ¶
func (auo *AttachmentUpdateOne) SetURI(s string) *AttachmentUpdateOne
SetURI sets the "uri" field.
func (*AttachmentUpdateOne) SetUpdatedAt ¶
func (auo *AttachmentUpdateOne) SetUpdatedAt(t time.Time) *AttachmentUpdateOne
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentUpdateOne) SetWidth ¶
func (auo *AttachmentUpdateOne) SetWidth(i int) *AttachmentUpdateOne
SetWidth sets the "width" field.
func (*AttachmentUpdateOne) Where ¶
func (auo *AttachmentUpdateOne) Where(ps ...predicate.Attachment) *AttachmentUpdateOne
Where appends a list predicates to the AttachmentUpdate builder.
type AttachmentUpsert ¶
AttachmentUpsert is the "OnConflict" setter.
func (*AttachmentUpsert) AddFps ¶
func (u *AttachmentUpsert) AddFps(v int) *AttachmentUpsert
AddFps adds v to the "fps" field.
func (*AttachmentUpsert) AddHeight ¶
func (u *AttachmentUpsert) AddHeight(v int) *AttachmentUpsert
AddHeight adds v to the "height" field.
func (*AttachmentUpsert) AddSize ¶
func (u *AttachmentUpsert) AddSize(v int) *AttachmentUpsert
AddSize adds v to the "size" field.
func (*AttachmentUpsert) AddWidth ¶
func (u *AttachmentUpsert) AddWidth(v int) *AttachmentUpsert
AddWidth adds v to the "width" field.
func (*AttachmentUpsert) ClearBlurhash ¶
func (u *AttachmentUpsert) ClearBlurhash() *AttachmentUpsert
ClearBlurhash clears the value of the "blurhash" field.
func (*AttachmentUpsert) ClearFps ¶
func (u *AttachmentUpsert) ClearFps() *AttachmentUpsert
ClearFps clears the value of the "fps" field.
func (*AttachmentUpsert) ClearHeight ¶
func (u *AttachmentUpsert) ClearHeight() *AttachmentUpsert
ClearHeight clears the value of the "height" field.
func (*AttachmentUpsert) ClearWidth ¶
func (u *AttachmentUpsert) ClearWidth() *AttachmentUpsert
ClearWidth clears the value of the "width" field.
func (*AttachmentUpsert) SetBlurhash ¶
func (u *AttachmentUpsert) SetBlurhash(v string) *AttachmentUpsert
SetBlurhash sets the "blurhash" field.
func (*AttachmentUpsert) SetDescription ¶
func (u *AttachmentUpsert) SetDescription(v string) *AttachmentUpsert
SetDescription sets the "description" field.
func (*AttachmentUpsert) SetExtensions ¶
func (u *AttachmentUpsert) SetExtensions(v versia.Extensions) *AttachmentUpsert
SetExtensions sets the "extensions" field.
func (*AttachmentUpsert) SetFps ¶
func (u *AttachmentUpsert) SetFps(v int) *AttachmentUpsert
SetFps sets the "fps" field.
func (*AttachmentUpsert) SetHeight ¶
func (u *AttachmentUpsert) SetHeight(v int) *AttachmentUpsert
SetHeight sets the "height" field.
func (*AttachmentUpsert) SetIsRemote ¶
func (u *AttachmentUpsert) SetIsRemote(v bool) *AttachmentUpsert
SetIsRemote sets the "isRemote" field.
func (*AttachmentUpsert) SetMimeType ¶
func (u *AttachmentUpsert) SetMimeType(v string) *AttachmentUpsert
SetMimeType sets the "mimeType" field.
func (*AttachmentUpsert) SetSha256 ¶
func (u *AttachmentUpsert) SetSha256(v []byte) *AttachmentUpsert
SetSha256 sets the "sha256" field.
func (*AttachmentUpsert) SetSize ¶
func (u *AttachmentUpsert) SetSize(v int) *AttachmentUpsert
SetSize sets the "size" field.
func (*AttachmentUpsert) SetURI ¶
func (u *AttachmentUpsert) SetURI(v string) *AttachmentUpsert
SetURI sets the "uri" field.
func (*AttachmentUpsert) SetUpdatedAt ¶
func (u *AttachmentUpsert) SetUpdatedAt(v time.Time) *AttachmentUpsert
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentUpsert) SetWidth ¶
func (u *AttachmentUpsert) SetWidth(v int) *AttachmentUpsert
SetWidth sets the "width" field.
func (*AttachmentUpsert) UpdateBlurhash ¶
func (u *AttachmentUpsert) UpdateBlurhash() *AttachmentUpsert
UpdateBlurhash sets the "blurhash" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateDescription ¶
func (u *AttachmentUpsert) UpdateDescription() *AttachmentUpsert
UpdateDescription sets the "description" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateExtensions ¶
func (u *AttachmentUpsert) UpdateExtensions() *AttachmentUpsert
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateFps ¶
func (u *AttachmentUpsert) UpdateFps() *AttachmentUpsert
UpdateFps sets the "fps" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateHeight ¶
func (u *AttachmentUpsert) UpdateHeight() *AttachmentUpsert
UpdateHeight sets the "height" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateIsRemote ¶
func (u *AttachmentUpsert) UpdateIsRemote() *AttachmentUpsert
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateMimeType ¶
func (u *AttachmentUpsert) UpdateMimeType() *AttachmentUpsert
UpdateMimeType sets the "mimeType" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateSha256 ¶
func (u *AttachmentUpsert) UpdateSha256() *AttachmentUpsert
UpdateSha256 sets the "sha256" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateSize ¶
func (u *AttachmentUpsert) UpdateSize() *AttachmentUpsert
UpdateSize sets the "size" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateURI ¶
func (u *AttachmentUpsert) UpdateURI() *AttachmentUpsert
UpdateURI sets the "uri" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateUpdatedAt ¶
func (u *AttachmentUpsert) UpdateUpdatedAt() *AttachmentUpsert
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*AttachmentUpsert) UpdateWidth ¶
func (u *AttachmentUpsert) UpdateWidth() *AttachmentUpsert
UpdateWidth sets the "width" field to the value that was provided on create.
type AttachmentUpsertBulk ¶
type AttachmentUpsertBulk struct {
// contains filtered or unexported fields
}
AttachmentUpsertBulk is the builder for "upsert"-ing a bulk of Attachment nodes.
func (*AttachmentUpsertBulk) AddFps ¶
func (u *AttachmentUpsertBulk) AddFps(v int) *AttachmentUpsertBulk
AddFps adds v to the "fps" field.
func (*AttachmentUpsertBulk) AddHeight ¶
func (u *AttachmentUpsertBulk) AddHeight(v int) *AttachmentUpsertBulk
AddHeight adds v to the "height" field.
func (*AttachmentUpsertBulk) AddSize ¶
func (u *AttachmentUpsertBulk) AddSize(v int) *AttachmentUpsertBulk
AddSize adds v to the "size" field.
func (*AttachmentUpsertBulk) AddWidth ¶
func (u *AttachmentUpsertBulk) AddWidth(v int) *AttachmentUpsertBulk
AddWidth adds v to the "width" field.
func (*AttachmentUpsertBulk) ClearBlurhash ¶
func (u *AttachmentUpsertBulk) ClearBlurhash() *AttachmentUpsertBulk
ClearBlurhash clears the value of the "blurhash" field.
func (*AttachmentUpsertBulk) ClearFps ¶
func (u *AttachmentUpsertBulk) ClearFps() *AttachmentUpsertBulk
ClearFps clears the value of the "fps" field.
func (*AttachmentUpsertBulk) ClearHeight ¶
func (u *AttachmentUpsertBulk) ClearHeight() *AttachmentUpsertBulk
ClearHeight clears the value of the "height" field.
func (*AttachmentUpsertBulk) ClearWidth ¶
func (u *AttachmentUpsertBulk) ClearWidth() *AttachmentUpsertBulk
ClearWidth clears the value of the "width" field.
func (*AttachmentUpsertBulk) DoNothing ¶
func (u *AttachmentUpsertBulk) DoNothing() *AttachmentUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*AttachmentUpsertBulk) Exec ¶
func (u *AttachmentUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*AttachmentUpsertBulk) ExecX ¶
func (u *AttachmentUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentUpsertBulk) Ignore ¶
func (u *AttachmentUpsertBulk) Ignore() *AttachmentUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Attachment.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*AttachmentUpsertBulk) SetBlurhash ¶
func (u *AttachmentUpsertBulk) SetBlurhash(v string) *AttachmentUpsertBulk
SetBlurhash sets the "blurhash" field.
func (*AttachmentUpsertBulk) SetDescription ¶
func (u *AttachmentUpsertBulk) SetDescription(v string) *AttachmentUpsertBulk
SetDescription sets the "description" field.
func (*AttachmentUpsertBulk) SetExtensions ¶
func (u *AttachmentUpsertBulk) SetExtensions(v versia.Extensions) *AttachmentUpsertBulk
SetExtensions sets the "extensions" field.
func (*AttachmentUpsertBulk) SetFps ¶
func (u *AttachmentUpsertBulk) SetFps(v int) *AttachmentUpsertBulk
SetFps sets the "fps" field.
func (*AttachmentUpsertBulk) SetHeight ¶
func (u *AttachmentUpsertBulk) SetHeight(v int) *AttachmentUpsertBulk
SetHeight sets the "height" field.
func (*AttachmentUpsertBulk) SetIsRemote ¶
func (u *AttachmentUpsertBulk) SetIsRemote(v bool) *AttachmentUpsertBulk
SetIsRemote sets the "isRemote" field.
func (*AttachmentUpsertBulk) SetMimeType ¶
func (u *AttachmentUpsertBulk) SetMimeType(v string) *AttachmentUpsertBulk
SetMimeType sets the "mimeType" field.
func (*AttachmentUpsertBulk) SetSha256 ¶
func (u *AttachmentUpsertBulk) SetSha256(v []byte) *AttachmentUpsertBulk
SetSha256 sets the "sha256" field.
func (*AttachmentUpsertBulk) SetSize ¶
func (u *AttachmentUpsertBulk) SetSize(v int) *AttachmentUpsertBulk
SetSize sets the "size" field.
func (*AttachmentUpsertBulk) SetURI ¶
func (u *AttachmentUpsertBulk) SetURI(v string) *AttachmentUpsertBulk
SetURI sets the "uri" field.
func (*AttachmentUpsertBulk) SetUpdatedAt ¶
func (u *AttachmentUpsertBulk) SetUpdatedAt(v time.Time) *AttachmentUpsertBulk
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentUpsertBulk) SetWidth ¶
func (u *AttachmentUpsertBulk) SetWidth(v int) *AttachmentUpsertBulk
SetWidth sets the "width" field.
func (*AttachmentUpsertBulk) Update ¶
func (u *AttachmentUpsertBulk) Update(set func(*AttachmentUpsert)) *AttachmentUpsertBulk
Update allows overriding fields `UPDATE` values. See the AttachmentCreateBulk.OnConflict documentation for more info.
func (*AttachmentUpsertBulk) UpdateBlurhash ¶
func (u *AttachmentUpsertBulk) UpdateBlurhash() *AttachmentUpsertBulk
UpdateBlurhash sets the "blurhash" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateDescription ¶
func (u *AttachmentUpsertBulk) UpdateDescription() *AttachmentUpsertBulk
UpdateDescription sets the "description" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateExtensions ¶
func (u *AttachmentUpsertBulk) UpdateExtensions() *AttachmentUpsertBulk
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateFps ¶
func (u *AttachmentUpsertBulk) UpdateFps() *AttachmentUpsertBulk
UpdateFps sets the "fps" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateHeight ¶
func (u *AttachmentUpsertBulk) UpdateHeight() *AttachmentUpsertBulk
UpdateHeight sets the "height" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateIsRemote ¶
func (u *AttachmentUpsertBulk) UpdateIsRemote() *AttachmentUpsertBulk
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateMimeType ¶
func (u *AttachmentUpsertBulk) UpdateMimeType() *AttachmentUpsertBulk
UpdateMimeType sets the "mimeType" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateNewValues ¶
func (u *AttachmentUpsertBulk) UpdateNewValues() *AttachmentUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Attachment.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(attachment.FieldID) }), ). Exec(ctx)
func (*AttachmentUpsertBulk) UpdateSha256 ¶
func (u *AttachmentUpsertBulk) UpdateSha256() *AttachmentUpsertBulk
UpdateSha256 sets the "sha256" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateSize ¶
func (u *AttachmentUpsertBulk) UpdateSize() *AttachmentUpsertBulk
UpdateSize sets the "size" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateURI ¶
func (u *AttachmentUpsertBulk) UpdateURI() *AttachmentUpsertBulk
UpdateURI sets the "uri" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateUpdatedAt ¶
func (u *AttachmentUpsertBulk) UpdateUpdatedAt() *AttachmentUpsertBulk
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*AttachmentUpsertBulk) UpdateWidth ¶
func (u *AttachmentUpsertBulk) UpdateWidth() *AttachmentUpsertBulk
UpdateWidth sets the "width" field to the value that was provided on create.
type AttachmentUpsertOne ¶
type AttachmentUpsertOne struct {
// contains filtered or unexported fields
}
AttachmentUpsertOne is the builder for "upsert"-ing
one Attachment node.
func (*AttachmentUpsertOne) AddFps ¶
func (u *AttachmentUpsertOne) AddFps(v int) *AttachmentUpsertOne
AddFps adds v to the "fps" field.
func (*AttachmentUpsertOne) AddHeight ¶
func (u *AttachmentUpsertOne) AddHeight(v int) *AttachmentUpsertOne
AddHeight adds v to the "height" field.
func (*AttachmentUpsertOne) AddSize ¶
func (u *AttachmentUpsertOne) AddSize(v int) *AttachmentUpsertOne
AddSize adds v to the "size" field.
func (*AttachmentUpsertOne) AddWidth ¶
func (u *AttachmentUpsertOne) AddWidth(v int) *AttachmentUpsertOne
AddWidth adds v to the "width" field.
func (*AttachmentUpsertOne) ClearBlurhash ¶
func (u *AttachmentUpsertOne) ClearBlurhash() *AttachmentUpsertOne
ClearBlurhash clears the value of the "blurhash" field.
func (*AttachmentUpsertOne) ClearFps ¶
func (u *AttachmentUpsertOne) ClearFps() *AttachmentUpsertOne
ClearFps clears the value of the "fps" field.
func (*AttachmentUpsertOne) ClearHeight ¶
func (u *AttachmentUpsertOne) ClearHeight() *AttachmentUpsertOne
ClearHeight clears the value of the "height" field.
func (*AttachmentUpsertOne) ClearWidth ¶
func (u *AttachmentUpsertOne) ClearWidth() *AttachmentUpsertOne
ClearWidth clears the value of the "width" field.
func (*AttachmentUpsertOne) DoNothing ¶
func (u *AttachmentUpsertOne) DoNothing() *AttachmentUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*AttachmentUpsertOne) Exec ¶
func (u *AttachmentUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*AttachmentUpsertOne) ExecX ¶
func (u *AttachmentUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AttachmentUpsertOne) ID ¶
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*AttachmentUpsertOne) IDX ¶
func (u *AttachmentUpsertOne) IDX(ctx context.Context) uuid.UUID
IDX is like ID, but panics if an error occurs.
func (*AttachmentUpsertOne) Ignore ¶
func (u *AttachmentUpsertOne) Ignore() *AttachmentUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Attachment.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*AttachmentUpsertOne) SetBlurhash ¶
func (u *AttachmentUpsertOne) SetBlurhash(v string) *AttachmentUpsertOne
SetBlurhash sets the "blurhash" field.
func (*AttachmentUpsertOne) SetDescription ¶
func (u *AttachmentUpsertOne) SetDescription(v string) *AttachmentUpsertOne
SetDescription sets the "description" field.
func (*AttachmentUpsertOne) SetExtensions ¶
func (u *AttachmentUpsertOne) SetExtensions(v versia.Extensions) *AttachmentUpsertOne
SetExtensions sets the "extensions" field.
func (*AttachmentUpsertOne) SetFps ¶
func (u *AttachmentUpsertOne) SetFps(v int) *AttachmentUpsertOne
SetFps sets the "fps" field.
func (*AttachmentUpsertOne) SetHeight ¶
func (u *AttachmentUpsertOne) SetHeight(v int) *AttachmentUpsertOne
SetHeight sets the "height" field.
func (*AttachmentUpsertOne) SetIsRemote ¶
func (u *AttachmentUpsertOne) SetIsRemote(v bool) *AttachmentUpsertOne
SetIsRemote sets the "isRemote" field.
func (*AttachmentUpsertOne) SetMimeType ¶
func (u *AttachmentUpsertOne) SetMimeType(v string) *AttachmentUpsertOne
SetMimeType sets the "mimeType" field.
func (*AttachmentUpsertOne) SetSha256 ¶
func (u *AttachmentUpsertOne) SetSha256(v []byte) *AttachmentUpsertOne
SetSha256 sets the "sha256" field.
func (*AttachmentUpsertOne) SetSize ¶
func (u *AttachmentUpsertOne) SetSize(v int) *AttachmentUpsertOne
SetSize sets the "size" field.
func (*AttachmentUpsertOne) SetURI ¶
func (u *AttachmentUpsertOne) SetURI(v string) *AttachmentUpsertOne
SetURI sets the "uri" field.
func (*AttachmentUpsertOne) SetUpdatedAt ¶
func (u *AttachmentUpsertOne) SetUpdatedAt(v time.Time) *AttachmentUpsertOne
SetUpdatedAt sets the "updated_at" field.
func (*AttachmentUpsertOne) SetWidth ¶
func (u *AttachmentUpsertOne) SetWidth(v int) *AttachmentUpsertOne
SetWidth sets the "width" field.
func (*AttachmentUpsertOne) Update ¶
func (u *AttachmentUpsertOne) Update(set func(*AttachmentUpsert)) *AttachmentUpsertOne
Update allows overriding fields `UPDATE` values. See the AttachmentCreate.OnConflict documentation for more info.
func (*AttachmentUpsertOne) UpdateBlurhash ¶
func (u *AttachmentUpsertOne) UpdateBlurhash() *AttachmentUpsertOne
UpdateBlurhash sets the "blurhash" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateDescription ¶
func (u *AttachmentUpsertOne) UpdateDescription() *AttachmentUpsertOne
UpdateDescription sets the "description" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateExtensions ¶
func (u *AttachmentUpsertOne) UpdateExtensions() *AttachmentUpsertOne
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateFps ¶
func (u *AttachmentUpsertOne) UpdateFps() *AttachmentUpsertOne
UpdateFps sets the "fps" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateHeight ¶
func (u *AttachmentUpsertOne) UpdateHeight() *AttachmentUpsertOne
UpdateHeight sets the "height" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateIsRemote ¶
func (u *AttachmentUpsertOne) UpdateIsRemote() *AttachmentUpsertOne
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateMimeType ¶
func (u *AttachmentUpsertOne) UpdateMimeType() *AttachmentUpsertOne
UpdateMimeType sets the "mimeType" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateNewValues ¶
func (u *AttachmentUpsertOne) UpdateNewValues() *AttachmentUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:
client.Attachment.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(attachment.FieldID) }), ). Exec(ctx)
func (*AttachmentUpsertOne) UpdateSha256 ¶
func (u *AttachmentUpsertOne) UpdateSha256() *AttachmentUpsertOne
UpdateSha256 sets the "sha256" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateSize ¶
func (u *AttachmentUpsertOne) UpdateSize() *AttachmentUpsertOne
UpdateSize sets the "size" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateURI ¶
func (u *AttachmentUpsertOne) UpdateURI() *AttachmentUpsertOne
UpdateURI sets the "uri" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateUpdatedAt ¶
func (u *AttachmentUpsertOne) UpdateUpdatedAt() *AttachmentUpsertOne
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*AttachmentUpsertOne) UpdateWidth ¶
func (u *AttachmentUpsertOne) UpdateWidth() *AttachmentUpsertOne
UpdateWidth sets the "width" field to the value that was provided on create.
type Client ¶
type Client struct { // Schema is the client for creating, migrating and dropping schema. Schema *migrate.Schema // Attachment is the client for interacting with the Attachment builders. Attachment *AttachmentClient // Follow is the client for interacting with the Follow builders. Follow *FollowClient // Image is the client for interacting with the Image builders. Image *ImageClient // InstanceMetadata is the client for interacting with the InstanceMetadata builders. InstanceMetadata *InstanceMetadataClient // Note is the client for interacting with the Note builders. Note *NoteClient // User is the client for interacting with the User builders. User *UserClient // contains filtered or unexported fields }
Client is the client that holds all ent builders.
func FromContext ¶
FromContext returns a Client stored inside a context, or nil if there isn't one.
func Open ¶
Open opens a database/sql.DB specified by the driver name and the data source name, and returns a new client attached to it. Optional parameters can be added for configuring the client.
func (*Client) Debug ¶
Debug returns a new debug-client. It's used to get verbose logging on specific operations.
client.Debug(). Attachment. Query(). Count(ctx)
func (*Client) Intercept ¶
func (c *Client) Intercept(interceptors ...Interceptor)
Intercept adds the query interceptors to all the entity clients. In order to add interceptors to a specific client, call: `client.Node.Intercept(...)`.
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 Follow ¶
type Follow struct { // ID of the ent. ID uuid.UUID `json:"id,omitempty"` // IsRemote holds the value of the "isRemote" field. IsRemote bool `json:"isRemote,omitempty"` // URI holds the value of the "uri" field. URI string `json:"uri,omitempty"` // Extensions holds the value of the "extensions" field. Extensions versia.Extensions `json:"extensions,omitempty"` // CreatedAt holds the value of the "created_at" field. CreatedAt time.Time `json:"created_at,omitempty"` // UpdatedAt holds the value of the "updated_at" field. UpdatedAt time.Time `json:"updated_at,omitempty"` // Status holds the value of the "status" field. Status follow.Status `json:"status,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the FollowQuery when eager-loading is set. Edges FollowEdges `json:"edges"` // contains filtered or unexported fields }
Follow is the model entity for the Follow schema.
func (*Follow) QueryFollowee ¶
QueryFollowee queries the "followee" edge of the Follow entity.
func (*Follow) QueryFollower ¶
QueryFollower queries the "follower" edge of the Follow entity.
func (*Follow) Unwrap ¶
Unwrap unwraps the Follow 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 (*Follow) Update ¶
func (f *Follow) Update() *FollowUpdateOne
Update returns a builder for updating this Follow. Note that you need to call Follow.Unwrap() before calling this method if this Follow was returned from a transaction, and the transaction was committed or rolled back.
type FollowClient ¶
type FollowClient struct {
// contains filtered or unexported fields
}
FollowClient is a client for the Follow schema.
func NewFollowClient ¶
func NewFollowClient(c config) *FollowClient
NewFollowClient returns a client for the Follow from the given config.
func (*FollowClient) Create ¶
func (c *FollowClient) Create() *FollowCreate
Create returns a builder for creating a Follow entity.
func (*FollowClient) CreateBulk ¶
func (c *FollowClient) CreateBulk(builders ...*FollowCreate) *FollowCreateBulk
CreateBulk returns a builder for creating a bulk of Follow entities.
func (*FollowClient) Delete ¶
func (c *FollowClient) Delete() *FollowDelete
Delete returns a delete builder for Follow.
func (*FollowClient) DeleteOne ¶
func (c *FollowClient) DeleteOne(f *Follow) *FollowDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*FollowClient) DeleteOneID ¶
func (c *FollowClient) DeleteOneID(id uuid.UUID) *FollowDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*FollowClient) Intercept ¶
func (c *FollowClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `follow.Intercept(f(g(h())))`.
func (*FollowClient) Interceptors ¶
func (c *FollowClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*FollowClient) MapCreateBulk ¶
func (c *FollowClient) MapCreateBulk(slice any, setFunc func(*FollowCreate, int)) *FollowCreateBulk
MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.
func (*FollowClient) Query ¶
func (c *FollowClient) Query() *FollowQuery
Query returns a query builder for Follow.
func (*FollowClient) QueryFollowee ¶
func (c *FollowClient) QueryFollowee(f *Follow) *UserQuery
QueryFollowee queries the followee edge of a Follow.
func (*FollowClient) QueryFollower ¶
func (c *FollowClient) QueryFollower(f *Follow) *UserQuery
QueryFollower queries the follower edge of a Follow.
func (*FollowClient) Update ¶
func (c *FollowClient) Update() *FollowUpdate
Update returns an update builder for Follow.
func (*FollowClient) UpdateOne ¶
func (c *FollowClient) UpdateOne(f *Follow) *FollowUpdateOne
UpdateOne returns an update builder for the given entity.
func (*FollowClient) UpdateOneID ¶
func (c *FollowClient) UpdateOneID(id uuid.UUID) *FollowUpdateOne
UpdateOneID returns an update builder for the given id.
func (*FollowClient) Use ¶
func (c *FollowClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `follow.Hooks(f(g(h())))`.
type FollowCreate ¶
type FollowCreate struct {
// contains filtered or unexported fields
}
FollowCreate is the builder for creating a Follow entity.
func (*FollowCreate) Exec ¶
func (fc *FollowCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*FollowCreate) ExecX ¶
func (fc *FollowCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowCreate) Mutation ¶
func (fc *FollowCreate) Mutation() *FollowMutation
Mutation returns the FollowMutation object of the builder.
func (*FollowCreate) OnConflict ¶
func (fc *FollowCreate) OnConflict(opts ...sql.ConflictOption) *FollowUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Follow.Create(). SetIsRemote(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.FollowUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*FollowCreate) OnConflictColumns ¶
func (fc *FollowCreate) OnConflictColumns(columns ...string) *FollowUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Follow.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*FollowCreate) Save ¶
func (fc *FollowCreate) Save(ctx context.Context) (*Follow, error)
Save creates the Follow in the database.
func (*FollowCreate) SaveX ¶
func (fc *FollowCreate) SaveX(ctx context.Context) *Follow
SaveX calls Save and panics if Save returns an error.
func (*FollowCreate) SetCreatedAt ¶
func (fc *FollowCreate) SetCreatedAt(t time.Time) *FollowCreate
SetCreatedAt sets the "created_at" field.
func (*FollowCreate) SetExtensions ¶
func (fc *FollowCreate) SetExtensions(v versia.Extensions) *FollowCreate
SetExtensions sets the "extensions" field.
func (*FollowCreate) SetFollowee ¶
func (fc *FollowCreate) SetFollowee(u *User) *FollowCreate
SetFollowee sets the "followee" edge to the User entity.
func (*FollowCreate) SetFolloweeID ¶
func (fc *FollowCreate) SetFolloweeID(id uuid.UUID) *FollowCreate
SetFolloweeID sets the "followee" edge to the User entity by ID.
func (*FollowCreate) SetFollower ¶
func (fc *FollowCreate) SetFollower(u *User) *FollowCreate
SetFollower sets the "follower" edge to the User entity.
func (*FollowCreate) SetFollowerID ¶
func (fc *FollowCreate) SetFollowerID(id uuid.UUID) *FollowCreate
SetFollowerID sets the "follower" edge to the User entity by ID.
func (*FollowCreate) SetID ¶
func (fc *FollowCreate) SetID(u uuid.UUID) *FollowCreate
SetID sets the "id" field.
func (*FollowCreate) SetIsRemote ¶
func (fc *FollowCreate) SetIsRemote(b bool) *FollowCreate
SetIsRemote sets the "isRemote" field.
func (*FollowCreate) SetNillableCreatedAt ¶
func (fc *FollowCreate) SetNillableCreatedAt(t *time.Time) *FollowCreate
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*FollowCreate) SetNillableID ¶
func (fc *FollowCreate) SetNillableID(u *uuid.UUID) *FollowCreate
SetNillableID sets the "id" field if the given value is not nil.
func (*FollowCreate) SetNillableStatus ¶
func (fc *FollowCreate) SetNillableStatus(f *follow.Status) *FollowCreate
SetNillableStatus sets the "status" field if the given value is not nil.
func (*FollowCreate) SetNillableUpdatedAt ¶
func (fc *FollowCreate) SetNillableUpdatedAt(t *time.Time) *FollowCreate
SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.
func (*FollowCreate) SetStatus ¶
func (fc *FollowCreate) SetStatus(f follow.Status) *FollowCreate
SetStatus sets the "status" field.
func (*FollowCreate) SetURI ¶
func (fc *FollowCreate) SetURI(s string) *FollowCreate
SetURI sets the "uri" field.
func (*FollowCreate) SetUpdatedAt ¶
func (fc *FollowCreate) SetUpdatedAt(t time.Time) *FollowCreate
SetUpdatedAt sets the "updated_at" field.
type FollowCreateBulk ¶
type FollowCreateBulk struct {
// contains filtered or unexported fields
}
FollowCreateBulk is the builder for creating many Follow entities in bulk.
func (*FollowCreateBulk) Exec ¶
func (fcb *FollowCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*FollowCreateBulk) ExecX ¶
func (fcb *FollowCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowCreateBulk) OnConflict ¶
func (fcb *FollowCreateBulk) OnConflict(opts ...sql.ConflictOption) *FollowUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Follow.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.FollowUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*FollowCreateBulk) OnConflictColumns ¶
func (fcb *FollowCreateBulk) OnConflictColumns(columns ...string) *FollowUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Follow.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type FollowDelete ¶
type FollowDelete struct {
// contains filtered or unexported fields
}
FollowDelete is the builder for deleting a Follow entity.
func (*FollowDelete) Exec ¶
func (fd *FollowDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*FollowDelete) ExecX ¶
func (fd *FollowDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*FollowDelete) Where ¶
func (fd *FollowDelete) Where(ps ...predicate.Follow) *FollowDelete
Where appends a list predicates to the FollowDelete builder.
type FollowDeleteOne ¶
type FollowDeleteOne struct {
// contains filtered or unexported fields
}
FollowDeleteOne is the builder for deleting a single Follow entity.
func (*FollowDeleteOne) Exec ¶
func (fdo *FollowDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*FollowDeleteOne) ExecX ¶
func (fdo *FollowDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowDeleteOne) Where ¶
func (fdo *FollowDeleteOne) Where(ps ...predicate.Follow) *FollowDeleteOne
Where appends a list predicates to the FollowDelete builder.
type FollowEdges ¶
type FollowEdges struct { // Follower holds the value of the follower edge. Follower *User `json:"follower,omitempty"` // Followee holds the value of the followee edge. Followee *User `json:"followee,omitempty"` // contains filtered or unexported fields }
FollowEdges holds the relations/edges for other nodes in the graph.
func (FollowEdges) FolloweeOrErr ¶
func (e FollowEdges) FolloweeOrErr() (*User, error)
FolloweeOrErr returns the Followee value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (FollowEdges) FollowerOrErr ¶
func (e FollowEdges) FollowerOrErr() (*User, error)
FollowerOrErr returns the Follower value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type FollowGroupBy ¶
type FollowGroupBy struct {
// contains filtered or unexported fields
}
FollowGroupBy is the group-by builder for Follow entities.
func (*FollowGroupBy) Aggregate ¶
func (fgb *FollowGroupBy) Aggregate(fns ...AggregateFunc) *FollowGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*FollowGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*FollowGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*FollowGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*FollowGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*FollowGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*FollowGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*FollowGroupBy) Scan ¶
func (fgb *FollowGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*FollowGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type FollowMutation ¶
type FollowMutation struct {
// contains filtered or unexported fields
}
FollowMutation represents an operation that mutates the Follow nodes in the graph.
func (*FollowMutation) AddField ¶
func (m *FollowMutation) 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 (*FollowMutation) AddedEdges ¶
func (m *FollowMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*FollowMutation) AddedField ¶
func (m *FollowMutation) 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 (*FollowMutation) AddedFields ¶
func (m *FollowMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*FollowMutation) AddedIDs ¶
func (m *FollowMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*FollowMutation) ClearEdge ¶
func (m *FollowMutation) 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 (*FollowMutation) ClearField ¶
func (m *FollowMutation) 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 (*FollowMutation) ClearFollowee ¶
func (m *FollowMutation) ClearFollowee()
ClearFollowee clears the "followee" edge to the User entity.
func (*FollowMutation) ClearFollower ¶
func (m *FollowMutation) ClearFollower()
ClearFollower clears the "follower" edge to the User entity.
func (*FollowMutation) ClearedEdges ¶
func (m *FollowMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*FollowMutation) ClearedFields ¶
func (m *FollowMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (FollowMutation) Client ¶
func (m FollowMutation) 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 (*FollowMutation) CreatedAt ¶
func (m *FollowMutation) CreatedAt() (r time.Time, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*FollowMutation) EdgeCleared ¶
func (m *FollowMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*FollowMutation) Extensions ¶
func (m *FollowMutation) Extensions() (r versia.Extensions, exists bool)
Extensions returns the value of the "extensions" field in the mutation.
func (*FollowMutation) Field ¶
func (m *FollowMutation) 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 (*FollowMutation) FieldCleared ¶
func (m *FollowMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*FollowMutation) Fields ¶
func (m *FollowMutation) 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 (*FollowMutation) FolloweeCleared ¶
func (m *FollowMutation) FolloweeCleared() bool
FolloweeCleared reports if the "followee" edge to the User entity was cleared.
func (*FollowMutation) FolloweeID ¶
func (m *FollowMutation) FolloweeID() (id uuid.UUID, exists bool)
FolloweeID returns the "followee" edge ID in the mutation.
func (*FollowMutation) FolloweeIDs ¶
func (m *FollowMutation) FolloweeIDs() (ids []uuid.UUID)
FolloweeIDs returns the "followee" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use FolloweeID instead. It exists only for internal usage by the builders.
func (*FollowMutation) FollowerCleared ¶
func (m *FollowMutation) FollowerCleared() bool
FollowerCleared reports if the "follower" edge to the User entity was cleared.
func (*FollowMutation) FollowerID ¶
func (m *FollowMutation) FollowerID() (id uuid.UUID, exists bool)
FollowerID returns the "follower" edge ID in the mutation.
func (*FollowMutation) FollowerIDs ¶
func (m *FollowMutation) FollowerIDs() (ids []uuid.UUID)
FollowerIDs returns the "follower" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use FollowerID instead. It exists only for internal usage by the builders.
func (*FollowMutation) ID ¶
func (m *FollowMutation) ID() (id uuid.UUID, 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 (*FollowMutation) IDs ¶
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 (*FollowMutation) IsRemote ¶
func (m *FollowMutation) IsRemote() (r bool, exists bool)
IsRemote returns the value of the "isRemote" field in the mutation.
func (*FollowMutation) OldCreatedAt ¶
OldCreatedAt returns the old "created_at" field's value of the Follow entity. If the Follow 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 (*FollowMutation) OldExtensions ¶
func (m *FollowMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
OldExtensions returns the old "extensions" field's value of the Follow entity. If the Follow 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 (*FollowMutation) 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 (*FollowMutation) OldIsRemote ¶
func (m *FollowMutation) OldIsRemote(ctx context.Context) (v bool, err error)
OldIsRemote returns the old "isRemote" field's value of the Follow entity. If the Follow 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 (*FollowMutation) OldStatus ¶
OldStatus returns the old "status" field's value of the Follow entity. If the Follow 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 (*FollowMutation) OldURI ¶
func (m *FollowMutation) OldURI(ctx context.Context) (v string, err error)
OldURI returns the old "uri" field's value of the Follow entity. If the Follow 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 (*FollowMutation) OldUpdatedAt ¶
OldUpdatedAt returns the old "updated_at" field's value of the Follow entity. If the Follow 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 (*FollowMutation) RemovedEdges ¶
func (m *FollowMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*FollowMutation) RemovedIDs ¶
func (m *FollowMutation) 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 (*FollowMutation) ResetCreatedAt ¶
func (m *FollowMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*FollowMutation) ResetEdge ¶
func (m *FollowMutation) 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 (*FollowMutation) ResetExtensions ¶
func (m *FollowMutation) ResetExtensions()
ResetExtensions resets all changes to the "extensions" field.
func (*FollowMutation) ResetField ¶
func (m *FollowMutation) 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 (*FollowMutation) ResetFollowee ¶
func (m *FollowMutation) ResetFollowee()
ResetFollowee resets all changes to the "followee" edge.
func (*FollowMutation) ResetFollower ¶
func (m *FollowMutation) ResetFollower()
ResetFollower resets all changes to the "follower" edge.
func (*FollowMutation) ResetIsRemote ¶
func (m *FollowMutation) ResetIsRemote()
ResetIsRemote resets all changes to the "isRemote" field.
func (*FollowMutation) ResetStatus ¶
func (m *FollowMutation) ResetStatus()
ResetStatus resets all changes to the "status" field.
func (*FollowMutation) ResetURI ¶
func (m *FollowMutation) ResetURI()
ResetURI resets all changes to the "uri" field.
func (*FollowMutation) ResetUpdatedAt ¶
func (m *FollowMutation) ResetUpdatedAt()
ResetUpdatedAt resets all changes to the "updated_at" field.
func (*FollowMutation) SetCreatedAt ¶
func (m *FollowMutation) SetCreatedAt(t time.Time)
SetCreatedAt sets the "created_at" field.
func (*FollowMutation) SetExtensions ¶
func (m *FollowMutation) SetExtensions(v versia.Extensions)
SetExtensions sets the "extensions" field.
func (*FollowMutation) SetField ¶
func (m *FollowMutation) 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 (*FollowMutation) SetFolloweeID ¶
func (m *FollowMutation) SetFolloweeID(id uuid.UUID)
SetFolloweeID sets the "followee" edge to the User entity by id.
func (*FollowMutation) SetFollowerID ¶
func (m *FollowMutation) SetFollowerID(id uuid.UUID)
SetFollowerID sets the "follower" edge to the User entity by id.
func (*FollowMutation) SetID ¶
func (m *FollowMutation) SetID(id uuid.UUID)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Follow entities.
func (*FollowMutation) SetIsRemote ¶
func (m *FollowMutation) SetIsRemote(b bool)
SetIsRemote sets the "isRemote" field.
func (*FollowMutation) SetOp ¶
func (m *FollowMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*FollowMutation) SetStatus ¶
func (m *FollowMutation) SetStatus(f follow.Status)
SetStatus sets the "status" field.
func (*FollowMutation) SetURI ¶
func (m *FollowMutation) SetURI(s string)
SetURI sets the "uri" field.
func (*FollowMutation) SetUpdatedAt ¶
func (m *FollowMutation) SetUpdatedAt(t time.Time)
SetUpdatedAt sets the "updated_at" field.
func (*FollowMutation) Status ¶
func (m *FollowMutation) Status() (r follow.Status, exists bool)
Status returns the value of the "status" field in the mutation.
func (FollowMutation) Tx ¶
func (m FollowMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*FollowMutation) Type ¶
func (m *FollowMutation) Type() string
Type returns the node type of this mutation (Follow).
func (*FollowMutation) URI ¶
func (m *FollowMutation) URI() (r string, exists bool)
URI returns the value of the "uri" field in the mutation.
func (*FollowMutation) UpdatedAt ¶
func (m *FollowMutation) UpdatedAt() (r time.Time, exists bool)
UpdatedAt returns the value of the "updated_at" field in the mutation.
func (*FollowMutation) Where ¶
func (m *FollowMutation) Where(ps ...predicate.Follow)
Where appends a list predicates to the FollowMutation builder.
func (*FollowMutation) WhereP ¶
func (m *FollowMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the FollowMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type FollowQuery ¶
type FollowQuery struct {
// contains filtered or unexported fields
}
FollowQuery is the builder for querying Follow entities.
func (*FollowQuery) Aggregate ¶
func (fq *FollowQuery) Aggregate(fns ...AggregateFunc) *FollowSelect
Aggregate returns a FollowSelect configured with the given aggregations.
func (*FollowQuery) All ¶
func (fq *FollowQuery) All(ctx context.Context) ([]*Follow, error)
All executes the query and returns a list of Follows.
func (*FollowQuery) AllX ¶
func (fq *FollowQuery) AllX(ctx context.Context) []*Follow
AllX is like All, but panics if an error occurs.
func (*FollowQuery) Clone ¶
func (fq *FollowQuery) Clone() *FollowQuery
Clone returns a duplicate of the FollowQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*FollowQuery) Count ¶
func (fq *FollowQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*FollowQuery) CountX ¶
func (fq *FollowQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*FollowQuery) Exist ¶
func (fq *FollowQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*FollowQuery) ExistX ¶
func (fq *FollowQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*FollowQuery) First ¶
func (fq *FollowQuery) First(ctx context.Context) (*Follow, error)
First returns the first Follow entity from the query. Returns a *NotFoundError when no Follow was found.
func (*FollowQuery) FirstID ¶
FirstID returns the first Follow ID from the query. Returns a *NotFoundError when no Follow ID was found.
func (*FollowQuery) FirstIDX ¶
func (fq *FollowQuery) FirstIDX(ctx context.Context) uuid.UUID
FirstIDX is like FirstID, but panics if an error occurs.
func (*FollowQuery) FirstX ¶
func (fq *FollowQuery) FirstX(ctx context.Context) *Follow
FirstX is like First, but panics if an error occurs.
func (*FollowQuery) GroupBy ¶
func (fq *FollowQuery) GroupBy(field string, fields ...string) *FollowGroupBy
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 { IsRemote bool `json:"isRemote,omitempty"` Count int `json:"count,omitempty"` } client.Follow.Query(). GroupBy(follow.FieldIsRemote). Aggregate(ent.Count()). Scan(ctx, &v)
func (*FollowQuery) IDsX ¶
func (fq *FollowQuery) IDsX(ctx context.Context) []uuid.UUID
IDsX is like IDs, but panics if an error occurs.
func (*FollowQuery) Limit ¶
func (fq *FollowQuery) Limit(limit int) *FollowQuery
Limit the number of records to be returned by this query.
func (*FollowQuery) Offset ¶
func (fq *FollowQuery) Offset(offset int) *FollowQuery
Offset to start from.
func (*FollowQuery) Only ¶
func (fq *FollowQuery) Only(ctx context.Context) (*Follow, error)
Only returns a single Follow entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Follow entity is found. Returns a *NotFoundError when no Follow entities are found.
func (*FollowQuery) OnlyID ¶
OnlyID is like Only, but returns the only Follow ID in the query. Returns a *NotSingularError when more than one Follow ID is found. Returns a *NotFoundError when no entities are found.
func (*FollowQuery) OnlyIDX ¶
func (fq *FollowQuery) OnlyIDX(ctx context.Context) uuid.UUID
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*FollowQuery) OnlyX ¶
func (fq *FollowQuery) OnlyX(ctx context.Context) *Follow
OnlyX is like Only, but panics if an error occurs.
func (*FollowQuery) Order ¶
func (fq *FollowQuery) Order(o ...follow.OrderOption) *FollowQuery
Order specifies how the records should be ordered.
func (*FollowQuery) QueryFollowee ¶
func (fq *FollowQuery) QueryFollowee() *UserQuery
QueryFollowee chains the current query on the "followee" edge.
func (*FollowQuery) QueryFollower ¶
func (fq *FollowQuery) QueryFollower() *UserQuery
QueryFollower chains the current query on the "follower" edge.
func (*FollowQuery) Select ¶
func (fq *FollowQuery) Select(fields ...string) *FollowSelect
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 { IsRemote bool `json:"isRemote,omitempty"` } client.Follow.Query(). Select(follow.FieldIsRemote). Scan(ctx, &v)
func (*FollowQuery) Unique ¶
func (fq *FollowQuery) Unique(unique bool) *FollowQuery
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 (*FollowQuery) Where ¶
func (fq *FollowQuery) Where(ps ...predicate.Follow) *FollowQuery
Where adds a new predicate for the FollowQuery builder.
func (*FollowQuery) WithFollowee ¶
func (fq *FollowQuery) WithFollowee(opts ...func(*UserQuery)) *FollowQuery
WithFollowee tells the query-builder to eager-load the nodes that are connected to the "followee" edge. The optional arguments are used to configure the query builder of the edge.
func (*FollowQuery) WithFollower ¶
func (fq *FollowQuery) WithFollower(opts ...func(*UserQuery)) *FollowQuery
WithFollower tells the query-builder to eager-load the nodes that are connected to the "follower" edge. The optional arguments are used to configure the query builder of the edge.
type FollowSelect ¶
type FollowSelect struct { *FollowQuery // contains filtered or unexported fields }
FollowSelect is the builder for selecting fields of Follow entities.
func (*FollowSelect) Aggregate ¶
func (fs *FollowSelect) Aggregate(fns ...AggregateFunc) *FollowSelect
Aggregate adds the given aggregation functions to the selector query.
func (*FollowSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*FollowSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*FollowSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*FollowSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*FollowSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*FollowSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*FollowSelect) Scan ¶
func (fs *FollowSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*FollowSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type FollowUpdate ¶
type FollowUpdate struct {
// contains filtered or unexported fields
}
FollowUpdate is the builder for updating Follow entities.
func (*FollowUpdate) ClearFollowee ¶
func (fu *FollowUpdate) ClearFollowee() *FollowUpdate
ClearFollowee clears the "followee" edge to the User entity.
func (*FollowUpdate) ClearFollower ¶
func (fu *FollowUpdate) ClearFollower() *FollowUpdate
ClearFollower clears the "follower" edge to the User entity.
func (*FollowUpdate) Exec ¶
func (fu *FollowUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*FollowUpdate) ExecX ¶
func (fu *FollowUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowUpdate) Mutation ¶
func (fu *FollowUpdate) Mutation() *FollowMutation
Mutation returns the FollowMutation object of the builder.
func (*FollowUpdate) Save ¶
func (fu *FollowUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*FollowUpdate) SaveX ¶
func (fu *FollowUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*FollowUpdate) SetExtensions ¶
func (fu *FollowUpdate) SetExtensions(v versia.Extensions) *FollowUpdate
SetExtensions sets the "extensions" field.
func (*FollowUpdate) SetFollowee ¶
func (fu *FollowUpdate) SetFollowee(u *User) *FollowUpdate
SetFollowee sets the "followee" edge to the User entity.
func (*FollowUpdate) SetFolloweeID ¶
func (fu *FollowUpdate) SetFolloweeID(id uuid.UUID) *FollowUpdate
SetFolloweeID sets the "followee" edge to the User entity by ID.
func (*FollowUpdate) SetFollower ¶
func (fu *FollowUpdate) SetFollower(u *User) *FollowUpdate
SetFollower sets the "follower" edge to the User entity.
func (*FollowUpdate) SetFollowerID ¶
func (fu *FollowUpdate) SetFollowerID(id uuid.UUID) *FollowUpdate
SetFollowerID sets the "follower" edge to the User entity by ID.
func (*FollowUpdate) SetIsRemote ¶
func (fu *FollowUpdate) SetIsRemote(b bool) *FollowUpdate
SetIsRemote sets the "isRemote" field.
func (*FollowUpdate) SetNillableIsRemote ¶
func (fu *FollowUpdate) SetNillableIsRemote(b *bool) *FollowUpdate
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*FollowUpdate) SetNillableStatus ¶
func (fu *FollowUpdate) SetNillableStatus(f *follow.Status) *FollowUpdate
SetNillableStatus sets the "status" field if the given value is not nil.
func (*FollowUpdate) SetNillableURI ¶
func (fu *FollowUpdate) SetNillableURI(s *string) *FollowUpdate
SetNillableURI sets the "uri" field if the given value is not nil.
func (*FollowUpdate) SetStatus ¶
func (fu *FollowUpdate) SetStatus(f follow.Status) *FollowUpdate
SetStatus sets the "status" field.
func (*FollowUpdate) SetURI ¶
func (fu *FollowUpdate) SetURI(s string) *FollowUpdate
SetURI sets the "uri" field.
func (*FollowUpdate) SetUpdatedAt ¶
func (fu *FollowUpdate) SetUpdatedAt(t time.Time) *FollowUpdate
SetUpdatedAt sets the "updated_at" field.
func (*FollowUpdate) Where ¶
func (fu *FollowUpdate) Where(ps ...predicate.Follow) *FollowUpdate
Where appends a list predicates to the FollowUpdate builder.
type FollowUpdateOne ¶
type FollowUpdateOne struct {
// contains filtered or unexported fields
}
FollowUpdateOne is the builder for updating a single Follow entity.
func (*FollowUpdateOne) ClearFollowee ¶
func (fuo *FollowUpdateOne) ClearFollowee() *FollowUpdateOne
ClearFollowee clears the "followee" edge to the User entity.
func (*FollowUpdateOne) ClearFollower ¶
func (fuo *FollowUpdateOne) ClearFollower() *FollowUpdateOne
ClearFollower clears the "follower" edge to the User entity.
func (*FollowUpdateOne) Exec ¶
func (fuo *FollowUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*FollowUpdateOne) ExecX ¶
func (fuo *FollowUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowUpdateOne) Mutation ¶
func (fuo *FollowUpdateOne) Mutation() *FollowMutation
Mutation returns the FollowMutation object of the builder.
func (*FollowUpdateOne) Save ¶
func (fuo *FollowUpdateOne) Save(ctx context.Context) (*Follow, error)
Save executes the query and returns the updated Follow entity.
func (*FollowUpdateOne) SaveX ¶
func (fuo *FollowUpdateOne) SaveX(ctx context.Context) *Follow
SaveX is like Save, but panics if an error occurs.
func (*FollowUpdateOne) Select ¶
func (fuo *FollowUpdateOne) Select(field string, fields ...string) *FollowUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*FollowUpdateOne) SetExtensions ¶
func (fuo *FollowUpdateOne) SetExtensions(v versia.Extensions) *FollowUpdateOne
SetExtensions sets the "extensions" field.
func (*FollowUpdateOne) SetFollowee ¶
func (fuo *FollowUpdateOne) SetFollowee(u *User) *FollowUpdateOne
SetFollowee sets the "followee" edge to the User entity.
func (*FollowUpdateOne) SetFolloweeID ¶
func (fuo *FollowUpdateOne) SetFolloweeID(id uuid.UUID) *FollowUpdateOne
SetFolloweeID sets the "followee" edge to the User entity by ID.
func (*FollowUpdateOne) SetFollower ¶
func (fuo *FollowUpdateOne) SetFollower(u *User) *FollowUpdateOne
SetFollower sets the "follower" edge to the User entity.
func (*FollowUpdateOne) SetFollowerID ¶
func (fuo *FollowUpdateOne) SetFollowerID(id uuid.UUID) *FollowUpdateOne
SetFollowerID sets the "follower" edge to the User entity by ID.
func (*FollowUpdateOne) SetIsRemote ¶
func (fuo *FollowUpdateOne) SetIsRemote(b bool) *FollowUpdateOne
SetIsRemote sets the "isRemote" field.
func (*FollowUpdateOne) SetNillableIsRemote ¶
func (fuo *FollowUpdateOne) SetNillableIsRemote(b *bool) *FollowUpdateOne
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*FollowUpdateOne) SetNillableStatus ¶
func (fuo *FollowUpdateOne) SetNillableStatus(f *follow.Status) *FollowUpdateOne
SetNillableStatus sets the "status" field if the given value is not nil.
func (*FollowUpdateOne) SetNillableURI ¶
func (fuo *FollowUpdateOne) SetNillableURI(s *string) *FollowUpdateOne
SetNillableURI sets the "uri" field if the given value is not nil.
func (*FollowUpdateOne) SetStatus ¶
func (fuo *FollowUpdateOne) SetStatus(f follow.Status) *FollowUpdateOne
SetStatus sets the "status" field.
func (*FollowUpdateOne) SetURI ¶
func (fuo *FollowUpdateOne) SetURI(s string) *FollowUpdateOne
SetURI sets the "uri" field.
func (*FollowUpdateOne) SetUpdatedAt ¶
func (fuo *FollowUpdateOne) SetUpdatedAt(t time.Time) *FollowUpdateOne
SetUpdatedAt sets the "updated_at" field.
func (*FollowUpdateOne) Where ¶
func (fuo *FollowUpdateOne) Where(ps ...predicate.Follow) *FollowUpdateOne
Where appends a list predicates to the FollowUpdate builder.
type FollowUpsert ¶
FollowUpsert is the "OnConflict" setter.
func (*FollowUpsert) SetExtensions ¶
func (u *FollowUpsert) SetExtensions(v versia.Extensions) *FollowUpsert
SetExtensions sets the "extensions" field.
func (*FollowUpsert) SetIsRemote ¶
func (u *FollowUpsert) SetIsRemote(v bool) *FollowUpsert
SetIsRemote sets the "isRemote" field.
func (*FollowUpsert) SetStatus ¶
func (u *FollowUpsert) SetStatus(v follow.Status) *FollowUpsert
SetStatus sets the "status" field.
func (*FollowUpsert) SetURI ¶
func (u *FollowUpsert) SetURI(v string) *FollowUpsert
SetURI sets the "uri" field.
func (*FollowUpsert) SetUpdatedAt ¶
func (u *FollowUpsert) SetUpdatedAt(v time.Time) *FollowUpsert
SetUpdatedAt sets the "updated_at" field.
func (*FollowUpsert) UpdateExtensions ¶
func (u *FollowUpsert) UpdateExtensions() *FollowUpsert
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*FollowUpsert) UpdateIsRemote ¶
func (u *FollowUpsert) UpdateIsRemote() *FollowUpsert
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*FollowUpsert) UpdateStatus ¶
func (u *FollowUpsert) UpdateStatus() *FollowUpsert
UpdateStatus sets the "status" field to the value that was provided on create.
func (*FollowUpsert) UpdateURI ¶
func (u *FollowUpsert) UpdateURI() *FollowUpsert
UpdateURI sets the "uri" field to the value that was provided on create.
func (*FollowUpsert) UpdateUpdatedAt ¶
func (u *FollowUpsert) UpdateUpdatedAt() *FollowUpsert
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
type FollowUpsertBulk ¶
type FollowUpsertBulk struct {
// contains filtered or unexported fields
}
FollowUpsertBulk is the builder for "upsert"-ing a bulk of Follow nodes.
func (*FollowUpsertBulk) DoNothing ¶
func (u *FollowUpsertBulk) DoNothing() *FollowUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*FollowUpsertBulk) Exec ¶
func (u *FollowUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*FollowUpsertBulk) ExecX ¶
func (u *FollowUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowUpsertBulk) Ignore ¶
func (u *FollowUpsertBulk) Ignore() *FollowUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Follow.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*FollowUpsertBulk) SetExtensions ¶
func (u *FollowUpsertBulk) SetExtensions(v versia.Extensions) *FollowUpsertBulk
SetExtensions sets the "extensions" field.
func (*FollowUpsertBulk) SetIsRemote ¶
func (u *FollowUpsertBulk) SetIsRemote(v bool) *FollowUpsertBulk
SetIsRemote sets the "isRemote" field.
func (*FollowUpsertBulk) SetStatus ¶
func (u *FollowUpsertBulk) SetStatus(v follow.Status) *FollowUpsertBulk
SetStatus sets the "status" field.
func (*FollowUpsertBulk) SetURI ¶
func (u *FollowUpsertBulk) SetURI(v string) *FollowUpsertBulk
SetURI sets the "uri" field.
func (*FollowUpsertBulk) SetUpdatedAt ¶
func (u *FollowUpsertBulk) SetUpdatedAt(v time.Time) *FollowUpsertBulk
SetUpdatedAt sets the "updated_at" field.
func (*FollowUpsertBulk) Update ¶
func (u *FollowUpsertBulk) Update(set func(*FollowUpsert)) *FollowUpsertBulk
Update allows overriding fields `UPDATE` values. See the FollowCreateBulk.OnConflict documentation for more info.
func (*FollowUpsertBulk) UpdateExtensions ¶
func (u *FollowUpsertBulk) UpdateExtensions() *FollowUpsertBulk
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*FollowUpsertBulk) UpdateIsRemote ¶
func (u *FollowUpsertBulk) UpdateIsRemote() *FollowUpsertBulk
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*FollowUpsertBulk) UpdateNewValues ¶
func (u *FollowUpsertBulk) UpdateNewValues() *FollowUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Follow.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(follow.FieldID) }), ). Exec(ctx)
func (*FollowUpsertBulk) UpdateStatus ¶
func (u *FollowUpsertBulk) UpdateStatus() *FollowUpsertBulk
UpdateStatus sets the "status" field to the value that was provided on create.
func (*FollowUpsertBulk) UpdateURI ¶
func (u *FollowUpsertBulk) UpdateURI() *FollowUpsertBulk
UpdateURI sets the "uri" field to the value that was provided on create.
func (*FollowUpsertBulk) UpdateUpdatedAt ¶
func (u *FollowUpsertBulk) UpdateUpdatedAt() *FollowUpsertBulk
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
type FollowUpsertOne ¶
type FollowUpsertOne struct {
// contains filtered or unexported fields
}
FollowUpsertOne is the builder for "upsert"-ing
one Follow node.
func (*FollowUpsertOne) DoNothing ¶
func (u *FollowUpsertOne) DoNothing() *FollowUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*FollowUpsertOne) Exec ¶
func (u *FollowUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*FollowUpsertOne) ExecX ¶
func (u *FollowUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*FollowUpsertOne) IDX ¶
func (u *FollowUpsertOne) IDX(ctx context.Context) uuid.UUID
IDX is like ID, but panics if an error occurs.
func (*FollowUpsertOne) Ignore ¶
func (u *FollowUpsertOne) Ignore() *FollowUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Follow.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*FollowUpsertOne) SetExtensions ¶
func (u *FollowUpsertOne) SetExtensions(v versia.Extensions) *FollowUpsertOne
SetExtensions sets the "extensions" field.
func (*FollowUpsertOne) SetIsRemote ¶
func (u *FollowUpsertOne) SetIsRemote(v bool) *FollowUpsertOne
SetIsRemote sets the "isRemote" field.
func (*FollowUpsertOne) SetStatus ¶
func (u *FollowUpsertOne) SetStatus(v follow.Status) *FollowUpsertOne
SetStatus sets the "status" field.
func (*FollowUpsertOne) SetURI ¶
func (u *FollowUpsertOne) SetURI(v string) *FollowUpsertOne
SetURI sets the "uri" field.
func (*FollowUpsertOne) SetUpdatedAt ¶
func (u *FollowUpsertOne) SetUpdatedAt(v time.Time) *FollowUpsertOne
SetUpdatedAt sets the "updated_at" field.
func (*FollowUpsertOne) Update ¶
func (u *FollowUpsertOne) Update(set func(*FollowUpsert)) *FollowUpsertOne
Update allows overriding fields `UPDATE` values. See the FollowCreate.OnConflict documentation for more info.
func (*FollowUpsertOne) UpdateExtensions ¶
func (u *FollowUpsertOne) UpdateExtensions() *FollowUpsertOne
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*FollowUpsertOne) UpdateIsRemote ¶
func (u *FollowUpsertOne) UpdateIsRemote() *FollowUpsertOne
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*FollowUpsertOne) UpdateNewValues ¶
func (u *FollowUpsertOne) UpdateNewValues() *FollowUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:
client.Follow.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(follow.FieldID) }), ). Exec(ctx)
func (*FollowUpsertOne) UpdateStatus ¶
func (u *FollowUpsertOne) UpdateStatus() *FollowUpsertOne
UpdateStatus sets the "status" field to the value that was provided on create.
func (*FollowUpsertOne) UpdateURI ¶
func (u *FollowUpsertOne) UpdateURI() *FollowUpsertOne
UpdateURI sets the "uri" field to the value that was provided on create.
func (*FollowUpsertOne) UpdateUpdatedAt ¶
func (u *FollowUpsertOne) UpdateUpdatedAt() *FollowUpsertOne
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
type Image ¶
type Image struct { // ID of the ent. ID int `json:"id,omitempty"` // URL holds the value of the "url" field. URL string `json:"url,omitempty"` // MimeType holds the value of the "mimeType" field. MimeType string `json:"mimeType,omitempty"` // contains filtered or unexported fields }
Image is the model entity for the Image schema.
func (*Image) Unwrap ¶
Unwrap unwraps the Image 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 (*Image) Update ¶
func (i *Image) Update() *ImageUpdateOne
Update returns a builder for updating this Image. Note that you need to call Image.Unwrap() before calling this method if this Image was returned from a transaction, and the transaction was committed or rolled back.
type ImageClient ¶
type ImageClient struct {
// contains filtered or unexported fields
}
ImageClient is a client for the Image schema.
func NewImageClient ¶
func NewImageClient(c config) *ImageClient
NewImageClient returns a client for the Image from the given config.
func (*ImageClient) Create ¶
func (c *ImageClient) Create() *ImageCreate
Create returns a builder for creating a Image entity.
func (*ImageClient) CreateBulk ¶
func (c *ImageClient) CreateBulk(builders ...*ImageCreate) *ImageCreateBulk
CreateBulk returns a builder for creating a bulk of Image entities.
func (*ImageClient) Delete ¶
func (c *ImageClient) Delete() *ImageDelete
Delete returns a delete builder for Image.
func (*ImageClient) DeleteOne ¶
func (c *ImageClient) DeleteOne(i *Image) *ImageDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*ImageClient) DeleteOneID ¶
func (c *ImageClient) DeleteOneID(id int) *ImageDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*ImageClient) GetX ¶
func (c *ImageClient) GetX(ctx context.Context, id int) *Image
GetX is like Get, but panics if an error occurs.
func (*ImageClient) Intercept ¶
func (c *ImageClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `image.Intercept(f(g(h())))`.
func (*ImageClient) Interceptors ¶
func (c *ImageClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*ImageClient) MapCreateBulk ¶
func (c *ImageClient) MapCreateBulk(slice any, setFunc func(*ImageCreate, int)) *ImageCreateBulk
MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.
func (*ImageClient) Query ¶
func (c *ImageClient) Query() *ImageQuery
Query returns a query builder for Image.
func (*ImageClient) Update ¶
func (c *ImageClient) Update() *ImageUpdate
Update returns an update builder for Image.
func (*ImageClient) UpdateOne ¶
func (c *ImageClient) UpdateOne(i *Image) *ImageUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ImageClient) UpdateOneID ¶
func (c *ImageClient) UpdateOneID(id int) *ImageUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ImageClient) Use ¶
func (c *ImageClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `image.Hooks(f(g(h())))`.
type ImageCreate ¶
type ImageCreate struct {
// contains filtered or unexported fields
}
ImageCreate is the builder for creating a Image entity.
func (*ImageCreate) Exec ¶
func (ic *ImageCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ImageCreate) ExecX ¶
func (ic *ImageCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageCreate) Mutation ¶
func (ic *ImageCreate) Mutation() *ImageMutation
Mutation returns the ImageMutation object of the builder.
func (*ImageCreate) OnConflict ¶
func (ic *ImageCreate) OnConflict(opts ...sql.ConflictOption) *ImageUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Image.Create(). SetURL(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.ImageUpsert) { SetURL(v+v). }). Exec(ctx)
func (*ImageCreate) OnConflictColumns ¶
func (ic *ImageCreate) OnConflictColumns(columns ...string) *ImageUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Image.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*ImageCreate) Save ¶
func (ic *ImageCreate) Save(ctx context.Context) (*Image, error)
Save creates the Image in the database.
func (*ImageCreate) SaveX ¶
func (ic *ImageCreate) SaveX(ctx context.Context) *Image
SaveX calls Save and panics if Save returns an error.
func (*ImageCreate) SetMimeType ¶
func (ic *ImageCreate) SetMimeType(s string) *ImageCreate
SetMimeType sets the "mimeType" field.
func (*ImageCreate) SetURL ¶
func (ic *ImageCreate) SetURL(s string) *ImageCreate
SetURL sets the "url" field.
type ImageCreateBulk ¶
type ImageCreateBulk struct {
// contains filtered or unexported fields
}
ImageCreateBulk is the builder for creating many Image entities in bulk.
func (*ImageCreateBulk) Exec ¶
func (icb *ImageCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ImageCreateBulk) ExecX ¶
func (icb *ImageCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageCreateBulk) OnConflict ¶
func (icb *ImageCreateBulk) OnConflict(opts ...sql.ConflictOption) *ImageUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Image.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.ImageUpsert) { SetURL(v+v). }). Exec(ctx)
func (*ImageCreateBulk) OnConflictColumns ¶
func (icb *ImageCreateBulk) OnConflictColumns(columns ...string) *ImageUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Image.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type ImageDelete ¶
type ImageDelete struct {
// contains filtered or unexported fields
}
ImageDelete is the builder for deleting a Image entity.
func (*ImageDelete) Exec ¶
func (id *ImageDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ImageDelete) ExecX ¶
func (id *ImageDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ImageDelete) Where ¶
func (id *ImageDelete) Where(ps ...predicate.Image) *ImageDelete
Where appends a list predicates to the ImageDelete builder.
type ImageDeleteOne ¶
type ImageDeleteOne struct {
// contains filtered or unexported fields
}
ImageDeleteOne is the builder for deleting a single Image entity.
func (*ImageDeleteOne) Exec ¶
func (ido *ImageDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ImageDeleteOne) ExecX ¶
func (ido *ImageDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageDeleteOne) Where ¶
func (ido *ImageDeleteOne) Where(ps ...predicate.Image) *ImageDeleteOne
Where appends a list predicates to the ImageDelete builder.
type ImageGroupBy ¶
type ImageGroupBy struct {
// contains filtered or unexported fields
}
ImageGroupBy is the group-by builder for Image entities.
func (*ImageGroupBy) Aggregate ¶
func (igb *ImageGroupBy) Aggregate(fns ...AggregateFunc) *ImageGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ImageGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ImageGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ImageGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ImageGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ImageGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ImageGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ImageGroupBy) Scan ¶
func (igb *ImageGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ImageGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ImageMutation ¶
type ImageMutation struct {
// contains filtered or unexported fields
}
ImageMutation represents an operation that mutates the Image nodes in the graph.
func (*ImageMutation) AddField ¶
func (m *ImageMutation) 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 (*ImageMutation) AddedEdges ¶
func (m *ImageMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ImageMutation) AddedField ¶
func (m *ImageMutation) 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 (*ImageMutation) AddedFields ¶
func (m *ImageMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ImageMutation) AddedIDs ¶
func (m *ImageMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ImageMutation) ClearEdge ¶
func (m *ImageMutation) 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 (*ImageMutation) ClearField ¶
func (m *ImageMutation) 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 (*ImageMutation) ClearedEdges ¶
func (m *ImageMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ImageMutation) ClearedFields ¶
func (m *ImageMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ImageMutation) Client ¶
func (m ImageMutation) 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 (*ImageMutation) EdgeCleared ¶
func (m *ImageMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ImageMutation) Field ¶
func (m *ImageMutation) 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 (*ImageMutation) FieldCleared ¶
func (m *ImageMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ImageMutation) Fields ¶
func (m *ImageMutation) 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 (*ImageMutation) ID ¶
func (m *ImageMutation) 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 (*ImageMutation) IDs ¶
func (m *ImageMutation) 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 (*ImageMutation) MimeType ¶
func (m *ImageMutation) MimeType() (r string, exists bool)
MimeType returns the value of the "mimeType" field in the mutation.
func (*ImageMutation) 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 (*ImageMutation) OldMimeType ¶
func (m *ImageMutation) OldMimeType(ctx context.Context) (v string, err error)
OldMimeType returns the old "mimeType" field's value of the Image entity. If the Image 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 (*ImageMutation) OldURL ¶
func (m *ImageMutation) OldURL(ctx context.Context) (v string, err error)
OldURL returns the old "url" field's value of the Image entity. If the Image 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 (*ImageMutation) RemovedEdges ¶
func (m *ImageMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ImageMutation) RemovedIDs ¶
func (m *ImageMutation) 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 (*ImageMutation) ResetEdge ¶
func (m *ImageMutation) 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 (*ImageMutation) ResetField ¶
func (m *ImageMutation) 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 (*ImageMutation) ResetMimeType ¶
func (m *ImageMutation) ResetMimeType()
ResetMimeType resets all changes to the "mimeType" field.
func (*ImageMutation) ResetURL ¶
func (m *ImageMutation) ResetURL()
ResetURL resets all changes to the "url" field.
func (*ImageMutation) SetField ¶
func (m *ImageMutation) 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 (*ImageMutation) SetMimeType ¶
func (m *ImageMutation) SetMimeType(s string)
SetMimeType sets the "mimeType" field.
func (*ImageMutation) SetOp ¶
func (m *ImageMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*ImageMutation) SetURL ¶
func (m *ImageMutation) SetURL(s string)
SetURL sets the "url" field.
func (ImageMutation) Tx ¶
func (m ImageMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ImageMutation) Type ¶
func (m *ImageMutation) Type() string
Type returns the node type of this mutation (Image).
func (*ImageMutation) URL ¶
func (m *ImageMutation) URL() (r string, exists bool)
URL returns the value of the "url" field in the mutation.
func (*ImageMutation) Where ¶
func (m *ImageMutation) Where(ps ...predicate.Image)
Where appends a list predicates to the ImageMutation builder.
func (*ImageMutation) WhereP ¶
func (m *ImageMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the ImageMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type ImageQuery ¶
type ImageQuery struct {
// contains filtered or unexported fields
}
ImageQuery is the builder for querying Image entities.
func (*ImageQuery) Aggregate ¶
func (iq *ImageQuery) Aggregate(fns ...AggregateFunc) *ImageSelect
Aggregate returns a ImageSelect configured with the given aggregations.
func (*ImageQuery) All ¶
func (iq *ImageQuery) All(ctx context.Context) ([]*Image, error)
All executes the query and returns a list of Images.
func (*ImageQuery) AllX ¶
func (iq *ImageQuery) AllX(ctx context.Context) []*Image
AllX is like All, but panics if an error occurs.
func (*ImageQuery) Clone ¶
func (iq *ImageQuery) Clone() *ImageQuery
Clone returns a duplicate of the ImageQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ImageQuery) Count ¶
func (iq *ImageQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*ImageQuery) CountX ¶
func (iq *ImageQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*ImageQuery) Exist ¶
func (iq *ImageQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*ImageQuery) ExistX ¶
func (iq *ImageQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*ImageQuery) First ¶
func (iq *ImageQuery) First(ctx context.Context) (*Image, error)
First returns the first Image entity from the query. Returns a *NotFoundError when no Image was found.
func (*ImageQuery) FirstID ¶
func (iq *ImageQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Image ID from the query. Returns a *NotFoundError when no Image ID was found.
func (*ImageQuery) FirstIDX ¶
func (iq *ImageQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*ImageQuery) FirstX ¶
func (iq *ImageQuery) FirstX(ctx context.Context) *Image
FirstX is like First, but panics if an error occurs.
func (*ImageQuery) GroupBy ¶
func (iq *ImageQuery) GroupBy(field string, fields ...string) *ImageGroupBy
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 { URL string `json:"url,omitempty"` Count int `json:"count,omitempty"` } client.Image.Query(). GroupBy(image.FieldURL). Aggregate(ent.Count()). Scan(ctx, &v)
func (*ImageQuery) IDs ¶
func (iq *ImageQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of Image IDs.
func (*ImageQuery) IDsX ¶
func (iq *ImageQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*ImageQuery) Limit ¶
func (iq *ImageQuery) Limit(limit int) *ImageQuery
Limit the number of records to be returned by this query.
func (*ImageQuery) Offset ¶
func (iq *ImageQuery) Offset(offset int) *ImageQuery
Offset to start from.
func (*ImageQuery) Only ¶
func (iq *ImageQuery) Only(ctx context.Context) (*Image, error)
Only returns a single Image entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Image entity is found. Returns a *NotFoundError when no Image entities are found.
func (*ImageQuery) OnlyID ¶
func (iq *ImageQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Image ID in the query. Returns a *NotSingularError when more than one Image ID is found. Returns a *NotFoundError when no entities are found.
func (*ImageQuery) OnlyIDX ¶
func (iq *ImageQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*ImageQuery) OnlyX ¶
func (iq *ImageQuery) OnlyX(ctx context.Context) *Image
OnlyX is like Only, but panics if an error occurs.
func (*ImageQuery) Order ¶
func (iq *ImageQuery) Order(o ...image.OrderOption) *ImageQuery
Order specifies how the records should be ordered.
func (*ImageQuery) Select ¶
func (iq *ImageQuery) Select(fields ...string) *ImageSelect
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 { URL string `json:"url,omitempty"` } client.Image.Query(). Select(image.FieldURL). Scan(ctx, &v)
func (*ImageQuery) Unique ¶
func (iq *ImageQuery) Unique(unique bool) *ImageQuery
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 (*ImageQuery) Where ¶
func (iq *ImageQuery) Where(ps ...predicate.Image) *ImageQuery
Where adds a new predicate for the ImageQuery builder.
type ImageSelect ¶
type ImageSelect struct { *ImageQuery // contains filtered or unexported fields }
ImageSelect is the builder for selecting fields of Image entities.
func (*ImageSelect) Aggregate ¶
func (is *ImageSelect) Aggregate(fns ...AggregateFunc) *ImageSelect
Aggregate adds the given aggregation functions to the selector query.
func (*ImageSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ImageSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ImageSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ImageSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ImageSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ImageSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ImageSelect) Scan ¶
func (is *ImageSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ImageSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ImageUpdate ¶
type ImageUpdate struct {
// contains filtered or unexported fields
}
ImageUpdate is the builder for updating Image entities.
func (*ImageUpdate) Exec ¶
func (iu *ImageUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ImageUpdate) ExecX ¶
func (iu *ImageUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageUpdate) Mutation ¶
func (iu *ImageUpdate) Mutation() *ImageMutation
Mutation returns the ImageMutation object of the builder.
func (*ImageUpdate) Save ¶
func (iu *ImageUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ImageUpdate) SaveX ¶
func (iu *ImageUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ImageUpdate) SetMimeType ¶
func (iu *ImageUpdate) SetMimeType(s string) *ImageUpdate
SetMimeType sets the "mimeType" field.
func (*ImageUpdate) SetNillableMimeType ¶
func (iu *ImageUpdate) SetNillableMimeType(s *string) *ImageUpdate
SetNillableMimeType sets the "mimeType" field if the given value is not nil.
func (*ImageUpdate) SetNillableURL ¶
func (iu *ImageUpdate) SetNillableURL(s *string) *ImageUpdate
SetNillableURL sets the "url" field if the given value is not nil.
func (*ImageUpdate) SetURL ¶
func (iu *ImageUpdate) SetURL(s string) *ImageUpdate
SetURL sets the "url" field.
func (*ImageUpdate) Where ¶
func (iu *ImageUpdate) Where(ps ...predicate.Image) *ImageUpdate
Where appends a list predicates to the ImageUpdate builder.
type ImageUpdateOne ¶
type ImageUpdateOne struct {
// contains filtered or unexported fields
}
ImageUpdateOne is the builder for updating a single Image entity.
func (*ImageUpdateOne) Exec ¶
func (iuo *ImageUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ImageUpdateOne) ExecX ¶
func (iuo *ImageUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageUpdateOne) Mutation ¶
func (iuo *ImageUpdateOne) Mutation() *ImageMutation
Mutation returns the ImageMutation object of the builder.
func (*ImageUpdateOne) Save ¶
func (iuo *ImageUpdateOne) Save(ctx context.Context) (*Image, error)
Save executes the query and returns the updated Image entity.
func (*ImageUpdateOne) SaveX ¶
func (iuo *ImageUpdateOne) SaveX(ctx context.Context) *Image
SaveX is like Save, but panics if an error occurs.
func (*ImageUpdateOne) Select ¶
func (iuo *ImageUpdateOne) Select(field string, fields ...string) *ImageUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ImageUpdateOne) SetMimeType ¶
func (iuo *ImageUpdateOne) SetMimeType(s string) *ImageUpdateOne
SetMimeType sets the "mimeType" field.
func (*ImageUpdateOne) SetNillableMimeType ¶
func (iuo *ImageUpdateOne) SetNillableMimeType(s *string) *ImageUpdateOne
SetNillableMimeType sets the "mimeType" field if the given value is not nil.
func (*ImageUpdateOne) SetNillableURL ¶
func (iuo *ImageUpdateOne) SetNillableURL(s *string) *ImageUpdateOne
SetNillableURL sets the "url" field if the given value is not nil.
func (*ImageUpdateOne) SetURL ¶
func (iuo *ImageUpdateOne) SetURL(s string) *ImageUpdateOne
SetURL sets the "url" field.
func (*ImageUpdateOne) Where ¶
func (iuo *ImageUpdateOne) Where(ps ...predicate.Image) *ImageUpdateOne
Where appends a list predicates to the ImageUpdate builder.
type ImageUpsert ¶
ImageUpsert is the "OnConflict" setter.
func (*ImageUpsert) SetMimeType ¶
func (u *ImageUpsert) SetMimeType(v string) *ImageUpsert
SetMimeType sets the "mimeType" field.
func (*ImageUpsert) SetURL ¶
func (u *ImageUpsert) SetURL(v string) *ImageUpsert
SetURL sets the "url" field.
func (*ImageUpsert) UpdateMimeType ¶
func (u *ImageUpsert) UpdateMimeType() *ImageUpsert
UpdateMimeType sets the "mimeType" field to the value that was provided on create.
func (*ImageUpsert) UpdateURL ¶
func (u *ImageUpsert) UpdateURL() *ImageUpsert
UpdateURL sets the "url" field to the value that was provided on create.
type ImageUpsertBulk ¶
type ImageUpsertBulk struct {
// contains filtered or unexported fields
}
ImageUpsertBulk is the builder for "upsert"-ing a bulk of Image nodes.
func (*ImageUpsertBulk) DoNothing ¶
func (u *ImageUpsertBulk) DoNothing() *ImageUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ImageUpsertBulk) Exec ¶
func (u *ImageUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ImageUpsertBulk) ExecX ¶
func (u *ImageUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageUpsertBulk) Ignore ¶
func (u *ImageUpsertBulk) Ignore() *ImageUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Image.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ImageUpsertBulk) SetMimeType ¶
func (u *ImageUpsertBulk) SetMimeType(v string) *ImageUpsertBulk
SetMimeType sets the "mimeType" field.
func (*ImageUpsertBulk) SetURL ¶
func (u *ImageUpsertBulk) SetURL(v string) *ImageUpsertBulk
SetURL sets the "url" field.
func (*ImageUpsertBulk) Update ¶
func (u *ImageUpsertBulk) Update(set func(*ImageUpsert)) *ImageUpsertBulk
Update allows overriding fields `UPDATE` values. See the ImageCreateBulk.OnConflict documentation for more info.
func (*ImageUpsertBulk) UpdateMimeType ¶
func (u *ImageUpsertBulk) UpdateMimeType() *ImageUpsertBulk
UpdateMimeType sets the "mimeType" field to the value that was provided on create.
func (*ImageUpsertBulk) UpdateNewValues ¶
func (u *ImageUpsertBulk) UpdateNewValues() *ImageUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Image.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*ImageUpsertBulk) UpdateURL ¶
func (u *ImageUpsertBulk) UpdateURL() *ImageUpsertBulk
UpdateURL sets the "url" field to the value that was provided on create.
type ImageUpsertOne ¶
type ImageUpsertOne struct {
// contains filtered or unexported fields
}
ImageUpsertOne is the builder for "upsert"-ing
one Image node.
func (*ImageUpsertOne) DoNothing ¶
func (u *ImageUpsertOne) DoNothing() *ImageUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ImageUpsertOne) Exec ¶
func (u *ImageUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*ImageUpsertOne) ExecX ¶
func (u *ImageUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ImageUpsertOne) ID ¶
func (u *ImageUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*ImageUpsertOne) IDX ¶
func (u *ImageUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*ImageUpsertOne) Ignore ¶
func (u *ImageUpsertOne) Ignore() *ImageUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Image.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ImageUpsertOne) SetMimeType ¶
func (u *ImageUpsertOne) SetMimeType(v string) *ImageUpsertOne
SetMimeType sets the "mimeType" field.
func (*ImageUpsertOne) SetURL ¶
func (u *ImageUpsertOne) SetURL(v string) *ImageUpsertOne
SetURL sets the "url" field.
func (*ImageUpsertOne) Update ¶
func (u *ImageUpsertOne) Update(set func(*ImageUpsert)) *ImageUpsertOne
Update allows overriding fields `UPDATE` values. See the ImageCreate.OnConflict documentation for more info.
func (*ImageUpsertOne) UpdateMimeType ¶
func (u *ImageUpsertOne) UpdateMimeType() *ImageUpsertOne
UpdateMimeType sets the "mimeType" field to the value that was provided on create.
func (*ImageUpsertOne) UpdateNewValues ¶
func (u *ImageUpsertOne) UpdateNewValues() *ImageUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Image.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*ImageUpsertOne) UpdateURL ¶
func (u *ImageUpsertOne) UpdateURL() *ImageUpsertOne
UpdateURL sets the "url" field to the value that was provided on create.
type InstanceMetadata ¶
type InstanceMetadata struct { // ID of the ent. ID uuid.UUID `json:"id,omitempty"` // IsRemote holds the value of the "isRemote" field. IsRemote bool `json:"isRemote,omitempty"` // URI holds the value of the "uri" field. URI string `json:"uri,omitempty"` // Extensions holds the value of the "extensions" field. Extensions versia.Extensions `json:"extensions,omitempty"` // CreatedAt holds the value of the "created_at" field. CreatedAt time.Time `json:"created_at,omitempty"` // UpdatedAt holds the value of the "updated_at" field. UpdatedAt time.Time `json:"updated_at,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Description holds the value of the "description" field. Description *string `json:"description,omitempty"` // Host holds the value of the "host" field. Host string `json:"host,omitempty"` // PublicKey holds the value of the "publicKey" field. PublicKey []byte `json:"publicKey,omitempty"` // PublicKeyAlgorithm holds the value of the "publicKeyAlgorithm" field. PublicKeyAlgorithm string `json:"publicKeyAlgorithm,omitempty"` // PrivateKey holds the value of the "privateKey" field. PrivateKey []byte `json:"privateKey,omitempty"` // SoftwareName holds the value of the "softwareName" field. SoftwareName string `json:"softwareName,omitempty"` // SoftwareVersion holds the value of the "softwareVersion" field. SoftwareVersion string `json:"softwareVersion,omitempty"` SharedInboxURI string `json:"sharedInboxURI,omitempty"` // ModeratorsURI holds the value of the "moderatorsURI" field. ModeratorsURI *string `json:"moderatorsURI,omitempty"` // AdminsURI holds the value of the "adminsURI" field. AdminsURI *string `json:"adminsURI,omitempty"` // LogoEndpoint holds the value of the "logoEndpoint" field. LogoEndpoint *string `json:"logoEndpoint,omitempty"` // LogoMimeType holds the value of the "logoMimeType" field. LogoMimeType *string `json:"logoMimeType,omitempty"` // BannerEndpoint holds the value of the "bannerEndpoint" field. BannerEndpoint *string `json:"bannerEndpoint,omitempty"` // BannerMimeType holds the value of the "bannerMimeType" field. BannerMimeType *string `json:"bannerMimeType,omitempty"` // SupportedVersions holds the value of the "supportedVersions" field. SupportedVersions []string `json:"supportedVersions,omitempty"` // SupportedExtensions holds the value of the "supportedExtensions" field. SupportedExtensions []string `json:"supportedExtensions,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the InstanceMetadataQuery when eager-loading is set. Edges InstanceMetadataEdges `json:"edges"` // contains filtered or unexported fields }
InstanceMetadata is the model entity for the InstanceMetadata schema.
func (*InstanceMetadata) QueryAdmins ¶
func (im *InstanceMetadata) QueryAdmins() *UserQuery
QueryAdmins queries the "admins" edge of the InstanceMetadata entity.
func (*InstanceMetadata) QueryModerators ¶
func (im *InstanceMetadata) QueryModerators() *UserQuery
QueryModerators queries the "moderators" edge of the InstanceMetadata entity.
func (*InstanceMetadata) QueryUsers ¶
func (im *InstanceMetadata) QueryUsers() *UserQuery
QueryUsers queries the "users" edge of the InstanceMetadata entity.
func (*InstanceMetadata) String ¶
func (im *InstanceMetadata) String() string
String implements the fmt.Stringer.
func (*InstanceMetadata) Unwrap ¶
func (im *InstanceMetadata) Unwrap() *InstanceMetadata
Unwrap unwraps the InstanceMetadata 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 (*InstanceMetadata) Update ¶
func (im *InstanceMetadata) Update() *InstanceMetadataUpdateOne
Update returns a builder for updating this InstanceMetadata. Note that you need to call InstanceMetadata.Unwrap() before calling this method if this InstanceMetadata was returned from a transaction, and the transaction was committed or rolled back.
type InstanceMetadataClient ¶
type InstanceMetadataClient struct {
// contains filtered or unexported fields
}
InstanceMetadataClient is a client for the InstanceMetadata schema.
func NewInstanceMetadataClient ¶
func NewInstanceMetadataClient(c config) *InstanceMetadataClient
NewInstanceMetadataClient returns a client for the InstanceMetadata from the given config.
func (*InstanceMetadataClient) Create ¶
func (c *InstanceMetadataClient) Create() *InstanceMetadataCreate
Create returns a builder for creating a InstanceMetadata entity.
func (*InstanceMetadataClient) CreateBulk ¶
func (c *InstanceMetadataClient) CreateBulk(builders ...*InstanceMetadataCreate) *InstanceMetadataCreateBulk
CreateBulk returns a builder for creating a bulk of InstanceMetadata entities.
func (*InstanceMetadataClient) Delete ¶
func (c *InstanceMetadataClient) Delete() *InstanceMetadataDelete
Delete returns a delete builder for InstanceMetadata.
func (*InstanceMetadataClient) DeleteOne ¶
func (c *InstanceMetadataClient) DeleteOne(im *InstanceMetadata) *InstanceMetadataDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*InstanceMetadataClient) DeleteOneID ¶
func (c *InstanceMetadataClient) DeleteOneID(id uuid.UUID) *InstanceMetadataDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*InstanceMetadataClient) Get ¶
func (c *InstanceMetadataClient) Get(ctx context.Context, id uuid.UUID) (*InstanceMetadata, error)
Get returns a InstanceMetadata entity by its id.
func (*InstanceMetadataClient) GetX ¶
func (c *InstanceMetadataClient) GetX(ctx context.Context, id uuid.UUID) *InstanceMetadata
GetX is like Get, but panics if an error occurs.
func (*InstanceMetadataClient) Hooks ¶
func (c *InstanceMetadataClient) Hooks() []Hook
Hooks returns the client hooks.
func (*InstanceMetadataClient) Intercept ¶
func (c *InstanceMetadataClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `instancemetadata.Intercept(f(g(h())))`.
func (*InstanceMetadataClient) Interceptors ¶
func (c *InstanceMetadataClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*InstanceMetadataClient) MapCreateBulk ¶
func (c *InstanceMetadataClient) MapCreateBulk(slice any, setFunc func(*InstanceMetadataCreate, int)) *InstanceMetadataCreateBulk
MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.
func (*InstanceMetadataClient) Query ¶
func (c *InstanceMetadataClient) Query() *InstanceMetadataQuery
Query returns a query builder for InstanceMetadata.
func (*InstanceMetadataClient) QueryAdmins ¶
func (c *InstanceMetadataClient) QueryAdmins(im *InstanceMetadata) *UserQuery
QueryAdmins queries the admins edge of a InstanceMetadata.
func (*InstanceMetadataClient) QueryModerators ¶
func (c *InstanceMetadataClient) QueryModerators(im *InstanceMetadata) *UserQuery
QueryModerators queries the moderators edge of a InstanceMetadata.
func (*InstanceMetadataClient) QueryUsers ¶
func (c *InstanceMetadataClient) QueryUsers(im *InstanceMetadata) *UserQuery
QueryUsers queries the users edge of a InstanceMetadata.
func (*InstanceMetadataClient) Update ¶
func (c *InstanceMetadataClient) Update() *InstanceMetadataUpdate
Update returns an update builder for InstanceMetadata.
func (*InstanceMetadataClient) UpdateOne ¶
func (c *InstanceMetadataClient) UpdateOne(im *InstanceMetadata) *InstanceMetadataUpdateOne
UpdateOne returns an update builder for the given entity.
func (*InstanceMetadataClient) UpdateOneID ¶
func (c *InstanceMetadataClient) UpdateOneID(id uuid.UUID) *InstanceMetadataUpdateOne
UpdateOneID returns an update builder for the given id.
func (*InstanceMetadataClient) Use ¶
func (c *InstanceMetadataClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `instancemetadata.Hooks(f(g(h())))`.
type InstanceMetadataCreate ¶
type InstanceMetadataCreate struct {
// contains filtered or unexported fields
}
InstanceMetadataCreate is the builder for creating a InstanceMetadata entity.
func (*InstanceMetadataCreate) AddAdminIDs ¶
func (imc *InstanceMetadataCreate) AddAdminIDs(ids ...uuid.UUID) *InstanceMetadataCreate
AddAdminIDs adds the "admins" edge to the User entity by IDs.
func (*InstanceMetadataCreate) AddAdmins ¶
func (imc *InstanceMetadataCreate) AddAdmins(u ...*User) *InstanceMetadataCreate
AddAdmins adds the "admins" edges to the User entity.
func (*InstanceMetadataCreate) AddModeratorIDs ¶
func (imc *InstanceMetadataCreate) AddModeratorIDs(ids ...uuid.UUID) *InstanceMetadataCreate
AddModeratorIDs adds the "moderators" edge to the User entity by IDs.
func (*InstanceMetadataCreate) AddModerators ¶
func (imc *InstanceMetadataCreate) AddModerators(u ...*User) *InstanceMetadataCreate
AddModerators adds the "moderators" edges to the User entity.
func (*InstanceMetadataCreate) AddUserIDs ¶
func (imc *InstanceMetadataCreate) AddUserIDs(ids ...uuid.UUID) *InstanceMetadataCreate
AddUserIDs adds the "users" edge to the User entity by IDs.
func (*InstanceMetadataCreate) AddUsers ¶
func (imc *InstanceMetadataCreate) AddUsers(u ...*User) *InstanceMetadataCreate
AddUsers adds the "users" edges to the User entity.
func (*InstanceMetadataCreate) Exec ¶
func (imc *InstanceMetadataCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*InstanceMetadataCreate) ExecX ¶
func (imc *InstanceMetadataCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataCreate) Mutation ¶
func (imc *InstanceMetadataCreate) Mutation() *InstanceMetadataMutation
Mutation returns the InstanceMetadataMutation object of the builder.
func (*InstanceMetadataCreate) OnConflict ¶
func (imc *InstanceMetadataCreate) OnConflict(opts ...sql.ConflictOption) *InstanceMetadataUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.InstanceMetadata.Create(). SetIsRemote(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.InstanceMetadataUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*InstanceMetadataCreate) OnConflictColumns ¶
func (imc *InstanceMetadataCreate) OnConflictColumns(columns ...string) *InstanceMetadataUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.InstanceMetadata.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*InstanceMetadataCreate) Save ¶
func (imc *InstanceMetadataCreate) Save(ctx context.Context) (*InstanceMetadata, error)
Save creates the InstanceMetadata in the database.
func (*InstanceMetadataCreate) SaveX ¶
func (imc *InstanceMetadataCreate) SaveX(ctx context.Context) *InstanceMetadata
SaveX calls Save and panics if Save returns an error.
func (*InstanceMetadataCreate) SetAdminsURI ¶
func (imc *InstanceMetadataCreate) SetAdminsURI(s string) *InstanceMetadataCreate
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataCreate) SetBannerEndpoint ¶
func (imc *InstanceMetadataCreate) SetBannerEndpoint(s string) *InstanceMetadataCreate
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataCreate) SetBannerMimeType ¶
func (imc *InstanceMetadataCreate) SetBannerMimeType(s string) *InstanceMetadataCreate
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataCreate) SetCreatedAt ¶
func (imc *InstanceMetadataCreate) SetCreatedAt(t time.Time) *InstanceMetadataCreate
SetCreatedAt sets the "created_at" field.
func (*InstanceMetadataCreate) SetDescription ¶
func (imc *InstanceMetadataCreate) SetDescription(s string) *InstanceMetadataCreate
SetDescription sets the "description" field.
func (*InstanceMetadataCreate) SetExtensions ¶
func (imc *InstanceMetadataCreate) SetExtensions(v versia.Extensions) *InstanceMetadataCreate
SetExtensions sets the "extensions" field.
func (*InstanceMetadataCreate) SetHost ¶
func (imc *InstanceMetadataCreate) SetHost(s string) *InstanceMetadataCreate
SetHost sets the "host" field.
func (*InstanceMetadataCreate) SetID ¶
func (imc *InstanceMetadataCreate) SetID(u uuid.UUID) *InstanceMetadataCreate
SetID sets the "id" field.
func (*InstanceMetadataCreate) SetIsRemote ¶
func (imc *InstanceMetadataCreate) SetIsRemote(b bool) *InstanceMetadataCreate
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataCreate) SetLogoEndpoint ¶
func (imc *InstanceMetadataCreate) SetLogoEndpoint(s string) *InstanceMetadataCreate
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataCreate) SetLogoMimeType ¶
func (imc *InstanceMetadataCreate) SetLogoMimeType(s string) *InstanceMetadataCreate
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataCreate) SetModeratorsURI ¶
func (imc *InstanceMetadataCreate) SetModeratorsURI(s string) *InstanceMetadataCreate
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataCreate) SetName ¶
func (imc *InstanceMetadataCreate) SetName(s string) *InstanceMetadataCreate
SetName sets the "name" field.
func (*InstanceMetadataCreate) SetNillableAdminsURI ¶
func (imc *InstanceMetadataCreate) SetNillableAdminsURI(s *string) *InstanceMetadataCreate
SetNillableAdminsURI sets the "adminsURI" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableBannerEndpoint ¶
func (imc *InstanceMetadataCreate) SetNillableBannerEndpoint(s *string) *InstanceMetadataCreate
SetNillableBannerEndpoint sets the "bannerEndpoint" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableBannerMimeType ¶
func (imc *InstanceMetadataCreate) SetNillableBannerMimeType(s *string) *InstanceMetadataCreate
SetNillableBannerMimeType sets the "bannerMimeType" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableCreatedAt ¶
func (imc *InstanceMetadataCreate) SetNillableCreatedAt(t *time.Time) *InstanceMetadataCreate
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableDescription ¶
func (imc *InstanceMetadataCreate) SetNillableDescription(s *string) *InstanceMetadataCreate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableID ¶
func (imc *InstanceMetadataCreate) SetNillableID(u *uuid.UUID) *InstanceMetadataCreate
SetNillableID sets the "id" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableLogoEndpoint ¶
func (imc *InstanceMetadataCreate) SetNillableLogoEndpoint(s *string) *InstanceMetadataCreate
SetNillableLogoEndpoint sets the "logoEndpoint" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableLogoMimeType ¶
func (imc *InstanceMetadataCreate) SetNillableLogoMimeType(s *string) *InstanceMetadataCreate
SetNillableLogoMimeType sets the "logoMimeType" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableModeratorsURI ¶
func (imc *InstanceMetadataCreate) SetNillableModeratorsURI(s *string) *InstanceMetadataCreate
SetNillableModeratorsURI sets the "moderatorsURI" field if the given value is not nil.
func (*InstanceMetadataCreate) SetNillableUpdatedAt ¶
func (imc *InstanceMetadataCreate) SetNillableUpdatedAt(t *time.Time) *InstanceMetadataCreate
SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.
func (*InstanceMetadataCreate) SetPrivateKey ¶
func (imc *InstanceMetadataCreate) SetPrivateKey(b []byte) *InstanceMetadataCreate
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataCreate) SetPublicKey ¶
func (imc *InstanceMetadataCreate) SetPublicKey(b []byte) *InstanceMetadataCreate
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataCreate) SetPublicKeyAlgorithm ¶
func (imc *InstanceMetadataCreate) SetPublicKeyAlgorithm(s string) *InstanceMetadataCreate
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataCreate) SetSharedInboxURI ¶
func (imc *InstanceMetadataCreate) SetSharedInboxURI(s string) *InstanceMetadataCreate
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataCreate) SetSoftwareName ¶
func (imc *InstanceMetadataCreate) SetSoftwareName(s string) *InstanceMetadataCreate
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataCreate) SetSoftwareVersion ¶
func (imc *InstanceMetadataCreate) SetSoftwareVersion(s string) *InstanceMetadataCreate
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataCreate) SetSupportedExtensions ¶
func (imc *InstanceMetadataCreate) SetSupportedExtensions(s []string) *InstanceMetadataCreate
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataCreate) SetSupportedVersions ¶
func (imc *InstanceMetadataCreate) SetSupportedVersions(s []string) *InstanceMetadataCreate
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataCreate) SetURI ¶
func (imc *InstanceMetadataCreate) SetURI(s string) *InstanceMetadataCreate
SetURI sets the "uri" field.
func (*InstanceMetadataCreate) SetUpdatedAt ¶
func (imc *InstanceMetadataCreate) SetUpdatedAt(t time.Time) *InstanceMetadataCreate
SetUpdatedAt sets the "updated_at" field.
type InstanceMetadataCreateBulk ¶
type InstanceMetadataCreateBulk struct {
// contains filtered or unexported fields
}
InstanceMetadataCreateBulk is the builder for creating many InstanceMetadata entities in bulk.
func (*InstanceMetadataCreateBulk) Exec ¶
func (imcb *InstanceMetadataCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*InstanceMetadataCreateBulk) ExecX ¶
func (imcb *InstanceMetadataCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataCreateBulk) OnConflict ¶
func (imcb *InstanceMetadataCreateBulk) OnConflict(opts ...sql.ConflictOption) *InstanceMetadataUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.InstanceMetadata.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.InstanceMetadataUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*InstanceMetadataCreateBulk) OnConflictColumns ¶
func (imcb *InstanceMetadataCreateBulk) OnConflictColumns(columns ...string) *InstanceMetadataUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.InstanceMetadata.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*InstanceMetadataCreateBulk) Save ¶
func (imcb *InstanceMetadataCreateBulk) Save(ctx context.Context) ([]*InstanceMetadata, error)
Save creates the InstanceMetadata entities in the database.
func (*InstanceMetadataCreateBulk) SaveX ¶
func (imcb *InstanceMetadataCreateBulk) SaveX(ctx context.Context) []*InstanceMetadata
SaveX is like Save, but panics if an error occurs.
type InstanceMetadataDelete ¶
type InstanceMetadataDelete struct {
// contains filtered or unexported fields
}
InstanceMetadataDelete is the builder for deleting a InstanceMetadata entity.
func (*InstanceMetadataDelete) Exec ¶
func (imd *InstanceMetadataDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*InstanceMetadataDelete) ExecX ¶
func (imd *InstanceMetadataDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataDelete) Where ¶
func (imd *InstanceMetadataDelete) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataDelete
Where appends a list predicates to the InstanceMetadataDelete builder.
type InstanceMetadataDeleteOne ¶
type InstanceMetadataDeleteOne struct {
// contains filtered or unexported fields
}
InstanceMetadataDeleteOne is the builder for deleting a single InstanceMetadata entity.
func (*InstanceMetadataDeleteOne) Exec ¶
func (imdo *InstanceMetadataDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*InstanceMetadataDeleteOne) ExecX ¶
func (imdo *InstanceMetadataDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataDeleteOne) Where ¶
func (imdo *InstanceMetadataDeleteOne) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataDeleteOne
Where appends a list predicates to the InstanceMetadataDelete builder.
type InstanceMetadataEdges ¶
type InstanceMetadataEdges struct { // Users holds the value of the users edge. Users []*User `json:"users,omitempty"` // Moderators holds the value of the moderators edge. Moderators []*User `json:"moderators,omitempty"` // Admins holds the value of the admins edge. Admins []*User `json:"admins,omitempty"` // contains filtered or unexported fields }
InstanceMetadataEdges holds the relations/edges for other nodes in the graph.
func (InstanceMetadataEdges) AdminsOrErr ¶
func (e InstanceMetadataEdges) AdminsOrErr() ([]*User, error)
AdminsOrErr returns the Admins value or an error if the edge was not loaded in eager-loading.
func (InstanceMetadataEdges) ModeratorsOrErr ¶
func (e InstanceMetadataEdges) ModeratorsOrErr() ([]*User, error)
ModeratorsOrErr returns the Moderators value or an error if the edge was not loaded in eager-loading.
func (InstanceMetadataEdges) UsersOrErr ¶
func (e InstanceMetadataEdges) UsersOrErr() ([]*User, error)
UsersOrErr returns the Users value or an error if the edge was not loaded in eager-loading.
type InstanceMetadataGroupBy ¶
type InstanceMetadataGroupBy struct {
// contains filtered or unexported fields
}
InstanceMetadataGroupBy is the group-by builder for InstanceMetadata entities.
func (*InstanceMetadataGroupBy) Aggregate ¶
func (imgb *InstanceMetadataGroupBy) Aggregate(fns ...AggregateFunc) *InstanceMetadataGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*InstanceMetadataGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataGroupBy) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*InstanceMetadataGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataGroupBy) Scan ¶
func (imgb *InstanceMetadataGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*InstanceMetadataGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type InstanceMetadataMutation ¶
type InstanceMetadataMutation struct {
// contains filtered or unexported fields
}
InstanceMetadataMutation represents an operation that mutates the InstanceMetadata nodes in the graph.
func (*InstanceMetadataMutation) AddAdminIDs ¶
func (m *InstanceMetadataMutation) AddAdminIDs(ids ...uuid.UUID)
AddAdminIDs adds the "admins" edge to the User entity by ids.
func (*InstanceMetadataMutation) AddField ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) AddModeratorIDs ¶
func (m *InstanceMetadataMutation) AddModeratorIDs(ids ...uuid.UUID)
AddModeratorIDs adds the "moderators" edge to the User entity by ids.
func (*InstanceMetadataMutation) AddUserIDs ¶
func (m *InstanceMetadataMutation) AddUserIDs(ids ...uuid.UUID)
AddUserIDs adds the "users" edge to the User entity by ids.
func (*InstanceMetadataMutation) AddedEdges ¶
func (m *InstanceMetadataMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*InstanceMetadataMutation) AddedField ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) AddedFields ¶
func (m *InstanceMetadataMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*InstanceMetadataMutation) AddedIDs ¶
func (m *InstanceMetadataMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*InstanceMetadataMutation) AdminsCleared ¶
func (m *InstanceMetadataMutation) AdminsCleared() bool
AdminsCleared reports if the "admins" edge to the User entity was cleared.
func (*InstanceMetadataMutation) AdminsIDs ¶
func (m *InstanceMetadataMutation) AdminsIDs() (ids []uuid.UUID)
AdminsIDs returns the "admins" edge IDs in the mutation.
func (*InstanceMetadataMutation) AdminsURI ¶
func (m *InstanceMetadataMutation) AdminsURI() (r string, exists bool)
AdminsURI returns the value of the "adminsURI" field in the mutation.
func (*InstanceMetadataMutation) AdminsURICleared ¶
func (m *InstanceMetadataMutation) AdminsURICleared() bool
AdminsURICleared returns if the "adminsURI" field was cleared in this mutation.
func (*InstanceMetadataMutation) AppendSupportedExtensions ¶
func (m *InstanceMetadataMutation) AppendSupportedExtensions(s []string)
AppendSupportedExtensions adds s to the "supportedExtensions" field.
func (*InstanceMetadataMutation) AppendSupportedVersions ¶
func (m *InstanceMetadataMutation) AppendSupportedVersions(s []string)
AppendSupportedVersions adds s to the "supportedVersions" field.
func (*InstanceMetadataMutation) AppendedSupportedExtensions ¶
func (m *InstanceMetadataMutation) AppendedSupportedExtensions() ([]string, bool)
AppendedSupportedExtensions returns the list of values that were appended to the "supportedExtensions" field in this mutation.
func (*InstanceMetadataMutation) AppendedSupportedVersions ¶
func (m *InstanceMetadataMutation) AppendedSupportedVersions() ([]string, bool)
AppendedSupportedVersions returns the list of values that were appended to the "supportedVersions" field in this mutation.
func (*InstanceMetadataMutation) BannerEndpoint ¶
func (m *InstanceMetadataMutation) BannerEndpoint() (r string, exists bool)
BannerEndpoint returns the value of the "bannerEndpoint" field in the mutation.
func (*InstanceMetadataMutation) BannerEndpointCleared ¶
func (m *InstanceMetadataMutation) BannerEndpointCleared() bool
BannerEndpointCleared returns if the "bannerEndpoint" field was cleared in this mutation.
func (*InstanceMetadataMutation) BannerMimeType ¶
func (m *InstanceMetadataMutation) BannerMimeType() (r string, exists bool)
BannerMimeType returns the value of the "bannerMimeType" field in the mutation.
func (*InstanceMetadataMutation) BannerMimeTypeCleared ¶
func (m *InstanceMetadataMutation) BannerMimeTypeCleared() bool
BannerMimeTypeCleared returns if the "bannerMimeType" field was cleared in this mutation.
func (*InstanceMetadataMutation) ClearAdmins ¶
func (m *InstanceMetadataMutation) ClearAdmins()
ClearAdmins clears the "admins" edge to the User entity.
func (*InstanceMetadataMutation) ClearAdminsURI ¶
func (m *InstanceMetadataMutation) ClearAdminsURI()
ClearAdminsURI clears the value of the "adminsURI" field.
func (*InstanceMetadataMutation) ClearBannerEndpoint ¶
func (m *InstanceMetadataMutation) ClearBannerEndpoint()
ClearBannerEndpoint clears the value of the "bannerEndpoint" field.
func (*InstanceMetadataMutation) ClearBannerMimeType ¶
func (m *InstanceMetadataMutation) ClearBannerMimeType()
ClearBannerMimeType clears the value of the "bannerMimeType" field.
func (*InstanceMetadataMutation) ClearDescription ¶
func (m *InstanceMetadataMutation) ClearDescription()
ClearDescription clears the value of the "description" field.
func (*InstanceMetadataMutation) ClearEdge ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) ClearField ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) ClearLogoEndpoint ¶
func (m *InstanceMetadataMutation) ClearLogoEndpoint()
ClearLogoEndpoint clears the value of the "logoEndpoint" field.
func (*InstanceMetadataMutation) ClearLogoMimeType ¶
func (m *InstanceMetadataMutation) ClearLogoMimeType()
ClearLogoMimeType clears the value of the "logoMimeType" field.
func (*InstanceMetadataMutation) ClearModerators ¶
func (m *InstanceMetadataMutation) ClearModerators()
ClearModerators clears the "moderators" edge to the User entity.
func (*InstanceMetadataMutation) ClearModeratorsURI ¶
func (m *InstanceMetadataMutation) ClearModeratorsURI()
ClearModeratorsURI clears the value of the "moderatorsURI" field.
func (*InstanceMetadataMutation) ClearPrivateKey ¶
func (m *InstanceMetadataMutation) ClearPrivateKey()
ClearPrivateKey clears the value of the "privateKey" field.
func (*InstanceMetadataMutation) ClearUsers ¶
func (m *InstanceMetadataMutation) ClearUsers()
ClearUsers clears the "users" edge to the User entity.
func (*InstanceMetadataMutation) ClearedEdges ¶
func (m *InstanceMetadataMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*InstanceMetadataMutation) ClearedFields ¶
func (m *InstanceMetadataMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (InstanceMetadataMutation) Client ¶
func (m InstanceMetadataMutation) 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 (*InstanceMetadataMutation) CreatedAt ¶
func (m *InstanceMetadataMutation) CreatedAt() (r time.Time, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*InstanceMetadataMutation) Description ¶
func (m *InstanceMetadataMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*InstanceMetadataMutation) DescriptionCleared ¶
func (m *InstanceMetadataMutation) DescriptionCleared() bool
DescriptionCleared returns if the "description" field was cleared in this mutation.
func (*InstanceMetadataMutation) EdgeCleared ¶
func (m *InstanceMetadataMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*InstanceMetadataMutation) Extensions ¶
func (m *InstanceMetadataMutation) Extensions() (r versia.Extensions, exists bool)
Extensions returns the value of the "extensions" field in the mutation.
func (*InstanceMetadataMutation) Field ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) FieldCleared ¶
func (m *InstanceMetadataMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*InstanceMetadataMutation) Fields ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) Host ¶
func (m *InstanceMetadataMutation) Host() (r string, exists bool)
Host returns the value of the "host" field in the mutation.
func (*InstanceMetadataMutation) ID ¶
func (m *InstanceMetadataMutation) ID() (id uuid.UUID, 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 (*InstanceMetadataMutation) IDs ¶
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 (*InstanceMetadataMutation) IsRemote ¶
func (m *InstanceMetadataMutation) IsRemote() (r bool, exists bool)
IsRemote returns the value of the "isRemote" field in the mutation.
func (*InstanceMetadataMutation) LogoEndpoint ¶
func (m *InstanceMetadataMutation) LogoEndpoint() (r string, exists bool)
LogoEndpoint returns the value of the "logoEndpoint" field in the mutation.
func (*InstanceMetadataMutation) LogoEndpointCleared ¶
func (m *InstanceMetadataMutation) LogoEndpointCleared() bool
LogoEndpointCleared returns if the "logoEndpoint" field was cleared in this mutation.
func (*InstanceMetadataMutation) LogoMimeType ¶
func (m *InstanceMetadataMutation) LogoMimeType() (r string, exists bool)
LogoMimeType returns the value of the "logoMimeType" field in the mutation.
func (*InstanceMetadataMutation) LogoMimeTypeCleared ¶
func (m *InstanceMetadataMutation) LogoMimeTypeCleared() bool
LogoMimeTypeCleared returns if the "logoMimeType" field was cleared in this mutation.
func (*InstanceMetadataMutation) ModeratorsCleared ¶
func (m *InstanceMetadataMutation) ModeratorsCleared() bool
ModeratorsCleared reports if the "moderators" edge to the User entity was cleared.
func (*InstanceMetadataMutation) ModeratorsIDs ¶
func (m *InstanceMetadataMutation) ModeratorsIDs() (ids []uuid.UUID)
ModeratorsIDs returns the "moderators" edge IDs in the mutation.
func (*InstanceMetadataMutation) ModeratorsURI ¶
func (m *InstanceMetadataMutation) ModeratorsURI() (r string, exists bool)
ModeratorsURI returns the value of the "moderatorsURI" field in the mutation.
func (*InstanceMetadataMutation) ModeratorsURICleared ¶
func (m *InstanceMetadataMutation) ModeratorsURICleared() bool
ModeratorsURICleared returns if the "moderatorsURI" field was cleared in this mutation.
func (*InstanceMetadataMutation) Name ¶
func (m *InstanceMetadataMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*InstanceMetadataMutation) OldAdminsURI ¶
func (m *InstanceMetadataMutation) OldAdminsURI(ctx context.Context) (v *string, err error)
OldAdminsURI returns the old "adminsURI" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldBannerEndpoint ¶
func (m *InstanceMetadataMutation) OldBannerEndpoint(ctx context.Context) (v *string, err error)
OldBannerEndpoint returns the old "bannerEndpoint" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldBannerMimeType ¶
func (m *InstanceMetadataMutation) OldBannerMimeType(ctx context.Context) (v *string, err error)
OldBannerMimeType returns the old "bannerMimeType" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldCreatedAt ¶
OldCreatedAt returns the old "created_at" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldDescription ¶
func (m *InstanceMetadataMutation) OldDescription(ctx context.Context) (v *string, err error)
OldDescription returns the old "description" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldExtensions ¶
func (m *InstanceMetadataMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
OldExtensions returns the old "extensions" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) 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 (*InstanceMetadataMutation) OldHost ¶
func (m *InstanceMetadataMutation) OldHost(ctx context.Context) (v string, err error)
OldHost returns the old "host" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldIsRemote ¶
func (m *InstanceMetadataMutation) OldIsRemote(ctx context.Context) (v bool, err error)
OldIsRemote returns the old "isRemote" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldLogoEndpoint ¶
func (m *InstanceMetadataMutation) OldLogoEndpoint(ctx context.Context) (v *string, err error)
OldLogoEndpoint returns the old "logoEndpoint" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldLogoMimeType ¶
func (m *InstanceMetadataMutation) OldLogoMimeType(ctx context.Context) (v *string, err error)
OldLogoMimeType returns the old "logoMimeType" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldModeratorsURI ¶
func (m *InstanceMetadataMutation) OldModeratorsURI(ctx context.Context) (v *string, err error)
OldModeratorsURI returns the old "moderatorsURI" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldName ¶
func (m *InstanceMetadataMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldPrivateKey ¶
func (m *InstanceMetadataMutation) OldPrivateKey(ctx context.Context) (v []byte, err error)
OldPrivateKey returns the old "privateKey" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldPublicKey ¶
func (m *InstanceMetadataMutation) OldPublicKey(ctx context.Context) (v []byte, err error)
OldPublicKey returns the old "publicKey" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldPublicKeyAlgorithm ¶
func (m *InstanceMetadataMutation) OldPublicKeyAlgorithm(ctx context.Context) (v string, err error)
OldPublicKeyAlgorithm returns the old "publicKeyAlgorithm" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldSharedInboxURI ¶
func (m *InstanceMetadataMutation) OldSharedInboxURI(ctx context.Context) (v string, err error)
OldSharedInboxURI returns the old "sharedInboxURI" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldSoftwareName ¶
func (m *InstanceMetadataMutation) OldSoftwareName(ctx context.Context) (v string, err error)
OldSoftwareName returns the old "softwareName" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldSoftwareVersion ¶
func (m *InstanceMetadataMutation) OldSoftwareVersion(ctx context.Context) (v string, err error)
OldSoftwareVersion returns the old "softwareVersion" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldSupportedExtensions ¶
func (m *InstanceMetadataMutation) OldSupportedExtensions(ctx context.Context) (v []string, err error)
OldSupportedExtensions returns the old "supportedExtensions" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldSupportedVersions ¶
func (m *InstanceMetadataMutation) OldSupportedVersions(ctx context.Context) (v []string, err error)
OldSupportedVersions returns the old "supportedVersions" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldURI ¶
func (m *InstanceMetadataMutation) OldURI(ctx context.Context) (v string, err error)
OldURI returns the old "uri" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) OldUpdatedAt ¶
OldUpdatedAt returns the old "updated_at" field's value of the InstanceMetadata entity. If the InstanceMetadata 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 (*InstanceMetadataMutation) Op ¶
func (m *InstanceMetadataMutation) Op() Op
Op returns the operation name.
func (*InstanceMetadataMutation) PrivateKey ¶
func (m *InstanceMetadataMutation) PrivateKey() (r []byte, exists bool)
PrivateKey returns the value of the "privateKey" field in the mutation.
func (*InstanceMetadataMutation) PrivateKeyCleared ¶
func (m *InstanceMetadataMutation) PrivateKeyCleared() bool
PrivateKeyCleared returns if the "privateKey" field was cleared in this mutation.
func (*InstanceMetadataMutation) PublicKey ¶
func (m *InstanceMetadataMutation) PublicKey() (r []byte, exists bool)
PublicKey returns the value of the "publicKey" field in the mutation.
func (*InstanceMetadataMutation) PublicKeyAlgorithm ¶
func (m *InstanceMetadataMutation) PublicKeyAlgorithm() (r string, exists bool)
PublicKeyAlgorithm returns the value of the "publicKeyAlgorithm" field in the mutation.
func (*InstanceMetadataMutation) RemoveAdminIDs ¶
func (m *InstanceMetadataMutation) RemoveAdminIDs(ids ...uuid.UUID)
RemoveAdminIDs removes the "admins" edge to the User entity by IDs.
func (*InstanceMetadataMutation) RemoveModeratorIDs ¶
func (m *InstanceMetadataMutation) RemoveModeratorIDs(ids ...uuid.UUID)
RemoveModeratorIDs removes the "moderators" edge to the User entity by IDs.
func (*InstanceMetadataMutation) RemoveUserIDs ¶
func (m *InstanceMetadataMutation) RemoveUserIDs(ids ...uuid.UUID)
RemoveUserIDs removes the "users" edge to the User entity by IDs.
func (*InstanceMetadataMutation) RemovedAdminsIDs ¶
func (m *InstanceMetadataMutation) RemovedAdminsIDs() (ids []uuid.UUID)
RemovedAdmins returns the removed IDs of the "admins" edge to the User entity.
func (*InstanceMetadataMutation) RemovedEdges ¶
func (m *InstanceMetadataMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*InstanceMetadataMutation) RemovedIDs ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) RemovedModeratorsIDs ¶
func (m *InstanceMetadataMutation) RemovedModeratorsIDs() (ids []uuid.UUID)
RemovedModerators returns the removed IDs of the "moderators" edge to the User entity.
func (*InstanceMetadataMutation) RemovedUsersIDs ¶
func (m *InstanceMetadataMutation) RemovedUsersIDs() (ids []uuid.UUID)
RemovedUsers returns the removed IDs of the "users" edge to the User entity.
func (*InstanceMetadataMutation) ResetAdmins ¶
func (m *InstanceMetadataMutation) ResetAdmins()
ResetAdmins resets all changes to the "admins" edge.
func (*InstanceMetadataMutation) ResetAdminsURI ¶
func (m *InstanceMetadataMutation) ResetAdminsURI()
ResetAdminsURI resets all changes to the "adminsURI" field.
func (*InstanceMetadataMutation) ResetBannerEndpoint ¶
func (m *InstanceMetadataMutation) ResetBannerEndpoint()
ResetBannerEndpoint resets all changes to the "bannerEndpoint" field.
func (*InstanceMetadataMutation) ResetBannerMimeType ¶
func (m *InstanceMetadataMutation) ResetBannerMimeType()
ResetBannerMimeType resets all changes to the "bannerMimeType" field.
func (*InstanceMetadataMutation) ResetCreatedAt ¶
func (m *InstanceMetadataMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*InstanceMetadataMutation) ResetDescription ¶
func (m *InstanceMetadataMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*InstanceMetadataMutation) ResetEdge ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) ResetExtensions ¶
func (m *InstanceMetadataMutation) ResetExtensions()
ResetExtensions resets all changes to the "extensions" field.
func (*InstanceMetadataMutation) ResetField ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) ResetHost ¶
func (m *InstanceMetadataMutation) ResetHost()
ResetHost resets all changes to the "host" field.
func (*InstanceMetadataMutation) ResetIsRemote ¶
func (m *InstanceMetadataMutation) ResetIsRemote()
ResetIsRemote resets all changes to the "isRemote" field.
func (*InstanceMetadataMutation) ResetLogoEndpoint ¶
func (m *InstanceMetadataMutation) ResetLogoEndpoint()
ResetLogoEndpoint resets all changes to the "logoEndpoint" field.
func (*InstanceMetadataMutation) ResetLogoMimeType ¶
func (m *InstanceMetadataMutation) ResetLogoMimeType()
ResetLogoMimeType resets all changes to the "logoMimeType" field.
func (*InstanceMetadataMutation) ResetModerators ¶
func (m *InstanceMetadataMutation) ResetModerators()
ResetModerators resets all changes to the "moderators" edge.
func (*InstanceMetadataMutation) ResetModeratorsURI ¶
func (m *InstanceMetadataMutation) ResetModeratorsURI()
ResetModeratorsURI resets all changes to the "moderatorsURI" field.
func (*InstanceMetadataMutation) ResetName ¶
func (m *InstanceMetadataMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*InstanceMetadataMutation) ResetPrivateKey ¶
func (m *InstanceMetadataMutation) ResetPrivateKey()
ResetPrivateKey resets all changes to the "privateKey" field.
func (*InstanceMetadataMutation) ResetPublicKey ¶
func (m *InstanceMetadataMutation) ResetPublicKey()
ResetPublicKey resets all changes to the "publicKey" field.
func (*InstanceMetadataMutation) ResetPublicKeyAlgorithm ¶
func (m *InstanceMetadataMutation) ResetPublicKeyAlgorithm()
ResetPublicKeyAlgorithm resets all changes to the "publicKeyAlgorithm" field.
func (*InstanceMetadataMutation) ResetSharedInboxURI ¶
func (m *InstanceMetadataMutation) ResetSharedInboxURI()
ResetSharedInboxURI resets all changes to the "sharedInboxURI" field.
func (*InstanceMetadataMutation) ResetSoftwareName ¶
func (m *InstanceMetadataMutation) ResetSoftwareName()
ResetSoftwareName resets all changes to the "softwareName" field.
func (*InstanceMetadataMutation) ResetSoftwareVersion ¶
func (m *InstanceMetadataMutation) ResetSoftwareVersion()
ResetSoftwareVersion resets all changes to the "softwareVersion" field.
func (*InstanceMetadataMutation) ResetSupportedExtensions ¶
func (m *InstanceMetadataMutation) ResetSupportedExtensions()
ResetSupportedExtensions resets all changes to the "supportedExtensions" field.
func (*InstanceMetadataMutation) ResetSupportedVersions ¶
func (m *InstanceMetadataMutation) ResetSupportedVersions()
ResetSupportedVersions resets all changes to the "supportedVersions" field.
func (*InstanceMetadataMutation) ResetURI ¶
func (m *InstanceMetadataMutation) ResetURI()
ResetURI resets all changes to the "uri" field.
func (*InstanceMetadataMutation) ResetUpdatedAt ¶
func (m *InstanceMetadataMutation) ResetUpdatedAt()
ResetUpdatedAt resets all changes to the "updated_at" field.
func (*InstanceMetadataMutation) ResetUsers ¶
func (m *InstanceMetadataMutation) ResetUsers()
ResetUsers resets all changes to the "users" edge.
func (*InstanceMetadataMutation) SetAdminsURI ¶
func (m *InstanceMetadataMutation) SetAdminsURI(s string)
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataMutation) SetBannerEndpoint ¶
func (m *InstanceMetadataMutation) SetBannerEndpoint(s string)
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataMutation) SetBannerMimeType ¶
func (m *InstanceMetadataMutation) SetBannerMimeType(s string)
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataMutation) SetCreatedAt ¶
func (m *InstanceMetadataMutation) SetCreatedAt(t time.Time)
SetCreatedAt sets the "created_at" field.
func (*InstanceMetadataMutation) SetDescription ¶
func (m *InstanceMetadataMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*InstanceMetadataMutation) SetExtensions ¶
func (m *InstanceMetadataMutation) SetExtensions(v versia.Extensions)
SetExtensions sets the "extensions" field.
func (*InstanceMetadataMutation) SetField ¶
func (m *InstanceMetadataMutation) 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 (*InstanceMetadataMutation) SetHost ¶
func (m *InstanceMetadataMutation) SetHost(s string)
SetHost sets the "host" field.
func (*InstanceMetadataMutation) SetID ¶
func (m *InstanceMetadataMutation) SetID(id uuid.UUID)
SetID sets the value of the id field. Note that this operation is only accepted on creation of InstanceMetadata entities.
func (*InstanceMetadataMutation) SetIsRemote ¶
func (m *InstanceMetadataMutation) SetIsRemote(b bool)
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataMutation) SetLogoEndpoint ¶
func (m *InstanceMetadataMutation) SetLogoEndpoint(s string)
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataMutation) SetLogoMimeType ¶
func (m *InstanceMetadataMutation) SetLogoMimeType(s string)
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataMutation) SetModeratorsURI ¶
func (m *InstanceMetadataMutation) SetModeratorsURI(s string)
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataMutation) SetName ¶
func (m *InstanceMetadataMutation) SetName(s string)
SetName sets the "name" field.
func (*InstanceMetadataMutation) SetOp ¶
func (m *InstanceMetadataMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*InstanceMetadataMutation) SetPrivateKey ¶
func (m *InstanceMetadataMutation) SetPrivateKey(b []byte)
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataMutation) SetPublicKey ¶
func (m *InstanceMetadataMutation) SetPublicKey(b []byte)
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataMutation) SetPublicKeyAlgorithm ¶
func (m *InstanceMetadataMutation) SetPublicKeyAlgorithm(s string)
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataMutation) SetSharedInboxURI ¶
func (m *InstanceMetadataMutation) SetSharedInboxURI(s string)
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataMutation) SetSoftwareName ¶
func (m *InstanceMetadataMutation) SetSoftwareName(s string)
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataMutation) SetSoftwareVersion ¶
func (m *InstanceMetadataMutation) SetSoftwareVersion(s string)
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataMutation) SetSupportedExtensions ¶
func (m *InstanceMetadataMutation) SetSupportedExtensions(s []string)
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataMutation) SetSupportedVersions ¶
func (m *InstanceMetadataMutation) SetSupportedVersions(s []string)
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataMutation) SetURI ¶
func (m *InstanceMetadataMutation) SetURI(s string)
SetURI sets the "uri" field.
func (*InstanceMetadataMutation) SetUpdatedAt ¶
func (m *InstanceMetadataMutation) SetUpdatedAt(t time.Time)
SetUpdatedAt sets the "updated_at" field.
func (*InstanceMetadataMutation) SharedInboxURI ¶
func (m *InstanceMetadataMutation) SharedInboxURI() (r string, exists bool)
SharedInboxURI returns the value of the "sharedInboxURI" field in the mutation.
func (*InstanceMetadataMutation) SoftwareName ¶
func (m *InstanceMetadataMutation) SoftwareName() (r string, exists bool)
SoftwareName returns the value of the "softwareName" field in the mutation.
func (*InstanceMetadataMutation) SoftwareVersion ¶
func (m *InstanceMetadataMutation) SoftwareVersion() (r string, exists bool)
SoftwareVersion returns the value of the "softwareVersion" field in the mutation.
func (*InstanceMetadataMutation) SupportedExtensions ¶
func (m *InstanceMetadataMutation) SupportedExtensions() (r []string, exists bool)
SupportedExtensions returns the value of the "supportedExtensions" field in the mutation.
func (*InstanceMetadataMutation) SupportedVersions ¶
func (m *InstanceMetadataMutation) SupportedVersions() (r []string, exists bool)
SupportedVersions returns the value of the "supportedVersions" field in the mutation.
func (InstanceMetadataMutation) Tx ¶
func (m InstanceMetadataMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*InstanceMetadataMutation) Type ¶
func (m *InstanceMetadataMutation) Type() string
Type returns the node type of this mutation (InstanceMetadata).
func (*InstanceMetadataMutation) URI ¶
func (m *InstanceMetadataMutation) URI() (r string, exists bool)
URI returns the value of the "uri" field in the mutation.
func (*InstanceMetadataMutation) UpdatedAt ¶
func (m *InstanceMetadataMutation) UpdatedAt() (r time.Time, exists bool)
UpdatedAt returns the value of the "updated_at" field in the mutation.
func (*InstanceMetadataMutation) UsersCleared ¶
func (m *InstanceMetadataMutation) UsersCleared() bool
UsersCleared reports if the "users" edge to the User entity was cleared.
func (*InstanceMetadataMutation) UsersIDs ¶
func (m *InstanceMetadataMutation) UsersIDs() (ids []uuid.UUID)
UsersIDs returns the "users" edge IDs in the mutation.
func (*InstanceMetadataMutation) Where ¶
func (m *InstanceMetadataMutation) Where(ps ...predicate.InstanceMetadata)
Where appends a list predicates to the InstanceMetadataMutation builder.
func (*InstanceMetadataMutation) WhereP ¶
func (m *InstanceMetadataMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the InstanceMetadataMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type InstanceMetadataQuery ¶
type InstanceMetadataQuery struct {
// contains filtered or unexported fields
}
InstanceMetadataQuery is the builder for querying InstanceMetadata entities.
func (*InstanceMetadataQuery) Aggregate ¶
func (imq *InstanceMetadataQuery) Aggregate(fns ...AggregateFunc) *InstanceMetadataSelect
Aggregate returns a InstanceMetadataSelect configured with the given aggregations.
func (*InstanceMetadataQuery) All ¶
func (imq *InstanceMetadataQuery) All(ctx context.Context) ([]*InstanceMetadata, error)
All executes the query and returns a list of InstanceMetadataSlice.
func (*InstanceMetadataQuery) AllX ¶
func (imq *InstanceMetadataQuery) AllX(ctx context.Context) []*InstanceMetadata
AllX is like All, but panics if an error occurs.
func (*InstanceMetadataQuery) Clone ¶
func (imq *InstanceMetadataQuery) Clone() *InstanceMetadataQuery
Clone returns a duplicate of the InstanceMetadataQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*InstanceMetadataQuery) Count ¶
func (imq *InstanceMetadataQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*InstanceMetadataQuery) CountX ¶
func (imq *InstanceMetadataQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*InstanceMetadataQuery) Exist ¶
func (imq *InstanceMetadataQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*InstanceMetadataQuery) ExistX ¶
func (imq *InstanceMetadataQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*InstanceMetadataQuery) First ¶
func (imq *InstanceMetadataQuery) First(ctx context.Context) (*InstanceMetadata, error)
First returns the first InstanceMetadata entity from the query. Returns a *NotFoundError when no InstanceMetadata was found.
func (*InstanceMetadataQuery) FirstID ¶
FirstID returns the first InstanceMetadata ID from the query. Returns a *NotFoundError when no InstanceMetadata ID was found.
func (*InstanceMetadataQuery) FirstIDX ¶
func (imq *InstanceMetadataQuery) FirstIDX(ctx context.Context) uuid.UUID
FirstIDX is like FirstID, but panics if an error occurs.
func (*InstanceMetadataQuery) FirstX ¶
func (imq *InstanceMetadataQuery) FirstX(ctx context.Context) *InstanceMetadata
FirstX is like First, but panics if an error occurs.
func (*InstanceMetadataQuery) GroupBy ¶
func (imq *InstanceMetadataQuery) GroupBy(field string, fields ...string) *InstanceMetadataGroupBy
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 { IsRemote bool `json:"isRemote,omitempty"` Count int `json:"count,omitempty"` } client.InstanceMetadata.Query(). GroupBy(instancemetadata.FieldIsRemote). Aggregate(ent.Count()). Scan(ctx, &v)
func (*InstanceMetadataQuery) IDs ¶
IDs executes the query and returns a list of InstanceMetadata IDs.
func (*InstanceMetadataQuery) IDsX ¶
func (imq *InstanceMetadataQuery) IDsX(ctx context.Context) []uuid.UUID
IDsX is like IDs, but panics if an error occurs.
func (*InstanceMetadataQuery) Limit ¶
func (imq *InstanceMetadataQuery) Limit(limit int) *InstanceMetadataQuery
Limit the number of records to be returned by this query.
func (*InstanceMetadataQuery) Offset ¶
func (imq *InstanceMetadataQuery) Offset(offset int) *InstanceMetadataQuery
Offset to start from.
func (*InstanceMetadataQuery) Only ¶
func (imq *InstanceMetadataQuery) Only(ctx context.Context) (*InstanceMetadata, error)
Only returns a single InstanceMetadata entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one InstanceMetadata entity is found. Returns a *NotFoundError when no InstanceMetadata entities are found.
func (*InstanceMetadataQuery) OnlyID ¶
OnlyID is like Only, but returns the only InstanceMetadata ID in the query. Returns a *NotSingularError when more than one InstanceMetadata ID is found. Returns a *NotFoundError when no entities are found.
func (*InstanceMetadataQuery) OnlyIDX ¶
func (imq *InstanceMetadataQuery) OnlyIDX(ctx context.Context) uuid.UUID
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*InstanceMetadataQuery) OnlyX ¶
func (imq *InstanceMetadataQuery) OnlyX(ctx context.Context) *InstanceMetadata
OnlyX is like Only, but panics if an error occurs.
func (*InstanceMetadataQuery) Order ¶
func (imq *InstanceMetadataQuery) Order(o ...instancemetadata.OrderOption) *InstanceMetadataQuery
Order specifies how the records should be ordered.
func (*InstanceMetadataQuery) QueryAdmins ¶
func (imq *InstanceMetadataQuery) QueryAdmins() *UserQuery
QueryAdmins chains the current query on the "admins" edge.
func (*InstanceMetadataQuery) QueryModerators ¶
func (imq *InstanceMetadataQuery) QueryModerators() *UserQuery
QueryModerators chains the current query on the "moderators" edge.
func (*InstanceMetadataQuery) QueryUsers ¶
func (imq *InstanceMetadataQuery) QueryUsers() *UserQuery
QueryUsers chains the current query on the "users" edge.
func (*InstanceMetadataQuery) Select ¶
func (imq *InstanceMetadataQuery) Select(fields ...string) *InstanceMetadataSelect
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 { IsRemote bool `json:"isRemote,omitempty"` } client.InstanceMetadata.Query(). Select(instancemetadata.FieldIsRemote). Scan(ctx, &v)
func (*InstanceMetadataQuery) Unique ¶
func (imq *InstanceMetadataQuery) Unique(unique bool) *InstanceMetadataQuery
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 (*InstanceMetadataQuery) Where ¶
func (imq *InstanceMetadataQuery) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataQuery
Where adds a new predicate for the InstanceMetadataQuery builder.
func (*InstanceMetadataQuery) WithAdmins ¶
func (imq *InstanceMetadataQuery) WithAdmins(opts ...func(*UserQuery)) *InstanceMetadataQuery
WithAdmins tells the query-builder to eager-load the nodes that are connected to the "admins" edge. The optional arguments are used to configure the query builder of the edge.
func (*InstanceMetadataQuery) WithModerators ¶
func (imq *InstanceMetadataQuery) WithModerators(opts ...func(*UserQuery)) *InstanceMetadataQuery
WithModerators tells the query-builder to eager-load the nodes that are connected to the "moderators" edge. The optional arguments are used to configure the query builder of the edge.
func (*InstanceMetadataQuery) WithUsers ¶
func (imq *InstanceMetadataQuery) WithUsers(opts ...func(*UserQuery)) *InstanceMetadataQuery
WithUsers tells the query-builder to eager-load the nodes that are connected to the "users" edge. The optional arguments are used to configure the query builder of the edge.
type InstanceMetadataSelect ¶
type InstanceMetadataSelect struct { *InstanceMetadataQuery // contains filtered or unexported fields }
InstanceMetadataSelect is the builder for selecting fields of InstanceMetadata entities.
func (*InstanceMetadataSelect) Aggregate ¶
func (ims *InstanceMetadataSelect) Aggregate(fns ...AggregateFunc) *InstanceMetadataSelect
Aggregate adds the given aggregation functions to the selector query.
func (*InstanceMetadataSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataSelect) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*InstanceMetadataSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*InstanceMetadataSelect) Scan ¶
func (ims *InstanceMetadataSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*InstanceMetadataSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type InstanceMetadataSlice ¶
type InstanceMetadataSlice []*InstanceMetadata
InstanceMetadataSlice is a parsable slice of InstanceMetadata.
type InstanceMetadataUpdate ¶
type InstanceMetadataUpdate struct {
// contains filtered or unexported fields
}
InstanceMetadataUpdate is the builder for updating InstanceMetadata entities.
func (*InstanceMetadataUpdate) AddAdminIDs ¶
func (imu *InstanceMetadataUpdate) AddAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
AddAdminIDs adds the "admins" edge to the User entity by IDs.
func (*InstanceMetadataUpdate) AddAdmins ¶
func (imu *InstanceMetadataUpdate) AddAdmins(u ...*User) *InstanceMetadataUpdate
AddAdmins adds the "admins" edges to the User entity.
func (*InstanceMetadataUpdate) AddModeratorIDs ¶
func (imu *InstanceMetadataUpdate) AddModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
AddModeratorIDs adds the "moderators" edge to the User entity by IDs.
func (*InstanceMetadataUpdate) AddModerators ¶
func (imu *InstanceMetadataUpdate) AddModerators(u ...*User) *InstanceMetadataUpdate
AddModerators adds the "moderators" edges to the User entity.
func (*InstanceMetadataUpdate) AddUserIDs ¶
func (imu *InstanceMetadataUpdate) AddUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
AddUserIDs adds the "users" edge to the User entity by IDs.
func (*InstanceMetadataUpdate) AddUsers ¶
func (imu *InstanceMetadataUpdate) AddUsers(u ...*User) *InstanceMetadataUpdate
AddUsers adds the "users" edges to the User entity.
func (*InstanceMetadataUpdate) AppendSupportedExtensions ¶
func (imu *InstanceMetadataUpdate) AppendSupportedExtensions(s []string) *InstanceMetadataUpdate
AppendSupportedExtensions appends s to the "supportedExtensions" field.
func (*InstanceMetadataUpdate) AppendSupportedVersions ¶
func (imu *InstanceMetadataUpdate) AppendSupportedVersions(s []string) *InstanceMetadataUpdate
AppendSupportedVersions appends s to the "supportedVersions" field.
func (*InstanceMetadataUpdate) ClearAdmins ¶
func (imu *InstanceMetadataUpdate) ClearAdmins() *InstanceMetadataUpdate
ClearAdmins clears all "admins" edges to the User entity.
func (*InstanceMetadataUpdate) ClearAdminsURI ¶
func (imu *InstanceMetadataUpdate) ClearAdminsURI() *InstanceMetadataUpdate
ClearAdminsURI clears the value of the "adminsURI" field.
func (*InstanceMetadataUpdate) ClearBannerEndpoint ¶
func (imu *InstanceMetadataUpdate) ClearBannerEndpoint() *InstanceMetadataUpdate
ClearBannerEndpoint clears the value of the "bannerEndpoint" field.
func (*InstanceMetadataUpdate) ClearBannerMimeType ¶
func (imu *InstanceMetadataUpdate) ClearBannerMimeType() *InstanceMetadataUpdate
ClearBannerMimeType clears the value of the "bannerMimeType" field.
func (*InstanceMetadataUpdate) ClearDescription ¶
func (imu *InstanceMetadataUpdate) ClearDescription() *InstanceMetadataUpdate
ClearDescription clears the value of the "description" field.
func (*InstanceMetadataUpdate) ClearLogoEndpoint ¶
func (imu *InstanceMetadataUpdate) ClearLogoEndpoint() *InstanceMetadataUpdate
ClearLogoEndpoint clears the value of the "logoEndpoint" field.
func (*InstanceMetadataUpdate) ClearLogoMimeType ¶
func (imu *InstanceMetadataUpdate) ClearLogoMimeType() *InstanceMetadataUpdate
ClearLogoMimeType clears the value of the "logoMimeType" field.
func (*InstanceMetadataUpdate) ClearModerators ¶
func (imu *InstanceMetadataUpdate) ClearModerators() *InstanceMetadataUpdate
ClearModerators clears all "moderators" edges to the User entity.
func (*InstanceMetadataUpdate) ClearModeratorsURI ¶
func (imu *InstanceMetadataUpdate) ClearModeratorsURI() *InstanceMetadataUpdate
ClearModeratorsURI clears the value of the "moderatorsURI" field.
func (*InstanceMetadataUpdate) ClearPrivateKey ¶
func (imu *InstanceMetadataUpdate) ClearPrivateKey() *InstanceMetadataUpdate
ClearPrivateKey clears the value of the "privateKey" field.
func (*InstanceMetadataUpdate) ClearUsers ¶
func (imu *InstanceMetadataUpdate) ClearUsers() *InstanceMetadataUpdate
ClearUsers clears all "users" edges to the User entity.
func (*InstanceMetadataUpdate) Exec ¶
func (imu *InstanceMetadataUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*InstanceMetadataUpdate) ExecX ¶
func (imu *InstanceMetadataUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataUpdate) Mutation ¶
func (imu *InstanceMetadataUpdate) Mutation() *InstanceMetadataMutation
Mutation returns the InstanceMetadataMutation object of the builder.
func (*InstanceMetadataUpdate) RemoveAdminIDs ¶
func (imu *InstanceMetadataUpdate) RemoveAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
RemoveAdminIDs removes the "admins" edge to User entities by IDs.
func (*InstanceMetadataUpdate) RemoveAdmins ¶
func (imu *InstanceMetadataUpdate) RemoveAdmins(u ...*User) *InstanceMetadataUpdate
RemoveAdmins removes "admins" edges to User entities.
func (*InstanceMetadataUpdate) RemoveModeratorIDs ¶
func (imu *InstanceMetadataUpdate) RemoveModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
RemoveModeratorIDs removes the "moderators" edge to User entities by IDs.
func (*InstanceMetadataUpdate) RemoveModerators ¶
func (imu *InstanceMetadataUpdate) RemoveModerators(u ...*User) *InstanceMetadataUpdate
RemoveModerators removes "moderators" edges to User entities.
func (*InstanceMetadataUpdate) RemoveUserIDs ¶
func (imu *InstanceMetadataUpdate) RemoveUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdate
RemoveUserIDs removes the "users" edge to User entities by IDs.
func (*InstanceMetadataUpdate) RemoveUsers ¶
func (imu *InstanceMetadataUpdate) RemoveUsers(u ...*User) *InstanceMetadataUpdate
RemoveUsers removes "users" edges to User entities.
func (*InstanceMetadataUpdate) Save ¶
func (imu *InstanceMetadataUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*InstanceMetadataUpdate) SaveX ¶
func (imu *InstanceMetadataUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*InstanceMetadataUpdate) SetAdminsURI ¶
func (imu *InstanceMetadataUpdate) SetAdminsURI(s string) *InstanceMetadataUpdate
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataUpdate) SetBannerEndpoint ¶
func (imu *InstanceMetadataUpdate) SetBannerEndpoint(s string) *InstanceMetadataUpdate
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataUpdate) SetBannerMimeType ¶
func (imu *InstanceMetadataUpdate) SetBannerMimeType(s string) *InstanceMetadataUpdate
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataUpdate) SetDescription ¶
func (imu *InstanceMetadataUpdate) SetDescription(s string) *InstanceMetadataUpdate
SetDescription sets the "description" field.
func (*InstanceMetadataUpdate) SetExtensions ¶
func (imu *InstanceMetadataUpdate) SetExtensions(v versia.Extensions) *InstanceMetadataUpdate
SetExtensions sets the "extensions" field.
func (*InstanceMetadataUpdate) SetHost ¶
func (imu *InstanceMetadataUpdate) SetHost(s string) *InstanceMetadataUpdate
SetHost sets the "host" field.
func (*InstanceMetadataUpdate) SetIsRemote ¶
func (imu *InstanceMetadataUpdate) SetIsRemote(b bool) *InstanceMetadataUpdate
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataUpdate) SetLogoEndpoint ¶
func (imu *InstanceMetadataUpdate) SetLogoEndpoint(s string) *InstanceMetadataUpdate
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataUpdate) SetLogoMimeType ¶
func (imu *InstanceMetadataUpdate) SetLogoMimeType(s string) *InstanceMetadataUpdate
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataUpdate) SetModeratorsURI ¶
func (imu *InstanceMetadataUpdate) SetModeratorsURI(s string) *InstanceMetadataUpdate
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataUpdate) SetName ¶
func (imu *InstanceMetadataUpdate) SetName(s string) *InstanceMetadataUpdate
SetName sets the "name" field.
func (*InstanceMetadataUpdate) SetNillableAdminsURI ¶
func (imu *InstanceMetadataUpdate) SetNillableAdminsURI(s *string) *InstanceMetadataUpdate
SetNillableAdminsURI sets the "adminsURI" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableBannerEndpoint ¶
func (imu *InstanceMetadataUpdate) SetNillableBannerEndpoint(s *string) *InstanceMetadataUpdate
SetNillableBannerEndpoint sets the "bannerEndpoint" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableBannerMimeType ¶
func (imu *InstanceMetadataUpdate) SetNillableBannerMimeType(s *string) *InstanceMetadataUpdate
SetNillableBannerMimeType sets the "bannerMimeType" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableDescription ¶
func (imu *InstanceMetadataUpdate) SetNillableDescription(s *string) *InstanceMetadataUpdate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableHost ¶
func (imu *InstanceMetadataUpdate) SetNillableHost(s *string) *InstanceMetadataUpdate
SetNillableHost sets the "host" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableIsRemote ¶
func (imu *InstanceMetadataUpdate) SetNillableIsRemote(b *bool) *InstanceMetadataUpdate
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableLogoEndpoint ¶
func (imu *InstanceMetadataUpdate) SetNillableLogoEndpoint(s *string) *InstanceMetadataUpdate
SetNillableLogoEndpoint sets the "logoEndpoint" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableLogoMimeType ¶
func (imu *InstanceMetadataUpdate) SetNillableLogoMimeType(s *string) *InstanceMetadataUpdate
SetNillableLogoMimeType sets the "logoMimeType" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableModeratorsURI ¶
func (imu *InstanceMetadataUpdate) SetNillableModeratorsURI(s *string) *InstanceMetadataUpdate
SetNillableModeratorsURI sets the "moderatorsURI" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableName ¶
func (imu *InstanceMetadataUpdate) SetNillableName(s *string) *InstanceMetadataUpdate
SetNillableName sets the "name" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillablePublicKeyAlgorithm ¶
func (imu *InstanceMetadataUpdate) SetNillablePublicKeyAlgorithm(s *string) *InstanceMetadataUpdate
SetNillablePublicKeyAlgorithm sets the "publicKeyAlgorithm" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableSharedInboxURI ¶
func (imu *InstanceMetadataUpdate) SetNillableSharedInboxURI(s *string) *InstanceMetadataUpdate
SetNillableSharedInboxURI sets the "sharedInboxURI" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableSoftwareName ¶
func (imu *InstanceMetadataUpdate) SetNillableSoftwareName(s *string) *InstanceMetadataUpdate
SetNillableSoftwareName sets the "softwareName" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableSoftwareVersion ¶
func (imu *InstanceMetadataUpdate) SetNillableSoftwareVersion(s *string) *InstanceMetadataUpdate
SetNillableSoftwareVersion sets the "softwareVersion" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetNillableURI ¶
func (imu *InstanceMetadataUpdate) SetNillableURI(s *string) *InstanceMetadataUpdate
SetNillableURI sets the "uri" field if the given value is not nil.
func (*InstanceMetadataUpdate) SetPrivateKey ¶
func (imu *InstanceMetadataUpdate) SetPrivateKey(b []byte) *InstanceMetadataUpdate
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataUpdate) SetPublicKey ¶
func (imu *InstanceMetadataUpdate) SetPublicKey(b []byte) *InstanceMetadataUpdate
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataUpdate) SetPublicKeyAlgorithm ¶
func (imu *InstanceMetadataUpdate) SetPublicKeyAlgorithm(s string) *InstanceMetadataUpdate
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataUpdate) SetSharedInboxURI ¶
func (imu *InstanceMetadataUpdate) SetSharedInboxURI(s string) *InstanceMetadataUpdate
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataUpdate) SetSoftwareName ¶
func (imu *InstanceMetadataUpdate) SetSoftwareName(s string) *InstanceMetadataUpdate
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataUpdate) SetSoftwareVersion ¶
func (imu *InstanceMetadataUpdate) SetSoftwareVersion(s string) *InstanceMetadataUpdate
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataUpdate) SetSupportedExtensions ¶
func (imu *InstanceMetadataUpdate) SetSupportedExtensions(s []string) *InstanceMetadataUpdate
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataUpdate) SetSupportedVersions ¶
func (imu *InstanceMetadataUpdate) SetSupportedVersions(s []string) *InstanceMetadataUpdate
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataUpdate) SetURI ¶
func (imu *InstanceMetadataUpdate) SetURI(s string) *InstanceMetadataUpdate
SetURI sets the "uri" field.
func (*InstanceMetadataUpdate) SetUpdatedAt ¶
func (imu *InstanceMetadataUpdate) SetUpdatedAt(t time.Time) *InstanceMetadataUpdate
SetUpdatedAt sets the "updated_at" field.
func (*InstanceMetadataUpdate) Where ¶
func (imu *InstanceMetadataUpdate) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataUpdate
Where appends a list predicates to the InstanceMetadataUpdate builder.
type InstanceMetadataUpdateOne ¶
type InstanceMetadataUpdateOne struct {
// contains filtered or unexported fields
}
InstanceMetadataUpdateOne is the builder for updating a single InstanceMetadata entity.
func (*InstanceMetadataUpdateOne) AddAdminIDs ¶
func (imuo *InstanceMetadataUpdateOne) AddAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
AddAdminIDs adds the "admins" edge to the User entity by IDs.
func (*InstanceMetadataUpdateOne) AddAdmins ¶
func (imuo *InstanceMetadataUpdateOne) AddAdmins(u ...*User) *InstanceMetadataUpdateOne
AddAdmins adds the "admins" edges to the User entity.
func (*InstanceMetadataUpdateOne) AddModeratorIDs ¶
func (imuo *InstanceMetadataUpdateOne) AddModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
AddModeratorIDs adds the "moderators" edge to the User entity by IDs.
func (*InstanceMetadataUpdateOne) AddModerators ¶
func (imuo *InstanceMetadataUpdateOne) AddModerators(u ...*User) *InstanceMetadataUpdateOne
AddModerators adds the "moderators" edges to the User entity.
func (*InstanceMetadataUpdateOne) AddUserIDs ¶
func (imuo *InstanceMetadataUpdateOne) AddUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
AddUserIDs adds the "users" edge to the User entity by IDs.
func (*InstanceMetadataUpdateOne) AddUsers ¶
func (imuo *InstanceMetadataUpdateOne) AddUsers(u ...*User) *InstanceMetadataUpdateOne
AddUsers adds the "users" edges to the User entity.
func (*InstanceMetadataUpdateOne) AppendSupportedExtensions ¶
func (imuo *InstanceMetadataUpdateOne) AppendSupportedExtensions(s []string) *InstanceMetadataUpdateOne
AppendSupportedExtensions appends s to the "supportedExtensions" field.
func (*InstanceMetadataUpdateOne) AppendSupportedVersions ¶
func (imuo *InstanceMetadataUpdateOne) AppendSupportedVersions(s []string) *InstanceMetadataUpdateOne
AppendSupportedVersions appends s to the "supportedVersions" field.
func (*InstanceMetadataUpdateOne) ClearAdmins ¶
func (imuo *InstanceMetadataUpdateOne) ClearAdmins() *InstanceMetadataUpdateOne
ClearAdmins clears all "admins" edges to the User entity.
func (*InstanceMetadataUpdateOne) ClearAdminsURI ¶
func (imuo *InstanceMetadataUpdateOne) ClearAdminsURI() *InstanceMetadataUpdateOne
ClearAdminsURI clears the value of the "adminsURI" field.
func (*InstanceMetadataUpdateOne) ClearBannerEndpoint ¶
func (imuo *InstanceMetadataUpdateOne) ClearBannerEndpoint() *InstanceMetadataUpdateOne
ClearBannerEndpoint clears the value of the "bannerEndpoint" field.
func (*InstanceMetadataUpdateOne) ClearBannerMimeType ¶
func (imuo *InstanceMetadataUpdateOne) ClearBannerMimeType() *InstanceMetadataUpdateOne
ClearBannerMimeType clears the value of the "bannerMimeType" field.
func (*InstanceMetadataUpdateOne) ClearDescription ¶
func (imuo *InstanceMetadataUpdateOne) ClearDescription() *InstanceMetadataUpdateOne
ClearDescription clears the value of the "description" field.
func (*InstanceMetadataUpdateOne) ClearLogoEndpoint ¶
func (imuo *InstanceMetadataUpdateOne) ClearLogoEndpoint() *InstanceMetadataUpdateOne
ClearLogoEndpoint clears the value of the "logoEndpoint" field.
func (*InstanceMetadataUpdateOne) ClearLogoMimeType ¶
func (imuo *InstanceMetadataUpdateOne) ClearLogoMimeType() *InstanceMetadataUpdateOne
ClearLogoMimeType clears the value of the "logoMimeType" field.
func (*InstanceMetadataUpdateOne) ClearModerators ¶
func (imuo *InstanceMetadataUpdateOne) ClearModerators() *InstanceMetadataUpdateOne
ClearModerators clears all "moderators" edges to the User entity.
func (*InstanceMetadataUpdateOne) ClearModeratorsURI ¶
func (imuo *InstanceMetadataUpdateOne) ClearModeratorsURI() *InstanceMetadataUpdateOne
ClearModeratorsURI clears the value of the "moderatorsURI" field.
func (*InstanceMetadataUpdateOne) ClearPrivateKey ¶
func (imuo *InstanceMetadataUpdateOne) ClearPrivateKey() *InstanceMetadataUpdateOne
ClearPrivateKey clears the value of the "privateKey" field.
func (*InstanceMetadataUpdateOne) ClearUsers ¶
func (imuo *InstanceMetadataUpdateOne) ClearUsers() *InstanceMetadataUpdateOne
ClearUsers clears all "users" edges to the User entity.
func (*InstanceMetadataUpdateOne) Exec ¶
func (imuo *InstanceMetadataUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*InstanceMetadataUpdateOne) ExecX ¶
func (imuo *InstanceMetadataUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataUpdateOne) Mutation ¶
func (imuo *InstanceMetadataUpdateOne) Mutation() *InstanceMetadataMutation
Mutation returns the InstanceMetadataMutation object of the builder.
func (*InstanceMetadataUpdateOne) RemoveAdminIDs ¶
func (imuo *InstanceMetadataUpdateOne) RemoveAdminIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
RemoveAdminIDs removes the "admins" edge to User entities by IDs.
func (*InstanceMetadataUpdateOne) RemoveAdmins ¶
func (imuo *InstanceMetadataUpdateOne) RemoveAdmins(u ...*User) *InstanceMetadataUpdateOne
RemoveAdmins removes "admins" edges to User entities.
func (*InstanceMetadataUpdateOne) RemoveModeratorIDs ¶
func (imuo *InstanceMetadataUpdateOne) RemoveModeratorIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
RemoveModeratorIDs removes the "moderators" edge to User entities by IDs.
func (*InstanceMetadataUpdateOne) RemoveModerators ¶
func (imuo *InstanceMetadataUpdateOne) RemoveModerators(u ...*User) *InstanceMetadataUpdateOne
RemoveModerators removes "moderators" edges to User entities.
func (*InstanceMetadataUpdateOne) RemoveUserIDs ¶
func (imuo *InstanceMetadataUpdateOne) RemoveUserIDs(ids ...uuid.UUID) *InstanceMetadataUpdateOne
RemoveUserIDs removes the "users" edge to User entities by IDs.
func (*InstanceMetadataUpdateOne) RemoveUsers ¶
func (imuo *InstanceMetadataUpdateOne) RemoveUsers(u ...*User) *InstanceMetadataUpdateOne
RemoveUsers removes "users" edges to User entities.
func (*InstanceMetadataUpdateOne) Save ¶
func (imuo *InstanceMetadataUpdateOne) Save(ctx context.Context) (*InstanceMetadata, error)
Save executes the query and returns the updated InstanceMetadata entity.
func (*InstanceMetadataUpdateOne) SaveX ¶
func (imuo *InstanceMetadataUpdateOne) SaveX(ctx context.Context) *InstanceMetadata
SaveX is like Save, but panics if an error occurs.
func (*InstanceMetadataUpdateOne) Select ¶
func (imuo *InstanceMetadataUpdateOne) Select(field string, fields ...string) *InstanceMetadataUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*InstanceMetadataUpdateOne) SetAdminsURI ¶
func (imuo *InstanceMetadataUpdateOne) SetAdminsURI(s string) *InstanceMetadataUpdateOne
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataUpdateOne) SetBannerEndpoint ¶
func (imuo *InstanceMetadataUpdateOne) SetBannerEndpoint(s string) *InstanceMetadataUpdateOne
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataUpdateOne) SetBannerMimeType ¶
func (imuo *InstanceMetadataUpdateOne) SetBannerMimeType(s string) *InstanceMetadataUpdateOne
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataUpdateOne) SetDescription ¶
func (imuo *InstanceMetadataUpdateOne) SetDescription(s string) *InstanceMetadataUpdateOne
SetDescription sets the "description" field.
func (*InstanceMetadataUpdateOne) SetExtensions ¶
func (imuo *InstanceMetadataUpdateOne) SetExtensions(v versia.Extensions) *InstanceMetadataUpdateOne
SetExtensions sets the "extensions" field.
func (*InstanceMetadataUpdateOne) SetHost ¶
func (imuo *InstanceMetadataUpdateOne) SetHost(s string) *InstanceMetadataUpdateOne
SetHost sets the "host" field.
func (*InstanceMetadataUpdateOne) SetIsRemote ¶
func (imuo *InstanceMetadataUpdateOne) SetIsRemote(b bool) *InstanceMetadataUpdateOne
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataUpdateOne) SetLogoEndpoint ¶
func (imuo *InstanceMetadataUpdateOne) SetLogoEndpoint(s string) *InstanceMetadataUpdateOne
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataUpdateOne) SetLogoMimeType ¶
func (imuo *InstanceMetadataUpdateOne) SetLogoMimeType(s string) *InstanceMetadataUpdateOne
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataUpdateOne) SetModeratorsURI ¶
func (imuo *InstanceMetadataUpdateOne) SetModeratorsURI(s string) *InstanceMetadataUpdateOne
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataUpdateOne) SetName ¶
func (imuo *InstanceMetadataUpdateOne) SetName(s string) *InstanceMetadataUpdateOne
SetName sets the "name" field.
func (*InstanceMetadataUpdateOne) SetNillableAdminsURI ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableAdminsURI(s *string) *InstanceMetadataUpdateOne
SetNillableAdminsURI sets the "adminsURI" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableBannerEndpoint ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableBannerEndpoint(s *string) *InstanceMetadataUpdateOne
SetNillableBannerEndpoint sets the "bannerEndpoint" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableBannerMimeType ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableBannerMimeType(s *string) *InstanceMetadataUpdateOne
SetNillableBannerMimeType sets the "bannerMimeType" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableDescription ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableDescription(s *string) *InstanceMetadataUpdateOne
SetNillableDescription sets the "description" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableHost ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableHost(s *string) *InstanceMetadataUpdateOne
SetNillableHost sets the "host" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableIsRemote ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableIsRemote(b *bool) *InstanceMetadataUpdateOne
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableLogoEndpoint ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableLogoEndpoint(s *string) *InstanceMetadataUpdateOne
SetNillableLogoEndpoint sets the "logoEndpoint" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableLogoMimeType ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableLogoMimeType(s *string) *InstanceMetadataUpdateOne
SetNillableLogoMimeType sets the "logoMimeType" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableModeratorsURI ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableModeratorsURI(s *string) *InstanceMetadataUpdateOne
SetNillableModeratorsURI sets the "moderatorsURI" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableName ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableName(s *string) *InstanceMetadataUpdateOne
SetNillableName sets the "name" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillablePublicKeyAlgorithm ¶
func (imuo *InstanceMetadataUpdateOne) SetNillablePublicKeyAlgorithm(s *string) *InstanceMetadataUpdateOne
SetNillablePublicKeyAlgorithm sets the "publicKeyAlgorithm" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableSharedInboxURI ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableSharedInboxURI(s *string) *InstanceMetadataUpdateOne
SetNillableSharedInboxURI sets the "sharedInboxURI" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableSoftwareName ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableSoftwareName(s *string) *InstanceMetadataUpdateOne
SetNillableSoftwareName sets the "softwareName" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableSoftwareVersion ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableSoftwareVersion(s *string) *InstanceMetadataUpdateOne
SetNillableSoftwareVersion sets the "softwareVersion" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetNillableURI ¶
func (imuo *InstanceMetadataUpdateOne) SetNillableURI(s *string) *InstanceMetadataUpdateOne
SetNillableURI sets the "uri" field if the given value is not nil.
func (*InstanceMetadataUpdateOne) SetPrivateKey ¶
func (imuo *InstanceMetadataUpdateOne) SetPrivateKey(b []byte) *InstanceMetadataUpdateOne
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataUpdateOne) SetPublicKey ¶
func (imuo *InstanceMetadataUpdateOne) SetPublicKey(b []byte) *InstanceMetadataUpdateOne
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataUpdateOne) SetPublicKeyAlgorithm ¶
func (imuo *InstanceMetadataUpdateOne) SetPublicKeyAlgorithm(s string) *InstanceMetadataUpdateOne
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataUpdateOne) SetSharedInboxURI ¶
func (imuo *InstanceMetadataUpdateOne) SetSharedInboxURI(s string) *InstanceMetadataUpdateOne
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataUpdateOne) SetSoftwareName ¶
func (imuo *InstanceMetadataUpdateOne) SetSoftwareName(s string) *InstanceMetadataUpdateOne
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataUpdateOne) SetSoftwareVersion ¶
func (imuo *InstanceMetadataUpdateOne) SetSoftwareVersion(s string) *InstanceMetadataUpdateOne
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataUpdateOne) SetSupportedExtensions ¶
func (imuo *InstanceMetadataUpdateOne) SetSupportedExtensions(s []string) *InstanceMetadataUpdateOne
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataUpdateOne) SetSupportedVersions ¶
func (imuo *InstanceMetadataUpdateOne) SetSupportedVersions(s []string) *InstanceMetadataUpdateOne
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataUpdateOne) SetURI ¶
func (imuo *InstanceMetadataUpdateOne) SetURI(s string) *InstanceMetadataUpdateOne
SetURI sets the "uri" field.
func (*InstanceMetadataUpdateOne) SetUpdatedAt ¶
func (imuo *InstanceMetadataUpdateOne) SetUpdatedAt(t time.Time) *InstanceMetadataUpdateOne
SetUpdatedAt sets the "updated_at" field.
func (*InstanceMetadataUpdateOne) Where ¶
func (imuo *InstanceMetadataUpdateOne) Where(ps ...predicate.InstanceMetadata) *InstanceMetadataUpdateOne
Where appends a list predicates to the InstanceMetadataUpdate builder.
type InstanceMetadataUpsert ¶
InstanceMetadataUpsert is the "OnConflict" setter.
func (*InstanceMetadataUpsert) ClearAdminsURI ¶
func (u *InstanceMetadataUpsert) ClearAdminsURI() *InstanceMetadataUpsert
ClearAdminsURI clears the value of the "adminsURI" field.
func (*InstanceMetadataUpsert) ClearBannerEndpoint ¶
func (u *InstanceMetadataUpsert) ClearBannerEndpoint() *InstanceMetadataUpsert
ClearBannerEndpoint clears the value of the "bannerEndpoint" field.
func (*InstanceMetadataUpsert) ClearBannerMimeType ¶
func (u *InstanceMetadataUpsert) ClearBannerMimeType() *InstanceMetadataUpsert
ClearBannerMimeType clears the value of the "bannerMimeType" field.
func (*InstanceMetadataUpsert) ClearDescription ¶
func (u *InstanceMetadataUpsert) ClearDescription() *InstanceMetadataUpsert
ClearDescription clears the value of the "description" field.
func (*InstanceMetadataUpsert) ClearLogoEndpoint ¶
func (u *InstanceMetadataUpsert) ClearLogoEndpoint() *InstanceMetadataUpsert
ClearLogoEndpoint clears the value of the "logoEndpoint" field.
func (*InstanceMetadataUpsert) ClearLogoMimeType ¶
func (u *InstanceMetadataUpsert) ClearLogoMimeType() *InstanceMetadataUpsert
ClearLogoMimeType clears the value of the "logoMimeType" field.
func (*InstanceMetadataUpsert) ClearModeratorsURI ¶
func (u *InstanceMetadataUpsert) ClearModeratorsURI() *InstanceMetadataUpsert
ClearModeratorsURI clears the value of the "moderatorsURI" field.
func (*InstanceMetadataUpsert) ClearPrivateKey ¶
func (u *InstanceMetadataUpsert) ClearPrivateKey() *InstanceMetadataUpsert
ClearPrivateKey clears the value of the "privateKey" field.
func (*InstanceMetadataUpsert) SetAdminsURI ¶
func (u *InstanceMetadataUpsert) SetAdminsURI(v string) *InstanceMetadataUpsert
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataUpsert) SetBannerEndpoint ¶
func (u *InstanceMetadataUpsert) SetBannerEndpoint(v string) *InstanceMetadataUpsert
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataUpsert) SetBannerMimeType ¶
func (u *InstanceMetadataUpsert) SetBannerMimeType(v string) *InstanceMetadataUpsert
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataUpsert) SetDescription ¶
func (u *InstanceMetadataUpsert) SetDescription(v string) *InstanceMetadataUpsert
SetDescription sets the "description" field.
func (*InstanceMetadataUpsert) SetExtensions ¶
func (u *InstanceMetadataUpsert) SetExtensions(v versia.Extensions) *InstanceMetadataUpsert
SetExtensions sets the "extensions" field.
func (*InstanceMetadataUpsert) SetHost ¶
func (u *InstanceMetadataUpsert) SetHost(v string) *InstanceMetadataUpsert
SetHost sets the "host" field.
func (*InstanceMetadataUpsert) SetIsRemote ¶
func (u *InstanceMetadataUpsert) SetIsRemote(v bool) *InstanceMetadataUpsert
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataUpsert) SetLogoEndpoint ¶
func (u *InstanceMetadataUpsert) SetLogoEndpoint(v string) *InstanceMetadataUpsert
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataUpsert) SetLogoMimeType ¶
func (u *InstanceMetadataUpsert) SetLogoMimeType(v string) *InstanceMetadataUpsert
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataUpsert) SetModeratorsURI ¶
func (u *InstanceMetadataUpsert) SetModeratorsURI(v string) *InstanceMetadataUpsert
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataUpsert) SetName ¶
func (u *InstanceMetadataUpsert) SetName(v string) *InstanceMetadataUpsert
SetName sets the "name" field.
func (*InstanceMetadataUpsert) SetPrivateKey ¶
func (u *InstanceMetadataUpsert) SetPrivateKey(v []byte) *InstanceMetadataUpsert
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataUpsert) SetPublicKey ¶
func (u *InstanceMetadataUpsert) SetPublicKey(v []byte) *InstanceMetadataUpsert
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataUpsert) SetPublicKeyAlgorithm ¶
func (u *InstanceMetadataUpsert) SetPublicKeyAlgorithm(v string) *InstanceMetadataUpsert
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataUpsert) SetSharedInboxURI ¶
func (u *InstanceMetadataUpsert) SetSharedInboxURI(v string) *InstanceMetadataUpsert
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataUpsert) SetSoftwareName ¶
func (u *InstanceMetadataUpsert) SetSoftwareName(v string) *InstanceMetadataUpsert
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataUpsert) SetSoftwareVersion ¶
func (u *InstanceMetadataUpsert) SetSoftwareVersion(v string) *InstanceMetadataUpsert
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataUpsert) SetSupportedExtensions ¶
func (u *InstanceMetadataUpsert) SetSupportedExtensions(v []string) *InstanceMetadataUpsert
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataUpsert) SetSupportedVersions ¶
func (u *InstanceMetadataUpsert) SetSupportedVersions(v []string) *InstanceMetadataUpsert
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataUpsert) SetURI ¶
func (u *InstanceMetadataUpsert) SetURI(v string) *InstanceMetadataUpsert
SetURI sets the "uri" field.
func (*InstanceMetadataUpsert) SetUpdatedAt ¶
func (u *InstanceMetadataUpsert) SetUpdatedAt(v time.Time) *InstanceMetadataUpsert
SetUpdatedAt sets the "updated_at" field.
func (*InstanceMetadataUpsert) UpdateAdminsURI ¶
func (u *InstanceMetadataUpsert) UpdateAdminsURI() *InstanceMetadataUpsert
UpdateAdminsURI sets the "adminsURI" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateBannerEndpoint ¶
func (u *InstanceMetadataUpsert) UpdateBannerEndpoint() *InstanceMetadataUpsert
UpdateBannerEndpoint sets the "bannerEndpoint" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateBannerMimeType ¶
func (u *InstanceMetadataUpsert) UpdateBannerMimeType() *InstanceMetadataUpsert
UpdateBannerMimeType sets the "bannerMimeType" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateDescription ¶
func (u *InstanceMetadataUpsert) UpdateDescription() *InstanceMetadataUpsert
UpdateDescription sets the "description" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateExtensions ¶
func (u *InstanceMetadataUpsert) UpdateExtensions() *InstanceMetadataUpsert
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateHost ¶
func (u *InstanceMetadataUpsert) UpdateHost() *InstanceMetadataUpsert
UpdateHost sets the "host" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateIsRemote ¶
func (u *InstanceMetadataUpsert) UpdateIsRemote() *InstanceMetadataUpsert
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateLogoEndpoint ¶
func (u *InstanceMetadataUpsert) UpdateLogoEndpoint() *InstanceMetadataUpsert
UpdateLogoEndpoint sets the "logoEndpoint" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateLogoMimeType ¶
func (u *InstanceMetadataUpsert) UpdateLogoMimeType() *InstanceMetadataUpsert
UpdateLogoMimeType sets the "logoMimeType" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateModeratorsURI ¶
func (u *InstanceMetadataUpsert) UpdateModeratorsURI() *InstanceMetadataUpsert
UpdateModeratorsURI sets the "moderatorsURI" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateName ¶
func (u *InstanceMetadataUpsert) UpdateName() *InstanceMetadataUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdatePrivateKey ¶
func (u *InstanceMetadataUpsert) UpdatePrivateKey() *InstanceMetadataUpsert
UpdatePrivateKey sets the "privateKey" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdatePublicKey ¶
func (u *InstanceMetadataUpsert) UpdatePublicKey() *InstanceMetadataUpsert
UpdatePublicKey sets the "publicKey" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdatePublicKeyAlgorithm ¶
func (u *InstanceMetadataUpsert) UpdatePublicKeyAlgorithm() *InstanceMetadataUpsert
UpdatePublicKeyAlgorithm sets the "publicKeyAlgorithm" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateSharedInboxURI ¶
func (u *InstanceMetadataUpsert) UpdateSharedInboxURI() *InstanceMetadataUpsert
UpdateSharedInboxURI sets the "sharedInboxURI" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateSoftwareName ¶
func (u *InstanceMetadataUpsert) UpdateSoftwareName() *InstanceMetadataUpsert
UpdateSoftwareName sets the "softwareName" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateSoftwareVersion ¶
func (u *InstanceMetadataUpsert) UpdateSoftwareVersion() *InstanceMetadataUpsert
UpdateSoftwareVersion sets the "softwareVersion" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateSupportedExtensions ¶
func (u *InstanceMetadataUpsert) UpdateSupportedExtensions() *InstanceMetadataUpsert
UpdateSupportedExtensions sets the "supportedExtensions" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateSupportedVersions ¶
func (u *InstanceMetadataUpsert) UpdateSupportedVersions() *InstanceMetadataUpsert
UpdateSupportedVersions sets the "supportedVersions" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateURI ¶
func (u *InstanceMetadataUpsert) UpdateURI() *InstanceMetadataUpsert
UpdateURI sets the "uri" field to the value that was provided on create.
func (*InstanceMetadataUpsert) UpdateUpdatedAt ¶
func (u *InstanceMetadataUpsert) UpdateUpdatedAt() *InstanceMetadataUpsert
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
type InstanceMetadataUpsertBulk ¶
type InstanceMetadataUpsertBulk struct {
// contains filtered or unexported fields
}
InstanceMetadataUpsertBulk is the builder for "upsert"-ing a bulk of InstanceMetadata nodes.
func (*InstanceMetadataUpsertBulk) ClearAdminsURI ¶
func (u *InstanceMetadataUpsertBulk) ClearAdminsURI() *InstanceMetadataUpsertBulk
ClearAdminsURI clears the value of the "adminsURI" field.
func (*InstanceMetadataUpsertBulk) ClearBannerEndpoint ¶
func (u *InstanceMetadataUpsertBulk) ClearBannerEndpoint() *InstanceMetadataUpsertBulk
ClearBannerEndpoint clears the value of the "bannerEndpoint" field.
func (*InstanceMetadataUpsertBulk) ClearBannerMimeType ¶
func (u *InstanceMetadataUpsertBulk) ClearBannerMimeType() *InstanceMetadataUpsertBulk
ClearBannerMimeType clears the value of the "bannerMimeType" field.
func (*InstanceMetadataUpsertBulk) ClearDescription ¶
func (u *InstanceMetadataUpsertBulk) ClearDescription() *InstanceMetadataUpsertBulk
ClearDescription clears the value of the "description" field.
func (*InstanceMetadataUpsertBulk) ClearLogoEndpoint ¶
func (u *InstanceMetadataUpsertBulk) ClearLogoEndpoint() *InstanceMetadataUpsertBulk
ClearLogoEndpoint clears the value of the "logoEndpoint" field.
func (*InstanceMetadataUpsertBulk) ClearLogoMimeType ¶
func (u *InstanceMetadataUpsertBulk) ClearLogoMimeType() *InstanceMetadataUpsertBulk
ClearLogoMimeType clears the value of the "logoMimeType" field.
func (*InstanceMetadataUpsertBulk) ClearModeratorsURI ¶
func (u *InstanceMetadataUpsertBulk) ClearModeratorsURI() *InstanceMetadataUpsertBulk
ClearModeratorsURI clears the value of the "moderatorsURI" field.
func (*InstanceMetadataUpsertBulk) ClearPrivateKey ¶
func (u *InstanceMetadataUpsertBulk) ClearPrivateKey() *InstanceMetadataUpsertBulk
ClearPrivateKey clears the value of the "privateKey" field.
func (*InstanceMetadataUpsertBulk) DoNothing ¶
func (u *InstanceMetadataUpsertBulk) DoNothing() *InstanceMetadataUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*InstanceMetadataUpsertBulk) Exec ¶
func (u *InstanceMetadataUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*InstanceMetadataUpsertBulk) ExecX ¶
func (u *InstanceMetadataUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataUpsertBulk) Ignore ¶
func (u *InstanceMetadataUpsertBulk) Ignore() *InstanceMetadataUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.InstanceMetadata.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*InstanceMetadataUpsertBulk) SetAdminsURI ¶
func (u *InstanceMetadataUpsertBulk) SetAdminsURI(v string) *InstanceMetadataUpsertBulk
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataUpsertBulk) SetBannerEndpoint ¶
func (u *InstanceMetadataUpsertBulk) SetBannerEndpoint(v string) *InstanceMetadataUpsertBulk
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataUpsertBulk) SetBannerMimeType ¶
func (u *InstanceMetadataUpsertBulk) SetBannerMimeType(v string) *InstanceMetadataUpsertBulk
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataUpsertBulk) SetDescription ¶
func (u *InstanceMetadataUpsertBulk) SetDescription(v string) *InstanceMetadataUpsertBulk
SetDescription sets the "description" field.
func (*InstanceMetadataUpsertBulk) SetExtensions ¶
func (u *InstanceMetadataUpsertBulk) SetExtensions(v versia.Extensions) *InstanceMetadataUpsertBulk
SetExtensions sets the "extensions" field.
func (*InstanceMetadataUpsertBulk) SetHost ¶
func (u *InstanceMetadataUpsertBulk) SetHost(v string) *InstanceMetadataUpsertBulk
SetHost sets the "host" field.
func (*InstanceMetadataUpsertBulk) SetIsRemote ¶
func (u *InstanceMetadataUpsertBulk) SetIsRemote(v bool) *InstanceMetadataUpsertBulk
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataUpsertBulk) SetLogoEndpoint ¶
func (u *InstanceMetadataUpsertBulk) SetLogoEndpoint(v string) *InstanceMetadataUpsertBulk
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataUpsertBulk) SetLogoMimeType ¶
func (u *InstanceMetadataUpsertBulk) SetLogoMimeType(v string) *InstanceMetadataUpsertBulk
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataUpsertBulk) SetModeratorsURI ¶
func (u *InstanceMetadataUpsertBulk) SetModeratorsURI(v string) *InstanceMetadataUpsertBulk
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataUpsertBulk) SetName ¶
func (u *InstanceMetadataUpsertBulk) SetName(v string) *InstanceMetadataUpsertBulk
SetName sets the "name" field.
func (*InstanceMetadataUpsertBulk) SetPrivateKey ¶
func (u *InstanceMetadataUpsertBulk) SetPrivateKey(v []byte) *InstanceMetadataUpsertBulk
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataUpsertBulk) SetPublicKey ¶
func (u *InstanceMetadataUpsertBulk) SetPublicKey(v []byte) *InstanceMetadataUpsertBulk
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataUpsertBulk) SetPublicKeyAlgorithm ¶
func (u *InstanceMetadataUpsertBulk) SetPublicKeyAlgorithm(v string) *InstanceMetadataUpsertBulk
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataUpsertBulk) SetSharedInboxURI ¶
func (u *InstanceMetadataUpsertBulk) SetSharedInboxURI(v string) *InstanceMetadataUpsertBulk
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataUpsertBulk) SetSoftwareName ¶
func (u *InstanceMetadataUpsertBulk) SetSoftwareName(v string) *InstanceMetadataUpsertBulk
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataUpsertBulk) SetSoftwareVersion ¶
func (u *InstanceMetadataUpsertBulk) SetSoftwareVersion(v string) *InstanceMetadataUpsertBulk
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataUpsertBulk) SetSupportedExtensions ¶
func (u *InstanceMetadataUpsertBulk) SetSupportedExtensions(v []string) *InstanceMetadataUpsertBulk
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataUpsertBulk) SetSupportedVersions ¶
func (u *InstanceMetadataUpsertBulk) SetSupportedVersions(v []string) *InstanceMetadataUpsertBulk
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataUpsertBulk) SetURI ¶
func (u *InstanceMetadataUpsertBulk) SetURI(v string) *InstanceMetadataUpsertBulk
SetURI sets the "uri" field.
func (*InstanceMetadataUpsertBulk) SetUpdatedAt ¶
func (u *InstanceMetadataUpsertBulk) SetUpdatedAt(v time.Time) *InstanceMetadataUpsertBulk
SetUpdatedAt sets the "updated_at" field.
func (*InstanceMetadataUpsertBulk) Update ¶
func (u *InstanceMetadataUpsertBulk) Update(set func(*InstanceMetadataUpsert)) *InstanceMetadataUpsertBulk
Update allows overriding fields `UPDATE` values. See the InstanceMetadataCreateBulk.OnConflict documentation for more info.
func (*InstanceMetadataUpsertBulk) UpdateAdminsURI ¶
func (u *InstanceMetadataUpsertBulk) UpdateAdminsURI() *InstanceMetadataUpsertBulk
UpdateAdminsURI sets the "adminsURI" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateBannerEndpoint ¶
func (u *InstanceMetadataUpsertBulk) UpdateBannerEndpoint() *InstanceMetadataUpsertBulk
UpdateBannerEndpoint sets the "bannerEndpoint" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateBannerMimeType ¶
func (u *InstanceMetadataUpsertBulk) UpdateBannerMimeType() *InstanceMetadataUpsertBulk
UpdateBannerMimeType sets the "bannerMimeType" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateDescription ¶
func (u *InstanceMetadataUpsertBulk) UpdateDescription() *InstanceMetadataUpsertBulk
UpdateDescription sets the "description" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateExtensions ¶
func (u *InstanceMetadataUpsertBulk) UpdateExtensions() *InstanceMetadataUpsertBulk
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateHost ¶
func (u *InstanceMetadataUpsertBulk) UpdateHost() *InstanceMetadataUpsertBulk
UpdateHost sets the "host" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateIsRemote ¶
func (u *InstanceMetadataUpsertBulk) UpdateIsRemote() *InstanceMetadataUpsertBulk
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateLogoEndpoint ¶
func (u *InstanceMetadataUpsertBulk) UpdateLogoEndpoint() *InstanceMetadataUpsertBulk
UpdateLogoEndpoint sets the "logoEndpoint" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateLogoMimeType ¶
func (u *InstanceMetadataUpsertBulk) UpdateLogoMimeType() *InstanceMetadataUpsertBulk
UpdateLogoMimeType sets the "logoMimeType" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateModeratorsURI ¶
func (u *InstanceMetadataUpsertBulk) UpdateModeratorsURI() *InstanceMetadataUpsertBulk
UpdateModeratorsURI sets the "moderatorsURI" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateName ¶
func (u *InstanceMetadataUpsertBulk) UpdateName() *InstanceMetadataUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateNewValues ¶
func (u *InstanceMetadataUpsertBulk) UpdateNewValues() *InstanceMetadataUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.InstanceMetadata.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(instancemetadata.FieldID) }), ). Exec(ctx)
func (*InstanceMetadataUpsertBulk) UpdatePrivateKey ¶
func (u *InstanceMetadataUpsertBulk) UpdatePrivateKey() *InstanceMetadataUpsertBulk
UpdatePrivateKey sets the "privateKey" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdatePublicKey ¶
func (u *InstanceMetadataUpsertBulk) UpdatePublicKey() *InstanceMetadataUpsertBulk
UpdatePublicKey sets the "publicKey" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdatePublicKeyAlgorithm ¶
func (u *InstanceMetadataUpsertBulk) UpdatePublicKeyAlgorithm() *InstanceMetadataUpsertBulk
UpdatePublicKeyAlgorithm sets the "publicKeyAlgorithm" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateSharedInboxURI ¶
func (u *InstanceMetadataUpsertBulk) UpdateSharedInboxURI() *InstanceMetadataUpsertBulk
UpdateSharedInboxURI sets the "sharedInboxURI" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateSoftwareName ¶
func (u *InstanceMetadataUpsertBulk) UpdateSoftwareName() *InstanceMetadataUpsertBulk
UpdateSoftwareName sets the "softwareName" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateSoftwareVersion ¶
func (u *InstanceMetadataUpsertBulk) UpdateSoftwareVersion() *InstanceMetadataUpsertBulk
UpdateSoftwareVersion sets the "softwareVersion" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateSupportedExtensions ¶
func (u *InstanceMetadataUpsertBulk) UpdateSupportedExtensions() *InstanceMetadataUpsertBulk
UpdateSupportedExtensions sets the "supportedExtensions" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateSupportedVersions ¶
func (u *InstanceMetadataUpsertBulk) UpdateSupportedVersions() *InstanceMetadataUpsertBulk
UpdateSupportedVersions sets the "supportedVersions" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateURI ¶
func (u *InstanceMetadataUpsertBulk) UpdateURI() *InstanceMetadataUpsertBulk
UpdateURI sets the "uri" field to the value that was provided on create.
func (*InstanceMetadataUpsertBulk) UpdateUpdatedAt ¶
func (u *InstanceMetadataUpsertBulk) UpdateUpdatedAt() *InstanceMetadataUpsertBulk
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
type InstanceMetadataUpsertOne ¶
type InstanceMetadataUpsertOne struct {
// contains filtered or unexported fields
}
InstanceMetadataUpsertOne is the builder for "upsert"-ing
one InstanceMetadata node.
func (*InstanceMetadataUpsertOne) ClearAdminsURI ¶
func (u *InstanceMetadataUpsertOne) ClearAdminsURI() *InstanceMetadataUpsertOne
ClearAdminsURI clears the value of the "adminsURI" field.
func (*InstanceMetadataUpsertOne) ClearBannerEndpoint ¶
func (u *InstanceMetadataUpsertOne) ClearBannerEndpoint() *InstanceMetadataUpsertOne
ClearBannerEndpoint clears the value of the "bannerEndpoint" field.
func (*InstanceMetadataUpsertOne) ClearBannerMimeType ¶
func (u *InstanceMetadataUpsertOne) ClearBannerMimeType() *InstanceMetadataUpsertOne
ClearBannerMimeType clears the value of the "bannerMimeType" field.
func (*InstanceMetadataUpsertOne) ClearDescription ¶
func (u *InstanceMetadataUpsertOne) ClearDescription() *InstanceMetadataUpsertOne
ClearDescription clears the value of the "description" field.
func (*InstanceMetadataUpsertOne) ClearLogoEndpoint ¶
func (u *InstanceMetadataUpsertOne) ClearLogoEndpoint() *InstanceMetadataUpsertOne
ClearLogoEndpoint clears the value of the "logoEndpoint" field.
func (*InstanceMetadataUpsertOne) ClearLogoMimeType ¶
func (u *InstanceMetadataUpsertOne) ClearLogoMimeType() *InstanceMetadataUpsertOne
ClearLogoMimeType clears the value of the "logoMimeType" field.
func (*InstanceMetadataUpsertOne) ClearModeratorsURI ¶
func (u *InstanceMetadataUpsertOne) ClearModeratorsURI() *InstanceMetadataUpsertOne
ClearModeratorsURI clears the value of the "moderatorsURI" field.
func (*InstanceMetadataUpsertOne) ClearPrivateKey ¶
func (u *InstanceMetadataUpsertOne) ClearPrivateKey() *InstanceMetadataUpsertOne
ClearPrivateKey clears the value of the "privateKey" field.
func (*InstanceMetadataUpsertOne) DoNothing ¶
func (u *InstanceMetadataUpsertOne) DoNothing() *InstanceMetadataUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*InstanceMetadataUpsertOne) Exec ¶
func (u *InstanceMetadataUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*InstanceMetadataUpsertOne) ExecX ¶
func (u *InstanceMetadataUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*InstanceMetadataUpsertOne) ID ¶
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*InstanceMetadataUpsertOne) IDX ¶
func (u *InstanceMetadataUpsertOne) IDX(ctx context.Context) uuid.UUID
IDX is like ID, but panics if an error occurs.
func (*InstanceMetadataUpsertOne) Ignore ¶
func (u *InstanceMetadataUpsertOne) Ignore() *InstanceMetadataUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.InstanceMetadata.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*InstanceMetadataUpsertOne) SetAdminsURI ¶
func (u *InstanceMetadataUpsertOne) SetAdminsURI(v string) *InstanceMetadataUpsertOne
SetAdminsURI sets the "adminsURI" field.
func (*InstanceMetadataUpsertOne) SetBannerEndpoint ¶
func (u *InstanceMetadataUpsertOne) SetBannerEndpoint(v string) *InstanceMetadataUpsertOne
SetBannerEndpoint sets the "bannerEndpoint" field.
func (*InstanceMetadataUpsertOne) SetBannerMimeType ¶
func (u *InstanceMetadataUpsertOne) SetBannerMimeType(v string) *InstanceMetadataUpsertOne
SetBannerMimeType sets the "bannerMimeType" field.
func (*InstanceMetadataUpsertOne) SetDescription ¶
func (u *InstanceMetadataUpsertOne) SetDescription(v string) *InstanceMetadataUpsertOne
SetDescription sets the "description" field.
func (*InstanceMetadataUpsertOne) SetExtensions ¶
func (u *InstanceMetadataUpsertOne) SetExtensions(v versia.Extensions) *InstanceMetadataUpsertOne
SetExtensions sets the "extensions" field.
func (*InstanceMetadataUpsertOne) SetHost ¶
func (u *InstanceMetadataUpsertOne) SetHost(v string) *InstanceMetadataUpsertOne
SetHost sets the "host" field.
func (*InstanceMetadataUpsertOne) SetIsRemote ¶
func (u *InstanceMetadataUpsertOne) SetIsRemote(v bool) *InstanceMetadataUpsertOne
SetIsRemote sets the "isRemote" field.
func (*InstanceMetadataUpsertOne) SetLogoEndpoint ¶
func (u *InstanceMetadataUpsertOne) SetLogoEndpoint(v string) *InstanceMetadataUpsertOne
SetLogoEndpoint sets the "logoEndpoint" field.
func (*InstanceMetadataUpsertOne) SetLogoMimeType ¶
func (u *InstanceMetadataUpsertOne) SetLogoMimeType(v string) *InstanceMetadataUpsertOne
SetLogoMimeType sets the "logoMimeType" field.
func (*InstanceMetadataUpsertOne) SetModeratorsURI ¶
func (u *InstanceMetadataUpsertOne) SetModeratorsURI(v string) *InstanceMetadataUpsertOne
SetModeratorsURI sets the "moderatorsURI" field.
func (*InstanceMetadataUpsertOne) SetName ¶
func (u *InstanceMetadataUpsertOne) SetName(v string) *InstanceMetadataUpsertOne
SetName sets the "name" field.
func (*InstanceMetadataUpsertOne) SetPrivateKey ¶
func (u *InstanceMetadataUpsertOne) SetPrivateKey(v []byte) *InstanceMetadataUpsertOne
SetPrivateKey sets the "privateKey" field.
func (*InstanceMetadataUpsertOne) SetPublicKey ¶
func (u *InstanceMetadataUpsertOne) SetPublicKey(v []byte) *InstanceMetadataUpsertOne
SetPublicKey sets the "publicKey" field.
func (*InstanceMetadataUpsertOne) SetPublicKeyAlgorithm ¶
func (u *InstanceMetadataUpsertOne) SetPublicKeyAlgorithm(v string) *InstanceMetadataUpsertOne
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*InstanceMetadataUpsertOne) SetSharedInboxURI ¶
func (u *InstanceMetadataUpsertOne) SetSharedInboxURI(v string) *InstanceMetadataUpsertOne
SetSharedInboxURI sets the "sharedInboxURI" field.
func (*InstanceMetadataUpsertOne) SetSoftwareName ¶
func (u *InstanceMetadataUpsertOne) SetSoftwareName(v string) *InstanceMetadataUpsertOne
SetSoftwareName sets the "softwareName" field.
func (*InstanceMetadataUpsertOne) SetSoftwareVersion ¶
func (u *InstanceMetadataUpsertOne) SetSoftwareVersion(v string) *InstanceMetadataUpsertOne
SetSoftwareVersion sets the "softwareVersion" field.
func (*InstanceMetadataUpsertOne) SetSupportedExtensions ¶
func (u *InstanceMetadataUpsertOne) SetSupportedExtensions(v []string) *InstanceMetadataUpsertOne
SetSupportedExtensions sets the "supportedExtensions" field.
func (*InstanceMetadataUpsertOne) SetSupportedVersions ¶
func (u *InstanceMetadataUpsertOne) SetSupportedVersions(v []string) *InstanceMetadataUpsertOne
SetSupportedVersions sets the "supportedVersions" field.
func (*InstanceMetadataUpsertOne) SetURI ¶
func (u *InstanceMetadataUpsertOne) SetURI(v string) *InstanceMetadataUpsertOne
SetURI sets the "uri" field.
func (*InstanceMetadataUpsertOne) SetUpdatedAt ¶
func (u *InstanceMetadataUpsertOne) SetUpdatedAt(v time.Time) *InstanceMetadataUpsertOne
SetUpdatedAt sets the "updated_at" field.
func (*InstanceMetadataUpsertOne) Update ¶
func (u *InstanceMetadataUpsertOne) Update(set func(*InstanceMetadataUpsert)) *InstanceMetadataUpsertOne
Update allows overriding fields `UPDATE` values. See the InstanceMetadataCreate.OnConflict documentation for more info.
func (*InstanceMetadataUpsertOne) UpdateAdminsURI ¶
func (u *InstanceMetadataUpsertOne) UpdateAdminsURI() *InstanceMetadataUpsertOne
UpdateAdminsURI sets the "adminsURI" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateBannerEndpoint ¶
func (u *InstanceMetadataUpsertOne) UpdateBannerEndpoint() *InstanceMetadataUpsertOne
UpdateBannerEndpoint sets the "bannerEndpoint" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateBannerMimeType ¶
func (u *InstanceMetadataUpsertOne) UpdateBannerMimeType() *InstanceMetadataUpsertOne
UpdateBannerMimeType sets the "bannerMimeType" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateDescription ¶
func (u *InstanceMetadataUpsertOne) UpdateDescription() *InstanceMetadataUpsertOne
UpdateDescription sets the "description" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateExtensions ¶
func (u *InstanceMetadataUpsertOne) UpdateExtensions() *InstanceMetadataUpsertOne
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateHost ¶
func (u *InstanceMetadataUpsertOne) UpdateHost() *InstanceMetadataUpsertOne
UpdateHost sets the "host" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateIsRemote ¶
func (u *InstanceMetadataUpsertOne) UpdateIsRemote() *InstanceMetadataUpsertOne
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateLogoEndpoint ¶
func (u *InstanceMetadataUpsertOne) UpdateLogoEndpoint() *InstanceMetadataUpsertOne
UpdateLogoEndpoint sets the "logoEndpoint" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateLogoMimeType ¶
func (u *InstanceMetadataUpsertOne) UpdateLogoMimeType() *InstanceMetadataUpsertOne
UpdateLogoMimeType sets the "logoMimeType" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateModeratorsURI ¶
func (u *InstanceMetadataUpsertOne) UpdateModeratorsURI() *InstanceMetadataUpsertOne
UpdateModeratorsURI sets the "moderatorsURI" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateName ¶
func (u *InstanceMetadataUpsertOne) UpdateName() *InstanceMetadataUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateNewValues ¶
func (u *InstanceMetadataUpsertOne) UpdateNewValues() *InstanceMetadataUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:
client.InstanceMetadata.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(instancemetadata.FieldID) }), ). Exec(ctx)
func (*InstanceMetadataUpsertOne) UpdatePrivateKey ¶
func (u *InstanceMetadataUpsertOne) UpdatePrivateKey() *InstanceMetadataUpsertOne
UpdatePrivateKey sets the "privateKey" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdatePublicKey ¶
func (u *InstanceMetadataUpsertOne) UpdatePublicKey() *InstanceMetadataUpsertOne
UpdatePublicKey sets the "publicKey" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdatePublicKeyAlgorithm ¶
func (u *InstanceMetadataUpsertOne) UpdatePublicKeyAlgorithm() *InstanceMetadataUpsertOne
UpdatePublicKeyAlgorithm sets the "publicKeyAlgorithm" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateSharedInboxURI ¶
func (u *InstanceMetadataUpsertOne) UpdateSharedInboxURI() *InstanceMetadataUpsertOne
UpdateSharedInboxURI sets the "sharedInboxURI" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateSoftwareName ¶
func (u *InstanceMetadataUpsertOne) UpdateSoftwareName() *InstanceMetadataUpsertOne
UpdateSoftwareName sets the "softwareName" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateSoftwareVersion ¶
func (u *InstanceMetadataUpsertOne) UpdateSoftwareVersion() *InstanceMetadataUpsertOne
UpdateSoftwareVersion sets the "softwareVersion" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateSupportedExtensions ¶
func (u *InstanceMetadataUpsertOne) UpdateSupportedExtensions() *InstanceMetadataUpsertOne
UpdateSupportedExtensions sets the "supportedExtensions" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateSupportedVersions ¶
func (u *InstanceMetadataUpsertOne) UpdateSupportedVersions() *InstanceMetadataUpsertOne
UpdateSupportedVersions sets the "supportedVersions" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateURI ¶
func (u *InstanceMetadataUpsertOne) UpdateURI() *InstanceMetadataUpsertOne
UpdateURI sets the "uri" field to the value that was provided on create.
func (*InstanceMetadataUpsertOne) UpdateUpdatedAt ¶
func (u *InstanceMetadataUpsertOne) UpdateUpdatedAt() *InstanceMetadataUpsertOne
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
type InterceptFunc ¶
type InterceptFunc = ent.InterceptFunc
ent aliases to avoid import conflicts in user's code.
type Interceptor ¶
type Interceptor = ent.Interceptor
ent aliases to avoid import conflicts in user's code.
type MutateFunc ¶
type MutateFunc = ent.MutateFunc
ent aliases to avoid import conflicts in user's code.
type 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 Note ¶
type Note struct { // ID of the ent. ID uuid.UUID `json:"id,omitempty"` // IsRemote holds the value of the "isRemote" field. IsRemote bool `json:"isRemote,omitempty"` // URI holds the value of the "uri" field. URI string `json:"uri,omitempty"` // Extensions holds the value of the "extensions" field. Extensions versia.Extensions `json:"extensions,omitempty"` // CreatedAt holds the value of the "created_at" field. CreatedAt time.Time `json:"created_at,omitempty"` // UpdatedAt holds the value of the "updated_at" field. UpdatedAt time.Time `json:"updated_at,omitempty"` // Subject holds the value of the "subject" field. Subject *string `json:"subject,omitempty"` // Content holds the value of the "content" field. Content string `json:"content,omitempty"` // IsSensitive holds the value of the "isSensitive" field. IsSensitive bool `json:"isSensitive,omitempty"` // Visibility holds the value of the "visibility" field. Visibility note.Visibility `json:"visibility,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the NoteQuery when eager-loading is set. Edges NoteEdges `json:"edges"` // contains filtered or unexported fields }
Note is the model entity for the Note schema.
func (*Note) QueryAttachments ¶
func (n *Note) QueryAttachments() *AttachmentQuery
QueryAttachments queries the "attachments" edge of the Note entity.
func (*Note) QueryAuthor ¶
QueryAuthor queries the "author" edge of the Note entity.
func (*Note) QueryMentions ¶
QueryMentions queries the "mentions" edge of the Note entity.
func (*Note) Unwrap ¶
Unwrap unwraps the Note 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 (*Note) Update ¶
func (n *Note) Update() *NoteUpdateOne
Update returns a builder for updating this Note. Note that you need to call Note.Unwrap() before calling this method if this Note was returned from a transaction, and the transaction was committed or rolled back.
type NoteClient ¶
type NoteClient struct {
// contains filtered or unexported fields
}
NoteClient is a client for the Note schema.
func NewNoteClient ¶
func NewNoteClient(c config) *NoteClient
NewNoteClient returns a client for the Note from the given config.
func (*NoteClient) Create ¶
func (c *NoteClient) Create() *NoteCreate
Create returns a builder for creating a Note entity.
func (*NoteClient) CreateBulk ¶
func (c *NoteClient) CreateBulk(builders ...*NoteCreate) *NoteCreateBulk
CreateBulk returns a builder for creating a bulk of Note entities.
func (*NoteClient) Delete ¶
func (c *NoteClient) Delete() *NoteDelete
Delete returns a delete builder for Note.
func (*NoteClient) DeleteOne ¶
func (c *NoteClient) DeleteOne(n *Note) *NoteDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*NoteClient) DeleteOneID ¶
func (c *NoteClient) DeleteOneID(id uuid.UUID) *NoteDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*NoteClient) Intercept ¶
func (c *NoteClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `note.Intercept(f(g(h())))`.
func (*NoteClient) Interceptors ¶
func (c *NoteClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*NoteClient) MapCreateBulk ¶
func (c *NoteClient) MapCreateBulk(slice any, setFunc func(*NoteCreate, int)) *NoteCreateBulk
MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.
func (*NoteClient) Query ¶
func (c *NoteClient) Query() *NoteQuery
Query returns a query builder for Note.
func (*NoteClient) QueryAttachments ¶
func (c *NoteClient) QueryAttachments(n *Note) *AttachmentQuery
QueryAttachments queries the attachments edge of a Note.
func (*NoteClient) QueryAuthor ¶
func (c *NoteClient) QueryAuthor(n *Note) *UserQuery
QueryAuthor queries the author edge of a Note.
func (*NoteClient) QueryMentions ¶
func (c *NoteClient) QueryMentions(n *Note) *UserQuery
QueryMentions queries the mentions edge of a Note.
func (*NoteClient) Update ¶
func (c *NoteClient) Update() *NoteUpdate
Update returns an update builder for Note.
func (*NoteClient) UpdateOne ¶
func (c *NoteClient) UpdateOne(n *Note) *NoteUpdateOne
UpdateOne returns an update builder for the given entity.
func (*NoteClient) UpdateOneID ¶
func (c *NoteClient) UpdateOneID(id uuid.UUID) *NoteUpdateOne
UpdateOneID returns an update builder for the given id.
func (*NoteClient) Use ¶
func (c *NoteClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `note.Hooks(f(g(h())))`.
type NoteCreate ¶
type NoteCreate struct {
// contains filtered or unexported fields
}
NoteCreate is the builder for creating a Note entity.
func (*NoteCreate) AddAttachmentIDs ¶
func (nc *NoteCreate) AddAttachmentIDs(ids ...uuid.UUID) *NoteCreate
AddAttachmentIDs adds the "attachments" edge to the Attachment entity by IDs.
func (*NoteCreate) AddAttachments ¶
func (nc *NoteCreate) AddAttachments(a ...*Attachment) *NoteCreate
AddAttachments adds the "attachments" edges to the Attachment entity.
func (*NoteCreate) AddMentionIDs ¶
func (nc *NoteCreate) AddMentionIDs(ids ...uuid.UUID) *NoteCreate
AddMentionIDs adds the "mentions" edge to the User entity by IDs.
func (*NoteCreate) AddMentions ¶
func (nc *NoteCreate) AddMentions(u ...*User) *NoteCreate
AddMentions adds the "mentions" edges to the User entity.
func (*NoteCreate) Exec ¶
func (nc *NoteCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*NoteCreate) ExecX ¶
func (nc *NoteCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteCreate) Mutation ¶
func (nc *NoteCreate) Mutation() *NoteMutation
Mutation returns the NoteMutation object of the builder.
func (*NoteCreate) OnConflict ¶
func (nc *NoteCreate) OnConflict(opts ...sql.ConflictOption) *NoteUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Note.Create(). SetIsRemote(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.NoteUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*NoteCreate) OnConflictColumns ¶
func (nc *NoteCreate) OnConflictColumns(columns ...string) *NoteUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Note.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*NoteCreate) Save ¶
func (nc *NoteCreate) Save(ctx context.Context) (*Note, error)
Save creates the Note in the database.
func (*NoteCreate) SaveX ¶
func (nc *NoteCreate) SaveX(ctx context.Context) *Note
SaveX calls Save and panics if Save returns an error.
func (*NoteCreate) SetAuthor ¶
func (nc *NoteCreate) SetAuthor(u *User) *NoteCreate
SetAuthor sets the "author" edge to the User entity.
func (*NoteCreate) SetAuthorID ¶
func (nc *NoteCreate) SetAuthorID(id uuid.UUID) *NoteCreate
SetAuthorID sets the "author" edge to the User entity by ID.
func (*NoteCreate) SetContent ¶
func (nc *NoteCreate) SetContent(s string) *NoteCreate
SetContent sets the "content" field.
func (*NoteCreate) SetCreatedAt ¶
func (nc *NoteCreate) SetCreatedAt(t time.Time) *NoteCreate
SetCreatedAt sets the "created_at" field.
func (*NoteCreate) SetExtensions ¶
func (nc *NoteCreate) SetExtensions(v versia.Extensions) *NoteCreate
SetExtensions sets the "extensions" field.
func (*NoteCreate) SetID ¶
func (nc *NoteCreate) SetID(u uuid.UUID) *NoteCreate
SetID sets the "id" field.
func (*NoteCreate) SetIsRemote ¶
func (nc *NoteCreate) SetIsRemote(b bool) *NoteCreate
SetIsRemote sets the "isRemote" field.
func (*NoteCreate) SetIsSensitive ¶
func (nc *NoteCreate) SetIsSensitive(b bool) *NoteCreate
SetIsSensitive sets the "isSensitive" field.
func (*NoteCreate) SetNillableCreatedAt ¶
func (nc *NoteCreate) SetNillableCreatedAt(t *time.Time) *NoteCreate
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*NoteCreate) SetNillableID ¶
func (nc *NoteCreate) SetNillableID(u *uuid.UUID) *NoteCreate
SetNillableID sets the "id" field if the given value is not nil.
func (*NoteCreate) SetNillableIsSensitive ¶
func (nc *NoteCreate) SetNillableIsSensitive(b *bool) *NoteCreate
SetNillableIsSensitive sets the "isSensitive" field if the given value is not nil.
func (*NoteCreate) SetNillableSubject ¶
func (nc *NoteCreate) SetNillableSubject(s *string) *NoteCreate
SetNillableSubject sets the "subject" field if the given value is not nil.
func (*NoteCreate) SetNillableUpdatedAt ¶
func (nc *NoteCreate) SetNillableUpdatedAt(t *time.Time) *NoteCreate
SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.
func (*NoteCreate) SetNillableVisibility ¶
func (nc *NoteCreate) SetNillableVisibility(n *note.Visibility) *NoteCreate
SetNillableVisibility sets the "visibility" field if the given value is not nil.
func (*NoteCreate) SetSubject ¶
func (nc *NoteCreate) SetSubject(s string) *NoteCreate
SetSubject sets the "subject" field.
func (*NoteCreate) SetURI ¶
func (nc *NoteCreate) SetURI(s string) *NoteCreate
SetURI sets the "uri" field.
func (*NoteCreate) SetUpdatedAt ¶
func (nc *NoteCreate) SetUpdatedAt(t time.Time) *NoteCreate
SetUpdatedAt sets the "updated_at" field.
func (*NoteCreate) SetVisibility ¶
func (nc *NoteCreate) SetVisibility(n note.Visibility) *NoteCreate
SetVisibility sets the "visibility" field.
type NoteCreateBulk ¶
type NoteCreateBulk struct {
// contains filtered or unexported fields
}
NoteCreateBulk is the builder for creating many Note entities in bulk.
func (*NoteCreateBulk) Exec ¶
func (ncb *NoteCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*NoteCreateBulk) ExecX ¶
func (ncb *NoteCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteCreateBulk) OnConflict ¶
func (ncb *NoteCreateBulk) OnConflict(opts ...sql.ConflictOption) *NoteUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Note.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.NoteUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*NoteCreateBulk) OnConflictColumns ¶
func (ncb *NoteCreateBulk) OnConflictColumns(columns ...string) *NoteUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Note.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type NoteDelete ¶
type NoteDelete struct {
// contains filtered or unexported fields
}
NoteDelete is the builder for deleting a Note entity.
func (*NoteDelete) Exec ¶
func (nd *NoteDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*NoteDelete) ExecX ¶
func (nd *NoteDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*NoteDelete) Where ¶
func (nd *NoteDelete) Where(ps ...predicate.Note) *NoteDelete
Where appends a list predicates to the NoteDelete builder.
type NoteDeleteOne ¶
type NoteDeleteOne struct {
// contains filtered or unexported fields
}
NoteDeleteOne is the builder for deleting a single Note entity.
func (*NoteDeleteOne) Exec ¶
func (ndo *NoteDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*NoteDeleteOne) ExecX ¶
func (ndo *NoteDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteDeleteOne) Where ¶
func (ndo *NoteDeleteOne) Where(ps ...predicate.Note) *NoteDeleteOne
Where appends a list predicates to the NoteDelete builder.
type NoteEdges ¶
type NoteEdges struct { // Author holds the value of the author edge. Author *User `json:"author,omitempty"` // Mentions holds the value of the mentions edge. Mentions []*User `json:"mentions,omitempty"` // Attachments holds the value of the attachments edge. Attachments []*Attachment `json:"attachments,omitempty"` // contains filtered or unexported fields }
NoteEdges holds the relations/edges for other nodes in the graph.
func (NoteEdges) AttachmentsOrErr ¶
func (e NoteEdges) AttachmentsOrErr() ([]*Attachment, error)
AttachmentsOrErr returns the Attachments value or an error if the edge was not loaded in eager-loading.
func (NoteEdges) AuthorOrErr ¶
AuthorOrErr returns the Author value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (NoteEdges) MentionsOrErr ¶
MentionsOrErr returns the Mentions value or an error if the edge was not loaded in eager-loading.
type NoteGroupBy ¶
type NoteGroupBy struct {
// contains filtered or unexported fields
}
NoteGroupBy is the group-by builder for Note entities.
func (*NoteGroupBy) Aggregate ¶
func (ngb *NoteGroupBy) Aggregate(fns ...AggregateFunc) *NoteGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*NoteGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*NoteGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*NoteGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*NoteGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*NoteGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*NoteGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*NoteGroupBy) Scan ¶
func (ngb *NoteGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*NoteGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type NoteMutation ¶
type NoteMutation struct {
// contains filtered or unexported fields
}
NoteMutation represents an operation that mutates the Note nodes in the graph.
func (*NoteMutation) AddAttachmentIDs ¶
func (m *NoteMutation) AddAttachmentIDs(ids ...uuid.UUID)
AddAttachmentIDs adds the "attachments" edge to the Attachment entity by ids.
func (*NoteMutation) AddField ¶
func (m *NoteMutation) 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 (*NoteMutation) AddMentionIDs ¶
func (m *NoteMutation) AddMentionIDs(ids ...uuid.UUID)
AddMentionIDs adds the "mentions" edge to the User entity by ids.
func (*NoteMutation) AddedEdges ¶
func (m *NoteMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*NoteMutation) AddedField ¶
func (m *NoteMutation) 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 (*NoteMutation) AddedFields ¶
func (m *NoteMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*NoteMutation) AddedIDs ¶
func (m *NoteMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*NoteMutation) AttachmentsCleared ¶
func (m *NoteMutation) AttachmentsCleared() bool
AttachmentsCleared reports if the "attachments" edge to the Attachment entity was cleared.
func (*NoteMutation) AttachmentsIDs ¶
func (m *NoteMutation) AttachmentsIDs() (ids []uuid.UUID)
AttachmentsIDs returns the "attachments" edge IDs in the mutation.
func (*NoteMutation) AuthorCleared ¶
func (m *NoteMutation) AuthorCleared() bool
AuthorCleared reports if the "author" edge to the User entity was cleared.
func (*NoteMutation) AuthorID ¶
func (m *NoteMutation) AuthorID() (id uuid.UUID, exists bool)
AuthorID returns the "author" edge ID in the mutation.
func (*NoteMutation) AuthorIDs ¶
func (m *NoteMutation) AuthorIDs() (ids []uuid.UUID)
AuthorIDs returns the "author" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AuthorID instead. It exists only for internal usage by the builders.
func (*NoteMutation) ClearAttachments ¶
func (m *NoteMutation) ClearAttachments()
ClearAttachments clears the "attachments" edge to the Attachment entity.
func (*NoteMutation) ClearAuthor ¶
func (m *NoteMutation) ClearAuthor()
ClearAuthor clears the "author" edge to the User entity.
func (*NoteMutation) ClearEdge ¶
func (m *NoteMutation) 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 (*NoteMutation) ClearField ¶
func (m *NoteMutation) 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 (*NoteMutation) ClearMentions ¶
func (m *NoteMutation) ClearMentions()
ClearMentions clears the "mentions" edge to the User entity.
func (*NoteMutation) ClearSubject ¶
func (m *NoteMutation) ClearSubject()
ClearSubject clears the value of the "subject" field.
func (*NoteMutation) ClearedEdges ¶
func (m *NoteMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*NoteMutation) ClearedFields ¶
func (m *NoteMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (NoteMutation) Client ¶
func (m NoteMutation) 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 (*NoteMutation) Content ¶
func (m *NoteMutation) Content() (r string, exists bool)
Content returns the value of the "content" field in the mutation.
func (*NoteMutation) CreatedAt ¶
func (m *NoteMutation) CreatedAt() (r time.Time, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*NoteMutation) EdgeCleared ¶
func (m *NoteMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*NoteMutation) Extensions ¶
func (m *NoteMutation) Extensions() (r versia.Extensions, exists bool)
Extensions returns the value of the "extensions" field in the mutation.
func (*NoteMutation) Field ¶
func (m *NoteMutation) 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 (*NoteMutation) FieldCleared ¶
func (m *NoteMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*NoteMutation) Fields ¶
func (m *NoteMutation) 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 (*NoteMutation) ID ¶
func (m *NoteMutation) ID() (id uuid.UUID, 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 (*NoteMutation) IDs ¶
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 (*NoteMutation) IsRemote ¶
func (m *NoteMutation) IsRemote() (r bool, exists bool)
IsRemote returns the value of the "isRemote" field in the mutation.
func (*NoteMutation) IsSensitive ¶
func (m *NoteMutation) IsSensitive() (r bool, exists bool)
IsSensitive returns the value of the "isSensitive" field in the mutation.
func (*NoteMutation) MentionsCleared ¶
func (m *NoteMutation) MentionsCleared() bool
MentionsCleared reports if the "mentions" edge to the User entity was cleared.
func (*NoteMutation) MentionsIDs ¶
func (m *NoteMutation) MentionsIDs() (ids []uuid.UUID)
MentionsIDs returns the "mentions" edge IDs in the mutation.
func (*NoteMutation) OldContent ¶
func (m *NoteMutation) OldContent(ctx context.Context) (v string, err error)
OldContent returns the old "content" field's value of the Note entity. If the Note 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 (*NoteMutation) OldCreatedAt ¶
OldCreatedAt returns the old "created_at" field's value of the Note entity. If the Note 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 (*NoteMutation) OldExtensions ¶
func (m *NoteMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
OldExtensions returns the old "extensions" field's value of the Note entity. If the Note 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 (*NoteMutation) 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 (*NoteMutation) OldIsRemote ¶
func (m *NoteMutation) OldIsRemote(ctx context.Context) (v bool, err error)
OldIsRemote returns the old "isRemote" field's value of the Note entity. If the Note 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 (*NoteMutation) OldIsSensitive ¶
func (m *NoteMutation) OldIsSensitive(ctx context.Context) (v bool, err error)
OldIsSensitive returns the old "isSensitive" field's value of the Note entity. If the Note 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 (*NoteMutation) OldSubject ¶
func (m *NoteMutation) OldSubject(ctx context.Context) (v *string, err error)
OldSubject returns the old "subject" field's value of the Note entity. If the Note 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 (*NoteMutation) OldURI ¶
func (m *NoteMutation) OldURI(ctx context.Context) (v string, err error)
OldURI returns the old "uri" field's value of the Note entity. If the Note 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 (*NoteMutation) OldUpdatedAt ¶
OldUpdatedAt returns the old "updated_at" field's value of the Note entity. If the Note 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 (*NoteMutation) OldVisibility ¶
func (m *NoteMutation) OldVisibility(ctx context.Context) (v note.Visibility, err error)
OldVisibility returns the old "visibility" field's value of the Note entity. If the Note 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 (*NoteMutation) RemoveAttachmentIDs ¶
func (m *NoteMutation) RemoveAttachmentIDs(ids ...uuid.UUID)
RemoveAttachmentIDs removes the "attachments" edge to the Attachment entity by IDs.
func (*NoteMutation) RemoveMentionIDs ¶
func (m *NoteMutation) RemoveMentionIDs(ids ...uuid.UUID)
RemoveMentionIDs removes the "mentions" edge to the User entity by IDs.
func (*NoteMutation) RemovedAttachmentsIDs ¶
func (m *NoteMutation) RemovedAttachmentsIDs() (ids []uuid.UUID)
RemovedAttachments returns the removed IDs of the "attachments" edge to the Attachment entity.
func (*NoteMutation) RemovedEdges ¶
func (m *NoteMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*NoteMutation) RemovedIDs ¶
func (m *NoteMutation) 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 (*NoteMutation) RemovedMentionsIDs ¶
func (m *NoteMutation) RemovedMentionsIDs() (ids []uuid.UUID)
RemovedMentions returns the removed IDs of the "mentions" edge to the User entity.
func (*NoteMutation) ResetAttachments ¶
func (m *NoteMutation) ResetAttachments()
ResetAttachments resets all changes to the "attachments" edge.
func (*NoteMutation) ResetAuthor ¶
func (m *NoteMutation) ResetAuthor()
ResetAuthor resets all changes to the "author" edge.
func (*NoteMutation) ResetContent ¶
func (m *NoteMutation) ResetContent()
ResetContent resets all changes to the "content" field.
func (*NoteMutation) ResetCreatedAt ¶
func (m *NoteMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*NoteMutation) ResetEdge ¶
func (m *NoteMutation) 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 (*NoteMutation) ResetExtensions ¶
func (m *NoteMutation) ResetExtensions()
ResetExtensions resets all changes to the "extensions" field.
func (*NoteMutation) ResetField ¶
func (m *NoteMutation) 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 (*NoteMutation) ResetIsRemote ¶
func (m *NoteMutation) ResetIsRemote()
ResetIsRemote resets all changes to the "isRemote" field.
func (*NoteMutation) ResetIsSensitive ¶
func (m *NoteMutation) ResetIsSensitive()
ResetIsSensitive resets all changes to the "isSensitive" field.
func (*NoteMutation) ResetMentions ¶
func (m *NoteMutation) ResetMentions()
ResetMentions resets all changes to the "mentions" edge.
func (*NoteMutation) ResetSubject ¶
func (m *NoteMutation) ResetSubject()
ResetSubject resets all changes to the "subject" field.
func (*NoteMutation) ResetURI ¶
func (m *NoteMutation) ResetURI()
ResetURI resets all changes to the "uri" field.
func (*NoteMutation) ResetUpdatedAt ¶
func (m *NoteMutation) ResetUpdatedAt()
ResetUpdatedAt resets all changes to the "updated_at" field.
func (*NoteMutation) ResetVisibility ¶
func (m *NoteMutation) ResetVisibility()
ResetVisibility resets all changes to the "visibility" field.
func (*NoteMutation) SetAuthorID ¶
func (m *NoteMutation) SetAuthorID(id uuid.UUID)
SetAuthorID sets the "author" edge to the User entity by id.
func (*NoteMutation) SetContent ¶
func (m *NoteMutation) SetContent(s string)
SetContent sets the "content" field.
func (*NoteMutation) SetCreatedAt ¶
func (m *NoteMutation) SetCreatedAt(t time.Time)
SetCreatedAt sets the "created_at" field.
func (*NoteMutation) SetExtensions ¶
func (m *NoteMutation) SetExtensions(v versia.Extensions)
SetExtensions sets the "extensions" field.
func (*NoteMutation) SetField ¶
func (m *NoteMutation) 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 (*NoteMutation) SetID ¶
func (m *NoteMutation) SetID(id uuid.UUID)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Note entities.
func (*NoteMutation) SetIsRemote ¶
func (m *NoteMutation) SetIsRemote(b bool)
SetIsRemote sets the "isRemote" field.
func (*NoteMutation) SetIsSensitive ¶
func (m *NoteMutation) SetIsSensitive(b bool)
SetIsSensitive sets the "isSensitive" field.
func (*NoteMutation) SetOp ¶
func (m *NoteMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*NoteMutation) SetSubject ¶
func (m *NoteMutation) SetSubject(s string)
SetSubject sets the "subject" field.
func (*NoteMutation) SetUpdatedAt ¶
func (m *NoteMutation) SetUpdatedAt(t time.Time)
SetUpdatedAt sets the "updated_at" field.
func (*NoteMutation) SetVisibility ¶
func (m *NoteMutation) SetVisibility(n note.Visibility)
SetVisibility sets the "visibility" field.
func (*NoteMutation) Subject ¶
func (m *NoteMutation) Subject() (r string, exists bool)
Subject returns the value of the "subject" field in the mutation.
func (*NoteMutation) SubjectCleared ¶
func (m *NoteMutation) SubjectCleared() bool
SubjectCleared returns if the "subject" field was cleared in this mutation.
func (NoteMutation) Tx ¶
func (m NoteMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*NoteMutation) Type ¶
func (m *NoteMutation) Type() string
Type returns the node type of this mutation (Note).
func (*NoteMutation) URI ¶
func (m *NoteMutation) URI() (r string, exists bool)
URI returns the value of the "uri" field in the mutation.
func (*NoteMutation) UpdatedAt ¶
func (m *NoteMutation) UpdatedAt() (r time.Time, exists bool)
UpdatedAt returns the value of the "updated_at" field in the mutation.
func (*NoteMutation) Visibility ¶
func (m *NoteMutation) Visibility() (r note.Visibility, exists bool)
Visibility returns the value of the "visibility" field in the mutation.
func (*NoteMutation) Where ¶
func (m *NoteMutation) Where(ps ...predicate.Note)
Where appends a list predicates to the NoteMutation builder.
func (*NoteMutation) WhereP ¶
func (m *NoteMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the NoteMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type NoteQuery ¶
type NoteQuery struct {
// contains filtered or unexported fields
}
NoteQuery is the builder for querying Note entities.
func (*NoteQuery) Aggregate ¶
func (nq *NoteQuery) Aggregate(fns ...AggregateFunc) *NoteSelect
Aggregate returns a NoteSelect configured with the given aggregations.
func (*NoteQuery) Clone ¶
Clone returns a duplicate of the NoteQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*NoteQuery) First ¶
First returns the first Note entity from the query. Returns a *NotFoundError when no Note was found.
func (*NoteQuery) FirstID ¶
FirstID returns the first Note ID from the query. Returns a *NotFoundError when no Note ID was found.
func (*NoteQuery) GroupBy ¶
func (nq *NoteQuery) GroupBy(field string, fields ...string) *NoteGroupBy
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 { IsRemote bool `json:"isRemote,omitempty"` Count int `json:"count,omitempty"` } client.Note.Query(). GroupBy(note.FieldIsRemote). Aggregate(ent.Count()). Scan(ctx, &v)
func (*NoteQuery) Only ¶
Only returns a single Note entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Note entity is found. Returns a *NotFoundError when no Note entities are found.
func (*NoteQuery) OnlyID ¶
OnlyID is like Only, but returns the only Note ID in the query. Returns a *NotSingularError when more than one Note ID is found. Returns a *NotFoundError when no entities are found.
func (*NoteQuery) Order ¶
func (nq *NoteQuery) Order(o ...note.OrderOption) *NoteQuery
Order specifies how the records should be ordered.
func (*NoteQuery) QueryAttachments ¶
func (nq *NoteQuery) QueryAttachments() *AttachmentQuery
QueryAttachments chains the current query on the "attachments" edge.
func (*NoteQuery) QueryAuthor ¶
QueryAuthor chains the current query on the "author" edge.
func (*NoteQuery) QueryMentions ¶
QueryMentions chains the current query on the "mentions" edge.
func (*NoteQuery) Select ¶
func (nq *NoteQuery) Select(fields ...string) *NoteSelect
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 { IsRemote bool `json:"isRemote,omitempty"` } client.Note.Query(). Select(note.FieldIsRemote). Scan(ctx, &v)
func (*NoteQuery) 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 (*NoteQuery) WithAttachments ¶
func (nq *NoteQuery) WithAttachments(opts ...func(*AttachmentQuery)) *NoteQuery
WithAttachments tells the query-builder to eager-load the nodes that are connected to the "attachments" edge. The optional arguments are used to configure the query builder of the edge.
func (*NoteQuery) WithAuthor ¶
WithAuthor tells the query-builder to eager-load the nodes that are connected to the "author" edge. The optional arguments are used to configure the query builder of the edge.
func (*NoteQuery) WithMentions ¶
WithMentions tells the query-builder to eager-load the nodes that are connected to the "mentions" edge. The optional arguments are used to configure the query builder of the edge.
type NoteSelect ¶
type NoteSelect struct { *NoteQuery // contains filtered or unexported fields }
NoteSelect is the builder for selecting fields of Note entities.
func (*NoteSelect) Aggregate ¶
func (ns *NoteSelect) Aggregate(fns ...AggregateFunc) *NoteSelect
Aggregate adds the given aggregation functions to the selector query.
func (*NoteSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*NoteSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*NoteSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*NoteSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*NoteSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*NoteSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*NoteSelect) Scan ¶
func (ns *NoteSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*NoteSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type NoteUpdate ¶
type NoteUpdate struct {
// contains filtered or unexported fields
}
NoteUpdate is the builder for updating Note entities.
func (*NoteUpdate) AddAttachmentIDs ¶
func (nu *NoteUpdate) AddAttachmentIDs(ids ...uuid.UUID) *NoteUpdate
AddAttachmentIDs adds the "attachments" edge to the Attachment entity by IDs.
func (*NoteUpdate) AddAttachments ¶
func (nu *NoteUpdate) AddAttachments(a ...*Attachment) *NoteUpdate
AddAttachments adds the "attachments" edges to the Attachment entity.
func (*NoteUpdate) AddMentionIDs ¶
func (nu *NoteUpdate) AddMentionIDs(ids ...uuid.UUID) *NoteUpdate
AddMentionIDs adds the "mentions" edge to the User entity by IDs.
func (*NoteUpdate) AddMentions ¶
func (nu *NoteUpdate) AddMentions(u ...*User) *NoteUpdate
AddMentions adds the "mentions" edges to the User entity.
func (*NoteUpdate) ClearAttachments ¶
func (nu *NoteUpdate) ClearAttachments() *NoteUpdate
ClearAttachments clears all "attachments" edges to the Attachment entity.
func (*NoteUpdate) ClearAuthor ¶
func (nu *NoteUpdate) ClearAuthor() *NoteUpdate
ClearAuthor clears the "author" edge to the User entity.
func (*NoteUpdate) ClearMentions ¶
func (nu *NoteUpdate) ClearMentions() *NoteUpdate
ClearMentions clears all "mentions" edges to the User entity.
func (*NoteUpdate) ClearSubject ¶
func (nu *NoteUpdate) ClearSubject() *NoteUpdate
ClearSubject clears the value of the "subject" field.
func (*NoteUpdate) Exec ¶
func (nu *NoteUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*NoteUpdate) ExecX ¶
func (nu *NoteUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteUpdate) Mutation ¶
func (nu *NoteUpdate) Mutation() *NoteMutation
Mutation returns the NoteMutation object of the builder.
func (*NoteUpdate) RemoveAttachmentIDs ¶
func (nu *NoteUpdate) RemoveAttachmentIDs(ids ...uuid.UUID) *NoteUpdate
RemoveAttachmentIDs removes the "attachments" edge to Attachment entities by IDs.
func (*NoteUpdate) RemoveAttachments ¶
func (nu *NoteUpdate) RemoveAttachments(a ...*Attachment) *NoteUpdate
RemoveAttachments removes "attachments" edges to Attachment entities.
func (*NoteUpdate) RemoveMentionIDs ¶
func (nu *NoteUpdate) RemoveMentionIDs(ids ...uuid.UUID) *NoteUpdate
RemoveMentionIDs removes the "mentions" edge to User entities by IDs.
func (*NoteUpdate) RemoveMentions ¶
func (nu *NoteUpdate) RemoveMentions(u ...*User) *NoteUpdate
RemoveMentions removes "mentions" edges to User entities.
func (*NoteUpdate) Save ¶
func (nu *NoteUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*NoteUpdate) SaveX ¶
func (nu *NoteUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*NoteUpdate) SetAuthor ¶
func (nu *NoteUpdate) SetAuthor(u *User) *NoteUpdate
SetAuthor sets the "author" edge to the User entity.
func (*NoteUpdate) SetAuthorID ¶
func (nu *NoteUpdate) SetAuthorID(id uuid.UUID) *NoteUpdate
SetAuthorID sets the "author" edge to the User entity by ID.
func (*NoteUpdate) SetContent ¶
func (nu *NoteUpdate) SetContent(s string) *NoteUpdate
SetContent sets the "content" field.
func (*NoteUpdate) SetExtensions ¶
func (nu *NoteUpdate) SetExtensions(v versia.Extensions) *NoteUpdate
SetExtensions sets the "extensions" field.
func (*NoteUpdate) SetIsRemote ¶
func (nu *NoteUpdate) SetIsRemote(b bool) *NoteUpdate
SetIsRemote sets the "isRemote" field.
func (*NoteUpdate) SetIsSensitive ¶
func (nu *NoteUpdate) SetIsSensitive(b bool) *NoteUpdate
SetIsSensitive sets the "isSensitive" field.
func (*NoteUpdate) SetNillableContent ¶
func (nu *NoteUpdate) SetNillableContent(s *string) *NoteUpdate
SetNillableContent sets the "content" field if the given value is not nil.
func (*NoteUpdate) SetNillableIsRemote ¶
func (nu *NoteUpdate) SetNillableIsRemote(b *bool) *NoteUpdate
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*NoteUpdate) SetNillableIsSensitive ¶
func (nu *NoteUpdate) SetNillableIsSensitive(b *bool) *NoteUpdate
SetNillableIsSensitive sets the "isSensitive" field if the given value is not nil.
func (*NoteUpdate) SetNillableSubject ¶
func (nu *NoteUpdate) SetNillableSubject(s *string) *NoteUpdate
SetNillableSubject sets the "subject" field if the given value is not nil.
func (*NoteUpdate) SetNillableURI ¶
func (nu *NoteUpdate) SetNillableURI(s *string) *NoteUpdate
SetNillableURI sets the "uri" field if the given value is not nil.
func (*NoteUpdate) SetNillableVisibility ¶
func (nu *NoteUpdate) SetNillableVisibility(n *note.Visibility) *NoteUpdate
SetNillableVisibility sets the "visibility" field if the given value is not nil.
func (*NoteUpdate) SetSubject ¶
func (nu *NoteUpdate) SetSubject(s string) *NoteUpdate
SetSubject sets the "subject" field.
func (*NoteUpdate) SetURI ¶
func (nu *NoteUpdate) SetURI(s string) *NoteUpdate
SetURI sets the "uri" field.
func (*NoteUpdate) SetUpdatedAt ¶
func (nu *NoteUpdate) SetUpdatedAt(t time.Time) *NoteUpdate
SetUpdatedAt sets the "updated_at" field.
func (*NoteUpdate) SetVisibility ¶
func (nu *NoteUpdate) SetVisibility(n note.Visibility) *NoteUpdate
SetVisibility sets the "visibility" field.
func (*NoteUpdate) Where ¶
func (nu *NoteUpdate) Where(ps ...predicate.Note) *NoteUpdate
Where appends a list predicates to the NoteUpdate builder.
type NoteUpdateOne ¶
type NoteUpdateOne struct {
// contains filtered or unexported fields
}
NoteUpdateOne is the builder for updating a single Note entity.
func (*NoteUpdateOne) AddAttachmentIDs ¶
func (nuo *NoteUpdateOne) AddAttachmentIDs(ids ...uuid.UUID) *NoteUpdateOne
AddAttachmentIDs adds the "attachments" edge to the Attachment entity by IDs.
func (*NoteUpdateOne) AddAttachments ¶
func (nuo *NoteUpdateOne) AddAttachments(a ...*Attachment) *NoteUpdateOne
AddAttachments adds the "attachments" edges to the Attachment entity.
func (*NoteUpdateOne) AddMentionIDs ¶
func (nuo *NoteUpdateOne) AddMentionIDs(ids ...uuid.UUID) *NoteUpdateOne
AddMentionIDs adds the "mentions" edge to the User entity by IDs.
func (*NoteUpdateOne) AddMentions ¶
func (nuo *NoteUpdateOne) AddMentions(u ...*User) *NoteUpdateOne
AddMentions adds the "mentions" edges to the User entity.
func (*NoteUpdateOne) ClearAttachments ¶
func (nuo *NoteUpdateOne) ClearAttachments() *NoteUpdateOne
ClearAttachments clears all "attachments" edges to the Attachment entity.
func (*NoteUpdateOne) ClearAuthor ¶
func (nuo *NoteUpdateOne) ClearAuthor() *NoteUpdateOne
ClearAuthor clears the "author" edge to the User entity.
func (*NoteUpdateOne) ClearMentions ¶
func (nuo *NoteUpdateOne) ClearMentions() *NoteUpdateOne
ClearMentions clears all "mentions" edges to the User entity.
func (*NoteUpdateOne) ClearSubject ¶
func (nuo *NoteUpdateOne) ClearSubject() *NoteUpdateOne
ClearSubject clears the value of the "subject" field.
func (*NoteUpdateOne) Exec ¶
func (nuo *NoteUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*NoteUpdateOne) ExecX ¶
func (nuo *NoteUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteUpdateOne) Mutation ¶
func (nuo *NoteUpdateOne) Mutation() *NoteMutation
Mutation returns the NoteMutation object of the builder.
func (*NoteUpdateOne) RemoveAttachmentIDs ¶
func (nuo *NoteUpdateOne) RemoveAttachmentIDs(ids ...uuid.UUID) *NoteUpdateOne
RemoveAttachmentIDs removes the "attachments" edge to Attachment entities by IDs.
func (*NoteUpdateOne) RemoveAttachments ¶
func (nuo *NoteUpdateOne) RemoveAttachments(a ...*Attachment) *NoteUpdateOne
RemoveAttachments removes "attachments" edges to Attachment entities.
func (*NoteUpdateOne) RemoveMentionIDs ¶
func (nuo *NoteUpdateOne) RemoveMentionIDs(ids ...uuid.UUID) *NoteUpdateOne
RemoveMentionIDs removes the "mentions" edge to User entities by IDs.
func (*NoteUpdateOne) RemoveMentions ¶
func (nuo *NoteUpdateOne) RemoveMentions(u ...*User) *NoteUpdateOne
RemoveMentions removes "mentions" edges to User entities.
func (*NoteUpdateOne) Save ¶
func (nuo *NoteUpdateOne) Save(ctx context.Context) (*Note, error)
Save executes the query and returns the updated Note entity.
func (*NoteUpdateOne) SaveX ¶
func (nuo *NoteUpdateOne) SaveX(ctx context.Context) *Note
SaveX is like Save, but panics if an error occurs.
func (*NoteUpdateOne) Select ¶
func (nuo *NoteUpdateOne) Select(field string, fields ...string) *NoteUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*NoteUpdateOne) SetAuthor ¶
func (nuo *NoteUpdateOne) SetAuthor(u *User) *NoteUpdateOne
SetAuthor sets the "author" edge to the User entity.
func (*NoteUpdateOne) SetAuthorID ¶
func (nuo *NoteUpdateOne) SetAuthorID(id uuid.UUID) *NoteUpdateOne
SetAuthorID sets the "author" edge to the User entity by ID.
func (*NoteUpdateOne) SetContent ¶
func (nuo *NoteUpdateOne) SetContent(s string) *NoteUpdateOne
SetContent sets the "content" field.
func (*NoteUpdateOne) SetExtensions ¶
func (nuo *NoteUpdateOne) SetExtensions(v versia.Extensions) *NoteUpdateOne
SetExtensions sets the "extensions" field.
func (*NoteUpdateOne) SetIsRemote ¶
func (nuo *NoteUpdateOne) SetIsRemote(b bool) *NoteUpdateOne
SetIsRemote sets the "isRemote" field.
func (*NoteUpdateOne) SetIsSensitive ¶
func (nuo *NoteUpdateOne) SetIsSensitive(b bool) *NoteUpdateOne
SetIsSensitive sets the "isSensitive" field.
func (*NoteUpdateOne) SetNillableContent ¶
func (nuo *NoteUpdateOne) SetNillableContent(s *string) *NoteUpdateOne
SetNillableContent sets the "content" field if the given value is not nil.
func (*NoteUpdateOne) SetNillableIsRemote ¶
func (nuo *NoteUpdateOne) SetNillableIsRemote(b *bool) *NoteUpdateOne
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*NoteUpdateOne) SetNillableIsSensitive ¶
func (nuo *NoteUpdateOne) SetNillableIsSensitive(b *bool) *NoteUpdateOne
SetNillableIsSensitive sets the "isSensitive" field if the given value is not nil.
func (*NoteUpdateOne) SetNillableSubject ¶
func (nuo *NoteUpdateOne) SetNillableSubject(s *string) *NoteUpdateOne
SetNillableSubject sets the "subject" field if the given value is not nil.
func (*NoteUpdateOne) SetNillableURI ¶
func (nuo *NoteUpdateOne) SetNillableURI(s *string) *NoteUpdateOne
SetNillableURI sets the "uri" field if the given value is not nil.
func (*NoteUpdateOne) SetNillableVisibility ¶
func (nuo *NoteUpdateOne) SetNillableVisibility(n *note.Visibility) *NoteUpdateOne
SetNillableVisibility sets the "visibility" field if the given value is not nil.
func (*NoteUpdateOne) SetSubject ¶
func (nuo *NoteUpdateOne) SetSubject(s string) *NoteUpdateOne
SetSubject sets the "subject" field.
func (*NoteUpdateOne) SetURI ¶
func (nuo *NoteUpdateOne) SetURI(s string) *NoteUpdateOne
SetURI sets the "uri" field.
func (*NoteUpdateOne) SetUpdatedAt ¶
func (nuo *NoteUpdateOne) SetUpdatedAt(t time.Time) *NoteUpdateOne
SetUpdatedAt sets the "updated_at" field.
func (*NoteUpdateOne) SetVisibility ¶
func (nuo *NoteUpdateOne) SetVisibility(n note.Visibility) *NoteUpdateOne
SetVisibility sets the "visibility" field.
func (*NoteUpdateOne) Where ¶
func (nuo *NoteUpdateOne) Where(ps ...predicate.Note) *NoteUpdateOne
Where appends a list predicates to the NoteUpdate builder.
type NoteUpsert ¶
NoteUpsert is the "OnConflict" setter.
func (*NoteUpsert) ClearSubject ¶
func (u *NoteUpsert) ClearSubject() *NoteUpsert
ClearSubject clears the value of the "subject" field.
func (*NoteUpsert) SetContent ¶
func (u *NoteUpsert) SetContent(v string) *NoteUpsert
SetContent sets the "content" field.
func (*NoteUpsert) SetExtensions ¶
func (u *NoteUpsert) SetExtensions(v versia.Extensions) *NoteUpsert
SetExtensions sets the "extensions" field.
func (*NoteUpsert) SetIsRemote ¶
func (u *NoteUpsert) SetIsRemote(v bool) *NoteUpsert
SetIsRemote sets the "isRemote" field.
func (*NoteUpsert) SetIsSensitive ¶
func (u *NoteUpsert) SetIsSensitive(v bool) *NoteUpsert
SetIsSensitive sets the "isSensitive" field.
func (*NoteUpsert) SetSubject ¶
func (u *NoteUpsert) SetSubject(v string) *NoteUpsert
SetSubject sets the "subject" field.
func (*NoteUpsert) SetURI ¶
func (u *NoteUpsert) SetURI(v string) *NoteUpsert
SetURI sets the "uri" field.
func (*NoteUpsert) SetUpdatedAt ¶
func (u *NoteUpsert) SetUpdatedAt(v time.Time) *NoteUpsert
SetUpdatedAt sets the "updated_at" field.
func (*NoteUpsert) SetVisibility ¶
func (u *NoteUpsert) SetVisibility(v note.Visibility) *NoteUpsert
SetVisibility sets the "visibility" field.
func (*NoteUpsert) UpdateContent ¶
func (u *NoteUpsert) UpdateContent() *NoteUpsert
UpdateContent sets the "content" field to the value that was provided on create.
func (*NoteUpsert) UpdateExtensions ¶
func (u *NoteUpsert) UpdateExtensions() *NoteUpsert
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*NoteUpsert) UpdateIsRemote ¶
func (u *NoteUpsert) UpdateIsRemote() *NoteUpsert
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*NoteUpsert) UpdateIsSensitive ¶
func (u *NoteUpsert) UpdateIsSensitive() *NoteUpsert
UpdateIsSensitive sets the "isSensitive" field to the value that was provided on create.
func (*NoteUpsert) UpdateSubject ¶
func (u *NoteUpsert) UpdateSubject() *NoteUpsert
UpdateSubject sets the "subject" field to the value that was provided on create.
func (*NoteUpsert) UpdateURI ¶
func (u *NoteUpsert) UpdateURI() *NoteUpsert
UpdateURI sets the "uri" field to the value that was provided on create.
func (*NoteUpsert) UpdateUpdatedAt ¶
func (u *NoteUpsert) UpdateUpdatedAt() *NoteUpsert
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*NoteUpsert) UpdateVisibility ¶
func (u *NoteUpsert) UpdateVisibility() *NoteUpsert
UpdateVisibility sets the "visibility" field to the value that was provided on create.
type NoteUpsertBulk ¶
type NoteUpsertBulk struct {
// contains filtered or unexported fields
}
NoteUpsertBulk is the builder for "upsert"-ing a bulk of Note nodes.
func (*NoteUpsertBulk) ClearSubject ¶
func (u *NoteUpsertBulk) ClearSubject() *NoteUpsertBulk
ClearSubject clears the value of the "subject" field.
func (*NoteUpsertBulk) DoNothing ¶
func (u *NoteUpsertBulk) DoNothing() *NoteUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*NoteUpsertBulk) Exec ¶
func (u *NoteUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*NoteUpsertBulk) ExecX ¶
func (u *NoteUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteUpsertBulk) Ignore ¶
func (u *NoteUpsertBulk) Ignore() *NoteUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Note.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*NoteUpsertBulk) SetContent ¶
func (u *NoteUpsertBulk) SetContent(v string) *NoteUpsertBulk
SetContent sets the "content" field.
func (*NoteUpsertBulk) SetExtensions ¶
func (u *NoteUpsertBulk) SetExtensions(v versia.Extensions) *NoteUpsertBulk
SetExtensions sets the "extensions" field.
func (*NoteUpsertBulk) SetIsRemote ¶
func (u *NoteUpsertBulk) SetIsRemote(v bool) *NoteUpsertBulk
SetIsRemote sets the "isRemote" field.
func (*NoteUpsertBulk) SetIsSensitive ¶
func (u *NoteUpsertBulk) SetIsSensitive(v bool) *NoteUpsertBulk
SetIsSensitive sets the "isSensitive" field.
func (*NoteUpsertBulk) SetSubject ¶
func (u *NoteUpsertBulk) SetSubject(v string) *NoteUpsertBulk
SetSubject sets the "subject" field.
func (*NoteUpsertBulk) SetURI ¶
func (u *NoteUpsertBulk) SetURI(v string) *NoteUpsertBulk
SetURI sets the "uri" field.
func (*NoteUpsertBulk) SetUpdatedAt ¶
func (u *NoteUpsertBulk) SetUpdatedAt(v time.Time) *NoteUpsertBulk
SetUpdatedAt sets the "updated_at" field.
func (*NoteUpsertBulk) SetVisibility ¶
func (u *NoteUpsertBulk) SetVisibility(v note.Visibility) *NoteUpsertBulk
SetVisibility sets the "visibility" field.
func (*NoteUpsertBulk) Update ¶
func (u *NoteUpsertBulk) Update(set func(*NoteUpsert)) *NoteUpsertBulk
Update allows overriding fields `UPDATE` values. See the NoteCreateBulk.OnConflict documentation for more info.
func (*NoteUpsertBulk) UpdateContent ¶
func (u *NoteUpsertBulk) UpdateContent() *NoteUpsertBulk
UpdateContent sets the "content" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateExtensions ¶
func (u *NoteUpsertBulk) UpdateExtensions() *NoteUpsertBulk
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateIsRemote ¶
func (u *NoteUpsertBulk) UpdateIsRemote() *NoteUpsertBulk
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateIsSensitive ¶
func (u *NoteUpsertBulk) UpdateIsSensitive() *NoteUpsertBulk
UpdateIsSensitive sets the "isSensitive" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateNewValues ¶
func (u *NoteUpsertBulk) UpdateNewValues() *NoteUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Note.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(note.FieldID) }), ). Exec(ctx)
func (*NoteUpsertBulk) UpdateSubject ¶
func (u *NoteUpsertBulk) UpdateSubject() *NoteUpsertBulk
UpdateSubject sets the "subject" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateURI ¶
func (u *NoteUpsertBulk) UpdateURI() *NoteUpsertBulk
UpdateURI sets the "uri" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateUpdatedAt ¶
func (u *NoteUpsertBulk) UpdateUpdatedAt() *NoteUpsertBulk
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*NoteUpsertBulk) UpdateVisibility ¶
func (u *NoteUpsertBulk) UpdateVisibility() *NoteUpsertBulk
UpdateVisibility sets the "visibility" field to the value that was provided on create.
type NoteUpsertOne ¶
type NoteUpsertOne struct {
// contains filtered or unexported fields
}
NoteUpsertOne is the builder for "upsert"-ing
one Note node.
func (*NoteUpsertOne) ClearSubject ¶
func (u *NoteUpsertOne) ClearSubject() *NoteUpsertOne
ClearSubject clears the value of the "subject" field.
func (*NoteUpsertOne) DoNothing ¶
func (u *NoteUpsertOne) DoNothing() *NoteUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*NoteUpsertOne) Exec ¶
func (u *NoteUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*NoteUpsertOne) ExecX ¶
func (u *NoteUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NoteUpsertOne) IDX ¶
func (u *NoteUpsertOne) IDX(ctx context.Context) uuid.UUID
IDX is like ID, but panics if an error occurs.
func (*NoteUpsertOne) Ignore ¶
func (u *NoteUpsertOne) Ignore() *NoteUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Note.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*NoteUpsertOne) SetContent ¶
func (u *NoteUpsertOne) SetContent(v string) *NoteUpsertOne
SetContent sets the "content" field.
func (*NoteUpsertOne) SetExtensions ¶
func (u *NoteUpsertOne) SetExtensions(v versia.Extensions) *NoteUpsertOne
SetExtensions sets the "extensions" field.
func (*NoteUpsertOne) SetIsRemote ¶
func (u *NoteUpsertOne) SetIsRemote(v bool) *NoteUpsertOne
SetIsRemote sets the "isRemote" field.
func (*NoteUpsertOne) SetIsSensitive ¶
func (u *NoteUpsertOne) SetIsSensitive(v bool) *NoteUpsertOne
SetIsSensitive sets the "isSensitive" field.
func (*NoteUpsertOne) SetSubject ¶
func (u *NoteUpsertOne) SetSubject(v string) *NoteUpsertOne
SetSubject sets the "subject" field.
func (*NoteUpsertOne) SetURI ¶
func (u *NoteUpsertOne) SetURI(v string) *NoteUpsertOne
SetURI sets the "uri" field.
func (*NoteUpsertOne) SetUpdatedAt ¶
func (u *NoteUpsertOne) SetUpdatedAt(v time.Time) *NoteUpsertOne
SetUpdatedAt sets the "updated_at" field.
func (*NoteUpsertOne) SetVisibility ¶
func (u *NoteUpsertOne) SetVisibility(v note.Visibility) *NoteUpsertOne
SetVisibility sets the "visibility" field.
func (*NoteUpsertOne) Update ¶
func (u *NoteUpsertOne) Update(set func(*NoteUpsert)) *NoteUpsertOne
Update allows overriding fields `UPDATE` values. See the NoteCreate.OnConflict documentation for more info.
func (*NoteUpsertOne) UpdateContent ¶
func (u *NoteUpsertOne) UpdateContent() *NoteUpsertOne
UpdateContent sets the "content" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateExtensions ¶
func (u *NoteUpsertOne) UpdateExtensions() *NoteUpsertOne
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateIsRemote ¶
func (u *NoteUpsertOne) UpdateIsRemote() *NoteUpsertOne
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateIsSensitive ¶
func (u *NoteUpsertOne) UpdateIsSensitive() *NoteUpsertOne
UpdateIsSensitive sets the "isSensitive" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateNewValues ¶
func (u *NoteUpsertOne) UpdateNewValues() *NoteUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:
client.Note.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(note.FieldID) }), ). Exec(ctx)
func (*NoteUpsertOne) UpdateSubject ¶
func (u *NoteUpsertOne) UpdateSubject() *NoteUpsertOne
UpdateSubject sets the "subject" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateURI ¶
func (u *NoteUpsertOne) UpdateURI() *NoteUpsertOne
UpdateURI sets the "uri" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateUpdatedAt ¶
func (u *NoteUpsertOne) UpdateUpdatedAt() *NoteUpsertOne
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*NoteUpsertOne) UpdateVisibility ¶
func (u *NoteUpsertOne) UpdateVisibility() *NoteUpsertOne
UpdateVisibility sets the "visibility" field to the value that was provided on create.
type OrderFunc ¶
OrderFunc applies an ordering on the sql selector. Deprecated: Use Asc/Desc functions or the package builders instead.
type QuerierFunc ¶
type QuerierFunc = ent.QuerierFunc
ent aliases to avoid import conflicts in user's code.
type QueryContext ¶
type QueryContext = ent.QueryContext
ent aliases to avoid import conflicts in user's code.
type RollbackFunc ¶
The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.
type RollbackHook ¶
type RollbackHook func(Rollbacker) Rollbacker
RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:
hook := func(next ent.Rollbacker) ent.Rollbacker { return ent.RollbackFunc(func(ctx context.Context, tx *ent.Tx) error { // Do some stuff before. if err := next.Rollback(ctx, tx); err != nil { return err } // Do some stuff after. return nil }) }
type Rollbacker ¶
Rollbacker is the interface that wraps the Rollback method.
type TraverseFunc ¶
type TraverseFunc = ent.TraverseFunc
ent aliases to avoid import conflicts in user's code.
type Tx ¶
type Tx struct { // Attachment is the client for interacting with the Attachment builders. Attachment *AttachmentClient // Follow is the client for interacting with the Follow builders. Follow *FollowClient // Image is the client for interacting with the Image builders. Image *ImageClient // InstanceMetadata is the client for interacting with the InstanceMetadata builders. InstanceMetadata *InstanceMetadataClient // Note is the client for interacting with the Note builders. Note *NoteClient // User is the client for interacting with the User builders. User *UserClient // contains filtered or unexported fields }
Tx is a transactional client that is created by calling Client.Tx().
func TxFromContext ¶
TxFromContext returns a Tx stored inside a context, or nil if there isn't one.
func (*Tx) OnRollback ¶
func (tx *Tx) OnRollback(f RollbackHook)
OnRollback adds a hook to call on rollback.
type User ¶
type User struct { // ID of the ent. ID uuid.UUID `json:"id,omitempty"` // IsRemote holds the value of the "isRemote" field. IsRemote bool `json:"isRemote,omitempty"` // URI holds the value of the "uri" field. URI string `json:"uri,omitempty"` // Extensions holds the value of the "extensions" field. Extensions versia.Extensions `json:"extensions,omitempty"` // CreatedAt holds the value of the "created_at" field. CreatedAt time.Time `json:"created_at,omitempty"` // UpdatedAt holds the value of the "updated_at" field. UpdatedAt time.Time `json:"updated_at,omitempty"` // Username holds the value of the "username" field. Username string `json:"username,omitempty"` // PasswordHash holds the value of the "passwordHash" field. PasswordHash *[]byte `json:"passwordHash,omitempty"` // DisplayName holds the value of the "displayName" field. DisplayName *string `json:"displayName,omitempty"` // Biography holds the value of the "biography" field. Biography *string `json:"biography,omitempty"` // PublicKey holds the value of the "publicKey" field. PublicKey []byte `json:"publicKey,omitempty"` // PublicKeyActor holds the value of the "publicKeyActor" field. PublicKeyActor string `json:"publicKeyActor,omitempty"` // PublicKeyAlgorithm holds the value of the "publicKeyAlgorithm" field. PublicKeyAlgorithm string `json:"publicKeyAlgorithm,omitempty"` // PrivateKey holds the value of the "privateKey" field. PrivateKey []byte `json:"privateKey,omitempty"` // Indexable holds the value of the "indexable" field. Indexable bool `json:"indexable,omitempty"` // PrivacyLevel holds the value of the "privacyLevel" field. PrivacyLevel user.PrivacyLevel `json:"privacyLevel,omitempty"` // Fields holds the value of the "fields" field. Fields []versia.UserField `json:"fields,omitempty"` // Inbox holds the value of the "inbox" field. Inbox string `json:"inbox,omitempty"` // Featured holds the value of the "featured" field. Featured string `json:"featured,omitempty"` // Followers holds the value of the "followers" field. Followers string `json:"followers,omitempty"` // Following holds the value of the "following" field. Following string `json:"following,omitempty"` // Outbox holds the value of the "outbox" field. Outbox string `json:"outbox,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the UserQuery when eager-loading is set. Edges UserEdges `json:"edges"` // contains filtered or unexported fields }
User is the model entity for the User schema.
func (*User) QueryAdministeredServers ¶
func (u *User) QueryAdministeredServers() *InstanceMetadataQuery
QueryAdministeredServers queries the "administeredServers" edge of the User entity.
func (*User) QueryAuthoredNotes ¶
QueryAuthoredNotes queries the "authoredNotes" edge of the User entity.
func (*User) QueryAvatarImage ¶
func (u *User) QueryAvatarImage() *ImageQuery
QueryAvatarImage queries the "avatarImage" edge of the User entity.
func (*User) QueryHeaderImage ¶
func (u *User) QueryHeaderImage() *ImageQuery
QueryHeaderImage queries the "headerImage" edge of the User entity.
func (*User) QueryMentionedNotes ¶
QueryMentionedNotes queries the "mentionedNotes" edge of the User entity.
func (*User) QueryModeratedServers ¶
func (u *User) QueryModeratedServers() *InstanceMetadataQuery
QueryModeratedServers queries the "moderatedServers" edge of the User entity.
func (*User) QueryServers ¶
func (u *User) QueryServers() *InstanceMetadataQuery
QueryServers queries the "servers" edge of the User entity.
func (*User) Unwrap ¶
Unwrap unwraps the User entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*User) Update ¶
func (u *User) Update() *UserUpdateOne
Update returns a builder for updating this User. Note that you need to call User.Unwrap() before calling this method if this User was returned from a transaction, and the transaction was committed or rolled back.
type UserClient ¶
type UserClient struct {
// contains filtered or unexported fields
}
UserClient is a client for the User schema.
func NewUserClient ¶
func NewUserClient(c config) *UserClient
NewUserClient returns a client for the User from the given config.
func (*UserClient) Create ¶
func (c *UserClient) Create() *UserCreate
Create returns a builder for creating a User entity.
func (*UserClient) CreateBulk ¶
func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
CreateBulk returns a builder for creating a bulk of User entities.
func (*UserClient) Delete ¶
func (c *UserClient) Delete() *UserDelete
Delete returns a delete builder for User.
func (*UserClient) DeleteOne ¶
func (c *UserClient) DeleteOne(u *User) *UserDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*UserClient) DeleteOneID ¶
func (c *UserClient) DeleteOneID(id uuid.UUID) *UserDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*UserClient) Intercept ¶
func (c *UserClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `user.Intercept(f(g(h())))`.
func (*UserClient) Interceptors ¶
func (c *UserClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*UserClient) MapCreateBulk ¶
func (c *UserClient) MapCreateBulk(slice any, setFunc func(*UserCreate, int)) *UserCreateBulk
MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.
func (*UserClient) Query ¶
func (c *UserClient) Query() *UserQuery
Query returns a query builder for User.
func (*UserClient) QueryAdministeredServers ¶
func (c *UserClient) QueryAdministeredServers(u *User) *InstanceMetadataQuery
QueryAdministeredServers queries the administeredServers edge of a User.
func (*UserClient) QueryAuthoredNotes ¶
func (c *UserClient) QueryAuthoredNotes(u *User) *NoteQuery
QueryAuthoredNotes queries the authoredNotes edge of a User.
func (*UserClient) QueryAvatarImage ¶
func (c *UserClient) QueryAvatarImage(u *User) *ImageQuery
QueryAvatarImage queries the avatarImage edge of a User.
func (*UserClient) QueryHeaderImage ¶
func (c *UserClient) QueryHeaderImage(u *User) *ImageQuery
QueryHeaderImage queries the headerImage edge of a User.
func (*UserClient) QueryMentionedNotes ¶
func (c *UserClient) QueryMentionedNotes(u *User) *NoteQuery
QueryMentionedNotes queries the mentionedNotes edge of a User.
func (*UserClient) QueryModeratedServers ¶
func (c *UserClient) QueryModeratedServers(u *User) *InstanceMetadataQuery
QueryModeratedServers queries the moderatedServers edge of a User.
func (*UserClient) QueryServers ¶
func (c *UserClient) QueryServers(u *User) *InstanceMetadataQuery
QueryServers queries the servers edge of a User.
func (*UserClient) Update ¶
func (c *UserClient) Update() *UserUpdate
Update returns an update builder for User.
func (*UserClient) UpdateOne ¶
func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
UpdateOne returns an update builder for the given entity.
func (*UserClient) UpdateOneID ¶
func (c *UserClient) UpdateOneID(id uuid.UUID) *UserUpdateOne
UpdateOneID returns an update builder for the given id.
func (*UserClient) Use ¶
func (c *UserClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `user.Hooks(f(g(h())))`.
type UserCreate ¶
type UserCreate struct {
// contains filtered or unexported fields
}
UserCreate is the builder for creating a User entity.
func (*UserCreate) AddAdministeredServerIDs ¶
func (uc *UserCreate) AddAdministeredServerIDs(ids ...uuid.UUID) *UserCreate
AddAdministeredServerIDs adds the "administeredServers" edge to the InstanceMetadata entity by IDs.
func (*UserCreate) AddAdministeredServers ¶
func (uc *UserCreate) AddAdministeredServers(i ...*InstanceMetadata) *UserCreate
AddAdministeredServers adds the "administeredServers" edges to the InstanceMetadata entity.
func (*UserCreate) AddAuthoredNoteIDs ¶
func (uc *UserCreate) AddAuthoredNoteIDs(ids ...uuid.UUID) *UserCreate
AddAuthoredNoteIDs adds the "authoredNotes" edge to the Note entity by IDs.
func (*UserCreate) AddAuthoredNotes ¶
func (uc *UserCreate) AddAuthoredNotes(n ...*Note) *UserCreate
AddAuthoredNotes adds the "authoredNotes" edges to the Note entity.
func (*UserCreate) AddMentionedNoteIDs ¶
func (uc *UserCreate) AddMentionedNoteIDs(ids ...uuid.UUID) *UserCreate
AddMentionedNoteIDs adds the "mentionedNotes" edge to the Note entity by IDs.
func (*UserCreate) AddMentionedNotes ¶
func (uc *UserCreate) AddMentionedNotes(n ...*Note) *UserCreate
AddMentionedNotes adds the "mentionedNotes" edges to the Note entity.
func (*UserCreate) AddModeratedServerIDs ¶
func (uc *UserCreate) AddModeratedServerIDs(ids ...uuid.UUID) *UserCreate
AddModeratedServerIDs adds the "moderatedServers" edge to the InstanceMetadata entity by IDs.
func (*UserCreate) AddModeratedServers ¶
func (uc *UserCreate) AddModeratedServers(i ...*InstanceMetadata) *UserCreate
AddModeratedServers adds the "moderatedServers" edges to the InstanceMetadata entity.
func (*UserCreate) AddServerIDs ¶
func (uc *UserCreate) AddServerIDs(ids ...uuid.UUID) *UserCreate
AddServerIDs adds the "servers" edge to the InstanceMetadata entity by IDs.
func (*UserCreate) AddServers ¶
func (uc *UserCreate) AddServers(i ...*InstanceMetadata) *UserCreate
AddServers adds the "servers" edges to the InstanceMetadata entity.
func (*UserCreate) Exec ¶
func (uc *UserCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*UserCreate) ExecX ¶
func (uc *UserCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserCreate) Mutation ¶
func (uc *UserCreate) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserCreate) OnConflict ¶
func (uc *UserCreate) OnConflict(opts ...sql.ConflictOption) *UserUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.User.Create(). SetIsRemote(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.UserUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*UserCreate) OnConflictColumns ¶
func (uc *UserCreate) OnConflictColumns(columns ...string) *UserUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*UserCreate) Save ¶
func (uc *UserCreate) Save(ctx context.Context) (*User, error)
Save creates the User in the database.
func (*UserCreate) SaveX ¶
func (uc *UserCreate) SaveX(ctx context.Context) *User
SaveX calls Save and panics if Save returns an error.
func (*UserCreate) SetAvatarImage ¶
func (uc *UserCreate) SetAvatarImage(i *Image) *UserCreate
SetAvatarImage sets the "avatarImage" edge to the Image entity.
func (*UserCreate) SetAvatarImageID ¶
func (uc *UserCreate) SetAvatarImageID(id int) *UserCreate
SetAvatarImageID sets the "avatarImage" edge to the Image entity by ID.
func (*UserCreate) SetBiography ¶
func (uc *UserCreate) SetBiography(s string) *UserCreate
SetBiography sets the "biography" field.
func (*UserCreate) SetCreatedAt ¶
func (uc *UserCreate) SetCreatedAt(t time.Time) *UserCreate
SetCreatedAt sets the "created_at" field.
func (*UserCreate) SetDisplayName ¶
func (uc *UserCreate) SetDisplayName(s string) *UserCreate
SetDisplayName sets the "displayName" field.
func (*UserCreate) SetExtensions ¶
func (uc *UserCreate) SetExtensions(v versia.Extensions) *UserCreate
SetExtensions sets the "extensions" field.
func (*UserCreate) SetFeatured ¶
func (uc *UserCreate) SetFeatured(s string) *UserCreate
SetFeatured sets the "featured" field.
func (*UserCreate) SetFields ¶
func (uc *UserCreate) SetFields(vf []versia.UserField) *UserCreate
SetFields sets the "fields" field.
func (*UserCreate) SetFollowers ¶
func (uc *UserCreate) SetFollowers(s string) *UserCreate
SetFollowers sets the "followers" field.
func (*UserCreate) SetFollowing ¶
func (uc *UserCreate) SetFollowing(s string) *UserCreate
SetFollowing sets the "following" field.
func (*UserCreate) SetHeaderImage ¶
func (uc *UserCreate) SetHeaderImage(i *Image) *UserCreate
SetHeaderImage sets the "headerImage" edge to the Image entity.
func (*UserCreate) SetHeaderImageID ¶
func (uc *UserCreate) SetHeaderImageID(id int) *UserCreate
SetHeaderImageID sets the "headerImage" edge to the Image entity by ID.
func (*UserCreate) SetID ¶
func (uc *UserCreate) SetID(u uuid.UUID) *UserCreate
SetID sets the "id" field.
func (*UserCreate) SetInbox ¶
func (uc *UserCreate) SetInbox(s string) *UserCreate
SetInbox sets the "inbox" field.
func (*UserCreate) SetIndexable ¶
func (uc *UserCreate) SetIndexable(b bool) *UserCreate
SetIndexable sets the "indexable" field.
func (*UserCreate) SetIsRemote ¶
func (uc *UserCreate) SetIsRemote(b bool) *UserCreate
SetIsRemote sets the "isRemote" field.
func (*UserCreate) SetNillableAvatarImageID ¶
func (uc *UserCreate) SetNillableAvatarImageID(id *int) *UserCreate
SetNillableAvatarImageID sets the "avatarImage" edge to the Image entity by ID if the given value is not nil.
func (*UserCreate) SetNillableBiography ¶
func (uc *UserCreate) SetNillableBiography(s *string) *UserCreate
SetNillableBiography sets the "biography" field if the given value is not nil.
func (*UserCreate) SetNillableCreatedAt ¶
func (uc *UserCreate) SetNillableCreatedAt(t *time.Time) *UserCreate
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*UserCreate) SetNillableDisplayName ¶
func (uc *UserCreate) SetNillableDisplayName(s *string) *UserCreate
SetNillableDisplayName sets the "displayName" field if the given value is not nil.
func (*UserCreate) SetNillableHeaderImageID ¶
func (uc *UserCreate) SetNillableHeaderImageID(id *int) *UserCreate
SetNillableHeaderImageID sets the "headerImage" edge to the Image entity by ID if the given value is not nil.
func (*UserCreate) SetNillableID ¶
func (uc *UserCreate) SetNillableID(u *uuid.UUID) *UserCreate
SetNillableID sets the "id" field if the given value is not nil.
func (*UserCreate) SetNillableIndexable ¶
func (uc *UserCreate) SetNillableIndexable(b *bool) *UserCreate
SetNillableIndexable sets the "indexable" field if the given value is not nil.
func (*UserCreate) SetNillablePrivacyLevel ¶
func (uc *UserCreate) SetNillablePrivacyLevel(ul *user.PrivacyLevel) *UserCreate
SetNillablePrivacyLevel sets the "privacyLevel" field if the given value is not nil.
func (*UserCreate) SetNillableUpdatedAt ¶
func (uc *UserCreate) SetNillableUpdatedAt(t *time.Time) *UserCreate
SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.
func (*UserCreate) SetOutbox ¶
func (uc *UserCreate) SetOutbox(s string) *UserCreate
SetOutbox sets the "outbox" field.
func (*UserCreate) SetPasswordHash ¶
func (uc *UserCreate) SetPasswordHash(b []byte) *UserCreate
SetPasswordHash sets the "passwordHash" field.
func (*UserCreate) SetPrivacyLevel ¶
func (uc *UserCreate) SetPrivacyLevel(ul user.PrivacyLevel) *UserCreate
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserCreate) SetPrivateKey ¶
func (uc *UserCreate) SetPrivateKey(b []byte) *UserCreate
SetPrivateKey sets the "privateKey" field.
func (*UserCreate) SetPublicKey ¶
func (uc *UserCreate) SetPublicKey(b []byte) *UserCreate
SetPublicKey sets the "publicKey" field.
func (*UserCreate) SetPublicKeyActor ¶
func (uc *UserCreate) SetPublicKeyActor(s string) *UserCreate
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserCreate) SetPublicKeyAlgorithm ¶
func (uc *UserCreate) SetPublicKeyAlgorithm(s string) *UserCreate
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserCreate) SetURI ¶
func (uc *UserCreate) SetURI(s string) *UserCreate
SetURI sets the "uri" field.
func (*UserCreate) SetUpdatedAt ¶
func (uc *UserCreate) SetUpdatedAt(t time.Time) *UserCreate
SetUpdatedAt sets the "updated_at" field.
func (*UserCreate) SetUsername ¶
func (uc *UserCreate) SetUsername(s string) *UserCreate
SetUsername sets the "username" field.
type UserCreateBulk ¶
type UserCreateBulk struct {
// contains filtered or unexported fields
}
UserCreateBulk is the builder for creating many User entities in bulk.
func (*UserCreateBulk) Exec ¶
func (ucb *UserCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*UserCreateBulk) ExecX ¶
func (ucb *UserCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserCreateBulk) OnConflict ¶
func (ucb *UserCreateBulk) OnConflict(opts ...sql.ConflictOption) *UserUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.User.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.UserUpsert) { SetIsRemote(v+v). }). Exec(ctx)
func (*UserCreateBulk) OnConflictColumns ¶
func (ucb *UserCreateBulk) OnConflictColumns(columns ...string) *UserUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type UserDelete ¶
type UserDelete struct {
// contains filtered or unexported fields
}
UserDelete is the builder for deleting a User entity.
func (*UserDelete) Exec ¶
func (ud *UserDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*UserDelete) ExecX ¶
func (ud *UserDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*UserDelete) Where ¶
func (ud *UserDelete) Where(ps ...predicate.User) *UserDelete
Where appends a list predicates to the UserDelete builder.
type UserDeleteOne ¶
type UserDeleteOne struct {
// contains filtered or unexported fields
}
UserDeleteOne is the builder for deleting a single User entity.
func (*UserDeleteOne) Exec ¶
func (udo *UserDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*UserDeleteOne) ExecX ¶
func (udo *UserDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserDeleteOne) Where ¶
func (udo *UserDeleteOne) Where(ps ...predicate.User) *UserDeleteOne
Where appends a list predicates to the UserDelete builder.
type UserEdges ¶
type UserEdges struct { // AvatarImage holds the value of the avatarImage edge. AvatarImage *Image `json:"avatarImage,omitempty"` // HeaderImage holds the value of the headerImage edge. HeaderImage *Image `json:"headerImage,omitempty"` // AuthoredNotes holds the value of the authoredNotes edge. AuthoredNotes []*Note `json:"authoredNotes,omitempty"` // MentionedNotes holds the value of the mentionedNotes edge. MentionedNotes []*Note `json:"mentionedNotes,omitempty"` // Servers holds the value of the servers edge. Servers []*InstanceMetadata `json:"servers,omitempty"` // ModeratedServers holds the value of the moderatedServers edge. ModeratedServers []*InstanceMetadata `json:"moderatedServers,omitempty"` // AdministeredServers holds the value of the administeredServers edge. AdministeredServers []*InstanceMetadata `json:"administeredServers,omitempty"` // contains filtered or unexported fields }
UserEdges holds the relations/edges for other nodes in the graph.
func (UserEdges) AdministeredServersOrErr ¶
func (e UserEdges) AdministeredServersOrErr() ([]*InstanceMetadata, error)
AdministeredServersOrErr returns the AdministeredServers value or an error if the edge was not loaded in eager-loading.
func (UserEdges) AuthoredNotesOrErr ¶
AuthoredNotesOrErr returns the AuthoredNotes value or an error if the edge was not loaded in eager-loading.
func (UserEdges) AvatarImageOrErr ¶
AvatarImageOrErr returns the AvatarImage value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (UserEdges) HeaderImageOrErr ¶
HeaderImageOrErr returns the HeaderImage value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (UserEdges) MentionedNotesOrErr ¶
MentionedNotesOrErr returns the MentionedNotes value or an error if the edge was not loaded in eager-loading.
func (UserEdges) ModeratedServersOrErr ¶
func (e UserEdges) ModeratedServersOrErr() ([]*InstanceMetadata, error)
ModeratedServersOrErr returns the ModeratedServers value or an error if the edge was not loaded in eager-loading.
func (UserEdges) ServersOrErr ¶
func (e UserEdges) ServersOrErr() ([]*InstanceMetadata, error)
ServersOrErr returns the Servers value or an error if the edge was not loaded in eager-loading.
type UserGroupBy ¶
type UserGroupBy struct {
// contains filtered or unexported fields
}
UserGroupBy is the group-by builder for User entities.
func (*UserGroupBy) Aggregate ¶
func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*UserGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*UserGroupBy) Scan ¶
func (ugb *UserGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*UserGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type UserMutation ¶
type UserMutation struct {
// contains filtered or unexported fields
}
UserMutation represents an operation that mutates the User nodes in the graph.
func (*UserMutation) AddAdministeredServerIDs ¶
func (m *UserMutation) AddAdministeredServerIDs(ids ...uuid.UUID)
AddAdministeredServerIDs adds the "administeredServers" edge to the InstanceMetadata entity by ids.
func (*UserMutation) AddAuthoredNoteIDs ¶
func (m *UserMutation) AddAuthoredNoteIDs(ids ...uuid.UUID)
AddAuthoredNoteIDs adds the "authoredNotes" edge to the Note entity by ids.
func (*UserMutation) AddField ¶
func (m *UserMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UserMutation) AddMentionedNoteIDs ¶
func (m *UserMutation) AddMentionedNoteIDs(ids ...uuid.UUID)
AddMentionedNoteIDs adds the "mentionedNotes" edge to the Note entity by ids.
func (*UserMutation) AddModeratedServerIDs ¶
func (m *UserMutation) AddModeratedServerIDs(ids ...uuid.UUID)
AddModeratedServerIDs adds the "moderatedServers" edge to the InstanceMetadata entity by ids.
func (*UserMutation) AddServerIDs ¶
func (m *UserMutation) AddServerIDs(ids ...uuid.UUID)
AddServerIDs adds the "servers" edge to the InstanceMetadata entity by ids.
func (*UserMutation) AddedEdges ¶
func (m *UserMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*UserMutation) AddedField ¶
func (m *UserMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UserMutation) AddedFields ¶
func (m *UserMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*UserMutation) AddedIDs ¶
func (m *UserMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*UserMutation) AdministeredServersCleared ¶
func (m *UserMutation) AdministeredServersCleared() bool
AdministeredServersCleared reports if the "administeredServers" edge to the InstanceMetadata entity was cleared.
func (*UserMutation) AdministeredServersIDs ¶
func (m *UserMutation) AdministeredServersIDs() (ids []uuid.UUID)
AdministeredServersIDs returns the "administeredServers" edge IDs in the mutation.
func (*UserMutation) AppendFields ¶
func (m *UserMutation) AppendFields(vf []versia.UserField)
AppendFields adds vf to the "fields" field.
func (*UserMutation) AppendedFields ¶
func (m *UserMutation) AppendedFields() ([]versia.UserField, bool)
AppendedFields returns the list of values that were appended to the "fields" field in this mutation.
func (*UserMutation) AuthoredNotesCleared ¶
func (m *UserMutation) AuthoredNotesCleared() bool
AuthoredNotesCleared reports if the "authoredNotes" edge to the Note entity was cleared.
func (*UserMutation) AuthoredNotesIDs ¶
func (m *UserMutation) AuthoredNotesIDs() (ids []uuid.UUID)
AuthoredNotesIDs returns the "authoredNotes" edge IDs in the mutation.
func (*UserMutation) AvatarImageCleared ¶
func (m *UserMutation) AvatarImageCleared() bool
AvatarImageCleared reports if the "avatarImage" edge to the Image entity was cleared.
func (*UserMutation) AvatarImageID ¶
func (m *UserMutation) AvatarImageID() (id int, exists bool)
AvatarImageID returns the "avatarImage" edge ID in the mutation.
func (*UserMutation) AvatarImageIDs ¶
func (m *UserMutation) AvatarImageIDs() (ids []int)
AvatarImageIDs returns the "avatarImage" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AvatarImageID instead. It exists only for internal usage by the builders.
func (*UserMutation) Biography ¶
func (m *UserMutation) Biography() (r string, exists bool)
Biography returns the value of the "biography" field in the mutation.
func (*UserMutation) BiographyCleared ¶
func (m *UserMutation) BiographyCleared() bool
BiographyCleared returns if the "biography" field was cleared in this mutation.
func (*UserMutation) ClearAdministeredServers ¶
func (m *UserMutation) ClearAdministeredServers()
ClearAdministeredServers clears the "administeredServers" edge to the InstanceMetadata entity.
func (*UserMutation) ClearAuthoredNotes ¶
func (m *UserMutation) ClearAuthoredNotes()
ClearAuthoredNotes clears the "authoredNotes" edge to the Note entity.
func (*UserMutation) ClearAvatarImage ¶
func (m *UserMutation) ClearAvatarImage()
ClearAvatarImage clears the "avatarImage" edge to the Image entity.
func (*UserMutation) ClearBiography ¶
func (m *UserMutation) ClearBiography()
ClearBiography clears the value of the "biography" field.
func (*UserMutation) ClearDisplayName ¶
func (m *UserMutation) ClearDisplayName()
ClearDisplayName clears the value of the "displayName" field.
func (*UserMutation) ClearEdge ¶
func (m *UserMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*UserMutation) ClearField ¶
func (m *UserMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ClearHeaderImage ¶
func (m *UserMutation) ClearHeaderImage()
ClearHeaderImage clears the "headerImage" edge to the Image entity.
func (*UserMutation) ClearMentionedNotes ¶
func (m *UserMutation) ClearMentionedNotes()
ClearMentionedNotes clears the "mentionedNotes" edge to the Note entity.
func (*UserMutation) ClearModeratedServers ¶
func (m *UserMutation) ClearModeratedServers()
ClearModeratedServers clears the "moderatedServers" edge to the InstanceMetadata entity.
func (*UserMutation) ClearPasswordHash ¶
func (m *UserMutation) ClearPasswordHash()
ClearPasswordHash clears the value of the "passwordHash" field.
func (*UserMutation) ClearPrivateKey ¶
func (m *UserMutation) ClearPrivateKey()
ClearPrivateKey clears the value of the "privateKey" field.
func (*UserMutation) ClearServers ¶
func (m *UserMutation) ClearServers()
ClearServers clears the "servers" edge to the InstanceMetadata entity.
func (*UserMutation) ClearedEdges ¶
func (m *UserMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*UserMutation) ClearedFields ¶
func (m *UserMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (UserMutation) Client ¶
func (m UserMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*UserMutation) CreatedAt ¶
func (m *UserMutation) CreatedAt() (r time.Time, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*UserMutation) DisplayName ¶
func (m *UserMutation) DisplayName() (r string, exists bool)
DisplayName returns the value of the "displayName" field in the mutation.
func (*UserMutation) DisplayNameCleared ¶
func (m *UserMutation) DisplayNameCleared() bool
DisplayNameCleared returns if the "displayName" field was cleared in this mutation.
func (*UserMutation) EdgeCleared ¶
func (m *UserMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*UserMutation) Extensions ¶
func (m *UserMutation) Extensions() (r versia.Extensions, exists bool)
Extensions returns the value of the "extensions" field in the mutation.
func (*UserMutation) Featured ¶
func (m *UserMutation) Featured() (r string, exists bool)
Featured returns the value of the "featured" field in the mutation.
func (*UserMutation) Field ¶
func (m *UserMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UserMutation) FieldCleared ¶
func (m *UserMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*UserMutation) Fields ¶
func (m *UserMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*UserMutation) Followers ¶
func (m *UserMutation) Followers() (r string, exists bool)
Followers returns the value of the "followers" field in the mutation.
func (*UserMutation) Following ¶
func (m *UserMutation) Following() (r string, exists bool)
Following returns the value of the "following" field in the mutation.
func (*UserMutation) GetFields ¶
func (m *UserMutation) GetFields() (r []versia.UserField, exists bool)
GetFields returns the value of the "fields" field in the mutation.
func (*UserMutation) HeaderImageCleared ¶
func (m *UserMutation) HeaderImageCleared() bool
HeaderImageCleared reports if the "headerImage" edge to the Image entity was cleared.
func (*UserMutation) HeaderImageID ¶
func (m *UserMutation) HeaderImageID() (id int, exists bool)
HeaderImageID returns the "headerImage" edge ID in the mutation.
func (*UserMutation) HeaderImageIDs ¶
func (m *UserMutation) HeaderImageIDs() (ids []int)
HeaderImageIDs returns the "headerImage" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use HeaderImageID instead. It exists only for internal usage by the builders.
func (*UserMutation) ID ¶
func (m *UserMutation) ID() (id uuid.UUID, exists bool)
ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
func (*UserMutation) IDs ¶
IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.
func (*UserMutation) Inbox ¶
func (m *UserMutation) Inbox() (r string, exists bool)
Inbox returns the value of the "inbox" field in the mutation.
func (*UserMutation) Indexable ¶
func (m *UserMutation) Indexable() (r bool, exists bool)
Indexable returns the value of the "indexable" field in the mutation.
func (*UserMutation) IsRemote ¶
func (m *UserMutation) IsRemote() (r bool, exists bool)
IsRemote returns the value of the "isRemote" field in the mutation.
func (*UserMutation) MentionedNotesCleared ¶
func (m *UserMutation) MentionedNotesCleared() bool
MentionedNotesCleared reports if the "mentionedNotes" edge to the Note entity was cleared.
func (*UserMutation) MentionedNotesIDs ¶
func (m *UserMutation) MentionedNotesIDs() (ids []uuid.UUID)
MentionedNotesIDs returns the "mentionedNotes" edge IDs in the mutation.
func (*UserMutation) ModeratedServersCleared ¶
func (m *UserMutation) ModeratedServersCleared() bool
ModeratedServersCleared reports if the "moderatedServers" edge to the InstanceMetadata entity was cleared.
func (*UserMutation) ModeratedServersIDs ¶
func (m *UserMutation) ModeratedServersIDs() (ids []uuid.UUID)
ModeratedServersIDs returns the "moderatedServers" edge IDs in the mutation.
func (*UserMutation) OldBiography ¶
func (m *UserMutation) OldBiography(ctx context.Context) (v *string, err error)
OldBiography returns the old "biography" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldCreatedAt ¶
OldCreatedAt returns the old "created_at" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldDisplayName ¶
func (m *UserMutation) OldDisplayName(ctx context.Context) (v *string, err error)
OldDisplayName returns the old "displayName" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldExtensions ¶
func (m *UserMutation) OldExtensions(ctx context.Context) (v versia.Extensions, err error)
OldExtensions returns the old "extensions" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldFeatured ¶
func (m *UserMutation) OldFeatured(ctx context.Context) (v string, err error)
OldFeatured returns the old "featured" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*UserMutation) OldFields ¶
OldFields returns the old "fields" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldFollowers ¶
func (m *UserMutation) OldFollowers(ctx context.Context) (v string, err error)
OldFollowers returns the old "followers" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldFollowing ¶
func (m *UserMutation) OldFollowing(ctx context.Context) (v string, err error)
OldFollowing returns the old "following" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldInbox ¶
func (m *UserMutation) OldInbox(ctx context.Context) (v string, err error)
OldInbox returns the old "inbox" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldIndexable ¶
func (m *UserMutation) OldIndexable(ctx context.Context) (v bool, err error)
OldIndexable returns the old "indexable" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldIsRemote ¶
func (m *UserMutation) OldIsRemote(ctx context.Context) (v bool, err error)
OldIsRemote returns the old "isRemote" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldOutbox ¶
func (m *UserMutation) OldOutbox(ctx context.Context) (v string, err error)
OldOutbox returns the old "outbox" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldPasswordHash ¶
func (m *UserMutation) OldPasswordHash(ctx context.Context) (v *[]byte, err error)
OldPasswordHash returns the old "passwordHash" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldPrivacyLevel ¶
func (m *UserMutation) OldPrivacyLevel(ctx context.Context) (v user.PrivacyLevel, err error)
OldPrivacyLevel returns the old "privacyLevel" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldPrivateKey ¶
func (m *UserMutation) OldPrivateKey(ctx context.Context) (v []byte, err error)
OldPrivateKey returns the old "privateKey" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldPublicKey ¶
func (m *UserMutation) OldPublicKey(ctx context.Context) (v []byte, err error)
OldPublicKey returns the old "publicKey" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldPublicKeyActor ¶
func (m *UserMutation) OldPublicKeyActor(ctx context.Context) (v string, err error)
OldPublicKeyActor returns the old "publicKeyActor" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldPublicKeyAlgorithm ¶
func (m *UserMutation) OldPublicKeyAlgorithm(ctx context.Context) (v string, err error)
OldPublicKeyAlgorithm returns the old "publicKeyAlgorithm" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldURI ¶
func (m *UserMutation) OldURI(ctx context.Context) (v string, err error)
OldURI returns the old "uri" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldUpdatedAt ¶
OldUpdatedAt returns the old "updated_at" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldUsername ¶
func (m *UserMutation) OldUsername(ctx context.Context) (v string, err error)
OldUsername returns the old "username" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) Outbox ¶
func (m *UserMutation) Outbox() (r string, exists bool)
Outbox returns the value of the "outbox" field in the mutation.
func (*UserMutation) PasswordHash ¶
func (m *UserMutation) PasswordHash() (r []byte, exists bool)
PasswordHash returns the value of the "passwordHash" field in the mutation.
func (*UserMutation) PasswordHashCleared ¶
func (m *UserMutation) PasswordHashCleared() bool
PasswordHashCleared returns if the "passwordHash" field was cleared in this mutation.
func (*UserMutation) PrivacyLevel ¶
func (m *UserMutation) PrivacyLevel() (r user.PrivacyLevel, exists bool)
PrivacyLevel returns the value of the "privacyLevel" field in the mutation.
func (*UserMutation) PrivateKey ¶
func (m *UserMutation) PrivateKey() (r []byte, exists bool)
PrivateKey returns the value of the "privateKey" field in the mutation.
func (*UserMutation) PrivateKeyCleared ¶
func (m *UserMutation) PrivateKeyCleared() bool
PrivateKeyCleared returns if the "privateKey" field was cleared in this mutation.
func (*UserMutation) PublicKey ¶
func (m *UserMutation) PublicKey() (r []byte, exists bool)
PublicKey returns the value of the "publicKey" field in the mutation.
func (*UserMutation) PublicKeyActor ¶
func (m *UserMutation) PublicKeyActor() (r string, exists bool)
PublicKeyActor returns the value of the "publicKeyActor" field in the mutation.
func (*UserMutation) PublicKeyAlgorithm ¶
func (m *UserMutation) PublicKeyAlgorithm() (r string, exists bool)
PublicKeyAlgorithm returns the value of the "publicKeyAlgorithm" field in the mutation.
func (*UserMutation) RemoveAdministeredServerIDs ¶
func (m *UserMutation) RemoveAdministeredServerIDs(ids ...uuid.UUID)
RemoveAdministeredServerIDs removes the "administeredServers" edge to the InstanceMetadata entity by IDs.
func (*UserMutation) RemoveAuthoredNoteIDs ¶
func (m *UserMutation) RemoveAuthoredNoteIDs(ids ...uuid.UUID)
RemoveAuthoredNoteIDs removes the "authoredNotes" edge to the Note entity by IDs.
func (*UserMutation) RemoveMentionedNoteIDs ¶
func (m *UserMutation) RemoveMentionedNoteIDs(ids ...uuid.UUID)
RemoveMentionedNoteIDs removes the "mentionedNotes" edge to the Note entity by IDs.
func (*UserMutation) RemoveModeratedServerIDs ¶
func (m *UserMutation) RemoveModeratedServerIDs(ids ...uuid.UUID)
RemoveModeratedServerIDs removes the "moderatedServers" edge to the InstanceMetadata entity by IDs.
func (*UserMutation) RemoveServerIDs ¶
func (m *UserMutation) RemoveServerIDs(ids ...uuid.UUID)
RemoveServerIDs removes the "servers" edge to the InstanceMetadata entity by IDs.
func (*UserMutation) RemovedAdministeredServersIDs ¶
func (m *UserMutation) RemovedAdministeredServersIDs() (ids []uuid.UUID)
RemovedAdministeredServers returns the removed IDs of the "administeredServers" edge to the InstanceMetadata entity.
func (*UserMutation) RemovedAuthoredNotesIDs ¶
func (m *UserMutation) RemovedAuthoredNotesIDs() (ids []uuid.UUID)
RemovedAuthoredNotes returns the removed IDs of the "authoredNotes" edge to the Note entity.
func (*UserMutation) RemovedEdges ¶
func (m *UserMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*UserMutation) RemovedIDs ¶
func (m *UserMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*UserMutation) RemovedMentionedNotesIDs ¶
func (m *UserMutation) RemovedMentionedNotesIDs() (ids []uuid.UUID)
RemovedMentionedNotes returns the removed IDs of the "mentionedNotes" edge to the Note entity.
func (*UserMutation) RemovedModeratedServersIDs ¶
func (m *UserMutation) RemovedModeratedServersIDs() (ids []uuid.UUID)
RemovedModeratedServers returns the removed IDs of the "moderatedServers" edge to the InstanceMetadata entity.
func (*UserMutation) RemovedServersIDs ¶
func (m *UserMutation) RemovedServersIDs() (ids []uuid.UUID)
RemovedServers returns the removed IDs of the "servers" edge to the InstanceMetadata entity.
func (*UserMutation) ResetAdministeredServers ¶
func (m *UserMutation) ResetAdministeredServers()
ResetAdministeredServers resets all changes to the "administeredServers" edge.
func (*UserMutation) ResetAuthoredNotes ¶
func (m *UserMutation) ResetAuthoredNotes()
ResetAuthoredNotes resets all changes to the "authoredNotes" edge.
func (*UserMutation) ResetAvatarImage ¶
func (m *UserMutation) ResetAvatarImage()
ResetAvatarImage resets all changes to the "avatarImage" edge.
func (*UserMutation) ResetBiography ¶
func (m *UserMutation) ResetBiography()
ResetBiography resets all changes to the "biography" field.
func (*UserMutation) ResetCreatedAt ¶
func (m *UserMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*UserMutation) ResetDisplayName ¶
func (m *UserMutation) ResetDisplayName()
ResetDisplayName resets all changes to the "displayName" field.
func (*UserMutation) ResetEdge ¶
func (m *UserMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*UserMutation) ResetExtensions ¶
func (m *UserMutation) ResetExtensions()
ResetExtensions resets all changes to the "extensions" field.
func (*UserMutation) ResetFeatured ¶
func (m *UserMutation) ResetFeatured()
ResetFeatured resets all changes to the "featured" field.
func (*UserMutation) ResetField ¶
func (m *UserMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ResetFields ¶
func (m *UserMutation) ResetFields()
ResetFields resets all changes to the "fields" field.
func (*UserMutation) ResetFollowers ¶
func (m *UserMutation) ResetFollowers()
ResetFollowers resets all changes to the "followers" field.
func (*UserMutation) ResetFollowing ¶
func (m *UserMutation) ResetFollowing()
ResetFollowing resets all changes to the "following" field.
func (*UserMutation) ResetHeaderImage ¶
func (m *UserMutation) ResetHeaderImage()
ResetHeaderImage resets all changes to the "headerImage" edge.
func (*UserMutation) ResetInbox ¶
func (m *UserMutation) ResetInbox()
ResetInbox resets all changes to the "inbox" field.
func (*UserMutation) ResetIndexable ¶
func (m *UserMutation) ResetIndexable()
ResetIndexable resets all changes to the "indexable" field.
func (*UserMutation) ResetIsRemote ¶
func (m *UserMutation) ResetIsRemote()
ResetIsRemote resets all changes to the "isRemote" field.
func (*UserMutation) ResetMentionedNotes ¶
func (m *UserMutation) ResetMentionedNotes()
ResetMentionedNotes resets all changes to the "mentionedNotes" edge.
func (*UserMutation) ResetModeratedServers ¶
func (m *UserMutation) ResetModeratedServers()
ResetModeratedServers resets all changes to the "moderatedServers" edge.
func (*UserMutation) ResetOutbox ¶
func (m *UserMutation) ResetOutbox()
ResetOutbox resets all changes to the "outbox" field.
func (*UserMutation) ResetPasswordHash ¶
func (m *UserMutation) ResetPasswordHash()
ResetPasswordHash resets all changes to the "passwordHash" field.
func (*UserMutation) ResetPrivacyLevel ¶
func (m *UserMutation) ResetPrivacyLevel()
ResetPrivacyLevel resets all changes to the "privacyLevel" field.
func (*UserMutation) ResetPrivateKey ¶
func (m *UserMutation) ResetPrivateKey()
ResetPrivateKey resets all changes to the "privateKey" field.
func (*UserMutation) ResetPublicKey ¶
func (m *UserMutation) ResetPublicKey()
ResetPublicKey resets all changes to the "publicKey" field.
func (*UserMutation) ResetPublicKeyActor ¶
func (m *UserMutation) ResetPublicKeyActor()
ResetPublicKeyActor resets all changes to the "publicKeyActor" field.
func (*UserMutation) ResetPublicKeyAlgorithm ¶
func (m *UserMutation) ResetPublicKeyAlgorithm()
ResetPublicKeyAlgorithm resets all changes to the "publicKeyAlgorithm" field.
func (*UserMutation) ResetServers ¶
func (m *UserMutation) ResetServers()
ResetServers resets all changes to the "servers" edge.
func (*UserMutation) ResetURI ¶
func (m *UserMutation) ResetURI()
ResetURI resets all changes to the "uri" field.
func (*UserMutation) ResetUpdatedAt ¶
func (m *UserMutation) ResetUpdatedAt()
ResetUpdatedAt resets all changes to the "updated_at" field.
func (*UserMutation) ResetUsername ¶
func (m *UserMutation) ResetUsername()
ResetUsername resets all changes to the "username" field.
func (*UserMutation) ServersCleared ¶
func (m *UserMutation) ServersCleared() bool
ServersCleared reports if the "servers" edge to the InstanceMetadata entity was cleared.
func (*UserMutation) ServersIDs ¶
func (m *UserMutation) ServersIDs() (ids []uuid.UUID)
ServersIDs returns the "servers" edge IDs in the mutation.
func (*UserMutation) SetAvatarImageID ¶
func (m *UserMutation) SetAvatarImageID(id int)
SetAvatarImageID sets the "avatarImage" edge to the Image entity by id.
func (*UserMutation) SetBiography ¶
func (m *UserMutation) SetBiography(s string)
SetBiography sets the "biography" field.
func (*UserMutation) SetCreatedAt ¶
func (m *UserMutation) SetCreatedAt(t time.Time)
SetCreatedAt sets the "created_at" field.
func (*UserMutation) SetDisplayName ¶
func (m *UserMutation) SetDisplayName(s string)
SetDisplayName sets the "displayName" field.
func (*UserMutation) SetExtensions ¶
func (m *UserMutation) SetExtensions(v versia.Extensions)
SetExtensions sets the "extensions" field.
func (*UserMutation) SetFeatured ¶
func (m *UserMutation) SetFeatured(s string)
SetFeatured sets the "featured" field.
func (*UserMutation) SetField ¶
func (m *UserMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UserMutation) SetFields ¶
func (m *UserMutation) SetFields(vf []versia.UserField)
SetFields sets the "fields" field.
func (*UserMutation) SetFollowers ¶
func (m *UserMutation) SetFollowers(s string)
SetFollowers sets the "followers" field.
func (*UserMutation) SetFollowing ¶
func (m *UserMutation) SetFollowing(s string)
SetFollowing sets the "following" field.
func (*UserMutation) SetHeaderImageID ¶
func (m *UserMutation) SetHeaderImageID(id int)
SetHeaderImageID sets the "headerImage" edge to the Image entity by id.
func (*UserMutation) SetID ¶
func (m *UserMutation) SetID(id uuid.UUID)
SetID sets the value of the id field. Note that this operation is only accepted on creation of User entities.
func (*UserMutation) SetInbox ¶
func (m *UserMutation) SetInbox(s string)
SetInbox sets the "inbox" field.
func (*UserMutation) SetIndexable ¶
func (m *UserMutation) SetIndexable(b bool)
SetIndexable sets the "indexable" field.
func (*UserMutation) SetIsRemote ¶
func (m *UserMutation) SetIsRemote(b bool)
SetIsRemote sets the "isRemote" field.
func (*UserMutation) SetOp ¶
func (m *UserMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*UserMutation) SetOutbox ¶
func (m *UserMutation) SetOutbox(s string)
SetOutbox sets the "outbox" field.
func (*UserMutation) SetPasswordHash ¶
func (m *UserMutation) SetPasswordHash(b []byte)
SetPasswordHash sets the "passwordHash" field.
func (*UserMutation) SetPrivacyLevel ¶
func (m *UserMutation) SetPrivacyLevel(ul user.PrivacyLevel)
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserMutation) SetPrivateKey ¶
func (m *UserMutation) SetPrivateKey(b []byte)
SetPrivateKey sets the "privateKey" field.
func (*UserMutation) SetPublicKey ¶
func (m *UserMutation) SetPublicKey(b []byte)
SetPublicKey sets the "publicKey" field.
func (*UserMutation) SetPublicKeyActor ¶
func (m *UserMutation) SetPublicKeyActor(s string)
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserMutation) SetPublicKeyAlgorithm ¶
func (m *UserMutation) SetPublicKeyAlgorithm(s string)
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserMutation) SetUpdatedAt ¶
func (m *UserMutation) SetUpdatedAt(t time.Time)
SetUpdatedAt sets the "updated_at" field.
func (*UserMutation) SetUsername ¶
func (m *UserMutation) SetUsername(s string)
SetUsername sets the "username" field.
func (UserMutation) Tx ¶
func (m UserMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*UserMutation) Type ¶
func (m *UserMutation) Type() string
Type returns the node type of this mutation (User).
func (*UserMutation) URI ¶
func (m *UserMutation) URI() (r string, exists bool)
URI returns the value of the "uri" field in the mutation.
func (*UserMutation) UpdatedAt ¶
func (m *UserMutation) UpdatedAt() (r time.Time, exists bool)
UpdatedAt returns the value of the "updated_at" field in the mutation.
func (*UserMutation) Username ¶
func (m *UserMutation) Username() (r string, exists bool)
Username returns the value of the "username" field in the mutation.
func (*UserMutation) Where ¶
func (m *UserMutation) Where(ps ...predicate.User)
Where appends a list predicates to the UserMutation builder.
func (*UserMutation) WhereP ¶
func (m *UserMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the UserMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type UserQuery ¶
type UserQuery struct {
// contains filtered or unexported fields
}
UserQuery is the builder for querying User entities.
func (*UserQuery) Aggregate ¶
func (uq *UserQuery) Aggregate(fns ...AggregateFunc) *UserSelect
Aggregate returns a UserSelect configured with the given aggregations.
func (*UserQuery) Clone ¶
Clone returns a duplicate of the UserQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*UserQuery) First ¶
First returns the first User entity from the query. Returns a *NotFoundError when no User was found.
func (*UserQuery) FirstID ¶
FirstID returns the first User ID from the query. Returns a *NotFoundError when no User ID was found.
func (*UserQuery) GroupBy ¶
func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { IsRemote bool `json:"isRemote,omitempty"` Count int `json:"count,omitempty"` } client.User.Query(). GroupBy(user.FieldIsRemote). Aggregate(ent.Count()). Scan(ctx, &v)
func (*UserQuery) Only ¶
Only returns a single User entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one User entity is found. Returns a *NotFoundError when no User entities are found.
func (*UserQuery) OnlyID ¶
OnlyID is like Only, but returns the only User ID in the query. Returns a *NotSingularError when more than one User ID is found. Returns a *NotFoundError when no entities are found.
func (*UserQuery) Order ¶
func (uq *UserQuery) Order(o ...user.OrderOption) *UserQuery
Order specifies how the records should be ordered.
func (*UserQuery) QueryAdministeredServers ¶
func (uq *UserQuery) QueryAdministeredServers() *InstanceMetadataQuery
QueryAdministeredServers chains the current query on the "administeredServers" edge.
func (*UserQuery) QueryAuthoredNotes ¶
QueryAuthoredNotes chains the current query on the "authoredNotes" edge.
func (*UserQuery) QueryAvatarImage ¶
func (uq *UserQuery) QueryAvatarImage() *ImageQuery
QueryAvatarImage chains the current query on the "avatarImage" edge.
func (*UserQuery) QueryHeaderImage ¶
func (uq *UserQuery) QueryHeaderImage() *ImageQuery
QueryHeaderImage chains the current query on the "headerImage" edge.
func (*UserQuery) QueryMentionedNotes ¶
QueryMentionedNotes chains the current query on the "mentionedNotes" edge.
func (*UserQuery) QueryModeratedServers ¶
func (uq *UserQuery) QueryModeratedServers() *InstanceMetadataQuery
QueryModeratedServers chains the current query on the "moderatedServers" edge.
func (*UserQuery) QueryServers ¶
func (uq *UserQuery) QueryServers() *InstanceMetadataQuery
QueryServers chains the current query on the "servers" edge.
func (*UserQuery) Select ¶
func (uq *UserQuery) Select(fields ...string) *UserSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { IsRemote bool `json:"isRemote,omitempty"` } client.User.Query(). Select(user.FieldIsRemote). Scan(ctx, &v)
func (*UserQuery) Unique ¶
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*UserQuery) WithAdministeredServers ¶
func (uq *UserQuery) WithAdministeredServers(opts ...func(*InstanceMetadataQuery)) *UserQuery
WithAdministeredServers tells the query-builder to eager-load the nodes that are connected to the "administeredServers" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithAuthoredNotes ¶
WithAuthoredNotes tells the query-builder to eager-load the nodes that are connected to the "authoredNotes" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithAvatarImage ¶
func (uq *UserQuery) WithAvatarImage(opts ...func(*ImageQuery)) *UserQuery
WithAvatarImage tells the query-builder to eager-load the nodes that are connected to the "avatarImage" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithHeaderImage ¶
func (uq *UserQuery) WithHeaderImage(opts ...func(*ImageQuery)) *UserQuery
WithHeaderImage tells the query-builder to eager-load the nodes that are connected to the "headerImage" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithMentionedNotes ¶
WithMentionedNotes tells the query-builder to eager-load the nodes that are connected to the "mentionedNotes" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithModeratedServers ¶
func (uq *UserQuery) WithModeratedServers(opts ...func(*InstanceMetadataQuery)) *UserQuery
WithModeratedServers tells the query-builder to eager-load the nodes that are connected to the "moderatedServers" edge. The optional arguments are used to configure the query builder of the edge.
func (*UserQuery) WithServers ¶
func (uq *UserQuery) WithServers(opts ...func(*InstanceMetadataQuery)) *UserQuery
WithServers tells the query-builder to eager-load the nodes that are connected to the "servers" edge. The optional arguments are used to configure the query builder of the edge.
type UserSelect ¶
type UserSelect struct { *UserQuery // contains filtered or unexported fields }
UserSelect is the builder for selecting fields of User entities.
func (*UserSelect) Aggregate ¶
func (us *UserSelect) Aggregate(fns ...AggregateFunc) *UserSelect
Aggregate adds the given aggregation functions to the selector query.
func (*UserSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*UserSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*UserSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*UserSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*UserSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*UserSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*UserSelect) Scan ¶
func (us *UserSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*UserSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type UserUpdate ¶
type UserUpdate struct {
// contains filtered or unexported fields
}
UserUpdate is the builder for updating User entities.
func (*UserUpdate) AddAdministeredServerIDs ¶
func (uu *UserUpdate) AddAdministeredServerIDs(ids ...uuid.UUID) *UserUpdate
AddAdministeredServerIDs adds the "administeredServers" edge to the InstanceMetadata entity by IDs.
func (*UserUpdate) AddAdministeredServers ¶
func (uu *UserUpdate) AddAdministeredServers(i ...*InstanceMetadata) *UserUpdate
AddAdministeredServers adds the "administeredServers" edges to the InstanceMetadata entity.
func (*UserUpdate) AddAuthoredNoteIDs ¶
func (uu *UserUpdate) AddAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdate
AddAuthoredNoteIDs adds the "authoredNotes" edge to the Note entity by IDs.
func (*UserUpdate) AddAuthoredNotes ¶
func (uu *UserUpdate) AddAuthoredNotes(n ...*Note) *UserUpdate
AddAuthoredNotes adds the "authoredNotes" edges to the Note entity.
func (*UserUpdate) AddMentionedNoteIDs ¶
func (uu *UserUpdate) AddMentionedNoteIDs(ids ...uuid.UUID) *UserUpdate
AddMentionedNoteIDs adds the "mentionedNotes" edge to the Note entity by IDs.
func (*UserUpdate) AddMentionedNotes ¶
func (uu *UserUpdate) AddMentionedNotes(n ...*Note) *UserUpdate
AddMentionedNotes adds the "mentionedNotes" edges to the Note entity.
func (*UserUpdate) AddModeratedServerIDs ¶
func (uu *UserUpdate) AddModeratedServerIDs(ids ...uuid.UUID) *UserUpdate
AddModeratedServerIDs adds the "moderatedServers" edge to the InstanceMetadata entity by IDs.
func (*UserUpdate) AddModeratedServers ¶
func (uu *UserUpdate) AddModeratedServers(i ...*InstanceMetadata) *UserUpdate
AddModeratedServers adds the "moderatedServers" edges to the InstanceMetadata entity.
func (*UserUpdate) AddServerIDs ¶
func (uu *UserUpdate) AddServerIDs(ids ...uuid.UUID) *UserUpdate
AddServerIDs adds the "servers" edge to the InstanceMetadata entity by IDs.
func (*UserUpdate) AddServers ¶
func (uu *UserUpdate) AddServers(i ...*InstanceMetadata) *UserUpdate
AddServers adds the "servers" edges to the InstanceMetadata entity.
func (*UserUpdate) AppendFields ¶
func (uu *UserUpdate) AppendFields(vf []versia.UserField) *UserUpdate
AppendFields appends vf to the "fields" field.
func (*UserUpdate) ClearAdministeredServers ¶
func (uu *UserUpdate) ClearAdministeredServers() *UserUpdate
ClearAdministeredServers clears all "administeredServers" edges to the InstanceMetadata entity.
func (*UserUpdate) ClearAuthoredNotes ¶
func (uu *UserUpdate) ClearAuthoredNotes() *UserUpdate
ClearAuthoredNotes clears all "authoredNotes" edges to the Note entity.
func (*UserUpdate) ClearAvatarImage ¶
func (uu *UserUpdate) ClearAvatarImage() *UserUpdate
ClearAvatarImage clears the "avatarImage" edge to the Image entity.
func (*UserUpdate) ClearBiography ¶
func (uu *UserUpdate) ClearBiography() *UserUpdate
ClearBiography clears the value of the "biography" field.
func (*UserUpdate) ClearDisplayName ¶
func (uu *UserUpdate) ClearDisplayName() *UserUpdate
ClearDisplayName clears the value of the "displayName" field.
func (*UserUpdate) ClearHeaderImage ¶
func (uu *UserUpdate) ClearHeaderImage() *UserUpdate
ClearHeaderImage clears the "headerImage" edge to the Image entity.
func (*UserUpdate) ClearMentionedNotes ¶
func (uu *UserUpdate) ClearMentionedNotes() *UserUpdate
ClearMentionedNotes clears all "mentionedNotes" edges to the Note entity.
func (*UserUpdate) ClearModeratedServers ¶
func (uu *UserUpdate) ClearModeratedServers() *UserUpdate
ClearModeratedServers clears all "moderatedServers" edges to the InstanceMetadata entity.
func (*UserUpdate) ClearPasswordHash ¶
func (uu *UserUpdate) ClearPasswordHash() *UserUpdate
ClearPasswordHash clears the value of the "passwordHash" field.
func (*UserUpdate) ClearPrivateKey ¶
func (uu *UserUpdate) ClearPrivateKey() *UserUpdate
ClearPrivateKey clears the value of the "privateKey" field.
func (*UserUpdate) ClearServers ¶
func (uu *UserUpdate) ClearServers() *UserUpdate
ClearServers clears all "servers" edges to the InstanceMetadata entity.
func (*UserUpdate) Exec ¶
func (uu *UserUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpdate) ExecX ¶
func (uu *UserUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpdate) Mutation ¶
func (uu *UserUpdate) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserUpdate) RemoveAdministeredServerIDs ¶
func (uu *UserUpdate) RemoveAdministeredServerIDs(ids ...uuid.UUID) *UserUpdate
RemoveAdministeredServerIDs removes the "administeredServers" edge to InstanceMetadata entities by IDs.
func (*UserUpdate) RemoveAdministeredServers ¶
func (uu *UserUpdate) RemoveAdministeredServers(i ...*InstanceMetadata) *UserUpdate
RemoveAdministeredServers removes "administeredServers" edges to InstanceMetadata entities.
func (*UserUpdate) RemoveAuthoredNoteIDs ¶
func (uu *UserUpdate) RemoveAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdate
RemoveAuthoredNoteIDs removes the "authoredNotes" edge to Note entities by IDs.
func (*UserUpdate) RemoveAuthoredNotes ¶
func (uu *UserUpdate) RemoveAuthoredNotes(n ...*Note) *UserUpdate
RemoveAuthoredNotes removes "authoredNotes" edges to Note entities.
func (*UserUpdate) RemoveMentionedNoteIDs ¶
func (uu *UserUpdate) RemoveMentionedNoteIDs(ids ...uuid.UUID) *UserUpdate
RemoveMentionedNoteIDs removes the "mentionedNotes" edge to Note entities by IDs.
func (*UserUpdate) RemoveMentionedNotes ¶
func (uu *UserUpdate) RemoveMentionedNotes(n ...*Note) *UserUpdate
RemoveMentionedNotes removes "mentionedNotes" edges to Note entities.
func (*UserUpdate) RemoveModeratedServerIDs ¶
func (uu *UserUpdate) RemoveModeratedServerIDs(ids ...uuid.UUID) *UserUpdate
RemoveModeratedServerIDs removes the "moderatedServers" edge to InstanceMetadata entities by IDs.
func (*UserUpdate) RemoveModeratedServers ¶
func (uu *UserUpdate) RemoveModeratedServers(i ...*InstanceMetadata) *UserUpdate
RemoveModeratedServers removes "moderatedServers" edges to InstanceMetadata entities.
func (*UserUpdate) RemoveServerIDs ¶
func (uu *UserUpdate) RemoveServerIDs(ids ...uuid.UUID) *UserUpdate
RemoveServerIDs removes the "servers" edge to InstanceMetadata entities by IDs.
func (*UserUpdate) RemoveServers ¶
func (uu *UserUpdate) RemoveServers(i ...*InstanceMetadata) *UserUpdate
RemoveServers removes "servers" edges to InstanceMetadata entities.
func (*UserUpdate) Save ¶
func (uu *UserUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*UserUpdate) SaveX ¶
func (uu *UserUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*UserUpdate) SetAvatarImage ¶
func (uu *UserUpdate) SetAvatarImage(i *Image) *UserUpdate
SetAvatarImage sets the "avatarImage" edge to the Image entity.
func (*UserUpdate) SetAvatarImageID ¶
func (uu *UserUpdate) SetAvatarImageID(id int) *UserUpdate
SetAvatarImageID sets the "avatarImage" edge to the Image entity by ID.
func (*UserUpdate) SetBiography ¶
func (uu *UserUpdate) SetBiography(s string) *UserUpdate
SetBiography sets the "biography" field.
func (*UserUpdate) SetDisplayName ¶
func (uu *UserUpdate) SetDisplayName(s string) *UserUpdate
SetDisplayName sets the "displayName" field.
func (*UserUpdate) SetExtensions ¶
func (uu *UserUpdate) SetExtensions(v versia.Extensions) *UserUpdate
SetExtensions sets the "extensions" field.
func (*UserUpdate) SetFeatured ¶
func (uu *UserUpdate) SetFeatured(s string) *UserUpdate
SetFeatured sets the "featured" field.
func (*UserUpdate) SetFields ¶
func (uu *UserUpdate) SetFields(vf []versia.UserField) *UserUpdate
SetFields sets the "fields" field.
func (*UserUpdate) SetFollowers ¶
func (uu *UserUpdate) SetFollowers(s string) *UserUpdate
SetFollowers sets the "followers" field.
func (*UserUpdate) SetFollowing ¶
func (uu *UserUpdate) SetFollowing(s string) *UserUpdate
SetFollowing sets the "following" field.
func (*UserUpdate) SetHeaderImage ¶
func (uu *UserUpdate) SetHeaderImage(i *Image) *UserUpdate
SetHeaderImage sets the "headerImage" edge to the Image entity.
func (*UserUpdate) SetHeaderImageID ¶
func (uu *UserUpdate) SetHeaderImageID(id int) *UserUpdate
SetHeaderImageID sets the "headerImage" edge to the Image entity by ID.
func (*UserUpdate) SetInbox ¶
func (uu *UserUpdate) SetInbox(s string) *UserUpdate
SetInbox sets the "inbox" field.
func (*UserUpdate) SetIndexable ¶
func (uu *UserUpdate) SetIndexable(b bool) *UserUpdate
SetIndexable sets the "indexable" field.
func (*UserUpdate) SetIsRemote ¶
func (uu *UserUpdate) SetIsRemote(b bool) *UserUpdate
SetIsRemote sets the "isRemote" field.
func (*UserUpdate) SetNillableAvatarImageID ¶
func (uu *UserUpdate) SetNillableAvatarImageID(id *int) *UserUpdate
SetNillableAvatarImageID sets the "avatarImage" edge to the Image entity by ID if the given value is not nil.
func (*UserUpdate) SetNillableBiography ¶
func (uu *UserUpdate) SetNillableBiography(s *string) *UserUpdate
SetNillableBiography sets the "biography" field if the given value is not nil.
func (*UserUpdate) SetNillableDisplayName ¶
func (uu *UserUpdate) SetNillableDisplayName(s *string) *UserUpdate
SetNillableDisplayName sets the "displayName" field if the given value is not nil.
func (*UserUpdate) SetNillableFeatured ¶
func (uu *UserUpdate) SetNillableFeatured(s *string) *UserUpdate
SetNillableFeatured sets the "featured" field if the given value is not nil.
func (*UserUpdate) SetNillableFollowers ¶
func (uu *UserUpdate) SetNillableFollowers(s *string) *UserUpdate
SetNillableFollowers sets the "followers" field if the given value is not nil.
func (*UserUpdate) SetNillableFollowing ¶
func (uu *UserUpdate) SetNillableFollowing(s *string) *UserUpdate
SetNillableFollowing sets the "following" field if the given value is not nil.
func (*UserUpdate) SetNillableHeaderImageID ¶
func (uu *UserUpdate) SetNillableHeaderImageID(id *int) *UserUpdate
SetNillableHeaderImageID sets the "headerImage" edge to the Image entity by ID if the given value is not nil.
func (*UserUpdate) SetNillableInbox ¶
func (uu *UserUpdate) SetNillableInbox(s *string) *UserUpdate
SetNillableInbox sets the "inbox" field if the given value is not nil.
func (*UserUpdate) SetNillableIndexable ¶
func (uu *UserUpdate) SetNillableIndexable(b *bool) *UserUpdate
SetNillableIndexable sets the "indexable" field if the given value is not nil.
func (*UserUpdate) SetNillableIsRemote ¶
func (uu *UserUpdate) SetNillableIsRemote(b *bool) *UserUpdate
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*UserUpdate) SetNillableOutbox ¶
func (uu *UserUpdate) SetNillableOutbox(s *string) *UserUpdate
SetNillableOutbox sets the "outbox" field if the given value is not nil.
func (*UserUpdate) SetNillablePrivacyLevel ¶
func (uu *UserUpdate) SetNillablePrivacyLevel(ul *user.PrivacyLevel) *UserUpdate
SetNillablePrivacyLevel sets the "privacyLevel" field if the given value is not nil.
func (*UserUpdate) SetNillablePublicKeyActor ¶
func (uu *UserUpdate) SetNillablePublicKeyActor(s *string) *UserUpdate
SetNillablePublicKeyActor sets the "publicKeyActor" field if the given value is not nil.
func (*UserUpdate) SetNillablePublicKeyAlgorithm ¶
func (uu *UserUpdate) SetNillablePublicKeyAlgorithm(s *string) *UserUpdate
SetNillablePublicKeyAlgorithm sets the "publicKeyAlgorithm" field if the given value is not nil.
func (*UserUpdate) SetNillableURI ¶
func (uu *UserUpdate) SetNillableURI(s *string) *UserUpdate
SetNillableURI sets the "uri" field if the given value is not nil.
func (*UserUpdate) SetNillableUsername ¶
func (uu *UserUpdate) SetNillableUsername(s *string) *UserUpdate
SetNillableUsername sets the "username" field if the given value is not nil.
func (*UserUpdate) SetOutbox ¶
func (uu *UserUpdate) SetOutbox(s string) *UserUpdate
SetOutbox sets the "outbox" field.
func (*UserUpdate) SetPasswordHash ¶
func (uu *UserUpdate) SetPasswordHash(b []byte) *UserUpdate
SetPasswordHash sets the "passwordHash" field.
func (*UserUpdate) SetPrivacyLevel ¶
func (uu *UserUpdate) SetPrivacyLevel(ul user.PrivacyLevel) *UserUpdate
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserUpdate) SetPrivateKey ¶
func (uu *UserUpdate) SetPrivateKey(b []byte) *UserUpdate
SetPrivateKey sets the "privateKey" field.
func (*UserUpdate) SetPublicKey ¶
func (uu *UserUpdate) SetPublicKey(b []byte) *UserUpdate
SetPublicKey sets the "publicKey" field.
func (*UserUpdate) SetPublicKeyActor ¶
func (uu *UserUpdate) SetPublicKeyActor(s string) *UserUpdate
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserUpdate) SetPublicKeyAlgorithm ¶
func (uu *UserUpdate) SetPublicKeyAlgorithm(s string) *UserUpdate
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserUpdate) SetURI ¶
func (uu *UserUpdate) SetURI(s string) *UserUpdate
SetURI sets the "uri" field.
func (*UserUpdate) SetUpdatedAt ¶
func (uu *UserUpdate) SetUpdatedAt(t time.Time) *UserUpdate
SetUpdatedAt sets the "updated_at" field.
func (*UserUpdate) SetUsername ¶
func (uu *UserUpdate) SetUsername(s string) *UserUpdate
SetUsername sets the "username" field.
func (*UserUpdate) Where ¶
func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
Where appends a list predicates to the UserUpdate builder.
type UserUpdateOne ¶
type UserUpdateOne struct {
// contains filtered or unexported fields
}
UserUpdateOne is the builder for updating a single User entity.
func (*UserUpdateOne) AddAdministeredServerIDs ¶
func (uuo *UserUpdateOne) AddAdministeredServerIDs(ids ...uuid.UUID) *UserUpdateOne
AddAdministeredServerIDs adds the "administeredServers" edge to the InstanceMetadata entity by IDs.
func (*UserUpdateOne) AddAdministeredServers ¶
func (uuo *UserUpdateOne) AddAdministeredServers(i ...*InstanceMetadata) *UserUpdateOne
AddAdministeredServers adds the "administeredServers" edges to the InstanceMetadata entity.
func (*UserUpdateOne) AddAuthoredNoteIDs ¶
func (uuo *UserUpdateOne) AddAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdateOne
AddAuthoredNoteIDs adds the "authoredNotes" edge to the Note entity by IDs.
func (*UserUpdateOne) AddAuthoredNotes ¶
func (uuo *UserUpdateOne) AddAuthoredNotes(n ...*Note) *UserUpdateOne
AddAuthoredNotes adds the "authoredNotes" edges to the Note entity.
func (*UserUpdateOne) AddMentionedNoteIDs ¶
func (uuo *UserUpdateOne) AddMentionedNoteIDs(ids ...uuid.UUID) *UserUpdateOne
AddMentionedNoteIDs adds the "mentionedNotes" edge to the Note entity by IDs.
func (*UserUpdateOne) AddMentionedNotes ¶
func (uuo *UserUpdateOne) AddMentionedNotes(n ...*Note) *UserUpdateOne
AddMentionedNotes adds the "mentionedNotes" edges to the Note entity.
func (*UserUpdateOne) AddModeratedServerIDs ¶
func (uuo *UserUpdateOne) AddModeratedServerIDs(ids ...uuid.UUID) *UserUpdateOne
AddModeratedServerIDs adds the "moderatedServers" edge to the InstanceMetadata entity by IDs.
func (*UserUpdateOne) AddModeratedServers ¶
func (uuo *UserUpdateOne) AddModeratedServers(i ...*InstanceMetadata) *UserUpdateOne
AddModeratedServers adds the "moderatedServers" edges to the InstanceMetadata entity.
func (*UserUpdateOne) AddServerIDs ¶
func (uuo *UserUpdateOne) AddServerIDs(ids ...uuid.UUID) *UserUpdateOne
AddServerIDs adds the "servers" edge to the InstanceMetadata entity by IDs.
func (*UserUpdateOne) AddServers ¶
func (uuo *UserUpdateOne) AddServers(i ...*InstanceMetadata) *UserUpdateOne
AddServers adds the "servers" edges to the InstanceMetadata entity.
func (*UserUpdateOne) AppendFields ¶
func (uuo *UserUpdateOne) AppendFields(vf []versia.UserField) *UserUpdateOne
AppendFields appends vf to the "fields" field.
func (*UserUpdateOne) ClearAdministeredServers ¶
func (uuo *UserUpdateOne) ClearAdministeredServers() *UserUpdateOne
ClearAdministeredServers clears all "administeredServers" edges to the InstanceMetadata entity.
func (*UserUpdateOne) ClearAuthoredNotes ¶
func (uuo *UserUpdateOne) ClearAuthoredNotes() *UserUpdateOne
ClearAuthoredNotes clears all "authoredNotes" edges to the Note entity.
func (*UserUpdateOne) ClearAvatarImage ¶
func (uuo *UserUpdateOne) ClearAvatarImage() *UserUpdateOne
ClearAvatarImage clears the "avatarImage" edge to the Image entity.
func (*UserUpdateOne) ClearBiography ¶
func (uuo *UserUpdateOne) ClearBiography() *UserUpdateOne
ClearBiography clears the value of the "biography" field.
func (*UserUpdateOne) ClearDisplayName ¶
func (uuo *UserUpdateOne) ClearDisplayName() *UserUpdateOne
ClearDisplayName clears the value of the "displayName" field.
func (*UserUpdateOne) ClearHeaderImage ¶
func (uuo *UserUpdateOne) ClearHeaderImage() *UserUpdateOne
ClearHeaderImage clears the "headerImage" edge to the Image entity.
func (*UserUpdateOne) ClearMentionedNotes ¶
func (uuo *UserUpdateOne) ClearMentionedNotes() *UserUpdateOne
ClearMentionedNotes clears all "mentionedNotes" edges to the Note entity.
func (*UserUpdateOne) ClearModeratedServers ¶
func (uuo *UserUpdateOne) ClearModeratedServers() *UserUpdateOne
ClearModeratedServers clears all "moderatedServers" edges to the InstanceMetadata entity.
func (*UserUpdateOne) ClearPasswordHash ¶
func (uuo *UserUpdateOne) ClearPasswordHash() *UserUpdateOne
ClearPasswordHash clears the value of the "passwordHash" field.
func (*UserUpdateOne) ClearPrivateKey ¶
func (uuo *UserUpdateOne) ClearPrivateKey() *UserUpdateOne
ClearPrivateKey clears the value of the "privateKey" field.
func (*UserUpdateOne) ClearServers ¶
func (uuo *UserUpdateOne) ClearServers() *UserUpdateOne
ClearServers clears all "servers" edges to the InstanceMetadata entity.
func (*UserUpdateOne) Exec ¶
func (uuo *UserUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*UserUpdateOne) ExecX ¶
func (uuo *UserUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpdateOne) Mutation ¶
func (uuo *UserUpdateOne) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserUpdateOne) RemoveAdministeredServerIDs ¶
func (uuo *UserUpdateOne) RemoveAdministeredServerIDs(ids ...uuid.UUID) *UserUpdateOne
RemoveAdministeredServerIDs removes the "administeredServers" edge to InstanceMetadata entities by IDs.
func (*UserUpdateOne) RemoveAdministeredServers ¶
func (uuo *UserUpdateOne) RemoveAdministeredServers(i ...*InstanceMetadata) *UserUpdateOne
RemoveAdministeredServers removes "administeredServers" edges to InstanceMetadata entities.
func (*UserUpdateOne) RemoveAuthoredNoteIDs ¶
func (uuo *UserUpdateOne) RemoveAuthoredNoteIDs(ids ...uuid.UUID) *UserUpdateOne
RemoveAuthoredNoteIDs removes the "authoredNotes" edge to Note entities by IDs.
func (*UserUpdateOne) RemoveAuthoredNotes ¶
func (uuo *UserUpdateOne) RemoveAuthoredNotes(n ...*Note) *UserUpdateOne
RemoveAuthoredNotes removes "authoredNotes" edges to Note entities.
func (*UserUpdateOne) RemoveMentionedNoteIDs ¶
func (uuo *UserUpdateOne) RemoveMentionedNoteIDs(ids ...uuid.UUID) *UserUpdateOne
RemoveMentionedNoteIDs removes the "mentionedNotes" edge to Note entities by IDs.
func (*UserUpdateOne) RemoveMentionedNotes ¶
func (uuo *UserUpdateOne) RemoveMentionedNotes(n ...*Note) *UserUpdateOne
RemoveMentionedNotes removes "mentionedNotes" edges to Note entities.
func (*UserUpdateOne) RemoveModeratedServerIDs ¶
func (uuo *UserUpdateOne) RemoveModeratedServerIDs(ids ...uuid.UUID) *UserUpdateOne
RemoveModeratedServerIDs removes the "moderatedServers" edge to InstanceMetadata entities by IDs.
func (*UserUpdateOne) RemoveModeratedServers ¶
func (uuo *UserUpdateOne) RemoveModeratedServers(i ...*InstanceMetadata) *UserUpdateOne
RemoveModeratedServers removes "moderatedServers" edges to InstanceMetadata entities.
func (*UserUpdateOne) RemoveServerIDs ¶
func (uuo *UserUpdateOne) RemoveServerIDs(ids ...uuid.UUID) *UserUpdateOne
RemoveServerIDs removes the "servers" edge to InstanceMetadata entities by IDs.
func (*UserUpdateOne) RemoveServers ¶
func (uuo *UserUpdateOne) RemoveServers(i ...*InstanceMetadata) *UserUpdateOne
RemoveServers removes "servers" edges to InstanceMetadata entities.
func (*UserUpdateOne) Save ¶
func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
Save executes the query and returns the updated User entity.
func (*UserUpdateOne) SaveX ¶
func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
SaveX is like Save, but panics if an error occurs.
func (*UserUpdateOne) Select ¶
func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*UserUpdateOne) SetAvatarImage ¶
func (uuo *UserUpdateOne) SetAvatarImage(i *Image) *UserUpdateOne
SetAvatarImage sets the "avatarImage" edge to the Image entity.
func (*UserUpdateOne) SetAvatarImageID ¶
func (uuo *UserUpdateOne) SetAvatarImageID(id int) *UserUpdateOne
SetAvatarImageID sets the "avatarImage" edge to the Image entity by ID.
func (*UserUpdateOne) SetBiography ¶
func (uuo *UserUpdateOne) SetBiography(s string) *UserUpdateOne
SetBiography sets the "biography" field.
func (*UserUpdateOne) SetDisplayName ¶
func (uuo *UserUpdateOne) SetDisplayName(s string) *UserUpdateOne
SetDisplayName sets the "displayName" field.
func (*UserUpdateOne) SetExtensions ¶
func (uuo *UserUpdateOne) SetExtensions(v versia.Extensions) *UserUpdateOne
SetExtensions sets the "extensions" field.
func (*UserUpdateOne) SetFeatured ¶
func (uuo *UserUpdateOne) SetFeatured(s string) *UserUpdateOne
SetFeatured sets the "featured" field.
func (*UserUpdateOne) SetFields ¶
func (uuo *UserUpdateOne) SetFields(vf []versia.UserField) *UserUpdateOne
SetFields sets the "fields" field.
func (*UserUpdateOne) SetFollowers ¶
func (uuo *UserUpdateOne) SetFollowers(s string) *UserUpdateOne
SetFollowers sets the "followers" field.
func (*UserUpdateOne) SetFollowing ¶
func (uuo *UserUpdateOne) SetFollowing(s string) *UserUpdateOne
SetFollowing sets the "following" field.
func (*UserUpdateOne) SetHeaderImage ¶
func (uuo *UserUpdateOne) SetHeaderImage(i *Image) *UserUpdateOne
SetHeaderImage sets the "headerImage" edge to the Image entity.
func (*UserUpdateOne) SetHeaderImageID ¶
func (uuo *UserUpdateOne) SetHeaderImageID(id int) *UserUpdateOne
SetHeaderImageID sets the "headerImage" edge to the Image entity by ID.
func (*UserUpdateOne) SetInbox ¶
func (uuo *UserUpdateOne) SetInbox(s string) *UserUpdateOne
SetInbox sets the "inbox" field.
func (*UserUpdateOne) SetIndexable ¶
func (uuo *UserUpdateOne) SetIndexable(b bool) *UserUpdateOne
SetIndexable sets the "indexable" field.
func (*UserUpdateOne) SetIsRemote ¶
func (uuo *UserUpdateOne) SetIsRemote(b bool) *UserUpdateOne
SetIsRemote sets the "isRemote" field.
func (*UserUpdateOne) SetNillableAvatarImageID ¶
func (uuo *UserUpdateOne) SetNillableAvatarImageID(id *int) *UserUpdateOne
SetNillableAvatarImageID sets the "avatarImage" edge to the Image entity by ID if the given value is not nil.
func (*UserUpdateOne) SetNillableBiography ¶
func (uuo *UserUpdateOne) SetNillableBiography(s *string) *UserUpdateOne
SetNillableBiography sets the "biography" field if the given value is not nil.
func (*UserUpdateOne) SetNillableDisplayName ¶
func (uuo *UserUpdateOne) SetNillableDisplayName(s *string) *UserUpdateOne
SetNillableDisplayName sets the "displayName" field if the given value is not nil.
func (*UserUpdateOne) SetNillableFeatured ¶
func (uuo *UserUpdateOne) SetNillableFeatured(s *string) *UserUpdateOne
SetNillableFeatured sets the "featured" field if the given value is not nil.
func (*UserUpdateOne) SetNillableFollowers ¶
func (uuo *UserUpdateOne) SetNillableFollowers(s *string) *UserUpdateOne
SetNillableFollowers sets the "followers" field if the given value is not nil.
func (*UserUpdateOne) SetNillableFollowing ¶
func (uuo *UserUpdateOne) SetNillableFollowing(s *string) *UserUpdateOne
SetNillableFollowing sets the "following" field if the given value is not nil.
func (*UserUpdateOne) SetNillableHeaderImageID ¶
func (uuo *UserUpdateOne) SetNillableHeaderImageID(id *int) *UserUpdateOne
SetNillableHeaderImageID sets the "headerImage" edge to the Image entity by ID if the given value is not nil.
func (*UserUpdateOne) SetNillableInbox ¶
func (uuo *UserUpdateOne) SetNillableInbox(s *string) *UserUpdateOne
SetNillableInbox sets the "inbox" field if the given value is not nil.
func (*UserUpdateOne) SetNillableIndexable ¶
func (uuo *UserUpdateOne) SetNillableIndexable(b *bool) *UserUpdateOne
SetNillableIndexable sets the "indexable" field if the given value is not nil.
func (*UserUpdateOne) SetNillableIsRemote ¶
func (uuo *UserUpdateOne) SetNillableIsRemote(b *bool) *UserUpdateOne
SetNillableIsRemote sets the "isRemote" field if the given value is not nil.
func (*UserUpdateOne) SetNillableOutbox ¶
func (uuo *UserUpdateOne) SetNillableOutbox(s *string) *UserUpdateOne
SetNillableOutbox sets the "outbox" field if the given value is not nil.
func (*UserUpdateOne) SetNillablePrivacyLevel ¶
func (uuo *UserUpdateOne) SetNillablePrivacyLevel(ul *user.PrivacyLevel) *UserUpdateOne
SetNillablePrivacyLevel sets the "privacyLevel" field if the given value is not nil.
func (*UserUpdateOne) SetNillablePublicKeyActor ¶
func (uuo *UserUpdateOne) SetNillablePublicKeyActor(s *string) *UserUpdateOne
SetNillablePublicKeyActor sets the "publicKeyActor" field if the given value is not nil.
func (*UserUpdateOne) SetNillablePublicKeyAlgorithm ¶
func (uuo *UserUpdateOne) SetNillablePublicKeyAlgorithm(s *string) *UserUpdateOne
SetNillablePublicKeyAlgorithm sets the "publicKeyAlgorithm" field if the given value is not nil.
func (*UserUpdateOne) SetNillableURI ¶
func (uuo *UserUpdateOne) SetNillableURI(s *string) *UserUpdateOne
SetNillableURI sets the "uri" field if the given value is not nil.
func (*UserUpdateOne) SetNillableUsername ¶
func (uuo *UserUpdateOne) SetNillableUsername(s *string) *UserUpdateOne
SetNillableUsername sets the "username" field if the given value is not nil.
func (*UserUpdateOne) SetOutbox ¶
func (uuo *UserUpdateOne) SetOutbox(s string) *UserUpdateOne
SetOutbox sets the "outbox" field.
func (*UserUpdateOne) SetPasswordHash ¶
func (uuo *UserUpdateOne) SetPasswordHash(b []byte) *UserUpdateOne
SetPasswordHash sets the "passwordHash" field.
func (*UserUpdateOne) SetPrivacyLevel ¶
func (uuo *UserUpdateOne) SetPrivacyLevel(ul user.PrivacyLevel) *UserUpdateOne
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserUpdateOne) SetPrivateKey ¶
func (uuo *UserUpdateOne) SetPrivateKey(b []byte) *UserUpdateOne
SetPrivateKey sets the "privateKey" field.
func (*UserUpdateOne) SetPublicKey ¶
func (uuo *UserUpdateOne) SetPublicKey(b []byte) *UserUpdateOne
SetPublicKey sets the "publicKey" field.
func (*UserUpdateOne) SetPublicKeyActor ¶
func (uuo *UserUpdateOne) SetPublicKeyActor(s string) *UserUpdateOne
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserUpdateOne) SetPublicKeyAlgorithm ¶
func (uuo *UserUpdateOne) SetPublicKeyAlgorithm(s string) *UserUpdateOne
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserUpdateOne) SetURI ¶
func (uuo *UserUpdateOne) SetURI(s string) *UserUpdateOne
SetURI sets the "uri" field.
func (*UserUpdateOne) SetUpdatedAt ¶
func (uuo *UserUpdateOne) SetUpdatedAt(t time.Time) *UserUpdateOne
SetUpdatedAt sets the "updated_at" field.
func (*UserUpdateOne) SetUsername ¶
func (uuo *UserUpdateOne) SetUsername(s string) *UserUpdateOne
SetUsername sets the "username" field.
func (*UserUpdateOne) Where ¶
func (uuo *UserUpdateOne) Where(ps ...predicate.User) *UserUpdateOne
Where appends a list predicates to the UserUpdate builder.
type UserUpsert ¶
UserUpsert is the "OnConflict" setter.
func (*UserUpsert) ClearBiography ¶
func (u *UserUpsert) ClearBiography() *UserUpsert
ClearBiography clears the value of the "biography" field.
func (*UserUpsert) ClearDisplayName ¶
func (u *UserUpsert) ClearDisplayName() *UserUpsert
ClearDisplayName clears the value of the "displayName" field.
func (*UserUpsert) ClearPasswordHash ¶
func (u *UserUpsert) ClearPasswordHash() *UserUpsert
ClearPasswordHash clears the value of the "passwordHash" field.
func (*UserUpsert) ClearPrivateKey ¶
func (u *UserUpsert) ClearPrivateKey() *UserUpsert
ClearPrivateKey clears the value of the "privateKey" field.
func (*UserUpsert) SetBiography ¶
func (u *UserUpsert) SetBiography(v string) *UserUpsert
SetBiography sets the "biography" field.
func (*UserUpsert) SetDisplayName ¶
func (u *UserUpsert) SetDisplayName(v string) *UserUpsert
SetDisplayName sets the "displayName" field.
func (*UserUpsert) SetExtensions ¶
func (u *UserUpsert) SetExtensions(v versia.Extensions) *UserUpsert
SetExtensions sets the "extensions" field.
func (*UserUpsert) SetFeatured ¶
func (u *UserUpsert) SetFeatured(v string) *UserUpsert
SetFeatured sets the "featured" field.
func (*UserUpsert) SetFields ¶
func (u *UserUpsert) SetFields(v []versia.UserField) *UserUpsert
SetFields sets the "fields" field.
func (*UserUpsert) SetFollowers ¶
func (u *UserUpsert) SetFollowers(v string) *UserUpsert
SetFollowers sets the "followers" field.
func (*UserUpsert) SetFollowing ¶
func (u *UserUpsert) SetFollowing(v string) *UserUpsert
SetFollowing sets the "following" field.
func (*UserUpsert) SetInbox ¶
func (u *UserUpsert) SetInbox(v string) *UserUpsert
SetInbox sets the "inbox" field.
func (*UserUpsert) SetIndexable ¶
func (u *UserUpsert) SetIndexable(v bool) *UserUpsert
SetIndexable sets the "indexable" field.
func (*UserUpsert) SetIsRemote ¶
func (u *UserUpsert) SetIsRemote(v bool) *UserUpsert
SetIsRemote sets the "isRemote" field.
func (*UserUpsert) SetOutbox ¶
func (u *UserUpsert) SetOutbox(v string) *UserUpsert
SetOutbox sets the "outbox" field.
func (*UserUpsert) SetPasswordHash ¶
func (u *UserUpsert) SetPasswordHash(v []byte) *UserUpsert
SetPasswordHash sets the "passwordHash" field.
func (*UserUpsert) SetPrivacyLevel ¶
func (u *UserUpsert) SetPrivacyLevel(v user.PrivacyLevel) *UserUpsert
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserUpsert) SetPrivateKey ¶
func (u *UserUpsert) SetPrivateKey(v []byte) *UserUpsert
SetPrivateKey sets the "privateKey" field.
func (*UserUpsert) SetPublicKey ¶
func (u *UserUpsert) SetPublicKey(v []byte) *UserUpsert
SetPublicKey sets the "publicKey" field.
func (*UserUpsert) SetPublicKeyActor ¶
func (u *UserUpsert) SetPublicKeyActor(v string) *UserUpsert
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserUpsert) SetPublicKeyAlgorithm ¶
func (u *UserUpsert) SetPublicKeyAlgorithm(v string) *UserUpsert
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserUpsert) SetURI ¶
func (u *UserUpsert) SetURI(v string) *UserUpsert
SetURI sets the "uri" field.
func (*UserUpsert) SetUpdatedAt ¶
func (u *UserUpsert) SetUpdatedAt(v time.Time) *UserUpsert
SetUpdatedAt sets the "updated_at" field.
func (*UserUpsert) SetUsername ¶
func (u *UserUpsert) SetUsername(v string) *UserUpsert
SetUsername sets the "username" field.
func (*UserUpsert) UpdateBiography ¶
func (u *UserUpsert) UpdateBiography() *UserUpsert
UpdateBiography sets the "biography" field to the value that was provided on create.
func (*UserUpsert) UpdateDisplayName ¶
func (u *UserUpsert) UpdateDisplayName() *UserUpsert
UpdateDisplayName sets the "displayName" field to the value that was provided on create.
func (*UserUpsert) UpdateExtensions ¶
func (u *UserUpsert) UpdateExtensions() *UserUpsert
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*UserUpsert) UpdateFeatured ¶
func (u *UserUpsert) UpdateFeatured() *UserUpsert
UpdateFeatured sets the "featured" field to the value that was provided on create.
func (*UserUpsert) UpdateFields ¶
func (u *UserUpsert) UpdateFields() *UserUpsert
UpdateFields sets the "fields" field to the value that was provided on create.
func (*UserUpsert) UpdateFollowers ¶
func (u *UserUpsert) UpdateFollowers() *UserUpsert
UpdateFollowers sets the "followers" field to the value that was provided on create.
func (*UserUpsert) UpdateFollowing ¶
func (u *UserUpsert) UpdateFollowing() *UserUpsert
UpdateFollowing sets the "following" field to the value that was provided on create.
func (*UserUpsert) UpdateInbox ¶
func (u *UserUpsert) UpdateInbox() *UserUpsert
UpdateInbox sets the "inbox" field to the value that was provided on create.
func (*UserUpsert) UpdateIndexable ¶
func (u *UserUpsert) UpdateIndexable() *UserUpsert
UpdateIndexable sets the "indexable" field to the value that was provided on create.
func (*UserUpsert) UpdateIsRemote ¶
func (u *UserUpsert) UpdateIsRemote() *UserUpsert
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*UserUpsert) UpdateOutbox ¶
func (u *UserUpsert) UpdateOutbox() *UserUpsert
UpdateOutbox sets the "outbox" field to the value that was provided on create.
func (*UserUpsert) UpdatePasswordHash ¶
func (u *UserUpsert) UpdatePasswordHash() *UserUpsert
UpdatePasswordHash sets the "passwordHash" field to the value that was provided on create.
func (*UserUpsert) UpdatePrivacyLevel ¶
func (u *UserUpsert) UpdatePrivacyLevel() *UserUpsert
UpdatePrivacyLevel sets the "privacyLevel" field to the value that was provided on create.
func (*UserUpsert) UpdatePrivateKey ¶
func (u *UserUpsert) UpdatePrivateKey() *UserUpsert
UpdatePrivateKey sets the "privateKey" field to the value that was provided on create.
func (*UserUpsert) UpdatePublicKey ¶
func (u *UserUpsert) UpdatePublicKey() *UserUpsert
UpdatePublicKey sets the "publicKey" field to the value that was provided on create.
func (*UserUpsert) UpdatePublicKeyActor ¶
func (u *UserUpsert) UpdatePublicKeyActor() *UserUpsert
UpdatePublicKeyActor sets the "publicKeyActor" field to the value that was provided on create.
func (*UserUpsert) UpdatePublicKeyAlgorithm ¶
func (u *UserUpsert) UpdatePublicKeyAlgorithm() *UserUpsert
UpdatePublicKeyAlgorithm sets the "publicKeyAlgorithm" field to the value that was provided on create.
func (*UserUpsert) UpdateURI ¶
func (u *UserUpsert) UpdateURI() *UserUpsert
UpdateURI sets the "uri" field to the value that was provided on create.
func (*UserUpsert) UpdateUpdatedAt ¶
func (u *UserUpsert) UpdateUpdatedAt() *UserUpsert
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*UserUpsert) UpdateUsername ¶
func (u *UserUpsert) UpdateUsername() *UserUpsert
UpdateUsername sets the "username" field to the value that was provided on create.
type UserUpsertBulk ¶
type UserUpsertBulk struct {
// contains filtered or unexported fields
}
UserUpsertBulk is the builder for "upsert"-ing a bulk of User nodes.
func (*UserUpsertBulk) ClearBiography ¶
func (u *UserUpsertBulk) ClearBiography() *UserUpsertBulk
ClearBiography clears the value of the "biography" field.
func (*UserUpsertBulk) ClearDisplayName ¶
func (u *UserUpsertBulk) ClearDisplayName() *UserUpsertBulk
ClearDisplayName clears the value of the "displayName" field.
func (*UserUpsertBulk) ClearPasswordHash ¶
func (u *UserUpsertBulk) ClearPasswordHash() *UserUpsertBulk
ClearPasswordHash clears the value of the "passwordHash" field.
func (*UserUpsertBulk) ClearPrivateKey ¶
func (u *UserUpsertBulk) ClearPrivateKey() *UserUpsertBulk
ClearPrivateKey clears the value of the "privateKey" field.
func (*UserUpsertBulk) DoNothing ¶
func (u *UserUpsertBulk) DoNothing() *UserUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*UserUpsertBulk) Exec ¶
func (u *UserUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpsertBulk) ExecX ¶
func (u *UserUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpsertBulk) Ignore ¶
func (u *UserUpsertBulk) Ignore() *UserUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*UserUpsertBulk) SetBiography ¶
func (u *UserUpsertBulk) SetBiography(v string) *UserUpsertBulk
SetBiography sets the "biography" field.
func (*UserUpsertBulk) SetDisplayName ¶
func (u *UserUpsertBulk) SetDisplayName(v string) *UserUpsertBulk
SetDisplayName sets the "displayName" field.
func (*UserUpsertBulk) SetExtensions ¶
func (u *UserUpsertBulk) SetExtensions(v versia.Extensions) *UserUpsertBulk
SetExtensions sets the "extensions" field.
func (*UserUpsertBulk) SetFeatured ¶
func (u *UserUpsertBulk) SetFeatured(v string) *UserUpsertBulk
SetFeatured sets the "featured" field.
func (*UserUpsertBulk) SetFields ¶
func (u *UserUpsertBulk) SetFields(v []versia.UserField) *UserUpsertBulk
SetFields sets the "fields" field.
func (*UserUpsertBulk) SetFollowers ¶
func (u *UserUpsertBulk) SetFollowers(v string) *UserUpsertBulk
SetFollowers sets the "followers" field.
func (*UserUpsertBulk) SetFollowing ¶
func (u *UserUpsertBulk) SetFollowing(v string) *UserUpsertBulk
SetFollowing sets the "following" field.
func (*UserUpsertBulk) SetInbox ¶
func (u *UserUpsertBulk) SetInbox(v string) *UserUpsertBulk
SetInbox sets the "inbox" field.
func (*UserUpsertBulk) SetIndexable ¶
func (u *UserUpsertBulk) SetIndexable(v bool) *UserUpsertBulk
SetIndexable sets the "indexable" field.
func (*UserUpsertBulk) SetIsRemote ¶
func (u *UserUpsertBulk) SetIsRemote(v bool) *UserUpsertBulk
SetIsRemote sets the "isRemote" field.
func (*UserUpsertBulk) SetOutbox ¶
func (u *UserUpsertBulk) SetOutbox(v string) *UserUpsertBulk
SetOutbox sets the "outbox" field.
func (*UserUpsertBulk) SetPasswordHash ¶
func (u *UserUpsertBulk) SetPasswordHash(v []byte) *UserUpsertBulk
SetPasswordHash sets the "passwordHash" field.
func (*UserUpsertBulk) SetPrivacyLevel ¶
func (u *UserUpsertBulk) SetPrivacyLevel(v user.PrivacyLevel) *UserUpsertBulk
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserUpsertBulk) SetPrivateKey ¶
func (u *UserUpsertBulk) SetPrivateKey(v []byte) *UserUpsertBulk
SetPrivateKey sets the "privateKey" field.
func (*UserUpsertBulk) SetPublicKey ¶
func (u *UserUpsertBulk) SetPublicKey(v []byte) *UserUpsertBulk
SetPublicKey sets the "publicKey" field.
func (*UserUpsertBulk) SetPublicKeyActor ¶
func (u *UserUpsertBulk) SetPublicKeyActor(v string) *UserUpsertBulk
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserUpsertBulk) SetPublicKeyAlgorithm ¶
func (u *UserUpsertBulk) SetPublicKeyAlgorithm(v string) *UserUpsertBulk
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserUpsertBulk) SetURI ¶
func (u *UserUpsertBulk) SetURI(v string) *UserUpsertBulk
SetURI sets the "uri" field.
func (*UserUpsertBulk) SetUpdatedAt ¶
func (u *UserUpsertBulk) SetUpdatedAt(v time.Time) *UserUpsertBulk
SetUpdatedAt sets the "updated_at" field.
func (*UserUpsertBulk) SetUsername ¶
func (u *UserUpsertBulk) SetUsername(v string) *UserUpsertBulk
SetUsername sets the "username" field.
func (*UserUpsertBulk) Update ¶
func (u *UserUpsertBulk) Update(set func(*UserUpsert)) *UserUpsertBulk
Update allows overriding fields `UPDATE` values. See the UserCreateBulk.OnConflict documentation for more info.
func (*UserUpsertBulk) UpdateBiography ¶
func (u *UserUpsertBulk) UpdateBiography() *UserUpsertBulk
UpdateBiography sets the "biography" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateDisplayName ¶
func (u *UserUpsertBulk) UpdateDisplayName() *UserUpsertBulk
UpdateDisplayName sets the "displayName" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateExtensions ¶
func (u *UserUpsertBulk) UpdateExtensions() *UserUpsertBulk
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateFeatured ¶
func (u *UserUpsertBulk) UpdateFeatured() *UserUpsertBulk
UpdateFeatured sets the "featured" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateFields ¶
func (u *UserUpsertBulk) UpdateFields() *UserUpsertBulk
UpdateFields sets the "fields" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateFollowers ¶
func (u *UserUpsertBulk) UpdateFollowers() *UserUpsertBulk
UpdateFollowers sets the "followers" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateFollowing ¶
func (u *UserUpsertBulk) UpdateFollowing() *UserUpsertBulk
UpdateFollowing sets the "following" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateInbox ¶
func (u *UserUpsertBulk) UpdateInbox() *UserUpsertBulk
UpdateInbox sets the "inbox" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateIndexable ¶
func (u *UserUpsertBulk) UpdateIndexable() *UserUpsertBulk
UpdateIndexable sets the "indexable" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateIsRemote ¶
func (u *UserUpsertBulk) UpdateIsRemote() *UserUpsertBulk
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateNewValues ¶
func (u *UserUpsertBulk) UpdateNewValues() *UserUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.User.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(user.FieldID) }), ). Exec(ctx)
func (*UserUpsertBulk) UpdateOutbox ¶
func (u *UserUpsertBulk) UpdateOutbox() *UserUpsertBulk
UpdateOutbox sets the "outbox" field to the value that was provided on create.
func (*UserUpsertBulk) UpdatePasswordHash ¶
func (u *UserUpsertBulk) UpdatePasswordHash() *UserUpsertBulk
UpdatePasswordHash sets the "passwordHash" field to the value that was provided on create.
func (*UserUpsertBulk) UpdatePrivacyLevel ¶
func (u *UserUpsertBulk) UpdatePrivacyLevel() *UserUpsertBulk
UpdatePrivacyLevel sets the "privacyLevel" field to the value that was provided on create.
func (*UserUpsertBulk) UpdatePrivateKey ¶
func (u *UserUpsertBulk) UpdatePrivateKey() *UserUpsertBulk
UpdatePrivateKey sets the "privateKey" field to the value that was provided on create.
func (*UserUpsertBulk) UpdatePublicKey ¶
func (u *UserUpsertBulk) UpdatePublicKey() *UserUpsertBulk
UpdatePublicKey sets the "publicKey" field to the value that was provided on create.
func (*UserUpsertBulk) UpdatePublicKeyActor ¶
func (u *UserUpsertBulk) UpdatePublicKeyActor() *UserUpsertBulk
UpdatePublicKeyActor sets the "publicKeyActor" field to the value that was provided on create.
func (*UserUpsertBulk) UpdatePublicKeyAlgorithm ¶
func (u *UserUpsertBulk) UpdatePublicKeyAlgorithm() *UserUpsertBulk
UpdatePublicKeyAlgorithm sets the "publicKeyAlgorithm" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateURI ¶
func (u *UserUpsertBulk) UpdateURI() *UserUpsertBulk
UpdateURI sets the "uri" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateUpdatedAt ¶
func (u *UserUpsertBulk) UpdateUpdatedAt() *UserUpsertBulk
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateUsername ¶
func (u *UserUpsertBulk) UpdateUsername() *UserUpsertBulk
UpdateUsername sets the "username" field to the value that was provided on create.
type UserUpsertOne ¶
type UserUpsertOne struct {
// contains filtered or unexported fields
}
UserUpsertOne is the builder for "upsert"-ing
one User node.
func (*UserUpsertOne) ClearBiography ¶
func (u *UserUpsertOne) ClearBiography() *UserUpsertOne
ClearBiography clears the value of the "biography" field.
func (*UserUpsertOne) ClearDisplayName ¶
func (u *UserUpsertOne) ClearDisplayName() *UserUpsertOne
ClearDisplayName clears the value of the "displayName" field.
func (*UserUpsertOne) ClearPasswordHash ¶
func (u *UserUpsertOne) ClearPasswordHash() *UserUpsertOne
ClearPasswordHash clears the value of the "passwordHash" field.
func (*UserUpsertOne) ClearPrivateKey ¶
func (u *UserUpsertOne) ClearPrivateKey() *UserUpsertOne
ClearPrivateKey clears the value of the "privateKey" field.
func (*UserUpsertOne) DoNothing ¶
func (u *UserUpsertOne) DoNothing() *UserUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*UserUpsertOne) Exec ¶
func (u *UserUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpsertOne) ExecX ¶
func (u *UserUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpsertOne) IDX ¶
func (u *UserUpsertOne) IDX(ctx context.Context) uuid.UUID
IDX is like ID, but panics if an error occurs.
func (*UserUpsertOne) Ignore ¶
func (u *UserUpsertOne) Ignore() *UserUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*UserUpsertOne) SetBiography ¶
func (u *UserUpsertOne) SetBiography(v string) *UserUpsertOne
SetBiography sets the "biography" field.
func (*UserUpsertOne) SetDisplayName ¶
func (u *UserUpsertOne) SetDisplayName(v string) *UserUpsertOne
SetDisplayName sets the "displayName" field.
func (*UserUpsertOne) SetExtensions ¶
func (u *UserUpsertOne) SetExtensions(v versia.Extensions) *UserUpsertOne
SetExtensions sets the "extensions" field.
func (*UserUpsertOne) SetFeatured ¶
func (u *UserUpsertOne) SetFeatured(v string) *UserUpsertOne
SetFeatured sets the "featured" field.
func (*UserUpsertOne) SetFields ¶
func (u *UserUpsertOne) SetFields(v []versia.UserField) *UserUpsertOne
SetFields sets the "fields" field.
func (*UserUpsertOne) SetFollowers ¶
func (u *UserUpsertOne) SetFollowers(v string) *UserUpsertOne
SetFollowers sets the "followers" field.
func (*UserUpsertOne) SetFollowing ¶
func (u *UserUpsertOne) SetFollowing(v string) *UserUpsertOne
SetFollowing sets the "following" field.
func (*UserUpsertOne) SetInbox ¶
func (u *UserUpsertOne) SetInbox(v string) *UserUpsertOne
SetInbox sets the "inbox" field.
func (*UserUpsertOne) SetIndexable ¶
func (u *UserUpsertOne) SetIndexable(v bool) *UserUpsertOne
SetIndexable sets the "indexable" field.
func (*UserUpsertOne) SetIsRemote ¶
func (u *UserUpsertOne) SetIsRemote(v bool) *UserUpsertOne
SetIsRemote sets the "isRemote" field.
func (*UserUpsertOne) SetOutbox ¶
func (u *UserUpsertOne) SetOutbox(v string) *UserUpsertOne
SetOutbox sets the "outbox" field.
func (*UserUpsertOne) SetPasswordHash ¶
func (u *UserUpsertOne) SetPasswordHash(v []byte) *UserUpsertOne
SetPasswordHash sets the "passwordHash" field.
func (*UserUpsertOne) SetPrivacyLevel ¶
func (u *UserUpsertOne) SetPrivacyLevel(v user.PrivacyLevel) *UserUpsertOne
SetPrivacyLevel sets the "privacyLevel" field.
func (*UserUpsertOne) SetPrivateKey ¶
func (u *UserUpsertOne) SetPrivateKey(v []byte) *UserUpsertOne
SetPrivateKey sets the "privateKey" field.
func (*UserUpsertOne) SetPublicKey ¶
func (u *UserUpsertOne) SetPublicKey(v []byte) *UserUpsertOne
SetPublicKey sets the "publicKey" field.
func (*UserUpsertOne) SetPublicKeyActor ¶
func (u *UserUpsertOne) SetPublicKeyActor(v string) *UserUpsertOne
SetPublicKeyActor sets the "publicKeyActor" field.
func (*UserUpsertOne) SetPublicKeyAlgorithm ¶
func (u *UserUpsertOne) SetPublicKeyAlgorithm(v string) *UserUpsertOne
SetPublicKeyAlgorithm sets the "publicKeyAlgorithm" field.
func (*UserUpsertOne) SetURI ¶
func (u *UserUpsertOne) SetURI(v string) *UserUpsertOne
SetURI sets the "uri" field.
func (*UserUpsertOne) SetUpdatedAt ¶
func (u *UserUpsertOne) SetUpdatedAt(v time.Time) *UserUpsertOne
SetUpdatedAt sets the "updated_at" field.
func (*UserUpsertOne) SetUsername ¶
func (u *UserUpsertOne) SetUsername(v string) *UserUpsertOne
SetUsername sets the "username" field.
func (*UserUpsertOne) Update ¶
func (u *UserUpsertOne) Update(set func(*UserUpsert)) *UserUpsertOne
Update allows overriding fields `UPDATE` values. See the UserCreate.OnConflict documentation for more info.
func (*UserUpsertOne) UpdateBiography ¶
func (u *UserUpsertOne) UpdateBiography() *UserUpsertOne
UpdateBiography sets the "biography" field to the value that was provided on create.
func (*UserUpsertOne) UpdateDisplayName ¶
func (u *UserUpsertOne) UpdateDisplayName() *UserUpsertOne
UpdateDisplayName sets the "displayName" field to the value that was provided on create.
func (*UserUpsertOne) UpdateExtensions ¶
func (u *UserUpsertOne) UpdateExtensions() *UserUpsertOne
UpdateExtensions sets the "extensions" field to the value that was provided on create.
func (*UserUpsertOne) UpdateFeatured ¶
func (u *UserUpsertOne) UpdateFeatured() *UserUpsertOne
UpdateFeatured sets the "featured" field to the value that was provided on create.
func (*UserUpsertOne) UpdateFields ¶
func (u *UserUpsertOne) UpdateFields() *UserUpsertOne
UpdateFields sets the "fields" field to the value that was provided on create.
func (*UserUpsertOne) UpdateFollowers ¶
func (u *UserUpsertOne) UpdateFollowers() *UserUpsertOne
UpdateFollowers sets the "followers" field to the value that was provided on create.
func (*UserUpsertOne) UpdateFollowing ¶
func (u *UserUpsertOne) UpdateFollowing() *UserUpsertOne
UpdateFollowing sets the "following" field to the value that was provided on create.
func (*UserUpsertOne) UpdateInbox ¶
func (u *UserUpsertOne) UpdateInbox() *UserUpsertOne
UpdateInbox sets the "inbox" field to the value that was provided on create.
func (*UserUpsertOne) UpdateIndexable ¶
func (u *UserUpsertOne) UpdateIndexable() *UserUpsertOne
UpdateIndexable sets the "indexable" field to the value that was provided on create.
func (*UserUpsertOne) UpdateIsRemote ¶
func (u *UserUpsertOne) UpdateIsRemote() *UserUpsertOne
UpdateIsRemote sets the "isRemote" field to the value that was provided on create.
func (*UserUpsertOne) UpdateNewValues ¶
func (u *UserUpsertOne) UpdateNewValues() *UserUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:
client.User.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(user.FieldID) }), ). Exec(ctx)
func (*UserUpsertOne) UpdateOutbox ¶
func (u *UserUpsertOne) UpdateOutbox() *UserUpsertOne
UpdateOutbox sets the "outbox" field to the value that was provided on create.
func (*UserUpsertOne) UpdatePasswordHash ¶
func (u *UserUpsertOne) UpdatePasswordHash() *UserUpsertOne
UpdatePasswordHash sets the "passwordHash" field to the value that was provided on create.
func (*UserUpsertOne) UpdatePrivacyLevel ¶
func (u *UserUpsertOne) UpdatePrivacyLevel() *UserUpsertOne
UpdatePrivacyLevel sets the "privacyLevel" field to the value that was provided on create.
func (*UserUpsertOne) UpdatePrivateKey ¶
func (u *UserUpsertOne) UpdatePrivateKey() *UserUpsertOne
UpdatePrivateKey sets the "privateKey" field to the value that was provided on create.
func (*UserUpsertOne) UpdatePublicKey ¶
func (u *UserUpsertOne) UpdatePublicKey() *UserUpsertOne
UpdatePublicKey sets the "publicKey" field to the value that was provided on create.
func (*UserUpsertOne) UpdatePublicKeyActor ¶
func (u *UserUpsertOne) UpdatePublicKeyActor() *UserUpsertOne
UpdatePublicKeyActor sets the "publicKeyActor" field to the value that was provided on create.
func (*UserUpsertOne) UpdatePublicKeyAlgorithm ¶
func (u *UserUpsertOne) UpdatePublicKeyAlgorithm() *UserUpsertOne
UpdatePublicKeyAlgorithm sets the "publicKeyAlgorithm" field to the value that was provided on create.
func (*UserUpsertOne) UpdateURI ¶
func (u *UserUpsertOne) UpdateURI() *UserUpsertOne
UpdateURI sets the "uri" field to the value that was provided on create.
func (*UserUpsertOne) UpdateUpdatedAt ¶
func (u *UserUpsertOne) UpdateUpdatedAt() *UserUpsertOne
UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.
func (*UserUpsertOne) UpdateUsername ¶
func (u *UserUpsertOne) UpdateUsername() *UserUpsertOne
UpdateUsername sets the "username" field to the value that was provided on create.
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
¶
- attachment.go
- attachment_create.go
- attachment_delete.go
- attachment_query.go
- attachment_update.go
- client.go
- ent.go
- follow.go
- follow_create.go
- follow_delete.go
- follow_query.go
- follow_update.go
- generate.go
- get_client.go
- image.go
- image_create.go
- image_delete.go
- image_query.go
- image_update.go
- instancemetadata.go
- instancemetadata_create.go
- instancemetadata_delete.go
- instancemetadata_query.go
- instancemetadata_update.go
- mutation.go
- note.go
- note_create.go
- note_delete.go
- note_query.go
- note_update.go
- ping.go
- runtime.go
- tx.go
- user.go
- user_create.go
- user_delete.go
- user_query.go
- user_update.go