Documentation ¶
Overview ¶
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
-------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
Code generated by ent, DO NOT EDIT. -------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
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 Client
- func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)
- func (c *Client) Close() error
- func (c *Client) Debug() *Client
- func (c *Client) Intercept(interceptors ...Interceptor)
- func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)
- func (c *Client) Tx(ctx context.Context) (*Tx, error)
- func (c *Client) Use(hooks ...Hook)
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type Document
- type DocumentClient
- func (c *DocumentClient) Create() *DocumentCreate
- func (c *DocumentClient) CreateBulk(builders ...*DocumentCreate) *DocumentCreateBulk
- func (c *DocumentClient) Delete() *DocumentDelete
- func (c *DocumentClient) DeleteOne(d *Document) *DocumentDeleteOne
- func (c *DocumentClient) DeleteOneID(id int) *DocumentDeleteOne
- func (c *DocumentClient) Get(ctx context.Context, id int) (*Document, error)
- func (c *DocumentClient) GetX(ctx context.Context, id int) *Document
- func (c *DocumentClient) Hooks() []Hook
- func (c *DocumentClient) Intercept(interceptors ...Interceptor)
- func (c *DocumentClient) Interceptors() []Interceptor
- func (c *DocumentClient) MapCreateBulk(slice any, setFunc func(*DocumentCreate, int)) *DocumentCreateBulk
- func (c *DocumentClient) Query() *DocumentQuery
- func (c *DocumentClient) QueryMetadata(d *Document) *MetadataQuery
- func (c *DocumentClient) QueryNodeList(d *Document) *NodeListQuery
- func (c *DocumentClient) Update() *DocumentUpdate
- func (c *DocumentClient) UpdateOne(d *Document) *DocumentUpdateOne
- func (c *DocumentClient) UpdateOneID(id int) *DocumentUpdateOne
- func (c *DocumentClient) Use(hooks ...Hook)
- type DocumentCreate
- func (dc *DocumentCreate) Exec(ctx context.Context) error
- func (dc *DocumentCreate) ExecX(ctx context.Context)
- func (dc *DocumentCreate) Mutation() *DocumentMutation
- func (dc *DocumentCreate) OnConflict(opts ...sql.ConflictOption) *DocumentUpsertOne
- func (dc *DocumentCreate) OnConflictColumns(columns ...string) *DocumentUpsertOne
- func (dc *DocumentCreate) Save(ctx context.Context) (*Document, error)
- func (dc *DocumentCreate) SaveX(ctx context.Context) *Document
- func (dc *DocumentCreate) SetMetadata(m *Metadata) *DocumentCreate
- func (dc *DocumentCreate) SetMetadataID(id string) *DocumentCreate
- func (dc *DocumentCreate) SetNodeList(n *NodeList) *DocumentCreate
- func (dc *DocumentCreate) SetNodeListID(id int) *DocumentCreate
- type DocumentCreateBulk
- func (dcb *DocumentCreateBulk) Exec(ctx context.Context) error
- func (dcb *DocumentCreateBulk) ExecX(ctx context.Context)
- func (dcb *DocumentCreateBulk) OnConflict(opts ...sql.ConflictOption) *DocumentUpsertBulk
- func (dcb *DocumentCreateBulk) OnConflictColumns(columns ...string) *DocumentUpsertBulk
- func (dcb *DocumentCreateBulk) Save(ctx context.Context) ([]*Document, error)
- func (dcb *DocumentCreateBulk) SaveX(ctx context.Context) []*Document
- type DocumentDelete
- type DocumentDeleteOne
- type DocumentEdges
- type DocumentGroupBy
- func (dgb *DocumentGroupBy) Aggregate(fns ...AggregateFunc) *DocumentGroupBy
- func (s *DocumentGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *DocumentGroupBy) BoolX(ctx context.Context) bool
- func (s *DocumentGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *DocumentGroupBy) BoolsX(ctx context.Context) []bool
- func (s *DocumentGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *DocumentGroupBy) Float64X(ctx context.Context) float64
- func (s *DocumentGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *DocumentGroupBy) Float64sX(ctx context.Context) []float64
- func (s *DocumentGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *DocumentGroupBy) IntX(ctx context.Context) int
- func (s *DocumentGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *DocumentGroupBy) IntsX(ctx context.Context) []int
- func (dgb *DocumentGroupBy) Scan(ctx context.Context, v any) error
- func (s *DocumentGroupBy) ScanX(ctx context.Context, v any)
- func (s *DocumentGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *DocumentGroupBy) StringX(ctx context.Context) string
- func (s *DocumentGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *DocumentGroupBy) StringsX(ctx context.Context) []string
- type DocumentMutation
- func (m *DocumentMutation) AddField(name string, value ent.Value) error
- func (m *DocumentMutation) AddedEdges() []string
- func (m *DocumentMutation) AddedField(name string) (ent.Value, bool)
- func (m *DocumentMutation) AddedFields() []string
- func (m *DocumentMutation) AddedIDs(name string) []ent.Value
- func (m *DocumentMutation) ClearEdge(name string) error
- func (m *DocumentMutation) ClearField(name string) error
- func (m *DocumentMutation) ClearMetadata()
- func (m *DocumentMutation) ClearNodeList()
- func (m *DocumentMutation) ClearedEdges() []string
- func (m *DocumentMutation) ClearedFields() []string
- func (m DocumentMutation) Client() *Client
- func (m *DocumentMutation) EdgeCleared(name string) bool
- func (m *DocumentMutation) Field(name string) (ent.Value, bool)
- func (m *DocumentMutation) FieldCleared(name string) bool
- func (m *DocumentMutation) Fields() []string
- func (m *DocumentMutation) ID() (id int, exists bool)
- func (m *DocumentMutation) IDs(ctx context.Context) ([]int, error)
- func (m *DocumentMutation) MetadataCleared() bool
- func (m *DocumentMutation) MetadataID() (id string, exists bool)
- func (m *DocumentMutation) MetadataIDs() (ids []string)
- func (m *DocumentMutation) NodeListCleared() bool
- func (m *DocumentMutation) NodeListID() (id int, exists bool)
- func (m *DocumentMutation) NodeListIDs() (ids []int)
- func (m *DocumentMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *DocumentMutation) Op() Op
- func (m *DocumentMutation) RemovedEdges() []string
- func (m *DocumentMutation) RemovedIDs(name string) []ent.Value
- func (m *DocumentMutation) ResetEdge(name string) error
- func (m *DocumentMutation) ResetField(name string) error
- func (m *DocumentMutation) ResetMetadata()
- func (m *DocumentMutation) ResetNodeList()
- func (m *DocumentMutation) SetField(name string, value ent.Value) error
- func (m *DocumentMutation) SetMetadataID(id string)
- func (m *DocumentMutation) SetNodeListID(id int)
- func (m *DocumentMutation) SetOp(op Op)
- func (m DocumentMutation) Tx() (*Tx, error)
- func (m *DocumentMutation) Type() string
- func (m *DocumentMutation) Where(ps ...predicate.Document)
- func (m *DocumentMutation) WhereP(ps ...func(*sql.Selector))
- type DocumentQuery
- func (dq *DocumentQuery) Aggregate(fns ...AggregateFunc) *DocumentSelect
- func (dq *DocumentQuery) All(ctx context.Context) ([]*Document, error)
- func (dq *DocumentQuery) AllX(ctx context.Context) []*Document
- func (dq *DocumentQuery) Clone() *DocumentQuery
- func (dq *DocumentQuery) Count(ctx context.Context) (int, error)
- func (dq *DocumentQuery) CountX(ctx context.Context) int
- func (dq *DocumentQuery) Exist(ctx context.Context) (bool, error)
- func (dq *DocumentQuery) ExistX(ctx context.Context) bool
- func (dq *DocumentQuery) First(ctx context.Context) (*Document, error)
- func (dq *DocumentQuery) FirstID(ctx context.Context) (id int, err error)
- func (dq *DocumentQuery) FirstIDX(ctx context.Context) int
- func (dq *DocumentQuery) FirstX(ctx context.Context) *Document
- func (dq *DocumentQuery) GroupBy(field string, fields ...string) *DocumentGroupBy
- func (dq *DocumentQuery) IDs(ctx context.Context) (ids []int, err error)
- func (dq *DocumentQuery) IDsX(ctx context.Context) []int
- func (dq *DocumentQuery) Limit(limit int) *DocumentQuery
- func (dq *DocumentQuery) Offset(offset int) *DocumentQuery
- func (dq *DocumentQuery) Only(ctx context.Context) (*Document, error)
- func (dq *DocumentQuery) OnlyID(ctx context.Context) (id int, err error)
- func (dq *DocumentQuery) OnlyIDX(ctx context.Context) int
- func (dq *DocumentQuery) OnlyX(ctx context.Context) *Document
- func (dq *DocumentQuery) Order(o ...document.OrderOption) *DocumentQuery
- func (dq *DocumentQuery) QueryMetadata() *MetadataQuery
- func (dq *DocumentQuery) QueryNodeList() *NodeListQuery
- func (dq *DocumentQuery) Select(fields ...string) *DocumentSelect
- func (dq *DocumentQuery) Unique(unique bool) *DocumentQuery
- func (dq *DocumentQuery) Where(ps ...predicate.Document) *DocumentQuery
- func (dq *DocumentQuery) WithMetadata(opts ...func(*MetadataQuery)) *DocumentQuery
- func (dq *DocumentQuery) WithNodeList(opts ...func(*NodeListQuery)) *DocumentQuery
- type DocumentSelect
- func (ds *DocumentSelect) Aggregate(fns ...AggregateFunc) *DocumentSelect
- func (s *DocumentSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *DocumentSelect) BoolX(ctx context.Context) bool
- func (s *DocumentSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *DocumentSelect) BoolsX(ctx context.Context) []bool
- func (s *DocumentSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *DocumentSelect) Float64X(ctx context.Context) float64
- func (s *DocumentSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *DocumentSelect) Float64sX(ctx context.Context) []float64
- func (s *DocumentSelect) Int(ctx context.Context) (_ int, err error)
- func (s *DocumentSelect) IntX(ctx context.Context) int
- func (s *DocumentSelect) Ints(ctx context.Context) ([]int, error)
- func (s *DocumentSelect) IntsX(ctx context.Context) []int
- func (ds *DocumentSelect) Scan(ctx context.Context, v any) error
- func (s *DocumentSelect) ScanX(ctx context.Context, v any)
- func (s *DocumentSelect) String(ctx context.Context) (_ string, err error)
- func (s *DocumentSelect) StringX(ctx context.Context) string
- func (s *DocumentSelect) Strings(ctx context.Context) ([]string, error)
- func (s *DocumentSelect) StringsX(ctx context.Context) []string
- type DocumentType
- type DocumentTypeClient
- func (c *DocumentTypeClient) Create() *DocumentTypeCreate
- func (c *DocumentTypeClient) CreateBulk(builders ...*DocumentTypeCreate) *DocumentTypeCreateBulk
- func (c *DocumentTypeClient) Delete() *DocumentTypeDelete
- func (c *DocumentTypeClient) DeleteOne(dt *DocumentType) *DocumentTypeDeleteOne
- func (c *DocumentTypeClient) DeleteOneID(id int) *DocumentTypeDeleteOne
- func (c *DocumentTypeClient) Get(ctx context.Context, id int) (*DocumentType, error)
- func (c *DocumentTypeClient) GetX(ctx context.Context, id int) *DocumentType
- func (c *DocumentTypeClient) Hooks() []Hook
- func (c *DocumentTypeClient) Intercept(interceptors ...Interceptor)
- func (c *DocumentTypeClient) Interceptors() []Interceptor
- func (c *DocumentTypeClient) MapCreateBulk(slice any, setFunc func(*DocumentTypeCreate, int)) *DocumentTypeCreateBulk
- func (c *DocumentTypeClient) Query() *DocumentTypeQuery
- func (c *DocumentTypeClient) QueryMetadata(dt *DocumentType) *MetadataQuery
- func (c *DocumentTypeClient) Update() *DocumentTypeUpdate
- func (c *DocumentTypeClient) UpdateOne(dt *DocumentType) *DocumentTypeUpdateOne
- func (c *DocumentTypeClient) UpdateOneID(id int) *DocumentTypeUpdateOne
- func (c *DocumentTypeClient) Use(hooks ...Hook)
- type DocumentTypeCreate
- func (dtc *DocumentTypeCreate) Exec(ctx context.Context) error
- func (dtc *DocumentTypeCreate) ExecX(ctx context.Context)
- func (dtc *DocumentTypeCreate) Mutation() *DocumentTypeMutation
- func (dtc *DocumentTypeCreate) OnConflict(opts ...sql.ConflictOption) *DocumentTypeUpsertOne
- func (dtc *DocumentTypeCreate) OnConflictColumns(columns ...string) *DocumentTypeUpsertOne
- func (dtc *DocumentTypeCreate) Save(ctx context.Context) (*DocumentType, error)
- func (dtc *DocumentTypeCreate) SaveX(ctx context.Context) *DocumentType
- func (dtc *DocumentTypeCreate) SetDescription(s string) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetMetadata(m *Metadata) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetMetadataID(id string) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetName(s string) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetNillableDescription(s *string) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetNillableMetadataID(id *string) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetNillableName(s *string) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetNillableType(d *documenttype.Type) *DocumentTypeCreate
- func (dtc *DocumentTypeCreate) SetType(d documenttype.Type) *DocumentTypeCreate
- type DocumentTypeCreateBulk
- func (dtcb *DocumentTypeCreateBulk) Exec(ctx context.Context) error
- func (dtcb *DocumentTypeCreateBulk) ExecX(ctx context.Context)
- func (dtcb *DocumentTypeCreateBulk) OnConflict(opts ...sql.ConflictOption) *DocumentTypeUpsertBulk
- func (dtcb *DocumentTypeCreateBulk) OnConflictColumns(columns ...string) *DocumentTypeUpsertBulk
- func (dtcb *DocumentTypeCreateBulk) Save(ctx context.Context) ([]*DocumentType, error)
- func (dtcb *DocumentTypeCreateBulk) SaveX(ctx context.Context) []*DocumentType
- type DocumentTypeDelete
- type DocumentTypeDeleteOne
- type DocumentTypeEdges
- type DocumentTypeGroupBy
- func (dtgb *DocumentTypeGroupBy) Aggregate(fns ...AggregateFunc) *DocumentTypeGroupBy
- func (s *DocumentTypeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *DocumentTypeGroupBy) BoolX(ctx context.Context) bool
- func (s *DocumentTypeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *DocumentTypeGroupBy) BoolsX(ctx context.Context) []bool
- func (s *DocumentTypeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *DocumentTypeGroupBy) Float64X(ctx context.Context) float64
- func (s *DocumentTypeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *DocumentTypeGroupBy) Float64sX(ctx context.Context) []float64
- func (s *DocumentTypeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *DocumentTypeGroupBy) IntX(ctx context.Context) int
- func (s *DocumentTypeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *DocumentTypeGroupBy) IntsX(ctx context.Context) []int
- func (dtgb *DocumentTypeGroupBy) Scan(ctx context.Context, v any) error
- func (s *DocumentTypeGroupBy) ScanX(ctx context.Context, v any)
- func (s *DocumentTypeGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *DocumentTypeGroupBy) StringX(ctx context.Context) string
- func (s *DocumentTypeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *DocumentTypeGroupBy) StringsX(ctx context.Context) []string
- type DocumentTypeMutation
- func (m *DocumentTypeMutation) AddField(name string, value ent.Value) error
- func (m *DocumentTypeMutation) AddedEdges() []string
- func (m *DocumentTypeMutation) AddedField(name string) (ent.Value, bool)
- func (m *DocumentTypeMutation) AddedFields() []string
- func (m *DocumentTypeMutation) AddedIDs(name string) []ent.Value
- func (m *DocumentTypeMutation) ClearDescription()
- func (m *DocumentTypeMutation) ClearEdge(name string) error
- func (m *DocumentTypeMutation) ClearField(name string) error
- func (m *DocumentTypeMutation) ClearMetadata()
- func (m *DocumentTypeMutation) ClearName()
- func (m *DocumentTypeMutation) ClearType()
- func (m *DocumentTypeMutation) ClearedEdges() []string
- func (m *DocumentTypeMutation) ClearedFields() []string
- func (m DocumentTypeMutation) Client() *Client
- func (m *DocumentTypeMutation) Description() (r string, exists bool)
- func (m *DocumentTypeMutation) DescriptionCleared() bool
- func (m *DocumentTypeMutation) EdgeCleared(name string) bool
- func (m *DocumentTypeMutation) Field(name string) (ent.Value, bool)
- func (m *DocumentTypeMutation) FieldCleared(name string) bool
- func (m *DocumentTypeMutation) Fields() []string
- func (m *DocumentTypeMutation) GetType() (r documenttype.Type, exists bool)
- func (m *DocumentTypeMutation) ID() (id int, exists bool)
- func (m *DocumentTypeMutation) IDs(ctx context.Context) ([]int, error)
- func (m *DocumentTypeMutation) MetadataCleared() bool
- func (m *DocumentTypeMutation) MetadataID() (id string, exists bool)
- func (m *DocumentTypeMutation) MetadataIDs() (ids []string)
- func (m *DocumentTypeMutation) Name() (r string, exists bool)
- func (m *DocumentTypeMutation) NameCleared() bool
- func (m *DocumentTypeMutation) OldDescription(ctx context.Context) (v *string, err error)
- func (m *DocumentTypeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *DocumentTypeMutation) OldName(ctx context.Context) (v *string, err error)
- func (m *DocumentTypeMutation) OldType(ctx context.Context) (v *documenttype.Type, err error)
- func (m *DocumentTypeMutation) Op() Op
- func (m *DocumentTypeMutation) RemovedEdges() []string
- func (m *DocumentTypeMutation) RemovedIDs(name string) []ent.Value
- func (m *DocumentTypeMutation) ResetDescription()
- func (m *DocumentTypeMutation) ResetEdge(name string) error
- func (m *DocumentTypeMutation) ResetField(name string) error
- func (m *DocumentTypeMutation) ResetMetadata()
- func (m *DocumentTypeMutation) ResetName()
- func (m *DocumentTypeMutation) ResetType()
- func (m *DocumentTypeMutation) SetDescription(s string)
- func (m *DocumentTypeMutation) SetField(name string, value ent.Value) error
- func (m *DocumentTypeMutation) SetMetadataID(id string)
- func (m *DocumentTypeMutation) SetName(s string)
- func (m *DocumentTypeMutation) SetOp(op Op)
- func (m *DocumentTypeMutation) SetType(d documenttype.Type)
- func (m DocumentTypeMutation) Tx() (*Tx, error)
- func (m *DocumentTypeMutation) Type() string
- func (m *DocumentTypeMutation) TypeCleared() bool
- func (m *DocumentTypeMutation) Where(ps ...predicate.DocumentType)
- func (m *DocumentTypeMutation) WhereP(ps ...func(*sql.Selector))
- type DocumentTypeQuery
- func (dtq *DocumentTypeQuery) Aggregate(fns ...AggregateFunc) *DocumentTypeSelect
- func (dtq *DocumentTypeQuery) All(ctx context.Context) ([]*DocumentType, error)
- func (dtq *DocumentTypeQuery) AllX(ctx context.Context) []*DocumentType
- func (dtq *DocumentTypeQuery) Clone() *DocumentTypeQuery
- func (dtq *DocumentTypeQuery) Count(ctx context.Context) (int, error)
- func (dtq *DocumentTypeQuery) CountX(ctx context.Context) int
- func (dtq *DocumentTypeQuery) Exist(ctx context.Context) (bool, error)
- func (dtq *DocumentTypeQuery) ExistX(ctx context.Context) bool
- func (dtq *DocumentTypeQuery) First(ctx context.Context) (*DocumentType, error)
- func (dtq *DocumentTypeQuery) FirstID(ctx context.Context) (id int, err error)
- func (dtq *DocumentTypeQuery) FirstIDX(ctx context.Context) int
- func (dtq *DocumentTypeQuery) FirstX(ctx context.Context) *DocumentType
- func (dtq *DocumentTypeQuery) GroupBy(field string, fields ...string) *DocumentTypeGroupBy
- func (dtq *DocumentTypeQuery) IDs(ctx context.Context) (ids []int, err error)
- func (dtq *DocumentTypeQuery) IDsX(ctx context.Context) []int
- func (dtq *DocumentTypeQuery) Limit(limit int) *DocumentTypeQuery
- func (dtq *DocumentTypeQuery) Offset(offset int) *DocumentTypeQuery
- func (dtq *DocumentTypeQuery) Only(ctx context.Context) (*DocumentType, error)
- func (dtq *DocumentTypeQuery) OnlyID(ctx context.Context) (id int, err error)
- func (dtq *DocumentTypeQuery) OnlyIDX(ctx context.Context) int
- func (dtq *DocumentTypeQuery) OnlyX(ctx context.Context) *DocumentType
- func (dtq *DocumentTypeQuery) Order(o ...documenttype.OrderOption) *DocumentTypeQuery
- func (dtq *DocumentTypeQuery) QueryMetadata() *MetadataQuery
- func (dtq *DocumentTypeQuery) Select(fields ...string) *DocumentTypeSelect
- func (dtq *DocumentTypeQuery) Unique(unique bool) *DocumentTypeQuery
- func (dtq *DocumentTypeQuery) Where(ps ...predicate.DocumentType) *DocumentTypeQuery
- func (dtq *DocumentTypeQuery) WithMetadata(opts ...func(*MetadataQuery)) *DocumentTypeQuery
- type DocumentTypeSelect
- func (dts *DocumentTypeSelect) Aggregate(fns ...AggregateFunc) *DocumentTypeSelect
- func (s *DocumentTypeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *DocumentTypeSelect) BoolX(ctx context.Context) bool
- func (s *DocumentTypeSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *DocumentTypeSelect) BoolsX(ctx context.Context) []bool
- func (s *DocumentTypeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *DocumentTypeSelect) Float64X(ctx context.Context) float64
- func (s *DocumentTypeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *DocumentTypeSelect) Float64sX(ctx context.Context) []float64
- func (s *DocumentTypeSelect) Int(ctx context.Context) (_ int, err error)
- func (s *DocumentTypeSelect) IntX(ctx context.Context) int
- func (s *DocumentTypeSelect) Ints(ctx context.Context) ([]int, error)
- func (s *DocumentTypeSelect) IntsX(ctx context.Context) []int
- func (dts *DocumentTypeSelect) Scan(ctx context.Context, v any) error
- func (s *DocumentTypeSelect) ScanX(ctx context.Context, v any)
- func (s *DocumentTypeSelect) String(ctx context.Context) (_ string, err error)
- func (s *DocumentTypeSelect) StringX(ctx context.Context) string
- func (s *DocumentTypeSelect) Strings(ctx context.Context) ([]string, error)
- func (s *DocumentTypeSelect) StringsX(ctx context.Context) []string
- type DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) ClearDescription() *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) ClearMetadata() *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) ClearName() *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) ClearType() *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) Exec(ctx context.Context) error
- func (dtu *DocumentTypeUpdate) ExecX(ctx context.Context)
- func (dtu *DocumentTypeUpdate) Mutation() *DocumentTypeMutation
- func (dtu *DocumentTypeUpdate) Save(ctx context.Context) (int, error)
- func (dtu *DocumentTypeUpdate) SaveX(ctx context.Context) int
- func (dtu *DocumentTypeUpdate) SetDescription(s string) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetMetadata(m *Metadata) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetMetadataID(id string) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetName(s string) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetNillableDescription(s *string) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetNillableMetadataID(id *string) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetNillableName(s *string) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetNillableType(d *documenttype.Type) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) SetType(d documenttype.Type) *DocumentTypeUpdate
- func (dtu *DocumentTypeUpdate) Where(ps ...predicate.DocumentType) *DocumentTypeUpdate
- type DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) ClearDescription() *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) ClearMetadata() *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) ClearName() *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) ClearType() *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) Exec(ctx context.Context) error
- func (dtuo *DocumentTypeUpdateOne) ExecX(ctx context.Context)
- func (dtuo *DocumentTypeUpdateOne) Mutation() *DocumentTypeMutation
- func (dtuo *DocumentTypeUpdateOne) Save(ctx context.Context) (*DocumentType, error)
- func (dtuo *DocumentTypeUpdateOne) SaveX(ctx context.Context) *DocumentType
- func (dtuo *DocumentTypeUpdateOne) Select(field string, fields ...string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetDescription(s string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetMetadata(m *Metadata) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetMetadataID(id string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetName(s string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetNillableDescription(s *string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetNillableMetadataID(id *string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetNillableName(s *string) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetNillableType(d *documenttype.Type) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) SetType(d documenttype.Type) *DocumentTypeUpdateOne
- func (dtuo *DocumentTypeUpdateOne) Where(ps ...predicate.DocumentType) *DocumentTypeUpdateOne
- type DocumentTypeUpsert
- func (u *DocumentTypeUpsert) ClearDescription() *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) ClearName() *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) ClearType() *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) SetDescription(v string) *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) SetName(v string) *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) SetType(v documenttype.Type) *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) UpdateDescription() *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) UpdateName() *DocumentTypeUpsert
- func (u *DocumentTypeUpsert) UpdateType() *DocumentTypeUpsert
- type DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) ClearDescription() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) ClearName() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) ClearType() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) DoNothing() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) Exec(ctx context.Context) error
- func (u *DocumentTypeUpsertBulk) ExecX(ctx context.Context)
- func (u *DocumentTypeUpsertBulk) Ignore() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) SetDescription(v string) *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) SetName(v string) *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) SetType(v documenttype.Type) *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) Update(set func(*DocumentTypeUpsert)) *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) UpdateDescription() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) UpdateName() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) UpdateNewValues() *DocumentTypeUpsertBulk
- func (u *DocumentTypeUpsertBulk) UpdateType() *DocumentTypeUpsertBulk
- type DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) ClearDescription() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) ClearName() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) ClearType() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) DoNothing() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) Exec(ctx context.Context) error
- func (u *DocumentTypeUpsertOne) ExecX(ctx context.Context)
- func (u *DocumentTypeUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *DocumentTypeUpsertOne) IDX(ctx context.Context) int
- func (u *DocumentTypeUpsertOne) Ignore() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) SetDescription(v string) *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) SetName(v string) *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) SetType(v documenttype.Type) *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) Update(set func(*DocumentTypeUpsert)) *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) UpdateDescription() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) UpdateName() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) UpdateNewValues() *DocumentTypeUpsertOne
- func (u *DocumentTypeUpsertOne) UpdateType() *DocumentTypeUpsertOne
- type DocumentTypes
- type DocumentUpdate
- func (du *DocumentUpdate) ClearMetadata() *DocumentUpdate
- func (du *DocumentUpdate) ClearNodeList() *DocumentUpdate
- func (du *DocumentUpdate) Exec(ctx context.Context) error
- func (du *DocumentUpdate) ExecX(ctx context.Context)
- func (du *DocumentUpdate) Mutation() *DocumentMutation
- func (du *DocumentUpdate) Save(ctx context.Context) (int, error)
- func (du *DocumentUpdate) SaveX(ctx context.Context) int
- func (du *DocumentUpdate) SetMetadata(m *Metadata) *DocumentUpdate
- func (du *DocumentUpdate) SetMetadataID(id string) *DocumentUpdate
- func (du *DocumentUpdate) SetNodeList(n *NodeList) *DocumentUpdate
- func (du *DocumentUpdate) SetNodeListID(id int) *DocumentUpdate
- func (du *DocumentUpdate) Where(ps ...predicate.Document) *DocumentUpdate
- type DocumentUpdateOne
- func (duo *DocumentUpdateOne) ClearMetadata() *DocumentUpdateOne
- func (duo *DocumentUpdateOne) ClearNodeList() *DocumentUpdateOne
- func (duo *DocumentUpdateOne) Exec(ctx context.Context) error
- func (duo *DocumentUpdateOne) ExecX(ctx context.Context)
- func (duo *DocumentUpdateOne) Mutation() *DocumentMutation
- func (duo *DocumentUpdateOne) Save(ctx context.Context) (*Document, error)
- func (duo *DocumentUpdateOne) SaveX(ctx context.Context) *Document
- func (duo *DocumentUpdateOne) Select(field string, fields ...string) *DocumentUpdateOne
- func (duo *DocumentUpdateOne) SetMetadata(m *Metadata) *DocumentUpdateOne
- func (duo *DocumentUpdateOne) SetMetadataID(id string) *DocumentUpdateOne
- func (duo *DocumentUpdateOne) SetNodeList(n *NodeList) *DocumentUpdateOne
- func (duo *DocumentUpdateOne) SetNodeListID(id int) *DocumentUpdateOne
- func (duo *DocumentUpdateOne) Where(ps ...predicate.Document) *DocumentUpdateOne
- type DocumentUpsert
- type DocumentUpsertBulk
- func (u *DocumentUpsertBulk) DoNothing() *DocumentUpsertBulk
- func (u *DocumentUpsertBulk) Exec(ctx context.Context) error
- func (u *DocumentUpsertBulk) ExecX(ctx context.Context)
- func (u *DocumentUpsertBulk) Ignore() *DocumentUpsertBulk
- func (u *DocumentUpsertBulk) Update(set func(*DocumentUpsert)) *DocumentUpsertBulk
- func (u *DocumentUpsertBulk) UpdateNewValues() *DocumentUpsertBulk
- type DocumentUpsertOne
- func (u *DocumentUpsertOne) DoNothing() *DocumentUpsertOne
- func (u *DocumentUpsertOne) Exec(ctx context.Context) error
- func (u *DocumentUpsertOne) ExecX(ctx context.Context)
- func (u *DocumentUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *DocumentUpsertOne) IDX(ctx context.Context) int
- func (u *DocumentUpsertOne) Ignore() *DocumentUpsertOne
- func (u *DocumentUpsertOne) Update(set func(*DocumentUpsert)) *DocumentUpsertOne
- func (u *DocumentUpsertOne) UpdateNewValues() *DocumentUpsertOne
- type Documents
- type EdgeType
- type EdgeTypeClient
- func (c *EdgeTypeClient) Create() *EdgeTypeCreate
- func (c *EdgeTypeClient) CreateBulk(builders ...*EdgeTypeCreate) *EdgeTypeCreateBulk
- func (c *EdgeTypeClient) Delete() *EdgeTypeDelete
- func (c *EdgeTypeClient) DeleteOne(et *EdgeType) *EdgeTypeDeleteOne
- func (c *EdgeTypeClient) DeleteOneID(id int) *EdgeTypeDeleteOne
- func (c *EdgeTypeClient) Get(ctx context.Context, id int) (*EdgeType, error)
- func (c *EdgeTypeClient) GetX(ctx context.Context, id int) *EdgeType
- func (c *EdgeTypeClient) Hooks() []Hook
- func (c *EdgeTypeClient) Intercept(interceptors ...Interceptor)
- func (c *EdgeTypeClient) Interceptors() []Interceptor
- func (c *EdgeTypeClient) MapCreateBulk(slice any, setFunc func(*EdgeTypeCreate, int)) *EdgeTypeCreateBulk
- func (c *EdgeTypeClient) Query() *EdgeTypeQuery
- func (c *EdgeTypeClient) QueryFrom(et *EdgeType) *NodeQuery
- func (c *EdgeTypeClient) QueryTo(et *EdgeType) *NodeQuery
- func (c *EdgeTypeClient) Update() *EdgeTypeUpdate
- func (c *EdgeTypeClient) UpdateOne(et *EdgeType) *EdgeTypeUpdateOne
- func (c *EdgeTypeClient) UpdateOneID(id int) *EdgeTypeUpdateOne
- func (c *EdgeTypeClient) Use(hooks ...Hook)
- type EdgeTypeCreate
- func (etc *EdgeTypeCreate) Exec(ctx context.Context) error
- func (etc *EdgeTypeCreate) ExecX(ctx context.Context)
- func (etc *EdgeTypeCreate) Mutation() *EdgeTypeMutation
- func (etc *EdgeTypeCreate) OnConflict(opts ...sql.ConflictOption) *EdgeTypeUpsertOne
- func (etc *EdgeTypeCreate) OnConflictColumns(columns ...string) *EdgeTypeUpsertOne
- func (etc *EdgeTypeCreate) Save(ctx context.Context) (*EdgeType, error)
- func (etc *EdgeTypeCreate) SaveX(ctx context.Context) *EdgeType
- func (etc *EdgeTypeCreate) SetFrom(n *Node) *EdgeTypeCreate
- func (etc *EdgeTypeCreate) SetFromID(id string) *EdgeTypeCreate
- func (etc *EdgeTypeCreate) SetNodeID(s string) *EdgeTypeCreate
- func (etc *EdgeTypeCreate) SetTo(n *Node) *EdgeTypeCreate
- func (etc *EdgeTypeCreate) SetToID(s string) *EdgeTypeCreate
- func (etc *EdgeTypeCreate) SetType(e edgetype.Type) *EdgeTypeCreate
- type EdgeTypeCreateBulk
- func (etcb *EdgeTypeCreateBulk) Exec(ctx context.Context) error
- func (etcb *EdgeTypeCreateBulk) ExecX(ctx context.Context)
- func (etcb *EdgeTypeCreateBulk) OnConflict(opts ...sql.ConflictOption) *EdgeTypeUpsertBulk
- func (etcb *EdgeTypeCreateBulk) OnConflictColumns(columns ...string) *EdgeTypeUpsertBulk
- func (etcb *EdgeTypeCreateBulk) Save(ctx context.Context) ([]*EdgeType, error)
- func (etcb *EdgeTypeCreateBulk) SaveX(ctx context.Context) []*EdgeType
- type EdgeTypeDelete
- type EdgeTypeDeleteOne
- type EdgeTypeEdges
- type EdgeTypeGroupBy
- func (etgb *EdgeTypeGroupBy) Aggregate(fns ...AggregateFunc) *EdgeTypeGroupBy
- func (s *EdgeTypeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *EdgeTypeGroupBy) BoolX(ctx context.Context) bool
- func (s *EdgeTypeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *EdgeTypeGroupBy) BoolsX(ctx context.Context) []bool
- func (s *EdgeTypeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *EdgeTypeGroupBy) Float64X(ctx context.Context) float64
- func (s *EdgeTypeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *EdgeTypeGroupBy) Float64sX(ctx context.Context) []float64
- func (s *EdgeTypeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *EdgeTypeGroupBy) IntX(ctx context.Context) int
- func (s *EdgeTypeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *EdgeTypeGroupBy) IntsX(ctx context.Context) []int
- func (etgb *EdgeTypeGroupBy) Scan(ctx context.Context, v any) error
- func (s *EdgeTypeGroupBy) ScanX(ctx context.Context, v any)
- func (s *EdgeTypeGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *EdgeTypeGroupBy) StringX(ctx context.Context) string
- func (s *EdgeTypeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *EdgeTypeGroupBy) StringsX(ctx context.Context) []string
- type EdgeTypeMutation
- func (m *EdgeTypeMutation) AddField(name string, value ent.Value) error
- func (m *EdgeTypeMutation) AddedEdges() []string
- func (m *EdgeTypeMutation) AddedField(name string) (ent.Value, bool)
- func (m *EdgeTypeMutation) AddedFields() []string
- func (m *EdgeTypeMutation) AddedIDs(name string) []ent.Value
- func (m *EdgeTypeMutation) ClearEdge(name string) error
- func (m *EdgeTypeMutation) ClearField(name string) error
- func (m *EdgeTypeMutation) ClearFrom()
- func (m *EdgeTypeMutation) ClearTo()
- func (m *EdgeTypeMutation) ClearedEdges() []string
- func (m *EdgeTypeMutation) ClearedFields() []string
- func (m EdgeTypeMutation) Client() *Client
- func (m *EdgeTypeMutation) EdgeCleared(name string) bool
- func (m *EdgeTypeMutation) Field(name string) (ent.Value, bool)
- func (m *EdgeTypeMutation) FieldCleared(name string) bool
- func (m *EdgeTypeMutation) Fields() []string
- func (m *EdgeTypeMutation) FromCleared() bool
- func (m *EdgeTypeMutation) FromID() (id string, exists bool)
- func (m *EdgeTypeMutation) FromIDs() (ids []string)
- func (m *EdgeTypeMutation) GetType() (r edgetype.Type, exists bool)
- func (m *EdgeTypeMutation) ID() (id int, exists bool)
- func (m *EdgeTypeMutation) IDs(ctx context.Context) ([]int, error)
- func (m *EdgeTypeMutation) NodeID() (r string, exists bool)
- func (m *EdgeTypeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *EdgeTypeMutation) OldNodeID(ctx context.Context) (v string, err error)
- func (m *EdgeTypeMutation) OldToID(ctx context.Context) (v string, err error)
- func (m *EdgeTypeMutation) OldType(ctx context.Context) (v edgetype.Type, err error)
- func (m *EdgeTypeMutation) Op() Op
- func (m *EdgeTypeMutation) RemovedEdges() []string
- func (m *EdgeTypeMutation) RemovedIDs(name string) []ent.Value
- func (m *EdgeTypeMutation) ResetEdge(name string) error
- func (m *EdgeTypeMutation) ResetField(name string) error
- func (m *EdgeTypeMutation) ResetFrom()
- func (m *EdgeTypeMutation) ResetNodeID()
- func (m *EdgeTypeMutation) ResetTo()
- func (m *EdgeTypeMutation) ResetToID()
- func (m *EdgeTypeMutation) ResetType()
- func (m *EdgeTypeMutation) SetField(name string, value ent.Value) error
- func (m *EdgeTypeMutation) SetFromID(id string)
- func (m *EdgeTypeMutation) SetNodeID(s string)
- func (m *EdgeTypeMutation) SetOp(op Op)
- func (m *EdgeTypeMutation) SetToID(s string)
- func (m *EdgeTypeMutation) SetType(e edgetype.Type)
- func (m *EdgeTypeMutation) ToCleared() bool
- func (m *EdgeTypeMutation) ToID() (r string, exists bool)
- func (m *EdgeTypeMutation) ToIDs() (ids []string)
- func (m EdgeTypeMutation) Tx() (*Tx, error)
- func (m *EdgeTypeMutation) Type() string
- func (m *EdgeTypeMutation) Where(ps ...predicate.EdgeType)
- func (m *EdgeTypeMutation) WhereP(ps ...func(*sql.Selector))
- type EdgeTypeQuery
- func (etq *EdgeTypeQuery) Aggregate(fns ...AggregateFunc) *EdgeTypeSelect
- func (etq *EdgeTypeQuery) All(ctx context.Context) ([]*EdgeType, error)
- func (etq *EdgeTypeQuery) AllX(ctx context.Context) []*EdgeType
- func (etq *EdgeTypeQuery) Clone() *EdgeTypeQuery
- func (etq *EdgeTypeQuery) Count(ctx context.Context) (int, error)
- func (etq *EdgeTypeQuery) CountX(ctx context.Context) int
- func (etq *EdgeTypeQuery) Exist(ctx context.Context) (bool, error)
- func (etq *EdgeTypeQuery) ExistX(ctx context.Context) bool
- func (etq *EdgeTypeQuery) First(ctx context.Context) (*EdgeType, error)
- func (etq *EdgeTypeQuery) FirstID(ctx context.Context) (id int, err error)
- func (etq *EdgeTypeQuery) FirstIDX(ctx context.Context) int
- func (etq *EdgeTypeQuery) FirstX(ctx context.Context) *EdgeType
- func (etq *EdgeTypeQuery) GroupBy(field string, fields ...string) *EdgeTypeGroupBy
- func (etq *EdgeTypeQuery) IDs(ctx context.Context) (ids []int, err error)
- func (etq *EdgeTypeQuery) IDsX(ctx context.Context) []int
- func (etq *EdgeTypeQuery) Limit(limit int) *EdgeTypeQuery
- func (etq *EdgeTypeQuery) Offset(offset int) *EdgeTypeQuery
- func (etq *EdgeTypeQuery) Only(ctx context.Context) (*EdgeType, error)
- func (etq *EdgeTypeQuery) OnlyID(ctx context.Context) (id int, err error)
- func (etq *EdgeTypeQuery) OnlyIDX(ctx context.Context) int
- func (etq *EdgeTypeQuery) OnlyX(ctx context.Context) *EdgeType
- func (etq *EdgeTypeQuery) Order(o ...edgetype.OrderOption) *EdgeTypeQuery
- func (etq *EdgeTypeQuery) QueryFrom() *NodeQuery
- func (etq *EdgeTypeQuery) QueryTo() *NodeQuery
- func (etq *EdgeTypeQuery) Select(fields ...string) *EdgeTypeSelect
- func (etq *EdgeTypeQuery) Unique(unique bool) *EdgeTypeQuery
- func (etq *EdgeTypeQuery) Where(ps ...predicate.EdgeType) *EdgeTypeQuery
- func (etq *EdgeTypeQuery) WithFrom(opts ...func(*NodeQuery)) *EdgeTypeQuery
- func (etq *EdgeTypeQuery) WithTo(opts ...func(*NodeQuery)) *EdgeTypeQuery
- type EdgeTypeSelect
- func (ets *EdgeTypeSelect) Aggregate(fns ...AggregateFunc) *EdgeTypeSelect
- func (s *EdgeTypeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *EdgeTypeSelect) BoolX(ctx context.Context) bool
- func (s *EdgeTypeSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *EdgeTypeSelect) BoolsX(ctx context.Context) []bool
- func (s *EdgeTypeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *EdgeTypeSelect) Float64X(ctx context.Context) float64
- func (s *EdgeTypeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *EdgeTypeSelect) Float64sX(ctx context.Context) []float64
- func (s *EdgeTypeSelect) Int(ctx context.Context) (_ int, err error)
- func (s *EdgeTypeSelect) IntX(ctx context.Context) int
- func (s *EdgeTypeSelect) Ints(ctx context.Context) ([]int, error)
- func (s *EdgeTypeSelect) IntsX(ctx context.Context) []int
- func (ets *EdgeTypeSelect) Scan(ctx context.Context, v any) error
- func (s *EdgeTypeSelect) ScanX(ctx context.Context, v any)
- func (s *EdgeTypeSelect) String(ctx context.Context) (_ string, err error)
- func (s *EdgeTypeSelect) StringX(ctx context.Context) string
- func (s *EdgeTypeSelect) Strings(ctx context.Context) ([]string, error)
- func (s *EdgeTypeSelect) StringsX(ctx context.Context) []string
- type EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) ClearFrom() *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) ClearTo() *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) Exec(ctx context.Context) error
- func (etu *EdgeTypeUpdate) ExecX(ctx context.Context)
- func (etu *EdgeTypeUpdate) Mutation() *EdgeTypeMutation
- func (etu *EdgeTypeUpdate) Save(ctx context.Context) (int, error)
- func (etu *EdgeTypeUpdate) SaveX(ctx context.Context) int
- func (etu *EdgeTypeUpdate) SetFrom(n *Node) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetFromID(id string) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetNillableNodeID(s *string) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetNillableToID(s *string) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetNillableType(e *edgetype.Type) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetNodeID(s string) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetTo(n *Node) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetToID(s string) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) SetType(e edgetype.Type) *EdgeTypeUpdate
- func (etu *EdgeTypeUpdate) Where(ps ...predicate.EdgeType) *EdgeTypeUpdate
- type EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) ClearFrom() *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) ClearTo() *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) Exec(ctx context.Context) error
- func (etuo *EdgeTypeUpdateOne) ExecX(ctx context.Context)
- func (etuo *EdgeTypeUpdateOne) Mutation() *EdgeTypeMutation
- func (etuo *EdgeTypeUpdateOne) Save(ctx context.Context) (*EdgeType, error)
- func (etuo *EdgeTypeUpdateOne) SaveX(ctx context.Context) *EdgeType
- func (etuo *EdgeTypeUpdateOne) Select(field string, fields ...string) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetFrom(n *Node) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetFromID(id string) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetNillableNodeID(s *string) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetNillableToID(s *string) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetNillableType(e *edgetype.Type) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetNodeID(s string) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetTo(n *Node) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetToID(s string) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) SetType(e edgetype.Type) *EdgeTypeUpdateOne
- func (etuo *EdgeTypeUpdateOne) Where(ps ...predicate.EdgeType) *EdgeTypeUpdateOne
- type EdgeTypeUpsert
- func (u *EdgeTypeUpsert) SetNodeID(v string) *EdgeTypeUpsert
- func (u *EdgeTypeUpsert) SetToID(v string) *EdgeTypeUpsert
- func (u *EdgeTypeUpsert) SetType(v edgetype.Type) *EdgeTypeUpsert
- func (u *EdgeTypeUpsert) UpdateNodeID() *EdgeTypeUpsert
- func (u *EdgeTypeUpsert) UpdateToID() *EdgeTypeUpsert
- func (u *EdgeTypeUpsert) UpdateType() *EdgeTypeUpsert
- type EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) DoNothing() *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) Exec(ctx context.Context) error
- func (u *EdgeTypeUpsertBulk) ExecX(ctx context.Context)
- func (u *EdgeTypeUpsertBulk) Ignore() *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) SetNodeID(v string) *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) SetToID(v string) *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) SetType(v edgetype.Type) *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) Update(set func(*EdgeTypeUpsert)) *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) UpdateNewValues() *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) UpdateNodeID() *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) UpdateToID() *EdgeTypeUpsertBulk
- func (u *EdgeTypeUpsertBulk) UpdateType() *EdgeTypeUpsertBulk
- type EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) DoNothing() *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) Exec(ctx context.Context) error
- func (u *EdgeTypeUpsertOne) ExecX(ctx context.Context)
- func (u *EdgeTypeUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *EdgeTypeUpsertOne) IDX(ctx context.Context) int
- func (u *EdgeTypeUpsertOne) Ignore() *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) SetNodeID(v string) *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) SetToID(v string) *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) SetType(v edgetype.Type) *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) Update(set func(*EdgeTypeUpsert)) *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) UpdateNewValues() *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) UpdateNodeID() *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) UpdateToID() *EdgeTypeUpsertOne
- func (u *EdgeTypeUpsertOne) UpdateType() *EdgeTypeUpsertOne
- type EdgeTypes
- type ExternalReference
- func (er *ExternalReference) QueryHashes() *HashesEntryQuery
- func (er *ExternalReference) QueryNode() *NodeQuery
- func (er *ExternalReference) String() string
- func (er *ExternalReference) Unwrap() *ExternalReference
- func (er *ExternalReference) Update() *ExternalReferenceUpdateOne
- func (er *ExternalReference) Value(name string) (ent.Value, error)
- type ExternalReferenceClient
- func (c *ExternalReferenceClient) Create() *ExternalReferenceCreate
- func (c *ExternalReferenceClient) CreateBulk(builders ...*ExternalReferenceCreate) *ExternalReferenceCreateBulk
- func (c *ExternalReferenceClient) Delete() *ExternalReferenceDelete
- func (c *ExternalReferenceClient) DeleteOne(er *ExternalReference) *ExternalReferenceDeleteOne
- func (c *ExternalReferenceClient) DeleteOneID(id int) *ExternalReferenceDeleteOne
- func (c *ExternalReferenceClient) Get(ctx context.Context, id int) (*ExternalReference, error)
- func (c *ExternalReferenceClient) GetX(ctx context.Context, id int) *ExternalReference
- func (c *ExternalReferenceClient) Hooks() []Hook
- func (c *ExternalReferenceClient) Intercept(interceptors ...Interceptor)
- func (c *ExternalReferenceClient) Interceptors() []Interceptor
- func (c *ExternalReferenceClient) MapCreateBulk(slice any, setFunc func(*ExternalReferenceCreate, int)) *ExternalReferenceCreateBulk
- func (c *ExternalReferenceClient) Query() *ExternalReferenceQuery
- func (c *ExternalReferenceClient) QueryHashes(er *ExternalReference) *HashesEntryQuery
- func (c *ExternalReferenceClient) QueryNode(er *ExternalReference) *NodeQuery
- func (c *ExternalReferenceClient) Update() *ExternalReferenceUpdate
- func (c *ExternalReferenceClient) UpdateOne(er *ExternalReference) *ExternalReferenceUpdateOne
- func (c *ExternalReferenceClient) UpdateOneID(id int) *ExternalReferenceUpdateOne
- func (c *ExternalReferenceClient) Use(hooks ...Hook)
- type ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) AddHashIDs(ids ...int) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) AddHashes(h ...*HashesEntry) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) Exec(ctx context.Context) error
- func (erc *ExternalReferenceCreate) ExecX(ctx context.Context)
- func (erc *ExternalReferenceCreate) Mutation() *ExternalReferenceMutation
- func (erc *ExternalReferenceCreate) OnConflict(opts ...sql.ConflictOption) *ExternalReferenceUpsertOne
- func (erc *ExternalReferenceCreate) OnConflictColumns(columns ...string) *ExternalReferenceUpsertOne
- func (erc *ExternalReferenceCreate) Save(ctx context.Context) (*ExternalReference, error)
- func (erc *ExternalReferenceCreate) SaveX(ctx context.Context) *ExternalReference
- func (erc *ExternalReferenceCreate) SetAuthority(s string) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) SetComment(s string) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) SetNillableAuthority(s *string) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) SetNode(n *Node) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) SetNodeID(id string) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) SetType(e externalreference.Type) *ExternalReferenceCreate
- func (erc *ExternalReferenceCreate) SetURL(s string) *ExternalReferenceCreate
- type ExternalReferenceCreateBulk
- func (ercb *ExternalReferenceCreateBulk) Exec(ctx context.Context) error
- func (ercb *ExternalReferenceCreateBulk) ExecX(ctx context.Context)
- func (ercb *ExternalReferenceCreateBulk) OnConflict(opts ...sql.ConflictOption) *ExternalReferenceUpsertBulk
- func (ercb *ExternalReferenceCreateBulk) OnConflictColumns(columns ...string) *ExternalReferenceUpsertBulk
- func (ercb *ExternalReferenceCreateBulk) Save(ctx context.Context) ([]*ExternalReference, error)
- func (ercb *ExternalReferenceCreateBulk) SaveX(ctx context.Context) []*ExternalReference
- type ExternalReferenceDelete
- type ExternalReferenceDeleteOne
- type ExternalReferenceEdges
- type ExternalReferenceGroupBy
- func (ergb *ExternalReferenceGroupBy) Aggregate(fns ...AggregateFunc) *ExternalReferenceGroupBy
- func (s *ExternalReferenceGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *ExternalReferenceGroupBy) BoolX(ctx context.Context) bool
- func (s *ExternalReferenceGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *ExternalReferenceGroupBy) BoolsX(ctx context.Context) []bool
- func (s *ExternalReferenceGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *ExternalReferenceGroupBy) Float64X(ctx context.Context) float64
- func (s *ExternalReferenceGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *ExternalReferenceGroupBy) Float64sX(ctx context.Context) []float64
- func (s *ExternalReferenceGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *ExternalReferenceGroupBy) IntX(ctx context.Context) int
- func (s *ExternalReferenceGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *ExternalReferenceGroupBy) IntsX(ctx context.Context) []int
- func (ergb *ExternalReferenceGroupBy) Scan(ctx context.Context, v any) error
- func (s *ExternalReferenceGroupBy) ScanX(ctx context.Context, v any)
- func (s *ExternalReferenceGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *ExternalReferenceGroupBy) StringX(ctx context.Context) string
- func (s *ExternalReferenceGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *ExternalReferenceGroupBy) StringsX(ctx context.Context) []string
- type ExternalReferenceMutation
- func (m *ExternalReferenceMutation) AddField(name string, value ent.Value) error
- func (m *ExternalReferenceMutation) AddHashIDs(ids ...int)
- func (m *ExternalReferenceMutation) AddedEdges() []string
- func (m *ExternalReferenceMutation) AddedField(name string) (ent.Value, bool)
- func (m *ExternalReferenceMutation) AddedFields() []string
- func (m *ExternalReferenceMutation) AddedIDs(name string) []ent.Value
- func (m *ExternalReferenceMutation) Authority() (r string, exists bool)
- func (m *ExternalReferenceMutation) AuthorityCleared() bool
- func (m *ExternalReferenceMutation) ClearAuthority()
- func (m *ExternalReferenceMutation) ClearEdge(name string) error
- func (m *ExternalReferenceMutation) ClearField(name string) error
- func (m *ExternalReferenceMutation) ClearHashes()
- func (m *ExternalReferenceMutation) ClearNode()
- func (m *ExternalReferenceMutation) ClearedEdges() []string
- func (m *ExternalReferenceMutation) ClearedFields() []string
- func (m ExternalReferenceMutation) Client() *Client
- func (m *ExternalReferenceMutation) Comment() (r string, exists bool)
- func (m *ExternalReferenceMutation) EdgeCleared(name string) bool
- func (m *ExternalReferenceMutation) Field(name string) (ent.Value, bool)
- func (m *ExternalReferenceMutation) FieldCleared(name string) bool
- func (m *ExternalReferenceMutation) Fields() []string
- func (m *ExternalReferenceMutation) GetType() (r externalreference.Type, exists bool)
- func (m *ExternalReferenceMutation) HashesCleared() bool
- func (m *ExternalReferenceMutation) HashesIDs() (ids []int)
- func (m *ExternalReferenceMutation) ID() (id int, exists bool)
- func (m *ExternalReferenceMutation) IDs(ctx context.Context) ([]int, error)
- func (m *ExternalReferenceMutation) NodeCleared() bool
- func (m *ExternalReferenceMutation) NodeID() (id string, exists bool)
- func (m *ExternalReferenceMutation) NodeIDs() (ids []string)
- func (m *ExternalReferenceMutation) OldAuthority(ctx context.Context) (v string, err error)
- func (m *ExternalReferenceMutation) OldComment(ctx context.Context) (v string, err error)
- func (m *ExternalReferenceMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ExternalReferenceMutation) OldType(ctx context.Context) (v externalreference.Type, err error)
- func (m *ExternalReferenceMutation) OldURL(ctx context.Context) (v string, err error)
- func (m *ExternalReferenceMutation) Op() Op
- func (m *ExternalReferenceMutation) RemoveHashIDs(ids ...int)
- func (m *ExternalReferenceMutation) RemovedEdges() []string
- func (m *ExternalReferenceMutation) RemovedHashesIDs() (ids []int)
- func (m *ExternalReferenceMutation) RemovedIDs(name string) []ent.Value
- func (m *ExternalReferenceMutation) ResetAuthority()
- func (m *ExternalReferenceMutation) ResetComment()
- func (m *ExternalReferenceMutation) ResetEdge(name string) error
- func (m *ExternalReferenceMutation) ResetField(name string) error
- func (m *ExternalReferenceMutation) ResetHashes()
- func (m *ExternalReferenceMutation) ResetNode()
- func (m *ExternalReferenceMutation) ResetType()
- func (m *ExternalReferenceMutation) ResetURL()
- func (m *ExternalReferenceMutation) SetAuthority(s string)
- func (m *ExternalReferenceMutation) SetComment(s string)
- func (m *ExternalReferenceMutation) SetField(name string, value ent.Value) error
- func (m *ExternalReferenceMutation) SetNodeID(id string)
- func (m *ExternalReferenceMutation) SetOp(op Op)
- func (m *ExternalReferenceMutation) SetType(e externalreference.Type)
- func (m *ExternalReferenceMutation) SetURL(s string)
- func (m ExternalReferenceMutation) Tx() (*Tx, error)
- func (m *ExternalReferenceMutation) Type() string
- func (m *ExternalReferenceMutation) URL() (r string, exists bool)
- func (m *ExternalReferenceMutation) Where(ps ...predicate.ExternalReference)
- func (m *ExternalReferenceMutation) WhereP(ps ...func(*sql.Selector))
- type ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) Aggregate(fns ...AggregateFunc) *ExternalReferenceSelect
- func (erq *ExternalReferenceQuery) All(ctx context.Context) ([]*ExternalReference, error)
- func (erq *ExternalReferenceQuery) AllX(ctx context.Context) []*ExternalReference
- func (erq *ExternalReferenceQuery) Clone() *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) Count(ctx context.Context) (int, error)
- func (erq *ExternalReferenceQuery) CountX(ctx context.Context) int
- func (erq *ExternalReferenceQuery) Exist(ctx context.Context) (bool, error)
- func (erq *ExternalReferenceQuery) ExistX(ctx context.Context) bool
- func (erq *ExternalReferenceQuery) First(ctx context.Context) (*ExternalReference, error)
- func (erq *ExternalReferenceQuery) FirstID(ctx context.Context) (id int, err error)
- func (erq *ExternalReferenceQuery) FirstIDX(ctx context.Context) int
- func (erq *ExternalReferenceQuery) FirstX(ctx context.Context) *ExternalReference
- func (erq *ExternalReferenceQuery) GroupBy(field string, fields ...string) *ExternalReferenceGroupBy
- func (erq *ExternalReferenceQuery) IDs(ctx context.Context) (ids []int, err error)
- func (erq *ExternalReferenceQuery) IDsX(ctx context.Context) []int
- func (erq *ExternalReferenceQuery) Limit(limit int) *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) Offset(offset int) *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) Only(ctx context.Context) (*ExternalReference, error)
- func (erq *ExternalReferenceQuery) OnlyID(ctx context.Context) (id int, err error)
- func (erq *ExternalReferenceQuery) OnlyIDX(ctx context.Context) int
- func (erq *ExternalReferenceQuery) OnlyX(ctx context.Context) *ExternalReference
- func (erq *ExternalReferenceQuery) Order(o ...externalreference.OrderOption) *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) QueryHashes() *HashesEntryQuery
- func (erq *ExternalReferenceQuery) QueryNode() *NodeQuery
- func (erq *ExternalReferenceQuery) Select(fields ...string) *ExternalReferenceSelect
- func (erq *ExternalReferenceQuery) Unique(unique bool) *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) Where(ps ...predicate.ExternalReference) *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) WithHashes(opts ...func(*HashesEntryQuery)) *ExternalReferenceQuery
- func (erq *ExternalReferenceQuery) WithNode(opts ...func(*NodeQuery)) *ExternalReferenceQuery
- type ExternalReferenceSelect
- func (ers *ExternalReferenceSelect) Aggregate(fns ...AggregateFunc) *ExternalReferenceSelect
- func (s *ExternalReferenceSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *ExternalReferenceSelect) BoolX(ctx context.Context) bool
- func (s *ExternalReferenceSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *ExternalReferenceSelect) BoolsX(ctx context.Context) []bool
- func (s *ExternalReferenceSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *ExternalReferenceSelect) Float64X(ctx context.Context) float64
- func (s *ExternalReferenceSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *ExternalReferenceSelect) Float64sX(ctx context.Context) []float64
- func (s *ExternalReferenceSelect) Int(ctx context.Context) (_ int, err error)
- func (s *ExternalReferenceSelect) IntX(ctx context.Context) int
- func (s *ExternalReferenceSelect) Ints(ctx context.Context) ([]int, error)
- func (s *ExternalReferenceSelect) IntsX(ctx context.Context) []int
- func (ers *ExternalReferenceSelect) Scan(ctx context.Context, v any) error
- func (s *ExternalReferenceSelect) ScanX(ctx context.Context, v any)
- func (s *ExternalReferenceSelect) String(ctx context.Context) (_ string, err error)
- func (s *ExternalReferenceSelect) StringX(ctx context.Context) string
- func (s *ExternalReferenceSelect) Strings(ctx context.Context) ([]string, error)
- func (s *ExternalReferenceSelect) StringsX(ctx context.Context) []string
- type ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) AddHashIDs(ids ...int) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) AddHashes(h ...*HashesEntry) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) ClearAuthority() *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) ClearHashes() *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) ClearNode() *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) Exec(ctx context.Context) error
- func (eru *ExternalReferenceUpdate) ExecX(ctx context.Context)
- func (eru *ExternalReferenceUpdate) Mutation() *ExternalReferenceMutation
- func (eru *ExternalReferenceUpdate) RemoveHashIDs(ids ...int) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) RemoveHashes(h ...*HashesEntry) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) Save(ctx context.Context) (int, error)
- func (eru *ExternalReferenceUpdate) SaveX(ctx context.Context) int
- func (eru *ExternalReferenceUpdate) SetAuthority(s string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetComment(s string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetNillableAuthority(s *string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetNillableComment(s *string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetNillableType(e *externalreference.Type) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetNillableURL(s *string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetNode(n *Node) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetNodeID(id string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetType(e externalreference.Type) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) SetURL(s string) *ExternalReferenceUpdate
- func (eru *ExternalReferenceUpdate) Where(ps ...predicate.ExternalReference) *ExternalReferenceUpdate
- type ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) AddHashIDs(ids ...int) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) AddHashes(h ...*HashesEntry) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) ClearAuthority() *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) ClearHashes() *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) ClearNode() *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) Exec(ctx context.Context) error
- func (eruo *ExternalReferenceUpdateOne) ExecX(ctx context.Context)
- func (eruo *ExternalReferenceUpdateOne) Mutation() *ExternalReferenceMutation
- func (eruo *ExternalReferenceUpdateOne) RemoveHashIDs(ids ...int) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) RemoveHashes(h ...*HashesEntry) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) Save(ctx context.Context) (*ExternalReference, error)
- func (eruo *ExternalReferenceUpdateOne) SaveX(ctx context.Context) *ExternalReference
- func (eruo *ExternalReferenceUpdateOne) Select(field string, fields ...string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetAuthority(s string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetComment(s string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetNillableAuthority(s *string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetNillableComment(s *string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetNillableType(e *externalreference.Type) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetNillableURL(s *string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetNode(n *Node) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetNodeID(id string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetType(e externalreference.Type) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) SetURL(s string) *ExternalReferenceUpdateOne
- func (eruo *ExternalReferenceUpdateOne) Where(ps ...predicate.ExternalReference) *ExternalReferenceUpdateOne
- type ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) ClearAuthority() *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) SetAuthority(v string) *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) SetComment(v string) *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) SetType(v externalreference.Type) *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) SetURL(v string) *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) UpdateAuthority() *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) UpdateComment() *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) UpdateType() *ExternalReferenceUpsert
- func (u *ExternalReferenceUpsert) UpdateURL() *ExternalReferenceUpsert
- type ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) ClearAuthority() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) DoNothing() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) Exec(ctx context.Context) error
- func (u *ExternalReferenceUpsertBulk) ExecX(ctx context.Context)
- func (u *ExternalReferenceUpsertBulk) Ignore() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) SetAuthority(v string) *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) SetComment(v string) *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) SetType(v externalreference.Type) *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) SetURL(v string) *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) Update(set func(*ExternalReferenceUpsert)) *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) UpdateAuthority() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) UpdateComment() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) UpdateNewValues() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) UpdateType() *ExternalReferenceUpsertBulk
- func (u *ExternalReferenceUpsertBulk) UpdateURL() *ExternalReferenceUpsertBulk
- type ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) ClearAuthority() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) DoNothing() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) Exec(ctx context.Context) error
- func (u *ExternalReferenceUpsertOne) ExecX(ctx context.Context)
- func (u *ExternalReferenceUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *ExternalReferenceUpsertOne) IDX(ctx context.Context) int
- func (u *ExternalReferenceUpsertOne) Ignore() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) SetAuthority(v string) *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) SetComment(v string) *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) SetType(v externalreference.Type) *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) SetURL(v string) *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) Update(set func(*ExternalReferenceUpsert)) *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) UpdateAuthority() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) UpdateComment() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) UpdateNewValues() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) UpdateType() *ExternalReferenceUpsertOne
- func (u *ExternalReferenceUpsertOne) UpdateURL() *ExternalReferenceUpsertOne
- type ExternalReferences
- type HashesEntries
- type HashesEntry
- func (he *HashesEntry) QueryExternalReferences() *ExternalReferenceQuery
- func (he *HashesEntry) QueryNodes() *NodeQuery
- func (he *HashesEntry) String() string
- func (he *HashesEntry) Unwrap() *HashesEntry
- func (he *HashesEntry) Update() *HashesEntryUpdateOne
- func (he *HashesEntry) Value(name string) (ent.Value, error)
- type HashesEntryClient
- func (c *HashesEntryClient) Create() *HashesEntryCreate
- func (c *HashesEntryClient) CreateBulk(builders ...*HashesEntryCreate) *HashesEntryCreateBulk
- func (c *HashesEntryClient) Delete() *HashesEntryDelete
- func (c *HashesEntryClient) DeleteOne(he *HashesEntry) *HashesEntryDeleteOne
- func (c *HashesEntryClient) DeleteOneID(id int) *HashesEntryDeleteOne
- func (c *HashesEntryClient) Get(ctx context.Context, id int) (*HashesEntry, error)
- func (c *HashesEntryClient) GetX(ctx context.Context, id int) *HashesEntry
- func (c *HashesEntryClient) Hooks() []Hook
- func (c *HashesEntryClient) Intercept(interceptors ...Interceptor)
- func (c *HashesEntryClient) Interceptors() []Interceptor
- func (c *HashesEntryClient) MapCreateBulk(slice any, setFunc func(*HashesEntryCreate, int)) *HashesEntryCreateBulk
- func (c *HashesEntryClient) Query() *HashesEntryQuery
- func (c *HashesEntryClient) QueryExternalReferences(he *HashesEntry) *ExternalReferenceQuery
- func (c *HashesEntryClient) QueryNodes(he *HashesEntry) *NodeQuery
- func (c *HashesEntryClient) Update() *HashesEntryUpdate
- func (c *HashesEntryClient) UpdateOne(he *HashesEntry) *HashesEntryUpdateOne
- func (c *HashesEntryClient) UpdateOneID(id int) *HashesEntryUpdateOne
- func (c *HashesEntryClient) Use(hooks ...Hook)
- type HashesEntryCreate
- func (hec *HashesEntryCreate) Exec(ctx context.Context) error
- func (hec *HashesEntryCreate) ExecX(ctx context.Context)
- func (hec *HashesEntryCreate) Mutation() *HashesEntryMutation
- func (hec *HashesEntryCreate) OnConflict(opts ...sql.ConflictOption) *HashesEntryUpsertOne
- func (hec *HashesEntryCreate) OnConflictColumns(columns ...string) *HashesEntryUpsertOne
- func (hec *HashesEntryCreate) Save(ctx context.Context) (*HashesEntry, error)
- func (hec *HashesEntryCreate) SaveX(ctx context.Context) *HashesEntry
- func (hec *HashesEntryCreate) SetExternalReferences(e *ExternalReference) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetExternalReferencesID(id int) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetHashData(s string) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetNillableExternalReferencesID(id *int) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetNillableNodesID(id *string) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetNodes(n *Node) *HashesEntryCreate
- func (hec *HashesEntryCreate) SetNodesID(id string) *HashesEntryCreate
- type HashesEntryCreateBulk
- func (hecb *HashesEntryCreateBulk) Exec(ctx context.Context) error
- func (hecb *HashesEntryCreateBulk) ExecX(ctx context.Context)
- func (hecb *HashesEntryCreateBulk) OnConflict(opts ...sql.ConflictOption) *HashesEntryUpsertBulk
- func (hecb *HashesEntryCreateBulk) OnConflictColumns(columns ...string) *HashesEntryUpsertBulk
- func (hecb *HashesEntryCreateBulk) Save(ctx context.Context) ([]*HashesEntry, error)
- func (hecb *HashesEntryCreateBulk) SaveX(ctx context.Context) []*HashesEntry
- type HashesEntryDelete
- type HashesEntryDeleteOne
- type HashesEntryEdges
- type HashesEntryGroupBy
- func (hegb *HashesEntryGroupBy) Aggregate(fns ...AggregateFunc) *HashesEntryGroupBy
- func (s *HashesEntryGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *HashesEntryGroupBy) BoolX(ctx context.Context) bool
- func (s *HashesEntryGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *HashesEntryGroupBy) BoolsX(ctx context.Context) []bool
- func (s *HashesEntryGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *HashesEntryGroupBy) Float64X(ctx context.Context) float64
- func (s *HashesEntryGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *HashesEntryGroupBy) Float64sX(ctx context.Context) []float64
- func (s *HashesEntryGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *HashesEntryGroupBy) IntX(ctx context.Context) int
- func (s *HashesEntryGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *HashesEntryGroupBy) IntsX(ctx context.Context) []int
- func (hegb *HashesEntryGroupBy) Scan(ctx context.Context, v any) error
- func (s *HashesEntryGroupBy) ScanX(ctx context.Context, v any)
- func (s *HashesEntryGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *HashesEntryGroupBy) StringX(ctx context.Context) string
- func (s *HashesEntryGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *HashesEntryGroupBy) StringsX(ctx context.Context) []string
- type HashesEntryMutation
- func (m *HashesEntryMutation) AddField(name string, value ent.Value) error
- func (m *HashesEntryMutation) AddedEdges() []string
- func (m *HashesEntryMutation) AddedField(name string) (ent.Value, bool)
- func (m *HashesEntryMutation) AddedFields() []string
- func (m *HashesEntryMutation) AddedIDs(name string) []ent.Value
- func (m *HashesEntryMutation) ClearEdge(name string) error
- func (m *HashesEntryMutation) ClearExternalReferences()
- func (m *HashesEntryMutation) ClearField(name string) error
- func (m *HashesEntryMutation) ClearNodes()
- func (m *HashesEntryMutation) ClearedEdges() []string
- func (m *HashesEntryMutation) ClearedFields() []string
- func (m HashesEntryMutation) Client() *Client
- func (m *HashesEntryMutation) EdgeCleared(name string) bool
- func (m *HashesEntryMutation) ExternalReferencesCleared() bool
- func (m *HashesEntryMutation) ExternalReferencesID() (id int, exists bool)
- func (m *HashesEntryMutation) ExternalReferencesIDs() (ids []int)
- func (m *HashesEntryMutation) Field(name string) (ent.Value, bool)
- func (m *HashesEntryMutation) FieldCleared(name string) bool
- func (m *HashesEntryMutation) Fields() []string
- func (m *HashesEntryMutation) HashAlgorithmType() (r hashesentry.HashAlgorithmType, exists bool)
- func (m *HashesEntryMutation) HashData() (r string, exists bool)
- func (m *HashesEntryMutation) ID() (id int, exists bool)
- func (m *HashesEntryMutation) IDs(ctx context.Context) ([]int, error)
- func (m *HashesEntryMutation) NodesCleared() bool
- func (m *HashesEntryMutation) NodesID() (id string, exists bool)
- func (m *HashesEntryMutation) NodesIDs() (ids []string)
- func (m *HashesEntryMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *HashesEntryMutation) OldHashAlgorithmType(ctx context.Context) (v hashesentry.HashAlgorithmType, err error)
- func (m *HashesEntryMutation) OldHashData(ctx context.Context) (v string, err error)
- func (m *HashesEntryMutation) Op() Op
- func (m *HashesEntryMutation) RemovedEdges() []string
- func (m *HashesEntryMutation) RemovedIDs(name string) []ent.Value
- func (m *HashesEntryMutation) ResetEdge(name string) error
- func (m *HashesEntryMutation) ResetExternalReferences()
- func (m *HashesEntryMutation) ResetField(name string) error
- func (m *HashesEntryMutation) ResetHashAlgorithmType()
- func (m *HashesEntryMutation) ResetHashData()
- func (m *HashesEntryMutation) ResetNodes()
- func (m *HashesEntryMutation) SetExternalReferencesID(id int)
- func (m *HashesEntryMutation) SetField(name string, value ent.Value) error
- func (m *HashesEntryMutation) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType)
- func (m *HashesEntryMutation) SetHashData(s string)
- func (m *HashesEntryMutation) SetNodesID(id string)
- func (m *HashesEntryMutation) SetOp(op Op)
- func (m HashesEntryMutation) Tx() (*Tx, error)
- func (m *HashesEntryMutation) Type() string
- func (m *HashesEntryMutation) Where(ps ...predicate.HashesEntry)
- func (m *HashesEntryMutation) WhereP(ps ...func(*sql.Selector))
- type HashesEntryQuery
- func (heq *HashesEntryQuery) Aggregate(fns ...AggregateFunc) *HashesEntrySelect
- func (heq *HashesEntryQuery) All(ctx context.Context) ([]*HashesEntry, error)
- func (heq *HashesEntryQuery) AllX(ctx context.Context) []*HashesEntry
- func (heq *HashesEntryQuery) Clone() *HashesEntryQuery
- func (heq *HashesEntryQuery) Count(ctx context.Context) (int, error)
- func (heq *HashesEntryQuery) CountX(ctx context.Context) int
- func (heq *HashesEntryQuery) Exist(ctx context.Context) (bool, error)
- func (heq *HashesEntryQuery) ExistX(ctx context.Context) bool
- func (heq *HashesEntryQuery) First(ctx context.Context) (*HashesEntry, error)
- func (heq *HashesEntryQuery) FirstID(ctx context.Context) (id int, err error)
- func (heq *HashesEntryQuery) FirstIDX(ctx context.Context) int
- func (heq *HashesEntryQuery) FirstX(ctx context.Context) *HashesEntry
- func (heq *HashesEntryQuery) GroupBy(field string, fields ...string) *HashesEntryGroupBy
- func (heq *HashesEntryQuery) IDs(ctx context.Context) (ids []int, err error)
- func (heq *HashesEntryQuery) IDsX(ctx context.Context) []int
- func (heq *HashesEntryQuery) Limit(limit int) *HashesEntryQuery
- func (heq *HashesEntryQuery) Offset(offset int) *HashesEntryQuery
- func (heq *HashesEntryQuery) Only(ctx context.Context) (*HashesEntry, error)
- func (heq *HashesEntryQuery) OnlyID(ctx context.Context) (id int, err error)
- func (heq *HashesEntryQuery) OnlyIDX(ctx context.Context) int
- func (heq *HashesEntryQuery) OnlyX(ctx context.Context) *HashesEntry
- func (heq *HashesEntryQuery) Order(o ...hashesentry.OrderOption) *HashesEntryQuery
- func (heq *HashesEntryQuery) QueryExternalReferences() *ExternalReferenceQuery
- func (heq *HashesEntryQuery) QueryNodes() *NodeQuery
- func (heq *HashesEntryQuery) Select(fields ...string) *HashesEntrySelect
- func (heq *HashesEntryQuery) Unique(unique bool) *HashesEntryQuery
- func (heq *HashesEntryQuery) Where(ps ...predicate.HashesEntry) *HashesEntryQuery
- func (heq *HashesEntryQuery) WithExternalReferences(opts ...func(*ExternalReferenceQuery)) *HashesEntryQuery
- func (heq *HashesEntryQuery) WithNodes(opts ...func(*NodeQuery)) *HashesEntryQuery
- type HashesEntrySelect
- func (hes *HashesEntrySelect) Aggregate(fns ...AggregateFunc) *HashesEntrySelect
- func (s *HashesEntrySelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *HashesEntrySelect) BoolX(ctx context.Context) bool
- func (s *HashesEntrySelect) Bools(ctx context.Context) ([]bool, error)
- func (s *HashesEntrySelect) BoolsX(ctx context.Context) []bool
- func (s *HashesEntrySelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *HashesEntrySelect) Float64X(ctx context.Context) float64
- func (s *HashesEntrySelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *HashesEntrySelect) Float64sX(ctx context.Context) []float64
- func (s *HashesEntrySelect) Int(ctx context.Context) (_ int, err error)
- func (s *HashesEntrySelect) IntX(ctx context.Context) int
- func (s *HashesEntrySelect) Ints(ctx context.Context) ([]int, error)
- func (s *HashesEntrySelect) IntsX(ctx context.Context) []int
- func (hes *HashesEntrySelect) Scan(ctx context.Context, v any) error
- func (s *HashesEntrySelect) ScanX(ctx context.Context, v any)
- func (s *HashesEntrySelect) String(ctx context.Context) (_ string, err error)
- func (s *HashesEntrySelect) StringX(ctx context.Context) string
- func (s *HashesEntrySelect) Strings(ctx context.Context) ([]string, error)
- func (s *HashesEntrySelect) StringsX(ctx context.Context) []string
- type HashesEntryUpdate
- func (heu *HashesEntryUpdate) ClearExternalReferences() *HashesEntryUpdate
- func (heu *HashesEntryUpdate) ClearNodes() *HashesEntryUpdate
- func (heu *HashesEntryUpdate) Exec(ctx context.Context) error
- func (heu *HashesEntryUpdate) ExecX(ctx context.Context)
- func (heu *HashesEntryUpdate) Mutation() *HashesEntryMutation
- func (heu *HashesEntryUpdate) Save(ctx context.Context) (int, error)
- func (heu *HashesEntryUpdate) SaveX(ctx context.Context) int
- func (heu *HashesEntryUpdate) SetExternalReferences(e *ExternalReference) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetExternalReferencesID(id int) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetHashData(s string) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetNillableExternalReferencesID(id *int) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetNillableHashAlgorithmType(hat *hashesentry.HashAlgorithmType) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetNillableHashData(s *string) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetNillableNodesID(id *string) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetNodes(n *Node) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) SetNodesID(id string) *HashesEntryUpdate
- func (heu *HashesEntryUpdate) Where(ps ...predicate.HashesEntry) *HashesEntryUpdate
- type HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) ClearExternalReferences() *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) ClearNodes() *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) Exec(ctx context.Context) error
- func (heuo *HashesEntryUpdateOne) ExecX(ctx context.Context)
- func (heuo *HashesEntryUpdateOne) Mutation() *HashesEntryMutation
- func (heuo *HashesEntryUpdateOne) Save(ctx context.Context) (*HashesEntry, error)
- func (heuo *HashesEntryUpdateOne) SaveX(ctx context.Context) *HashesEntry
- func (heuo *HashesEntryUpdateOne) Select(field string, fields ...string) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetExternalReferences(e *ExternalReference) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetExternalReferencesID(id int) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetHashData(s string) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetNillableExternalReferencesID(id *int) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetNillableHashAlgorithmType(hat *hashesentry.HashAlgorithmType) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetNillableHashData(s *string) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetNillableNodesID(id *string) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetNodes(n *Node) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) SetNodesID(id string) *HashesEntryUpdateOne
- func (heuo *HashesEntryUpdateOne) Where(ps ...predicate.HashesEntry) *HashesEntryUpdateOne
- type HashesEntryUpsert
- func (u *HashesEntryUpsert) SetHashAlgorithmType(v hashesentry.HashAlgorithmType) *HashesEntryUpsert
- func (u *HashesEntryUpsert) SetHashData(v string) *HashesEntryUpsert
- func (u *HashesEntryUpsert) UpdateHashAlgorithmType() *HashesEntryUpsert
- func (u *HashesEntryUpsert) UpdateHashData() *HashesEntryUpsert
- type HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) DoNothing() *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) Exec(ctx context.Context) error
- func (u *HashesEntryUpsertBulk) ExecX(ctx context.Context)
- func (u *HashesEntryUpsertBulk) Ignore() *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) SetHashAlgorithmType(v hashesentry.HashAlgorithmType) *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) SetHashData(v string) *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) Update(set func(*HashesEntryUpsert)) *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) UpdateHashAlgorithmType() *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) UpdateHashData() *HashesEntryUpsertBulk
- func (u *HashesEntryUpsertBulk) UpdateNewValues() *HashesEntryUpsertBulk
- type HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) DoNothing() *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) Exec(ctx context.Context) error
- func (u *HashesEntryUpsertOne) ExecX(ctx context.Context)
- func (u *HashesEntryUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *HashesEntryUpsertOne) IDX(ctx context.Context) int
- func (u *HashesEntryUpsertOne) Ignore() *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) SetHashAlgorithmType(v hashesentry.HashAlgorithmType) *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) SetHashData(v string) *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) Update(set func(*HashesEntryUpsert)) *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) UpdateHashAlgorithmType() *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) UpdateHashData() *HashesEntryUpsertOne
- func (u *HashesEntryUpsertOne) UpdateNewValues() *HashesEntryUpsertOne
- type Hook
- type IdentifiersEntries
- type IdentifiersEntry
- type IdentifiersEntryClient
- func (c *IdentifiersEntryClient) Create() *IdentifiersEntryCreate
- func (c *IdentifiersEntryClient) CreateBulk(builders ...*IdentifiersEntryCreate) *IdentifiersEntryCreateBulk
- func (c *IdentifiersEntryClient) Delete() *IdentifiersEntryDelete
- func (c *IdentifiersEntryClient) DeleteOne(ie *IdentifiersEntry) *IdentifiersEntryDeleteOne
- func (c *IdentifiersEntryClient) DeleteOneID(id int) *IdentifiersEntryDeleteOne
- func (c *IdentifiersEntryClient) Get(ctx context.Context, id int) (*IdentifiersEntry, error)
- func (c *IdentifiersEntryClient) GetX(ctx context.Context, id int) *IdentifiersEntry
- func (c *IdentifiersEntryClient) Hooks() []Hook
- func (c *IdentifiersEntryClient) Intercept(interceptors ...Interceptor)
- func (c *IdentifiersEntryClient) Interceptors() []Interceptor
- func (c *IdentifiersEntryClient) MapCreateBulk(slice any, setFunc func(*IdentifiersEntryCreate, int)) *IdentifiersEntryCreateBulk
- func (c *IdentifiersEntryClient) Query() *IdentifiersEntryQuery
- func (c *IdentifiersEntryClient) QueryNodes(ie *IdentifiersEntry) *NodeQuery
- func (c *IdentifiersEntryClient) Update() *IdentifiersEntryUpdate
- func (c *IdentifiersEntryClient) UpdateOne(ie *IdentifiersEntry) *IdentifiersEntryUpdateOne
- func (c *IdentifiersEntryClient) UpdateOneID(id int) *IdentifiersEntryUpdateOne
- func (c *IdentifiersEntryClient) Use(hooks ...Hook)
- type IdentifiersEntryCreate
- func (iec *IdentifiersEntryCreate) Exec(ctx context.Context) error
- func (iec *IdentifiersEntryCreate) ExecX(ctx context.Context)
- func (iec *IdentifiersEntryCreate) Mutation() *IdentifiersEntryMutation
- func (iec *IdentifiersEntryCreate) OnConflict(opts ...sql.ConflictOption) *IdentifiersEntryUpsertOne
- func (iec *IdentifiersEntryCreate) OnConflictColumns(columns ...string) *IdentifiersEntryUpsertOne
- func (iec *IdentifiersEntryCreate) Save(ctx context.Context) (*IdentifiersEntry, error)
- func (iec *IdentifiersEntryCreate) SaveX(ctx context.Context) *IdentifiersEntry
- func (iec *IdentifiersEntryCreate) SetNillableNodesID(id *string) *IdentifiersEntryCreate
- func (iec *IdentifiersEntryCreate) SetNodes(n *Node) *IdentifiersEntryCreate
- func (iec *IdentifiersEntryCreate) SetNodesID(id string) *IdentifiersEntryCreate
- func (iec *IdentifiersEntryCreate) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType) *IdentifiersEntryCreate
- func (iec *IdentifiersEntryCreate) SetSoftwareIdentifierValue(s string) *IdentifiersEntryCreate
- type IdentifiersEntryCreateBulk
- func (iecb *IdentifiersEntryCreateBulk) Exec(ctx context.Context) error
- func (iecb *IdentifiersEntryCreateBulk) ExecX(ctx context.Context)
- func (iecb *IdentifiersEntryCreateBulk) OnConflict(opts ...sql.ConflictOption) *IdentifiersEntryUpsertBulk
- func (iecb *IdentifiersEntryCreateBulk) OnConflictColumns(columns ...string) *IdentifiersEntryUpsertBulk
- func (iecb *IdentifiersEntryCreateBulk) Save(ctx context.Context) ([]*IdentifiersEntry, error)
- func (iecb *IdentifiersEntryCreateBulk) SaveX(ctx context.Context) []*IdentifiersEntry
- type IdentifiersEntryDelete
- type IdentifiersEntryDeleteOne
- type IdentifiersEntryEdges
- type IdentifiersEntryGroupBy
- func (iegb *IdentifiersEntryGroupBy) Aggregate(fns ...AggregateFunc) *IdentifiersEntryGroupBy
- func (s *IdentifiersEntryGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *IdentifiersEntryGroupBy) BoolX(ctx context.Context) bool
- func (s *IdentifiersEntryGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *IdentifiersEntryGroupBy) BoolsX(ctx context.Context) []bool
- func (s *IdentifiersEntryGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *IdentifiersEntryGroupBy) Float64X(ctx context.Context) float64
- func (s *IdentifiersEntryGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *IdentifiersEntryGroupBy) Float64sX(ctx context.Context) []float64
- func (s *IdentifiersEntryGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *IdentifiersEntryGroupBy) IntX(ctx context.Context) int
- func (s *IdentifiersEntryGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *IdentifiersEntryGroupBy) IntsX(ctx context.Context) []int
- func (iegb *IdentifiersEntryGroupBy) Scan(ctx context.Context, v any) error
- func (s *IdentifiersEntryGroupBy) ScanX(ctx context.Context, v any)
- func (s *IdentifiersEntryGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *IdentifiersEntryGroupBy) StringX(ctx context.Context) string
- func (s *IdentifiersEntryGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *IdentifiersEntryGroupBy) StringsX(ctx context.Context) []string
- type IdentifiersEntryMutation
- func (m *IdentifiersEntryMutation) AddField(name string, value ent.Value) error
- func (m *IdentifiersEntryMutation) AddedEdges() []string
- func (m *IdentifiersEntryMutation) AddedField(name string) (ent.Value, bool)
- func (m *IdentifiersEntryMutation) AddedFields() []string
- func (m *IdentifiersEntryMutation) AddedIDs(name string) []ent.Value
- func (m *IdentifiersEntryMutation) ClearEdge(name string) error
- func (m *IdentifiersEntryMutation) ClearField(name string) error
- func (m *IdentifiersEntryMutation) ClearNodes()
- func (m *IdentifiersEntryMutation) ClearedEdges() []string
- func (m *IdentifiersEntryMutation) ClearedFields() []string
- func (m IdentifiersEntryMutation) Client() *Client
- func (m *IdentifiersEntryMutation) EdgeCleared(name string) bool
- func (m *IdentifiersEntryMutation) Field(name string) (ent.Value, bool)
- func (m *IdentifiersEntryMutation) FieldCleared(name string) bool
- func (m *IdentifiersEntryMutation) Fields() []string
- func (m *IdentifiersEntryMutation) ID() (id int, exists bool)
- func (m *IdentifiersEntryMutation) IDs(ctx context.Context) ([]int, error)
- func (m *IdentifiersEntryMutation) NodesCleared() bool
- func (m *IdentifiersEntryMutation) NodesID() (id string, exists bool)
- func (m *IdentifiersEntryMutation) NodesIDs() (ids []string)
- func (m *IdentifiersEntryMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *IdentifiersEntryMutation) OldSoftwareIdentifierType(ctx context.Context) (v identifiersentry.SoftwareIdentifierType, err error)
- func (m *IdentifiersEntryMutation) OldSoftwareIdentifierValue(ctx context.Context) (v string, err error)
- func (m *IdentifiersEntryMutation) Op() Op
- func (m *IdentifiersEntryMutation) RemovedEdges() []string
- func (m *IdentifiersEntryMutation) RemovedIDs(name string) []ent.Value
- func (m *IdentifiersEntryMutation) ResetEdge(name string) error
- func (m *IdentifiersEntryMutation) ResetField(name string) error
- func (m *IdentifiersEntryMutation) ResetNodes()
- func (m *IdentifiersEntryMutation) ResetSoftwareIdentifierType()
- func (m *IdentifiersEntryMutation) ResetSoftwareIdentifierValue()
- func (m *IdentifiersEntryMutation) SetField(name string, value ent.Value) error
- func (m *IdentifiersEntryMutation) SetNodesID(id string)
- func (m *IdentifiersEntryMutation) SetOp(op Op)
- func (m *IdentifiersEntryMutation) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType)
- func (m *IdentifiersEntryMutation) SetSoftwareIdentifierValue(s string)
- func (m *IdentifiersEntryMutation) SoftwareIdentifierType() (r identifiersentry.SoftwareIdentifierType, exists bool)
- func (m *IdentifiersEntryMutation) SoftwareIdentifierValue() (r string, exists bool)
- func (m IdentifiersEntryMutation) Tx() (*Tx, error)
- func (m *IdentifiersEntryMutation) Type() string
- func (m *IdentifiersEntryMutation) Where(ps ...predicate.IdentifiersEntry)
- func (m *IdentifiersEntryMutation) WhereP(ps ...func(*sql.Selector))
- type IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) Aggregate(fns ...AggregateFunc) *IdentifiersEntrySelect
- func (ieq *IdentifiersEntryQuery) All(ctx context.Context) ([]*IdentifiersEntry, error)
- func (ieq *IdentifiersEntryQuery) AllX(ctx context.Context) []*IdentifiersEntry
- func (ieq *IdentifiersEntryQuery) Clone() *IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) Count(ctx context.Context) (int, error)
- func (ieq *IdentifiersEntryQuery) CountX(ctx context.Context) int
- func (ieq *IdentifiersEntryQuery) Exist(ctx context.Context) (bool, error)
- func (ieq *IdentifiersEntryQuery) ExistX(ctx context.Context) bool
- func (ieq *IdentifiersEntryQuery) First(ctx context.Context) (*IdentifiersEntry, error)
- func (ieq *IdentifiersEntryQuery) FirstID(ctx context.Context) (id int, err error)
- func (ieq *IdentifiersEntryQuery) FirstIDX(ctx context.Context) int
- func (ieq *IdentifiersEntryQuery) FirstX(ctx context.Context) *IdentifiersEntry
- func (ieq *IdentifiersEntryQuery) GroupBy(field string, fields ...string) *IdentifiersEntryGroupBy
- func (ieq *IdentifiersEntryQuery) IDs(ctx context.Context) (ids []int, err error)
- func (ieq *IdentifiersEntryQuery) IDsX(ctx context.Context) []int
- func (ieq *IdentifiersEntryQuery) Limit(limit int) *IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) Offset(offset int) *IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) Only(ctx context.Context) (*IdentifiersEntry, error)
- func (ieq *IdentifiersEntryQuery) OnlyID(ctx context.Context) (id int, err error)
- func (ieq *IdentifiersEntryQuery) OnlyIDX(ctx context.Context) int
- func (ieq *IdentifiersEntryQuery) OnlyX(ctx context.Context) *IdentifiersEntry
- func (ieq *IdentifiersEntryQuery) Order(o ...identifiersentry.OrderOption) *IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) QueryNodes() *NodeQuery
- func (ieq *IdentifiersEntryQuery) Select(fields ...string) *IdentifiersEntrySelect
- func (ieq *IdentifiersEntryQuery) Unique(unique bool) *IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryQuery
- func (ieq *IdentifiersEntryQuery) WithNodes(opts ...func(*NodeQuery)) *IdentifiersEntryQuery
- type IdentifiersEntrySelect
- func (ies *IdentifiersEntrySelect) Aggregate(fns ...AggregateFunc) *IdentifiersEntrySelect
- func (s *IdentifiersEntrySelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *IdentifiersEntrySelect) BoolX(ctx context.Context) bool
- func (s *IdentifiersEntrySelect) Bools(ctx context.Context) ([]bool, error)
- func (s *IdentifiersEntrySelect) BoolsX(ctx context.Context) []bool
- func (s *IdentifiersEntrySelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *IdentifiersEntrySelect) Float64X(ctx context.Context) float64
- func (s *IdentifiersEntrySelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *IdentifiersEntrySelect) Float64sX(ctx context.Context) []float64
- func (s *IdentifiersEntrySelect) Int(ctx context.Context) (_ int, err error)
- func (s *IdentifiersEntrySelect) IntX(ctx context.Context) int
- func (s *IdentifiersEntrySelect) Ints(ctx context.Context) ([]int, error)
- func (s *IdentifiersEntrySelect) IntsX(ctx context.Context) []int
- func (ies *IdentifiersEntrySelect) Scan(ctx context.Context, v any) error
- func (s *IdentifiersEntrySelect) ScanX(ctx context.Context, v any)
- func (s *IdentifiersEntrySelect) String(ctx context.Context) (_ string, err error)
- func (s *IdentifiersEntrySelect) StringX(ctx context.Context) string
- func (s *IdentifiersEntrySelect) Strings(ctx context.Context) ([]string, error)
- func (s *IdentifiersEntrySelect) StringsX(ctx context.Context) []string
- type IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) ClearNodes() *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) Exec(ctx context.Context) error
- func (ieu *IdentifiersEntryUpdate) ExecX(ctx context.Context)
- func (ieu *IdentifiersEntryUpdate) Mutation() *IdentifiersEntryMutation
- func (ieu *IdentifiersEntryUpdate) Save(ctx context.Context) (int, error)
- func (ieu *IdentifiersEntryUpdate) SaveX(ctx context.Context) int
- func (ieu *IdentifiersEntryUpdate) SetNillableNodesID(id *string) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) SetNillableSoftwareIdentifierType(iit *identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) SetNillableSoftwareIdentifierValue(s *string) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) SetNodes(n *Node) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) SetNodesID(id string) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) SetSoftwareIdentifierValue(s string) *IdentifiersEntryUpdate
- func (ieu *IdentifiersEntryUpdate) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryUpdate
- type IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) ClearNodes() *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) Exec(ctx context.Context) error
- func (ieuo *IdentifiersEntryUpdateOne) ExecX(ctx context.Context)
- func (ieuo *IdentifiersEntryUpdateOne) Mutation() *IdentifiersEntryMutation
- func (ieuo *IdentifiersEntryUpdateOne) Save(ctx context.Context) (*IdentifiersEntry, error)
- func (ieuo *IdentifiersEntryUpdateOne) SaveX(ctx context.Context) *IdentifiersEntry
- func (ieuo *IdentifiersEntryUpdateOne) Select(field string, fields ...string) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetNillableNodesID(id *string) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetNillableSoftwareIdentifierType(iit *identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetNillableSoftwareIdentifierValue(s *string) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetNodes(n *Node) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetNodesID(id string) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) SetSoftwareIdentifierValue(s string) *IdentifiersEntryUpdateOne
- func (ieuo *IdentifiersEntryUpdateOne) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryUpdateOne
- type IdentifiersEntryUpsert
- func (u *IdentifiersEntryUpsert) SetSoftwareIdentifierType(v identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpsert
- func (u *IdentifiersEntryUpsert) SetSoftwareIdentifierValue(v string) *IdentifiersEntryUpsert
- func (u *IdentifiersEntryUpsert) UpdateSoftwareIdentifierType() *IdentifiersEntryUpsert
- func (u *IdentifiersEntryUpsert) UpdateSoftwareIdentifierValue() *IdentifiersEntryUpsert
- type IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) DoNothing() *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) Exec(ctx context.Context) error
- func (u *IdentifiersEntryUpsertBulk) ExecX(ctx context.Context)
- func (u *IdentifiersEntryUpsertBulk) Ignore() *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) SetSoftwareIdentifierType(v identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) SetSoftwareIdentifierValue(v string) *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) Update(set func(*IdentifiersEntryUpsert)) *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) UpdateNewValues() *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) UpdateSoftwareIdentifierType() *IdentifiersEntryUpsertBulk
- func (u *IdentifiersEntryUpsertBulk) UpdateSoftwareIdentifierValue() *IdentifiersEntryUpsertBulk
- type IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) DoNothing() *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) Exec(ctx context.Context) error
- func (u *IdentifiersEntryUpsertOne) ExecX(ctx context.Context)
- func (u *IdentifiersEntryUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *IdentifiersEntryUpsertOne) IDX(ctx context.Context) int
- func (u *IdentifiersEntryUpsertOne) Ignore() *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) SetSoftwareIdentifierType(v identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) SetSoftwareIdentifierValue(v string) *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) Update(set func(*IdentifiersEntryUpsert)) *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) UpdateNewValues() *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) UpdateSoftwareIdentifierType() *IdentifiersEntryUpsertOne
- func (u *IdentifiersEntryUpsertOne) UpdateSoftwareIdentifierValue() *IdentifiersEntryUpsertOne
- type InterceptFunc
- type Interceptor
- type Metadata
- func (m *Metadata) QueryAuthors() *PersonQuery
- func (m *Metadata) QueryDocument() *DocumentQuery
- func (m *Metadata) QueryDocumentTypes() *DocumentTypeQuery
- func (m *Metadata) QueryTools() *ToolQuery
- func (m *Metadata) String() string
- func (m *Metadata) Unwrap() *Metadata
- func (m *Metadata) Update() *MetadataUpdateOne
- func (m *Metadata) Value(name string) (ent.Value, error)
- type MetadataClient
- func (c *MetadataClient) Create() *MetadataCreate
- func (c *MetadataClient) CreateBulk(builders ...*MetadataCreate) *MetadataCreateBulk
- func (c *MetadataClient) Delete() *MetadataDelete
- func (c *MetadataClient) DeleteOne(m *Metadata) *MetadataDeleteOne
- func (c *MetadataClient) DeleteOneID(id string) *MetadataDeleteOne
- func (c *MetadataClient) Get(ctx context.Context, id string) (*Metadata, error)
- func (c *MetadataClient) GetX(ctx context.Context, id string) *Metadata
- func (c *MetadataClient) Hooks() []Hook
- func (c *MetadataClient) Intercept(interceptors ...Interceptor)
- func (c *MetadataClient) Interceptors() []Interceptor
- func (c *MetadataClient) MapCreateBulk(slice any, setFunc func(*MetadataCreate, int)) *MetadataCreateBulk
- func (c *MetadataClient) Query() *MetadataQuery
- func (c *MetadataClient) QueryAuthors(m *Metadata) *PersonQuery
- func (c *MetadataClient) QueryDocument(m *Metadata) *DocumentQuery
- func (c *MetadataClient) QueryDocumentTypes(m *Metadata) *DocumentTypeQuery
- func (c *MetadataClient) QueryTools(m *Metadata) *ToolQuery
- func (c *MetadataClient) Update() *MetadataUpdate
- func (c *MetadataClient) UpdateOne(m *Metadata) *MetadataUpdateOne
- func (c *MetadataClient) UpdateOneID(id string) *MetadataUpdateOne
- func (c *MetadataClient) Use(hooks ...Hook)
- type MetadataCreate
- func (mc *MetadataCreate) AddAuthorIDs(ids ...int) *MetadataCreate
- func (mc *MetadataCreate) AddAuthors(p ...*Person) *MetadataCreate
- func (mc *MetadataCreate) AddDocumentTypeIDs(ids ...int) *MetadataCreate
- func (mc *MetadataCreate) AddDocumentTypes(d ...*DocumentType) *MetadataCreate
- func (mc *MetadataCreate) AddToolIDs(ids ...int) *MetadataCreate
- func (mc *MetadataCreate) AddTools(t ...*Tool) *MetadataCreate
- func (mc *MetadataCreate) Exec(ctx context.Context) error
- func (mc *MetadataCreate) ExecX(ctx context.Context)
- func (mc *MetadataCreate) Mutation() *MetadataMutation
- func (mc *MetadataCreate) OnConflict(opts ...sql.ConflictOption) *MetadataUpsertOne
- func (mc *MetadataCreate) OnConflictColumns(columns ...string) *MetadataUpsertOne
- func (mc *MetadataCreate) Save(ctx context.Context) (*Metadata, error)
- func (mc *MetadataCreate) SaveX(ctx context.Context) *Metadata
- func (mc *MetadataCreate) SetComment(s string) *MetadataCreate
- func (mc *MetadataCreate) SetDate(t time.Time) *MetadataCreate
- func (mc *MetadataCreate) SetDocument(d *Document) *MetadataCreate
- func (mc *MetadataCreate) SetDocumentID(id int) *MetadataCreate
- func (mc *MetadataCreate) SetID(s string) *MetadataCreate
- func (mc *MetadataCreate) SetName(s string) *MetadataCreate
- func (mc *MetadataCreate) SetNillableDocumentID(id *int) *MetadataCreate
- func (mc *MetadataCreate) SetVersion(s string) *MetadataCreate
- type MetadataCreateBulk
- func (mcb *MetadataCreateBulk) Exec(ctx context.Context) error
- func (mcb *MetadataCreateBulk) ExecX(ctx context.Context)
- func (mcb *MetadataCreateBulk) OnConflict(opts ...sql.ConflictOption) *MetadataUpsertBulk
- func (mcb *MetadataCreateBulk) OnConflictColumns(columns ...string) *MetadataUpsertBulk
- func (mcb *MetadataCreateBulk) Save(ctx context.Context) ([]*Metadata, error)
- func (mcb *MetadataCreateBulk) SaveX(ctx context.Context) []*Metadata
- type MetadataDelete
- type MetadataDeleteOne
- type MetadataEdges
- type MetadataGroupBy
- func (mgb *MetadataGroupBy) Aggregate(fns ...AggregateFunc) *MetadataGroupBy
- func (s *MetadataGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *MetadataGroupBy) BoolX(ctx context.Context) bool
- func (s *MetadataGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *MetadataGroupBy) BoolsX(ctx context.Context) []bool
- func (s *MetadataGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *MetadataGroupBy) Float64X(ctx context.Context) float64
- func (s *MetadataGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *MetadataGroupBy) Float64sX(ctx context.Context) []float64
- func (s *MetadataGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *MetadataGroupBy) IntX(ctx context.Context) int
- func (s *MetadataGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *MetadataGroupBy) IntsX(ctx context.Context) []int
- func (mgb *MetadataGroupBy) Scan(ctx context.Context, v any) error
- func (s *MetadataGroupBy) ScanX(ctx context.Context, v any)
- func (s *MetadataGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *MetadataGroupBy) StringX(ctx context.Context) string
- func (s *MetadataGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *MetadataGroupBy) StringsX(ctx context.Context) []string
- type MetadataMutation
- func (m *MetadataMutation) AddAuthorIDs(ids ...int)
- func (m *MetadataMutation) AddDocumentTypeIDs(ids ...int)
- func (m *MetadataMutation) AddField(name string, value ent.Value) error
- func (m *MetadataMutation) AddToolIDs(ids ...int)
- func (m *MetadataMutation) AddedEdges() []string
- func (m *MetadataMutation) AddedField(name string) (ent.Value, bool)
- func (m *MetadataMutation) AddedFields() []string
- func (m *MetadataMutation) AddedIDs(name string) []ent.Value
- func (m *MetadataMutation) AuthorsCleared() bool
- func (m *MetadataMutation) AuthorsIDs() (ids []int)
- func (m *MetadataMutation) ClearAuthors()
- func (m *MetadataMutation) ClearDocument()
- func (m *MetadataMutation) ClearDocumentTypes()
- func (m *MetadataMutation) ClearEdge(name string) error
- func (m *MetadataMutation) ClearField(name string) error
- func (m *MetadataMutation) ClearTools()
- func (m *MetadataMutation) ClearedEdges() []string
- func (m *MetadataMutation) ClearedFields() []string
- func (m MetadataMutation) Client() *Client
- func (m *MetadataMutation) Comment() (r string, exists bool)
- func (m *MetadataMutation) Date() (r time.Time, exists bool)
- func (m *MetadataMutation) DocumentCleared() bool
- func (m *MetadataMutation) DocumentID() (id int, exists bool)
- func (m *MetadataMutation) DocumentIDs() (ids []int)
- func (m *MetadataMutation) DocumentTypesCleared() bool
- func (m *MetadataMutation) DocumentTypesIDs() (ids []int)
- func (m *MetadataMutation) EdgeCleared(name string) bool
- func (m *MetadataMutation) Field(name string) (ent.Value, bool)
- func (m *MetadataMutation) FieldCleared(name string) bool
- func (m *MetadataMutation) Fields() []string
- func (m *MetadataMutation) ID() (id string, exists bool)
- func (m *MetadataMutation) IDs(ctx context.Context) ([]string, error)
- func (m *MetadataMutation) Name() (r string, exists bool)
- func (m *MetadataMutation) OldComment(ctx context.Context) (v string, err error)
- func (m *MetadataMutation) OldDate(ctx context.Context) (v time.Time, err error)
- func (m *MetadataMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *MetadataMutation) OldName(ctx context.Context) (v string, err error)
- func (m *MetadataMutation) OldVersion(ctx context.Context) (v string, err error)
- func (m *MetadataMutation) Op() Op
- func (m *MetadataMutation) RemoveAuthorIDs(ids ...int)
- func (m *MetadataMutation) RemoveDocumentTypeIDs(ids ...int)
- func (m *MetadataMutation) RemoveToolIDs(ids ...int)
- func (m *MetadataMutation) RemovedAuthorsIDs() (ids []int)
- func (m *MetadataMutation) RemovedDocumentTypesIDs() (ids []int)
- func (m *MetadataMutation) RemovedEdges() []string
- func (m *MetadataMutation) RemovedIDs(name string) []ent.Value
- func (m *MetadataMutation) RemovedToolsIDs() (ids []int)
- func (m *MetadataMutation) ResetAuthors()
- func (m *MetadataMutation) ResetComment()
- func (m *MetadataMutation) ResetDate()
- func (m *MetadataMutation) ResetDocument()
- func (m *MetadataMutation) ResetDocumentTypes()
- func (m *MetadataMutation) ResetEdge(name string) error
- func (m *MetadataMutation) ResetField(name string) error
- func (m *MetadataMutation) ResetName()
- func (m *MetadataMutation) ResetTools()
- func (m *MetadataMutation) ResetVersion()
- func (m *MetadataMutation) SetComment(s string)
- func (m *MetadataMutation) SetDate(t time.Time)
- func (m *MetadataMutation) SetDocumentID(id int)
- func (m *MetadataMutation) SetField(name string, value ent.Value) error
- func (m *MetadataMutation) SetID(id string)
- func (m *MetadataMutation) SetName(s string)
- func (m *MetadataMutation) SetOp(op Op)
- func (m *MetadataMutation) SetVersion(s string)
- func (m *MetadataMutation) ToolsCleared() bool
- func (m *MetadataMutation) ToolsIDs() (ids []int)
- func (m MetadataMutation) Tx() (*Tx, error)
- func (m *MetadataMutation) Type() string
- func (m *MetadataMutation) Version() (r string, exists bool)
- func (m *MetadataMutation) Where(ps ...predicate.Metadata)
- func (m *MetadataMutation) WhereP(ps ...func(*sql.Selector))
- type MetadataQuery
- func (mq *MetadataQuery) Aggregate(fns ...AggregateFunc) *MetadataSelect
- func (mq *MetadataQuery) All(ctx context.Context) ([]*Metadata, error)
- func (mq *MetadataQuery) AllX(ctx context.Context) []*Metadata
- func (mq *MetadataQuery) Clone() *MetadataQuery
- func (mq *MetadataQuery) Count(ctx context.Context) (int, error)
- func (mq *MetadataQuery) CountX(ctx context.Context) int
- func (mq *MetadataQuery) Exist(ctx context.Context) (bool, error)
- func (mq *MetadataQuery) ExistX(ctx context.Context) bool
- func (mq *MetadataQuery) First(ctx context.Context) (*Metadata, error)
- func (mq *MetadataQuery) FirstID(ctx context.Context) (id string, err error)
- func (mq *MetadataQuery) FirstIDX(ctx context.Context) string
- func (mq *MetadataQuery) FirstX(ctx context.Context) *Metadata
- func (mq *MetadataQuery) GroupBy(field string, fields ...string) *MetadataGroupBy
- func (mq *MetadataQuery) IDs(ctx context.Context) (ids []string, err error)
- func (mq *MetadataQuery) IDsX(ctx context.Context) []string
- func (mq *MetadataQuery) Limit(limit int) *MetadataQuery
- func (mq *MetadataQuery) Offset(offset int) *MetadataQuery
- func (mq *MetadataQuery) Only(ctx context.Context) (*Metadata, error)
- func (mq *MetadataQuery) OnlyID(ctx context.Context) (id string, err error)
- func (mq *MetadataQuery) OnlyIDX(ctx context.Context) string
- func (mq *MetadataQuery) OnlyX(ctx context.Context) *Metadata
- func (mq *MetadataQuery) Order(o ...metadata.OrderOption) *MetadataQuery
- func (mq *MetadataQuery) QueryAuthors() *PersonQuery
- func (mq *MetadataQuery) QueryDocument() *DocumentQuery
- func (mq *MetadataQuery) QueryDocumentTypes() *DocumentTypeQuery
- func (mq *MetadataQuery) QueryTools() *ToolQuery
- func (mq *MetadataQuery) Select(fields ...string) *MetadataSelect
- func (mq *MetadataQuery) Unique(unique bool) *MetadataQuery
- func (mq *MetadataQuery) Where(ps ...predicate.Metadata) *MetadataQuery
- func (mq *MetadataQuery) WithAuthors(opts ...func(*PersonQuery)) *MetadataQuery
- func (mq *MetadataQuery) WithDocument(opts ...func(*DocumentQuery)) *MetadataQuery
- func (mq *MetadataQuery) WithDocumentTypes(opts ...func(*DocumentTypeQuery)) *MetadataQuery
- func (mq *MetadataQuery) WithTools(opts ...func(*ToolQuery)) *MetadataQuery
- type MetadataSelect
- func (ms *MetadataSelect) Aggregate(fns ...AggregateFunc) *MetadataSelect
- func (s *MetadataSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *MetadataSelect) BoolX(ctx context.Context) bool
- func (s *MetadataSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *MetadataSelect) BoolsX(ctx context.Context) []bool
- func (s *MetadataSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *MetadataSelect) Float64X(ctx context.Context) float64
- func (s *MetadataSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *MetadataSelect) Float64sX(ctx context.Context) []float64
- func (s *MetadataSelect) Int(ctx context.Context) (_ int, err error)
- func (s *MetadataSelect) IntX(ctx context.Context) int
- func (s *MetadataSelect) Ints(ctx context.Context) ([]int, error)
- func (s *MetadataSelect) IntsX(ctx context.Context) []int
- func (ms *MetadataSelect) Scan(ctx context.Context, v any) error
- func (s *MetadataSelect) ScanX(ctx context.Context, v any)
- func (s *MetadataSelect) String(ctx context.Context) (_ string, err error)
- func (s *MetadataSelect) StringX(ctx context.Context) string
- func (s *MetadataSelect) Strings(ctx context.Context) ([]string, error)
- func (s *MetadataSelect) StringsX(ctx context.Context) []string
- type MetadataSlice
- type MetadataUpdate
- func (mu *MetadataUpdate) AddAuthorIDs(ids ...int) *MetadataUpdate
- func (mu *MetadataUpdate) AddAuthors(p ...*Person) *MetadataUpdate
- func (mu *MetadataUpdate) AddDocumentTypeIDs(ids ...int) *MetadataUpdate
- func (mu *MetadataUpdate) AddDocumentTypes(d ...*DocumentType) *MetadataUpdate
- func (mu *MetadataUpdate) AddToolIDs(ids ...int) *MetadataUpdate
- func (mu *MetadataUpdate) AddTools(t ...*Tool) *MetadataUpdate
- func (mu *MetadataUpdate) ClearAuthors() *MetadataUpdate
- func (mu *MetadataUpdate) ClearDocument() *MetadataUpdate
- func (mu *MetadataUpdate) ClearDocumentTypes() *MetadataUpdate
- func (mu *MetadataUpdate) ClearTools() *MetadataUpdate
- func (mu *MetadataUpdate) Exec(ctx context.Context) error
- func (mu *MetadataUpdate) ExecX(ctx context.Context)
- func (mu *MetadataUpdate) Mutation() *MetadataMutation
- func (mu *MetadataUpdate) RemoveAuthorIDs(ids ...int) *MetadataUpdate
- func (mu *MetadataUpdate) RemoveAuthors(p ...*Person) *MetadataUpdate
- func (mu *MetadataUpdate) RemoveDocumentTypeIDs(ids ...int) *MetadataUpdate
- func (mu *MetadataUpdate) RemoveDocumentTypes(d ...*DocumentType) *MetadataUpdate
- func (mu *MetadataUpdate) RemoveToolIDs(ids ...int) *MetadataUpdate
- func (mu *MetadataUpdate) RemoveTools(t ...*Tool) *MetadataUpdate
- func (mu *MetadataUpdate) Save(ctx context.Context) (int, error)
- func (mu *MetadataUpdate) SaveX(ctx context.Context) int
- func (mu *MetadataUpdate) SetComment(s string) *MetadataUpdate
- func (mu *MetadataUpdate) SetDate(t time.Time) *MetadataUpdate
- func (mu *MetadataUpdate) SetDocument(d *Document) *MetadataUpdate
- func (mu *MetadataUpdate) SetDocumentID(id int) *MetadataUpdate
- func (mu *MetadataUpdate) SetName(s string) *MetadataUpdate
- func (mu *MetadataUpdate) SetNillableComment(s *string) *MetadataUpdate
- func (mu *MetadataUpdate) SetNillableDate(t *time.Time) *MetadataUpdate
- func (mu *MetadataUpdate) SetNillableDocumentID(id *int) *MetadataUpdate
- func (mu *MetadataUpdate) SetNillableName(s *string) *MetadataUpdate
- func (mu *MetadataUpdate) SetNillableVersion(s *string) *MetadataUpdate
- func (mu *MetadataUpdate) SetVersion(s string) *MetadataUpdate
- func (mu *MetadataUpdate) Where(ps ...predicate.Metadata) *MetadataUpdate
- type MetadataUpdateOne
- func (muo *MetadataUpdateOne) AddAuthorIDs(ids ...int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) AddAuthors(p ...*Person) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) AddDocumentTypeIDs(ids ...int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) AddDocumentTypes(d ...*DocumentType) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) AddToolIDs(ids ...int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) AddTools(t ...*Tool) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) ClearAuthors() *MetadataUpdateOne
- func (muo *MetadataUpdateOne) ClearDocument() *MetadataUpdateOne
- func (muo *MetadataUpdateOne) ClearDocumentTypes() *MetadataUpdateOne
- func (muo *MetadataUpdateOne) ClearTools() *MetadataUpdateOne
- func (muo *MetadataUpdateOne) Exec(ctx context.Context) error
- func (muo *MetadataUpdateOne) ExecX(ctx context.Context)
- func (muo *MetadataUpdateOne) Mutation() *MetadataMutation
- func (muo *MetadataUpdateOne) RemoveAuthorIDs(ids ...int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) RemoveAuthors(p ...*Person) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) RemoveDocumentTypeIDs(ids ...int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) RemoveDocumentTypes(d ...*DocumentType) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) RemoveToolIDs(ids ...int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) RemoveTools(t ...*Tool) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) Save(ctx context.Context) (*Metadata, error)
- func (muo *MetadataUpdateOne) SaveX(ctx context.Context) *Metadata
- func (muo *MetadataUpdateOne) Select(field string, fields ...string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetComment(s string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetDate(t time.Time) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetDocument(d *Document) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetDocumentID(id int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetName(s string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetNillableComment(s *string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetNillableDate(t *time.Time) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetNillableDocumentID(id *int) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetNillableName(s *string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetNillableVersion(s *string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) SetVersion(s string) *MetadataUpdateOne
- func (muo *MetadataUpdateOne) Where(ps ...predicate.Metadata) *MetadataUpdateOne
- type MetadataUpsert
- func (u *MetadataUpsert) SetComment(v string) *MetadataUpsert
- func (u *MetadataUpsert) SetDate(v time.Time) *MetadataUpsert
- func (u *MetadataUpsert) SetName(v string) *MetadataUpsert
- func (u *MetadataUpsert) SetVersion(v string) *MetadataUpsert
- func (u *MetadataUpsert) UpdateComment() *MetadataUpsert
- func (u *MetadataUpsert) UpdateDate() *MetadataUpsert
- func (u *MetadataUpsert) UpdateName() *MetadataUpsert
- func (u *MetadataUpsert) UpdateVersion() *MetadataUpsert
- type MetadataUpsertBulk
- func (u *MetadataUpsertBulk) DoNothing() *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) Exec(ctx context.Context) error
- func (u *MetadataUpsertBulk) ExecX(ctx context.Context)
- func (u *MetadataUpsertBulk) Ignore() *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) SetComment(v string) *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) SetDate(v time.Time) *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) SetName(v string) *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) SetVersion(v string) *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) Update(set func(*MetadataUpsert)) *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) UpdateComment() *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) UpdateDate() *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) UpdateName() *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) UpdateNewValues() *MetadataUpsertBulk
- func (u *MetadataUpsertBulk) UpdateVersion() *MetadataUpsertBulk
- type MetadataUpsertOne
- func (u *MetadataUpsertOne) DoNothing() *MetadataUpsertOne
- func (u *MetadataUpsertOne) Exec(ctx context.Context) error
- func (u *MetadataUpsertOne) ExecX(ctx context.Context)
- func (u *MetadataUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *MetadataUpsertOne) IDX(ctx context.Context) string
- func (u *MetadataUpsertOne) Ignore() *MetadataUpsertOne
- func (u *MetadataUpsertOne) SetComment(v string) *MetadataUpsertOne
- func (u *MetadataUpsertOne) SetDate(v time.Time) *MetadataUpsertOne
- func (u *MetadataUpsertOne) SetName(v string) *MetadataUpsertOne
- func (u *MetadataUpsertOne) SetVersion(v string) *MetadataUpsertOne
- func (u *MetadataUpsertOne) Update(set func(*MetadataUpsert)) *MetadataUpsertOne
- func (u *MetadataUpsertOne) UpdateComment() *MetadataUpsertOne
- func (u *MetadataUpsertOne) UpdateDate() *MetadataUpsertOne
- func (u *MetadataUpsertOne) UpdateName() *MetadataUpsertOne
- func (u *MetadataUpsertOne) UpdateNewValues() *MetadataUpsertOne
- func (u *MetadataUpsertOne) UpdateVersion() *MetadataUpsertOne
- type MutateFunc
- type Mutation
- type Mutator
- type Node
- func (n *Node) QueryEdgeTypes() *EdgeTypeQuery
- func (n *Node) QueryExternalReferences() *ExternalReferenceQuery
- func (n *Node) QueryHashes() *HashesEntryQuery
- func (n *Node) QueryIdentifiers() *IdentifiersEntryQuery
- func (n *Node) QueryNodeList() *NodeListQuery
- func (n *Node) QueryNodes() *NodeQuery
- func (n *Node) QueryOriginators() *PersonQuery
- func (n *Node) QueryPrimaryPurpose() *PurposeQuery
- func (n *Node) QuerySuppliers() *PersonQuery
- func (n *Node) String() string
- func (n *Node) Unwrap() *Node
- func (n *Node) Update() *NodeUpdateOne
- func (n *Node) Value(name string) (ent.Value, error)
- type NodeClient
- func (c *NodeClient) Create() *NodeCreate
- func (c *NodeClient) CreateBulk(builders ...*NodeCreate) *NodeCreateBulk
- func (c *NodeClient) Delete() *NodeDelete
- func (c *NodeClient) DeleteOne(n *Node) *NodeDeleteOne
- func (c *NodeClient) DeleteOneID(id string) *NodeDeleteOne
- func (c *NodeClient) Get(ctx context.Context, id string) (*Node, error)
- func (c *NodeClient) GetX(ctx context.Context, id string) *Node
- func (c *NodeClient) Hooks() []Hook
- func (c *NodeClient) Intercept(interceptors ...Interceptor)
- func (c *NodeClient) Interceptors() []Interceptor
- func (c *NodeClient) MapCreateBulk(slice any, setFunc func(*NodeCreate, int)) *NodeCreateBulk
- func (c *NodeClient) Query() *NodeQuery
- func (c *NodeClient) QueryEdgeTypes(n *Node) *EdgeTypeQuery
- func (c *NodeClient) QueryExternalReferences(n *Node) *ExternalReferenceQuery
- func (c *NodeClient) QueryHashes(n *Node) *HashesEntryQuery
- func (c *NodeClient) QueryIdentifiers(n *Node) *IdentifiersEntryQuery
- func (c *NodeClient) QueryNodeList(n *Node) *NodeListQuery
- func (c *NodeClient) QueryNodes(n *Node) *NodeQuery
- func (c *NodeClient) QueryOriginators(n *Node) *PersonQuery
- func (c *NodeClient) QueryPrimaryPurpose(n *Node) *PurposeQuery
- func (c *NodeClient) QuerySuppliers(n *Node) *PersonQuery
- func (c *NodeClient) Update() *NodeUpdate
- func (c *NodeClient) UpdateOne(n *Node) *NodeUpdateOne
- func (c *NodeClient) UpdateOneID(id string) *NodeUpdateOne
- func (c *NodeClient) Use(hooks ...Hook)
- type NodeCreate
- func (nc *NodeCreate) AddEdgeTypeIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddEdgeTypes(e ...*EdgeType) *NodeCreate
- func (nc *NodeCreate) AddExternalReferenceIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddExternalReferences(e ...*ExternalReference) *NodeCreate
- func (nc *NodeCreate) AddHashIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddHashes(h ...*HashesEntry) *NodeCreate
- func (nc *NodeCreate) AddIdentifierIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddIdentifiers(i ...*IdentifiersEntry) *NodeCreate
- func (nc *NodeCreate) AddNodeIDs(ids ...string) *NodeCreate
- func (nc *NodeCreate) AddNodes(n ...*Node) *NodeCreate
- func (nc *NodeCreate) AddOriginatorIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddOriginators(p ...*Person) *NodeCreate
- func (nc *NodeCreate) AddPrimaryPurpose(p ...*Purpose) *NodeCreate
- func (nc *NodeCreate) AddPrimaryPurposeIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddSupplierIDs(ids ...int) *NodeCreate
- func (nc *NodeCreate) AddSuppliers(p ...*Person) *NodeCreate
- func (nc *NodeCreate) Exec(ctx context.Context) error
- func (nc *NodeCreate) ExecX(ctx context.Context)
- func (nc *NodeCreate) Mutation() *NodeMutation
- func (nc *NodeCreate) OnConflict(opts ...sql.ConflictOption) *NodeUpsertOne
- func (nc *NodeCreate) OnConflictColumns(columns ...string) *NodeUpsertOne
- func (nc *NodeCreate) Save(ctx context.Context) (*Node, error)
- func (nc *NodeCreate) SaveX(ctx context.Context) *Node
- func (nc *NodeCreate) SetAttribution(s []string) *NodeCreate
- func (nc *NodeCreate) SetBuildDate(t time.Time) *NodeCreate
- func (nc *NodeCreate) SetComment(s string) *NodeCreate
- func (nc *NodeCreate) SetCopyright(s string) *NodeCreate
- func (nc *NodeCreate) SetDescription(s string) *NodeCreate
- func (nc *NodeCreate) SetFileName(s string) *NodeCreate
- func (nc *NodeCreate) SetFileTypes(s []string) *NodeCreate
- func (nc *NodeCreate) SetID(s string) *NodeCreate
- func (nc *NodeCreate) SetLicenseComments(s string) *NodeCreate
- func (nc *NodeCreate) SetLicenseConcluded(s string) *NodeCreate
- func (nc *NodeCreate) SetLicenses(s []string) *NodeCreate
- func (nc *NodeCreate) SetName(s string) *NodeCreate
- func (nc *NodeCreate) SetNodeList(n *NodeList) *NodeCreate
- func (nc *NodeCreate) SetNodeListID(id int) *NodeCreate
- func (nc *NodeCreate) SetReleaseDate(t time.Time) *NodeCreate
- func (nc *NodeCreate) SetSourceInfo(s string) *NodeCreate
- func (nc *NodeCreate) SetSummary(s string) *NodeCreate
- func (nc *NodeCreate) SetType(n node.Type) *NodeCreate
- func (nc *NodeCreate) SetURLDownload(s string) *NodeCreate
- func (nc *NodeCreate) SetURLHome(s string) *NodeCreate
- func (nc *NodeCreate) SetValidUntilDate(t time.Time) *NodeCreate
- func (nc *NodeCreate) SetVersion(s string) *NodeCreate
- type NodeCreateBulk
- func (ncb *NodeCreateBulk) Exec(ctx context.Context) error
- func (ncb *NodeCreateBulk) ExecX(ctx context.Context)
- func (ncb *NodeCreateBulk) OnConflict(opts ...sql.ConflictOption) *NodeUpsertBulk
- func (ncb *NodeCreateBulk) OnConflictColumns(columns ...string) *NodeUpsertBulk
- func (ncb *NodeCreateBulk) Save(ctx context.Context) ([]*Node, error)
- func (ncb *NodeCreateBulk) SaveX(ctx context.Context) []*Node
- type NodeDelete
- type NodeDeleteOne
- type NodeEdges
- func (e NodeEdges) EdgeTypesOrErr() ([]*EdgeType, error)
- func (e NodeEdges) ExternalReferencesOrErr() ([]*ExternalReference, error)
- func (e NodeEdges) HashesOrErr() ([]*HashesEntry, error)
- func (e NodeEdges) IdentifiersOrErr() ([]*IdentifiersEntry, error)
- func (e NodeEdges) NodeListOrErr() (*NodeList, error)
- func (e NodeEdges) NodesOrErr() ([]*Node, error)
- func (e NodeEdges) OriginatorsOrErr() ([]*Person, error)
- func (e NodeEdges) PrimaryPurposeOrErr() ([]*Purpose, error)
- func (e NodeEdges) SuppliersOrErr() ([]*Person, error)
- type NodeGroupBy
- func (ngb *NodeGroupBy) Aggregate(fns ...AggregateFunc) *NodeGroupBy
- func (s *NodeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *NodeGroupBy) BoolX(ctx context.Context) bool
- func (s *NodeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *NodeGroupBy) BoolsX(ctx context.Context) []bool
- func (s *NodeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *NodeGroupBy) Float64X(ctx context.Context) float64
- func (s *NodeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *NodeGroupBy) Float64sX(ctx context.Context) []float64
- func (s *NodeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *NodeGroupBy) IntX(ctx context.Context) int
- func (s *NodeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *NodeGroupBy) IntsX(ctx context.Context) []int
- func (ngb *NodeGroupBy) Scan(ctx context.Context, v any) error
- func (s *NodeGroupBy) ScanX(ctx context.Context, v any)
- func (s *NodeGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *NodeGroupBy) StringX(ctx context.Context) string
- func (s *NodeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *NodeGroupBy) StringsX(ctx context.Context) []string
- type NodeList
- type NodeListClient
- func (c *NodeListClient) Create() *NodeListCreate
- func (c *NodeListClient) CreateBulk(builders ...*NodeListCreate) *NodeListCreateBulk
- func (c *NodeListClient) Delete() *NodeListDelete
- func (c *NodeListClient) DeleteOne(nl *NodeList) *NodeListDeleteOne
- func (c *NodeListClient) DeleteOneID(id int) *NodeListDeleteOne
- func (c *NodeListClient) Get(ctx context.Context, id int) (*NodeList, error)
- func (c *NodeListClient) GetX(ctx context.Context, id int) *NodeList
- func (c *NodeListClient) Hooks() []Hook
- func (c *NodeListClient) Intercept(interceptors ...Interceptor)
- func (c *NodeListClient) Interceptors() []Interceptor
- func (c *NodeListClient) MapCreateBulk(slice any, setFunc func(*NodeListCreate, int)) *NodeListCreateBulk
- func (c *NodeListClient) Query() *NodeListQuery
- func (c *NodeListClient) QueryDocument(nl *NodeList) *DocumentQuery
- func (c *NodeListClient) QueryNodes(nl *NodeList) *NodeQuery
- func (c *NodeListClient) Update() *NodeListUpdate
- func (c *NodeListClient) UpdateOne(nl *NodeList) *NodeListUpdateOne
- func (c *NodeListClient) UpdateOneID(id int) *NodeListUpdateOne
- func (c *NodeListClient) Use(hooks ...Hook)
- type NodeListCreate
- func (nlc *NodeListCreate) AddNodeIDs(ids ...string) *NodeListCreate
- func (nlc *NodeListCreate) AddNodes(n ...*Node) *NodeListCreate
- func (nlc *NodeListCreate) Exec(ctx context.Context) error
- func (nlc *NodeListCreate) ExecX(ctx context.Context)
- func (nlc *NodeListCreate) Mutation() *NodeListMutation
- func (nlc *NodeListCreate) OnConflict(opts ...sql.ConflictOption) *NodeListUpsertOne
- func (nlc *NodeListCreate) OnConflictColumns(columns ...string) *NodeListUpsertOne
- func (nlc *NodeListCreate) Save(ctx context.Context) (*NodeList, error)
- func (nlc *NodeListCreate) SaveX(ctx context.Context) *NodeList
- func (nlc *NodeListCreate) SetDocument(d *Document) *NodeListCreate
- func (nlc *NodeListCreate) SetDocumentID(id int) *NodeListCreate
- func (nlc *NodeListCreate) SetNillableDocumentID(id *int) *NodeListCreate
- func (nlc *NodeListCreate) SetRootElements(s []string) *NodeListCreate
- type NodeListCreateBulk
- func (nlcb *NodeListCreateBulk) Exec(ctx context.Context) error
- func (nlcb *NodeListCreateBulk) ExecX(ctx context.Context)
- func (nlcb *NodeListCreateBulk) OnConflict(opts ...sql.ConflictOption) *NodeListUpsertBulk
- func (nlcb *NodeListCreateBulk) OnConflictColumns(columns ...string) *NodeListUpsertBulk
- func (nlcb *NodeListCreateBulk) Save(ctx context.Context) ([]*NodeList, error)
- func (nlcb *NodeListCreateBulk) SaveX(ctx context.Context) []*NodeList
- type NodeListDelete
- type NodeListDeleteOne
- type NodeListEdges
- type NodeListGroupBy
- func (nlgb *NodeListGroupBy) Aggregate(fns ...AggregateFunc) *NodeListGroupBy
- func (s *NodeListGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *NodeListGroupBy) BoolX(ctx context.Context) bool
- func (s *NodeListGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *NodeListGroupBy) BoolsX(ctx context.Context) []bool
- func (s *NodeListGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *NodeListGroupBy) Float64X(ctx context.Context) float64
- func (s *NodeListGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *NodeListGroupBy) Float64sX(ctx context.Context) []float64
- func (s *NodeListGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *NodeListGroupBy) IntX(ctx context.Context) int
- func (s *NodeListGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *NodeListGroupBy) IntsX(ctx context.Context) []int
- func (nlgb *NodeListGroupBy) Scan(ctx context.Context, v any) error
- func (s *NodeListGroupBy) ScanX(ctx context.Context, v any)
- func (s *NodeListGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *NodeListGroupBy) StringX(ctx context.Context) string
- func (s *NodeListGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *NodeListGroupBy) StringsX(ctx context.Context) []string
- type NodeListMutation
- func (m *NodeListMutation) AddField(name string, value ent.Value) error
- func (m *NodeListMutation) AddNodeIDs(ids ...string)
- func (m *NodeListMutation) AddedEdges() []string
- func (m *NodeListMutation) AddedField(name string) (ent.Value, bool)
- func (m *NodeListMutation) AddedFields() []string
- func (m *NodeListMutation) AddedIDs(name string) []ent.Value
- func (m *NodeListMutation) AppendRootElements(s []string)
- func (m *NodeListMutation) AppendedRootElements() ([]string, bool)
- func (m *NodeListMutation) ClearDocument()
- func (m *NodeListMutation) ClearEdge(name string) error
- func (m *NodeListMutation) ClearField(name string) error
- func (m *NodeListMutation) ClearNodes()
- func (m *NodeListMutation) ClearedEdges() []string
- func (m *NodeListMutation) ClearedFields() []string
- func (m NodeListMutation) Client() *Client
- func (m *NodeListMutation) DocumentCleared() bool
- func (m *NodeListMutation) DocumentID() (id int, exists bool)
- func (m *NodeListMutation) DocumentIDs() (ids []int)
- func (m *NodeListMutation) EdgeCleared(name string) bool
- func (m *NodeListMutation) Field(name string) (ent.Value, bool)
- func (m *NodeListMutation) FieldCleared(name string) bool
- func (m *NodeListMutation) Fields() []string
- func (m *NodeListMutation) ID() (id int, exists bool)
- func (m *NodeListMutation) IDs(ctx context.Context) ([]int, error)
- func (m *NodeListMutation) NodesCleared() bool
- func (m *NodeListMutation) NodesIDs() (ids []string)
- func (m *NodeListMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *NodeListMutation) OldRootElements(ctx context.Context) (v []string, err error)
- func (m *NodeListMutation) Op() Op
- func (m *NodeListMutation) RemoveNodeIDs(ids ...string)
- func (m *NodeListMutation) RemovedEdges() []string
- func (m *NodeListMutation) RemovedIDs(name string) []ent.Value
- func (m *NodeListMutation) RemovedNodesIDs() (ids []string)
- func (m *NodeListMutation) ResetDocument()
- func (m *NodeListMutation) ResetEdge(name string) error
- func (m *NodeListMutation) ResetField(name string) error
- func (m *NodeListMutation) ResetNodes()
- func (m *NodeListMutation) ResetRootElements()
- func (m *NodeListMutation) RootElements() (r []string, exists bool)
- func (m *NodeListMutation) SetDocumentID(id int)
- func (m *NodeListMutation) SetField(name string, value ent.Value) error
- func (m *NodeListMutation) SetOp(op Op)
- func (m *NodeListMutation) SetRootElements(s []string)
- func (m NodeListMutation) Tx() (*Tx, error)
- func (m *NodeListMutation) Type() string
- func (m *NodeListMutation) Where(ps ...predicate.NodeList)
- func (m *NodeListMutation) WhereP(ps ...func(*sql.Selector))
- type NodeListQuery
- func (nlq *NodeListQuery) Aggregate(fns ...AggregateFunc) *NodeListSelect
- func (nlq *NodeListQuery) All(ctx context.Context) ([]*NodeList, error)
- func (nlq *NodeListQuery) AllX(ctx context.Context) []*NodeList
- func (nlq *NodeListQuery) Clone() *NodeListQuery
- func (nlq *NodeListQuery) Count(ctx context.Context) (int, error)
- func (nlq *NodeListQuery) CountX(ctx context.Context) int
- func (nlq *NodeListQuery) Exist(ctx context.Context) (bool, error)
- func (nlq *NodeListQuery) ExistX(ctx context.Context) bool
- func (nlq *NodeListQuery) First(ctx context.Context) (*NodeList, error)
- func (nlq *NodeListQuery) FirstID(ctx context.Context) (id int, err error)
- func (nlq *NodeListQuery) FirstIDX(ctx context.Context) int
- func (nlq *NodeListQuery) FirstX(ctx context.Context) *NodeList
- func (nlq *NodeListQuery) GroupBy(field string, fields ...string) *NodeListGroupBy
- func (nlq *NodeListQuery) IDs(ctx context.Context) (ids []int, err error)
- func (nlq *NodeListQuery) IDsX(ctx context.Context) []int
- func (nlq *NodeListQuery) Limit(limit int) *NodeListQuery
- func (nlq *NodeListQuery) Offset(offset int) *NodeListQuery
- func (nlq *NodeListQuery) Only(ctx context.Context) (*NodeList, error)
- func (nlq *NodeListQuery) OnlyID(ctx context.Context) (id int, err error)
- func (nlq *NodeListQuery) OnlyIDX(ctx context.Context) int
- func (nlq *NodeListQuery) OnlyX(ctx context.Context) *NodeList
- func (nlq *NodeListQuery) Order(o ...nodelist.OrderOption) *NodeListQuery
- func (nlq *NodeListQuery) QueryDocument() *DocumentQuery
- func (nlq *NodeListQuery) QueryNodes() *NodeQuery
- func (nlq *NodeListQuery) Select(fields ...string) *NodeListSelect
- func (nlq *NodeListQuery) Unique(unique bool) *NodeListQuery
- func (nlq *NodeListQuery) Where(ps ...predicate.NodeList) *NodeListQuery
- func (nlq *NodeListQuery) WithDocument(opts ...func(*DocumentQuery)) *NodeListQuery
- func (nlq *NodeListQuery) WithNodes(opts ...func(*NodeQuery)) *NodeListQuery
- type NodeListSelect
- func (nls *NodeListSelect) Aggregate(fns ...AggregateFunc) *NodeListSelect
- func (s *NodeListSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *NodeListSelect) BoolX(ctx context.Context) bool
- func (s *NodeListSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *NodeListSelect) BoolsX(ctx context.Context) []bool
- func (s *NodeListSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *NodeListSelect) Float64X(ctx context.Context) float64
- func (s *NodeListSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *NodeListSelect) Float64sX(ctx context.Context) []float64
- func (s *NodeListSelect) Int(ctx context.Context) (_ int, err error)
- func (s *NodeListSelect) IntX(ctx context.Context) int
- func (s *NodeListSelect) Ints(ctx context.Context) ([]int, error)
- func (s *NodeListSelect) IntsX(ctx context.Context) []int
- func (nls *NodeListSelect) Scan(ctx context.Context, v any) error
- func (s *NodeListSelect) ScanX(ctx context.Context, v any)
- func (s *NodeListSelect) String(ctx context.Context) (_ string, err error)
- func (s *NodeListSelect) StringX(ctx context.Context) string
- func (s *NodeListSelect) Strings(ctx context.Context) ([]string, error)
- func (s *NodeListSelect) StringsX(ctx context.Context) []string
- type NodeListUpdate
- func (nlu *NodeListUpdate) AddNodeIDs(ids ...string) *NodeListUpdate
- func (nlu *NodeListUpdate) AddNodes(n ...*Node) *NodeListUpdate
- func (nlu *NodeListUpdate) AppendRootElements(s []string) *NodeListUpdate
- func (nlu *NodeListUpdate) ClearDocument() *NodeListUpdate
- func (nlu *NodeListUpdate) ClearNodes() *NodeListUpdate
- func (nlu *NodeListUpdate) Exec(ctx context.Context) error
- func (nlu *NodeListUpdate) ExecX(ctx context.Context)
- func (nlu *NodeListUpdate) Mutation() *NodeListMutation
- func (nlu *NodeListUpdate) RemoveNodeIDs(ids ...string) *NodeListUpdate
- func (nlu *NodeListUpdate) RemoveNodes(n ...*Node) *NodeListUpdate
- func (nlu *NodeListUpdate) Save(ctx context.Context) (int, error)
- func (nlu *NodeListUpdate) SaveX(ctx context.Context) int
- func (nlu *NodeListUpdate) SetDocument(d *Document) *NodeListUpdate
- func (nlu *NodeListUpdate) SetDocumentID(id int) *NodeListUpdate
- func (nlu *NodeListUpdate) SetNillableDocumentID(id *int) *NodeListUpdate
- func (nlu *NodeListUpdate) SetRootElements(s []string) *NodeListUpdate
- func (nlu *NodeListUpdate) Where(ps ...predicate.NodeList) *NodeListUpdate
- type NodeListUpdateOne
- func (nluo *NodeListUpdateOne) AddNodeIDs(ids ...string) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) AddNodes(n ...*Node) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) AppendRootElements(s []string) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) ClearDocument() *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) ClearNodes() *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) Exec(ctx context.Context) error
- func (nluo *NodeListUpdateOne) ExecX(ctx context.Context)
- func (nluo *NodeListUpdateOne) Mutation() *NodeListMutation
- func (nluo *NodeListUpdateOne) RemoveNodeIDs(ids ...string) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) RemoveNodes(n ...*Node) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) Save(ctx context.Context) (*NodeList, error)
- func (nluo *NodeListUpdateOne) SaveX(ctx context.Context) *NodeList
- func (nluo *NodeListUpdateOne) Select(field string, fields ...string) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) SetDocument(d *Document) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) SetDocumentID(id int) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) SetNillableDocumentID(id *int) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) SetRootElements(s []string) *NodeListUpdateOne
- func (nluo *NodeListUpdateOne) Where(ps ...predicate.NodeList) *NodeListUpdateOne
- type NodeListUpsert
- type NodeListUpsertBulk
- func (u *NodeListUpsertBulk) DoNothing() *NodeListUpsertBulk
- func (u *NodeListUpsertBulk) Exec(ctx context.Context) error
- func (u *NodeListUpsertBulk) ExecX(ctx context.Context)
- func (u *NodeListUpsertBulk) Ignore() *NodeListUpsertBulk
- func (u *NodeListUpsertBulk) SetRootElements(v []string) *NodeListUpsertBulk
- func (u *NodeListUpsertBulk) Update(set func(*NodeListUpsert)) *NodeListUpsertBulk
- func (u *NodeListUpsertBulk) UpdateNewValues() *NodeListUpsertBulk
- func (u *NodeListUpsertBulk) UpdateRootElements() *NodeListUpsertBulk
- type NodeListUpsertOne
- func (u *NodeListUpsertOne) DoNothing() *NodeListUpsertOne
- func (u *NodeListUpsertOne) Exec(ctx context.Context) error
- func (u *NodeListUpsertOne) ExecX(ctx context.Context)
- func (u *NodeListUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *NodeListUpsertOne) IDX(ctx context.Context) int
- func (u *NodeListUpsertOne) Ignore() *NodeListUpsertOne
- func (u *NodeListUpsertOne) SetRootElements(v []string) *NodeListUpsertOne
- func (u *NodeListUpsertOne) Update(set func(*NodeListUpsert)) *NodeListUpsertOne
- func (u *NodeListUpsertOne) UpdateNewValues() *NodeListUpsertOne
- func (u *NodeListUpsertOne) UpdateRootElements() *NodeListUpsertOne
- type NodeLists
- type NodeMutation
- func (m *NodeMutation) AddEdgeTypeIDs(ids ...int)
- func (m *NodeMutation) AddExternalReferenceIDs(ids ...int)
- func (m *NodeMutation) AddField(name string, value ent.Value) error
- func (m *NodeMutation) AddHashIDs(ids ...int)
- func (m *NodeMutation) AddIdentifierIDs(ids ...int)
- func (m *NodeMutation) AddNodeIDs(ids ...string)
- func (m *NodeMutation) AddOriginatorIDs(ids ...int)
- func (m *NodeMutation) AddPrimaryPurposeIDs(ids ...int)
- func (m *NodeMutation) AddSupplierIDs(ids ...int)
- func (m *NodeMutation) AddedEdges() []string
- func (m *NodeMutation) AddedField(name string) (ent.Value, bool)
- func (m *NodeMutation) AddedFields() []string
- func (m *NodeMutation) AddedIDs(name string) []ent.Value
- func (m *NodeMutation) AppendAttribution(s []string)
- func (m *NodeMutation) AppendFileTypes(s []string)
- func (m *NodeMutation) AppendLicenses(s []string)
- func (m *NodeMutation) AppendedAttribution() ([]string, bool)
- func (m *NodeMutation) AppendedFileTypes() ([]string, bool)
- func (m *NodeMutation) AppendedLicenses() ([]string, bool)
- func (m *NodeMutation) Attribution() (r []string, exists bool)
- func (m *NodeMutation) BuildDate() (r time.Time, exists bool)
- func (m *NodeMutation) ClearEdge(name string) error
- func (m *NodeMutation) ClearEdgeTypes()
- func (m *NodeMutation) ClearExternalReferences()
- func (m *NodeMutation) ClearField(name string) error
- func (m *NodeMutation) ClearHashes()
- func (m *NodeMutation) ClearIdentifiers()
- func (m *NodeMutation) ClearNodeList()
- func (m *NodeMutation) ClearNodes()
- func (m *NodeMutation) ClearOriginators()
- func (m *NodeMutation) ClearPrimaryPurpose()
- func (m *NodeMutation) ClearSuppliers()
- func (m *NodeMutation) ClearedEdges() []string
- func (m *NodeMutation) ClearedFields() []string
- func (m NodeMutation) Client() *Client
- func (m *NodeMutation) Comment() (r string, exists bool)
- func (m *NodeMutation) Copyright() (r string, exists bool)
- func (m *NodeMutation) Description() (r string, exists bool)
- func (m *NodeMutation) EdgeCleared(name string) bool
- func (m *NodeMutation) EdgeTypesCleared() bool
- func (m *NodeMutation) EdgeTypesIDs() (ids []int)
- func (m *NodeMutation) ExternalReferencesCleared() bool
- func (m *NodeMutation) ExternalReferencesIDs() (ids []int)
- func (m *NodeMutation) Field(name string) (ent.Value, bool)
- func (m *NodeMutation) FieldCleared(name string) bool
- func (m *NodeMutation) Fields() []string
- func (m *NodeMutation) FileName() (r string, exists bool)
- func (m *NodeMutation) FileTypes() (r []string, exists bool)
- func (m *NodeMutation) GetType() (r node.Type, exists bool)
- func (m *NodeMutation) HashesCleared() bool
- func (m *NodeMutation) HashesIDs() (ids []int)
- func (m *NodeMutation) ID() (id string, exists bool)
- func (m *NodeMutation) IDs(ctx context.Context) ([]string, error)
- func (m *NodeMutation) IdentifiersCleared() bool
- func (m *NodeMutation) IdentifiersIDs() (ids []int)
- func (m *NodeMutation) LicenseComments() (r string, exists bool)
- func (m *NodeMutation) LicenseConcluded() (r string, exists bool)
- func (m *NodeMutation) Licenses() (r []string, exists bool)
- func (m *NodeMutation) Name() (r string, exists bool)
- func (m *NodeMutation) NodeListCleared() bool
- func (m *NodeMutation) NodeListID() (id int, exists bool)
- func (m *NodeMutation) NodeListIDs() (ids []int)
- func (m *NodeMutation) NodesCleared() bool
- func (m *NodeMutation) NodesIDs() (ids []string)
- func (m *NodeMutation) OldAttribution(ctx context.Context) (v []string, err error)
- func (m *NodeMutation) OldBuildDate(ctx context.Context) (v time.Time, err error)
- func (m *NodeMutation) OldComment(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldCopyright(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldDescription(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *NodeMutation) OldFileName(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldFileTypes(ctx context.Context) (v []string, err error)
- func (m *NodeMutation) OldLicenseComments(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldLicenseConcluded(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldLicenses(ctx context.Context) (v []string, err error)
- func (m *NodeMutation) OldName(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldReleaseDate(ctx context.Context) (v time.Time, err error)
- func (m *NodeMutation) OldSourceInfo(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldSummary(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldType(ctx context.Context) (v node.Type, err error)
- func (m *NodeMutation) OldURLDownload(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldURLHome(ctx context.Context) (v string, err error)
- func (m *NodeMutation) OldValidUntilDate(ctx context.Context) (v time.Time, err error)
- func (m *NodeMutation) OldVersion(ctx context.Context) (v string, err error)
- func (m *NodeMutation) Op() Op
- func (m *NodeMutation) OriginatorsCleared() bool
- func (m *NodeMutation) OriginatorsIDs() (ids []int)
- func (m *NodeMutation) PrimaryPurposeCleared() bool
- func (m *NodeMutation) PrimaryPurposeIDs() (ids []int)
- func (m *NodeMutation) ReleaseDate() (r time.Time, exists bool)
- func (m *NodeMutation) RemoveEdgeTypeIDs(ids ...int)
- func (m *NodeMutation) RemoveExternalReferenceIDs(ids ...int)
- func (m *NodeMutation) RemoveHashIDs(ids ...int)
- func (m *NodeMutation) RemoveIdentifierIDs(ids ...int)
- func (m *NodeMutation) RemoveNodeIDs(ids ...string)
- func (m *NodeMutation) RemoveOriginatorIDs(ids ...int)
- func (m *NodeMutation) RemovePrimaryPurposeIDs(ids ...int)
- func (m *NodeMutation) RemoveSupplierIDs(ids ...int)
- func (m *NodeMutation) RemovedEdgeTypesIDs() (ids []int)
- func (m *NodeMutation) RemovedEdges() []string
- func (m *NodeMutation) RemovedExternalReferencesIDs() (ids []int)
- func (m *NodeMutation) RemovedHashesIDs() (ids []int)
- func (m *NodeMutation) RemovedIDs(name string) []ent.Value
- func (m *NodeMutation) RemovedIdentifiersIDs() (ids []int)
- func (m *NodeMutation) RemovedNodesIDs() (ids []string)
- func (m *NodeMutation) RemovedOriginatorsIDs() (ids []int)
- func (m *NodeMutation) RemovedPrimaryPurposeIDs() (ids []int)
- func (m *NodeMutation) RemovedSuppliersIDs() (ids []int)
- func (m *NodeMutation) ResetAttribution()
- func (m *NodeMutation) ResetBuildDate()
- func (m *NodeMutation) ResetComment()
- func (m *NodeMutation) ResetCopyright()
- func (m *NodeMutation) ResetDescription()
- func (m *NodeMutation) ResetEdge(name string) error
- func (m *NodeMutation) ResetEdgeTypes()
- func (m *NodeMutation) ResetExternalReferences()
- func (m *NodeMutation) ResetField(name string) error
- func (m *NodeMutation) ResetFileName()
- func (m *NodeMutation) ResetFileTypes()
- func (m *NodeMutation) ResetHashes()
- func (m *NodeMutation) ResetIdentifiers()
- func (m *NodeMutation) ResetLicenseComments()
- func (m *NodeMutation) ResetLicenseConcluded()
- func (m *NodeMutation) ResetLicenses()
- func (m *NodeMutation) ResetName()
- func (m *NodeMutation) ResetNodeList()
- func (m *NodeMutation) ResetNodes()
- func (m *NodeMutation) ResetOriginators()
- func (m *NodeMutation) ResetPrimaryPurpose()
- func (m *NodeMutation) ResetReleaseDate()
- func (m *NodeMutation) ResetSourceInfo()
- func (m *NodeMutation) ResetSummary()
- func (m *NodeMutation) ResetSuppliers()
- func (m *NodeMutation) ResetType()
- func (m *NodeMutation) ResetURLDownload()
- func (m *NodeMutation) ResetURLHome()
- func (m *NodeMutation) ResetValidUntilDate()
- func (m *NodeMutation) ResetVersion()
- func (m *NodeMutation) SetAttribution(s []string)
- func (m *NodeMutation) SetBuildDate(t time.Time)
- func (m *NodeMutation) SetComment(s string)
- func (m *NodeMutation) SetCopyright(s string)
- func (m *NodeMutation) SetDescription(s string)
- func (m *NodeMutation) SetField(name string, value ent.Value) error
- func (m *NodeMutation) SetFileName(s string)
- func (m *NodeMutation) SetFileTypes(s []string)
- func (m *NodeMutation) SetID(id string)
- func (m *NodeMutation) SetLicenseComments(s string)
- func (m *NodeMutation) SetLicenseConcluded(s string)
- func (m *NodeMutation) SetLicenses(s []string)
- func (m *NodeMutation) SetName(s string)
- func (m *NodeMutation) SetNodeListID(id int)
- func (m *NodeMutation) SetOp(op Op)
- func (m *NodeMutation) SetReleaseDate(t time.Time)
- func (m *NodeMutation) SetSourceInfo(s string)
- func (m *NodeMutation) SetSummary(s string)
- func (m *NodeMutation) SetType(n node.Type)
- func (m *NodeMutation) SetURLDownload(s string)
- func (m *NodeMutation) SetURLHome(s string)
- func (m *NodeMutation) SetValidUntilDate(t time.Time)
- func (m *NodeMutation) SetVersion(s string)
- func (m *NodeMutation) SourceInfo() (r string, exists bool)
- func (m *NodeMutation) Summary() (r string, exists bool)
- func (m *NodeMutation) SuppliersCleared() bool
- func (m *NodeMutation) SuppliersIDs() (ids []int)
- func (m NodeMutation) Tx() (*Tx, error)
- func (m *NodeMutation) Type() string
- func (m *NodeMutation) URLDownload() (r string, exists bool)
- func (m *NodeMutation) URLHome() (r string, exists bool)
- func (m *NodeMutation) ValidUntilDate() (r time.Time, exists bool)
- func (m *NodeMutation) Version() (r string, exists bool)
- func (m *NodeMutation) Where(ps ...predicate.Node)
- func (m *NodeMutation) WhereP(ps ...func(*sql.Selector))
- type NodeQuery
- func (nq *NodeQuery) Aggregate(fns ...AggregateFunc) *NodeSelect
- func (nq *NodeQuery) All(ctx context.Context) ([]*Node, error)
- func (nq *NodeQuery) AllX(ctx context.Context) []*Node
- func (nq *NodeQuery) Clone() *NodeQuery
- func (nq *NodeQuery) Count(ctx context.Context) (int, error)
- func (nq *NodeQuery) CountX(ctx context.Context) int
- func (nq *NodeQuery) Exist(ctx context.Context) (bool, error)
- func (nq *NodeQuery) ExistX(ctx context.Context) bool
- func (nq *NodeQuery) First(ctx context.Context) (*Node, error)
- func (nq *NodeQuery) FirstID(ctx context.Context) (id string, err error)
- func (nq *NodeQuery) FirstIDX(ctx context.Context) string
- func (nq *NodeQuery) FirstX(ctx context.Context) *Node
- func (nq *NodeQuery) GroupBy(field string, fields ...string) *NodeGroupBy
- func (nq *NodeQuery) IDs(ctx context.Context) (ids []string, err error)
- func (nq *NodeQuery) IDsX(ctx context.Context) []string
- func (nq *NodeQuery) Limit(limit int) *NodeQuery
- func (nq *NodeQuery) Offset(offset int) *NodeQuery
- func (nq *NodeQuery) Only(ctx context.Context) (*Node, error)
- func (nq *NodeQuery) OnlyID(ctx context.Context) (id string, err error)
- func (nq *NodeQuery) OnlyIDX(ctx context.Context) string
- func (nq *NodeQuery) OnlyX(ctx context.Context) *Node
- func (nq *NodeQuery) Order(o ...node.OrderOption) *NodeQuery
- func (nq *NodeQuery) QueryEdgeTypes() *EdgeTypeQuery
- func (nq *NodeQuery) QueryExternalReferences() *ExternalReferenceQuery
- func (nq *NodeQuery) QueryHashes() *HashesEntryQuery
- func (nq *NodeQuery) QueryIdentifiers() *IdentifiersEntryQuery
- func (nq *NodeQuery) QueryNodeList() *NodeListQuery
- func (nq *NodeQuery) QueryNodes() *NodeQuery
- func (nq *NodeQuery) QueryOriginators() *PersonQuery
- func (nq *NodeQuery) QueryPrimaryPurpose() *PurposeQuery
- func (nq *NodeQuery) QuerySuppliers() *PersonQuery
- func (nq *NodeQuery) Select(fields ...string) *NodeSelect
- func (nq *NodeQuery) Unique(unique bool) *NodeQuery
- func (nq *NodeQuery) Where(ps ...predicate.Node) *NodeQuery
- func (nq *NodeQuery) WithEdgeTypes(opts ...func(*EdgeTypeQuery)) *NodeQuery
- func (nq *NodeQuery) WithExternalReferences(opts ...func(*ExternalReferenceQuery)) *NodeQuery
- func (nq *NodeQuery) WithHashes(opts ...func(*HashesEntryQuery)) *NodeQuery
- func (nq *NodeQuery) WithIdentifiers(opts ...func(*IdentifiersEntryQuery)) *NodeQuery
- func (nq *NodeQuery) WithNodeList(opts ...func(*NodeListQuery)) *NodeQuery
- func (nq *NodeQuery) WithNodes(opts ...func(*NodeQuery)) *NodeQuery
- func (nq *NodeQuery) WithOriginators(opts ...func(*PersonQuery)) *NodeQuery
- func (nq *NodeQuery) WithPrimaryPurpose(opts ...func(*PurposeQuery)) *NodeQuery
- func (nq *NodeQuery) WithSuppliers(opts ...func(*PersonQuery)) *NodeQuery
- type NodeSelect
- func (ns *NodeSelect) Aggregate(fns ...AggregateFunc) *NodeSelect
- func (s *NodeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *NodeSelect) BoolX(ctx context.Context) bool
- func (s *NodeSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *NodeSelect) BoolsX(ctx context.Context) []bool
- func (s *NodeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *NodeSelect) Float64X(ctx context.Context) float64
- func (s *NodeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *NodeSelect) Float64sX(ctx context.Context) []float64
- func (s *NodeSelect) Int(ctx context.Context) (_ int, err error)
- func (s *NodeSelect) IntX(ctx context.Context) int
- func (s *NodeSelect) Ints(ctx context.Context) ([]int, error)
- func (s *NodeSelect) IntsX(ctx context.Context) []int
- func (ns *NodeSelect) Scan(ctx context.Context, v any) error
- func (s *NodeSelect) ScanX(ctx context.Context, v any)
- func (s *NodeSelect) String(ctx context.Context) (_ string, err error)
- func (s *NodeSelect) StringX(ctx context.Context) string
- func (s *NodeSelect) Strings(ctx context.Context) ([]string, error)
- func (s *NodeSelect) StringsX(ctx context.Context) []string
- type NodeUpdate
- func (nu *NodeUpdate) AddEdgeTypeIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddEdgeTypes(e ...*EdgeType) *NodeUpdate
- func (nu *NodeUpdate) AddExternalReferenceIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddExternalReferences(e ...*ExternalReference) *NodeUpdate
- func (nu *NodeUpdate) AddHashIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddHashes(h ...*HashesEntry) *NodeUpdate
- func (nu *NodeUpdate) AddIdentifierIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddIdentifiers(i ...*IdentifiersEntry) *NodeUpdate
- func (nu *NodeUpdate) AddNodeIDs(ids ...string) *NodeUpdate
- func (nu *NodeUpdate) AddNodes(n ...*Node) *NodeUpdate
- func (nu *NodeUpdate) AddOriginatorIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddOriginators(p ...*Person) *NodeUpdate
- func (nu *NodeUpdate) AddPrimaryPurpose(p ...*Purpose) *NodeUpdate
- func (nu *NodeUpdate) AddPrimaryPurposeIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddSupplierIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) AddSuppliers(p ...*Person) *NodeUpdate
- func (nu *NodeUpdate) AppendAttribution(s []string) *NodeUpdate
- func (nu *NodeUpdate) AppendFileTypes(s []string) *NodeUpdate
- func (nu *NodeUpdate) AppendLicenses(s []string) *NodeUpdate
- func (nu *NodeUpdate) ClearEdgeTypes() *NodeUpdate
- func (nu *NodeUpdate) ClearExternalReferences() *NodeUpdate
- func (nu *NodeUpdate) ClearHashes() *NodeUpdate
- func (nu *NodeUpdate) ClearIdentifiers() *NodeUpdate
- func (nu *NodeUpdate) ClearNodeList() *NodeUpdate
- func (nu *NodeUpdate) ClearNodes() *NodeUpdate
- func (nu *NodeUpdate) ClearOriginators() *NodeUpdate
- func (nu *NodeUpdate) ClearPrimaryPurpose() *NodeUpdate
- func (nu *NodeUpdate) ClearSuppliers() *NodeUpdate
- func (nu *NodeUpdate) Exec(ctx context.Context) error
- func (nu *NodeUpdate) ExecX(ctx context.Context)
- func (nu *NodeUpdate) Mutation() *NodeMutation
- func (nu *NodeUpdate) RemoveEdgeTypeIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveEdgeTypes(e ...*EdgeType) *NodeUpdate
- func (nu *NodeUpdate) RemoveExternalReferenceIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveExternalReferences(e ...*ExternalReference) *NodeUpdate
- func (nu *NodeUpdate) RemoveHashIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveHashes(h ...*HashesEntry) *NodeUpdate
- func (nu *NodeUpdate) RemoveIdentifierIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveIdentifiers(i ...*IdentifiersEntry) *NodeUpdate
- func (nu *NodeUpdate) RemoveNodeIDs(ids ...string) *NodeUpdate
- func (nu *NodeUpdate) RemoveNodes(n ...*Node) *NodeUpdate
- func (nu *NodeUpdate) RemoveOriginatorIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveOriginators(p ...*Person) *NodeUpdate
- func (nu *NodeUpdate) RemovePrimaryPurpose(p ...*Purpose) *NodeUpdate
- func (nu *NodeUpdate) RemovePrimaryPurposeIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveSupplierIDs(ids ...int) *NodeUpdate
- func (nu *NodeUpdate) RemoveSuppliers(p ...*Person) *NodeUpdate
- func (nu *NodeUpdate) Save(ctx context.Context) (int, error)
- func (nu *NodeUpdate) SaveX(ctx context.Context) int
- func (nu *NodeUpdate) SetAttribution(s []string) *NodeUpdate
- func (nu *NodeUpdate) SetBuildDate(t time.Time) *NodeUpdate
- func (nu *NodeUpdate) SetComment(s string) *NodeUpdate
- func (nu *NodeUpdate) SetCopyright(s string) *NodeUpdate
- func (nu *NodeUpdate) SetDescription(s string) *NodeUpdate
- func (nu *NodeUpdate) SetFileName(s string) *NodeUpdate
- func (nu *NodeUpdate) SetFileTypes(s []string) *NodeUpdate
- func (nu *NodeUpdate) SetLicenseComments(s string) *NodeUpdate
- func (nu *NodeUpdate) SetLicenseConcluded(s string) *NodeUpdate
- func (nu *NodeUpdate) SetLicenses(s []string) *NodeUpdate
- func (nu *NodeUpdate) SetName(s string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableBuildDate(t *time.Time) *NodeUpdate
- func (nu *NodeUpdate) SetNillableComment(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableCopyright(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableDescription(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableFileName(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableLicenseComments(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableLicenseConcluded(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableName(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableReleaseDate(t *time.Time) *NodeUpdate
- func (nu *NodeUpdate) SetNillableSourceInfo(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableSummary(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableType(n *node.Type) *NodeUpdate
- func (nu *NodeUpdate) SetNillableURLDownload(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableURLHome(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNillableValidUntilDate(t *time.Time) *NodeUpdate
- func (nu *NodeUpdate) SetNillableVersion(s *string) *NodeUpdate
- func (nu *NodeUpdate) SetNodeList(n *NodeList) *NodeUpdate
- func (nu *NodeUpdate) SetNodeListID(id int) *NodeUpdate
- func (nu *NodeUpdate) SetReleaseDate(t time.Time) *NodeUpdate
- func (nu *NodeUpdate) SetSourceInfo(s string) *NodeUpdate
- func (nu *NodeUpdate) SetSummary(s string) *NodeUpdate
- func (nu *NodeUpdate) SetType(n node.Type) *NodeUpdate
- func (nu *NodeUpdate) SetURLDownload(s string) *NodeUpdate
- func (nu *NodeUpdate) SetURLHome(s string) *NodeUpdate
- func (nu *NodeUpdate) SetValidUntilDate(t time.Time) *NodeUpdate
- func (nu *NodeUpdate) SetVersion(s string) *NodeUpdate
- func (nu *NodeUpdate) Where(ps ...predicate.Node) *NodeUpdate
- type NodeUpdateOne
- func (nuo *NodeUpdateOne) AddEdgeTypeIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddEdgeTypes(e ...*EdgeType) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddExternalReferenceIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddExternalReferences(e ...*ExternalReference) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddHashIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddHashes(h ...*HashesEntry) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddIdentifierIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddIdentifiers(i ...*IdentifiersEntry) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddNodeIDs(ids ...string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddNodes(n ...*Node) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddOriginatorIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddOriginators(p ...*Person) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddPrimaryPurpose(p ...*Purpose) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddPrimaryPurposeIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddSupplierIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AddSuppliers(p ...*Person) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AppendAttribution(s []string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AppendFileTypes(s []string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) AppendLicenses(s []string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearEdgeTypes() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearExternalReferences() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearHashes() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearIdentifiers() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearNodeList() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearNodes() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearOriginators() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearPrimaryPurpose() *NodeUpdateOne
- func (nuo *NodeUpdateOne) ClearSuppliers() *NodeUpdateOne
- func (nuo *NodeUpdateOne) Exec(ctx context.Context) error
- func (nuo *NodeUpdateOne) ExecX(ctx context.Context)
- func (nuo *NodeUpdateOne) Mutation() *NodeMutation
- func (nuo *NodeUpdateOne) RemoveEdgeTypeIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveEdgeTypes(e ...*EdgeType) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveExternalReferenceIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveExternalReferences(e ...*ExternalReference) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveHashIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveHashes(h ...*HashesEntry) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveIdentifierIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveIdentifiers(i ...*IdentifiersEntry) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveNodeIDs(ids ...string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveNodes(n ...*Node) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveOriginatorIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveOriginators(p ...*Person) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemovePrimaryPurpose(p ...*Purpose) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemovePrimaryPurposeIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveSupplierIDs(ids ...int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) RemoveSuppliers(p ...*Person) *NodeUpdateOne
- func (nuo *NodeUpdateOne) Save(ctx context.Context) (*Node, error)
- func (nuo *NodeUpdateOne) SaveX(ctx context.Context) *Node
- func (nuo *NodeUpdateOne) Select(field string, fields ...string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetAttribution(s []string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetBuildDate(t time.Time) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetComment(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetCopyright(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetDescription(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetFileName(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetFileTypes(s []string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetLicenseComments(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetLicenseConcluded(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetLicenses(s []string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetName(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableBuildDate(t *time.Time) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableComment(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableCopyright(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableDescription(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableFileName(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableLicenseComments(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableLicenseConcluded(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableName(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableReleaseDate(t *time.Time) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableSourceInfo(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableSummary(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableType(n *node.Type) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableURLDownload(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableURLHome(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableValidUntilDate(t *time.Time) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNillableVersion(s *string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNodeList(n *NodeList) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetNodeListID(id int) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetReleaseDate(t time.Time) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetSourceInfo(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetSummary(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetType(n node.Type) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetURLDownload(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetURLHome(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetValidUntilDate(t time.Time) *NodeUpdateOne
- func (nuo *NodeUpdateOne) SetVersion(s string) *NodeUpdateOne
- func (nuo *NodeUpdateOne) Where(ps ...predicate.Node) *NodeUpdateOne
- type NodeUpsert
- func (u *NodeUpsert) SetAttribution(v []string) *NodeUpsert
- func (u *NodeUpsert) SetBuildDate(v time.Time) *NodeUpsert
- func (u *NodeUpsert) SetComment(v string) *NodeUpsert
- func (u *NodeUpsert) SetCopyright(v string) *NodeUpsert
- func (u *NodeUpsert) SetDescription(v string) *NodeUpsert
- func (u *NodeUpsert) SetFileName(v string) *NodeUpsert
- func (u *NodeUpsert) SetFileTypes(v []string) *NodeUpsert
- func (u *NodeUpsert) SetLicenseComments(v string) *NodeUpsert
- func (u *NodeUpsert) SetLicenseConcluded(v string) *NodeUpsert
- func (u *NodeUpsert) SetLicenses(v []string) *NodeUpsert
- func (u *NodeUpsert) SetName(v string) *NodeUpsert
- func (u *NodeUpsert) SetReleaseDate(v time.Time) *NodeUpsert
- func (u *NodeUpsert) SetSourceInfo(v string) *NodeUpsert
- func (u *NodeUpsert) SetSummary(v string) *NodeUpsert
- func (u *NodeUpsert) SetType(v node.Type) *NodeUpsert
- func (u *NodeUpsert) SetURLDownload(v string) *NodeUpsert
- func (u *NodeUpsert) SetURLHome(v string) *NodeUpsert
- func (u *NodeUpsert) SetValidUntilDate(v time.Time) *NodeUpsert
- func (u *NodeUpsert) SetVersion(v string) *NodeUpsert
- func (u *NodeUpsert) UpdateAttribution() *NodeUpsert
- func (u *NodeUpsert) UpdateBuildDate() *NodeUpsert
- func (u *NodeUpsert) UpdateComment() *NodeUpsert
- func (u *NodeUpsert) UpdateCopyright() *NodeUpsert
- func (u *NodeUpsert) UpdateDescription() *NodeUpsert
- func (u *NodeUpsert) UpdateFileName() *NodeUpsert
- func (u *NodeUpsert) UpdateFileTypes() *NodeUpsert
- func (u *NodeUpsert) UpdateLicenseComments() *NodeUpsert
- func (u *NodeUpsert) UpdateLicenseConcluded() *NodeUpsert
- func (u *NodeUpsert) UpdateLicenses() *NodeUpsert
- func (u *NodeUpsert) UpdateName() *NodeUpsert
- func (u *NodeUpsert) UpdateReleaseDate() *NodeUpsert
- func (u *NodeUpsert) UpdateSourceInfo() *NodeUpsert
- func (u *NodeUpsert) UpdateSummary() *NodeUpsert
- func (u *NodeUpsert) UpdateType() *NodeUpsert
- func (u *NodeUpsert) UpdateURLDownload() *NodeUpsert
- func (u *NodeUpsert) UpdateURLHome() *NodeUpsert
- func (u *NodeUpsert) UpdateValidUntilDate() *NodeUpsert
- func (u *NodeUpsert) UpdateVersion() *NodeUpsert
- type NodeUpsertBulk
- func (u *NodeUpsertBulk) DoNothing() *NodeUpsertBulk
- func (u *NodeUpsertBulk) Exec(ctx context.Context) error
- func (u *NodeUpsertBulk) ExecX(ctx context.Context)
- func (u *NodeUpsertBulk) Ignore() *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetAttribution(v []string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetBuildDate(v time.Time) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetComment(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetCopyright(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetDescription(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetFileName(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetFileTypes(v []string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetLicenseComments(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetLicenseConcluded(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetLicenses(v []string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetName(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetReleaseDate(v time.Time) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetSourceInfo(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetSummary(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetType(v node.Type) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetURLDownload(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetURLHome(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetValidUntilDate(v time.Time) *NodeUpsertBulk
- func (u *NodeUpsertBulk) SetVersion(v string) *NodeUpsertBulk
- func (u *NodeUpsertBulk) Update(set func(*NodeUpsert)) *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateAttribution() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateBuildDate() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateComment() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateCopyright() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateDescription() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateFileName() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateFileTypes() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateLicenseComments() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateLicenseConcluded() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateLicenses() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateName() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateNewValues() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateReleaseDate() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateSourceInfo() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateSummary() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateType() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateURLDownload() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateURLHome() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateValidUntilDate() *NodeUpsertBulk
- func (u *NodeUpsertBulk) UpdateVersion() *NodeUpsertBulk
- type NodeUpsertOne
- func (u *NodeUpsertOne) DoNothing() *NodeUpsertOne
- func (u *NodeUpsertOne) Exec(ctx context.Context) error
- func (u *NodeUpsertOne) ExecX(ctx context.Context)
- func (u *NodeUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *NodeUpsertOne) IDX(ctx context.Context) string
- func (u *NodeUpsertOne) Ignore() *NodeUpsertOne
- func (u *NodeUpsertOne) SetAttribution(v []string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetBuildDate(v time.Time) *NodeUpsertOne
- func (u *NodeUpsertOne) SetComment(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetCopyright(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetDescription(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetFileName(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetFileTypes(v []string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetLicenseComments(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetLicenseConcluded(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetLicenses(v []string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetName(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetReleaseDate(v time.Time) *NodeUpsertOne
- func (u *NodeUpsertOne) SetSourceInfo(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetSummary(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetType(v node.Type) *NodeUpsertOne
- func (u *NodeUpsertOne) SetURLDownload(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetURLHome(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) SetValidUntilDate(v time.Time) *NodeUpsertOne
- func (u *NodeUpsertOne) SetVersion(v string) *NodeUpsertOne
- func (u *NodeUpsertOne) Update(set func(*NodeUpsert)) *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateAttribution() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateBuildDate() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateComment() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateCopyright() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateDescription() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateFileName() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateFileTypes() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateLicenseComments() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateLicenseConcluded() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateLicenses() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateName() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateNewValues() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateReleaseDate() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateSourceInfo() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateSummary() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateType() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateURLDownload() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateURLHome() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateValidUntilDate() *NodeUpsertOne
- func (u *NodeUpsertOne) UpdateVersion() *NodeUpsertOne
- type Nodes
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Op
- type Option
- type OrderFunc
- type Person
- func (pe *Person) QueryContactOwner() *PersonQuery
- func (pe *Person) QueryContacts() *PersonQuery
- func (pe *Person) QueryMetadata() *MetadataQuery
- func (pe *Person) QueryNode() *NodeQuery
- func (pe *Person) String() string
- func (pe *Person) Unwrap() *Person
- func (pe *Person) Update() *PersonUpdateOne
- func (pe *Person) Value(name string) (ent.Value, error)
- type PersonClient
- func (c *PersonClient) Create() *PersonCreate
- func (c *PersonClient) CreateBulk(builders ...*PersonCreate) *PersonCreateBulk
- func (c *PersonClient) Delete() *PersonDelete
- func (c *PersonClient) DeleteOne(pe *Person) *PersonDeleteOne
- func (c *PersonClient) DeleteOneID(id int) *PersonDeleteOne
- func (c *PersonClient) Get(ctx context.Context, id int) (*Person, error)
- func (c *PersonClient) GetX(ctx context.Context, id int) *Person
- func (c *PersonClient) Hooks() []Hook
- func (c *PersonClient) Intercept(interceptors ...Interceptor)
- func (c *PersonClient) Interceptors() []Interceptor
- func (c *PersonClient) MapCreateBulk(slice any, setFunc func(*PersonCreate, int)) *PersonCreateBulk
- func (c *PersonClient) Query() *PersonQuery
- func (c *PersonClient) QueryContactOwner(pe *Person) *PersonQuery
- func (c *PersonClient) QueryContacts(pe *Person) *PersonQuery
- func (c *PersonClient) QueryMetadata(pe *Person) *MetadataQuery
- func (c *PersonClient) QueryNode(pe *Person) *NodeQuery
- func (c *PersonClient) Update() *PersonUpdate
- func (c *PersonClient) UpdateOne(pe *Person) *PersonUpdateOne
- func (c *PersonClient) UpdateOneID(id int) *PersonUpdateOne
- func (c *PersonClient) Use(hooks ...Hook)
- type PersonCreate
- func (pc *PersonCreate) AddContactIDs(ids ...int) *PersonCreate
- func (pc *PersonCreate) AddContacts(p ...*Person) *PersonCreate
- func (pc *PersonCreate) Exec(ctx context.Context) error
- func (pc *PersonCreate) ExecX(ctx context.Context)
- func (pc *PersonCreate) Mutation() *PersonMutation
- func (pc *PersonCreate) OnConflict(opts ...sql.ConflictOption) *PersonUpsertOne
- func (pc *PersonCreate) OnConflictColumns(columns ...string) *PersonUpsertOne
- func (pc *PersonCreate) Save(ctx context.Context) (*Person, error)
- func (pc *PersonCreate) SaveX(ctx context.Context) *Person
- func (pc *PersonCreate) SetContactOwner(p *Person) *PersonCreate
- func (pc *PersonCreate) SetContactOwnerID(id int) *PersonCreate
- func (pc *PersonCreate) SetEmail(s string) *PersonCreate
- func (pc *PersonCreate) SetIsOrg(b bool) *PersonCreate
- func (pc *PersonCreate) SetMetadata(m *Metadata) *PersonCreate
- func (pc *PersonCreate) SetMetadataID(id string) *PersonCreate
- func (pc *PersonCreate) SetName(s string) *PersonCreate
- func (pc *PersonCreate) SetNillableContactOwnerID(id *int) *PersonCreate
- func (pc *PersonCreate) SetNillableMetadataID(id *string) *PersonCreate
- func (pc *PersonCreate) SetNillableNodeID(id *string) *PersonCreate
- func (pc *PersonCreate) SetNode(n *Node) *PersonCreate
- func (pc *PersonCreate) SetNodeID(id string) *PersonCreate
- func (pc *PersonCreate) SetPhone(s string) *PersonCreate
- func (pc *PersonCreate) SetURL(s string) *PersonCreate
- type PersonCreateBulk
- func (pcb *PersonCreateBulk) Exec(ctx context.Context) error
- func (pcb *PersonCreateBulk) ExecX(ctx context.Context)
- func (pcb *PersonCreateBulk) OnConflict(opts ...sql.ConflictOption) *PersonUpsertBulk
- func (pcb *PersonCreateBulk) OnConflictColumns(columns ...string) *PersonUpsertBulk
- func (pcb *PersonCreateBulk) Save(ctx context.Context) ([]*Person, error)
- func (pcb *PersonCreateBulk) SaveX(ctx context.Context) []*Person
- type PersonDelete
- type PersonDeleteOne
- type PersonEdges
- type PersonGroupBy
- func (pgb *PersonGroupBy) Aggregate(fns ...AggregateFunc) *PersonGroupBy
- func (s *PersonGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *PersonGroupBy) BoolX(ctx context.Context) bool
- func (s *PersonGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *PersonGroupBy) BoolsX(ctx context.Context) []bool
- func (s *PersonGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *PersonGroupBy) Float64X(ctx context.Context) float64
- func (s *PersonGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *PersonGroupBy) Float64sX(ctx context.Context) []float64
- func (s *PersonGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *PersonGroupBy) IntX(ctx context.Context) int
- func (s *PersonGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *PersonGroupBy) IntsX(ctx context.Context) []int
- func (pgb *PersonGroupBy) Scan(ctx context.Context, v any) error
- func (s *PersonGroupBy) ScanX(ctx context.Context, v any)
- func (s *PersonGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *PersonGroupBy) StringX(ctx context.Context) string
- func (s *PersonGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *PersonGroupBy) StringsX(ctx context.Context) []string
- type PersonMutation
- func (m *PersonMutation) AddContactIDs(ids ...int)
- func (m *PersonMutation) AddField(name string, value ent.Value) error
- func (m *PersonMutation) AddedEdges() []string
- func (m *PersonMutation) AddedField(name string) (ent.Value, bool)
- func (m *PersonMutation) AddedFields() []string
- func (m *PersonMutation) AddedIDs(name string) []ent.Value
- func (m *PersonMutation) ClearContactOwner()
- func (m *PersonMutation) ClearContacts()
- func (m *PersonMutation) ClearEdge(name string) error
- func (m *PersonMutation) ClearField(name string) error
- func (m *PersonMutation) ClearMetadata()
- func (m *PersonMutation) ClearNode()
- func (m *PersonMutation) ClearedEdges() []string
- func (m *PersonMutation) ClearedFields() []string
- func (m PersonMutation) Client() *Client
- func (m *PersonMutation) ContactOwnerCleared() bool
- func (m *PersonMutation) ContactOwnerID() (id int, exists bool)
- func (m *PersonMutation) ContactOwnerIDs() (ids []int)
- func (m *PersonMutation) ContactsCleared() bool
- func (m *PersonMutation) ContactsIDs() (ids []int)
- func (m *PersonMutation) EdgeCleared(name string) bool
- func (m *PersonMutation) Email() (r string, exists bool)
- func (m *PersonMutation) Field(name string) (ent.Value, bool)
- func (m *PersonMutation) FieldCleared(name string) bool
- func (m *PersonMutation) Fields() []string
- func (m *PersonMutation) ID() (id int, exists bool)
- func (m *PersonMutation) IDs(ctx context.Context) ([]int, error)
- func (m *PersonMutation) IsOrg() (r bool, exists bool)
- func (m *PersonMutation) MetadataCleared() bool
- func (m *PersonMutation) MetadataID() (id string, exists bool)
- func (m *PersonMutation) MetadataIDs() (ids []string)
- func (m *PersonMutation) Name() (r string, exists bool)
- func (m *PersonMutation) NodeCleared() bool
- func (m *PersonMutation) NodeID() (id string, exists bool)
- func (m *PersonMutation) NodeIDs() (ids []string)
- func (m *PersonMutation) OldEmail(ctx context.Context) (v string, err error)
- func (m *PersonMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *PersonMutation) OldIsOrg(ctx context.Context) (v bool, err error)
- func (m *PersonMutation) OldName(ctx context.Context) (v string, err error)
- func (m *PersonMutation) OldPhone(ctx context.Context) (v string, err error)
- func (m *PersonMutation) OldURL(ctx context.Context) (v string, err error)
- func (m *PersonMutation) Op() Op
- func (m *PersonMutation) Phone() (r string, exists bool)
- func (m *PersonMutation) RemoveContactIDs(ids ...int)
- func (m *PersonMutation) RemovedContactsIDs() (ids []int)
- func (m *PersonMutation) RemovedEdges() []string
- func (m *PersonMutation) RemovedIDs(name string) []ent.Value
- func (m *PersonMutation) ResetContactOwner()
- func (m *PersonMutation) ResetContacts()
- func (m *PersonMutation) ResetEdge(name string) error
- func (m *PersonMutation) ResetEmail()
- func (m *PersonMutation) ResetField(name string) error
- func (m *PersonMutation) ResetIsOrg()
- func (m *PersonMutation) ResetMetadata()
- func (m *PersonMutation) ResetName()
- func (m *PersonMutation) ResetNode()
- func (m *PersonMutation) ResetPhone()
- func (m *PersonMutation) ResetURL()
- func (m *PersonMutation) SetContactOwnerID(id int)
- func (m *PersonMutation) SetEmail(s string)
- func (m *PersonMutation) SetField(name string, value ent.Value) error
- func (m *PersonMutation) SetIsOrg(b bool)
- func (m *PersonMutation) SetMetadataID(id string)
- func (m *PersonMutation) SetName(s string)
- func (m *PersonMutation) SetNodeID(id string)
- func (m *PersonMutation) SetOp(op Op)
- func (m *PersonMutation) SetPhone(s string)
- func (m *PersonMutation) SetURL(s string)
- func (m PersonMutation) Tx() (*Tx, error)
- func (m *PersonMutation) Type() string
- func (m *PersonMutation) URL() (r string, exists bool)
- func (m *PersonMutation) Where(ps ...predicate.Person)
- func (m *PersonMutation) WhereP(ps ...func(*sql.Selector))
- type PersonQuery
- func (pq *PersonQuery) Aggregate(fns ...AggregateFunc) *PersonSelect
- func (pq *PersonQuery) All(ctx context.Context) ([]*Person, error)
- func (pq *PersonQuery) AllX(ctx context.Context) []*Person
- func (pq *PersonQuery) Clone() *PersonQuery
- func (pq *PersonQuery) Count(ctx context.Context) (int, error)
- func (pq *PersonQuery) CountX(ctx context.Context) int
- func (pq *PersonQuery) Exist(ctx context.Context) (bool, error)
- func (pq *PersonQuery) ExistX(ctx context.Context) bool
- func (pq *PersonQuery) First(ctx context.Context) (*Person, error)
- func (pq *PersonQuery) FirstID(ctx context.Context) (id int, err error)
- func (pq *PersonQuery) FirstIDX(ctx context.Context) int
- func (pq *PersonQuery) FirstX(ctx context.Context) *Person
- func (pq *PersonQuery) GroupBy(field string, fields ...string) *PersonGroupBy
- func (pq *PersonQuery) IDs(ctx context.Context) (ids []int, err error)
- func (pq *PersonQuery) IDsX(ctx context.Context) []int
- func (pq *PersonQuery) Limit(limit int) *PersonQuery
- func (pq *PersonQuery) Offset(offset int) *PersonQuery
- func (pq *PersonQuery) Only(ctx context.Context) (*Person, error)
- func (pq *PersonQuery) OnlyID(ctx context.Context) (id int, err error)
- func (pq *PersonQuery) OnlyIDX(ctx context.Context) int
- func (pq *PersonQuery) OnlyX(ctx context.Context) *Person
- func (pq *PersonQuery) Order(o ...person.OrderOption) *PersonQuery
- func (pq *PersonQuery) QueryContactOwner() *PersonQuery
- func (pq *PersonQuery) QueryContacts() *PersonQuery
- func (pq *PersonQuery) QueryMetadata() *MetadataQuery
- func (pq *PersonQuery) QueryNode() *NodeQuery
- func (pq *PersonQuery) Select(fields ...string) *PersonSelect
- func (pq *PersonQuery) Unique(unique bool) *PersonQuery
- func (pq *PersonQuery) Where(ps ...predicate.Person) *PersonQuery
- func (pq *PersonQuery) WithContactOwner(opts ...func(*PersonQuery)) *PersonQuery
- func (pq *PersonQuery) WithContacts(opts ...func(*PersonQuery)) *PersonQuery
- func (pq *PersonQuery) WithMetadata(opts ...func(*MetadataQuery)) *PersonQuery
- func (pq *PersonQuery) WithNode(opts ...func(*NodeQuery)) *PersonQuery
- type PersonSelect
- func (ps *PersonSelect) Aggregate(fns ...AggregateFunc) *PersonSelect
- func (s *PersonSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *PersonSelect) BoolX(ctx context.Context) bool
- func (s *PersonSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *PersonSelect) BoolsX(ctx context.Context) []bool
- func (s *PersonSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *PersonSelect) Float64X(ctx context.Context) float64
- func (s *PersonSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *PersonSelect) Float64sX(ctx context.Context) []float64
- func (s *PersonSelect) Int(ctx context.Context) (_ int, err error)
- func (s *PersonSelect) IntX(ctx context.Context) int
- func (s *PersonSelect) Ints(ctx context.Context) ([]int, error)
- func (s *PersonSelect) IntsX(ctx context.Context) []int
- func (ps *PersonSelect) Scan(ctx context.Context, v any) error
- func (s *PersonSelect) ScanX(ctx context.Context, v any)
- func (s *PersonSelect) String(ctx context.Context) (_ string, err error)
- func (s *PersonSelect) StringX(ctx context.Context) string
- func (s *PersonSelect) Strings(ctx context.Context) ([]string, error)
- func (s *PersonSelect) StringsX(ctx context.Context) []string
- type PersonUpdate
- func (pu *PersonUpdate) AddContactIDs(ids ...int) *PersonUpdate
- func (pu *PersonUpdate) AddContacts(p ...*Person) *PersonUpdate
- func (pu *PersonUpdate) ClearContactOwner() *PersonUpdate
- func (pu *PersonUpdate) ClearContacts() *PersonUpdate
- func (pu *PersonUpdate) ClearMetadata() *PersonUpdate
- func (pu *PersonUpdate) ClearNode() *PersonUpdate
- func (pu *PersonUpdate) Exec(ctx context.Context) error
- func (pu *PersonUpdate) ExecX(ctx context.Context)
- func (pu *PersonUpdate) Mutation() *PersonMutation
- func (pu *PersonUpdate) RemoveContactIDs(ids ...int) *PersonUpdate
- func (pu *PersonUpdate) RemoveContacts(p ...*Person) *PersonUpdate
- func (pu *PersonUpdate) Save(ctx context.Context) (int, error)
- func (pu *PersonUpdate) SaveX(ctx context.Context) int
- func (pu *PersonUpdate) SetContactOwner(p *Person) *PersonUpdate
- func (pu *PersonUpdate) SetContactOwnerID(id int) *PersonUpdate
- func (pu *PersonUpdate) SetEmail(s string) *PersonUpdate
- func (pu *PersonUpdate) SetIsOrg(b bool) *PersonUpdate
- func (pu *PersonUpdate) SetMetadata(m *Metadata) *PersonUpdate
- func (pu *PersonUpdate) SetMetadataID(id string) *PersonUpdate
- func (pu *PersonUpdate) SetName(s string) *PersonUpdate
- func (pu *PersonUpdate) SetNillableContactOwnerID(id *int) *PersonUpdate
- func (pu *PersonUpdate) SetNillableEmail(s *string) *PersonUpdate
- func (pu *PersonUpdate) SetNillableIsOrg(b *bool) *PersonUpdate
- func (pu *PersonUpdate) SetNillableMetadataID(id *string) *PersonUpdate
- func (pu *PersonUpdate) SetNillableName(s *string) *PersonUpdate
- func (pu *PersonUpdate) SetNillableNodeID(id *string) *PersonUpdate
- func (pu *PersonUpdate) SetNillablePhone(s *string) *PersonUpdate
- func (pu *PersonUpdate) SetNillableURL(s *string) *PersonUpdate
- func (pu *PersonUpdate) SetNode(n *Node) *PersonUpdate
- func (pu *PersonUpdate) SetNodeID(id string) *PersonUpdate
- func (pu *PersonUpdate) SetPhone(s string) *PersonUpdate
- func (pu *PersonUpdate) SetURL(s string) *PersonUpdate
- func (pu *PersonUpdate) Where(ps ...predicate.Person) *PersonUpdate
- type PersonUpdateOne
- func (puo *PersonUpdateOne) AddContactIDs(ids ...int) *PersonUpdateOne
- func (puo *PersonUpdateOne) AddContacts(p ...*Person) *PersonUpdateOne
- func (puo *PersonUpdateOne) ClearContactOwner() *PersonUpdateOne
- func (puo *PersonUpdateOne) ClearContacts() *PersonUpdateOne
- func (puo *PersonUpdateOne) ClearMetadata() *PersonUpdateOne
- func (puo *PersonUpdateOne) ClearNode() *PersonUpdateOne
- func (puo *PersonUpdateOne) Exec(ctx context.Context) error
- func (puo *PersonUpdateOne) ExecX(ctx context.Context)
- func (puo *PersonUpdateOne) Mutation() *PersonMutation
- func (puo *PersonUpdateOne) RemoveContactIDs(ids ...int) *PersonUpdateOne
- func (puo *PersonUpdateOne) RemoveContacts(p ...*Person) *PersonUpdateOne
- func (puo *PersonUpdateOne) Save(ctx context.Context) (*Person, error)
- func (puo *PersonUpdateOne) SaveX(ctx context.Context) *Person
- func (puo *PersonUpdateOne) Select(field string, fields ...string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetContactOwner(p *Person) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetContactOwnerID(id int) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetEmail(s string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetIsOrg(b bool) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetMetadata(m *Metadata) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetMetadataID(id string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetName(s string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableContactOwnerID(id *int) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableEmail(s *string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableIsOrg(b *bool) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableMetadataID(id *string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableName(s *string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableNodeID(id *string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillablePhone(s *string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNillableURL(s *string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNode(n *Node) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetNodeID(id string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetPhone(s string) *PersonUpdateOne
- func (puo *PersonUpdateOne) SetURL(s string) *PersonUpdateOne
- func (puo *PersonUpdateOne) Where(ps ...predicate.Person) *PersonUpdateOne
- type PersonUpsert
- func (u *PersonUpsert) SetEmail(v string) *PersonUpsert
- func (u *PersonUpsert) SetIsOrg(v bool) *PersonUpsert
- func (u *PersonUpsert) SetName(v string) *PersonUpsert
- func (u *PersonUpsert) SetPhone(v string) *PersonUpsert
- func (u *PersonUpsert) SetURL(v string) *PersonUpsert
- func (u *PersonUpsert) UpdateEmail() *PersonUpsert
- func (u *PersonUpsert) UpdateIsOrg() *PersonUpsert
- func (u *PersonUpsert) UpdateName() *PersonUpsert
- func (u *PersonUpsert) UpdatePhone() *PersonUpsert
- func (u *PersonUpsert) UpdateURL() *PersonUpsert
- type PersonUpsertBulk
- func (u *PersonUpsertBulk) DoNothing() *PersonUpsertBulk
- func (u *PersonUpsertBulk) Exec(ctx context.Context) error
- func (u *PersonUpsertBulk) ExecX(ctx context.Context)
- func (u *PersonUpsertBulk) Ignore() *PersonUpsertBulk
- func (u *PersonUpsertBulk) SetEmail(v string) *PersonUpsertBulk
- func (u *PersonUpsertBulk) SetIsOrg(v bool) *PersonUpsertBulk
- func (u *PersonUpsertBulk) SetName(v string) *PersonUpsertBulk
- func (u *PersonUpsertBulk) SetPhone(v string) *PersonUpsertBulk
- func (u *PersonUpsertBulk) SetURL(v string) *PersonUpsertBulk
- func (u *PersonUpsertBulk) Update(set func(*PersonUpsert)) *PersonUpsertBulk
- func (u *PersonUpsertBulk) UpdateEmail() *PersonUpsertBulk
- func (u *PersonUpsertBulk) UpdateIsOrg() *PersonUpsertBulk
- func (u *PersonUpsertBulk) UpdateName() *PersonUpsertBulk
- func (u *PersonUpsertBulk) UpdateNewValues() *PersonUpsertBulk
- func (u *PersonUpsertBulk) UpdatePhone() *PersonUpsertBulk
- func (u *PersonUpsertBulk) UpdateURL() *PersonUpsertBulk
- type PersonUpsertOne
- func (u *PersonUpsertOne) DoNothing() *PersonUpsertOne
- func (u *PersonUpsertOne) Exec(ctx context.Context) error
- func (u *PersonUpsertOne) ExecX(ctx context.Context)
- func (u *PersonUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *PersonUpsertOne) IDX(ctx context.Context) int
- func (u *PersonUpsertOne) Ignore() *PersonUpsertOne
- func (u *PersonUpsertOne) SetEmail(v string) *PersonUpsertOne
- func (u *PersonUpsertOne) SetIsOrg(v bool) *PersonUpsertOne
- func (u *PersonUpsertOne) SetName(v string) *PersonUpsertOne
- func (u *PersonUpsertOne) SetPhone(v string) *PersonUpsertOne
- func (u *PersonUpsertOne) SetURL(v string) *PersonUpsertOne
- func (u *PersonUpsertOne) Update(set func(*PersonUpsert)) *PersonUpsertOne
- func (u *PersonUpsertOne) UpdateEmail() *PersonUpsertOne
- func (u *PersonUpsertOne) UpdateIsOrg() *PersonUpsertOne
- func (u *PersonUpsertOne) UpdateName() *PersonUpsertOne
- func (u *PersonUpsertOne) UpdateNewValues() *PersonUpsertOne
- func (u *PersonUpsertOne) UpdatePhone() *PersonUpsertOne
- func (u *PersonUpsertOne) UpdateURL() *PersonUpsertOne
- type Persons
- type Policy
- type Purpose
- type PurposeClient
- func (c *PurposeClient) Create() *PurposeCreate
- func (c *PurposeClient) CreateBulk(builders ...*PurposeCreate) *PurposeCreateBulk
- func (c *PurposeClient) Delete() *PurposeDelete
- func (c *PurposeClient) DeleteOne(pu *Purpose) *PurposeDeleteOne
- func (c *PurposeClient) DeleteOneID(id int) *PurposeDeleteOne
- func (c *PurposeClient) Get(ctx context.Context, id int) (*Purpose, error)
- func (c *PurposeClient) GetX(ctx context.Context, id int) *Purpose
- func (c *PurposeClient) Hooks() []Hook
- func (c *PurposeClient) Intercept(interceptors ...Interceptor)
- func (c *PurposeClient) Interceptors() []Interceptor
- func (c *PurposeClient) MapCreateBulk(slice any, setFunc func(*PurposeCreate, int)) *PurposeCreateBulk
- func (c *PurposeClient) Query() *PurposeQuery
- func (c *PurposeClient) QueryNode(pu *Purpose) *NodeQuery
- func (c *PurposeClient) Update() *PurposeUpdate
- func (c *PurposeClient) UpdateOne(pu *Purpose) *PurposeUpdateOne
- func (c *PurposeClient) UpdateOneID(id int) *PurposeUpdateOne
- func (c *PurposeClient) Use(hooks ...Hook)
- type PurposeCreate
- func (pc *PurposeCreate) AddNode(n ...*Node) *PurposeCreate
- func (pc *PurposeCreate) AddNodeIDs(ids ...string) *PurposeCreate
- func (pc *PurposeCreate) Exec(ctx context.Context) error
- func (pc *PurposeCreate) ExecX(ctx context.Context)
- func (pc *PurposeCreate) Mutation() *PurposeMutation
- func (pc *PurposeCreate) OnConflict(opts ...sql.ConflictOption) *PurposeUpsertOne
- func (pc *PurposeCreate) OnConflictColumns(columns ...string) *PurposeUpsertOne
- func (pc *PurposeCreate) Save(ctx context.Context) (*Purpose, error)
- func (pc *PurposeCreate) SaveX(ctx context.Context) *Purpose
- func (pc *PurposeCreate) SetPrimaryPurpose(pp purpose.PrimaryPurpose) *PurposeCreate
- type PurposeCreateBulk
- func (pcb *PurposeCreateBulk) Exec(ctx context.Context) error
- func (pcb *PurposeCreateBulk) ExecX(ctx context.Context)
- func (pcb *PurposeCreateBulk) OnConflict(opts ...sql.ConflictOption) *PurposeUpsertBulk
- func (pcb *PurposeCreateBulk) OnConflictColumns(columns ...string) *PurposeUpsertBulk
- func (pcb *PurposeCreateBulk) Save(ctx context.Context) ([]*Purpose, error)
- func (pcb *PurposeCreateBulk) SaveX(ctx context.Context) []*Purpose
- type PurposeDelete
- type PurposeDeleteOne
- type PurposeEdges
- type PurposeGroupBy
- func (pgb *PurposeGroupBy) Aggregate(fns ...AggregateFunc) *PurposeGroupBy
- func (s *PurposeGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *PurposeGroupBy) BoolX(ctx context.Context) bool
- func (s *PurposeGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *PurposeGroupBy) BoolsX(ctx context.Context) []bool
- func (s *PurposeGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *PurposeGroupBy) Float64X(ctx context.Context) float64
- func (s *PurposeGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *PurposeGroupBy) Float64sX(ctx context.Context) []float64
- func (s *PurposeGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *PurposeGroupBy) IntX(ctx context.Context) int
- func (s *PurposeGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *PurposeGroupBy) IntsX(ctx context.Context) []int
- func (pgb *PurposeGroupBy) Scan(ctx context.Context, v any) error
- func (s *PurposeGroupBy) ScanX(ctx context.Context, v any)
- func (s *PurposeGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *PurposeGroupBy) StringX(ctx context.Context) string
- func (s *PurposeGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *PurposeGroupBy) StringsX(ctx context.Context) []string
- type PurposeMutation
- func (m *PurposeMutation) AddField(name string, value ent.Value) error
- func (m *PurposeMutation) AddNodeIDs(ids ...string)
- func (m *PurposeMutation) AddedEdges() []string
- func (m *PurposeMutation) AddedField(name string) (ent.Value, bool)
- func (m *PurposeMutation) AddedFields() []string
- func (m *PurposeMutation) AddedIDs(name string) []ent.Value
- func (m *PurposeMutation) ClearEdge(name string) error
- func (m *PurposeMutation) ClearField(name string) error
- func (m *PurposeMutation) ClearNode()
- func (m *PurposeMutation) ClearedEdges() []string
- func (m *PurposeMutation) ClearedFields() []string
- func (m PurposeMutation) Client() *Client
- func (m *PurposeMutation) EdgeCleared(name string) bool
- func (m *PurposeMutation) Field(name string) (ent.Value, bool)
- func (m *PurposeMutation) FieldCleared(name string) bool
- func (m *PurposeMutation) Fields() []string
- func (m *PurposeMutation) ID() (id int, exists bool)
- func (m *PurposeMutation) IDs(ctx context.Context) ([]int, error)
- func (m *PurposeMutation) NodeCleared() bool
- func (m *PurposeMutation) NodeIDs() (ids []string)
- func (m *PurposeMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *PurposeMutation) OldPrimaryPurpose(ctx context.Context) (v purpose.PrimaryPurpose, err error)
- func (m *PurposeMutation) Op() Op
- func (m *PurposeMutation) PrimaryPurpose() (r purpose.PrimaryPurpose, exists bool)
- func (m *PurposeMutation) RemoveNodeIDs(ids ...string)
- func (m *PurposeMutation) RemovedEdges() []string
- func (m *PurposeMutation) RemovedIDs(name string) []ent.Value
- func (m *PurposeMutation) RemovedNodeIDs() (ids []string)
- func (m *PurposeMutation) ResetEdge(name string) error
- func (m *PurposeMutation) ResetField(name string) error
- func (m *PurposeMutation) ResetNode()
- func (m *PurposeMutation) ResetPrimaryPurpose()
- func (m *PurposeMutation) SetField(name string, value ent.Value) error
- func (m *PurposeMutation) SetOp(op Op)
- func (m *PurposeMutation) SetPrimaryPurpose(pp purpose.PrimaryPurpose)
- func (m PurposeMutation) Tx() (*Tx, error)
- func (m *PurposeMutation) Type() string
- func (m *PurposeMutation) Where(ps ...predicate.Purpose)
- func (m *PurposeMutation) WhereP(ps ...func(*sql.Selector))
- type PurposeQuery
- func (pq *PurposeQuery) Aggregate(fns ...AggregateFunc) *PurposeSelect
- func (pq *PurposeQuery) All(ctx context.Context) ([]*Purpose, error)
- func (pq *PurposeQuery) AllX(ctx context.Context) []*Purpose
- func (pq *PurposeQuery) Clone() *PurposeQuery
- func (pq *PurposeQuery) Count(ctx context.Context) (int, error)
- func (pq *PurposeQuery) CountX(ctx context.Context) int
- func (pq *PurposeQuery) Exist(ctx context.Context) (bool, error)
- func (pq *PurposeQuery) ExistX(ctx context.Context) bool
- func (pq *PurposeQuery) First(ctx context.Context) (*Purpose, error)
- func (pq *PurposeQuery) FirstID(ctx context.Context) (id int, err error)
- func (pq *PurposeQuery) FirstIDX(ctx context.Context) int
- func (pq *PurposeQuery) FirstX(ctx context.Context) *Purpose
- func (pq *PurposeQuery) GroupBy(field string, fields ...string) *PurposeGroupBy
- func (pq *PurposeQuery) IDs(ctx context.Context) (ids []int, err error)
- func (pq *PurposeQuery) IDsX(ctx context.Context) []int
- func (pq *PurposeQuery) Limit(limit int) *PurposeQuery
- func (pq *PurposeQuery) Offset(offset int) *PurposeQuery
- func (pq *PurposeQuery) Only(ctx context.Context) (*Purpose, error)
- func (pq *PurposeQuery) OnlyID(ctx context.Context) (id int, err error)
- func (pq *PurposeQuery) OnlyIDX(ctx context.Context) int
- func (pq *PurposeQuery) OnlyX(ctx context.Context) *Purpose
- func (pq *PurposeQuery) Order(o ...purpose.OrderOption) *PurposeQuery
- func (pq *PurposeQuery) QueryNode() *NodeQuery
- func (pq *PurposeQuery) Select(fields ...string) *PurposeSelect
- func (pq *PurposeQuery) Unique(unique bool) *PurposeQuery
- func (pq *PurposeQuery) Where(ps ...predicate.Purpose) *PurposeQuery
- func (pq *PurposeQuery) WithNode(opts ...func(*NodeQuery)) *PurposeQuery
- type PurposeSelect
- func (ps *PurposeSelect) Aggregate(fns ...AggregateFunc) *PurposeSelect
- func (s *PurposeSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *PurposeSelect) BoolX(ctx context.Context) bool
- func (s *PurposeSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *PurposeSelect) BoolsX(ctx context.Context) []bool
- func (s *PurposeSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *PurposeSelect) Float64X(ctx context.Context) float64
- func (s *PurposeSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *PurposeSelect) Float64sX(ctx context.Context) []float64
- func (s *PurposeSelect) Int(ctx context.Context) (_ int, err error)
- func (s *PurposeSelect) IntX(ctx context.Context) int
- func (s *PurposeSelect) Ints(ctx context.Context) ([]int, error)
- func (s *PurposeSelect) IntsX(ctx context.Context) []int
- func (ps *PurposeSelect) Scan(ctx context.Context, v any) error
- func (s *PurposeSelect) ScanX(ctx context.Context, v any)
- func (s *PurposeSelect) String(ctx context.Context) (_ string, err error)
- func (s *PurposeSelect) StringX(ctx context.Context) string
- func (s *PurposeSelect) Strings(ctx context.Context) ([]string, error)
- func (s *PurposeSelect) StringsX(ctx context.Context) []string
- type PurposeUpdate
- func (pu *PurposeUpdate) AddNode(n ...*Node) *PurposeUpdate
- func (pu *PurposeUpdate) AddNodeIDs(ids ...string) *PurposeUpdate
- func (pu *PurposeUpdate) ClearNode() *PurposeUpdate
- func (pu *PurposeUpdate) Exec(ctx context.Context) error
- func (pu *PurposeUpdate) ExecX(ctx context.Context)
- func (pu *PurposeUpdate) Mutation() *PurposeMutation
- func (pu *PurposeUpdate) RemoveNode(n ...*Node) *PurposeUpdate
- func (pu *PurposeUpdate) RemoveNodeIDs(ids ...string) *PurposeUpdate
- func (pu *PurposeUpdate) Save(ctx context.Context) (int, error)
- func (pu *PurposeUpdate) SaveX(ctx context.Context) int
- func (pu *PurposeUpdate) SetNillablePrimaryPurpose(pp *purpose.PrimaryPurpose) *PurposeUpdate
- func (pu *PurposeUpdate) SetPrimaryPurpose(pp purpose.PrimaryPurpose) *PurposeUpdate
- func (pu *PurposeUpdate) Where(ps ...predicate.Purpose) *PurposeUpdate
- type PurposeUpdateOne
- func (puo *PurposeUpdateOne) AddNode(n ...*Node) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) AddNodeIDs(ids ...string) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) ClearNode() *PurposeUpdateOne
- func (puo *PurposeUpdateOne) Exec(ctx context.Context) error
- func (puo *PurposeUpdateOne) ExecX(ctx context.Context)
- func (puo *PurposeUpdateOne) Mutation() *PurposeMutation
- func (puo *PurposeUpdateOne) RemoveNode(n ...*Node) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) RemoveNodeIDs(ids ...string) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) Save(ctx context.Context) (*Purpose, error)
- func (puo *PurposeUpdateOne) SaveX(ctx context.Context) *Purpose
- func (puo *PurposeUpdateOne) Select(field string, fields ...string) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) SetNillablePrimaryPurpose(pp *purpose.PrimaryPurpose) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) SetPrimaryPurpose(pp purpose.PrimaryPurpose) *PurposeUpdateOne
- func (puo *PurposeUpdateOne) Where(ps ...predicate.Purpose) *PurposeUpdateOne
- type PurposeUpsert
- type PurposeUpsertBulk
- func (u *PurposeUpsertBulk) DoNothing() *PurposeUpsertBulk
- func (u *PurposeUpsertBulk) Exec(ctx context.Context) error
- func (u *PurposeUpsertBulk) ExecX(ctx context.Context)
- func (u *PurposeUpsertBulk) Ignore() *PurposeUpsertBulk
- func (u *PurposeUpsertBulk) SetPrimaryPurpose(v purpose.PrimaryPurpose) *PurposeUpsertBulk
- func (u *PurposeUpsertBulk) Update(set func(*PurposeUpsert)) *PurposeUpsertBulk
- func (u *PurposeUpsertBulk) UpdateNewValues() *PurposeUpsertBulk
- func (u *PurposeUpsertBulk) UpdatePrimaryPurpose() *PurposeUpsertBulk
- type PurposeUpsertOne
- func (u *PurposeUpsertOne) DoNothing() *PurposeUpsertOne
- func (u *PurposeUpsertOne) Exec(ctx context.Context) error
- func (u *PurposeUpsertOne) ExecX(ctx context.Context)
- func (u *PurposeUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *PurposeUpsertOne) IDX(ctx context.Context) int
- func (u *PurposeUpsertOne) Ignore() *PurposeUpsertOne
- func (u *PurposeUpsertOne) SetPrimaryPurpose(v purpose.PrimaryPurpose) *PurposeUpsertOne
- func (u *PurposeUpsertOne) Update(set func(*PurposeUpsert)) *PurposeUpsertOne
- func (u *PurposeUpsertOne) UpdateNewValues() *PurposeUpsertOne
- func (u *PurposeUpsertOne) UpdatePrimaryPurpose() *PurposeUpsertOne
- type Purposes
- type Querier
- type QuerierFunc
- type Query
- type QueryContext
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type Tool
- type ToolClient
- func (c *ToolClient) Create() *ToolCreate
- func (c *ToolClient) CreateBulk(builders ...*ToolCreate) *ToolCreateBulk
- func (c *ToolClient) Delete() *ToolDelete
- func (c *ToolClient) DeleteOne(t *Tool) *ToolDeleteOne
- func (c *ToolClient) DeleteOneID(id int) *ToolDeleteOne
- func (c *ToolClient) Get(ctx context.Context, id int) (*Tool, error)
- func (c *ToolClient) GetX(ctx context.Context, id int) *Tool
- func (c *ToolClient) Hooks() []Hook
- func (c *ToolClient) Intercept(interceptors ...Interceptor)
- func (c *ToolClient) Interceptors() []Interceptor
- func (c *ToolClient) MapCreateBulk(slice any, setFunc func(*ToolCreate, int)) *ToolCreateBulk
- func (c *ToolClient) Query() *ToolQuery
- func (c *ToolClient) QueryMetadata(t *Tool) *MetadataQuery
- func (c *ToolClient) Update() *ToolUpdate
- func (c *ToolClient) UpdateOne(t *Tool) *ToolUpdateOne
- func (c *ToolClient) UpdateOneID(id int) *ToolUpdateOne
- func (c *ToolClient) Use(hooks ...Hook)
- type ToolCreate
- func (tc *ToolCreate) Exec(ctx context.Context) error
- func (tc *ToolCreate) ExecX(ctx context.Context)
- func (tc *ToolCreate) Mutation() *ToolMutation
- func (tc *ToolCreate) OnConflict(opts ...sql.ConflictOption) *ToolUpsertOne
- func (tc *ToolCreate) OnConflictColumns(columns ...string) *ToolUpsertOne
- func (tc *ToolCreate) Save(ctx context.Context) (*Tool, error)
- func (tc *ToolCreate) SaveX(ctx context.Context) *Tool
- func (tc *ToolCreate) SetMetadata(m *Metadata) *ToolCreate
- func (tc *ToolCreate) SetMetadataID(id string) *ToolCreate
- func (tc *ToolCreate) SetName(s string) *ToolCreate
- func (tc *ToolCreate) SetNillableMetadataID(id *string) *ToolCreate
- func (tc *ToolCreate) SetVendor(s string) *ToolCreate
- func (tc *ToolCreate) SetVersion(s string) *ToolCreate
- type ToolCreateBulk
- func (tcb *ToolCreateBulk) Exec(ctx context.Context) error
- func (tcb *ToolCreateBulk) ExecX(ctx context.Context)
- func (tcb *ToolCreateBulk) OnConflict(opts ...sql.ConflictOption) *ToolUpsertBulk
- func (tcb *ToolCreateBulk) OnConflictColumns(columns ...string) *ToolUpsertBulk
- func (tcb *ToolCreateBulk) Save(ctx context.Context) ([]*Tool, error)
- func (tcb *ToolCreateBulk) SaveX(ctx context.Context) []*Tool
- type ToolDelete
- type ToolDeleteOne
- type ToolEdges
- type ToolGroupBy
- func (tgb *ToolGroupBy) Aggregate(fns ...AggregateFunc) *ToolGroupBy
- func (s *ToolGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *ToolGroupBy) BoolX(ctx context.Context) bool
- func (s *ToolGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *ToolGroupBy) BoolsX(ctx context.Context) []bool
- func (s *ToolGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *ToolGroupBy) Float64X(ctx context.Context) float64
- func (s *ToolGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *ToolGroupBy) Float64sX(ctx context.Context) []float64
- func (s *ToolGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *ToolGroupBy) IntX(ctx context.Context) int
- func (s *ToolGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *ToolGroupBy) IntsX(ctx context.Context) []int
- func (tgb *ToolGroupBy) Scan(ctx context.Context, v any) error
- func (s *ToolGroupBy) ScanX(ctx context.Context, v any)
- func (s *ToolGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *ToolGroupBy) StringX(ctx context.Context) string
- func (s *ToolGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *ToolGroupBy) StringsX(ctx context.Context) []string
- type ToolMutation
- func (m *ToolMutation) AddField(name string, value ent.Value) error
- func (m *ToolMutation) AddedEdges() []string
- func (m *ToolMutation) AddedField(name string) (ent.Value, bool)
- func (m *ToolMutation) AddedFields() []string
- func (m *ToolMutation) AddedIDs(name string) []ent.Value
- func (m *ToolMutation) ClearEdge(name string) error
- func (m *ToolMutation) ClearField(name string) error
- func (m *ToolMutation) ClearMetadata()
- func (m *ToolMutation) ClearedEdges() []string
- func (m *ToolMutation) ClearedFields() []string
- func (m ToolMutation) Client() *Client
- func (m *ToolMutation) EdgeCleared(name string) bool
- func (m *ToolMutation) Field(name string) (ent.Value, bool)
- func (m *ToolMutation) FieldCleared(name string) bool
- func (m *ToolMutation) Fields() []string
- func (m *ToolMutation) ID() (id int, exists bool)
- func (m *ToolMutation) IDs(ctx context.Context) ([]int, error)
- func (m *ToolMutation) MetadataCleared() bool
- func (m *ToolMutation) MetadataID() (id string, exists bool)
- func (m *ToolMutation) MetadataIDs() (ids []string)
- func (m *ToolMutation) Name() (r string, exists bool)
- func (m *ToolMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ToolMutation) OldName(ctx context.Context) (v string, err error)
- func (m *ToolMutation) OldVendor(ctx context.Context) (v string, err error)
- func (m *ToolMutation) OldVersion(ctx context.Context) (v string, err error)
- func (m *ToolMutation) Op() Op
- func (m *ToolMutation) RemovedEdges() []string
- func (m *ToolMutation) RemovedIDs(name string) []ent.Value
- func (m *ToolMutation) ResetEdge(name string) error
- func (m *ToolMutation) ResetField(name string) error
- func (m *ToolMutation) ResetMetadata()
- func (m *ToolMutation) ResetName()
- func (m *ToolMutation) ResetVendor()
- func (m *ToolMutation) ResetVersion()
- func (m *ToolMutation) SetField(name string, value ent.Value) error
- func (m *ToolMutation) SetMetadataID(id string)
- func (m *ToolMutation) SetName(s string)
- func (m *ToolMutation) SetOp(op Op)
- func (m *ToolMutation) SetVendor(s string)
- func (m *ToolMutation) SetVersion(s string)
- func (m ToolMutation) Tx() (*Tx, error)
- func (m *ToolMutation) Type() string
- func (m *ToolMutation) Vendor() (r string, exists bool)
- func (m *ToolMutation) Version() (r string, exists bool)
- func (m *ToolMutation) Where(ps ...predicate.Tool)
- func (m *ToolMutation) WhereP(ps ...func(*sql.Selector))
- type ToolQuery
- func (tq *ToolQuery) Aggregate(fns ...AggregateFunc) *ToolSelect
- func (tq *ToolQuery) All(ctx context.Context) ([]*Tool, error)
- func (tq *ToolQuery) AllX(ctx context.Context) []*Tool
- func (tq *ToolQuery) Clone() *ToolQuery
- func (tq *ToolQuery) Count(ctx context.Context) (int, error)
- func (tq *ToolQuery) CountX(ctx context.Context) int
- func (tq *ToolQuery) Exist(ctx context.Context) (bool, error)
- func (tq *ToolQuery) ExistX(ctx context.Context) bool
- func (tq *ToolQuery) First(ctx context.Context) (*Tool, error)
- func (tq *ToolQuery) FirstID(ctx context.Context) (id int, err error)
- func (tq *ToolQuery) FirstIDX(ctx context.Context) int
- func (tq *ToolQuery) FirstX(ctx context.Context) *Tool
- func (tq *ToolQuery) GroupBy(field string, fields ...string) *ToolGroupBy
- func (tq *ToolQuery) IDs(ctx context.Context) (ids []int, err error)
- func (tq *ToolQuery) IDsX(ctx context.Context) []int
- func (tq *ToolQuery) Limit(limit int) *ToolQuery
- func (tq *ToolQuery) Offset(offset int) *ToolQuery
- func (tq *ToolQuery) Only(ctx context.Context) (*Tool, error)
- func (tq *ToolQuery) OnlyID(ctx context.Context) (id int, err error)
- func (tq *ToolQuery) OnlyIDX(ctx context.Context) int
- func (tq *ToolQuery) OnlyX(ctx context.Context) *Tool
- func (tq *ToolQuery) Order(o ...tool.OrderOption) *ToolQuery
- func (tq *ToolQuery) QueryMetadata() *MetadataQuery
- func (tq *ToolQuery) Select(fields ...string) *ToolSelect
- func (tq *ToolQuery) Unique(unique bool) *ToolQuery
- func (tq *ToolQuery) Where(ps ...predicate.Tool) *ToolQuery
- func (tq *ToolQuery) WithMetadata(opts ...func(*MetadataQuery)) *ToolQuery
- type ToolSelect
- func (ts *ToolSelect) Aggregate(fns ...AggregateFunc) *ToolSelect
- func (s *ToolSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *ToolSelect) BoolX(ctx context.Context) bool
- func (s *ToolSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *ToolSelect) BoolsX(ctx context.Context) []bool
- func (s *ToolSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *ToolSelect) Float64X(ctx context.Context) float64
- func (s *ToolSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *ToolSelect) Float64sX(ctx context.Context) []float64
- func (s *ToolSelect) Int(ctx context.Context) (_ int, err error)
- func (s *ToolSelect) IntX(ctx context.Context) int
- func (s *ToolSelect) Ints(ctx context.Context) ([]int, error)
- func (s *ToolSelect) IntsX(ctx context.Context) []int
- func (ts *ToolSelect) Scan(ctx context.Context, v any) error
- func (s *ToolSelect) ScanX(ctx context.Context, v any)
- func (s *ToolSelect) String(ctx context.Context) (_ string, err error)
- func (s *ToolSelect) StringX(ctx context.Context) string
- func (s *ToolSelect) Strings(ctx context.Context) ([]string, error)
- func (s *ToolSelect) StringsX(ctx context.Context) []string
- type ToolUpdate
- func (tu *ToolUpdate) ClearMetadata() *ToolUpdate
- func (tu *ToolUpdate) Exec(ctx context.Context) error
- func (tu *ToolUpdate) ExecX(ctx context.Context)
- func (tu *ToolUpdate) Mutation() *ToolMutation
- func (tu *ToolUpdate) Save(ctx context.Context) (int, error)
- func (tu *ToolUpdate) SaveX(ctx context.Context) int
- func (tu *ToolUpdate) SetMetadata(m *Metadata) *ToolUpdate
- func (tu *ToolUpdate) SetMetadataID(id string) *ToolUpdate
- func (tu *ToolUpdate) SetName(s string) *ToolUpdate
- func (tu *ToolUpdate) SetNillableMetadataID(id *string) *ToolUpdate
- func (tu *ToolUpdate) SetNillableName(s *string) *ToolUpdate
- func (tu *ToolUpdate) SetNillableVendor(s *string) *ToolUpdate
- func (tu *ToolUpdate) SetNillableVersion(s *string) *ToolUpdate
- func (tu *ToolUpdate) SetVendor(s string) *ToolUpdate
- func (tu *ToolUpdate) SetVersion(s string) *ToolUpdate
- func (tu *ToolUpdate) Where(ps ...predicate.Tool) *ToolUpdate
- type ToolUpdateOne
- func (tuo *ToolUpdateOne) ClearMetadata() *ToolUpdateOne
- func (tuo *ToolUpdateOne) Exec(ctx context.Context) error
- func (tuo *ToolUpdateOne) ExecX(ctx context.Context)
- func (tuo *ToolUpdateOne) Mutation() *ToolMutation
- func (tuo *ToolUpdateOne) Save(ctx context.Context) (*Tool, error)
- func (tuo *ToolUpdateOne) SaveX(ctx context.Context) *Tool
- func (tuo *ToolUpdateOne) Select(field string, fields ...string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetMetadata(m *Metadata) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetMetadataID(id string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetName(s string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetNillableMetadataID(id *string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetNillableName(s *string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetNillableVendor(s *string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetNillableVersion(s *string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetVendor(s string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) SetVersion(s string) *ToolUpdateOne
- func (tuo *ToolUpdateOne) Where(ps ...predicate.Tool) *ToolUpdateOne
- type ToolUpsert
- func (u *ToolUpsert) SetName(v string) *ToolUpsert
- func (u *ToolUpsert) SetVendor(v string) *ToolUpsert
- func (u *ToolUpsert) SetVersion(v string) *ToolUpsert
- func (u *ToolUpsert) UpdateName() *ToolUpsert
- func (u *ToolUpsert) UpdateVendor() *ToolUpsert
- func (u *ToolUpsert) UpdateVersion() *ToolUpsert
- type ToolUpsertBulk
- func (u *ToolUpsertBulk) DoNothing() *ToolUpsertBulk
- func (u *ToolUpsertBulk) Exec(ctx context.Context) error
- func (u *ToolUpsertBulk) ExecX(ctx context.Context)
- func (u *ToolUpsertBulk) Ignore() *ToolUpsertBulk
- func (u *ToolUpsertBulk) SetName(v string) *ToolUpsertBulk
- func (u *ToolUpsertBulk) SetVendor(v string) *ToolUpsertBulk
- func (u *ToolUpsertBulk) SetVersion(v string) *ToolUpsertBulk
- func (u *ToolUpsertBulk) Update(set func(*ToolUpsert)) *ToolUpsertBulk
- func (u *ToolUpsertBulk) UpdateName() *ToolUpsertBulk
- func (u *ToolUpsertBulk) UpdateNewValues() *ToolUpsertBulk
- func (u *ToolUpsertBulk) UpdateVendor() *ToolUpsertBulk
- func (u *ToolUpsertBulk) UpdateVersion() *ToolUpsertBulk
- type ToolUpsertOne
- func (u *ToolUpsertOne) DoNothing() *ToolUpsertOne
- func (u *ToolUpsertOne) Exec(ctx context.Context) error
- func (u *ToolUpsertOne) ExecX(ctx context.Context)
- func (u *ToolUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *ToolUpsertOne) IDX(ctx context.Context) int
- func (u *ToolUpsertOne) Ignore() *ToolUpsertOne
- func (u *ToolUpsertOne) SetName(v string) *ToolUpsertOne
- func (u *ToolUpsertOne) SetVendor(v string) *ToolUpsertOne
- func (u *ToolUpsertOne) SetVersion(v string) *ToolUpsertOne
- func (u *ToolUpsertOne) Update(set func(*ToolUpsert)) *ToolUpsertOne
- func (u *ToolUpsertOne) UpdateName() *ToolUpsertOne
- func (u *ToolUpsertOne) UpdateNewValues() *ToolUpsertOne
- func (u *ToolUpsertOne) UpdateVendor() *ToolUpsertOne
- func (u *ToolUpsertOne) UpdateVersion() *ToolUpsertOne
- type Tools
- type TraverseFunc
- type Traverser
- type Tx
- 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. TypeDocument = "Document" TypeDocumentType = "DocumentType" TypeEdgeType = "EdgeType" TypeExternalReference = "ExternalReference" TypeHashesEntry = "HashesEntry" TypeIdentifiersEntry = "IdentifiersEntry" TypeMetadata = "Metadata" TypeNode = "Node" TypeNodeList = "NodeList" TypePerson = "Person" TypePurpose = "Purpose" TypeTool = "Tool" )
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 Client ¶
type Client struct { // Schema is the client for creating, migrating and dropping schema. Schema *migrate.Schema // Document is the client for interacting with the Document builders. Document *DocumentClient // DocumentType is the client for interacting with the DocumentType builders. DocumentType *DocumentTypeClient // EdgeType is the client for interacting with the EdgeType builders. EdgeType *EdgeTypeClient // ExternalReference is the client for interacting with the ExternalReference builders. ExternalReference *ExternalReferenceClient // HashesEntry is the client for interacting with the HashesEntry builders. HashesEntry *HashesEntryClient // IdentifiersEntry is the client for interacting with the IdentifiersEntry builders. IdentifiersEntry *IdentifiersEntryClient // Metadata is the client for interacting with the Metadata builders. Metadata *MetadataClient // Node is the client for interacting with the Node builders. Node *NodeClient // NodeList is the client for interacting with the NodeList builders. NodeList *NodeListClient // Person is the client for interacting with the Person builders. Person *PersonClient // Purpose is the client for interacting with the Purpose builders. Purpose *PurposeClient // Tool is the client for interacting with the Tool builders. Tool *ToolClient // 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(). Document. 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 Document ¶
type Document struct { // ID of the ent. ID int `json:"id,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the DocumentQuery when eager-loading is set. Edges DocumentEdges `json:"edges"` // contains filtered or unexported fields }
Document is the model entity for the Document schema.
func (*Document) QueryMetadata ¶
func (d *Document) QueryMetadata() *MetadataQuery
QueryMetadata queries the "metadata" edge of the Document entity.
func (*Document) QueryNodeList ¶
func (d *Document) QueryNodeList() *NodeListQuery
QueryNodeList queries the "node_list" edge of the Document entity.
func (*Document) Unwrap ¶
Unwrap unwraps the Document 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 (*Document) Update ¶
func (d *Document) Update() *DocumentUpdateOne
Update returns a builder for updating this Document. Note that you need to call Document.Unwrap() before calling this method if this Document was returned from a transaction, and the transaction was committed or rolled back.
type DocumentClient ¶
type DocumentClient struct {
// contains filtered or unexported fields
}
DocumentClient is a client for the Document schema.
func NewDocumentClient ¶
func NewDocumentClient(c config) *DocumentClient
NewDocumentClient returns a client for the Document from the given config.
func (*DocumentClient) Create ¶
func (c *DocumentClient) Create() *DocumentCreate
Create returns a builder for creating a Document entity.
func (*DocumentClient) CreateBulk ¶
func (c *DocumentClient) CreateBulk(builders ...*DocumentCreate) *DocumentCreateBulk
CreateBulk returns a builder for creating a bulk of Document entities.
func (*DocumentClient) Delete ¶
func (c *DocumentClient) Delete() *DocumentDelete
Delete returns a delete builder for Document.
func (*DocumentClient) DeleteOne ¶
func (c *DocumentClient) DeleteOne(d *Document) *DocumentDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*DocumentClient) DeleteOneID ¶
func (c *DocumentClient) DeleteOneID(id int) *DocumentDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*DocumentClient) GetX ¶
func (c *DocumentClient) GetX(ctx context.Context, id int) *Document
GetX is like Get, but panics if an error occurs.
func (*DocumentClient) Hooks ¶
func (c *DocumentClient) Hooks() []Hook
Hooks returns the client hooks.
func (*DocumentClient) Intercept ¶
func (c *DocumentClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `document.Intercept(f(g(h())))`.
func (*DocumentClient) Interceptors ¶
func (c *DocumentClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*DocumentClient) MapCreateBulk ¶
func (c *DocumentClient) MapCreateBulk(slice any, setFunc func(*DocumentCreate, int)) *DocumentCreateBulk
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 (*DocumentClient) Query ¶
func (c *DocumentClient) Query() *DocumentQuery
Query returns a query builder for Document.
func (*DocumentClient) QueryMetadata ¶
func (c *DocumentClient) QueryMetadata(d *Document) *MetadataQuery
QueryMetadata queries the metadata edge of a Document.
func (*DocumentClient) QueryNodeList ¶
func (c *DocumentClient) QueryNodeList(d *Document) *NodeListQuery
QueryNodeList queries the node_list edge of a Document.
func (*DocumentClient) Update ¶
func (c *DocumentClient) Update() *DocumentUpdate
Update returns an update builder for Document.
func (*DocumentClient) UpdateOne ¶
func (c *DocumentClient) UpdateOne(d *Document) *DocumentUpdateOne
UpdateOne returns an update builder for the given entity.
func (*DocumentClient) UpdateOneID ¶
func (c *DocumentClient) UpdateOneID(id int) *DocumentUpdateOne
UpdateOneID returns an update builder for the given id.
func (*DocumentClient) Use ¶
func (c *DocumentClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `document.Hooks(f(g(h())))`.
type DocumentCreate ¶
type DocumentCreate struct {
// contains filtered or unexported fields
}
DocumentCreate is the builder for creating a Document entity.
func (*DocumentCreate) Exec ¶
func (dc *DocumentCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentCreate) ExecX ¶
func (dc *DocumentCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentCreate) Mutation ¶
func (dc *DocumentCreate) Mutation() *DocumentMutation
Mutation returns the DocumentMutation object of the builder.
func (*DocumentCreate) OnConflict ¶
func (dc *DocumentCreate) OnConflict(opts ...sql.ConflictOption) *DocumentUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Document.Create(). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). Exec(ctx)
func (*DocumentCreate) OnConflictColumns ¶
func (dc *DocumentCreate) OnConflictColumns(columns ...string) *DocumentUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Document.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*DocumentCreate) Save ¶
func (dc *DocumentCreate) Save(ctx context.Context) (*Document, error)
Save creates the Document in the database.
func (*DocumentCreate) SaveX ¶
func (dc *DocumentCreate) SaveX(ctx context.Context) *Document
SaveX calls Save and panics if Save returns an error.
func (*DocumentCreate) SetMetadata ¶
func (dc *DocumentCreate) SetMetadata(m *Metadata) *DocumentCreate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*DocumentCreate) SetMetadataID ¶
func (dc *DocumentCreate) SetMetadataID(id string) *DocumentCreate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*DocumentCreate) SetNodeList ¶
func (dc *DocumentCreate) SetNodeList(n *NodeList) *DocumentCreate
SetNodeList sets the "node_list" edge to the NodeList entity.
func (*DocumentCreate) SetNodeListID ¶
func (dc *DocumentCreate) SetNodeListID(id int) *DocumentCreate
SetNodeListID sets the "node_list" edge to the NodeList entity by ID.
type DocumentCreateBulk ¶
type DocumentCreateBulk struct {
// contains filtered or unexported fields
}
DocumentCreateBulk is the builder for creating many Document entities in bulk.
func (*DocumentCreateBulk) Exec ¶
func (dcb *DocumentCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentCreateBulk) ExecX ¶
func (dcb *DocumentCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentCreateBulk) OnConflict ¶
func (dcb *DocumentCreateBulk) OnConflict(opts ...sql.ConflictOption) *DocumentUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Document.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). Exec(ctx)
func (*DocumentCreateBulk) OnConflictColumns ¶
func (dcb *DocumentCreateBulk) OnConflictColumns(columns ...string) *DocumentUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Document.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type DocumentDelete ¶
type DocumentDelete struct {
// contains filtered or unexported fields
}
DocumentDelete is the builder for deleting a Document entity.
func (*DocumentDelete) Exec ¶
func (dd *DocumentDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*DocumentDelete) ExecX ¶
func (dd *DocumentDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*DocumentDelete) Where ¶
func (dd *DocumentDelete) Where(ps ...predicate.Document) *DocumentDelete
Where appends a list predicates to the DocumentDelete builder.
type DocumentDeleteOne ¶
type DocumentDeleteOne struct {
// contains filtered or unexported fields
}
DocumentDeleteOne is the builder for deleting a single Document entity.
func (*DocumentDeleteOne) Exec ¶
func (ddo *DocumentDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*DocumentDeleteOne) ExecX ¶
func (ddo *DocumentDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentDeleteOne) Where ¶
func (ddo *DocumentDeleteOne) Where(ps ...predicate.Document) *DocumentDeleteOne
Where appends a list predicates to the DocumentDelete builder.
type DocumentEdges ¶
type DocumentEdges struct { // Metadata holds the value of the metadata edge. Metadata *Metadata `json:"metadata,omitempty"` // NodeList holds the value of the node_list edge. NodeList *NodeList `json:"node_list,omitempty"` // contains filtered or unexported fields }
DocumentEdges holds the relations/edges for other nodes in the graph.
func (DocumentEdges) MetadataOrErr ¶
func (e DocumentEdges) MetadataOrErr() (*Metadata, error)
MetadataOrErr returns the Metadata value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (DocumentEdges) NodeListOrErr ¶
func (e DocumentEdges) NodeListOrErr() (*NodeList, error)
NodeListOrErr returns the NodeList value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type DocumentGroupBy ¶
type DocumentGroupBy struct {
// contains filtered or unexported fields
}
DocumentGroupBy is the group-by builder for Document entities.
func (*DocumentGroupBy) Aggregate ¶
func (dgb *DocumentGroupBy) Aggregate(fns ...AggregateFunc) *DocumentGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*DocumentGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*DocumentGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*DocumentGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*DocumentGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*DocumentGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*DocumentGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*DocumentGroupBy) Scan ¶
func (dgb *DocumentGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*DocumentGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type DocumentMutation ¶
type DocumentMutation struct {
// contains filtered or unexported fields
}
DocumentMutation represents an operation that mutates the Document nodes in the graph.
func (*DocumentMutation) AddField ¶
func (m *DocumentMutation) 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 (*DocumentMutation) AddedEdges ¶
func (m *DocumentMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*DocumentMutation) AddedField ¶
func (m *DocumentMutation) 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 (*DocumentMutation) AddedFields ¶
func (m *DocumentMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*DocumentMutation) AddedIDs ¶
func (m *DocumentMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*DocumentMutation) ClearEdge ¶
func (m *DocumentMutation) 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 (*DocumentMutation) ClearField ¶
func (m *DocumentMutation) 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 (*DocumentMutation) ClearMetadata ¶
func (m *DocumentMutation) ClearMetadata()
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*DocumentMutation) ClearNodeList ¶
func (m *DocumentMutation) ClearNodeList()
ClearNodeList clears the "node_list" edge to the NodeList entity.
func (*DocumentMutation) ClearedEdges ¶
func (m *DocumentMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*DocumentMutation) ClearedFields ¶
func (m *DocumentMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (DocumentMutation) Client ¶
func (m DocumentMutation) 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 (*DocumentMutation) EdgeCleared ¶
func (m *DocumentMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*DocumentMutation) Field ¶
func (m *DocumentMutation) 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 (*DocumentMutation) FieldCleared ¶
func (m *DocumentMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*DocumentMutation) Fields ¶
func (m *DocumentMutation) 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 (*DocumentMutation) ID ¶
func (m *DocumentMutation) 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 (*DocumentMutation) IDs ¶
func (m *DocumentMutation) 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 (*DocumentMutation) MetadataCleared ¶
func (m *DocumentMutation) MetadataCleared() bool
MetadataCleared reports if the "metadata" edge to the Metadata entity was cleared.
func (*DocumentMutation) MetadataID ¶
func (m *DocumentMutation) MetadataID() (id string, exists bool)
MetadataID returns the "metadata" edge ID in the mutation.
func (*DocumentMutation) MetadataIDs ¶
func (m *DocumentMutation) MetadataIDs() (ids []string)
MetadataIDs returns the "metadata" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use MetadataID instead. It exists only for internal usage by the builders.
func (*DocumentMutation) NodeListCleared ¶
func (m *DocumentMutation) NodeListCleared() bool
NodeListCleared reports if the "node_list" edge to the NodeList entity was cleared.
func (*DocumentMutation) NodeListID ¶
func (m *DocumentMutation) NodeListID() (id int, exists bool)
NodeListID returns the "node_list" edge ID in the mutation.
func (*DocumentMutation) NodeListIDs ¶
func (m *DocumentMutation) NodeListIDs() (ids []int)
NodeListIDs returns the "node_list" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use NodeListID instead. It exists only for internal usage by the builders.
func (*DocumentMutation) 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 (*DocumentMutation) RemovedEdges ¶
func (m *DocumentMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*DocumentMutation) RemovedIDs ¶
func (m *DocumentMutation) 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 (*DocumentMutation) ResetEdge ¶
func (m *DocumentMutation) 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 (*DocumentMutation) ResetField ¶
func (m *DocumentMutation) 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 (*DocumentMutation) ResetMetadata ¶
func (m *DocumentMutation) ResetMetadata()
ResetMetadata resets all changes to the "metadata" edge.
func (*DocumentMutation) ResetNodeList ¶
func (m *DocumentMutation) ResetNodeList()
ResetNodeList resets all changes to the "node_list" edge.
func (*DocumentMutation) SetField ¶
func (m *DocumentMutation) 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 (*DocumentMutation) SetMetadataID ¶
func (m *DocumentMutation) SetMetadataID(id string)
SetMetadataID sets the "metadata" edge to the Metadata entity by id.
func (*DocumentMutation) SetNodeListID ¶
func (m *DocumentMutation) SetNodeListID(id int)
SetNodeListID sets the "node_list" edge to the NodeList entity by id.
func (*DocumentMutation) SetOp ¶
func (m *DocumentMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (DocumentMutation) Tx ¶
func (m DocumentMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*DocumentMutation) Type ¶
func (m *DocumentMutation) Type() string
Type returns the node type of this mutation (Document).
func (*DocumentMutation) Where ¶
func (m *DocumentMutation) Where(ps ...predicate.Document)
Where appends a list predicates to the DocumentMutation builder.
func (*DocumentMutation) WhereP ¶
func (m *DocumentMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the DocumentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type DocumentQuery ¶
type DocumentQuery struct {
// contains filtered or unexported fields
}
DocumentQuery is the builder for querying Document entities.
func (*DocumentQuery) Aggregate ¶
func (dq *DocumentQuery) Aggregate(fns ...AggregateFunc) *DocumentSelect
Aggregate returns a DocumentSelect configured with the given aggregations.
func (*DocumentQuery) All ¶
func (dq *DocumentQuery) All(ctx context.Context) ([]*Document, error)
All executes the query and returns a list of Documents.
func (*DocumentQuery) AllX ¶
func (dq *DocumentQuery) AllX(ctx context.Context) []*Document
AllX is like All, but panics if an error occurs.
func (*DocumentQuery) Clone ¶
func (dq *DocumentQuery) Clone() *DocumentQuery
Clone returns a duplicate of the DocumentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*DocumentQuery) Count ¶
func (dq *DocumentQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*DocumentQuery) CountX ¶
func (dq *DocumentQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*DocumentQuery) Exist ¶
func (dq *DocumentQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*DocumentQuery) ExistX ¶
func (dq *DocumentQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*DocumentQuery) First ¶
func (dq *DocumentQuery) First(ctx context.Context) (*Document, error)
First returns the first Document entity from the query. Returns a *NotFoundError when no Document was found.
func (*DocumentQuery) FirstID ¶
func (dq *DocumentQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Document ID from the query. Returns a *NotFoundError when no Document ID was found.
func (*DocumentQuery) FirstIDX ¶
func (dq *DocumentQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*DocumentQuery) FirstX ¶
func (dq *DocumentQuery) FirstX(ctx context.Context) *Document
FirstX is like First, but panics if an error occurs.
func (*DocumentQuery) GroupBy ¶
func (dq *DocumentQuery) GroupBy(field string, fields ...string) *DocumentGroupBy
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.
func (*DocumentQuery) IDs ¶
func (dq *DocumentQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of Document IDs.
func (*DocumentQuery) IDsX ¶
func (dq *DocumentQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*DocumentQuery) Limit ¶
func (dq *DocumentQuery) Limit(limit int) *DocumentQuery
Limit the number of records to be returned by this query.
func (*DocumentQuery) Offset ¶
func (dq *DocumentQuery) Offset(offset int) *DocumentQuery
Offset to start from.
func (*DocumentQuery) Only ¶
func (dq *DocumentQuery) Only(ctx context.Context) (*Document, error)
Only returns a single Document entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Document entity is found. Returns a *NotFoundError when no Document entities are found.
func (*DocumentQuery) OnlyID ¶
func (dq *DocumentQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Document ID in the query. Returns a *NotSingularError when more than one Document ID is found. Returns a *NotFoundError when no entities are found.
func (*DocumentQuery) OnlyIDX ¶
func (dq *DocumentQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*DocumentQuery) OnlyX ¶
func (dq *DocumentQuery) OnlyX(ctx context.Context) *Document
OnlyX is like Only, but panics if an error occurs.
func (*DocumentQuery) Order ¶
func (dq *DocumentQuery) Order(o ...document.OrderOption) *DocumentQuery
Order specifies how the records should be ordered.
func (*DocumentQuery) QueryMetadata ¶
func (dq *DocumentQuery) QueryMetadata() *MetadataQuery
QueryMetadata chains the current query on the "metadata" edge.
func (*DocumentQuery) QueryNodeList ¶
func (dq *DocumentQuery) QueryNodeList() *NodeListQuery
QueryNodeList chains the current query on the "node_list" edge.
func (*DocumentQuery) Select ¶
func (dq *DocumentQuery) Select(fields ...string) *DocumentSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
func (*DocumentQuery) Unique ¶
func (dq *DocumentQuery) Unique(unique bool) *DocumentQuery
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 (*DocumentQuery) Where ¶
func (dq *DocumentQuery) Where(ps ...predicate.Document) *DocumentQuery
Where adds a new predicate for the DocumentQuery builder.
func (*DocumentQuery) WithMetadata ¶
func (dq *DocumentQuery) WithMetadata(opts ...func(*MetadataQuery)) *DocumentQuery
WithMetadata tells the query-builder to eager-load the nodes that are connected to the "metadata" edge. The optional arguments are used to configure the query builder of the edge.
func (*DocumentQuery) WithNodeList ¶
func (dq *DocumentQuery) WithNodeList(opts ...func(*NodeListQuery)) *DocumentQuery
WithNodeList tells the query-builder to eager-load the nodes that are connected to the "node_list" edge. The optional arguments are used to configure the query builder of the edge.
type DocumentSelect ¶
type DocumentSelect struct { *DocumentQuery // contains filtered or unexported fields }
DocumentSelect is the builder for selecting fields of Document entities.
func (*DocumentSelect) Aggregate ¶
func (ds *DocumentSelect) Aggregate(fns ...AggregateFunc) *DocumentSelect
Aggregate adds the given aggregation functions to the selector query.
func (*DocumentSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*DocumentSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*DocumentSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*DocumentSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*DocumentSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*DocumentSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*DocumentSelect) Scan ¶
func (ds *DocumentSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*DocumentSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type DocumentType ¶
type DocumentType struct { // ID of the ent. ID int `json:"id,omitempty"` // Type holds the value of the "type" field. Type *documenttype.Type `json:"type,omitempty"` // Name holds the value of the "name" field. Name *string `json:"name,omitempty"` // Description holds the value of the "description" field. Description *string `json:"description,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the DocumentTypeQuery when eager-loading is set. Edges DocumentTypeEdges `json:"edges"` // contains filtered or unexported fields }
DocumentType is the model entity for the DocumentType schema.
func (*DocumentType) QueryMetadata ¶
func (dt *DocumentType) QueryMetadata() *MetadataQuery
QueryMetadata queries the "metadata" edge of the DocumentType entity.
func (*DocumentType) String ¶
func (dt *DocumentType) String() string
String implements the fmt.Stringer.
func (*DocumentType) Unwrap ¶
func (dt *DocumentType) Unwrap() *DocumentType
Unwrap unwraps the DocumentType 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 (*DocumentType) Update ¶
func (dt *DocumentType) Update() *DocumentTypeUpdateOne
Update returns a builder for updating this DocumentType. Note that you need to call DocumentType.Unwrap() before calling this method if this DocumentType was returned from a transaction, and the transaction was committed or rolled back.
type DocumentTypeClient ¶
type DocumentTypeClient struct {
// contains filtered or unexported fields
}
DocumentTypeClient is a client for the DocumentType schema.
func NewDocumentTypeClient ¶
func NewDocumentTypeClient(c config) *DocumentTypeClient
NewDocumentTypeClient returns a client for the DocumentType from the given config.
func (*DocumentTypeClient) Create ¶
func (c *DocumentTypeClient) Create() *DocumentTypeCreate
Create returns a builder for creating a DocumentType entity.
func (*DocumentTypeClient) CreateBulk ¶
func (c *DocumentTypeClient) CreateBulk(builders ...*DocumentTypeCreate) *DocumentTypeCreateBulk
CreateBulk returns a builder for creating a bulk of DocumentType entities.
func (*DocumentTypeClient) Delete ¶
func (c *DocumentTypeClient) Delete() *DocumentTypeDelete
Delete returns a delete builder for DocumentType.
func (*DocumentTypeClient) DeleteOne ¶
func (c *DocumentTypeClient) DeleteOne(dt *DocumentType) *DocumentTypeDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*DocumentTypeClient) DeleteOneID ¶
func (c *DocumentTypeClient) DeleteOneID(id int) *DocumentTypeDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*DocumentTypeClient) Get ¶
func (c *DocumentTypeClient) Get(ctx context.Context, id int) (*DocumentType, error)
Get returns a DocumentType entity by its id.
func (*DocumentTypeClient) GetX ¶
func (c *DocumentTypeClient) GetX(ctx context.Context, id int) *DocumentType
GetX is like Get, but panics if an error occurs.
func (*DocumentTypeClient) Hooks ¶
func (c *DocumentTypeClient) Hooks() []Hook
Hooks returns the client hooks.
func (*DocumentTypeClient) Intercept ¶
func (c *DocumentTypeClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `documenttype.Intercept(f(g(h())))`.
func (*DocumentTypeClient) Interceptors ¶
func (c *DocumentTypeClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*DocumentTypeClient) MapCreateBulk ¶
func (c *DocumentTypeClient) MapCreateBulk(slice any, setFunc func(*DocumentTypeCreate, int)) *DocumentTypeCreateBulk
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 (*DocumentTypeClient) Query ¶
func (c *DocumentTypeClient) Query() *DocumentTypeQuery
Query returns a query builder for DocumentType.
func (*DocumentTypeClient) QueryMetadata ¶
func (c *DocumentTypeClient) QueryMetadata(dt *DocumentType) *MetadataQuery
QueryMetadata queries the metadata edge of a DocumentType.
func (*DocumentTypeClient) Update ¶
func (c *DocumentTypeClient) Update() *DocumentTypeUpdate
Update returns an update builder for DocumentType.
func (*DocumentTypeClient) UpdateOne ¶
func (c *DocumentTypeClient) UpdateOne(dt *DocumentType) *DocumentTypeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*DocumentTypeClient) UpdateOneID ¶
func (c *DocumentTypeClient) UpdateOneID(id int) *DocumentTypeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*DocumentTypeClient) Use ¶
func (c *DocumentTypeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `documenttype.Hooks(f(g(h())))`.
type DocumentTypeCreate ¶
type DocumentTypeCreate struct {
// contains filtered or unexported fields
}
DocumentTypeCreate is the builder for creating a DocumentType entity.
func (*DocumentTypeCreate) Exec ¶
func (dtc *DocumentTypeCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentTypeCreate) ExecX ¶
func (dtc *DocumentTypeCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeCreate) Mutation ¶
func (dtc *DocumentTypeCreate) Mutation() *DocumentTypeMutation
Mutation returns the DocumentTypeMutation object of the builder.
func (*DocumentTypeCreate) OnConflict ¶
func (dtc *DocumentTypeCreate) OnConflict(opts ...sql.ConflictOption) *DocumentTypeUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.DocumentType.Create(). SetType(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.DocumentTypeUpsert) { SetType(v+v). }). Exec(ctx)
func (*DocumentTypeCreate) OnConflictColumns ¶
func (dtc *DocumentTypeCreate) OnConflictColumns(columns ...string) *DocumentTypeUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.DocumentType.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*DocumentTypeCreate) Save ¶
func (dtc *DocumentTypeCreate) Save(ctx context.Context) (*DocumentType, error)
Save creates the DocumentType in the database.
func (*DocumentTypeCreate) SaveX ¶
func (dtc *DocumentTypeCreate) SaveX(ctx context.Context) *DocumentType
SaveX calls Save and panics if Save returns an error.
func (*DocumentTypeCreate) SetDescription ¶
func (dtc *DocumentTypeCreate) SetDescription(s string) *DocumentTypeCreate
SetDescription sets the "description" field.
func (*DocumentTypeCreate) SetMetadata ¶
func (dtc *DocumentTypeCreate) SetMetadata(m *Metadata) *DocumentTypeCreate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*DocumentTypeCreate) SetMetadataID ¶
func (dtc *DocumentTypeCreate) SetMetadataID(id string) *DocumentTypeCreate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*DocumentTypeCreate) SetName ¶
func (dtc *DocumentTypeCreate) SetName(s string) *DocumentTypeCreate
SetName sets the "name" field.
func (*DocumentTypeCreate) SetNillableDescription ¶
func (dtc *DocumentTypeCreate) SetNillableDescription(s *string) *DocumentTypeCreate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*DocumentTypeCreate) SetNillableMetadataID ¶
func (dtc *DocumentTypeCreate) SetNillableMetadataID(id *string) *DocumentTypeCreate
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*DocumentTypeCreate) SetNillableName ¶
func (dtc *DocumentTypeCreate) SetNillableName(s *string) *DocumentTypeCreate
SetNillableName sets the "name" field if the given value is not nil.
func (*DocumentTypeCreate) SetNillableType ¶
func (dtc *DocumentTypeCreate) SetNillableType(d *documenttype.Type) *DocumentTypeCreate
SetNillableType sets the "type" field if the given value is not nil.
func (*DocumentTypeCreate) SetType ¶
func (dtc *DocumentTypeCreate) SetType(d documenttype.Type) *DocumentTypeCreate
SetType sets the "type" field.
type DocumentTypeCreateBulk ¶
type DocumentTypeCreateBulk struct {
// contains filtered or unexported fields
}
DocumentTypeCreateBulk is the builder for creating many DocumentType entities in bulk.
func (*DocumentTypeCreateBulk) Exec ¶
func (dtcb *DocumentTypeCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentTypeCreateBulk) ExecX ¶
func (dtcb *DocumentTypeCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeCreateBulk) OnConflict ¶
func (dtcb *DocumentTypeCreateBulk) OnConflict(opts ...sql.ConflictOption) *DocumentTypeUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.DocumentType.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.DocumentTypeUpsert) { SetType(v+v). }). Exec(ctx)
func (*DocumentTypeCreateBulk) OnConflictColumns ¶
func (dtcb *DocumentTypeCreateBulk) OnConflictColumns(columns ...string) *DocumentTypeUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.DocumentType.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*DocumentTypeCreateBulk) Save ¶
func (dtcb *DocumentTypeCreateBulk) Save(ctx context.Context) ([]*DocumentType, error)
Save creates the DocumentType entities in the database.
func (*DocumentTypeCreateBulk) SaveX ¶
func (dtcb *DocumentTypeCreateBulk) SaveX(ctx context.Context) []*DocumentType
SaveX is like Save, but panics if an error occurs.
type DocumentTypeDelete ¶
type DocumentTypeDelete struct {
// contains filtered or unexported fields
}
DocumentTypeDelete is the builder for deleting a DocumentType entity.
func (*DocumentTypeDelete) Exec ¶
func (dtd *DocumentTypeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*DocumentTypeDelete) ExecX ¶
func (dtd *DocumentTypeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeDelete) Where ¶
func (dtd *DocumentTypeDelete) Where(ps ...predicate.DocumentType) *DocumentTypeDelete
Where appends a list predicates to the DocumentTypeDelete builder.
type DocumentTypeDeleteOne ¶
type DocumentTypeDeleteOne struct {
// contains filtered or unexported fields
}
DocumentTypeDeleteOne is the builder for deleting a single DocumentType entity.
func (*DocumentTypeDeleteOne) Exec ¶
func (dtdo *DocumentTypeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*DocumentTypeDeleteOne) ExecX ¶
func (dtdo *DocumentTypeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeDeleteOne) Where ¶
func (dtdo *DocumentTypeDeleteOne) Where(ps ...predicate.DocumentType) *DocumentTypeDeleteOne
Where appends a list predicates to the DocumentTypeDelete builder.
type DocumentTypeEdges ¶
type DocumentTypeEdges struct { // Metadata holds the value of the metadata edge. Metadata *Metadata `json:"metadata,omitempty"` // contains filtered or unexported fields }
DocumentTypeEdges holds the relations/edges for other nodes in the graph.
func (DocumentTypeEdges) MetadataOrErr ¶
func (e DocumentTypeEdges) MetadataOrErr() (*Metadata, error)
MetadataOrErr returns the Metadata value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type DocumentTypeGroupBy ¶
type DocumentTypeGroupBy struct {
// contains filtered or unexported fields
}
DocumentTypeGroupBy is the group-by builder for DocumentType entities.
func (*DocumentTypeGroupBy) Aggregate ¶
func (dtgb *DocumentTypeGroupBy) Aggregate(fns ...AggregateFunc) *DocumentTypeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*DocumentTypeGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*DocumentTypeGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*DocumentTypeGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*DocumentTypeGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*DocumentTypeGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*DocumentTypeGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*DocumentTypeGroupBy) Scan ¶
func (dtgb *DocumentTypeGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*DocumentTypeGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type DocumentTypeMutation ¶
type DocumentTypeMutation struct {
// contains filtered or unexported fields
}
DocumentTypeMutation represents an operation that mutates the DocumentType nodes in the graph.
func (*DocumentTypeMutation) AddField ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) AddedEdges ¶
func (m *DocumentTypeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*DocumentTypeMutation) AddedField ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) AddedFields ¶
func (m *DocumentTypeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*DocumentTypeMutation) AddedIDs ¶
func (m *DocumentTypeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*DocumentTypeMutation) ClearDescription ¶
func (m *DocumentTypeMutation) ClearDescription()
ClearDescription clears the value of the "description" field.
func (*DocumentTypeMutation) ClearEdge ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) ClearField ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) ClearMetadata ¶
func (m *DocumentTypeMutation) ClearMetadata()
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*DocumentTypeMutation) ClearName ¶
func (m *DocumentTypeMutation) ClearName()
ClearName clears the value of the "name" field.
func (*DocumentTypeMutation) ClearType ¶
func (m *DocumentTypeMutation) ClearType()
ClearType clears the value of the "type" field.
func (*DocumentTypeMutation) ClearedEdges ¶
func (m *DocumentTypeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*DocumentTypeMutation) ClearedFields ¶
func (m *DocumentTypeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (DocumentTypeMutation) Client ¶
func (m DocumentTypeMutation) 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 (*DocumentTypeMutation) Description ¶
func (m *DocumentTypeMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*DocumentTypeMutation) DescriptionCleared ¶
func (m *DocumentTypeMutation) DescriptionCleared() bool
DescriptionCleared returns if the "description" field was cleared in this mutation.
func (*DocumentTypeMutation) EdgeCleared ¶
func (m *DocumentTypeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*DocumentTypeMutation) Field ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) FieldCleared ¶
func (m *DocumentTypeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*DocumentTypeMutation) Fields ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) GetType ¶
func (m *DocumentTypeMutation) GetType() (r documenttype.Type, exists bool)
GetType returns the value of the "type" field in the mutation.
func (*DocumentTypeMutation) ID ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) IDs ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) MetadataCleared ¶
func (m *DocumentTypeMutation) MetadataCleared() bool
MetadataCleared reports if the "metadata" edge to the Metadata entity was cleared.
func (*DocumentTypeMutation) MetadataID ¶
func (m *DocumentTypeMutation) MetadataID() (id string, exists bool)
MetadataID returns the "metadata" edge ID in the mutation.
func (*DocumentTypeMutation) MetadataIDs ¶
func (m *DocumentTypeMutation) MetadataIDs() (ids []string)
MetadataIDs returns the "metadata" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use MetadataID instead. It exists only for internal usage by the builders.
func (*DocumentTypeMutation) Name ¶
func (m *DocumentTypeMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*DocumentTypeMutation) NameCleared ¶
func (m *DocumentTypeMutation) NameCleared() bool
NameCleared returns if the "name" field was cleared in this mutation.
func (*DocumentTypeMutation) OldDescription ¶
func (m *DocumentTypeMutation) OldDescription(ctx context.Context) (v *string, err error)
OldDescription returns the old "description" field's value of the DocumentType entity. If the DocumentType 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 (*DocumentTypeMutation) 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 (*DocumentTypeMutation) OldName ¶
func (m *DocumentTypeMutation) OldName(ctx context.Context) (v *string, err error)
OldName returns the old "name" field's value of the DocumentType entity. If the DocumentType 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 (*DocumentTypeMutation) OldType ¶
func (m *DocumentTypeMutation) OldType(ctx context.Context) (v *documenttype.Type, err error)
OldType returns the old "type" field's value of the DocumentType entity. If the DocumentType 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 (*DocumentTypeMutation) Op ¶
func (m *DocumentTypeMutation) Op() Op
Op returns the operation name.
func (*DocumentTypeMutation) RemovedEdges ¶
func (m *DocumentTypeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*DocumentTypeMutation) RemovedIDs ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) ResetDescription ¶
func (m *DocumentTypeMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*DocumentTypeMutation) ResetEdge ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) ResetField ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) ResetMetadata ¶
func (m *DocumentTypeMutation) ResetMetadata()
ResetMetadata resets all changes to the "metadata" edge.
func (*DocumentTypeMutation) ResetName ¶
func (m *DocumentTypeMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*DocumentTypeMutation) ResetType ¶
func (m *DocumentTypeMutation) ResetType()
ResetType resets all changes to the "type" field.
func (*DocumentTypeMutation) SetDescription ¶
func (m *DocumentTypeMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*DocumentTypeMutation) SetField ¶
func (m *DocumentTypeMutation) 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 (*DocumentTypeMutation) SetMetadataID ¶
func (m *DocumentTypeMutation) SetMetadataID(id string)
SetMetadataID sets the "metadata" edge to the Metadata entity by id.
func (*DocumentTypeMutation) SetName ¶
func (m *DocumentTypeMutation) SetName(s string)
SetName sets the "name" field.
func (*DocumentTypeMutation) SetOp ¶
func (m *DocumentTypeMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*DocumentTypeMutation) SetType ¶
func (m *DocumentTypeMutation) SetType(d documenttype.Type)
SetType sets the "type" field.
func (DocumentTypeMutation) Tx ¶
func (m DocumentTypeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*DocumentTypeMutation) Type ¶
func (m *DocumentTypeMutation) Type() string
Type returns the node type of this mutation (DocumentType).
func (*DocumentTypeMutation) TypeCleared ¶
func (m *DocumentTypeMutation) TypeCleared() bool
TypeCleared returns if the "type" field was cleared in this mutation.
func (*DocumentTypeMutation) Where ¶
func (m *DocumentTypeMutation) Where(ps ...predicate.DocumentType)
Where appends a list predicates to the DocumentTypeMutation builder.
func (*DocumentTypeMutation) WhereP ¶
func (m *DocumentTypeMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the DocumentTypeMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type DocumentTypeQuery ¶
type DocumentTypeQuery struct {
// contains filtered or unexported fields
}
DocumentTypeQuery is the builder for querying DocumentType entities.
func (*DocumentTypeQuery) Aggregate ¶
func (dtq *DocumentTypeQuery) Aggregate(fns ...AggregateFunc) *DocumentTypeSelect
Aggregate returns a DocumentTypeSelect configured with the given aggregations.
func (*DocumentTypeQuery) All ¶
func (dtq *DocumentTypeQuery) All(ctx context.Context) ([]*DocumentType, error)
All executes the query and returns a list of DocumentTypes.
func (*DocumentTypeQuery) AllX ¶
func (dtq *DocumentTypeQuery) AllX(ctx context.Context) []*DocumentType
AllX is like All, but panics if an error occurs.
func (*DocumentTypeQuery) Clone ¶
func (dtq *DocumentTypeQuery) Clone() *DocumentTypeQuery
Clone returns a duplicate of the DocumentTypeQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*DocumentTypeQuery) Count ¶
func (dtq *DocumentTypeQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*DocumentTypeQuery) CountX ¶
func (dtq *DocumentTypeQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*DocumentTypeQuery) Exist ¶
func (dtq *DocumentTypeQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*DocumentTypeQuery) ExistX ¶
func (dtq *DocumentTypeQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*DocumentTypeQuery) First ¶
func (dtq *DocumentTypeQuery) First(ctx context.Context) (*DocumentType, error)
First returns the first DocumentType entity from the query. Returns a *NotFoundError when no DocumentType was found.
func (*DocumentTypeQuery) FirstID ¶
func (dtq *DocumentTypeQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first DocumentType ID from the query. Returns a *NotFoundError when no DocumentType ID was found.
func (*DocumentTypeQuery) FirstIDX ¶
func (dtq *DocumentTypeQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*DocumentTypeQuery) FirstX ¶
func (dtq *DocumentTypeQuery) FirstX(ctx context.Context) *DocumentType
FirstX is like First, but panics if an error occurs.
func (*DocumentTypeQuery) GroupBy ¶
func (dtq *DocumentTypeQuery) GroupBy(field string, fields ...string) *DocumentTypeGroupBy
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 { Type documenttype.Type `json:"type,omitempty"` Count int `json:"count,omitempty"` } client.DocumentType.Query(). GroupBy(documenttype.FieldType). Aggregate(ent.Count()). Scan(ctx, &v)
func (*DocumentTypeQuery) IDs ¶
func (dtq *DocumentTypeQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of DocumentType IDs.
func (*DocumentTypeQuery) IDsX ¶
func (dtq *DocumentTypeQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*DocumentTypeQuery) Limit ¶
func (dtq *DocumentTypeQuery) Limit(limit int) *DocumentTypeQuery
Limit the number of records to be returned by this query.
func (*DocumentTypeQuery) Offset ¶
func (dtq *DocumentTypeQuery) Offset(offset int) *DocumentTypeQuery
Offset to start from.
func (*DocumentTypeQuery) Only ¶
func (dtq *DocumentTypeQuery) Only(ctx context.Context) (*DocumentType, error)
Only returns a single DocumentType entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one DocumentType entity is found. Returns a *NotFoundError when no DocumentType entities are found.
func (*DocumentTypeQuery) OnlyID ¶
func (dtq *DocumentTypeQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only DocumentType ID in the query. Returns a *NotSingularError when more than one DocumentType ID is found. Returns a *NotFoundError when no entities are found.
func (*DocumentTypeQuery) OnlyIDX ¶
func (dtq *DocumentTypeQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*DocumentTypeQuery) OnlyX ¶
func (dtq *DocumentTypeQuery) OnlyX(ctx context.Context) *DocumentType
OnlyX is like Only, but panics if an error occurs.
func (*DocumentTypeQuery) Order ¶
func (dtq *DocumentTypeQuery) Order(o ...documenttype.OrderOption) *DocumentTypeQuery
Order specifies how the records should be ordered.
func (*DocumentTypeQuery) QueryMetadata ¶
func (dtq *DocumentTypeQuery) QueryMetadata() *MetadataQuery
QueryMetadata chains the current query on the "metadata" edge.
func (*DocumentTypeQuery) Select ¶
func (dtq *DocumentTypeQuery) Select(fields ...string) *DocumentTypeSelect
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 { Type documenttype.Type `json:"type,omitempty"` } client.DocumentType.Query(). Select(documenttype.FieldType). Scan(ctx, &v)
func (*DocumentTypeQuery) Unique ¶
func (dtq *DocumentTypeQuery) Unique(unique bool) *DocumentTypeQuery
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 (*DocumentTypeQuery) Where ¶
func (dtq *DocumentTypeQuery) Where(ps ...predicate.DocumentType) *DocumentTypeQuery
Where adds a new predicate for the DocumentTypeQuery builder.
func (*DocumentTypeQuery) WithMetadata ¶
func (dtq *DocumentTypeQuery) WithMetadata(opts ...func(*MetadataQuery)) *DocumentTypeQuery
WithMetadata tells the query-builder to eager-load the nodes that are connected to the "metadata" edge. The optional arguments are used to configure the query builder of the edge.
type DocumentTypeSelect ¶
type DocumentTypeSelect struct { *DocumentTypeQuery // contains filtered or unexported fields }
DocumentTypeSelect is the builder for selecting fields of DocumentType entities.
func (*DocumentTypeSelect) Aggregate ¶
func (dts *DocumentTypeSelect) Aggregate(fns ...AggregateFunc) *DocumentTypeSelect
Aggregate adds the given aggregation functions to the selector query.
func (*DocumentTypeSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*DocumentTypeSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*DocumentTypeSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*DocumentTypeSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*DocumentTypeSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*DocumentTypeSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*DocumentTypeSelect) Scan ¶
func (dts *DocumentTypeSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*DocumentTypeSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type DocumentTypeUpdate ¶
type DocumentTypeUpdate struct {
// contains filtered or unexported fields
}
DocumentTypeUpdate is the builder for updating DocumentType entities.
func (*DocumentTypeUpdate) ClearDescription ¶
func (dtu *DocumentTypeUpdate) ClearDescription() *DocumentTypeUpdate
ClearDescription clears the value of the "description" field.
func (*DocumentTypeUpdate) ClearMetadata ¶
func (dtu *DocumentTypeUpdate) ClearMetadata() *DocumentTypeUpdate
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*DocumentTypeUpdate) ClearName ¶
func (dtu *DocumentTypeUpdate) ClearName() *DocumentTypeUpdate
ClearName clears the value of the "name" field.
func (*DocumentTypeUpdate) ClearType ¶
func (dtu *DocumentTypeUpdate) ClearType() *DocumentTypeUpdate
ClearType clears the value of the "type" field.
func (*DocumentTypeUpdate) Exec ¶
func (dtu *DocumentTypeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentTypeUpdate) ExecX ¶
func (dtu *DocumentTypeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeUpdate) Mutation ¶
func (dtu *DocumentTypeUpdate) Mutation() *DocumentTypeMutation
Mutation returns the DocumentTypeMutation object of the builder.
func (*DocumentTypeUpdate) Save ¶
func (dtu *DocumentTypeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*DocumentTypeUpdate) SaveX ¶
func (dtu *DocumentTypeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*DocumentTypeUpdate) SetDescription ¶
func (dtu *DocumentTypeUpdate) SetDescription(s string) *DocumentTypeUpdate
SetDescription sets the "description" field.
func (*DocumentTypeUpdate) SetMetadata ¶
func (dtu *DocumentTypeUpdate) SetMetadata(m *Metadata) *DocumentTypeUpdate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*DocumentTypeUpdate) SetMetadataID ¶
func (dtu *DocumentTypeUpdate) SetMetadataID(id string) *DocumentTypeUpdate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*DocumentTypeUpdate) SetName ¶
func (dtu *DocumentTypeUpdate) SetName(s string) *DocumentTypeUpdate
SetName sets the "name" field.
func (*DocumentTypeUpdate) SetNillableDescription ¶
func (dtu *DocumentTypeUpdate) SetNillableDescription(s *string) *DocumentTypeUpdate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*DocumentTypeUpdate) SetNillableMetadataID ¶
func (dtu *DocumentTypeUpdate) SetNillableMetadataID(id *string) *DocumentTypeUpdate
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*DocumentTypeUpdate) SetNillableName ¶
func (dtu *DocumentTypeUpdate) SetNillableName(s *string) *DocumentTypeUpdate
SetNillableName sets the "name" field if the given value is not nil.
func (*DocumentTypeUpdate) SetNillableType ¶
func (dtu *DocumentTypeUpdate) SetNillableType(d *documenttype.Type) *DocumentTypeUpdate
SetNillableType sets the "type" field if the given value is not nil.
func (*DocumentTypeUpdate) SetType ¶
func (dtu *DocumentTypeUpdate) SetType(d documenttype.Type) *DocumentTypeUpdate
SetType sets the "type" field.
func (*DocumentTypeUpdate) Where ¶
func (dtu *DocumentTypeUpdate) Where(ps ...predicate.DocumentType) *DocumentTypeUpdate
Where appends a list predicates to the DocumentTypeUpdate builder.
type DocumentTypeUpdateOne ¶
type DocumentTypeUpdateOne struct {
// contains filtered or unexported fields
}
DocumentTypeUpdateOne is the builder for updating a single DocumentType entity.
func (*DocumentTypeUpdateOne) ClearDescription ¶
func (dtuo *DocumentTypeUpdateOne) ClearDescription() *DocumentTypeUpdateOne
ClearDescription clears the value of the "description" field.
func (*DocumentTypeUpdateOne) ClearMetadata ¶
func (dtuo *DocumentTypeUpdateOne) ClearMetadata() *DocumentTypeUpdateOne
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*DocumentTypeUpdateOne) ClearName ¶
func (dtuo *DocumentTypeUpdateOne) ClearName() *DocumentTypeUpdateOne
ClearName clears the value of the "name" field.
func (*DocumentTypeUpdateOne) ClearType ¶
func (dtuo *DocumentTypeUpdateOne) ClearType() *DocumentTypeUpdateOne
ClearType clears the value of the "type" field.
func (*DocumentTypeUpdateOne) Exec ¶
func (dtuo *DocumentTypeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*DocumentTypeUpdateOne) ExecX ¶
func (dtuo *DocumentTypeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeUpdateOne) Mutation ¶
func (dtuo *DocumentTypeUpdateOne) Mutation() *DocumentTypeMutation
Mutation returns the DocumentTypeMutation object of the builder.
func (*DocumentTypeUpdateOne) Save ¶
func (dtuo *DocumentTypeUpdateOne) Save(ctx context.Context) (*DocumentType, error)
Save executes the query and returns the updated DocumentType entity.
func (*DocumentTypeUpdateOne) SaveX ¶
func (dtuo *DocumentTypeUpdateOne) SaveX(ctx context.Context) *DocumentType
SaveX is like Save, but panics if an error occurs.
func (*DocumentTypeUpdateOne) Select ¶
func (dtuo *DocumentTypeUpdateOne) Select(field string, fields ...string) *DocumentTypeUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*DocumentTypeUpdateOne) SetDescription ¶
func (dtuo *DocumentTypeUpdateOne) SetDescription(s string) *DocumentTypeUpdateOne
SetDescription sets the "description" field.
func (*DocumentTypeUpdateOne) SetMetadata ¶
func (dtuo *DocumentTypeUpdateOne) SetMetadata(m *Metadata) *DocumentTypeUpdateOne
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*DocumentTypeUpdateOne) SetMetadataID ¶
func (dtuo *DocumentTypeUpdateOne) SetMetadataID(id string) *DocumentTypeUpdateOne
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*DocumentTypeUpdateOne) SetName ¶
func (dtuo *DocumentTypeUpdateOne) SetName(s string) *DocumentTypeUpdateOne
SetName sets the "name" field.
func (*DocumentTypeUpdateOne) SetNillableDescription ¶
func (dtuo *DocumentTypeUpdateOne) SetNillableDescription(s *string) *DocumentTypeUpdateOne
SetNillableDescription sets the "description" field if the given value is not nil.
func (*DocumentTypeUpdateOne) SetNillableMetadataID ¶
func (dtuo *DocumentTypeUpdateOne) SetNillableMetadataID(id *string) *DocumentTypeUpdateOne
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*DocumentTypeUpdateOne) SetNillableName ¶
func (dtuo *DocumentTypeUpdateOne) SetNillableName(s *string) *DocumentTypeUpdateOne
SetNillableName sets the "name" field if the given value is not nil.
func (*DocumentTypeUpdateOne) SetNillableType ¶
func (dtuo *DocumentTypeUpdateOne) SetNillableType(d *documenttype.Type) *DocumentTypeUpdateOne
SetNillableType sets the "type" field if the given value is not nil.
func (*DocumentTypeUpdateOne) SetType ¶
func (dtuo *DocumentTypeUpdateOne) SetType(d documenttype.Type) *DocumentTypeUpdateOne
SetType sets the "type" field.
func (*DocumentTypeUpdateOne) Where ¶
func (dtuo *DocumentTypeUpdateOne) Where(ps ...predicate.DocumentType) *DocumentTypeUpdateOne
Where appends a list predicates to the DocumentTypeUpdate builder.
type DocumentTypeUpsert ¶
DocumentTypeUpsert is the "OnConflict" setter.
func (*DocumentTypeUpsert) ClearDescription ¶
func (u *DocumentTypeUpsert) ClearDescription() *DocumentTypeUpsert
ClearDescription clears the value of the "description" field.
func (*DocumentTypeUpsert) ClearName ¶
func (u *DocumentTypeUpsert) ClearName() *DocumentTypeUpsert
ClearName clears the value of the "name" field.
func (*DocumentTypeUpsert) ClearType ¶
func (u *DocumentTypeUpsert) ClearType() *DocumentTypeUpsert
ClearType clears the value of the "type" field.
func (*DocumentTypeUpsert) SetDescription ¶
func (u *DocumentTypeUpsert) SetDescription(v string) *DocumentTypeUpsert
SetDescription sets the "description" field.
func (*DocumentTypeUpsert) SetName ¶
func (u *DocumentTypeUpsert) SetName(v string) *DocumentTypeUpsert
SetName sets the "name" field.
func (*DocumentTypeUpsert) SetType ¶
func (u *DocumentTypeUpsert) SetType(v documenttype.Type) *DocumentTypeUpsert
SetType sets the "type" field.
func (*DocumentTypeUpsert) UpdateDescription ¶
func (u *DocumentTypeUpsert) UpdateDescription() *DocumentTypeUpsert
UpdateDescription sets the "description" field to the value that was provided on create.
func (*DocumentTypeUpsert) UpdateName ¶
func (u *DocumentTypeUpsert) UpdateName() *DocumentTypeUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*DocumentTypeUpsert) UpdateType ¶
func (u *DocumentTypeUpsert) UpdateType() *DocumentTypeUpsert
UpdateType sets the "type" field to the value that was provided on create.
type DocumentTypeUpsertBulk ¶
type DocumentTypeUpsertBulk struct {
// contains filtered or unexported fields
}
DocumentTypeUpsertBulk is the builder for "upsert"-ing a bulk of DocumentType nodes.
func (*DocumentTypeUpsertBulk) ClearDescription ¶
func (u *DocumentTypeUpsertBulk) ClearDescription() *DocumentTypeUpsertBulk
ClearDescription clears the value of the "description" field.
func (*DocumentTypeUpsertBulk) ClearName ¶
func (u *DocumentTypeUpsertBulk) ClearName() *DocumentTypeUpsertBulk
ClearName clears the value of the "name" field.
func (*DocumentTypeUpsertBulk) ClearType ¶
func (u *DocumentTypeUpsertBulk) ClearType() *DocumentTypeUpsertBulk
ClearType clears the value of the "type" field.
func (*DocumentTypeUpsertBulk) DoNothing ¶
func (u *DocumentTypeUpsertBulk) DoNothing() *DocumentTypeUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*DocumentTypeUpsertBulk) Exec ¶
func (u *DocumentTypeUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentTypeUpsertBulk) ExecX ¶
func (u *DocumentTypeUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeUpsertBulk) Ignore ¶
func (u *DocumentTypeUpsertBulk) Ignore() *DocumentTypeUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.DocumentType.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*DocumentTypeUpsertBulk) SetDescription ¶
func (u *DocumentTypeUpsertBulk) SetDescription(v string) *DocumentTypeUpsertBulk
SetDescription sets the "description" field.
func (*DocumentTypeUpsertBulk) SetName ¶
func (u *DocumentTypeUpsertBulk) SetName(v string) *DocumentTypeUpsertBulk
SetName sets the "name" field.
func (*DocumentTypeUpsertBulk) SetType ¶
func (u *DocumentTypeUpsertBulk) SetType(v documenttype.Type) *DocumentTypeUpsertBulk
SetType sets the "type" field.
func (*DocumentTypeUpsertBulk) Update ¶
func (u *DocumentTypeUpsertBulk) Update(set func(*DocumentTypeUpsert)) *DocumentTypeUpsertBulk
Update allows overriding fields `UPDATE` values. See the DocumentTypeCreateBulk.OnConflict documentation for more info.
func (*DocumentTypeUpsertBulk) UpdateDescription ¶
func (u *DocumentTypeUpsertBulk) UpdateDescription() *DocumentTypeUpsertBulk
UpdateDescription sets the "description" field to the value that was provided on create.
func (*DocumentTypeUpsertBulk) UpdateName ¶
func (u *DocumentTypeUpsertBulk) UpdateName() *DocumentTypeUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*DocumentTypeUpsertBulk) UpdateNewValues ¶
func (u *DocumentTypeUpsertBulk) UpdateNewValues() *DocumentTypeUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.DocumentType.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*DocumentTypeUpsertBulk) UpdateType ¶
func (u *DocumentTypeUpsertBulk) UpdateType() *DocumentTypeUpsertBulk
UpdateType sets the "type" field to the value that was provided on create.
type DocumentTypeUpsertOne ¶
type DocumentTypeUpsertOne struct {
// contains filtered or unexported fields
}
DocumentTypeUpsertOne is the builder for "upsert"-ing
one DocumentType node.
func (*DocumentTypeUpsertOne) ClearDescription ¶
func (u *DocumentTypeUpsertOne) ClearDescription() *DocumentTypeUpsertOne
ClearDescription clears the value of the "description" field.
func (*DocumentTypeUpsertOne) ClearName ¶
func (u *DocumentTypeUpsertOne) ClearName() *DocumentTypeUpsertOne
ClearName clears the value of the "name" field.
func (*DocumentTypeUpsertOne) ClearType ¶
func (u *DocumentTypeUpsertOne) ClearType() *DocumentTypeUpsertOne
ClearType clears the value of the "type" field.
func (*DocumentTypeUpsertOne) DoNothing ¶
func (u *DocumentTypeUpsertOne) DoNothing() *DocumentTypeUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*DocumentTypeUpsertOne) Exec ¶
func (u *DocumentTypeUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentTypeUpsertOne) ExecX ¶
func (u *DocumentTypeUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentTypeUpsertOne) ID ¶
func (u *DocumentTypeUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*DocumentTypeUpsertOne) IDX ¶
func (u *DocumentTypeUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*DocumentTypeUpsertOne) Ignore ¶
func (u *DocumentTypeUpsertOne) Ignore() *DocumentTypeUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.DocumentType.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*DocumentTypeUpsertOne) SetDescription ¶
func (u *DocumentTypeUpsertOne) SetDescription(v string) *DocumentTypeUpsertOne
SetDescription sets the "description" field.
func (*DocumentTypeUpsertOne) SetName ¶
func (u *DocumentTypeUpsertOne) SetName(v string) *DocumentTypeUpsertOne
SetName sets the "name" field.
func (*DocumentTypeUpsertOne) SetType ¶
func (u *DocumentTypeUpsertOne) SetType(v documenttype.Type) *DocumentTypeUpsertOne
SetType sets the "type" field.
func (*DocumentTypeUpsertOne) Update ¶
func (u *DocumentTypeUpsertOne) Update(set func(*DocumentTypeUpsert)) *DocumentTypeUpsertOne
Update allows overriding fields `UPDATE` values. See the DocumentTypeCreate.OnConflict documentation for more info.
func (*DocumentTypeUpsertOne) UpdateDescription ¶
func (u *DocumentTypeUpsertOne) UpdateDescription() *DocumentTypeUpsertOne
UpdateDescription sets the "description" field to the value that was provided on create.
func (*DocumentTypeUpsertOne) UpdateName ¶
func (u *DocumentTypeUpsertOne) UpdateName() *DocumentTypeUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*DocumentTypeUpsertOne) UpdateNewValues ¶
func (u *DocumentTypeUpsertOne) UpdateNewValues() *DocumentTypeUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.DocumentType.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*DocumentTypeUpsertOne) UpdateType ¶
func (u *DocumentTypeUpsertOne) UpdateType() *DocumentTypeUpsertOne
UpdateType sets the "type" field to the value that was provided on create.
type DocumentTypes ¶
type DocumentTypes []*DocumentType
DocumentTypes is a parsable slice of DocumentType.
type DocumentUpdate ¶
type DocumentUpdate struct {
// contains filtered or unexported fields
}
DocumentUpdate is the builder for updating Document entities.
func (*DocumentUpdate) ClearMetadata ¶
func (du *DocumentUpdate) ClearMetadata() *DocumentUpdate
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*DocumentUpdate) ClearNodeList ¶
func (du *DocumentUpdate) ClearNodeList() *DocumentUpdate
ClearNodeList clears the "node_list" edge to the NodeList entity.
func (*DocumentUpdate) Exec ¶
func (du *DocumentUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentUpdate) ExecX ¶
func (du *DocumentUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentUpdate) Mutation ¶
func (du *DocumentUpdate) Mutation() *DocumentMutation
Mutation returns the DocumentMutation object of the builder.
func (*DocumentUpdate) Save ¶
func (du *DocumentUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*DocumentUpdate) SaveX ¶
func (du *DocumentUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*DocumentUpdate) SetMetadata ¶
func (du *DocumentUpdate) SetMetadata(m *Metadata) *DocumentUpdate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*DocumentUpdate) SetMetadataID ¶
func (du *DocumentUpdate) SetMetadataID(id string) *DocumentUpdate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*DocumentUpdate) SetNodeList ¶
func (du *DocumentUpdate) SetNodeList(n *NodeList) *DocumentUpdate
SetNodeList sets the "node_list" edge to the NodeList entity.
func (*DocumentUpdate) SetNodeListID ¶
func (du *DocumentUpdate) SetNodeListID(id int) *DocumentUpdate
SetNodeListID sets the "node_list" edge to the NodeList entity by ID.
func (*DocumentUpdate) Where ¶
func (du *DocumentUpdate) Where(ps ...predicate.Document) *DocumentUpdate
Where appends a list predicates to the DocumentUpdate builder.
type DocumentUpdateOne ¶
type DocumentUpdateOne struct {
// contains filtered or unexported fields
}
DocumentUpdateOne is the builder for updating a single Document entity.
func (*DocumentUpdateOne) ClearMetadata ¶
func (duo *DocumentUpdateOne) ClearMetadata() *DocumentUpdateOne
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*DocumentUpdateOne) ClearNodeList ¶
func (duo *DocumentUpdateOne) ClearNodeList() *DocumentUpdateOne
ClearNodeList clears the "node_list" edge to the NodeList entity.
func (*DocumentUpdateOne) Exec ¶
func (duo *DocumentUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*DocumentUpdateOne) ExecX ¶
func (duo *DocumentUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentUpdateOne) Mutation ¶
func (duo *DocumentUpdateOne) Mutation() *DocumentMutation
Mutation returns the DocumentMutation object of the builder.
func (*DocumentUpdateOne) Save ¶
func (duo *DocumentUpdateOne) Save(ctx context.Context) (*Document, error)
Save executes the query and returns the updated Document entity.
func (*DocumentUpdateOne) SaveX ¶
func (duo *DocumentUpdateOne) SaveX(ctx context.Context) *Document
SaveX is like Save, but panics if an error occurs.
func (*DocumentUpdateOne) Select ¶
func (duo *DocumentUpdateOne) Select(field string, fields ...string) *DocumentUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*DocumentUpdateOne) SetMetadata ¶
func (duo *DocumentUpdateOne) SetMetadata(m *Metadata) *DocumentUpdateOne
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*DocumentUpdateOne) SetMetadataID ¶
func (duo *DocumentUpdateOne) SetMetadataID(id string) *DocumentUpdateOne
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*DocumentUpdateOne) SetNodeList ¶
func (duo *DocumentUpdateOne) SetNodeList(n *NodeList) *DocumentUpdateOne
SetNodeList sets the "node_list" edge to the NodeList entity.
func (*DocumentUpdateOne) SetNodeListID ¶
func (duo *DocumentUpdateOne) SetNodeListID(id int) *DocumentUpdateOne
SetNodeListID sets the "node_list" edge to the NodeList entity by ID.
func (*DocumentUpdateOne) Where ¶
func (duo *DocumentUpdateOne) Where(ps ...predicate.Document) *DocumentUpdateOne
Where appends a list predicates to the DocumentUpdate builder.
type DocumentUpsert ¶
DocumentUpsert is the "OnConflict" setter.
type DocumentUpsertBulk ¶
type DocumentUpsertBulk struct {
// contains filtered or unexported fields
}
DocumentUpsertBulk is the builder for "upsert"-ing a bulk of Document nodes.
func (*DocumentUpsertBulk) DoNothing ¶
func (u *DocumentUpsertBulk) DoNothing() *DocumentUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*DocumentUpsertBulk) Exec ¶
func (u *DocumentUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentUpsertBulk) ExecX ¶
func (u *DocumentUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentUpsertBulk) Ignore ¶
func (u *DocumentUpsertBulk) Ignore() *DocumentUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Document.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*DocumentUpsertBulk) Update ¶
func (u *DocumentUpsertBulk) Update(set func(*DocumentUpsert)) *DocumentUpsertBulk
Update allows overriding fields `UPDATE` values. See the DocumentCreateBulk.OnConflict documentation for more info.
func (*DocumentUpsertBulk) UpdateNewValues ¶
func (u *DocumentUpsertBulk) UpdateNewValues() *DocumentUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Document.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
type DocumentUpsertOne ¶
type DocumentUpsertOne struct {
// contains filtered or unexported fields
}
DocumentUpsertOne is the builder for "upsert"-ing
one Document node.
func (*DocumentUpsertOne) DoNothing ¶
func (u *DocumentUpsertOne) DoNothing() *DocumentUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*DocumentUpsertOne) Exec ¶
func (u *DocumentUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*DocumentUpsertOne) ExecX ¶
func (u *DocumentUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*DocumentUpsertOne) ID ¶
func (u *DocumentUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*DocumentUpsertOne) IDX ¶
func (u *DocumentUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*DocumentUpsertOne) Ignore ¶
func (u *DocumentUpsertOne) Ignore() *DocumentUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Document.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*DocumentUpsertOne) Update ¶
func (u *DocumentUpsertOne) Update(set func(*DocumentUpsert)) *DocumentUpsertOne
Update allows overriding fields `UPDATE` values. See the DocumentCreate.OnConflict documentation for more info.
func (*DocumentUpsertOne) UpdateNewValues ¶
func (u *DocumentUpsertOne) UpdateNewValues() *DocumentUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Document.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
type EdgeType ¶
type EdgeType struct { // ID of the ent. ID int `json:"id,omitempty"` // Type holds the value of the "type" field. Type edgetype.Type `json:"type,omitempty"` // NodeID holds the value of the "node_id" field. NodeID string `json:"node_id,omitempty"` // ToID holds the value of the "to_id" field. ToID string `json:"to_id,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the EdgeTypeQuery when eager-loading is set. Edges EdgeTypeEdges `json:"edges"` // contains filtered or unexported fields }
EdgeType is the model entity for the EdgeType schema.
func (*EdgeType) Unwrap ¶
Unwrap unwraps the EdgeType 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 (*EdgeType) Update ¶
func (et *EdgeType) Update() *EdgeTypeUpdateOne
Update returns a builder for updating this EdgeType. Note that you need to call EdgeType.Unwrap() before calling this method if this EdgeType was returned from a transaction, and the transaction was committed or rolled back.
type EdgeTypeClient ¶
type EdgeTypeClient struct {
// contains filtered or unexported fields
}
EdgeTypeClient is a client for the EdgeType schema.
func NewEdgeTypeClient ¶
func NewEdgeTypeClient(c config) *EdgeTypeClient
NewEdgeTypeClient returns a client for the EdgeType from the given config.
func (*EdgeTypeClient) Create ¶
func (c *EdgeTypeClient) Create() *EdgeTypeCreate
Create returns a builder for creating a EdgeType entity.
func (*EdgeTypeClient) CreateBulk ¶
func (c *EdgeTypeClient) CreateBulk(builders ...*EdgeTypeCreate) *EdgeTypeCreateBulk
CreateBulk returns a builder for creating a bulk of EdgeType entities.
func (*EdgeTypeClient) Delete ¶
func (c *EdgeTypeClient) Delete() *EdgeTypeDelete
Delete returns a delete builder for EdgeType.
func (*EdgeTypeClient) DeleteOne ¶
func (c *EdgeTypeClient) DeleteOne(et *EdgeType) *EdgeTypeDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*EdgeTypeClient) DeleteOneID ¶
func (c *EdgeTypeClient) DeleteOneID(id int) *EdgeTypeDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*EdgeTypeClient) GetX ¶
func (c *EdgeTypeClient) GetX(ctx context.Context, id int) *EdgeType
GetX is like Get, but panics if an error occurs.
func (*EdgeTypeClient) Hooks ¶
func (c *EdgeTypeClient) Hooks() []Hook
Hooks returns the client hooks.
func (*EdgeTypeClient) Intercept ¶
func (c *EdgeTypeClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `edgetype.Intercept(f(g(h())))`.
func (*EdgeTypeClient) Interceptors ¶
func (c *EdgeTypeClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*EdgeTypeClient) MapCreateBulk ¶
func (c *EdgeTypeClient) MapCreateBulk(slice any, setFunc func(*EdgeTypeCreate, int)) *EdgeTypeCreateBulk
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 (*EdgeTypeClient) Query ¶
func (c *EdgeTypeClient) Query() *EdgeTypeQuery
Query returns a query builder for EdgeType.
func (*EdgeTypeClient) QueryFrom ¶
func (c *EdgeTypeClient) QueryFrom(et *EdgeType) *NodeQuery
QueryFrom queries the from edge of a EdgeType.
func (*EdgeTypeClient) QueryTo ¶
func (c *EdgeTypeClient) QueryTo(et *EdgeType) *NodeQuery
QueryTo queries the to edge of a EdgeType.
func (*EdgeTypeClient) Update ¶
func (c *EdgeTypeClient) Update() *EdgeTypeUpdate
Update returns an update builder for EdgeType.
func (*EdgeTypeClient) UpdateOne ¶
func (c *EdgeTypeClient) UpdateOne(et *EdgeType) *EdgeTypeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*EdgeTypeClient) UpdateOneID ¶
func (c *EdgeTypeClient) UpdateOneID(id int) *EdgeTypeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*EdgeTypeClient) Use ¶
func (c *EdgeTypeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `edgetype.Hooks(f(g(h())))`.
type EdgeTypeCreate ¶
type EdgeTypeCreate struct {
// contains filtered or unexported fields
}
EdgeTypeCreate is the builder for creating a EdgeType entity.
func (*EdgeTypeCreate) Exec ¶
func (etc *EdgeTypeCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*EdgeTypeCreate) ExecX ¶
func (etc *EdgeTypeCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeCreate) Mutation ¶
func (etc *EdgeTypeCreate) Mutation() *EdgeTypeMutation
Mutation returns the EdgeTypeMutation object of the builder.
func (*EdgeTypeCreate) OnConflict ¶
func (etc *EdgeTypeCreate) OnConflict(opts ...sql.ConflictOption) *EdgeTypeUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.EdgeType.Create(). SetType(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.EdgeTypeUpsert) { SetType(v+v). }). Exec(ctx)
func (*EdgeTypeCreate) OnConflictColumns ¶
func (etc *EdgeTypeCreate) OnConflictColumns(columns ...string) *EdgeTypeUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.EdgeType.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*EdgeTypeCreate) Save ¶
func (etc *EdgeTypeCreate) Save(ctx context.Context) (*EdgeType, error)
Save creates the EdgeType in the database.
func (*EdgeTypeCreate) SaveX ¶
func (etc *EdgeTypeCreate) SaveX(ctx context.Context) *EdgeType
SaveX calls Save and panics if Save returns an error.
func (*EdgeTypeCreate) SetFrom ¶
func (etc *EdgeTypeCreate) SetFrom(n *Node) *EdgeTypeCreate
SetFrom sets the "from" edge to the Node entity.
func (*EdgeTypeCreate) SetFromID ¶
func (etc *EdgeTypeCreate) SetFromID(id string) *EdgeTypeCreate
SetFromID sets the "from" edge to the Node entity by ID.
func (*EdgeTypeCreate) SetNodeID ¶
func (etc *EdgeTypeCreate) SetNodeID(s string) *EdgeTypeCreate
SetNodeID sets the "node_id" field.
func (*EdgeTypeCreate) SetTo ¶
func (etc *EdgeTypeCreate) SetTo(n *Node) *EdgeTypeCreate
SetTo sets the "to" edge to the Node entity.
func (*EdgeTypeCreate) SetToID ¶
func (etc *EdgeTypeCreate) SetToID(s string) *EdgeTypeCreate
SetToID sets the "to_id" field.
func (*EdgeTypeCreate) SetType ¶
func (etc *EdgeTypeCreate) SetType(e edgetype.Type) *EdgeTypeCreate
SetType sets the "type" field.
type EdgeTypeCreateBulk ¶
type EdgeTypeCreateBulk struct {
// contains filtered or unexported fields
}
EdgeTypeCreateBulk is the builder for creating many EdgeType entities in bulk.
func (*EdgeTypeCreateBulk) Exec ¶
func (etcb *EdgeTypeCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*EdgeTypeCreateBulk) ExecX ¶
func (etcb *EdgeTypeCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeCreateBulk) OnConflict ¶
func (etcb *EdgeTypeCreateBulk) OnConflict(opts ...sql.ConflictOption) *EdgeTypeUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.EdgeType.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.EdgeTypeUpsert) { SetType(v+v). }). Exec(ctx)
func (*EdgeTypeCreateBulk) OnConflictColumns ¶
func (etcb *EdgeTypeCreateBulk) OnConflictColumns(columns ...string) *EdgeTypeUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.EdgeType.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type EdgeTypeDelete ¶
type EdgeTypeDelete struct {
// contains filtered or unexported fields
}
EdgeTypeDelete is the builder for deleting a EdgeType entity.
func (*EdgeTypeDelete) Exec ¶
func (etd *EdgeTypeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*EdgeTypeDelete) ExecX ¶
func (etd *EdgeTypeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeDelete) Where ¶
func (etd *EdgeTypeDelete) Where(ps ...predicate.EdgeType) *EdgeTypeDelete
Where appends a list predicates to the EdgeTypeDelete builder.
type EdgeTypeDeleteOne ¶
type EdgeTypeDeleteOne struct {
// contains filtered or unexported fields
}
EdgeTypeDeleteOne is the builder for deleting a single EdgeType entity.
func (*EdgeTypeDeleteOne) Exec ¶
func (etdo *EdgeTypeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*EdgeTypeDeleteOne) ExecX ¶
func (etdo *EdgeTypeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeDeleteOne) Where ¶
func (etdo *EdgeTypeDeleteOne) Where(ps ...predicate.EdgeType) *EdgeTypeDeleteOne
Where appends a list predicates to the EdgeTypeDelete builder.
type EdgeTypeEdges ¶
type EdgeTypeEdges struct { // From holds the value of the from edge. From *Node `json:"from,omitempty"` // To holds the value of the to edge. To *Node `json:"to,omitempty"` // contains filtered or unexported fields }
EdgeTypeEdges holds the relations/edges for other nodes in the graph.
func (EdgeTypeEdges) FromOrErr ¶
func (e EdgeTypeEdges) FromOrErr() (*Node, error)
FromOrErr returns the From value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (EdgeTypeEdges) ToOrErr ¶
func (e EdgeTypeEdges) ToOrErr() (*Node, error)
ToOrErr returns the To value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type EdgeTypeGroupBy ¶
type EdgeTypeGroupBy struct {
// contains filtered or unexported fields
}
EdgeTypeGroupBy is the group-by builder for EdgeType entities.
func (*EdgeTypeGroupBy) Aggregate ¶
func (etgb *EdgeTypeGroupBy) Aggregate(fns ...AggregateFunc) *EdgeTypeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*EdgeTypeGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*EdgeTypeGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*EdgeTypeGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*EdgeTypeGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*EdgeTypeGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*EdgeTypeGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*EdgeTypeGroupBy) Scan ¶
func (etgb *EdgeTypeGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*EdgeTypeGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type EdgeTypeMutation ¶
type EdgeTypeMutation struct {
// contains filtered or unexported fields
}
EdgeTypeMutation represents an operation that mutates the EdgeType nodes in the graph.
func (*EdgeTypeMutation) AddField ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) AddedEdges ¶
func (m *EdgeTypeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*EdgeTypeMutation) AddedField ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) AddedFields ¶
func (m *EdgeTypeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*EdgeTypeMutation) AddedIDs ¶
func (m *EdgeTypeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*EdgeTypeMutation) ClearEdge ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) ClearField ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) ClearFrom ¶
func (m *EdgeTypeMutation) ClearFrom()
ClearFrom clears the "from" edge to the Node entity.
func (*EdgeTypeMutation) ClearTo ¶
func (m *EdgeTypeMutation) ClearTo()
ClearTo clears the "to" edge to the Node entity.
func (*EdgeTypeMutation) ClearedEdges ¶
func (m *EdgeTypeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*EdgeTypeMutation) ClearedFields ¶
func (m *EdgeTypeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (EdgeTypeMutation) Client ¶
func (m EdgeTypeMutation) 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 (*EdgeTypeMutation) EdgeCleared ¶
func (m *EdgeTypeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*EdgeTypeMutation) Field ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) FieldCleared ¶
func (m *EdgeTypeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*EdgeTypeMutation) Fields ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) FromCleared ¶
func (m *EdgeTypeMutation) FromCleared() bool
FromCleared reports if the "from" edge to the Node entity was cleared.
func (*EdgeTypeMutation) FromID ¶
func (m *EdgeTypeMutation) FromID() (id string, exists bool)
FromID returns the "from" edge ID in the mutation.
func (*EdgeTypeMutation) FromIDs ¶
func (m *EdgeTypeMutation) FromIDs() (ids []string)
FromIDs returns the "from" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use FromID instead. It exists only for internal usage by the builders.
func (*EdgeTypeMutation) GetType ¶
func (m *EdgeTypeMutation) GetType() (r edgetype.Type, exists bool)
GetType returns the value of the "type" field in the mutation.
func (*EdgeTypeMutation) ID ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) IDs ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) NodeID ¶
func (m *EdgeTypeMutation) NodeID() (r string, exists bool)
NodeID returns the value of the "node_id" field in the mutation.
func (*EdgeTypeMutation) 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 (*EdgeTypeMutation) OldNodeID ¶
func (m *EdgeTypeMutation) OldNodeID(ctx context.Context) (v string, err error)
OldNodeID returns the old "node_id" field's value of the EdgeType entity. If the EdgeType 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 (*EdgeTypeMutation) OldToID ¶
func (m *EdgeTypeMutation) OldToID(ctx context.Context) (v string, err error)
OldToID returns the old "to_id" field's value of the EdgeType entity. If the EdgeType 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 (*EdgeTypeMutation) OldType ¶
OldType returns the old "type" field's value of the EdgeType entity. If the EdgeType 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 (*EdgeTypeMutation) RemovedEdges ¶
func (m *EdgeTypeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*EdgeTypeMutation) RemovedIDs ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) ResetEdge ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) ResetField ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) ResetFrom ¶
func (m *EdgeTypeMutation) ResetFrom()
ResetFrom resets all changes to the "from" edge.
func (*EdgeTypeMutation) ResetNodeID ¶
func (m *EdgeTypeMutation) ResetNodeID()
ResetNodeID resets all changes to the "node_id" field.
func (*EdgeTypeMutation) ResetTo ¶
func (m *EdgeTypeMutation) ResetTo()
ResetTo resets all changes to the "to" edge.
func (*EdgeTypeMutation) ResetToID ¶
func (m *EdgeTypeMutation) ResetToID()
ResetToID resets all changes to the "to_id" field.
func (*EdgeTypeMutation) ResetType ¶
func (m *EdgeTypeMutation) ResetType()
ResetType resets all changes to the "type" field.
func (*EdgeTypeMutation) SetField ¶
func (m *EdgeTypeMutation) 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 (*EdgeTypeMutation) SetFromID ¶
func (m *EdgeTypeMutation) SetFromID(id string)
SetFromID sets the "from" edge to the Node entity by id.
func (*EdgeTypeMutation) SetNodeID ¶
func (m *EdgeTypeMutation) SetNodeID(s string)
SetNodeID sets the "node_id" field.
func (*EdgeTypeMutation) SetOp ¶
func (m *EdgeTypeMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*EdgeTypeMutation) SetToID ¶
func (m *EdgeTypeMutation) SetToID(s string)
SetToID sets the "to_id" field.
func (*EdgeTypeMutation) SetType ¶
func (m *EdgeTypeMutation) SetType(e edgetype.Type)
SetType sets the "type" field.
func (*EdgeTypeMutation) ToCleared ¶
func (m *EdgeTypeMutation) ToCleared() bool
ToCleared reports if the "to" edge to the Node entity was cleared.
func (*EdgeTypeMutation) ToID ¶
func (m *EdgeTypeMutation) ToID() (r string, exists bool)
ToID returns the value of the "to_id" field in the mutation.
func (*EdgeTypeMutation) ToIDs ¶
func (m *EdgeTypeMutation) ToIDs() (ids []string)
ToIDs returns the "to" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ToID instead. It exists only for internal usage by the builders.
func (EdgeTypeMutation) Tx ¶
func (m EdgeTypeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*EdgeTypeMutation) Type ¶
func (m *EdgeTypeMutation) Type() string
Type returns the node type of this mutation (EdgeType).
func (*EdgeTypeMutation) Where ¶
func (m *EdgeTypeMutation) Where(ps ...predicate.EdgeType)
Where appends a list predicates to the EdgeTypeMutation builder.
func (*EdgeTypeMutation) WhereP ¶
func (m *EdgeTypeMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the EdgeTypeMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type EdgeTypeQuery ¶
type EdgeTypeQuery struct {
// contains filtered or unexported fields
}
EdgeTypeQuery is the builder for querying EdgeType entities.
func (*EdgeTypeQuery) Aggregate ¶
func (etq *EdgeTypeQuery) Aggregate(fns ...AggregateFunc) *EdgeTypeSelect
Aggregate returns a EdgeTypeSelect configured with the given aggregations.
func (*EdgeTypeQuery) All ¶
func (etq *EdgeTypeQuery) All(ctx context.Context) ([]*EdgeType, error)
All executes the query and returns a list of EdgeTypes.
func (*EdgeTypeQuery) AllX ¶
func (etq *EdgeTypeQuery) AllX(ctx context.Context) []*EdgeType
AllX is like All, but panics if an error occurs.
func (*EdgeTypeQuery) Clone ¶
func (etq *EdgeTypeQuery) Clone() *EdgeTypeQuery
Clone returns a duplicate of the EdgeTypeQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*EdgeTypeQuery) Count ¶
func (etq *EdgeTypeQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*EdgeTypeQuery) CountX ¶
func (etq *EdgeTypeQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*EdgeTypeQuery) Exist ¶
func (etq *EdgeTypeQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*EdgeTypeQuery) ExistX ¶
func (etq *EdgeTypeQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*EdgeTypeQuery) First ¶
func (etq *EdgeTypeQuery) First(ctx context.Context) (*EdgeType, error)
First returns the first EdgeType entity from the query. Returns a *NotFoundError when no EdgeType was found.
func (*EdgeTypeQuery) FirstID ¶
func (etq *EdgeTypeQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first EdgeType ID from the query. Returns a *NotFoundError when no EdgeType ID was found.
func (*EdgeTypeQuery) FirstIDX ¶
func (etq *EdgeTypeQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*EdgeTypeQuery) FirstX ¶
func (etq *EdgeTypeQuery) FirstX(ctx context.Context) *EdgeType
FirstX is like First, but panics if an error occurs.
func (*EdgeTypeQuery) GroupBy ¶
func (etq *EdgeTypeQuery) GroupBy(field string, fields ...string) *EdgeTypeGroupBy
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 { Type edgetype.Type `json:"type,omitempty"` Count int `json:"count,omitempty"` } client.EdgeType.Query(). GroupBy(edgetype.FieldType). Aggregate(ent.Count()). Scan(ctx, &v)
func (*EdgeTypeQuery) IDs ¶
func (etq *EdgeTypeQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of EdgeType IDs.
func (*EdgeTypeQuery) IDsX ¶
func (etq *EdgeTypeQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*EdgeTypeQuery) Limit ¶
func (etq *EdgeTypeQuery) Limit(limit int) *EdgeTypeQuery
Limit the number of records to be returned by this query.
func (*EdgeTypeQuery) Offset ¶
func (etq *EdgeTypeQuery) Offset(offset int) *EdgeTypeQuery
Offset to start from.
func (*EdgeTypeQuery) Only ¶
func (etq *EdgeTypeQuery) Only(ctx context.Context) (*EdgeType, error)
Only returns a single EdgeType entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one EdgeType entity is found. Returns a *NotFoundError when no EdgeType entities are found.
func (*EdgeTypeQuery) OnlyID ¶
func (etq *EdgeTypeQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only EdgeType ID in the query. Returns a *NotSingularError when more than one EdgeType ID is found. Returns a *NotFoundError when no entities are found.
func (*EdgeTypeQuery) OnlyIDX ¶
func (etq *EdgeTypeQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*EdgeTypeQuery) OnlyX ¶
func (etq *EdgeTypeQuery) OnlyX(ctx context.Context) *EdgeType
OnlyX is like Only, but panics if an error occurs.
func (*EdgeTypeQuery) Order ¶
func (etq *EdgeTypeQuery) Order(o ...edgetype.OrderOption) *EdgeTypeQuery
Order specifies how the records should be ordered.
func (*EdgeTypeQuery) QueryFrom ¶
func (etq *EdgeTypeQuery) QueryFrom() *NodeQuery
QueryFrom chains the current query on the "from" edge.
func (*EdgeTypeQuery) QueryTo ¶
func (etq *EdgeTypeQuery) QueryTo() *NodeQuery
QueryTo chains the current query on the "to" edge.
func (*EdgeTypeQuery) Select ¶
func (etq *EdgeTypeQuery) Select(fields ...string) *EdgeTypeSelect
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 { Type edgetype.Type `json:"type,omitempty"` } client.EdgeType.Query(). Select(edgetype.FieldType). Scan(ctx, &v)
func (*EdgeTypeQuery) Unique ¶
func (etq *EdgeTypeQuery) Unique(unique bool) *EdgeTypeQuery
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 (*EdgeTypeQuery) Where ¶
func (etq *EdgeTypeQuery) Where(ps ...predicate.EdgeType) *EdgeTypeQuery
Where adds a new predicate for the EdgeTypeQuery builder.
func (*EdgeTypeQuery) WithFrom ¶
func (etq *EdgeTypeQuery) WithFrom(opts ...func(*NodeQuery)) *EdgeTypeQuery
WithFrom tells the query-builder to eager-load the nodes that are connected to the "from" edge. The optional arguments are used to configure the query builder of the edge.
func (*EdgeTypeQuery) WithTo ¶
func (etq *EdgeTypeQuery) WithTo(opts ...func(*NodeQuery)) *EdgeTypeQuery
WithTo tells the query-builder to eager-load the nodes that are connected to the "to" edge. The optional arguments are used to configure the query builder of the edge.
type EdgeTypeSelect ¶
type EdgeTypeSelect struct { *EdgeTypeQuery // contains filtered or unexported fields }
EdgeTypeSelect is the builder for selecting fields of EdgeType entities.
func (*EdgeTypeSelect) Aggregate ¶
func (ets *EdgeTypeSelect) Aggregate(fns ...AggregateFunc) *EdgeTypeSelect
Aggregate adds the given aggregation functions to the selector query.
func (*EdgeTypeSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*EdgeTypeSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*EdgeTypeSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*EdgeTypeSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*EdgeTypeSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*EdgeTypeSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*EdgeTypeSelect) Scan ¶
func (ets *EdgeTypeSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*EdgeTypeSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type EdgeTypeUpdate ¶
type EdgeTypeUpdate struct {
// contains filtered or unexported fields
}
EdgeTypeUpdate is the builder for updating EdgeType entities.
func (*EdgeTypeUpdate) ClearFrom ¶
func (etu *EdgeTypeUpdate) ClearFrom() *EdgeTypeUpdate
ClearFrom clears the "from" edge to the Node entity.
func (*EdgeTypeUpdate) ClearTo ¶
func (etu *EdgeTypeUpdate) ClearTo() *EdgeTypeUpdate
ClearTo clears the "to" edge to the Node entity.
func (*EdgeTypeUpdate) Exec ¶
func (etu *EdgeTypeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*EdgeTypeUpdate) ExecX ¶
func (etu *EdgeTypeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeUpdate) Mutation ¶
func (etu *EdgeTypeUpdate) Mutation() *EdgeTypeMutation
Mutation returns the EdgeTypeMutation object of the builder.
func (*EdgeTypeUpdate) Save ¶
func (etu *EdgeTypeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*EdgeTypeUpdate) SaveX ¶
func (etu *EdgeTypeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*EdgeTypeUpdate) SetFrom ¶
func (etu *EdgeTypeUpdate) SetFrom(n *Node) *EdgeTypeUpdate
SetFrom sets the "from" edge to the Node entity.
func (*EdgeTypeUpdate) SetFromID ¶
func (etu *EdgeTypeUpdate) SetFromID(id string) *EdgeTypeUpdate
SetFromID sets the "from" edge to the Node entity by ID.
func (*EdgeTypeUpdate) SetNillableNodeID ¶
func (etu *EdgeTypeUpdate) SetNillableNodeID(s *string) *EdgeTypeUpdate
SetNillableNodeID sets the "node_id" field if the given value is not nil.
func (*EdgeTypeUpdate) SetNillableToID ¶
func (etu *EdgeTypeUpdate) SetNillableToID(s *string) *EdgeTypeUpdate
SetNillableToID sets the "to_id" field if the given value is not nil.
func (*EdgeTypeUpdate) SetNillableType ¶
func (etu *EdgeTypeUpdate) SetNillableType(e *edgetype.Type) *EdgeTypeUpdate
SetNillableType sets the "type" field if the given value is not nil.
func (*EdgeTypeUpdate) SetNodeID ¶
func (etu *EdgeTypeUpdate) SetNodeID(s string) *EdgeTypeUpdate
SetNodeID sets the "node_id" field.
func (*EdgeTypeUpdate) SetTo ¶
func (etu *EdgeTypeUpdate) SetTo(n *Node) *EdgeTypeUpdate
SetTo sets the "to" edge to the Node entity.
func (*EdgeTypeUpdate) SetToID ¶
func (etu *EdgeTypeUpdate) SetToID(s string) *EdgeTypeUpdate
SetToID sets the "to_id" field.
func (*EdgeTypeUpdate) SetType ¶
func (etu *EdgeTypeUpdate) SetType(e edgetype.Type) *EdgeTypeUpdate
SetType sets the "type" field.
func (*EdgeTypeUpdate) Where ¶
func (etu *EdgeTypeUpdate) Where(ps ...predicate.EdgeType) *EdgeTypeUpdate
Where appends a list predicates to the EdgeTypeUpdate builder.
type EdgeTypeUpdateOne ¶
type EdgeTypeUpdateOne struct {
// contains filtered or unexported fields
}
EdgeTypeUpdateOne is the builder for updating a single EdgeType entity.
func (*EdgeTypeUpdateOne) ClearFrom ¶
func (etuo *EdgeTypeUpdateOne) ClearFrom() *EdgeTypeUpdateOne
ClearFrom clears the "from" edge to the Node entity.
func (*EdgeTypeUpdateOne) ClearTo ¶
func (etuo *EdgeTypeUpdateOne) ClearTo() *EdgeTypeUpdateOne
ClearTo clears the "to" edge to the Node entity.
func (*EdgeTypeUpdateOne) Exec ¶
func (etuo *EdgeTypeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*EdgeTypeUpdateOne) ExecX ¶
func (etuo *EdgeTypeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeUpdateOne) Mutation ¶
func (etuo *EdgeTypeUpdateOne) Mutation() *EdgeTypeMutation
Mutation returns the EdgeTypeMutation object of the builder.
func (*EdgeTypeUpdateOne) Save ¶
func (etuo *EdgeTypeUpdateOne) Save(ctx context.Context) (*EdgeType, error)
Save executes the query and returns the updated EdgeType entity.
func (*EdgeTypeUpdateOne) SaveX ¶
func (etuo *EdgeTypeUpdateOne) SaveX(ctx context.Context) *EdgeType
SaveX is like Save, but panics if an error occurs.
func (*EdgeTypeUpdateOne) Select ¶
func (etuo *EdgeTypeUpdateOne) Select(field string, fields ...string) *EdgeTypeUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*EdgeTypeUpdateOne) SetFrom ¶
func (etuo *EdgeTypeUpdateOne) SetFrom(n *Node) *EdgeTypeUpdateOne
SetFrom sets the "from" edge to the Node entity.
func (*EdgeTypeUpdateOne) SetFromID ¶
func (etuo *EdgeTypeUpdateOne) SetFromID(id string) *EdgeTypeUpdateOne
SetFromID sets the "from" edge to the Node entity by ID.
func (*EdgeTypeUpdateOne) SetNillableNodeID ¶
func (etuo *EdgeTypeUpdateOne) SetNillableNodeID(s *string) *EdgeTypeUpdateOne
SetNillableNodeID sets the "node_id" field if the given value is not nil.
func (*EdgeTypeUpdateOne) SetNillableToID ¶
func (etuo *EdgeTypeUpdateOne) SetNillableToID(s *string) *EdgeTypeUpdateOne
SetNillableToID sets the "to_id" field if the given value is not nil.
func (*EdgeTypeUpdateOne) SetNillableType ¶
func (etuo *EdgeTypeUpdateOne) SetNillableType(e *edgetype.Type) *EdgeTypeUpdateOne
SetNillableType sets the "type" field if the given value is not nil.
func (*EdgeTypeUpdateOne) SetNodeID ¶
func (etuo *EdgeTypeUpdateOne) SetNodeID(s string) *EdgeTypeUpdateOne
SetNodeID sets the "node_id" field.
func (*EdgeTypeUpdateOne) SetTo ¶
func (etuo *EdgeTypeUpdateOne) SetTo(n *Node) *EdgeTypeUpdateOne
SetTo sets the "to" edge to the Node entity.
func (*EdgeTypeUpdateOne) SetToID ¶
func (etuo *EdgeTypeUpdateOne) SetToID(s string) *EdgeTypeUpdateOne
SetToID sets the "to_id" field.
func (*EdgeTypeUpdateOne) SetType ¶
func (etuo *EdgeTypeUpdateOne) SetType(e edgetype.Type) *EdgeTypeUpdateOne
SetType sets the "type" field.
func (*EdgeTypeUpdateOne) Where ¶
func (etuo *EdgeTypeUpdateOne) Where(ps ...predicate.EdgeType) *EdgeTypeUpdateOne
Where appends a list predicates to the EdgeTypeUpdate builder.
type EdgeTypeUpsert ¶
EdgeTypeUpsert is the "OnConflict" setter.
func (*EdgeTypeUpsert) SetNodeID ¶
func (u *EdgeTypeUpsert) SetNodeID(v string) *EdgeTypeUpsert
SetNodeID sets the "node_id" field.
func (*EdgeTypeUpsert) SetToID ¶
func (u *EdgeTypeUpsert) SetToID(v string) *EdgeTypeUpsert
SetToID sets the "to_id" field.
func (*EdgeTypeUpsert) SetType ¶
func (u *EdgeTypeUpsert) SetType(v edgetype.Type) *EdgeTypeUpsert
SetType sets the "type" field.
func (*EdgeTypeUpsert) UpdateNodeID ¶
func (u *EdgeTypeUpsert) UpdateNodeID() *EdgeTypeUpsert
UpdateNodeID sets the "node_id" field to the value that was provided on create.
func (*EdgeTypeUpsert) UpdateToID ¶
func (u *EdgeTypeUpsert) UpdateToID() *EdgeTypeUpsert
UpdateToID sets the "to_id" field to the value that was provided on create.
func (*EdgeTypeUpsert) UpdateType ¶
func (u *EdgeTypeUpsert) UpdateType() *EdgeTypeUpsert
UpdateType sets the "type" field to the value that was provided on create.
type EdgeTypeUpsertBulk ¶
type EdgeTypeUpsertBulk struct {
// contains filtered or unexported fields
}
EdgeTypeUpsertBulk is the builder for "upsert"-ing a bulk of EdgeType nodes.
func (*EdgeTypeUpsertBulk) DoNothing ¶
func (u *EdgeTypeUpsertBulk) DoNothing() *EdgeTypeUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*EdgeTypeUpsertBulk) Exec ¶
func (u *EdgeTypeUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*EdgeTypeUpsertBulk) ExecX ¶
func (u *EdgeTypeUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeUpsertBulk) Ignore ¶
func (u *EdgeTypeUpsertBulk) Ignore() *EdgeTypeUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.EdgeType.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*EdgeTypeUpsertBulk) SetNodeID ¶
func (u *EdgeTypeUpsertBulk) SetNodeID(v string) *EdgeTypeUpsertBulk
SetNodeID sets the "node_id" field.
func (*EdgeTypeUpsertBulk) SetToID ¶
func (u *EdgeTypeUpsertBulk) SetToID(v string) *EdgeTypeUpsertBulk
SetToID sets the "to_id" field.
func (*EdgeTypeUpsertBulk) SetType ¶
func (u *EdgeTypeUpsertBulk) SetType(v edgetype.Type) *EdgeTypeUpsertBulk
SetType sets the "type" field.
func (*EdgeTypeUpsertBulk) Update ¶
func (u *EdgeTypeUpsertBulk) Update(set func(*EdgeTypeUpsert)) *EdgeTypeUpsertBulk
Update allows overriding fields `UPDATE` values. See the EdgeTypeCreateBulk.OnConflict documentation for more info.
func (*EdgeTypeUpsertBulk) UpdateNewValues ¶
func (u *EdgeTypeUpsertBulk) UpdateNewValues() *EdgeTypeUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.EdgeType.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*EdgeTypeUpsertBulk) UpdateNodeID ¶
func (u *EdgeTypeUpsertBulk) UpdateNodeID() *EdgeTypeUpsertBulk
UpdateNodeID sets the "node_id" field to the value that was provided on create.
func (*EdgeTypeUpsertBulk) UpdateToID ¶
func (u *EdgeTypeUpsertBulk) UpdateToID() *EdgeTypeUpsertBulk
UpdateToID sets the "to_id" field to the value that was provided on create.
func (*EdgeTypeUpsertBulk) UpdateType ¶
func (u *EdgeTypeUpsertBulk) UpdateType() *EdgeTypeUpsertBulk
UpdateType sets the "type" field to the value that was provided on create.
type EdgeTypeUpsertOne ¶
type EdgeTypeUpsertOne struct {
// contains filtered or unexported fields
}
EdgeTypeUpsertOne is the builder for "upsert"-ing
one EdgeType node.
func (*EdgeTypeUpsertOne) DoNothing ¶
func (u *EdgeTypeUpsertOne) DoNothing() *EdgeTypeUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*EdgeTypeUpsertOne) Exec ¶
func (u *EdgeTypeUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*EdgeTypeUpsertOne) ExecX ¶
func (u *EdgeTypeUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*EdgeTypeUpsertOne) ID ¶
func (u *EdgeTypeUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*EdgeTypeUpsertOne) IDX ¶
func (u *EdgeTypeUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*EdgeTypeUpsertOne) Ignore ¶
func (u *EdgeTypeUpsertOne) Ignore() *EdgeTypeUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.EdgeType.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*EdgeTypeUpsertOne) SetNodeID ¶
func (u *EdgeTypeUpsertOne) SetNodeID(v string) *EdgeTypeUpsertOne
SetNodeID sets the "node_id" field.
func (*EdgeTypeUpsertOne) SetToID ¶
func (u *EdgeTypeUpsertOne) SetToID(v string) *EdgeTypeUpsertOne
SetToID sets the "to_id" field.
func (*EdgeTypeUpsertOne) SetType ¶
func (u *EdgeTypeUpsertOne) SetType(v edgetype.Type) *EdgeTypeUpsertOne
SetType sets the "type" field.
func (*EdgeTypeUpsertOne) Update ¶
func (u *EdgeTypeUpsertOne) Update(set func(*EdgeTypeUpsert)) *EdgeTypeUpsertOne
Update allows overriding fields `UPDATE` values. See the EdgeTypeCreate.OnConflict documentation for more info.
func (*EdgeTypeUpsertOne) UpdateNewValues ¶
func (u *EdgeTypeUpsertOne) UpdateNewValues() *EdgeTypeUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.EdgeType.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*EdgeTypeUpsertOne) UpdateNodeID ¶
func (u *EdgeTypeUpsertOne) UpdateNodeID() *EdgeTypeUpsertOne
UpdateNodeID sets the "node_id" field to the value that was provided on create.
func (*EdgeTypeUpsertOne) UpdateToID ¶
func (u *EdgeTypeUpsertOne) UpdateToID() *EdgeTypeUpsertOne
UpdateToID sets the "to_id" field to the value that was provided on create.
func (*EdgeTypeUpsertOne) UpdateType ¶
func (u *EdgeTypeUpsertOne) UpdateType() *EdgeTypeUpsertOne
UpdateType sets the "type" field to the value that was provided on create.
type ExternalReference ¶
type ExternalReference struct { // ID of the ent. ID int `json:"id,omitempty"` // URL holds the value of the "url" field. URL string `json:"url,omitempty"` // Comment holds the value of the "comment" field. Comment string `json:"comment,omitempty"` // Authority holds the value of the "authority" field. Authority string `json:"authority,omitempty"` // Type holds the value of the "type" field. Type externalreference.Type `json:"type,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the ExternalReferenceQuery when eager-loading is set. Edges ExternalReferenceEdges `json:"edges"` // contains filtered or unexported fields }
ExternalReference is the model entity for the ExternalReference schema.
func (*ExternalReference) QueryHashes ¶
func (er *ExternalReference) QueryHashes() *HashesEntryQuery
QueryHashes queries the "hashes" edge of the ExternalReference entity.
func (*ExternalReference) QueryNode ¶
func (er *ExternalReference) QueryNode() *NodeQuery
QueryNode queries the "node" edge of the ExternalReference entity.
func (*ExternalReference) String ¶
func (er *ExternalReference) String() string
String implements the fmt.Stringer.
func (*ExternalReference) Unwrap ¶
func (er *ExternalReference) Unwrap() *ExternalReference
Unwrap unwraps the ExternalReference 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 (*ExternalReference) Update ¶
func (er *ExternalReference) Update() *ExternalReferenceUpdateOne
Update returns a builder for updating this ExternalReference. Note that you need to call ExternalReference.Unwrap() before calling this method if this ExternalReference was returned from a transaction, and the transaction was committed or rolled back.
type ExternalReferenceClient ¶
type ExternalReferenceClient struct {
// contains filtered or unexported fields
}
ExternalReferenceClient is a client for the ExternalReference schema.
func NewExternalReferenceClient ¶
func NewExternalReferenceClient(c config) *ExternalReferenceClient
NewExternalReferenceClient returns a client for the ExternalReference from the given config.
func (*ExternalReferenceClient) Create ¶
func (c *ExternalReferenceClient) Create() *ExternalReferenceCreate
Create returns a builder for creating a ExternalReference entity.
func (*ExternalReferenceClient) CreateBulk ¶
func (c *ExternalReferenceClient) CreateBulk(builders ...*ExternalReferenceCreate) *ExternalReferenceCreateBulk
CreateBulk returns a builder for creating a bulk of ExternalReference entities.
func (*ExternalReferenceClient) Delete ¶
func (c *ExternalReferenceClient) Delete() *ExternalReferenceDelete
Delete returns a delete builder for ExternalReference.
func (*ExternalReferenceClient) DeleteOne ¶
func (c *ExternalReferenceClient) DeleteOne(er *ExternalReference) *ExternalReferenceDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*ExternalReferenceClient) DeleteOneID ¶
func (c *ExternalReferenceClient) DeleteOneID(id int) *ExternalReferenceDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*ExternalReferenceClient) Get ¶
func (c *ExternalReferenceClient) Get(ctx context.Context, id int) (*ExternalReference, error)
Get returns a ExternalReference entity by its id.
func (*ExternalReferenceClient) GetX ¶
func (c *ExternalReferenceClient) GetX(ctx context.Context, id int) *ExternalReference
GetX is like Get, but panics if an error occurs.
func (*ExternalReferenceClient) Hooks ¶
func (c *ExternalReferenceClient) Hooks() []Hook
Hooks returns the client hooks.
func (*ExternalReferenceClient) Intercept ¶
func (c *ExternalReferenceClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `externalreference.Intercept(f(g(h())))`.
func (*ExternalReferenceClient) Interceptors ¶
func (c *ExternalReferenceClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*ExternalReferenceClient) MapCreateBulk ¶
func (c *ExternalReferenceClient) MapCreateBulk(slice any, setFunc func(*ExternalReferenceCreate, int)) *ExternalReferenceCreateBulk
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 (*ExternalReferenceClient) Query ¶
func (c *ExternalReferenceClient) Query() *ExternalReferenceQuery
Query returns a query builder for ExternalReference.
func (*ExternalReferenceClient) QueryHashes ¶
func (c *ExternalReferenceClient) QueryHashes(er *ExternalReference) *HashesEntryQuery
QueryHashes queries the hashes edge of a ExternalReference.
func (*ExternalReferenceClient) QueryNode ¶
func (c *ExternalReferenceClient) QueryNode(er *ExternalReference) *NodeQuery
QueryNode queries the node edge of a ExternalReference.
func (*ExternalReferenceClient) Update ¶
func (c *ExternalReferenceClient) Update() *ExternalReferenceUpdate
Update returns an update builder for ExternalReference.
func (*ExternalReferenceClient) UpdateOne ¶
func (c *ExternalReferenceClient) UpdateOne(er *ExternalReference) *ExternalReferenceUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ExternalReferenceClient) UpdateOneID ¶
func (c *ExternalReferenceClient) UpdateOneID(id int) *ExternalReferenceUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ExternalReferenceClient) Use ¶
func (c *ExternalReferenceClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `externalreference.Hooks(f(g(h())))`.
type ExternalReferenceCreate ¶
type ExternalReferenceCreate struct {
// contains filtered or unexported fields
}
ExternalReferenceCreate is the builder for creating a ExternalReference entity.
func (*ExternalReferenceCreate) AddHashIDs ¶
func (erc *ExternalReferenceCreate) AddHashIDs(ids ...int) *ExternalReferenceCreate
AddHashIDs adds the "hashes" edge to the HashesEntry entity by IDs.
func (*ExternalReferenceCreate) AddHashes ¶
func (erc *ExternalReferenceCreate) AddHashes(h ...*HashesEntry) *ExternalReferenceCreate
AddHashes adds the "hashes" edges to the HashesEntry entity.
func (*ExternalReferenceCreate) Exec ¶
func (erc *ExternalReferenceCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ExternalReferenceCreate) ExecX ¶
func (erc *ExternalReferenceCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceCreate) Mutation ¶
func (erc *ExternalReferenceCreate) Mutation() *ExternalReferenceMutation
Mutation returns the ExternalReferenceMutation object of the builder.
func (*ExternalReferenceCreate) OnConflict ¶
func (erc *ExternalReferenceCreate) OnConflict(opts ...sql.ConflictOption) *ExternalReferenceUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.ExternalReference.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.ExternalReferenceUpsert) { SetURL(v+v). }). Exec(ctx)
func (*ExternalReferenceCreate) OnConflictColumns ¶
func (erc *ExternalReferenceCreate) OnConflictColumns(columns ...string) *ExternalReferenceUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.ExternalReference.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*ExternalReferenceCreate) Save ¶
func (erc *ExternalReferenceCreate) Save(ctx context.Context) (*ExternalReference, error)
Save creates the ExternalReference in the database.
func (*ExternalReferenceCreate) SaveX ¶
func (erc *ExternalReferenceCreate) SaveX(ctx context.Context) *ExternalReference
SaveX calls Save and panics if Save returns an error.
func (*ExternalReferenceCreate) SetAuthority ¶
func (erc *ExternalReferenceCreate) SetAuthority(s string) *ExternalReferenceCreate
SetAuthority sets the "authority" field.
func (*ExternalReferenceCreate) SetComment ¶
func (erc *ExternalReferenceCreate) SetComment(s string) *ExternalReferenceCreate
SetComment sets the "comment" field.
func (*ExternalReferenceCreate) SetNillableAuthority ¶
func (erc *ExternalReferenceCreate) SetNillableAuthority(s *string) *ExternalReferenceCreate
SetNillableAuthority sets the "authority" field if the given value is not nil.
func (*ExternalReferenceCreate) SetNode ¶
func (erc *ExternalReferenceCreate) SetNode(n *Node) *ExternalReferenceCreate
SetNode sets the "node" edge to the Node entity.
func (*ExternalReferenceCreate) SetNodeID ¶
func (erc *ExternalReferenceCreate) SetNodeID(id string) *ExternalReferenceCreate
SetNodeID sets the "node" edge to the Node entity by ID.
func (*ExternalReferenceCreate) SetType ¶
func (erc *ExternalReferenceCreate) SetType(e externalreference.Type) *ExternalReferenceCreate
SetType sets the "type" field.
func (*ExternalReferenceCreate) SetURL ¶
func (erc *ExternalReferenceCreate) SetURL(s string) *ExternalReferenceCreate
SetURL sets the "url" field.
type ExternalReferenceCreateBulk ¶
type ExternalReferenceCreateBulk struct {
// contains filtered or unexported fields
}
ExternalReferenceCreateBulk is the builder for creating many ExternalReference entities in bulk.
func (*ExternalReferenceCreateBulk) Exec ¶
func (ercb *ExternalReferenceCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ExternalReferenceCreateBulk) ExecX ¶
func (ercb *ExternalReferenceCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceCreateBulk) OnConflict ¶
func (ercb *ExternalReferenceCreateBulk) OnConflict(opts ...sql.ConflictOption) *ExternalReferenceUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.ExternalReference.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.ExternalReferenceUpsert) { SetURL(v+v). }). Exec(ctx)
func (*ExternalReferenceCreateBulk) OnConflictColumns ¶
func (ercb *ExternalReferenceCreateBulk) OnConflictColumns(columns ...string) *ExternalReferenceUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.ExternalReference.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*ExternalReferenceCreateBulk) Save ¶
func (ercb *ExternalReferenceCreateBulk) Save(ctx context.Context) ([]*ExternalReference, error)
Save creates the ExternalReference entities in the database.
func (*ExternalReferenceCreateBulk) SaveX ¶
func (ercb *ExternalReferenceCreateBulk) SaveX(ctx context.Context) []*ExternalReference
SaveX is like Save, but panics if an error occurs.
type ExternalReferenceDelete ¶
type ExternalReferenceDelete struct {
// contains filtered or unexported fields
}
ExternalReferenceDelete is the builder for deleting a ExternalReference entity.
func (*ExternalReferenceDelete) Exec ¶
func (erd *ExternalReferenceDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ExternalReferenceDelete) ExecX ¶
func (erd *ExternalReferenceDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceDelete) Where ¶
func (erd *ExternalReferenceDelete) Where(ps ...predicate.ExternalReference) *ExternalReferenceDelete
Where appends a list predicates to the ExternalReferenceDelete builder.
type ExternalReferenceDeleteOne ¶
type ExternalReferenceDeleteOne struct {
// contains filtered or unexported fields
}
ExternalReferenceDeleteOne is the builder for deleting a single ExternalReference entity.
func (*ExternalReferenceDeleteOne) Exec ¶
func (erdo *ExternalReferenceDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ExternalReferenceDeleteOne) ExecX ¶
func (erdo *ExternalReferenceDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceDeleteOne) Where ¶
func (erdo *ExternalReferenceDeleteOne) Where(ps ...predicate.ExternalReference) *ExternalReferenceDeleteOne
Where appends a list predicates to the ExternalReferenceDelete builder.
type ExternalReferenceEdges ¶
type ExternalReferenceEdges struct { // Hashes holds the value of the hashes edge. Hashes []*HashesEntry `json:"hashes,omitempty"` // Node holds the value of the node edge. Node *Node `json:"node,omitempty"` // contains filtered or unexported fields }
ExternalReferenceEdges holds the relations/edges for other nodes in the graph.
func (ExternalReferenceEdges) HashesOrErr ¶
func (e ExternalReferenceEdges) HashesOrErr() ([]*HashesEntry, error)
HashesOrErr returns the Hashes value or an error if the edge was not loaded in eager-loading.
func (ExternalReferenceEdges) NodeOrErr ¶
func (e ExternalReferenceEdges) NodeOrErr() (*Node, error)
NodeOrErr returns the Node value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type ExternalReferenceGroupBy ¶
type ExternalReferenceGroupBy struct {
// contains filtered or unexported fields
}
ExternalReferenceGroupBy is the group-by builder for ExternalReference entities.
func (*ExternalReferenceGroupBy) Aggregate ¶
func (ergb *ExternalReferenceGroupBy) Aggregate(fns ...AggregateFunc) *ExternalReferenceGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ExternalReferenceGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceGroupBy) Float64X ¶
Float64X is like Float64, but panics if an error occurs.
func (*ExternalReferenceGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceGroupBy) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*ExternalReferenceGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceGroupBy) Scan ¶
func (ergb *ExternalReferenceGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ExternalReferenceGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ExternalReferenceMutation ¶
type ExternalReferenceMutation struct {
// contains filtered or unexported fields
}
ExternalReferenceMutation represents an operation that mutates the ExternalReference nodes in the graph.
func (*ExternalReferenceMutation) AddField ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) AddHashIDs ¶
func (m *ExternalReferenceMutation) AddHashIDs(ids ...int)
AddHashIDs adds the "hashes" edge to the HashesEntry entity by ids.
func (*ExternalReferenceMutation) AddedEdges ¶
func (m *ExternalReferenceMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ExternalReferenceMutation) AddedField ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) AddedFields ¶
func (m *ExternalReferenceMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ExternalReferenceMutation) AddedIDs ¶
func (m *ExternalReferenceMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ExternalReferenceMutation) Authority ¶
func (m *ExternalReferenceMutation) Authority() (r string, exists bool)
Authority returns the value of the "authority" field in the mutation.
func (*ExternalReferenceMutation) AuthorityCleared ¶
func (m *ExternalReferenceMutation) AuthorityCleared() bool
AuthorityCleared returns if the "authority" field was cleared in this mutation.
func (*ExternalReferenceMutation) ClearAuthority ¶
func (m *ExternalReferenceMutation) ClearAuthority()
ClearAuthority clears the value of the "authority" field.
func (*ExternalReferenceMutation) ClearEdge ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) ClearField ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) ClearHashes ¶
func (m *ExternalReferenceMutation) ClearHashes()
ClearHashes clears the "hashes" edge to the HashesEntry entity.
func (*ExternalReferenceMutation) ClearNode ¶
func (m *ExternalReferenceMutation) ClearNode()
ClearNode clears the "node" edge to the Node entity.
func (*ExternalReferenceMutation) ClearedEdges ¶
func (m *ExternalReferenceMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ExternalReferenceMutation) ClearedFields ¶
func (m *ExternalReferenceMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ExternalReferenceMutation) Client ¶
func (m ExternalReferenceMutation) 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 (*ExternalReferenceMutation) Comment ¶
func (m *ExternalReferenceMutation) Comment() (r string, exists bool)
Comment returns the value of the "comment" field in the mutation.
func (*ExternalReferenceMutation) EdgeCleared ¶
func (m *ExternalReferenceMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ExternalReferenceMutation) Field ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) FieldCleared ¶
func (m *ExternalReferenceMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ExternalReferenceMutation) Fields ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) GetType ¶
func (m *ExternalReferenceMutation) GetType() (r externalreference.Type, exists bool)
GetType returns the value of the "type" field in the mutation.
func (*ExternalReferenceMutation) HashesCleared ¶
func (m *ExternalReferenceMutation) HashesCleared() bool
HashesCleared reports if the "hashes" edge to the HashesEntry entity was cleared.
func (*ExternalReferenceMutation) HashesIDs ¶
func (m *ExternalReferenceMutation) HashesIDs() (ids []int)
HashesIDs returns the "hashes" edge IDs in the mutation.
func (*ExternalReferenceMutation) ID ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) IDs ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) NodeCleared ¶
func (m *ExternalReferenceMutation) NodeCleared() bool
NodeCleared reports if the "node" edge to the Node entity was cleared.
func (*ExternalReferenceMutation) NodeID ¶
func (m *ExternalReferenceMutation) NodeID() (id string, exists bool)
NodeID returns the "node" edge ID in the mutation.
func (*ExternalReferenceMutation) NodeIDs ¶
func (m *ExternalReferenceMutation) NodeIDs() (ids []string)
NodeIDs returns the "node" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use NodeID instead. It exists only for internal usage by the builders.
func (*ExternalReferenceMutation) OldAuthority ¶
func (m *ExternalReferenceMutation) OldAuthority(ctx context.Context) (v string, err error)
OldAuthority returns the old "authority" field's value of the ExternalReference entity. If the ExternalReference 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 (*ExternalReferenceMutation) OldComment ¶
func (m *ExternalReferenceMutation) OldComment(ctx context.Context) (v string, err error)
OldComment returns the old "comment" field's value of the ExternalReference entity. If the ExternalReference 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 (*ExternalReferenceMutation) 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 (*ExternalReferenceMutation) OldType ¶
func (m *ExternalReferenceMutation) OldType(ctx context.Context) (v externalreference.Type, err error)
OldType returns the old "type" field's value of the ExternalReference entity. If the ExternalReference 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 (*ExternalReferenceMutation) OldURL ¶
func (m *ExternalReferenceMutation) OldURL(ctx context.Context) (v string, err error)
OldURL returns the old "url" field's value of the ExternalReference entity. If the ExternalReference 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 (*ExternalReferenceMutation) Op ¶
func (m *ExternalReferenceMutation) Op() Op
Op returns the operation name.
func (*ExternalReferenceMutation) RemoveHashIDs ¶
func (m *ExternalReferenceMutation) RemoveHashIDs(ids ...int)
RemoveHashIDs removes the "hashes" edge to the HashesEntry entity by IDs.
func (*ExternalReferenceMutation) RemovedEdges ¶
func (m *ExternalReferenceMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ExternalReferenceMutation) RemovedHashesIDs ¶
func (m *ExternalReferenceMutation) RemovedHashesIDs() (ids []int)
RemovedHashes returns the removed IDs of the "hashes" edge to the HashesEntry entity.
func (*ExternalReferenceMutation) RemovedIDs ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) ResetAuthority ¶
func (m *ExternalReferenceMutation) ResetAuthority()
ResetAuthority resets all changes to the "authority" field.
func (*ExternalReferenceMutation) ResetComment ¶
func (m *ExternalReferenceMutation) ResetComment()
ResetComment resets all changes to the "comment" field.
func (*ExternalReferenceMutation) ResetEdge ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) ResetField ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) ResetHashes ¶
func (m *ExternalReferenceMutation) ResetHashes()
ResetHashes resets all changes to the "hashes" edge.
func (*ExternalReferenceMutation) ResetNode ¶
func (m *ExternalReferenceMutation) ResetNode()
ResetNode resets all changes to the "node" edge.
func (*ExternalReferenceMutation) ResetType ¶
func (m *ExternalReferenceMutation) ResetType()
ResetType resets all changes to the "type" field.
func (*ExternalReferenceMutation) ResetURL ¶
func (m *ExternalReferenceMutation) ResetURL()
ResetURL resets all changes to the "url" field.
func (*ExternalReferenceMutation) SetAuthority ¶
func (m *ExternalReferenceMutation) SetAuthority(s string)
SetAuthority sets the "authority" field.
func (*ExternalReferenceMutation) SetComment ¶
func (m *ExternalReferenceMutation) SetComment(s string)
SetComment sets the "comment" field.
func (*ExternalReferenceMutation) SetField ¶
func (m *ExternalReferenceMutation) 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 (*ExternalReferenceMutation) SetNodeID ¶
func (m *ExternalReferenceMutation) SetNodeID(id string)
SetNodeID sets the "node" edge to the Node entity by id.
func (*ExternalReferenceMutation) SetOp ¶
func (m *ExternalReferenceMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*ExternalReferenceMutation) SetType ¶
func (m *ExternalReferenceMutation) SetType(e externalreference.Type)
SetType sets the "type" field.
func (*ExternalReferenceMutation) SetURL ¶
func (m *ExternalReferenceMutation) SetURL(s string)
SetURL sets the "url" field.
func (ExternalReferenceMutation) Tx ¶
func (m ExternalReferenceMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ExternalReferenceMutation) Type ¶
func (m *ExternalReferenceMutation) Type() string
Type returns the node type of this mutation (ExternalReference).
func (*ExternalReferenceMutation) URL ¶
func (m *ExternalReferenceMutation) URL() (r string, exists bool)
URL returns the value of the "url" field in the mutation.
func (*ExternalReferenceMutation) Where ¶
func (m *ExternalReferenceMutation) Where(ps ...predicate.ExternalReference)
Where appends a list predicates to the ExternalReferenceMutation builder.
func (*ExternalReferenceMutation) WhereP ¶
func (m *ExternalReferenceMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the ExternalReferenceMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type ExternalReferenceQuery ¶
type ExternalReferenceQuery struct {
// contains filtered or unexported fields
}
ExternalReferenceQuery is the builder for querying ExternalReference entities.
func (*ExternalReferenceQuery) Aggregate ¶
func (erq *ExternalReferenceQuery) Aggregate(fns ...AggregateFunc) *ExternalReferenceSelect
Aggregate returns a ExternalReferenceSelect configured with the given aggregations.
func (*ExternalReferenceQuery) All ¶
func (erq *ExternalReferenceQuery) All(ctx context.Context) ([]*ExternalReference, error)
All executes the query and returns a list of ExternalReferences.
func (*ExternalReferenceQuery) AllX ¶
func (erq *ExternalReferenceQuery) AllX(ctx context.Context) []*ExternalReference
AllX is like All, but panics if an error occurs.
func (*ExternalReferenceQuery) Clone ¶
func (erq *ExternalReferenceQuery) Clone() *ExternalReferenceQuery
Clone returns a duplicate of the ExternalReferenceQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ExternalReferenceQuery) Count ¶
func (erq *ExternalReferenceQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*ExternalReferenceQuery) CountX ¶
func (erq *ExternalReferenceQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*ExternalReferenceQuery) Exist ¶
func (erq *ExternalReferenceQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*ExternalReferenceQuery) ExistX ¶
func (erq *ExternalReferenceQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*ExternalReferenceQuery) First ¶
func (erq *ExternalReferenceQuery) First(ctx context.Context) (*ExternalReference, error)
First returns the first ExternalReference entity from the query. Returns a *NotFoundError when no ExternalReference was found.
func (*ExternalReferenceQuery) FirstID ¶
func (erq *ExternalReferenceQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first ExternalReference ID from the query. Returns a *NotFoundError when no ExternalReference ID was found.
func (*ExternalReferenceQuery) FirstIDX ¶
func (erq *ExternalReferenceQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*ExternalReferenceQuery) FirstX ¶
func (erq *ExternalReferenceQuery) FirstX(ctx context.Context) *ExternalReference
FirstX is like First, but panics if an error occurs.
func (*ExternalReferenceQuery) GroupBy ¶
func (erq *ExternalReferenceQuery) GroupBy(field string, fields ...string) *ExternalReferenceGroupBy
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.ExternalReference.Query(). GroupBy(externalreference.FieldURL). Aggregate(ent.Count()). Scan(ctx, &v)
func (*ExternalReferenceQuery) IDs ¶
func (erq *ExternalReferenceQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of ExternalReference IDs.
func (*ExternalReferenceQuery) IDsX ¶
func (erq *ExternalReferenceQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*ExternalReferenceQuery) Limit ¶
func (erq *ExternalReferenceQuery) Limit(limit int) *ExternalReferenceQuery
Limit the number of records to be returned by this query.
func (*ExternalReferenceQuery) Offset ¶
func (erq *ExternalReferenceQuery) Offset(offset int) *ExternalReferenceQuery
Offset to start from.
func (*ExternalReferenceQuery) Only ¶
func (erq *ExternalReferenceQuery) Only(ctx context.Context) (*ExternalReference, error)
Only returns a single ExternalReference entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ExternalReference entity is found. Returns a *NotFoundError when no ExternalReference entities are found.
func (*ExternalReferenceQuery) OnlyID ¶
func (erq *ExternalReferenceQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only ExternalReference ID in the query. Returns a *NotSingularError when more than one ExternalReference ID is found. Returns a *NotFoundError when no entities are found.
func (*ExternalReferenceQuery) OnlyIDX ¶
func (erq *ExternalReferenceQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*ExternalReferenceQuery) OnlyX ¶
func (erq *ExternalReferenceQuery) OnlyX(ctx context.Context) *ExternalReference
OnlyX is like Only, but panics if an error occurs.
func (*ExternalReferenceQuery) Order ¶
func (erq *ExternalReferenceQuery) Order(o ...externalreference.OrderOption) *ExternalReferenceQuery
Order specifies how the records should be ordered.
func (*ExternalReferenceQuery) QueryHashes ¶
func (erq *ExternalReferenceQuery) QueryHashes() *HashesEntryQuery
QueryHashes chains the current query on the "hashes" edge.
func (*ExternalReferenceQuery) QueryNode ¶
func (erq *ExternalReferenceQuery) QueryNode() *NodeQuery
QueryNode chains the current query on the "node" edge.
func (*ExternalReferenceQuery) Select ¶
func (erq *ExternalReferenceQuery) Select(fields ...string) *ExternalReferenceSelect
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.ExternalReference.Query(). Select(externalreference.FieldURL). Scan(ctx, &v)
func (*ExternalReferenceQuery) Unique ¶
func (erq *ExternalReferenceQuery) Unique(unique bool) *ExternalReferenceQuery
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 (*ExternalReferenceQuery) Where ¶
func (erq *ExternalReferenceQuery) Where(ps ...predicate.ExternalReference) *ExternalReferenceQuery
Where adds a new predicate for the ExternalReferenceQuery builder.
func (*ExternalReferenceQuery) WithHashes ¶
func (erq *ExternalReferenceQuery) WithHashes(opts ...func(*HashesEntryQuery)) *ExternalReferenceQuery
WithHashes tells the query-builder to eager-load the nodes that are connected to the "hashes" edge. The optional arguments are used to configure the query builder of the edge.
func (*ExternalReferenceQuery) WithNode ¶
func (erq *ExternalReferenceQuery) WithNode(opts ...func(*NodeQuery)) *ExternalReferenceQuery
WithNode tells the query-builder to eager-load the nodes that are connected to the "node" edge. The optional arguments are used to configure the query builder of the edge.
type ExternalReferenceSelect ¶
type ExternalReferenceSelect struct { *ExternalReferenceQuery // contains filtered or unexported fields }
ExternalReferenceSelect is the builder for selecting fields of ExternalReference entities.
func (*ExternalReferenceSelect) Aggregate ¶
func (ers *ExternalReferenceSelect) Aggregate(fns ...AggregateFunc) *ExternalReferenceSelect
Aggregate adds the given aggregation functions to the selector query.
func (*ExternalReferenceSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceSelect) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*ExternalReferenceSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ExternalReferenceSelect) Scan ¶
func (ers *ExternalReferenceSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ExternalReferenceSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ExternalReferenceUpdate ¶
type ExternalReferenceUpdate struct {
// contains filtered or unexported fields
}
ExternalReferenceUpdate is the builder for updating ExternalReference entities.
func (*ExternalReferenceUpdate) AddHashIDs ¶
func (eru *ExternalReferenceUpdate) AddHashIDs(ids ...int) *ExternalReferenceUpdate
AddHashIDs adds the "hashes" edge to the HashesEntry entity by IDs.
func (*ExternalReferenceUpdate) AddHashes ¶
func (eru *ExternalReferenceUpdate) AddHashes(h ...*HashesEntry) *ExternalReferenceUpdate
AddHashes adds the "hashes" edges to the HashesEntry entity.
func (*ExternalReferenceUpdate) ClearAuthority ¶
func (eru *ExternalReferenceUpdate) ClearAuthority() *ExternalReferenceUpdate
ClearAuthority clears the value of the "authority" field.
func (*ExternalReferenceUpdate) ClearHashes ¶
func (eru *ExternalReferenceUpdate) ClearHashes() *ExternalReferenceUpdate
ClearHashes clears all "hashes" edges to the HashesEntry entity.
func (*ExternalReferenceUpdate) ClearNode ¶
func (eru *ExternalReferenceUpdate) ClearNode() *ExternalReferenceUpdate
ClearNode clears the "node" edge to the Node entity.
func (*ExternalReferenceUpdate) Exec ¶
func (eru *ExternalReferenceUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ExternalReferenceUpdate) ExecX ¶
func (eru *ExternalReferenceUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceUpdate) Mutation ¶
func (eru *ExternalReferenceUpdate) Mutation() *ExternalReferenceMutation
Mutation returns the ExternalReferenceMutation object of the builder.
func (*ExternalReferenceUpdate) RemoveHashIDs ¶
func (eru *ExternalReferenceUpdate) RemoveHashIDs(ids ...int) *ExternalReferenceUpdate
RemoveHashIDs removes the "hashes" edge to HashesEntry entities by IDs.
func (*ExternalReferenceUpdate) RemoveHashes ¶
func (eru *ExternalReferenceUpdate) RemoveHashes(h ...*HashesEntry) *ExternalReferenceUpdate
RemoveHashes removes "hashes" edges to HashesEntry entities.
func (*ExternalReferenceUpdate) Save ¶
func (eru *ExternalReferenceUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ExternalReferenceUpdate) SaveX ¶
func (eru *ExternalReferenceUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ExternalReferenceUpdate) SetAuthority ¶
func (eru *ExternalReferenceUpdate) SetAuthority(s string) *ExternalReferenceUpdate
SetAuthority sets the "authority" field.
func (*ExternalReferenceUpdate) SetComment ¶
func (eru *ExternalReferenceUpdate) SetComment(s string) *ExternalReferenceUpdate
SetComment sets the "comment" field.
func (*ExternalReferenceUpdate) SetNillableAuthority ¶
func (eru *ExternalReferenceUpdate) SetNillableAuthority(s *string) *ExternalReferenceUpdate
SetNillableAuthority sets the "authority" field if the given value is not nil.
func (*ExternalReferenceUpdate) SetNillableComment ¶
func (eru *ExternalReferenceUpdate) SetNillableComment(s *string) *ExternalReferenceUpdate
SetNillableComment sets the "comment" field if the given value is not nil.
func (*ExternalReferenceUpdate) SetNillableType ¶
func (eru *ExternalReferenceUpdate) SetNillableType(e *externalreference.Type) *ExternalReferenceUpdate
SetNillableType sets the "type" field if the given value is not nil.
func (*ExternalReferenceUpdate) SetNillableURL ¶
func (eru *ExternalReferenceUpdate) SetNillableURL(s *string) *ExternalReferenceUpdate
SetNillableURL sets the "url" field if the given value is not nil.
func (*ExternalReferenceUpdate) SetNode ¶
func (eru *ExternalReferenceUpdate) SetNode(n *Node) *ExternalReferenceUpdate
SetNode sets the "node" edge to the Node entity.
func (*ExternalReferenceUpdate) SetNodeID ¶
func (eru *ExternalReferenceUpdate) SetNodeID(id string) *ExternalReferenceUpdate
SetNodeID sets the "node" edge to the Node entity by ID.
func (*ExternalReferenceUpdate) SetType ¶
func (eru *ExternalReferenceUpdate) SetType(e externalreference.Type) *ExternalReferenceUpdate
SetType sets the "type" field.
func (*ExternalReferenceUpdate) SetURL ¶
func (eru *ExternalReferenceUpdate) SetURL(s string) *ExternalReferenceUpdate
SetURL sets the "url" field.
func (*ExternalReferenceUpdate) Where ¶
func (eru *ExternalReferenceUpdate) Where(ps ...predicate.ExternalReference) *ExternalReferenceUpdate
Where appends a list predicates to the ExternalReferenceUpdate builder.
type ExternalReferenceUpdateOne ¶
type ExternalReferenceUpdateOne struct {
// contains filtered or unexported fields
}
ExternalReferenceUpdateOne is the builder for updating a single ExternalReference entity.
func (*ExternalReferenceUpdateOne) AddHashIDs ¶
func (eruo *ExternalReferenceUpdateOne) AddHashIDs(ids ...int) *ExternalReferenceUpdateOne
AddHashIDs adds the "hashes" edge to the HashesEntry entity by IDs.
func (*ExternalReferenceUpdateOne) AddHashes ¶
func (eruo *ExternalReferenceUpdateOne) AddHashes(h ...*HashesEntry) *ExternalReferenceUpdateOne
AddHashes adds the "hashes" edges to the HashesEntry entity.
func (*ExternalReferenceUpdateOne) ClearAuthority ¶
func (eruo *ExternalReferenceUpdateOne) ClearAuthority() *ExternalReferenceUpdateOne
ClearAuthority clears the value of the "authority" field.
func (*ExternalReferenceUpdateOne) ClearHashes ¶
func (eruo *ExternalReferenceUpdateOne) ClearHashes() *ExternalReferenceUpdateOne
ClearHashes clears all "hashes" edges to the HashesEntry entity.
func (*ExternalReferenceUpdateOne) ClearNode ¶
func (eruo *ExternalReferenceUpdateOne) ClearNode() *ExternalReferenceUpdateOne
ClearNode clears the "node" edge to the Node entity.
func (*ExternalReferenceUpdateOne) Exec ¶
func (eruo *ExternalReferenceUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ExternalReferenceUpdateOne) ExecX ¶
func (eruo *ExternalReferenceUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceUpdateOne) Mutation ¶
func (eruo *ExternalReferenceUpdateOne) Mutation() *ExternalReferenceMutation
Mutation returns the ExternalReferenceMutation object of the builder.
func (*ExternalReferenceUpdateOne) RemoveHashIDs ¶
func (eruo *ExternalReferenceUpdateOne) RemoveHashIDs(ids ...int) *ExternalReferenceUpdateOne
RemoveHashIDs removes the "hashes" edge to HashesEntry entities by IDs.
func (*ExternalReferenceUpdateOne) RemoveHashes ¶
func (eruo *ExternalReferenceUpdateOne) RemoveHashes(h ...*HashesEntry) *ExternalReferenceUpdateOne
RemoveHashes removes "hashes" edges to HashesEntry entities.
func (*ExternalReferenceUpdateOne) Save ¶
func (eruo *ExternalReferenceUpdateOne) Save(ctx context.Context) (*ExternalReference, error)
Save executes the query and returns the updated ExternalReference entity.
func (*ExternalReferenceUpdateOne) SaveX ¶
func (eruo *ExternalReferenceUpdateOne) SaveX(ctx context.Context) *ExternalReference
SaveX is like Save, but panics if an error occurs.
func (*ExternalReferenceUpdateOne) Select ¶
func (eruo *ExternalReferenceUpdateOne) Select(field string, fields ...string) *ExternalReferenceUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ExternalReferenceUpdateOne) SetAuthority ¶
func (eruo *ExternalReferenceUpdateOne) SetAuthority(s string) *ExternalReferenceUpdateOne
SetAuthority sets the "authority" field.
func (*ExternalReferenceUpdateOne) SetComment ¶
func (eruo *ExternalReferenceUpdateOne) SetComment(s string) *ExternalReferenceUpdateOne
SetComment sets the "comment" field.
func (*ExternalReferenceUpdateOne) SetNillableAuthority ¶
func (eruo *ExternalReferenceUpdateOne) SetNillableAuthority(s *string) *ExternalReferenceUpdateOne
SetNillableAuthority sets the "authority" field if the given value is not nil.
func (*ExternalReferenceUpdateOne) SetNillableComment ¶
func (eruo *ExternalReferenceUpdateOne) SetNillableComment(s *string) *ExternalReferenceUpdateOne
SetNillableComment sets the "comment" field if the given value is not nil.
func (*ExternalReferenceUpdateOne) SetNillableType ¶
func (eruo *ExternalReferenceUpdateOne) SetNillableType(e *externalreference.Type) *ExternalReferenceUpdateOne
SetNillableType sets the "type" field if the given value is not nil.
func (*ExternalReferenceUpdateOne) SetNillableURL ¶
func (eruo *ExternalReferenceUpdateOne) SetNillableURL(s *string) *ExternalReferenceUpdateOne
SetNillableURL sets the "url" field if the given value is not nil.
func (*ExternalReferenceUpdateOne) SetNode ¶
func (eruo *ExternalReferenceUpdateOne) SetNode(n *Node) *ExternalReferenceUpdateOne
SetNode sets the "node" edge to the Node entity.
func (*ExternalReferenceUpdateOne) SetNodeID ¶
func (eruo *ExternalReferenceUpdateOne) SetNodeID(id string) *ExternalReferenceUpdateOne
SetNodeID sets the "node" edge to the Node entity by ID.
func (*ExternalReferenceUpdateOne) SetType ¶
func (eruo *ExternalReferenceUpdateOne) SetType(e externalreference.Type) *ExternalReferenceUpdateOne
SetType sets the "type" field.
func (*ExternalReferenceUpdateOne) SetURL ¶
func (eruo *ExternalReferenceUpdateOne) SetURL(s string) *ExternalReferenceUpdateOne
SetURL sets the "url" field.
func (*ExternalReferenceUpdateOne) Where ¶
func (eruo *ExternalReferenceUpdateOne) Where(ps ...predicate.ExternalReference) *ExternalReferenceUpdateOne
Where appends a list predicates to the ExternalReferenceUpdate builder.
type ExternalReferenceUpsert ¶
ExternalReferenceUpsert is the "OnConflict" setter.
func (*ExternalReferenceUpsert) ClearAuthority ¶
func (u *ExternalReferenceUpsert) ClearAuthority() *ExternalReferenceUpsert
ClearAuthority clears the value of the "authority" field.
func (*ExternalReferenceUpsert) SetAuthority ¶
func (u *ExternalReferenceUpsert) SetAuthority(v string) *ExternalReferenceUpsert
SetAuthority sets the "authority" field.
func (*ExternalReferenceUpsert) SetComment ¶
func (u *ExternalReferenceUpsert) SetComment(v string) *ExternalReferenceUpsert
SetComment sets the "comment" field.
func (*ExternalReferenceUpsert) SetType ¶
func (u *ExternalReferenceUpsert) SetType(v externalreference.Type) *ExternalReferenceUpsert
SetType sets the "type" field.
func (*ExternalReferenceUpsert) SetURL ¶
func (u *ExternalReferenceUpsert) SetURL(v string) *ExternalReferenceUpsert
SetURL sets the "url" field.
func (*ExternalReferenceUpsert) UpdateAuthority ¶
func (u *ExternalReferenceUpsert) UpdateAuthority() *ExternalReferenceUpsert
UpdateAuthority sets the "authority" field to the value that was provided on create.
func (*ExternalReferenceUpsert) UpdateComment ¶
func (u *ExternalReferenceUpsert) UpdateComment() *ExternalReferenceUpsert
UpdateComment sets the "comment" field to the value that was provided on create.
func (*ExternalReferenceUpsert) UpdateType ¶
func (u *ExternalReferenceUpsert) UpdateType() *ExternalReferenceUpsert
UpdateType sets the "type" field to the value that was provided on create.
func (*ExternalReferenceUpsert) UpdateURL ¶
func (u *ExternalReferenceUpsert) UpdateURL() *ExternalReferenceUpsert
UpdateURL sets the "url" field to the value that was provided on create.
type ExternalReferenceUpsertBulk ¶
type ExternalReferenceUpsertBulk struct {
// contains filtered or unexported fields
}
ExternalReferenceUpsertBulk is the builder for "upsert"-ing a bulk of ExternalReference nodes.
func (*ExternalReferenceUpsertBulk) ClearAuthority ¶
func (u *ExternalReferenceUpsertBulk) ClearAuthority() *ExternalReferenceUpsertBulk
ClearAuthority clears the value of the "authority" field.
func (*ExternalReferenceUpsertBulk) DoNothing ¶
func (u *ExternalReferenceUpsertBulk) DoNothing() *ExternalReferenceUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ExternalReferenceUpsertBulk) Exec ¶
func (u *ExternalReferenceUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ExternalReferenceUpsertBulk) ExecX ¶
func (u *ExternalReferenceUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceUpsertBulk) Ignore ¶
func (u *ExternalReferenceUpsertBulk) Ignore() *ExternalReferenceUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.ExternalReference.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ExternalReferenceUpsertBulk) SetAuthority ¶
func (u *ExternalReferenceUpsertBulk) SetAuthority(v string) *ExternalReferenceUpsertBulk
SetAuthority sets the "authority" field.
func (*ExternalReferenceUpsertBulk) SetComment ¶
func (u *ExternalReferenceUpsertBulk) SetComment(v string) *ExternalReferenceUpsertBulk
SetComment sets the "comment" field.
func (*ExternalReferenceUpsertBulk) SetType ¶
func (u *ExternalReferenceUpsertBulk) SetType(v externalreference.Type) *ExternalReferenceUpsertBulk
SetType sets the "type" field.
func (*ExternalReferenceUpsertBulk) SetURL ¶
func (u *ExternalReferenceUpsertBulk) SetURL(v string) *ExternalReferenceUpsertBulk
SetURL sets the "url" field.
func (*ExternalReferenceUpsertBulk) Update ¶
func (u *ExternalReferenceUpsertBulk) Update(set func(*ExternalReferenceUpsert)) *ExternalReferenceUpsertBulk
Update allows overriding fields `UPDATE` values. See the ExternalReferenceCreateBulk.OnConflict documentation for more info.
func (*ExternalReferenceUpsertBulk) UpdateAuthority ¶
func (u *ExternalReferenceUpsertBulk) UpdateAuthority() *ExternalReferenceUpsertBulk
UpdateAuthority sets the "authority" field to the value that was provided on create.
func (*ExternalReferenceUpsertBulk) UpdateComment ¶
func (u *ExternalReferenceUpsertBulk) UpdateComment() *ExternalReferenceUpsertBulk
UpdateComment sets the "comment" field to the value that was provided on create.
func (*ExternalReferenceUpsertBulk) UpdateNewValues ¶
func (u *ExternalReferenceUpsertBulk) UpdateNewValues() *ExternalReferenceUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.ExternalReference.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*ExternalReferenceUpsertBulk) UpdateType ¶
func (u *ExternalReferenceUpsertBulk) UpdateType() *ExternalReferenceUpsertBulk
UpdateType sets the "type" field to the value that was provided on create.
func (*ExternalReferenceUpsertBulk) UpdateURL ¶
func (u *ExternalReferenceUpsertBulk) UpdateURL() *ExternalReferenceUpsertBulk
UpdateURL sets the "url" field to the value that was provided on create.
type ExternalReferenceUpsertOne ¶
type ExternalReferenceUpsertOne struct {
// contains filtered or unexported fields
}
ExternalReferenceUpsertOne is the builder for "upsert"-ing
one ExternalReference node.
func (*ExternalReferenceUpsertOne) ClearAuthority ¶
func (u *ExternalReferenceUpsertOne) ClearAuthority() *ExternalReferenceUpsertOne
ClearAuthority clears the value of the "authority" field.
func (*ExternalReferenceUpsertOne) DoNothing ¶
func (u *ExternalReferenceUpsertOne) DoNothing() *ExternalReferenceUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ExternalReferenceUpsertOne) Exec ¶
func (u *ExternalReferenceUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*ExternalReferenceUpsertOne) ExecX ¶
func (u *ExternalReferenceUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ExternalReferenceUpsertOne) ID ¶
func (u *ExternalReferenceUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*ExternalReferenceUpsertOne) IDX ¶
func (u *ExternalReferenceUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*ExternalReferenceUpsertOne) Ignore ¶
func (u *ExternalReferenceUpsertOne) Ignore() *ExternalReferenceUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.ExternalReference.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ExternalReferenceUpsertOne) SetAuthority ¶
func (u *ExternalReferenceUpsertOne) SetAuthority(v string) *ExternalReferenceUpsertOne
SetAuthority sets the "authority" field.
func (*ExternalReferenceUpsertOne) SetComment ¶
func (u *ExternalReferenceUpsertOne) SetComment(v string) *ExternalReferenceUpsertOne
SetComment sets the "comment" field.
func (*ExternalReferenceUpsertOne) SetType ¶
func (u *ExternalReferenceUpsertOne) SetType(v externalreference.Type) *ExternalReferenceUpsertOne
SetType sets the "type" field.
func (*ExternalReferenceUpsertOne) SetURL ¶
func (u *ExternalReferenceUpsertOne) SetURL(v string) *ExternalReferenceUpsertOne
SetURL sets the "url" field.
func (*ExternalReferenceUpsertOne) Update ¶
func (u *ExternalReferenceUpsertOne) Update(set func(*ExternalReferenceUpsert)) *ExternalReferenceUpsertOne
Update allows overriding fields `UPDATE` values. See the ExternalReferenceCreate.OnConflict documentation for more info.
func (*ExternalReferenceUpsertOne) UpdateAuthority ¶
func (u *ExternalReferenceUpsertOne) UpdateAuthority() *ExternalReferenceUpsertOne
UpdateAuthority sets the "authority" field to the value that was provided on create.
func (*ExternalReferenceUpsertOne) UpdateComment ¶
func (u *ExternalReferenceUpsertOne) UpdateComment() *ExternalReferenceUpsertOne
UpdateComment sets the "comment" field to the value that was provided on create.
func (*ExternalReferenceUpsertOne) UpdateNewValues ¶
func (u *ExternalReferenceUpsertOne) UpdateNewValues() *ExternalReferenceUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.ExternalReference.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*ExternalReferenceUpsertOne) UpdateType ¶
func (u *ExternalReferenceUpsertOne) UpdateType() *ExternalReferenceUpsertOne
UpdateType sets the "type" field to the value that was provided on create.
func (*ExternalReferenceUpsertOne) UpdateURL ¶
func (u *ExternalReferenceUpsertOne) UpdateURL() *ExternalReferenceUpsertOne
UpdateURL sets the "url" field to the value that was provided on create.
type ExternalReferences ¶
type ExternalReferences []*ExternalReference
ExternalReferences is a parsable slice of ExternalReference.
type HashesEntries ¶
type HashesEntries []*HashesEntry
HashesEntries is a parsable slice of HashesEntry.
type HashesEntry ¶
type HashesEntry struct { // ID of the ent. ID int `json:"id,omitempty"` // HashAlgorithmType holds the value of the "hash_algorithm_type" field. HashAlgorithmType hashesentry.HashAlgorithmType `json:"hash_algorithm_type,omitempty"` // HashData holds the value of the "hash_data" field. HashData string `json:"hash_data,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the HashesEntryQuery when eager-loading is set. Edges HashesEntryEdges `json:"edges"` // contains filtered or unexported fields }
HashesEntry is the model entity for the HashesEntry schema.
func (*HashesEntry) QueryExternalReferences ¶
func (he *HashesEntry) QueryExternalReferences() *ExternalReferenceQuery
QueryExternalReferences queries the "external_references" edge of the HashesEntry entity.
func (*HashesEntry) QueryNodes ¶
func (he *HashesEntry) QueryNodes() *NodeQuery
QueryNodes queries the "nodes" edge of the HashesEntry entity.
func (*HashesEntry) String ¶
func (he *HashesEntry) String() string
String implements the fmt.Stringer.
func (*HashesEntry) Unwrap ¶
func (he *HashesEntry) Unwrap() *HashesEntry
Unwrap unwraps the HashesEntry 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 (*HashesEntry) Update ¶
func (he *HashesEntry) Update() *HashesEntryUpdateOne
Update returns a builder for updating this HashesEntry. Note that you need to call HashesEntry.Unwrap() before calling this method if this HashesEntry was returned from a transaction, and the transaction was committed or rolled back.
type HashesEntryClient ¶
type HashesEntryClient struct {
// contains filtered or unexported fields
}
HashesEntryClient is a client for the HashesEntry schema.
func NewHashesEntryClient ¶
func NewHashesEntryClient(c config) *HashesEntryClient
NewHashesEntryClient returns a client for the HashesEntry from the given config.
func (*HashesEntryClient) Create ¶
func (c *HashesEntryClient) Create() *HashesEntryCreate
Create returns a builder for creating a HashesEntry entity.
func (*HashesEntryClient) CreateBulk ¶
func (c *HashesEntryClient) CreateBulk(builders ...*HashesEntryCreate) *HashesEntryCreateBulk
CreateBulk returns a builder for creating a bulk of HashesEntry entities.
func (*HashesEntryClient) Delete ¶
func (c *HashesEntryClient) Delete() *HashesEntryDelete
Delete returns a delete builder for HashesEntry.
func (*HashesEntryClient) DeleteOne ¶
func (c *HashesEntryClient) DeleteOne(he *HashesEntry) *HashesEntryDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*HashesEntryClient) DeleteOneID ¶
func (c *HashesEntryClient) DeleteOneID(id int) *HashesEntryDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*HashesEntryClient) Get ¶
func (c *HashesEntryClient) Get(ctx context.Context, id int) (*HashesEntry, error)
Get returns a HashesEntry entity by its id.
func (*HashesEntryClient) GetX ¶
func (c *HashesEntryClient) GetX(ctx context.Context, id int) *HashesEntry
GetX is like Get, but panics if an error occurs.
func (*HashesEntryClient) Hooks ¶
func (c *HashesEntryClient) Hooks() []Hook
Hooks returns the client hooks.
func (*HashesEntryClient) Intercept ¶
func (c *HashesEntryClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `hashesentry.Intercept(f(g(h())))`.
func (*HashesEntryClient) Interceptors ¶
func (c *HashesEntryClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*HashesEntryClient) MapCreateBulk ¶
func (c *HashesEntryClient) MapCreateBulk(slice any, setFunc func(*HashesEntryCreate, int)) *HashesEntryCreateBulk
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 (*HashesEntryClient) Query ¶
func (c *HashesEntryClient) Query() *HashesEntryQuery
Query returns a query builder for HashesEntry.
func (*HashesEntryClient) QueryExternalReferences ¶
func (c *HashesEntryClient) QueryExternalReferences(he *HashesEntry) *ExternalReferenceQuery
QueryExternalReferences queries the external_references edge of a HashesEntry.
func (*HashesEntryClient) QueryNodes ¶
func (c *HashesEntryClient) QueryNodes(he *HashesEntry) *NodeQuery
QueryNodes queries the nodes edge of a HashesEntry.
func (*HashesEntryClient) Update ¶
func (c *HashesEntryClient) Update() *HashesEntryUpdate
Update returns an update builder for HashesEntry.
func (*HashesEntryClient) UpdateOne ¶
func (c *HashesEntryClient) UpdateOne(he *HashesEntry) *HashesEntryUpdateOne
UpdateOne returns an update builder for the given entity.
func (*HashesEntryClient) UpdateOneID ¶
func (c *HashesEntryClient) UpdateOneID(id int) *HashesEntryUpdateOne
UpdateOneID returns an update builder for the given id.
func (*HashesEntryClient) Use ¶
func (c *HashesEntryClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `hashesentry.Hooks(f(g(h())))`.
type HashesEntryCreate ¶
type HashesEntryCreate struct {
// contains filtered or unexported fields
}
HashesEntryCreate is the builder for creating a HashesEntry entity.
func (*HashesEntryCreate) Exec ¶
func (hec *HashesEntryCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*HashesEntryCreate) ExecX ¶
func (hec *HashesEntryCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryCreate) Mutation ¶
func (hec *HashesEntryCreate) Mutation() *HashesEntryMutation
Mutation returns the HashesEntryMutation object of the builder.
func (*HashesEntryCreate) OnConflict ¶
func (hec *HashesEntryCreate) OnConflict(opts ...sql.ConflictOption) *HashesEntryUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.HashesEntry.Create(). SetHashAlgorithmType(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.HashesEntryUpsert) { SetHashAlgorithmType(v+v). }). Exec(ctx)
func (*HashesEntryCreate) OnConflictColumns ¶
func (hec *HashesEntryCreate) OnConflictColumns(columns ...string) *HashesEntryUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.HashesEntry.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*HashesEntryCreate) Save ¶
func (hec *HashesEntryCreate) Save(ctx context.Context) (*HashesEntry, error)
Save creates the HashesEntry in the database.
func (*HashesEntryCreate) SaveX ¶
func (hec *HashesEntryCreate) SaveX(ctx context.Context) *HashesEntry
SaveX calls Save and panics if Save returns an error.
func (*HashesEntryCreate) SetExternalReferences ¶
func (hec *HashesEntryCreate) SetExternalReferences(e *ExternalReference) *HashesEntryCreate
SetExternalReferences sets the "external_references" edge to the ExternalReference entity.
func (*HashesEntryCreate) SetExternalReferencesID ¶
func (hec *HashesEntryCreate) SetExternalReferencesID(id int) *HashesEntryCreate
SetExternalReferencesID sets the "external_references" edge to the ExternalReference entity by ID.
func (*HashesEntryCreate) SetHashAlgorithmType ¶
func (hec *HashesEntryCreate) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType) *HashesEntryCreate
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryCreate) SetHashData ¶
func (hec *HashesEntryCreate) SetHashData(s string) *HashesEntryCreate
SetHashData sets the "hash_data" field.
func (*HashesEntryCreate) SetNillableExternalReferencesID ¶
func (hec *HashesEntryCreate) SetNillableExternalReferencesID(id *int) *HashesEntryCreate
SetNillableExternalReferencesID sets the "external_references" edge to the ExternalReference entity by ID if the given value is not nil.
func (*HashesEntryCreate) SetNillableNodesID ¶
func (hec *HashesEntryCreate) SetNillableNodesID(id *string) *HashesEntryCreate
SetNillableNodesID sets the "nodes" edge to the Node entity by ID if the given value is not nil.
func (*HashesEntryCreate) SetNodes ¶
func (hec *HashesEntryCreate) SetNodes(n *Node) *HashesEntryCreate
SetNodes sets the "nodes" edge to the Node entity.
func (*HashesEntryCreate) SetNodesID ¶
func (hec *HashesEntryCreate) SetNodesID(id string) *HashesEntryCreate
SetNodesID sets the "nodes" edge to the Node entity by ID.
type HashesEntryCreateBulk ¶
type HashesEntryCreateBulk struct {
// contains filtered or unexported fields
}
HashesEntryCreateBulk is the builder for creating many HashesEntry entities in bulk.
func (*HashesEntryCreateBulk) Exec ¶
func (hecb *HashesEntryCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*HashesEntryCreateBulk) ExecX ¶
func (hecb *HashesEntryCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryCreateBulk) OnConflict ¶
func (hecb *HashesEntryCreateBulk) OnConflict(opts ...sql.ConflictOption) *HashesEntryUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.HashesEntry.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.HashesEntryUpsert) { SetHashAlgorithmType(v+v). }). Exec(ctx)
func (*HashesEntryCreateBulk) OnConflictColumns ¶
func (hecb *HashesEntryCreateBulk) OnConflictColumns(columns ...string) *HashesEntryUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.HashesEntry.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*HashesEntryCreateBulk) Save ¶
func (hecb *HashesEntryCreateBulk) Save(ctx context.Context) ([]*HashesEntry, error)
Save creates the HashesEntry entities in the database.
func (*HashesEntryCreateBulk) SaveX ¶
func (hecb *HashesEntryCreateBulk) SaveX(ctx context.Context) []*HashesEntry
SaveX is like Save, but panics if an error occurs.
type HashesEntryDelete ¶
type HashesEntryDelete struct {
// contains filtered or unexported fields
}
HashesEntryDelete is the builder for deleting a HashesEntry entity.
func (*HashesEntryDelete) Exec ¶
func (hed *HashesEntryDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*HashesEntryDelete) ExecX ¶
func (hed *HashesEntryDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryDelete) Where ¶
func (hed *HashesEntryDelete) Where(ps ...predicate.HashesEntry) *HashesEntryDelete
Where appends a list predicates to the HashesEntryDelete builder.
type HashesEntryDeleteOne ¶
type HashesEntryDeleteOne struct {
// contains filtered or unexported fields
}
HashesEntryDeleteOne is the builder for deleting a single HashesEntry entity.
func (*HashesEntryDeleteOne) Exec ¶
func (hedo *HashesEntryDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*HashesEntryDeleteOne) ExecX ¶
func (hedo *HashesEntryDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryDeleteOne) Where ¶
func (hedo *HashesEntryDeleteOne) Where(ps ...predicate.HashesEntry) *HashesEntryDeleteOne
Where appends a list predicates to the HashesEntryDelete builder.
type HashesEntryEdges ¶
type HashesEntryEdges struct { // ExternalReferences holds the value of the external_references edge. ExternalReferences *ExternalReference `json:"external_references,omitempty"` // Nodes holds the value of the nodes edge. Nodes *Node `json:"nodes,omitempty"` // contains filtered or unexported fields }
HashesEntryEdges holds the relations/edges for other nodes in the graph.
func (HashesEntryEdges) ExternalReferencesOrErr ¶
func (e HashesEntryEdges) ExternalReferencesOrErr() (*ExternalReference, error)
ExternalReferencesOrErr returns the ExternalReferences value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (HashesEntryEdges) NodesOrErr ¶
func (e HashesEntryEdges) NodesOrErr() (*Node, error)
NodesOrErr returns the Nodes value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type HashesEntryGroupBy ¶
type HashesEntryGroupBy struct {
// contains filtered or unexported fields
}
HashesEntryGroupBy is the group-by builder for HashesEntry entities.
func (*HashesEntryGroupBy) Aggregate ¶
func (hegb *HashesEntryGroupBy) Aggregate(fns ...AggregateFunc) *HashesEntryGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*HashesEntryGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*HashesEntryGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*HashesEntryGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*HashesEntryGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*HashesEntryGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*HashesEntryGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*HashesEntryGroupBy) Scan ¶
func (hegb *HashesEntryGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*HashesEntryGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type HashesEntryMutation ¶
type HashesEntryMutation struct {
// contains filtered or unexported fields
}
HashesEntryMutation represents an operation that mutates the HashesEntry nodes in the graph.
func (*HashesEntryMutation) AddField ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) AddedEdges ¶
func (m *HashesEntryMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*HashesEntryMutation) AddedField ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) AddedFields ¶
func (m *HashesEntryMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*HashesEntryMutation) AddedIDs ¶
func (m *HashesEntryMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*HashesEntryMutation) ClearEdge ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) ClearExternalReferences ¶
func (m *HashesEntryMutation) ClearExternalReferences()
ClearExternalReferences clears the "external_references" edge to the ExternalReference entity.
func (*HashesEntryMutation) ClearField ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) ClearNodes ¶
func (m *HashesEntryMutation) ClearNodes()
ClearNodes clears the "nodes" edge to the Node entity.
func (*HashesEntryMutation) ClearedEdges ¶
func (m *HashesEntryMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*HashesEntryMutation) ClearedFields ¶
func (m *HashesEntryMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (HashesEntryMutation) Client ¶
func (m HashesEntryMutation) 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 (*HashesEntryMutation) EdgeCleared ¶
func (m *HashesEntryMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*HashesEntryMutation) ExternalReferencesCleared ¶
func (m *HashesEntryMutation) ExternalReferencesCleared() bool
ExternalReferencesCleared reports if the "external_references" edge to the ExternalReference entity was cleared.
func (*HashesEntryMutation) ExternalReferencesID ¶
func (m *HashesEntryMutation) ExternalReferencesID() (id int, exists bool)
ExternalReferencesID returns the "external_references" edge ID in the mutation.
func (*HashesEntryMutation) ExternalReferencesIDs ¶
func (m *HashesEntryMutation) ExternalReferencesIDs() (ids []int)
ExternalReferencesIDs returns the "external_references" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ExternalReferencesID instead. It exists only for internal usage by the builders.
func (*HashesEntryMutation) Field ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) FieldCleared ¶
func (m *HashesEntryMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*HashesEntryMutation) Fields ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) HashAlgorithmType ¶
func (m *HashesEntryMutation) HashAlgorithmType() (r hashesentry.HashAlgorithmType, exists bool)
HashAlgorithmType returns the value of the "hash_algorithm_type" field in the mutation.
func (*HashesEntryMutation) HashData ¶
func (m *HashesEntryMutation) HashData() (r string, exists bool)
HashData returns the value of the "hash_data" field in the mutation.
func (*HashesEntryMutation) ID ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) IDs ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) NodesCleared ¶
func (m *HashesEntryMutation) NodesCleared() bool
NodesCleared reports if the "nodes" edge to the Node entity was cleared.
func (*HashesEntryMutation) NodesID ¶
func (m *HashesEntryMutation) NodesID() (id string, exists bool)
NodesID returns the "nodes" edge ID in the mutation.
func (*HashesEntryMutation) NodesIDs ¶
func (m *HashesEntryMutation) NodesIDs() (ids []string)
NodesIDs returns the "nodes" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use NodesID instead. It exists only for internal usage by the builders.
func (*HashesEntryMutation) 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 (*HashesEntryMutation) OldHashAlgorithmType ¶
func (m *HashesEntryMutation) OldHashAlgorithmType(ctx context.Context) (v hashesentry.HashAlgorithmType, err error)
OldHashAlgorithmType returns the old "hash_algorithm_type" field's value of the HashesEntry entity. If the HashesEntry 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 (*HashesEntryMutation) OldHashData ¶
func (m *HashesEntryMutation) OldHashData(ctx context.Context) (v string, err error)
OldHashData returns the old "hash_data" field's value of the HashesEntry entity. If the HashesEntry 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 (*HashesEntryMutation) Op ¶
func (m *HashesEntryMutation) Op() Op
Op returns the operation name.
func (*HashesEntryMutation) RemovedEdges ¶
func (m *HashesEntryMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*HashesEntryMutation) RemovedIDs ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) ResetEdge ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) ResetExternalReferences ¶
func (m *HashesEntryMutation) ResetExternalReferences()
ResetExternalReferences resets all changes to the "external_references" edge.
func (*HashesEntryMutation) ResetField ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) ResetHashAlgorithmType ¶
func (m *HashesEntryMutation) ResetHashAlgorithmType()
ResetHashAlgorithmType resets all changes to the "hash_algorithm_type" field.
func (*HashesEntryMutation) ResetHashData ¶
func (m *HashesEntryMutation) ResetHashData()
ResetHashData resets all changes to the "hash_data" field.
func (*HashesEntryMutation) ResetNodes ¶
func (m *HashesEntryMutation) ResetNodes()
ResetNodes resets all changes to the "nodes" edge.
func (*HashesEntryMutation) SetExternalReferencesID ¶
func (m *HashesEntryMutation) SetExternalReferencesID(id int)
SetExternalReferencesID sets the "external_references" edge to the ExternalReference entity by id.
func (*HashesEntryMutation) SetField ¶
func (m *HashesEntryMutation) 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 (*HashesEntryMutation) SetHashAlgorithmType ¶
func (m *HashesEntryMutation) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType)
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryMutation) SetHashData ¶
func (m *HashesEntryMutation) SetHashData(s string)
SetHashData sets the "hash_data" field.
func (*HashesEntryMutation) SetNodesID ¶
func (m *HashesEntryMutation) SetNodesID(id string)
SetNodesID sets the "nodes" edge to the Node entity by id.
func (*HashesEntryMutation) SetOp ¶
func (m *HashesEntryMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (HashesEntryMutation) Tx ¶
func (m HashesEntryMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*HashesEntryMutation) Type ¶
func (m *HashesEntryMutation) Type() string
Type returns the node type of this mutation (HashesEntry).
func (*HashesEntryMutation) Where ¶
func (m *HashesEntryMutation) Where(ps ...predicate.HashesEntry)
Where appends a list predicates to the HashesEntryMutation builder.
func (*HashesEntryMutation) WhereP ¶
func (m *HashesEntryMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the HashesEntryMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type HashesEntryQuery ¶
type HashesEntryQuery struct {
// contains filtered or unexported fields
}
HashesEntryQuery is the builder for querying HashesEntry entities.
func (*HashesEntryQuery) Aggregate ¶
func (heq *HashesEntryQuery) Aggregate(fns ...AggregateFunc) *HashesEntrySelect
Aggregate returns a HashesEntrySelect configured with the given aggregations.
func (*HashesEntryQuery) All ¶
func (heq *HashesEntryQuery) All(ctx context.Context) ([]*HashesEntry, error)
All executes the query and returns a list of HashesEntries.
func (*HashesEntryQuery) AllX ¶
func (heq *HashesEntryQuery) AllX(ctx context.Context) []*HashesEntry
AllX is like All, but panics if an error occurs.
func (*HashesEntryQuery) Clone ¶
func (heq *HashesEntryQuery) Clone() *HashesEntryQuery
Clone returns a duplicate of the HashesEntryQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*HashesEntryQuery) Count ¶
func (heq *HashesEntryQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*HashesEntryQuery) CountX ¶
func (heq *HashesEntryQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*HashesEntryQuery) Exist ¶
func (heq *HashesEntryQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*HashesEntryQuery) ExistX ¶
func (heq *HashesEntryQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*HashesEntryQuery) First ¶
func (heq *HashesEntryQuery) First(ctx context.Context) (*HashesEntry, error)
First returns the first HashesEntry entity from the query. Returns a *NotFoundError when no HashesEntry was found.
func (*HashesEntryQuery) FirstID ¶
func (heq *HashesEntryQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first HashesEntry ID from the query. Returns a *NotFoundError when no HashesEntry ID was found.
func (*HashesEntryQuery) FirstIDX ¶
func (heq *HashesEntryQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*HashesEntryQuery) FirstX ¶
func (heq *HashesEntryQuery) FirstX(ctx context.Context) *HashesEntry
FirstX is like First, but panics if an error occurs.
func (*HashesEntryQuery) GroupBy ¶
func (heq *HashesEntryQuery) GroupBy(field string, fields ...string) *HashesEntryGroupBy
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 { HashAlgorithmType hashesentry.HashAlgorithmType `json:"hash_algorithm_type,omitempty"` Count int `json:"count,omitempty"` } client.HashesEntry.Query(). GroupBy(hashesentry.FieldHashAlgorithmType). Aggregate(ent.Count()). Scan(ctx, &v)
func (*HashesEntryQuery) IDs ¶
func (heq *HashesEntryQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of HashesEntry IDs.
func (*HashesEntryQuery) IDsX ¶
func (heq *HashesEntryQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*HashesEntryQuery) Limit ¶
func (heq *HashesEntryQuery) Limit(limit int) *HashesEntryQuery
Limit the number of records to be returned by this query.
func (*HashesEntryQuery) Offset ¶
func (heq *HashesEntryQuery) Offset(offset int) *HashesEntryQuery
Offset to start from.
func (*HashesEntryQuery) Only ¶
func (heq *HashesEntryQuery) Only(ctx context.Context) (*HashesEntry, error)
Only returns a single HashesEntry entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one HashesEntry entity is found. Returns a *NotFoundError when no HashesEntry entities are found.
func (*HashesEntryQuery) OnlyID ¶
func (heq *HashesEntryQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only HashesEntry ID in the query. Returns a *NotSingularError when more than one HashesEntry ID is found. Returns a *NotFoundError when no entities are found.
func (*HashesEntryQuery) OnlyIDX ¶
func (heq *HashesEntryQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*HashesEntryQuery) OnlyX ¶
func (heq *HashesEntryQuery) OnlyX(ctx context.Context) *HashesEntry
OnlyX is like Only, but panics if an error occurs.
func (*HashesEntryQuery) Order ¶
func (heq *HashesEntryQuery) Order(o ...hashesentry.OrderOption) *HashesEntryQuery
Order specifies how the records should be ordered.
func (*HashesEntryQuery) QueryExternalReferences ¶
func (heq *HashesEntryQuery) QueryExternalReferences() *ExternalReferenceQuery
QueryExternalReferences chains the current query on the "external_references" edge.
func (*HashesEntryQuery) QueryNodes ¶
func (heq *HashesEntryQuery) QueryNodes() *NodeQuery
QueryNodes chains the current query on the "nodes" edge.
func (*HashesEntryQuery) Select ¶
func (heq *HashesEntryQuery) Select(fields ...string) *HashesEntrySelect
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 { HashAlgorithmType hashesentry.HashAlgorithmType `json:"hash_algorithm_type,omitempty"` } client.HashesEntry.Query(). Select(hashesentry.FieldHashAlgorithmType). Scan(ctx, &v)
func (*HashesEntryQuery) Unique ¶
func (heq *HashesEntryQuery) Unique(unique bool) *HashesEntryQuery
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 (*HashesEntryQuery) Where ¶
func (heq *HashesEntryQuery) Where(ps ...predicate.HashesEntry) *HashesEntryQuery
Where adds a new predicate for the HashesEntryQuery builder.
func (*HashesEntryQuery) WithExternalReferences ¶
func (heq *HashesEntryQuery) WithExternalReferences(opts ...func(*ExternalReferenceQuery)) *HashesEntryQuery
WithExternalReferences tells the query-builder to eager-load the nodes that are connected to the "external_references" edge. The optional arguments are used to configure the query builder of the edge.
func (*HashesEntryQuery) WithNodes ¶
func (heq *HashesEntryQuery) WithNodes(opts ...func(*NodeQuery)) *HashesEntryQuery
WithNodes tells the query-builder to eager-load the nodes that are connected to the "nodes" edge. The optional arguments are used to configure the query builder of the edge.
type HashesEntrySelect ¶
type HashesEntrySelect struct { *HashesEntryQuery // contains filtered or unexported fields }
HashesEntrySelect is the builder for selecting fields of HashesEntry entities.
func (*HashesEntrySelect) Aggregate ¶
func (hes *HashesEntrySelect) Aggregate(fns ...AggregateFunc) *HashesEntrySelect
Aggregate adds the given aggregation functions to the selector query.
func (*HashesEntrySelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*HashesEntrySelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*HashesEntrySelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*HashesEntrySelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*HashesEntrySelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*HashesEntrySelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*HashesEntrySelect) Scan ¶
func (hes *HashesEntrySelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*HashesEntrySelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type HashesEntryUpdate ¶
type HashesEntryUpdate struct {
// contains filtered or unexported fields
}
HashesEntryUpdate is the builder for updating HashesEntry entities.
func (*HashesEntryUpdate) ClearExternalReferences ¶
func (heu *HashesEntryUpdate) ClearExternalReferences() *HashesEntryUpdate
ClearExternalReferences clears the "external_references" edge to the ExternalReference entity.
func (*HashesEntryUpdate) ClearNodes ¶
func (heu *HashesEntryUpdate) ClearNodes() *HashesEntryUpdate
ClearNodes clears the "nodes" edge to the Node entity.
func (*HashesEntryUpdate) Exec ¶
func (heu *HashesEntryUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*HashesEntryUpdate) ExecX ¶
func (heu *HashesEntryUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryUpdate) Mutation ¶
func (heu *HashesEntryUpdate) Mutation() *HashesEntryMutation
Mutation returns the HashesEntryMutation object of the builder.
func (*HashesEntryUpdate) Save ¶
func (heu *HashesEntryUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*HashesEntryUpdate) SaveX ¶
func (heu *HashesEntryUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*HashesEntryUpdate) SetExternalReferences ¶
func (heu *HashesEntryUpdate) SetExternalReferences(e *ExternalReference) *HashesEntryUpdate
SetExternalReferences sets the "external_references" edge to the ExternalReference entity.
func (*HashesEntryUpdate) SetExternalReferencesID ¶
func (heu *HashesEntryUpdate) SetExternalReferencesID(id int) *HashesEntryUpdate
SetExternalReferencesID sets the "external_references" edge to the ExternalReference entity by ID.
func (*HashesEntryUpdate) SetHashAlgorithmType ¶
func (heu *HashesEntryUpdate) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType) *HashesEntryUpdate
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryUpdate) SetHashData ¶
func (heu *HashesEntryUpdate) SetHashData(s string) *HashesEntryUpdate
SetHashData sets the "hash_data" field.
func (*HashesEntryUpdate) SetNillableExternalReferencesID ¶
func (heu *HashesEntryUpdate) SetNillableExternalReferencesID(id *int) *HashesEntryUpdate
SetNillableExternalReferencesID sets the "external_references" edge to the ExternalReference entity by ID if the given value is not nil.
func (*HashesEntryUpdate) SetNillableHashAlgorithmType ¶
func (heu *HashesEntryUpdate) SetNillableHashAlgorithmType(hat *hashesentry.HashAlgorithmType) *HashesEntryUpdate
SetNillableHashAlgorithmType sets the "hash_algorithm_type" field if the given value is not nil.
func (*HashesEntryUpdate) SetNillableHashData ¶
func (heu *HashesEntryUpdate) SetNillableHashData(s *string) *HashesEntryUpdate
SetNillableHashData sets the "hash_data" field if the given value is not nil.
func (*HashesEntryUpdate) SetNillableNodesID ¶
func (heu *HashesEntryUpdate) SetNillableNodesID(id *string) *HashesEntryUpdate
SetNillableNodesID sets the "nodes" edge to the Node entity by ID if the given value is not nil.
func (*HashesEntryUpdate) SetNodes ¶
func (heu *HashesEntryUpdate) SetNodes(n *Node) *HashesEntryUpdate
SetNodes sets the "nodes" edge to the Node entity.
func (*HashesEntryUpdate) SetNodesID ¶
func (heu *HashesEntryUpdate) SetNodesID(id string) *HashesEntryUpdate
SetNodesID sets the "nodes" edge to the Node entity by ID.
func (*HashesEntryUpdate) Where ¶
func (heu *HashesEntryUpdate) Where(ps ...predicate.HashesEntry) *HashesEntryUpdate
Where appends a list predicates to the HashesEntryUpdate builder.
type HashesEntryUpdateOne ¶
type HashesEntryUpdateOne struct {
// contains filtered or unexported fields
}
HashesEntryUpdateOne is the builder for updating a single HashesEntry entity.
func (*HashesEntryUpdateOne) ClearExternalReferences ¶
func (heuo *HashesEntryUpdateOne) ClearExternalReferences() *HashesEntryUpdateOne
ClearExternalReferences clears the "external_references" edge to the ExternalReference entity.
func (*HashesEntryUpdateOne) ClearNodes ¶
func (heuo *HashesEntryUpdateOne) ClearNodes() *HashesEntryUpdateOne
ClearNodes clears the "nodes" edge to the Node entity.
func (*HashesEntryUpdateOne) Exec ¶
func (heuo *HashesEntryUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*HashesEntryUpdateOne) ExecX ¶
func (heuo *HashesEntryUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryUpdateOne) Mutation ¶
func (heuo *HashesEntryUpdateOne) Mutation() *HashesEntryMutation
Mutation returns the HashesEntryMutation object of the builder.
func (*HashesEntryUpdateOne) Save ¶
func (heuo *HashesEntryUpdateOne) Save(ctx context.Context) (*HashesEntry, error)
Save executes the query and returns the updated HashesEntry entity.
func (*HashesEntryUpdateOne) SaveX ¶
func (heuo *HashesEntryUpdateOne) SaveX(ctx context.Context) *HashesEntry
SaveX is like Save, but panics if an error occurs.
func (*HashesEntryUpdateOne) Select ¶
func (heuo *HashesEntryUpdateOne) Select(field string, fields ...string) *HashesEntryUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*HashesEntryUpdateOne) SetExternalReferences ¶
func (heuo *HashesEntryUpdateOne) SetExternalReferences(e *ExternalReference) *HashesEntryUpdateOne
SetExternalReferences sets the "external_references" edge to the ExternalReference entity.
func (*HashesEntryUpdateOne) SetExternalReferencesID ¶
func (heuo *HashesEntryUpdateOne) SetExternalReferencesID(id int) *HashesEntryUpdateOne
SetExternalReferencesID sets the "external_references" edge to the ExternalReference entity by ID.
func (*HashesEntryUpdateOne) SetHashAlgorithmType ¶
func (heuo *HashesEntryUpdateOne) SetHashAlgorithmType(hat hashesentry.HashAlgorithmType) *HashesEntryUpdateOne
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryUpdateOne) SetHashData ¶
func (heuo *HashesEntryUpdateOne) SetHashData(s string) *HashesEntryUpdateOne
SetHashData sets the "hash_data" field.
func (*HashesEntryUpdateOne) SetNillableExternalReferencesID ¶
func (heuo *HashesEntryUpdateOne) SetNillableExternalReferencesID(id *int) *HashesEntryUpdateOne
SetNillableExternalReferencesID sets the "external_references" edge to the ExternalReference entity by ID if the given value is not nil.
func (*HashesEntryUpdateOne) SetNillableHashAlgorithmType ¶
func (heuo *HashesEntryUpdateOne) SetNillableHashAlgorithmType(hat *hashesentry.HashAlgorithmType) *HashesEntryUpdateOne
SetNillableHashAlgorithmType sets the "hash_algorithm_type" field if the given value is not nil.
func (*HashesEntryUpdateOne) SetNillableHashData ¶
func (heuo *HashesEntryUpdateOne) SetNillableHashData(s *string) *HashesEntryUpdateOne
SetNillableHashData sets the "hash_data" field if the given value is not nil.
func (*HashesEntryUpdateOne) SetNillableNodesID ¶
func (heuo *HashesEntryUpdateOne) SetNillableNodesID(id *string) *HashesEntryUpdateOne
SetNillableNodesID sets the "nodes" edge to the Node entity by ID if the given value is not nil.
func (*HashesEntryUpdateOne) SetNodes ¶
func (heuo *HashesEntryUpdateOne) SetNodes(n *Node) *HashesEntryUpdateOne
SetNodes sets the "nodes" edge to the Node entity.
func (*HashesEntryUpdateOne) SetNodesID ¶
func (heuo *HashesEntryUpdateOne) SetNodesID(id string) *HashesEntryUpdateOne
SetNodesID sets the "nodes" edge to the Node entity by ID.
func (*HashesEntryUpdateOne) Where ¶
func (heuo *HashesEntryUpdateOne) Where(ps ...predicate.HashesEntry) *HashesEntryUpdateOne
Where appends a list predicates to the HashesEntryUpdate builder.
type HashesEntryUpsert ¶
HashesEntryUpsert is the "OnConflict" setter.
func (*HashesEntryUpsert) SetHashAlgorithmType ¶
func (u *HashesEntryUpsert) SetHashAlgorithmType(v hashesentry.HashAlgorithmType) *HashesEntryUpsert
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryUpsert) SetHashData ¶
func (u *HashesEntryUpsert) SetHashData(v string) *HashesEntryUpsert
SetHashData sets the "hash_data" field.
func (*HashesEntryUpsert) UpdateHashAlgorithmType ¶
func (u *HashesEntryUpsert) UpdateHashAlgorithmType() *HashesEntryUpsert
UpdateHashAlgorithmType sets the "hash_algorithm_type" field to the value that was provided on create.
func (*HashesEntryUpsert) UpdateHashData ¶
func (u *HashesEntryUpsert) UpdateHashData() *HashesEntryUpsert
UpdateHashData sets the "hash_data" field to the value that was provided on create.
type HashesEntryUpsertBulk ¶
type HashesEntryUpsertBulk struct {
// contains filtered or unexported fields
}
HashesEntryUpsertBulk is the builder for "upsert"-ing a bulk of HashesEntry nodes.
func (*HashesEntryUpsertBulk) DoNothing ¶
func (u *HashesEntryUpsertBulk) DoNothing() *HashesEntryUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*HashesEntryUpsertBulk) Exec ¶
func (u *HashesEntryUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*HashesEntryUpsertBulk) ExecX ¶
func (u *HashesEntryUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryUpsertBulk) Ignore ¶
func (u *HashesEntryUpsertBulk) Ignore() *HashesEntryUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.HashesEntry.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*HashesEntryUpsertBulk) SetHashAlgorithmType ¶
func (u *HashesEntryUpsertBulk) SetHashAlgorithmType(v hashesentry.HashAlgorithmType) *HashesEntryUpsertBulk
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryUpsertBulk) SetHashData ¶
func (u *HashesEntryUpsertBulk) SetHashData(v string) *HashesEntryUpsertBulk
SetHashData sets the "hash_data" field.
func (*HashesEntryUpsertBulk) Update ¶
func (u *HashesEntryUpsertBulk) Update(set func(*HashesEntryUpsert)) *HashesEntryUpsertBulk
Update allows overriding fields `UPDATE` values. See the HashesEntryCreateBulk.OnConflict documentation for more info.
func (*HashesEntryUpsertBulk) UpdateHashAlgorithmType ¶
func (u *HashesEntryUpsertBulk) UpdateHashAlgorithmType() *HashesEntryUpsertBulk
UpdateHashAlgorithmType sets the "hash_algorithm_type" field to the value that was provided on create.
func (*HashesEntryUpsertBulk) UpdateHashData ¶
func (u *HashesEntryUpsertBulk) UpdateHashData() *HashesEntryUpsertBulk
UpdateHashData sets the "hash_data" field to the value that was provided on create.
func (*HashesEntryUpsertBulk) UpdateNewValues ¶
func (u *HashesEntryUpsertBulk) UpdateNewValues() *HashesEntryUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.HashesEntry.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
type HashesEntryUpsertOne ¶
type HashesEntryUpsertOne struct {
// contains filtered or unexported fields
}
HashesEntryUpsertOne is the builder for "upsert"-ing
one HashesEntry node.
func (*HashesEntryUpsertOne) DoNothing ¶
func (u *HashesEntryUpsertOne) DoNothing() *HashesEntryUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*HashesEntryUpsertOne) Exec ¶
func (u *HashesEntryUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*HashesEntryUpsertOne) ExecX ¶
func (u *HashesEntryUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*HashesEntryUpsertOne) ID ¶
func (u *HashesEntryUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*HashesEntryUpsertOne) IDX ¶
func (u *HashesEntryUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*HashesEntryUpsertOne) Ignore ¶
func (u *HashesEntryUpsertOne) Ignore() *HashesEntryUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.HashesEntry.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*HashesEntryUpsertOne) SetHashAlgorithmType ¶
func (u *HashesEntryUpsertOne) SetHashAlgorithmType(v hashesentry.HashAlgorithmType) *HashesEntryUpsertOne
SetHashAlgorithmType sets the "hash_algorithm_type" field.
func (*HashesEntryUpsertOne) SetHashData ¶
func (u *HashesEntryUpsertOne) SetHashData(v string) *HashesEntryUpsertOne
SetHashData sets the "hash_data" field.
func (*HashesEntryUpsertOne) Update ¶
func (u *HashesEntryUpsertOne) Update(set func(*HashesEntryUpsert)) *HashesEntryUpsertOne
Update allows overriding fields `UPDATE` values. See the HashesEntryCreate.OnConflict documentation for more info.
func (*HashesEntryUpsertOne) UpdateHashAlgorithmType ¶
func (u *HashesEntryUpsertOne) UpdateHashAlgorithmType() *HashesEntryUpsertOne
UpdateHashAlgorithmType sets the "hash_algorithm_type" field to the value that was provided on create.
func (*HashesEntryUpsertOne) UpdateHashData ¶
func (u *HashesEntryUpsertOne) UpdateHashData() *HashesEntryUpsertOne
UpdateHashData sets the "hash_data" field to the value that was provided on create.
func (*HashesEntryUpsertOne) UpdateNewValues ¶
func (u *HashesEntryUpsertOne) UpdateNewValues() *HashesEntryUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.HashesEntry.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
type IdentifiersEntries ¶
type IdentifiersEntries []*IdentifiersEntry
IdentifiersEntries is a parsable slice of IdentifiersEntry.
type IdentifiersEntry ¶
type IdentifiersEntry struct { // ID of the ent. ID int `json:"id,omitempty"` // SoftwareIdentifierType holds the value of the "software_identifier_type" field. SoftwareIdentifierType identifiersentry.SoftwareIdentifierType `json:"software_identifier_type,omitempty"` // SoftwareIdentifierValue holds the value of the "software_identifier_value" field. SoftwareIdentifierValue string `json:"software_identifier_value,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the IdentifiersEntryQuery when eager-loading is set. Edges IdentifiersEntryEdges `json:"edges"` // contains filtered or unexported fields }
IdentifiersEntry is the model entity for the IdentifiersEntry schema.
func (*IdentifiersEntry) QueryNodes ¶
func (ie *IdentifiersEntry) QueryNodes() *NodeQuery
QueryNodes queries the "nodes" edge of the IdentifiersEntry entity.
func (*IdentifiersEntry) String ¶
func (ie *IdentifiersEntry) String() string
String implements the fmt.Stringer.
func (*IdentifiersEntry) Unwrap ¶
func (ie *IdentifiersEntry) Unwrap() *IdentifiersEntry
Unwrap unwraps the IdentifiersEntry 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 (*IdentifiersEntry) Update ¶
func (ie *IdentifiersEntry) Update() *IdentifiersEntryUpdateOne
Update returns a builder for updating this IdentifiersEntry. Note that you need to call IdentifiersEntry.Unwrap() before calling this method if this IdentifiersEntry was returned from a transaction, and the transaction was committed or rolled back.
type IdentifiersEntryClient ¶
type IdentifiersEntryClient struct {
// contains filtered or unexported fields
}
IdentifiersEntryClient is a client for the IdentifiersEntry schema.
func NewIdentifiersEntryClient ¶
func NewIdentifiersEntryClient(c config) *IdentifiersEntryClient
NewIdentifiersEntryClient returns a client for the IdentifiersEntry from the given config.
func (*IdentifiersEntryClient) Create ¶
func (c *IdentifiersEntryClient) Create() *IdentifiersEntryCreate
Create returns a builder for creating a IdentifiersEntry entity.
func (*IdentifiersEntryClient) CreateBulk ¶
func (c *IdentifiersEntryClient) CreateBulk(builders ...*IdentifiersEntryCreate) *IdentifiersEntryCreateBulk
CreateBulk returns a builder for creating a bulk of IdentifiersEntry entities.
func (*IdentifiersEntryClient) Delete ¶
func (c *IdentifiersEntryClient) Delete() *IdentifiersEntryDelete
Delete returns a delete builder for IdentifiersEntry.
func (*IdentifiersEntryClient) DeleteOne ¶
func (c *IdentifiersEntryClient) DeleteOne(ie *IdentifiersEntry) *IdentifiersEntryDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*IdentifiersEntryClient) DeleteOneID ¶
func (c *IdentifiersEntryClient) DeleteOneID(id int) *IdentifiersEntryDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*IdentifiersEntryClient) Get ¶
func (c *IdentifiersEntryClient) Get(ctx context.Context, id int) (*IdentifiersEntry, error)
Get returns a IdentifiersEntry entity by its id.
func (*IdentifiersEntryClient) GetX ¶
func (c *IdentifiersEntryClient) GetX(ctx context.Context, id int) *IdentifiersEntry
GetX is like Get, but panics if an error occurs.
func (*IdentifiersEntryClient) Hooks ¶
func (c *IdentifiersEntryClient) Hooks() []Hook
Hooks returns the client hooks.
func (*IdentifiersEntryClient) Intercept ¶
func (c *IdentifiersEntryClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `identifiersentry.Intercept(f(g(h())))`.
func (*IdentifiersEntryClient) Interceptors ¶
func (c *IdentifiersEntryClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*IdentifiersEntryClient) MapCreateBulk ¶
func (c *IdentifiersEntryClient) MapCreateBulk(slice any, setFunc func(*IdentifiersEntryCreate, int)) *IdentifiersEntryCreateBulk
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 (*IdentifiersEntryClient) Query ¶
func (c *IdentifiersEntryClient) Query() *IdentifiersEntryQuery
Query returns a query builder for IdentifiersEntry.
func (*IdentifiersEntryClient) QueryNodes ¶
func (c *IdentifiersEntryClient) QueryNodes(ie *IdentifiersEntry) *NodeQuery
QueryNodes queries the nodes edge of a IdentifiersEntry.
func (*IdentifiersEntryClient) Update ¶
func (c *IdentifiersEntryClient) Update() *IdentifiersEntryUpdate
Update returns an update builder for IdentifiersEntry.
func (*IdentifiersEntryClient) UpdateOne ¶
func (c *IdentifiersEntryClient) UpdateOne(ie *IdentifiersEntry) *IdentifiersEntryUpdateOne
UpdateOne returns an update builder for the given entity.
func (*IdentifiersEntryClient) UpdateOneID ¶
func (c *IdentifiersEntryClient) UpdateOneID(id int) *IdentifiersEntryUpdateOne
UpdateOneID returns an update builder for the given id.
func (*IdentifiersEntryClient) Use ¶
func (c *IdentifiersEntryClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `identifiersentry.Hooks(f(g(h())))`.
type IdentifiersEntryCreate ¶
type IdentifiersEntryCreate struct {
// contains filtered or unexported fields
}
IdentifiersEntryCreate is the builder for creating a IdentifiersEntry entity.
func (*IdentifiersEntryCreate) Exec ¶
func (iec *IdentifiersEntryCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*IdentifiersEntryCreate) ExecX ¶
func (iec *IdentifiersEntryCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryCreate) Mutation ¶
func (iec *IdentifiersEntryCreate) Mutation() *IdentifiersEntryMutation
Mutation returns the IdentifiersEntryMutation object of the builder.
func (*IdentifiersEntryCreate) OnConflict ¶
func (iec *IdentifiersEntryCreate) OnConflict(opts ...sql.ConflictOption) *IdentifiersEntryUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.IdentifiersEntry.Create(). SetSoftwareIdentifierType(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.IdentifiersEntryUpsert) { SetSoftwareIdentifierType(v+v). }). Exec(ctx)
func (*IdentifiersEntryCreate) OnConflictColumns ¶
func (iec *IdentifiersEntryCreate) OnConflictColumns(columns ...string) *IdentifiersEntryUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.IdentifiersEntry.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*IdentifiersEntryCreate) Save ¶
func (iec *IdentifiersEntryCreate) Save(ctx context.Context) (*IdentifiersEntry, error)
Save creates the IdentifiersEntry in the database.
func (*IdentifiersEntryCreate) SaveX ¶
func (iec *IdentifiersEntryCreate) SaveX(ctx context.Context) *IdentifiersEntry
SaveX calls Save and panics if Save returns an error.
func (*IdentifiersEntryCreate) SetNillableNodesID ¶
func (iec *IdentifiersEntryCreate) SetNillableNodesID(id *string) *IdentifiersEntryCreate
SetNillableNodesID sets the "nodes" edge to the Node entity by ID if the given value is not nil.
func (*IdentifiersEntryCreate) SetNodes ¶
func (iec *IdentifiersEntryCreate) SetNodes(n *Node) *IdentifiersEntryCreate
SetNodes sets the "nodes" edge to the Node entity.
func (*IdentifiersEntryCreate) SetNodesID ¶
func (iec *IdentifiersEntryCreate) SetNodesID(id string) *IdentifiersEntryCreate
SetNodesID sets the "nodes" edge to the Node entity by ID.
func (*IdentifiersEntryCreate) SetSoftwareIdentifierType ¶
func (iec *IdentifiersEntryCreate) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType) *IdentifiersEntryCreate
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryCreate) SetSoftwareIdentifierValue ¶
func (iec *IdentifiersEntryCreate) SetSoftwareIdentifierValue(s string) *IdentifiersEntryCreate
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
type IdentifiersEntryCreateBulk ¶
type IdentifiersEntryCreateBulk struct {
// contains filtered or unexported fields
}
IdentifiersEntryCreateBulk is the builder for creating many IdentifiersEntry entities in bulk.
func (*IdentifiersEntryCreateBulk) Exec ¶
func (iecb *IdentifiersEntryCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*IdentifiersEntryCreateBulk) ExecX ¶
func (iecb *IdentifiersEntryCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryCreateBulk) OnConflict ¶
func (iecb *IdentifiersEntryCreateBulk) OnConflict(opts ...sql.ConflictOption) *IdentifiersEntryUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.IdentifiersEntry.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.IdentifiersEntryUpsert) { SetSoftwareIdentifierType(v+v). }). Exec(ctx)
func (*IdentifiersEntryCreateBulk) OnConflictColumns ¶
func (iecb *IdentifiersEntryCreateBulk) OnConflictColumns(columns ...string) *IdentifiersEntryUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.IdentifiersEntry.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*IdentifiersEntryCreateBulk) Save ¶
func (iecb *IdentifiersEntryCreateBulk) Save(ctx context.Context) ([]*IdentifiersEntry, error)
Save creates the IdentifiersEntry entities in the database.
func (*IdentifiersEntryCreateBulk) SaveX ¶
func (iecb *IdentifiersEntryCreateBulk) SaveX(ctx context.Context) []*IdentifiersEntry
SaveX is like Save, but panics if an error occurs.
type IdentifiersEntryDelete ¶
type IdentifiersEntryDelete struct {
// contains filtered or unexported fields
}
IdentifiersEntryDelete is the builder for deleting a IdentifiersEntry entity.
func (*IdentifiersEntryDelete) Exec ¶
func (ied *IdentifiersEntryDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*IdentifiersEntryDelete) ExecX ¶
func (ied *IdentifiersEntryDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryDelete) Where ¶
func (ied *IdentifiersEntryDelete) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryDelete
Where appends a list predicates to the IdentifiersEntryDelete builder.
type IdentifiersEntryDeleteOne ¶
type IdentifiersEntryDeleteOne struct {
// contains filtered or unexported fields
}
IdentifiersEntryDeleteOne is the builder for deleting a single IdentifiersEntry entity.
func (*IdentifiersEntryDeleteOne) Exec ¶
func (iedo *IdentifiersEntryDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*IdentifiersEntryDeleteOne) ExecX ¶
func (iedo *IdentifiersEntryDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryDeleteOne) Where ¶
func (iedo *IdentifiersEntryDeleteOne) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryDeleteOne
Where appends a list predicates to the IdentifiersEntryDelete builder.
type IdentifiersEntryEdges ¶
type IdentifiersEntryEdges struct { // Nodes holds the value of the nodes edge. Nodes *Node `json:"nodes,omitempty"` // contains filtered or unexported fields }
IdentifiersEntryEdges holds the relations/edges for other nodes in the graph.
func (IdentifiersEntryEdges) NodesOrErr ¶
func (e IdentifiersEntryEdges) NodesOrErr() (*Node, error)
NodesOrErr returns the Nodes value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type IdentifiersEntryGroupBy ¶
type IdentifiersEntryGroupBy struct {
// contains filtered or unexported fields
}
IdentifiersEntryGroupBy is the group-by builder for IdentifiersEntry entities.
func (*IdentifiersEntryGroupBy) Aggregate ¶
func (iegb *IdentifiersEntryGroupBy) Aggregate(fns ...AggregateFunc) *IdentifiersEntryGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*IdentifiersEntryGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntryGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntryGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntryGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntryGroupBy) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*IdentifiersEntryGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntryGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntryGroupBy) Scan ¶
func (iegb *IdentifiersEntryGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*IdentifiersEntryGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type IdentifiersEntryMutation ¶
type IdentifiersEntryMutation struct {
// contains filtered or unexported fields
}
IdentifiersEntryMutation represents an operation that mutates the IdentifiersEntry nodes in the graph.
func (*IdentifiersEntryMutation) AddField ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) AddedEdges ¶
func (m *IdentifiersEntryMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*IdentifiersEntryMutation) AddedField ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) AddedFields ¶
func (m *IdentifiersEntryMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*IdentifiersEntryMutation) AddedIDs ¶
func (m *IdentifiersEntryMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*IdentifiersEntryMutation) ClearEdge ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) ClearField ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) ClearNodes ¶
func (m *IdentifiersEntryMutation) ClearNodes()
ClearNodes clears the "nodes" edge to the Node entity.
func (*IdentifiersEntryMutation) ClearedEdges ¶
func (m *IdentifiersEntryMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*IdentifiersEntryMutation) ClearedFields ¶
func (m *IdentifiersEntryMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (IdentifiersEntryMutation) Client ¶
func (m IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) EdgeCleared ¶
func (m *IdentifiersEntryMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*IdentifiersEntryMutation) Field ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) FieldCleared ¶
func (m *IdentifiersEntryMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*IdentifiersEntryMutation) Fields ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) ID ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) IDs ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) NodesCleared ¶
func (m *IdentifiersEntryMutation) NodesCleared() bool
NodesCleared reports if the "nodes" edge to the Node entity was cleared.
func (*IdentifiersEntryMutation) NodesID ¶
func (m *IdentifiersEntryMutation) NodesID() (id string, exists bool)
NodesID returns the "nodes" edge ID in the mutation.
func (*IdentifiersEntryMutation) NodesIDs ¶
func (m *IdentifiersEntryMutation) NodesIDs() (ids []string)
NodesIDs returns the "nodes" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use NodesID instead. It exists only for internal usage by the builders.
func (*IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) OldSoftwareIdentifierType ¶
func (m *IdentifiersEntryMutation) OldSoftwareIdentifierType(ctx context.Context) (v identifiersentry.SoftwareIdentifierType, err error)
OldSoftwareIdentifierType returns the old "software_identifier_type" field's value of the IdentifiersEntry entity. If the IdentifiersEntry 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 (*IdentifiersEntryMutation) OldSoftwareIdentifierValue ¶
func (m *IdentifiersEntryMutation) OldSoftwareIdentifierValue(ctx context.Context) (v string, err error)
OldSoftwareIdentifierValue returns the old "software_identifier_value" field's value of the IdentifiersEntry entity. If the IdentifiersEntry 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 (*IdentifiersEntryMutation) Op ¶
func (m *IdentifiersEntryMutation) Op() Op
Op returns the operation name.
func (*IdentifiersEntryMutation) RemovedEdges ¶
func (m *IdentifiersEntryMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*IdentifiersEntryMutation) RemovedIDs ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) ResetEdge ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) ResetField ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) ResetNodes ¶
func (m *IdentifiersEntryMutation) ResetNodes()
ResetNodes resets all changes to the "nodes" edge.
func (*IdentifiersEntryMutation) ResetSoftwareIdentifierType ¶
func (m *IdentifiersEntryMutation) ResetSoftwareIdentifierType()
ResetSoftwareIdentifierType resets all changes to the "software_identifier_type" field.
func (*IdentifiersEntryMutation) ResetSoftwareIdentifierValue ¶
func (m *IdentifiersEntryMutation) ResetSoftwareIdentifierValue()
ResetSoftwareIdentifierValue resets all changes to the "software_identifier_value" field.
func (*IdentifiersEntryMutation) SetField ¶
func (m *IdentifiersEntryMutation) 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 (*IdentifiersEntryMutation) SetNodesID ¶
func (m *IdentifiersEntryMutation) SetNodesID(id string)
SetNodesID sets the "nodes" edge to the Node entity by id.
func (*IdentifiersEntryMutation) SetOp ¶
func (m *IdentifiersEntryMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*IdentifiersEntryMutation) SetSoftwareIdentifierType ¶
func (m *IdentifiersEntryMutation) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType)
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryMutation) SetSoftwareIdentifierValue ¶
func (m *IdentifiersEntryMutation) SetSoftwareIdentifierValue(s string)
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
func (*IdentifiersEntryMutation) SoftwareIdentifierType ¶
func (m *IdentifiersEntryMutation) SoftwareIdentifierType() (r identifiersentry.SoftwareIdentifierType, exists bool)
SoftwareIdentifierType returns the value of the "software_identifier_type" field in the mutation.
func (*IdentifiersEntryMutation) SoftwareIdentifierValue ¶
func (m *IdentifiersEntryMutation) SoftwareIdentifierValue() (r string, exists bool)
SoftwareIdentifierValue returns the value of the "software_identifier_value" field in the mutation.
func (IdentifiersEntryMutation) Tx ¶
func (m IdentifiersEntryMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*IdentifiersEntryMutation) Type ¶
func (m *IdentifiersEntryMutation) Type() string
Type returns the node type of this mutation (IdentifiersEntry).
func (*IdentifiersEntryMutation) Where ¶
func (m *IdentifiersEntryMutation) Where(ps ...predicate.IdentifiersEntry)
Where appends a list predicates to the IdentifiersEntryMutation builder.
func (*IdentifiersEntryMutation) WhereP ¶
func (m *IdentifiersEntryMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the IdentifiersEntryMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type IdentifiersEntryQuery ¶
type IdentifiersEntryQuery struct {
// contains filtered or unexported fields
}
IdentifiersEntryQuery is the builder for querying IdentifiersEntry entities.
func (*IdentifiersEntryQuery) Aggregate ¶
func (ieq *IdentifiersEntryQuery) Aggregate(fns ...AggregateFunc) *IdentifiersEntrySelect
Aggregate returns a IdentifiersEntrySelect configured with the given aggregations.
func (*IdentifiersEntryQuery) All ¶
func (ieq *IdentifiersEntryQuery) All(ctx context.Context) ([]*IdentifiersEntry, error)
All executes the query and returns a list of IdentifiersEntries.
func (*IdentifiersEntryQuery) AllX ¶
func (ieq *IdentifiersEntryQuery) AllX(ctx context.Context) []*IdentifiersEntry
AllX is like All, but panics if an error occurs.
func (*IdentifiersEntryQuery) Clone ¶
func (ieq *IdentifiersEntryQuery) Clone() *IdentifiersEntryQuery
Clone returns a duplicate of the IdentifiersEntryQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*IdentifiersEntryQuery) Count ¶
func (ieq *IdentifiersEntryQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*IdentifiersEntryQuery) CountX ¶
func (ieq *IdentifiersEntryQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*IdentifiersEntryQuery) Exist ¶
func (ieq *IdentifiersEntryQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*IdentifiersEntryQuery) ExistX ¶
func (ieq *IdentifiersEntryQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*IdentifiersEntryQuery) First ¶
func (ieq *IdentifiersEntryQuery) First(ctx context.Context) (*IdentifiersEntry, error)
First returns the first IdentifiersEntry entity from the query. Returns a *NotFoundError when no IdentifiersEntry was found.
func (*IdentifiersEntryQuery) FirstID ¶
func (ieq *IdentifiersEntryQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first IdentifiersEntry ID from the query. Returns a *NotFoundError when no IdentifiersEntry ID was found.
func (*IdentifiersEntryQuery) FirstIDX ¶
func (ieq *IdentifiersEntryQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*IdentifiersEntryQuery) FirstX ¶
func (ieq *IdentifiersEntryQuery) FirstX(ctx context.Context) *IdentifiersEntry
FirstX is like First, but panics if an error occurs.
func (*IdentifiersEntryQuery) GroupBy ¶
func (ieq *IdentifiersEntryQuery) GroupBy(field string, fields ...string) *IdentifiersEntryGroupBy
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 { SoftwareIdentifierType identifiersentry.SoftwareIdentifierType `json:"software_identifier_type,omitempty"` Count int `json:"count,omitempty"` } client.IdentifiersEntry.Query(). GroupBy(identifiersentry.FieldSoftwareIdentifierType). Aggregate(ent.Count()). Scan(ctx, &v)
func (*IdentifiersEntryQuery) IDs ¶
func (ieq *IdentifiersEntryQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of IdentifiersEntry IDs.
func (*IdentifiersEntryQuery) IDsX ¶
func (ieq *IdentifiersEntryQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*IdentifiersEntryQuery) Limit ¶
func (ieq *IdentifiersEntryQuery) Limit(limit int) *IdentifiersEntryQuery
Limit the number of records to be returned by this query.
func (*IdentifiersEntryQuery) Offset ¶
func (ieq *IdentifiersEntryQuery) Offset(offset int) *IdentifiersEntryQuery
Offset to start from.
func (*IdentifiersEntryQuery) Only ¶
func (ieq *IdentifiersEntryQuery) Only(ctx context.Context) (*IdentifiersEntry, error)
Only returns a single IdentifiersEntry entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one IdentifiersEntry entity is found. Returns a *NotFoundError when no IdentifiersEntry entities are found.
func (*IdentifiersEntryQuery) OnlyID ¶
func (ieq *IdentifiersEntryQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only IdentifiersEntry ID in the query. Returns a *NotSingularError when more than one IdentifiersEntry ID is found. Returns a *NotFoundError when no entities are found.
func (*IdentifiersEntryQuery) OnlyIDX ¶
func (ieq *IdentifiersEntryQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*IdentifiersEntryQuery) OnlyX ¶
func (ieq *IdentifiersEntryQuery) OnlyX(ctx context.Context) *IdentifiersEntry
OnlyX is like Only, but panics if an error occurs.
func (*IdentifiersEntryQuery) Order ¶
func (ieq *IdentifiersEntryQuery) Order(o ...identifiersentry.OrderOption) *IdentifiersEntryQuery
Order specifies how the records should be ordered.
func (*IdentifiersEntryQuery) QueryNodes ¶
func (ieq *IdentifiersEntryQuery) QueryNodes() *NodeQuery
QueryNodes chains the current query on the "nodes" edge.
func (*IdentifiersEntryQuery) Select ¶
func (ieq *IdentifiersEntryQuery) Select(fields ...string) *IdentifiersEntrySelect
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 { SoftwareIdentifierType identifiersentry.SoftwareIdentifierType `json:"software_identifier_type,omitempty"` } client.IdentifiersEntry.Query(). Select(identifiersentry.FieldSoftwareIdentifierType). Scan(ctx, &v)
func (*IdentifiersEntryQuery) Unique ¶
func (ieq *IdentifiersEntryQuery) Unique(unique bool) *IdentifiersEntryQuery
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 (*IdentifiersEntryQuery) Where ¶
func (ieq *IdentifiersEntryQuery) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryQuery
Where adds a new predicate for the IdentifiersEntryQuery builder.
func (*IdentifiersEntryQuery) WithNodes ¶
func (ieq *IdentifiersEntryQuery) WithNodes(opts ...func(*NodeQuery)) *IdentifiersEntryQuery
WithNodes tells the query-builder to eager-load the nodes that are connected to the "nodes" edge. The optional arguments are used to configure the query builder of the edge.
type IdentifiersEntrySelect ¶
type IdentifiersEntrySelect struct { *IdentifiersEntryQuery // contains filtered or unexported fields }
IdentifiersEntrySelect is the builder for selecting fields of IdentifiersEntry entities.
func (*IdentifiersEntrySelect) Aggregate ¶
func (ies *IdentifiersEntrySelect) Aggregate(fns ...AggregateFunc) *IdentifiersEntrySelect
Aggregate adds the given aggregation functions to the selector query.
func (*IdentifiersEntrySelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntrySelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntrySelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntrySelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntrySelect) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*IdentifiersEntrySelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntrySelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*IdentifiersEntrySelect) Scan ¶
func (ies *IdentifiersEntrySelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*IdentifiersEntrySelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type IdentifiersEntryUpdate ¶
type IdentifiersEntryUpdate struct {
// contains filtered or unexported fields
}
IdentifiersEntryUpdate is the builder for updating IdentifiersEntry entities.
func (*IdentifiersEntryUpdate) ClearNodes ¶
func (ieu *IdentifiersEntryUpdate) ClearNodes() *IdentifiersEntryUpdate
ClearNodes clears the "nodes" edge to the Node entity.
func (*IdentifiersEntryUpdate) Exec ¶
func (ieu *IdentifiersEntryUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*IdentifiersEntryUpdate) ExecX ¶
func (ieu *IdentifiersEntryUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryUpdate) Mutation ¶
func (ieu *IdentifiersEntryUpdate) Mutation() *IdentifiersEntryMutation
Mutation returns the IdentifiersEntryMutation object of the builder.
func (*IdentifiersEntryUpdate) Save ¶
func (ieu *IdentifiersEntryUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*IdentifiersEntryUpdate) SaveX ¶
func (ieu *IdentifiersEntryUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*IdentifiersEntryUpdate) SetNillableNodesID ¶
func (ieu *IdentifiersEntryUpdate) SetNillableNodesID(id *string) *IdentifiersEntryUpdate
SetNillableNodesID sets the "nodes" edge to the Node entity by ID if the given value is not nil.
func (*IdentifiersEntryUpdate) SetNillableSoftwareIdentifierType ¶
func (ieu *IdentifiersEntryUpdate) SetNillableSoftwareIdentifierType(iit *identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdate
SetNillableSoftwareIdentifierType sets the "software_identifier_type" field if the given value is not nil.
func (*IdentifiersEntryUpdate) SetNillableSoftwareIdentifierValue ¶
func (ieu *IdentifiersEntryUpdate) SetNillableSoftwareIdentifierValue(s *string) *IdentifiersEntryUpdate
SetNillableSoftwareIdentifierValue sets the "software_identifier_value" field if the given value is not nil.
func (*IdentifiersEntryUpdate) SetNodes ¶
func (ieu *IdentifiersEntryUpdate) SetNodes(n *Node) *IdentifiersEntryUpdate
SetNodes sets the "nodes" edge to the Node entity.
func (*IdentifiersEntryUpdate) SetNodesID ¶
func (ieu *IdentifiersEntryUpdate) SetNodesID(id string) *IdentifiersEntryUpdate
SetNodesID sets the "nodes" edge to the Node entity by ID.
func (*IdentifiersEntryUpdate) SetSoftwareIdentifierType ¶
func (ieu *IdentifiersEntryUpdate) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdate
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryUpdate) SetSoftwareIdentifierValue ¶
func (ieu *IdentifiersEntryUpdate) SetSoftwareIdentifierValue(s string) *IdentifiersEntryUpdate
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
func (*IdentifiersEntryUpdate) Where ¶
func (ieu *IdentifiersEntryUpdate) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryUpdate
Where appends a list predicates to the IdentifiersEntryUpdate builder.
type IdentifiersEntryUpdateOne ¶
type IdentifiersEntryUpdateOne struct {
// contains filtered or unexported fields
}
IdentifiersEntryUpdateOne is the builder for updating a single IdentifiersEntry entity.
func (*IdentifiersEntryUpdateOne) ClearNodes ¶
func (ieuo *IdentifiersEntryUpdateOne) ClearNodes() *IdentifiersEntryUpdateOne
ClearNodes clears the "nodes" edge to the Node entity.
func (*IdentifiersEntryUpdateOne) Exec ¶
func (ieuo *IdentifiersEntryUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*IdentifiersEntryUpdateOne) ExecX ¶
func (ieuo *IdentifiersEntryUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryUpdateOne) Mutation ¶
func (ieuo *IdentifiersEntryUpdateOne) Mutation() *IdentifiersEntryMutation
Mutation returns the IdentifiersEntryMutation object of the builder.
func (*IdentifiersEntryUpdateOne) Save ¶
func (ieuo *IdentifiersEntryUpdateOne) Save(ctx context.Context) (*IdentifiersEntry, error)
Save executes the query and returns the updated IdentifiersEntry entity.
func (*IdentifiersEntryUpdateOne) SaveX ¶
func (ieuo *IdentifiersEntryUpdateOne) SaveX(ctx context.Context) *IdentifiersEntry
SaveX is like Save, but panics if an error occurs.
func (*IdentifiersEntryUpdateOne) Select ¶
func (ieuo *IdentifiersEntryUpdateOne) Select(field string, fields ...string) *IdentifiersEntryUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*IdentifiersEntryUpdateOne) SetNillableNodesID ¶
func (ieuo *IdentifiersEntryUpdateOne) SetNillableNodesID(id *string) *IdentifiersEntryUpdateOne
SetNillableNodesID sets the "nodes" edge to the Node entity by ID if the given value is not nil.
func (*IdentifiersEntryUpdateOne) SetNillableSoftwareIdentifierType ¶
func (ieuo *IdentifiersEntryUpdateOne) SetNillableSoftwareIdentifierType(iit *identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdateOne
SetNillableSoftwareIdentifierType sets the "software_identifier_type" field if the given value is not nil.
func (*IdentifiersEntryUpdateOne) SetNillableSoftwareIdentifierValue ¶
func (ieuo *IdentifiersEntryUpdateOne) SetNillableSoftwareIdentifierValue(s *string) *IdentifiersEntryUpdateOne
SetNillableSoftwareIdentifierValue sets the "software_identifier_value" field if the given value is not nil.
func (*IdentifiersEntryUpdateOne) SetNodes ¶
func (ieuo *IdentifiersEntryUpdateOne) SetNodes(n *Node) *IdentifiersEntryUpdateOne
SetNodes sets the "nodes" edge to the Node entity.
func (*IdentifiersEntryUpdateOne) SetNodesID ¶
func (ieuo *IdentifiersEntryUpdateOne) SetNodesID(id string) *IdentifiersEntryUpdateOne
SetNodesID sets the "nodes" edge to the Node entity by ID.
func (*IdentifiersEntryUpdateOne) SetSoftwareIdentifierType ¶
func (ieuo *IdentifiersEntryUpdateOne) SetSoftwareIdentifierType(iit identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpdateOne
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryUpdateOne) SetSoftwareIdentifierValue ¶
func (ieuo *IdentifiersEntryUpdateOne) SetSoftwareIdentifierValue(s string) *IdentifiersEntryUpdateOne
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
func (*IdentifiersEntryUpdateOne) Where ¶
func (ieuo *IdentifiersEntryUpdateOne) Where(ps ...predicate.IdentifiersEntry) *IdentifiersEntryUpdateOne
Where appends a list predicates to the IdentifiersEntryUpdate builder.
type IdentifiersEntryUpsert ¶
IdentifiersEntryUpsert is the "OnConflict" setter.
func (*IdentifiersEntryUpsert) SetSoftwareIdentifierType ¶
func (u *IdentifiersEntryUpsert) SetSoftwareIdentifierType(v identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpsert
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryUpsert) SetSoftwareIdentifierValue ¶
func (u *IdentifiersEntryUpsert) SetSoftwareIdentifierValue(v string) *IdentifiersEntryUpsert
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
func (*IdentifiersEntryUpsert) UpdateSoftwareIdentifierType ¶
func (u *IdentifiersEntryUpsert) UpdateSoftwareIdentifierType() *IdentifiersEntryUpsert
UpdateSoftwareIdentifierType sets the "software_identifier_type" field to the value that was provided on create.
func (*IdentifiersEntryUpsert) UpdateSoftwareIdentifierValue ¶
func (u *IdentifiersEntryUpsert) UpdateSoftwareIdentifierValue() *IdentifiersEntryUpsert
UpdateSoftwareIdentifierValue sets the "software_identifier_value" field to the value that was provided on create.
type IdentifiersEntryUpsertBulk ¶
type IdentifiersEntryUpsertBulk struct {
// contains filtered or unexported fields
}
IdentifiersEntryUpsertBulk is the builder for "upsert"-ing a bulk of IdentifiersEntry nodes.
func (*IdentifiersEntryUpsertBulk) DoNothing ¶
func (u *IdentifiersEntryUpsertBulk) DoNothing() *IdentifiersEntryUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*IdentifiersEntryUpsertBulk) Exec ¶
func (u *IdentifiersEntryUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*IdentifiersEntryUpsertBulk) ExecX ¶
func (u *IdentifiersEntryUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryUpsertBulk) Ignore ¶
func (u *IdentifiersEntryUpsertBulk) Ignore() *IdentifiersEntryUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.IdentifiersEntry.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*IdentifiersEntryUpsertBulk) SetSoftwareIdentifierType ¶
func (u *IdentifiersEntryUpsertBulk) SetSoftwareIdentifierType(v identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpsertBulk
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryUpsertBulk) SetSoftwareIdentifierValue ¶
func (u *IdentifiersEntryUpsertBulk) SetSoftwareIdentifierValue(v string) *IdentifiersEntryUpsertBulk
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
func (*IdentifiersEntryUpsertBulk) Update ¶
func (u *IdentifiersEntryUpsertBulk) Update(set func(*IdentifiersEntryUpsert)) *IdentifiersEntryUpsertBulk
Update allows overriding fields `UPDATE` values. See the IdentifiersEntryCreateBulk.OnConflict documentation for more info.
func (*IdentifiersEntryUpsertBulk) UpdateNewValues ¶
func (u *IdentifiersEntryUpsertBulk) UpdateNewValues() *IdentifiersEntryUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.IdentifiersEntry.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*IdentifiersEntryUpsertBulk) UpdateSoftwareIdentifierType ¶
func (u *IdentifiersEntryUpsertBulk) UpdateSoftwareIdentifierType() *IdentifiersEntryUpsertBulk
UpdateSoftwareIdentifierType sets the "software_identifier_type" field to the value that was provided on create.
func (*IdentifiersEntryUpsertBulk) UpdateSoftwareIdentifierValue ¶
func (u *IdentifiersEntryUpsertBulk) UpdateSoftwareIdentifierValue() *IdentifiersEntryUpsertBulk
UpdateSoftwareIdentifierValue sets the "software_identifier_value" field to the value that was provided on create.
type IdentifiersEntryUpsertOne ¶
type IdentifiersEntryUpsertOne struct {
// contains filtered or unexported fields
}
IdentifiersEntryUpsertOne is the builder for "upsert"-ing
one IdentifiersEntry node.
func (*IdentifiersEntryUpsertOne) DoNothing ¶
func (u *IdentifiersEntryUpsertOne) DoNothing() *IdentifiersEntryUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*IdentifiersEntryUpsertOne) Exec ¶
func (u *IdentifiersEntryUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*IdentifiersEntryUpsertOne) ExecX ¶
func (u *IdentifiersEntryUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*IdentifiersEntryUpsertOne) ID ¶
func (u *IdentifiersEntryUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*IdentifiersEntryUpsertOne) IDX ¶
func (u *IdentifiersEntryUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*IdentifiersEntryUpsertOne) Ignore ¶
func (u *IdentifiersEntryUpsertOne) Ignore() *IdentifiersEntryUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.IdentifiersEntry.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*IdentifiersEntryUpsertOne) SetSoftwareIdentifierType ¶
func (u *IdentifiersEntryUpsertOne) SetSoftwareIdentifierType(v identifiersentry.SoftwareIdentifierType) *IdentifiersEntryUpsertOne
SetSoftwareIdentifierType sets the "software_identifier_type" field.
func (*IdentifiersEntryUpsertOne) SetSoftwareIdentifierValue ¶
func (u *IdentifiersEntryUpsertOne) SetSoftwareIdentifierValue(v string) *IdentifiersEntryUpsertOne
SetSoftwareIdentifierValue sets the "software_identifier_value" field.
func (*IdentifiersEntryUpsertOne) Update ¶
func (u *IdentifiersEntryUpsertOne) Update(set func(*IdentifiersEntryUpsert)) *IdentifiersEntryUpsertOne
Update allows overriding fields `UPDATE` values. See the IdentifiersEntryCreate.OnConflict documentation for more info.
func (*IdentifiersEntryUpsertOne) UpdateNewValues ¶
func (u *IdentifiersEntryUpsertOne) UpdateNewValues() *IdentifiersEntryUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.IdentifiersEntry.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*IdentifiersEntryUpsertOne) UpdateSoftwareIdentifierType ¶
func (u *IdentifiersEntryUpsertOne) UpdateSoftwareIdentifierType() *IdentifiersEntryUpsertOne
UpdateSoftwareIdentifierType sets the "software_identifier_type" field to the value that was provided on create.
func (*IdentifiersEntryUpsertOne) UpdateSoftwareIdentifierValue ¶
func (u *IdentifiersEntryUpsertOne) UpdateSoftwareIdentifierValue() *IdentifiersEntryUpsertOne
UpdateSoftwareIdentifierValue sets the "software_identifier_value" 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 Metadata ¶
type Metadata struct { // ID of the ent. ID string `json:"id,omitempty"` // Version holds the value of the "version" field. Version string `json:"version,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Date holds the value of the "date" field. Date time.Time `json:"date,omitempty"` // Comment holds the value of the "comment" field. Comment string `json:"comment,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the MetadataQuery when eager-loading is set. Edges MetadataEdges `json:"edges"` // contains filtered or unexported fields }
Metadata is the model entity for the Metadata schema.
func (*Metadata) QueryAuthors ¶
func (m *Metadata) QueryAuthors() *PersonQuery
QueryAuthors queries the "authors" edge of the Metadata entity.
func (*Metadata) QueryDocument ¶
func (m *Metadata) QueryDocument() *DocumentQuery
QueryDocument queries the "document" edge of the Metadata entity.
func (*Metadata) QueryDocumentTypes ¶
func (m *Metadata) QueryDocumentTypes() *DocumentTypeQuery
QueryDocumentTypes queries the "document_types" edge of the Metadata entity.
func (*Metadata) QueryTools ¶
QueryTools queries the "tools" edge of the Metadata entity.
func (*Metadata) Unwrap ¶
Unwrap unwraps the Metadata 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 (*Metadata) Update ¶
func (m *Metadata) Update() *MetadataUpdateOne
Update returns a builder for updating this Metadata. Note that you need to call Metadata.Unwrap() before calling this method if this Metadata was returned from a transaction, and the transaction was committed or rolled back.
type MetadataClient ¶
type MetadataClient struct {
// contains filtered or unexported fields
}
MetadataClient is a client for the Metadata schema.
func NewMetadataClient ¶
func NewMetadataClient(c config) *MetadataClient
NewMetadataClient returns a client for the Metadata from the given config.
func (*MetadataClient) Create ¶
func (c *MetadataClient) Create() *MetadataCreate
Create returns a builder for creating a Metadata entity.
func (*MetadataClient) CreateBulk ¶
func (c *MetadataClient) CreateBulk(builders ...*MetadataCreate) *MetadataCreateBulk
CreateBulk returns a builder for creating a bulk of Metadata entities.
func (*MetadataClient) Delete ¶
func (c *MetadataClient) Delete() *MetadataDelete
Delete returns a delete builder for Metadata.
func (*MetadataClient) DeleteOne ¶
func (c *MetadataClient) DeleteOne(m *Metadata) *MetadataDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*MetadataClient) DeleteOneID ¶
func (c *MetadataClient) DeleteOneID(id string) *MetadataDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*MetadataClient) GetX ¶
func (c *MetadataClient) GetX(ctx context.Context, id string) *Metadata
GetX is like Get, but panics if an error occurs.
func (*MetadataClient) Hooks ¶
func (c *MetadataClient) Hooks() []Hook
Hooks returns the client hooks.
func (*MetadataClient) Intercept ¶
func (c *MetadataClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `metadata.Intercept(f(g(h())))`.
func (*MetadataClient) Interceptors ¶
func (c *MetadataClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*MetadataClient) MapCreateBulk ¶
func (c *MetadataClient) MapCreateBulk(slice any, setFunc func(*MetadataCreate, int)) *MetadataCreateBulk
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 (*MetadataClient) Query ¶
func (c *MetadataClient) Query() *MetadataQuery
Query returns a query builder for Metadata.
func (*MetadataClient) QueryAuthors ¶
func (c *MetadataClient) QueryAuthors(m *Metadata) *PersonQuery
QueryAuthors queries the authors edge of a Metadata.
func (*MetadataClient) QueryDocument ¶
func (c *MetadataClient) QueryDocument(m *Metadata) *DocumentQuery
QueryDocument queries the document edge of a Metadata.
func (*MetadataClient) QueryDocumentTypes ¶
func (c *MetadataClient) QueryDocumentTypes(m *Metadata) *DocumentTypeQuery
QueryDocumentTypes queries the document_types edge of a Metadata.
func (*MetadataClient) QueryTools ¶
func (c *MetadataClient) QueryTools(m *Metadata) *ToolQuery
QueryTools queries the tools edge of a Metadata.
func (*MetadataClient) Update ¶
func (c *MetadataClient) Update() *MetadataUpdate
Update returns an update builder for Metadata.
func (*MetadataClient) UpdateOne ¶
func (c *MetadataClient) UpdateOne(m *Metadata) *MetadataUpdateOne
UpdateOne returns an update builder for the given entity.
func (*MetadataClient) UpdateOneID ¶
func (c *MetadataClient) UpdateOneID(id string) *MetadataUpdateOne
UpdateOneID returns an update builder for the given id.
func (*MetadataClient) Use ¶
func (c *MetadataClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `metadata.Hooks(f(g(h())))`.
type MetadataCreate ¶
type MetadataCreate struct {
// contains filtered or unexported fields
}
MetadataCreate is the builder for creating a Metadata entity.
func (*MetadataCreate) AddAuthorIDs ¶
func (mc *MetadataCreate) AddAuthorIDs(ids ...int) *MetadataCreate
AddAuthorIDs adds the "authors" edge to the Person entity by IDs.
func (*MetadataCreate) AddAuthors ¶
func (mc *MetadataCreate) AddAuthors(p ...*Person) *MetadataCreate
AddAuthors adds the "authors" edges to the Person entity.
func (*MetadataCreate) AddDocumentTypeIDs ¶
func (mc *MetadataCreate) AddDocumentTypeIDs(ids ...int) *MetadataCreate
AddDocumentTypeIDs adds the "document_types" edge to the DocumentType entity by IDs.
func (*MetadataCreate) AddDocumentTypes ¶
func (mc *MetadataCreate) AddDocumentTypes(d ...*DocumentType) *MetadataCreate
AddDocumentTypes adds the "document_types" edges to the DocumentType entity.
func (*MetadataCreate) AddToolIDs ¶
func (mc *MetadataCreate) AddToolIDs(ids ...int) *MetadataCreate
AddToolIDs adds the "tools" edge to the Tool entity by IDs.
func (*MetadataCreate) AddTools ¶
func (mc *MetadataCreate) AddTools(t ...*Tool) *MetadataCreate
AddTools adds the "tools" edges to the Tool entity.
func (*MetadataCreate) Exec ¶
func (mc *MetadataCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*MetadataCreate) ExecX ¶
func (mc *MetadataCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataCreate) Mutation ¶
func (mc *MetadataCreate) Mutation() *MetadataMutation
Mutation returns the MetadataMutation object of the builder.
func (*MetadataCreate) OnConflict ¶
func (mc *MetadataCreate) OnConflict(opts ...sql.ConflictOption) *MetadataUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Metadata.Create(). SetVersion(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.MetadataUpsert) { SetVersion(v+v). }). Exec(ctx)
func (*MetadataCreate) OnConflictColumns ¶
func (mc *MetadataCreate) OnConflictColumns(columns ...string) *MetadataUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Metadata.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*MetadataCreate) Save ¶
func (mc *MetadataCreate) Save(ctx context.Context) (*Metadata, error)
Save creates the Metadata in the database.
func (*MetadataCreate) SaveX ¶
func (mc *MetadataCreate) SaveX(ctx context.Context) *Metadata
SaveX calls Save and panics if Save returns an error.
func (*MetadataCreate) SetComment ¶
func (mc *MetadataCreate) SetComment(s string) *MetadataCreate
SetComment sets the "comment" field.
func (*MetadataCreate) SetDate ¶
func (mc *MetadataCreate) SetDate(t time.Time) *MetadataCreate
SetDate sets the "date" field.
func (*MetadataCreate) SetDocument ¶
func (mc *MetadataCreate) SetDocument(d *Document) *MetadataCreate
SetDocument sets the "document" edge to the Document entity.
func (*MetadataCreate) SetDocumentID ¶
func (mc *MetadataCreate) SetDocumentID(id int) *MetadataCreate
SetDocumentID sets the "document" edge to the Document entity by ID.
func (*MetadataCreate) SetID ¶
func (mc *MetadataCreate) SetID(s string) *MetadataCreate
SetID sets the "id" field.
func (*MetadataCreate) SetName ¶
func (mc *MetadataCreate) SetName(s string) *MetadataCreate
SetName sets the "name" field.
func (*MetadataCreate) SetNillableDocumentID ¶
func (mc *MetadataCreate) SetNillableDocumentID(id *int) *MetadataCreate
SetNillableDocumentID sets the "document" edge to the Document entity by ID if the given value is not nil.
func (*MetadataCreate) SetVersion ¶
func (mc *MetadataCreate) SetVersion(s string) *MetadataCreate
SetVersion sets the "version" field.
type MetadataCreateBulk ¶
type MetadataCreateBulk struct {
// contains filtered or unexported fields
}
MetadataCreateBulk is the builder for creating many Metadata entities in bulk.
func (*MetadataCreateBulk) Exec ¶
func (mcb *MetadataCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MetadataCreateBulk) ExecX ¶
func (mcb *MetadataCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataCreateBulk) OnConflict ¶
func (mcb *MetadataCreateBulk) OnConflict(opts ...sql.ConflictOption) *MetadataUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Metadata.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.MetadataUpsert) { SetVersion(v+v). }). Exec(ctx)
func (*MetadataCreateBulk) OnConflictColumns ¶
func (mcb *MetadataCreateBulk) OnConflictColumns(columns ...string) *MetadataUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Metadata.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type MetadataDelete ¶
type MetadataDelete struct {
// contains filtered or unexported fields
}
MetadataDelete is the builder for deleting a Metadata entity.
func (*MetadataDelete) Exec ¶
func (md *MetadataDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*MetadataDelete) ExecX ¶
func (md *MetadataDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*MetadataDelete) Where ¶
func (md *MetadataDelete) Where(ps ...predicate.Metadata) *MetadataDelete
Where appends a list predicates to the MetadataDelete builder.
type MetadataDeleteOne ¶
type MetadataDeleteOne struct {
// contains filtered or unexported fields
}
MetadataDeleteOne is the builder for deleting a single Metadata entity.
func (*MetadataDeleteOne) Exec ¶
func (mdo *MetadataDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*MetadataDeleteOne) ExecX ¶
func (mdo *MetadataDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataDeleteOne) Where ¶
func (mdo *MetadataDeleteOne) Where(ps ...predicate.Metadata) *MetadataDeleteOne
Where appends a list predicates to the MetadataDelete builder.
type MetadataEdges ¶
type MetadataEdges struct { // Tools holds the value of the tools edge. Tools []*Tool `json:"tools,omitempty"` // Authors holds the value of the authors edge. Authors []*Person `json:"authors,omitempty"` // DocumentTypes holds the value of the document_types edge. DocumentTypes []*DocumentType `json:"document_types,omitempty"` // Document holds the value of the document edge. Document *Document `json:"document,omitempty"` // contains filtered or unexported fields }
MetadataEdges holds the relations/edges for other nodes in the graph.
func (MetadataEdges) AuthorsOrErr ¶
func (e MetadataEdges) AuthorsOrErr() ([]*Person, error)
AuthorsOrErr returns the Authors value or an error if the edge was not loaded in eager-loading.
func (MetadataEdges) DocumentOrErr ¶
func (e MetadataEdges) DocumentOrErr() (*Document, error)
DocumentOrErr returns the Document value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (MetadataEdges) DocumentTypesOrErr ¶
func (e MetadataEdges) DocumentTypesOrErr() ([]*DocumentType, error)
DocumentTypesOrErr returns the DocumentTypes value or an error if the edge was not loaded in eager-loading.
func (MetadataEdges) ToolsOrErr ¶
func (e MetadataEdges) ToolsOrErr() ([]*Tool, error)
ToolsOrErr returns the Tools value or an error if the edge was not loaded in eager-loading.
type MetadataGroupBy ¶
type MetadataGroupBy struct {
// contains filtered or unexported fields
}
MetadataGroupBy is the group-by builder for Metadata entities.
func (*MetadataGroupBy) Aggregate ¶
func (mgb *MetadataGroupBy) Aggregate(fns ...AggregateFunc) *MetadataGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*MetadataGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MetadataGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MetadataGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MetadataGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MetadataGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MetadataGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MetadataGroupBy) Scan ¶
func (mgb *MetadataGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*MetadataGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type MetadataMutation ¶
type MetadataMutation struct {
// contains filtered or unexported fields
}
MetadataMutation represents an operation that mutates the Metadata nodes in the graph.
func (*MetadataMutation) AddAuthorIDs ¶
func (m *MetadataMutation) AddAuthorIDs(ids ...int)
AddAuthorIDs adds the "authors" edge to the Person entity by ids.
func (*MetadataMutation) AddDocumentTypeIDs ¶
func (m *MetadataMutation) AddDocumentTypeIDs(ids ...int)
AddDocumentTypeIDs adds the "document_types" edge to the DocumentType entity by ids.
func (*MetadataMutation) AddField ¶
func (m *MetadataMutation) 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 (*MetadataMutation) AddToolIDs ¶
func (m *MetadataMutation) AddToolIDs(ids ...int)
AddToolIDs adds the "tools" edge to the Tool entity by ids.
func (*MetadataMutation) AddedEdges ¶
func (m *MetadataMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*MetadataMutation) AddedField ¶
func (m *MetadataMutation) 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 (*MetadataMutation) AddedFields ¶
func (m *MetadataMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*MetadataMutation) AddedIDs ¶
func (m *MetadataMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*MetadataMutation) AuthorsCleared ¶
func (m *MetadataMutation) AuthorsCleared() bool
AuthorsCleared reports if the "authors" edge to the Person entity was cleared.
func (*MetadataMutation) AuthorsIDs ¶
func (m *MetadataMutation) AuthorsIDs() (ids []int)
AuthorsIDs returns the "authors" edge IDs in the mutation.
func (*MetadataMutation) ClearAuthors ¶
func (m *MetadataMutation) ClearAuthors()
ClearAuthors clears the "authors" edge to the Person entity.
func (*MetadataMutation) ClearDocument ¶
func (m *MetadataMutation) ClearDocument()
ClearDocument clears the "document" edge to the Document entity.
func (*MetadataMutation) ClearDocumentTypes ¶
func (m *MetadataMutation) ClearDocumentTypes()
ClearDocumentTypes clears the "document_types" edge to the DocumentType entity.
func (*MetadataMutation) ClearEdge ¶
func (m *MetadataMutation) 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 (*MetadataMutation) ClearField ¶
func (m *MetadataMutation) 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 (*MetadataMutation) ClearTools ¶
func (m *MetadataMutation) ClearTools()
ClearTools clears the "tools" edge to the Tool entity.
func (*MetadataMutation) ClearedEdges ¶
func (m *MetadataMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*MetadataMutation) ClearedFields ¶
func (m *MetadataMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (MetadataMutation) Client ¶
func (m MetadataMutation) 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 (*MetadataMutation) Comment ¶
func (m *MetadataMutation) Comment() (r string, exists bool)
Comment returns the value of the "comment" field in the mutation.
func (*MetadataMutation) Date ¶
func (m *MetadataMutation) Date() (r time.Time, exists bool)
Date returns the value of the "date" field in the mutation.
func (*MetadataMutation) DocumentCleared ¶
func (m *MetadataMutation) DocumentCleared() bool
DocumentCleared reports if the "document" edge to the Document entity was cleared.
func (*MetadataMutation) DocumentID ¶
func (m *MetadataMutation) DocumentID() (id int, exists bool)
DocumentID returns the "document" edge ID in the mutation.
func (*MetadataMutation) DocumentIDs ¶
func (m *MetadataMutation) DocumentIDs() (ids []int)
DocumentIDs returns the "document" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use DocumentID instead. It exists only for internal usage by the builders.
func (*MetadataMutation) DocumentTypesCleared ¶
func (m *MetadataMutation) DocumentTypesCleared() bool
DocumentTypesCleared reports if the "document_types" edge to the DocumentType entity was cleared.
func (*MetadataMutation) DocumentTypesIDs ¶
func (m *MetadataMutation) DocumentTypesIDs() (ids []int)
DocumentTypesIDs returns the "document_types" edge IDs in the mutation.
func (*MetadataMutation) EdgeCleared ¶
func (m *MetadataMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*MetadataMutation) Field ¶
func (m *MetadataMutation) 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 (*MetadataMutation) FieldCleared ¶
func (m *MetadataMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*MetadataMutation) Fields ¶
func (m *MetadataMutation) 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 (*MetadataMutation) ID ¶
func (m *MetadataMutation) ID() (id string, 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 (*MetadataMutation) IDs ¶
func (m *MetadataMutation) IDs(ctx context.Context) ([]string, 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 (*MetadataMutation) Name ¶
func (m *MetadataMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*MetadataMutation) OldComment ¶
func (m *MetadataMutation) OldComment(ctx context.Context) (v string, err error)
OldComment returns the old "comment" field's value of the Metadata entity. If the Metadata 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 (*MetadataMutation) OldDate ¶
OldDate returns the old "date" field's value of the Metadata entity. If the Metadata 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 (*MetadataMutation) 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 (*MetadataMutation) OldName ¶
func (m *MetadataMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Metadata entity. If the Metadata 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 (*MetadataMutation) OldVersion ¶
func (m *MetadataMutation) OldVersion(ctx context.Context) (v string, err error)
OldVersion returns the old "version" field's value of the Metadata entity. If the Metadata 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 (*MetadataMutation) RemoveAuthorIDs ¶
func (m *MetadataMutation) RemoveAuthorIDs(ids ...int)
RemoveAuthorIDs removes the "authors" edge to the Person entity by IDs.
func (*MetadataMutation) RemoveDocumentTypeIDs ¶
func (m *MetadataMutation) RemoveDocumentTypeIDs(ids ...int)
RemoveDocumentTypeIDs removes the "document_types" edge to the DocumentType entity by IDs.
func (*MetadataMutation) RemoveToolIDs ¶
func (m *MetadataMutation) RemoveToolIDs(ids ...int)
RemoveToolIDs removes the "tools" edge to the Tool entity by IDs.
func (*MetadataMutation) RemovedAuthorsIDs ¶
func (m *MetadataMutation) RemovedAuthorsIDs() (ids []int)
RemovedAuthors returns the removed IDs of the "authors" edge to the Person entity.
func (*MetadataMutation) RemovedDocumentTypesIDs ¶
func (m *MetadataMutation) RemovedDocumentTypesIDs() (ids []int)
RemovedDocumentTypes returns the removed IDs of the "document_types" edge to the DocumentType entity.
func (*MetadataMutation) RemovedEdges ¶
func (m *MetadataMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*MetadataMutation) RemovedIDs ¶
func (m *MetadataMutation) 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 (*MetadataMutation) RemovedToolsIDs ¶
func (m *MetadataMutation) RemovedToolsIDs() (ids []int)
RemovedTools returns the removed IDs of the "tools" edge to the Tool entity.
func (*MetadataMutation) ResetAuthors ¶
func (m *MetadataMutation) ResetAuthors()
ResetAuthors resets all changes to the "authors" edge.
func (*MetadataMutation) ResetComment ¶
func (m *MetadataMutation) ResetComment()
ResetComment resets all changes to the "comment" field.
func (*MetadataMutation) ResetDate ¶
func (m *MetadataMutation) ResetDate()
ResetDate resets all changes to the "date" field.
func (*MetadataMutation) ResetDocument ¶
func (m *MetadataMutation) ResetDocument()
ResetDocument resets all changes to the "document" edge.
func (*MetadataMutation) ResetDocumentTypes ¶
func (m *MetadataMutation) ResetDocumentTypes()
ResetDocumentTypes resets all changes to the "document_types" edge.
func (*MetadataMutation) ResetEdge ¶
func (m *MetadataMutation) 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 (*MetadataMutation) ResetField ¶
func (m *MetadataMutation) 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 (*MetadataMutation) ResetName ¶
func (m *MetadataMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*MetadataMutation) ResetTools ¶
func (m *MetadataMutation) ResetTools()
ResetTools resets all changes to the "tools" edge.
func (*MetadataMutation) ResetVersion ¶
func (m *MetadataMutation) ResetVersion()
ResetVersion resets all changes to the "version" field.
func (*MetadataMutation) SetComment ¶
func (m *MetadataMutation) SetComment(s string)
SetComment sets the "comment" field.
func (*MetadataMutation) SetDate ¶
func (m *MetadataMutation) SetDate(t time.Time)
SetDate sets the "date" field.
func (*MetadataMutation) SetDocumentID ¶
func (m *MetadataMutation) SetDocumentID(id int)
SetDocumentID sets the "document" edge to the Document entity by id.
func (*MetadataMutation) SetField ¶
func (m *MetadataMutation) 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 (*MetadataMutation) SetID ¶
func (m *MetadataMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Metadata entities.
func (*MetadataMutation) SetName ¶
func (m *MetadataMutation) SetName(s string)
SetName sets the "name" field.
func (*MetadataMutation) SetOp ¶
func (m *MetadataMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*MetadataMutation) SetVersion ¶
func (m *MetadataMutation) SetVersion(s string)
SetVersion sets the "version" field.
func (*MetadataMutation) ToolsCleared ¶
func (m *MetadataMutation) ToolsCleared() bool
ToolsCleared reports if the "tools" edge to the Tool entity was cleared.
func (*MetadataMutation) ToolsIDs ¶
func (m *MetadataMutation) ToolsIDs() (ids []int)
ToolsIDs returns the "tools" edge IDs in the mutation.
func (MetadataMutation) Tx ¶
func (m MetadataMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*MetadataMutation) Type ¶
func (m *MetadataMutation) Type() string
Type returns the node type of this mutation (Metadata).
func (*MetadataMutation) Version ¶
func (m *MetadataMutation) Version() (r string, exists bool)
Version returns the value of the "version" field in the mutation.
func (*MetadataMutation) Where ¶
func (m *MetadataMutation) Where(ps ...predicate.Metadata)
Where appends a list predicates to the MetadataMutation builder.
func (*MetadataMutation) WhereP ¶
func (m *MetadataMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the MetadataMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type MetadataQuery ¶
type MetadataQuery struct {
// contains filtered or unexported fields
}
MetadataQuery is the builder for querying Metadata entities.
func (*MetadataQuery) Aggregate ¶
func (mq *MetadataQuery) Aggregate(fns ...AggregateFunc) *MetadataSelect
Aggregate returns a MetadataSelect configured with the given aggregations.
func (*MetadataQuery) All ¶
func (mq *MetadataQuery) All(ctx context.Context) ([]*Metadata, error)
All executes the query and returns a list of MetadataSlice.
func (*MetadataQuery) AllX ¶
func (mq *MetadataQuery) AllX(ctx context.Context) []*Metadata
AllX is like All, but panics if an error occurs.
func (*MetadataQuery) Clone ¶
func (mq *MetadataQuery) Clone() *MetadataQuery
Clone returns a duplicate of the MetadataQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*MetadataQuery) Count ¶
func (mq *MetadataQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*MetadataQuery) CountX ¶
func (mq *MetadataQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*MetadataQuery) Exist ¶
func (mq *MetadataQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*MetadataQuery) ExistX ¶
func (mq *MetadataQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*MetadataQuery) First ¶
func (mq *MetadataQuery) First(ctx context.Context) (*Metadata, error)
First returns the first Metadata entity from the query. Returns a *NotFoundError when no Metadata was found.
func (*MetadataQuery) FirstID ¶
func (mq *MetadataQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first Metadata ID from the query. Returns a *NotFoundError when no Metadata ID was found.
func (*MetadataQuery) FirstIDX ¶
func (mq *MetadataQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*MetadataQuery) FirstX ¶
func (mq *MetadataQuery) FirstX(ctx context.Context) *Metadata
FirstX is like First, but panics if an error occurs.
func (*MetadataQuery) GroupBy ¶
func (mq *MetadataQuery) GroupBy(field string, fields ...string) *MetadataGroupBy
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 { Version string `json:"version,omitempty"` Count int `json:"count,omitempty"` } client.Metadata.Query(). GroupBy(metadata.FieldVersion). Aggregate(ent.Count()). Scan(ctx, &v)
func (*MetadataQuery) IDs ¶
func (mq *MetadataQuery) IDs(ctx context.Context) (ids []string, err error)
IDs executes the query and returns a list of Metadata IDs.
func (*MetadataQuery) IDsX ¶
func (mq *MetadataQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*MetadataQuery) Limit ¶
func (mq *MetadataQuery) Limit(limit int) *MetadataQuery
Limit the number of records to be returned by this query.
func (*MetadataQuery) Offset ¶
func (mq *MetadataQuery) Offset(offset int) *MetadataQuery
Offset to start from.
func (*MetadataQuery) Only ¶
func (mq *MetadataQuery) Only(ctx context.Context) (*Metadata, error)
Only returns a single Metadata entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Metadata entity is found. Returns a *NotFoundError when no Metadata entities are found.
func (*MetadataQuery) OnlyID ¶
func (mq *MetadataQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID is like Only, but returns the only Metadata ID in the query. Returns a *NotSingularError when more than one Metadata ID is found. Returns a *NotFoundError when no entities are found.
func (*MetadataQuery) OnlyIDX ¶
func (mq *MetadataQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*MetadataQuery) OnlyX ¶
func (mq *MetadataQuery) OnlyX(ctx context.Context) *Metadata
OnlyX is like Only, but panics if an error occurs.
func (*MetadataQuery) Order ¶
func (mq *MetadataQuery) Order(o ...metadata.OrderOption) *MetadataQuery
Order specifies how the records should be ordered.
func (*MetadataQuery) QueryAuthors ¶
func (mq *MetadataQuery) QueryAuthors() *PersonQuery
QueryAuthors chains the current query on the "authors" edge.
func (*MetadataQuery) QueryDocument ¶
func (mq *MetadataQuery) QueryDocument() *DocumentQuery
QueryDocument chains the current query on the "document" edge.
func (*MetadataQuery) QueryDocumentTypes ¶
func (mq *MetadataQuery) QueryDocumentTypes() *DocumentTypeQuery
QueryDocumentTypes chains the current query on the "document_types" edge.
func (*MetadataQuery) QueryTools ¶
func (mq *MetadataQuery) QueryTools() *ToolQuery
QueryTools chains the current query on the "tools" edge.
func (*MetadataQuery) Select ¶
func (mq *MetadataQuery) Select(fields ...string) *MetadataSelect
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 { Version string `json:"version,omitempty"` } client.Metadata.Query(). Select(metadata.FieldVersion). Scan(ctx, &v)
func (*MetadataQuery) Unique ¶
func (mq *MetadataQuery) Unique(unique bool) *MetadataQuery
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 (*MetadataQuery) Where ¶
func (mq *MetadataQuery) Where(ps ...predicate.Metadata) *MetadataQuery
Where adds a new predicate for the MetadataQuery builder.
func (*MetadataQuery) WithAuthors ¶
func (mq *MetadataQuery) WithAuthors(opts ...func(*PersonQuery)) *MetadataQuery
WithAuthors tells the query-builder to eager-load the nodes that are connected to the "authors" edge. The optional arguments are used to configure the query builder of the edge.
func (*MetadataQuery) WithDocument ¶
func (mq *MetadataQuery) WithDocument(opts ...func(*DocumentQuery)) *MetadataQuery
WithDocument tells the query-builder to eager-load the nodes that are connected to the "document" edge. The optional arguments are used to configure the query builder of the edge.
func (*MetadataQuery) WithDocumentTypes ¶
func (mq *MetadataQuery) WithDocumentTypes(opts ...func(*DocumentTypeQuery)) *MetadataQuery
WithDocumentTypes tells the query-builder to eager-load the nodes that are connected to the "document_types" edge. The optional arguments are used to configure the query builder of the edge.
func (*MetadataQuery) WithTools ¶
func (mq *MetadataQuery) WithTools(opts ...func(*ToolQuery)) *MetadataQuery
WithTools tells the query-builder to eager-load the nodes that are connected to the "tools" edge. The optional arguments are used to configure the query builder of the edge.
type MetadataSelect ¶
type MetadataSelect struct { *MetadataQuery // contains filtered or unexported fields }
MetadataSelect is the builder for selecting fields of Metadata entities.
func (*MetadataSelect) Aggregate ¶
func (ms *MetadataSelect) Aggregate(fns ...AggregateFunc) *MetadataSelect
Aggregate adds the given aggregation functions to the selector query.
func (*MetadataSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*MetadataSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*MetadataSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*MetadataSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*MetadataSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*MetadataSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*MetadataSelect) Scan ¶
func (ms *MetadataSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*MetadataSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type MetadataUpdate ¶
type MetadataUpdate struct {
// contains filtered or unexported fields
}
MetadataUpdate is the builder for updating Metadata entities.
func (*MetadataUpdate) AddAuthorIDs ¶
func (mu *MetadataUpdate) AddAuthorIDs(ids ...int) *MetadataUpdate
AddAuthorIDs adds the "authors" edge to the Person entity by IDs.
func (*MetadataUpdate) AddAuthors ¶
func (mu *MetadataUpdate) AddAuthors(p ...*Person) *MetadataUpdate
AddAuthors adds the "authors" edges to the Person entity.
func (*MetadataUpdate) AddDocumentTypeIDs ¶
func (mu *MetadataUpdate) AddDocumentTypeIDs(ids ...int) *MetadataUpdate
AddDocumentTypeIDs adds the "document_types" edge to the DocumentType entity by IDs.
func (*MetadataUpdate) AddDocumentTypes ¶
func (mu *MetadataUpdate) AddDocumentTypes(d ...*DocumentType) *MetadataUpdate
AddDocumentTypes adds the "document_types" edges to the DocumentType entity.
func (*MetadataUpdate) AddToolIDs ¶
func (mu *MetadataUpdate) AddToolIDs(ids ...int) *MetadataUpdate
AddToolIDs adds the "tools" edge to the Tool entity by IDs.
func (*MetadataUpdate) AddTools ¶
func (mu *MetadataUpdate) AddTools(t ...*Tool) *MetadataUpdate
AddTools adds the "tools" edges to the Tool entity.
func (*MetadataUpdate) ClearAuthors ¶
func (mu *MetadataUpdate) ClearAuthors() *MetadataUpdate
ClearAuthors clears all "authors" edges to the Person entity.
func (*MetadataUpdate) ClearDocument ¶
func (mu *MetadataUpdate) ClearDocument() *MetadataUpdate
ClearDocument clears the "document" edge to the Document entity.
func (*MetadataUpdate) ClearDocumentTypes ¶
func (mu *MetadataUpdate) ClearDocumentTypes() *MetadataUpdate
ClearDocumentTypes clears all "document_types" edges to the DocumentType entity.
func (*MetadataUpdate) ClearTools ¶
func (mu *MetadataUpdate) ClearTools() *MetadataUpdate
ClearTools clears all "tools" edges to the Tool entity.
func (*MetadataUpdate) Exec ¶
func (mu *MetadataUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*MetadataUpdate) ExecX ¶
func (mu *MetadataUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataUpdate) Mutation ¶
func (mu *MetadataUpdate) Mutation() *MetadataMutation
Mutation returns the MetadataMutation object of the builder.
func (*MetadataUpdate) RemoveAuthorIDs ¶
func (mu *MetadataUpdate) RemoveAuthorIDs(ids ...int) *MetadataUpdate
RemoveAuthorIDs removes the "authors" edge to Person entities by IDs.
func (*MetadataUpdate) RemoveAuthors ¶
func (mu *MetadataUpdate) RemoveAuthors(p ...*Person) *MetadataUpdate
RemoveAuthors removes "authors" edges to Person entities.
func (*MetadataUpdate) RemoveDocumentTypeIDs ¶
func (mu *MetadataUpdate) RemoveDocumentTypeIDs(ids ...int) *MetadataUpdate
RemoveDocumentTypeIDs removes the "document_types" edge to DocumentType entities by IDs.
func (*MetadataUpdate) RemoveDocumentTypes ¶
func (mu *MetadataUpdate) RemoveDocumentTypes(d ...*DocumentType) *MetadataUpdate
RemoveDocumentTypes removes "document_types" edges to DocumentType entities.
func (*MetadataUpdate) RemoveToolIDs ¶
func (mu *MetadataUpdate) RemoveToolIDs(ids ...int) *MetadataUpdate
RemoveToolIDs removes the "tools" edge to Tool entities by IDs.
func (*MetadataUpdate) RemoveTools ¶
func (mu *MetadataUpdate) RemoveTools(t ...*Tool) *MetadataUpdate
RemoveTools removes "tools" edges to Tool entities.
func (*MetadataUpdate) Save ¶
func (mu *MetadataUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*MetadataUpdate) SaveX ¶
func (mu *MetadataUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*MetadataUpdate) SetComment ¶
func (mu *MetadataUpdate) SetComment(s string) *MetadataUpdate
SetComment sets the "comment" field.
func (*MetadataUpdate) SetDate ¶
func (mu *MetadataUpdate) SetDate(t time.Time) *MetadataUpdate
SetDate sets the "date" field.
func (*MetadataUpdate) SetDocument ¶
func (mu *MetadataUpdate) SetDocument(d *Document) *MetadataUpdate
SetDocument sets the "document" edge to the Document entity.
func (*MetadataUpdate) SetDocumentID ¶
func (mu *MetadataUpdate) SetDocumentID(id int) *MetadataUpdate
SetDocumentID sets the "document" edge to the Document entity by ID.
func (*MetadataUpdate) SetName ¶
func (mu *MetadataUpdate) SetName(s string) *MetadataUpdate
SetName sets the "name" field.
func (*MetadataUpdate) SetNillableComment ¶
func (mu *MetadataUpdate) SetNillableComment(s *string) *MetadataUpdate
SetNillableComment sets the "comment" field if the given value is not nil.
func (*MetadataUpdate) SetNillableDate ¶
func (mu *MetadataUpdate) SetNillableDate(t *time.Time) *MetadataUpdate
SetNillableDate sets the "date" field if the given value is not nil.
func (*MetadataUpdate) SetNillableDocumentID ¶
func (mu *MetadataUpdate) SetNillableDocumentID(id *int) *MetadataUpdate
SetNillableDocumentID sets the "document" edge to the Document entity by ID if the given value is not nil.
func (*MetadataUpdate) SetNillableName ¶
func (mu *MetadataUpdate) SetNillableName(s *string) *MetadataUpdate
SetNillableName sets the "name" field if the given value is not nil.
func (*MetadataUpdate) SetNillableVersion ¶
func (mu *MetadataUpdate) SetNillableVersion(s *string) *MetadataUpdate
SetNillableVersion sets the "version" field if the given value is not nil.
func (*MetadataUpdate) SetVersion ¶
func (mu *MetadataUpdate) SetVersion(s string) *MetadataUpdate
SetVersion sets the "version" field.
func (*MetadataUpdate) Where ¶
func (mu *MetadataUpdate) Where(ps ...predicate.Metadata) *MetadataUpdate
Where appends a list predicates to the MetadataUpdate builder.
type MetadataUpdateOne ¶
type MetadataUpdateOne struct {
// contains filtered or unexported fields
}
MetadataUpdateOne is the builder for updating a single Metadata entity.
func (*MetadataUpdateOne) AddAuthorIDs ¶
func (muo *MetadataUpdateOne) AddAuthorIDs(ids ...int) *MetadataUpdateOne
AddAuthorIDs adds the "authors" edge to the Person entity by IDs.
func (*MetadataUpdateOne) AddAuthors ¶
func (muo *MetadataUpdateOne) AddAuthors(p ...*Person) *MetadataUpdateOne
AddAuthors adds the "authors" edges to the Person entity.
func (*MetadataUpdateOne) AddDocumentTypeIDs ¶
func (muo *MetadataUpdateOne) AddDocumentTypeIDs(ids ...int) *MetadataUpdateOne
AddDocumentTypeIDs adds the "document_types" edge to the DocumentType entity by IDs.
func (*MetadataUpdateOne) AddDocumentTypes ¶
func (muo *MetadataUpdateOne) AddDocumentTypes(d ...*DocumentType) *MetadataUpdateOne
AddDocumentTypes adds the "document_types" edges to the DocumentType entity.
func (*MetadataUpdateOne) AddToolIDs ¶
func (muo *MetadataUpdateOne) AddToolIDs(ids ...int) *MetadataUpdateOne
AddToolIDs adds the "tools" edge to the Tool entity by IDs.
func (*MetadataUpdateOne) AddTools ¶
func (muo *MetadataUpdateOne) AddTools(t ...*Tool) *MetadataUpdateOne
AddTools adds the "tools" edges to the Tool entity.
func (*MetadataUpdateOne) ClearAuthors ¶
func (muo *MetadataUpdateOne) ClearAuthors() *MetadataUpdateOne
ClearAuthors clears all "authors" edges to the Person entity.
func (*MetadataUpdateOne) ClearDocument ¶
func (muo *MetadataUpdateOne) ClearDocument() *MetadataUpdateOne
ClearDocument clears the "document" edge to the Document entity.
func (*MetadataUpdateOne) ClearDocumentTypes ¶
func (muo *MetadataUpdateOne) ClearDocumentTypes() *MetadataUpdateOne
ClearDocumentTypes clears all "document_types" edges to the DocumentType entity.
func (*MetadataUpdateOne) ClearTools ¶
func (muo *MetadataUpdateOne) ClearTools() *MetadataUpdateOne
ClearTools clears all "tools" edges to the Tool entity.
func (*MetadataUpdateOne) Exec ¶
func (muo *MetadataUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*MetadataUpdateOne) ExecX ¶
func (muo *MetadataUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataUpdateOne) Mutation ¶
func (muo *MetadataUpdateOne) Mutation() *MetadataMutation
Mutation returns the MetadataMutation object of the builder.
func (*MetadataUpdateOne) RemoveAuthorIDs ¶
func (muo *MetadataUpdateOne) RemoveAuthorIDs(ids ...int) *MetadataUpdateOne
RemoveAuthorIDs removes the "authors" edge to Person entities by IDs.
func (*MetadataUpdateOne) RemoveAuthors ¶
func (muo *MetadataUpdateOne) RemoveAuthors(p ...*Person) *MetadataUpdateOne
RemoveAuthors removes "authors" edges to Person entities.
func (*MetadataUpdateOne) RemoveDocumentTypeIDs ¶
func (muo *MetadataUpdateOne) RemoveDocumentTypeIDs(ids ...int) *MetadataUpdateOne
RemoveDocumentTypeIDs removes the "document_types" edge to DocumentType entities by IDs.
func (*MetadataUpdateOne) RemoveDocumentTypes ¶
func (muo *MetadataUpdateOne) RemoveDocumentTypes(d ...*DocumentType) *MetadataUpdateOne
RemoveDocumentTypes removes "document_types" edges to DocumentType entities.
func (*MetadataUpdateOne) RemoveToolIDs ¶
func (muo *MetadataUpdateOne) RemoveToolIDs(ids ...int) *MetadataUpdateOne
RemoveToolIDs removes the "tools" edge to Tool entities by IDs.
func (*MetadataUpdateOne) RemoveTools ¶
func (muo *MetadataUpdateOne) RemoveTools(t ...*Tool) *MetadataUpdateOne
RemoveTools removes "tools" edges to Tool entities.
func (*MetadataUpdateOne) Save ¶
func (muo *MetadataUpdateOne) Save(ctx context.Context) (*Metadata, error)
Save executes the query and returns the updated Metadata entity.
func (*MetadataUpdateOne) SaveX ¶
func (muo *MetadataUpdateOne) SaveX(ctx context.Context) *Metadata
SaveX is like Save, but panics if an error occurs.
func (*MetadataUpdateOne) Select ¶
func (muo *MetadataUpdateOne) Select(field string, fields ...string) *MetadataUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*MetadataUpdateOne) SetComment ¶
func (muo *MetadataUpdateOne) SetComment(s string) *MetadataUpdateOne
SetComment sets the "comment" field.
func (*MetadataUpdateOne) SetDate ¶
func (muo *MetadataUpdateOne) SetDate(t time.Time) *MetadataUpdateOne
SetDate sets the "date" field.
func (*MetadataUpdateOne) SetDocument ¶
func (muo *MetadataUpdateOne) SetDocument(d *Document) *MetadataUpdateOne
SetDocument sets the "document" edge to the Document entity.
func (*MetadataUpdateOne) SetDocumentID ¶
func (muo *MetadataUpdateOne) SetDocumentID(id int) *MetadataUpdateOne
SetDocumentID sets the "document" edge to the Document entity by ID.
func (*MetadataUpdateOne) SetName ¶
func (muo *MetadataUpdateOne) SetName(s string) *MetadataUpdateOne
SetName sets the "name" field.
func (*MetadataUpdateOne) SetNillableComment ¶
func (muo *MetadataUpdateOne) SetNillableComment(s *string) *MetadataUpdateOne
SetNillableComment sets the "comment" field if the given value is not nil.
func (*MetadataUpdateOne) SetNillableDate ¶
func (muo *MetadataUpdateOne) SetNillableDate(t *time.Time) *MetadataUpdateOne
SetNillableDate sets the "date" field if the given value is not nil.
func (*MetadataUpdateOne) SetNillableDocumentID ¶
func (muo *MetadataUpdateOne) SetNillableDocumentID(id *int) *MetadataUpdateOne
SetNillableDocumentID sets the "document" edge to the Document entity by ID if the given value is not nil.
func (*MetadataUpdateOne) SetNillableName ¶
func (muo *MetadataUpdateOne) SetNillableName(s *string) *MetadataUpdateOne
SetNillableName sets the "name" field if the given value is not nil.
func (*MetadataUpdateOne) SetNillableVersion ¶
func (muo *MetadataUpdateOne) SetNillableVersion(s *string) *MetadataUpdateOne
SetNillableVersion sets the "version" field if the given value is not nil.
func (*MetadataUpdateOne) SetVersion ¶
func (muo *MetadataUpdateOne) SetVersion(s string) *MetadataUpdateOne
SetVersion sets the "version" field.
func (*MetadataUpdateOne) Where ¶
func (muo *MetadataUpdateOne) Where(ps ...predicate.Metadata) *MetadataUpdateOne
Where appends a list predicates to the MetadataUpdate builder.
type MetadataUpsert ¶
MetadataUpsert is the "OnConflict" setter.
func (*MetadataUpsert) SetComment ¶
func (u *MetadataUpsert) SetComment(v string) *MetadataUpsert
SetComment sets the "comment" field.
func (*MetadataUpsert) SetDate ¶
func (u *MetadataUpsert) SetDate(v time.Time) *MetadataUpsert
SetDate sets the "date" field.
func (*MetadataUpsert) SetName ¶
func (u *MetadataUpsert) SetName(v string) *MetadataUpsert
SetName sets the "name" field.
func (*MetadataUpsert) SetVersion ¶
func (u *MetadataUpsert) SetVersion(v string) *MetadataUpsert
SetVersion sets the "version" field.
func (*MetadataUpsert) UpdateComment ¶
func (u *MetadataUpsert) UpdateComment() *MetadataUpsert
UpdateComment sets the "comment" field to the value that was provided on create.
func (*MetadataUpsert) UpdateDate ¶
func (u *MetadataUpsert) UpdateDate() *MetadataUpsert
UpdateDate sets the "date" field to the value that was provided on create.
func (*MetadataUpsert) UpdateName ¶
func (u *MetadataUpsert) UpdateName() *MetadataUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*MetadataUpsert) UpdateVersion ¶
func (u *MetadataUpsert) UpdateVersion() *MetadataUpsert
UpdateVersion sets the "version" field to the value that was provided on create.
type MetadataUpsertBulk ¶
type MetadataUpsertBulk struct {
// contains filtered or unexported fields
}
MetadataUpsertBulk is the builder for "upsert"-ing a bulk of Metadata nodes.
func (*MetadataUpsertBulk) DoNothing ¶
func (u *MetadataUpsertBulk) DoNothing() *MetadataUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*MetadataUpsertBulk) Exec ¶
func (u *MetadataUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*MetadataUpsertBulk) ExecX ¶
func (u *MetadataUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataUpsertBulk) Ignore ¶
func (u *MetadataUpsertBulk) Ignore() *MetadataUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Metadata.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*MetadataUpsertBulk) SetComment ¶
func (u *MetadataUpsertBulk) SetComment(v string) *MetadataUpsertBulk
SetComment sets the "comment" field.
func (*MetadataUpsertBulk) SetDate ¶
func (u *MetadataUpsertBulk) SetDate(v time.Time) *MetadataUpsertBulk
SetDate sets the "date" field.
func (*MetadataUpsertBulk) SetName ¶
func (u *MetadataUpsertBulk) SetName(v string) *MetadataUpsertBulk
SetName sets the "name" field.
func (*MetadataUpsertBulk) SetVersion ¶
func (u *MetadataUpsertBulk) SetVersion(v string) *MetadataUpsertBulk
SetVersion sets the "version" field.
func (*MetadataUpsertBulk) Update ¶
func (u *MetadataUpsertBulk) Update(set func(*MetadataUpsert)) *MetadataUpsertBulk
Update allows overriding fields `UPDATE` values. See the MetadataCreateBulk.OnConflict documentation for more info.
func (*MetadataUpsertBulk) UpdateComment ¶
func (u *MetadataUpsertBulk) UpdateComment() *MetadataUpsertBulk
UpdateComment sets the "comment" field to the value that was provided on create.
func (*MetadataUpsertBulk) UpdateDate ¶
func (u *MetadataUpsertBulk) UpdateDate() *MetadataUpsertBulk
UpdateDate sets the "date" field to the value that was provided on create.
func (*MetadataUpsertBulk) UpdateName ¶
func (u *MetadataUpsertBulk) UpdateName() *MetadataUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*MetadataUpsertBulk) UpdateNewValues ¶
func (u *MetadataUpsertBulk) UpdateNewValues() *MetadataUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Metadata.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(metadata.FieldID) }), ). Exec(ctx)
func (*MetadataUpsertBulk) UpdateVersion ¶
func (u *MetadataUpsertBulk) UpdateVersion() *MetadataUpsertBulk
UpdateVersion sets the "version" field to the value that was provided on create.
type MetadataUpsertOne ¶
type MetadataUpsertOne struct {
// contains filtered or unexported fields
}
MetadataUpsertOne is the builder for "upsert"-ing
one Metadata node.
func (*MetadataUpsertOne) DoNothing ¶
func (u *MetadataUpsertOne) DoNothing() *MetadataUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*MetadataUpsertOne) Exec ¶
func (u *MetadataUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*MetadataUpsertOne) ExecX ¶
func (u *MetadataUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*MetadataUpsertOne) ID ¶
func (u *MetadataUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*MetadataUpsertOne) IDX ¶
func (u *MetadataUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*MetadataUpsertOne) Ignore ¶
func (u *MetadataUpsertOne) Ignore() *MetadataUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Metadata.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*MetadataUpsertOne) SetComment ¶
func (u *MetadataUpsertOne) SetComment(v string) *MetadataUpsertOne
SetComment sets the "comment" field.
func (*MetadataUpsertOne) SetDate ¶
func (u *MetadataUpsertOne) SetDate(v time.Time) *MetadataUpsertOne
SetDate sets the "date" field.
func (*MetadataUpsertOne) SetName ¶
func (u *MetadataUpsertOne) SetName(v string) *MetadataUpsertOne
SetName sets the "name" field.
func (*MetadataUpsertOne) SetVersion ¶
func (u *MetadataUpsertOne) SetVersion(v string) *MetadataUpsertOne
SetVersion sets the "version" field.
func (*MetadataUpsertOne) Update ¶
func (u *MetadataUpsertOne) Update(set func(*MetadataUpsert)) *MetadataUpsertOne
Update allows overriding fields `UPDATE` values. See the MetadataCreate.OnConflict documentation for more info.
func (*MetadataUpsertOne) UpdateComment ¶
func (u *MetadataUpsertOne) UpdateComment() *MetadataUpsertOne
UpdateComment sets the "comment" field to the value that was provided on create.
func (*MetadataUpsertOne) UpdateDate ¶
func (u *MetadataUpsertOne) UpdateDate() *MetadataUpsertOne
UpdateDate sets the "date" field to the value that was provided on create.
func (*MetadataUpsertOne) UpdateName ¶
func (u *MetadataUpsertOne) UpdateName() *MetadataUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*MetadataUpsertOne) UpdateNewValues ¶
func (u *MetadataUpsertOne) UpdateNewValues() *MetadataUpsertOne
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.Metadata.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(metadata.FieldID) }), ). Exec(ctx)
func (*MetadataUpsertOne) UpdateVersion ¶
func (u *MetadataUpsertOne) UpdateVersion() *MetadataUpsertOne
UpdateVersion sets the "version" field to the value that was provided on create.
type MutateFunc ¶
type MutateFunc = ent.MutateFunc
ent aliases to avoid import conflicts in user's code.
type Node ¶
type Node struct { // ID of the ent. ID string `json:"id,omitempty"` // Type holds the value of the "type" field. Type node.Type `json:"type,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Version holds the value of the "version" field. Version string `json:"version,omitempty"` // FileName holds the value of the "file_name" field. FileName string `json:"file_name,omitempty"` // URLHome holds the value of the "url_home" field. URLHome string `json:"url_home,omitempty"` // URLDownload holds the value of the "url_download" field. URLDownload string `json:"url_download,omitempty"` // Licenses holds the value of the "licenses" field. Licenses []string `json:"licenses,omitempty"` // LicenseConcluded holds the value of the "license_concluded" field. LicenseConcluded string `json:"license_concluded,omitempty"` // LicenseComments holds the value of the "license_comments" field. LicenseComments string `json:"license_comments,omitempty"` // Copyright holds the value of the "copyright" field. Copyright string `json:"copyright,omitempty"` // SourceInfo holds the value of the "source_info" field. SourceInfo string `json:"source_info,omitempty"` // Comment holds the value of the "comment" field. Comment string `json:"comment,omitempty"` // Summary holds the value of the "summary" field. Summary string `json:"summary,omitempty"` // Description holds the value of the "description" field. Description string `json:"description,omitempty"` // ReleaseDate holds the value of the "release_date" field. ReleaseDate time.Time `json:"release_date,omitempty"` // BuildDate holds the value of the "build_date" field. BuildDate time.Time `json:"build_date,omitempty"` // ValidUntilDate holds the value of the "valid_until_date" field. ValidUntilDate time.Time `json:"valid_until_date,omitempty"` // Attribution holds the value of the "attribution" field. Attribution []string `json:"attribution,omitempty"` // FileTypes holds the value of the "file_types" field. FileTypes []string `json:"file_types,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the NodeQuery when eager-loading is set. Edges NodeEdges `json:"edges"` // contains filtered or unexported fields }
Node is the model entity for the Node schema.
func (*Node) QueryEdgeTypes ¶
func (n *Node) QueryEdgeTypes() *EdgeTypeQuery
QueryEdgeTypes queries the "edge_types" edge of the Node entity.
func (*Node) QueryExternalReferences ¶
func (n *Node) QueryExternalReferences() *ExternalReferenceQuery
QueryExternalReferences queries the "external_references" edge of the Node entity.
func (*Node) QueryHashes ¶
func (n *Node) QueryHashes() *HashesEntryQuery
QueryHashes queries the "hashes" edge of the Node entity.
func (*Node) QueryIdentifiers ¶
func (n *Node) QueryIdentifiers() *IdentifiersEntryQuery
QueryIdentifiers queries the "identifiers" edge of the Node entity.
func (*Node) QueryNodeList ¶
func (n *Node) QueryNodeList() *NodeListQuery
QueryNodeList queries the "node_list" edge of the Node entity.
func (*Node) QueryNodes ¶
QueryNodes queries the "nodes" edge of the Node entity.
func (*Node) QueryOriginators ¶
func (n *Node) QueryOriginators() *PersonQuery
QueryOriginators queries the "originators" edge of the Node entity.
func (*Node) QueryPrimaryPurpose ¶
func (n *Node) QueryPrimaryPurpose() *PurposeQuery
QueryPrimaryPurpose queries the "primary_purpose" edge of the Node entity.
func (*Node) QuerySuppliers ¶
func (n *Node) QuerySuppliers() *PersonQuery
QuerySuppliers queries the "suppliers" edge of the Node entity.
func (*Node) Unwrap ¶
Unwrap unwraps the Node 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 (*Node) Update ¶
func (n *Node) Update() *NodeUpdateOne
Update returns a builder for updating this Node. Note that you need to call Node.Unwrap() before calling this method if this Node was returned from a transaction, and the transaction was committed or rolled back.
type NodeClient ¶
type NodeClient struct {
// contains filtered or unexported fields
}
NodeClient is a client for the Node schema.
func NewNodeClient ¶
func NewNodeClient(c config) *NodeClient
NewNodeClient returns a client for the Node from the given config.
func (*NodeClient) Create ¶
func (c *NodeClient) Create() *NodeCreate
Create returns a builder for creating a Node entity.
func (*NodeClient) CreateBulk ¶
func (c *NodeClient) CreateBulk(builders ...*NodeCreate) *NodeCreateBulk
CreateBulk returns a builder for creating a bulk of Node entities.
func (*NodeClient) Delete ¶
func (c *NodeClient) Delete() *NodeDelete
Delete returns a delete builder for Node.
func (*NodeClient) DeleteOne ¶
func (c *NodeClient) DeleteOne(n *Node) *NodeDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*NodeClient) DeleteOneID ¶
func (c *NodeClient) DeleteOneID(id string) *NodeDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*NodeClient) GetX ¶
func (c *NodeClient) GetX(ctx context.Context, id string) *Node
GetX is like Get, but panics if an error occurs.
func (*NodeClient) Intercept ¶
func (c *NodeClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `node.Intercept(f(g(h())))`.
func (*NodeClient) Interceptors ¶
func (c *NodeClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*NodeClient) MapCreateBulk ¶
func (c *NodeClient) MapCreateBulk(slice any, setFunc func(*NodeCreate, int)) *NodeCreateBulk
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 (*NodeClient) Query ¶
func (c *NodeClient) Query() *NodeQuery
Query returns a query builder for Node.
func (*NodeClient) QueryEdgeTypes ¶
func (c *NodeClient) QueryEdgeTypes(n *Node) *EdgeTypeQuery
QueryEdgeTypes queries the edge_types edge of a Node.
func (*NodeClient) QueryExternalReferences ¶
func (c *NodeClient) QueryExternalReferences(n *Node) *ExternalReferenceQuery
QueryExternalReferences queries the external_references edge of a Node.
func (*NodeClient) QueryHashes ¶
func (c *NodeClient) QueryHashes(n *Node) *HashesEntryQuery
QueryHashes queries the hashes edge of a Node.
func (*NodeClient) QueryIdentifiers ¶
func (c *NodeClient) QueryIdentifiers(n *Node) *IdentifiersEntryQuery
QueryIdentifiers queries the identifiers edge of a Node.
func (*NodeClient) QueryNodeList ¶
func (c *NodeClient) QueryNodeList(n *Node) *NodeListQuery
QueryNodeList queries the node_list edge of a Node.
func (*NodeClient) QueryNodes ¶
func (c *NodeClient) QueryNodes(n *Node) *NodeQuery
QueryNodes queries the nodes edge of a Node.
func (*NodeClient) QueryOriginators ¶
func (c *NodeClient) QueryOriginators(n *Node) *PersonQuery
QueryOriginators queries the originators edge of a Node.
func (*NodeClient) QueryPrimaryPurpose ¶
func (c *NodeClient) QueryPrimaryPurpose(n *Node) *PurposeQuery
QueryPrimaryPurpose queries the primary_purpose edge of a Node.
func (*NodeClient) QuerySuppliers ¶
func (c *NodeClient) QuerySuppliers(n *Node) *PersonQuery
QuerySuppliers queries the suppliers edge of a Node.
func (*NodeClient) Update ¶
func (c *NodeClient) Update() *NodeUpdate
Update returns an update builder for Node.
func (*NodeClient) UpdateOne ¶
func (c *NodeClient) UpdateOne(n *Node) *NodeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*NodeClient) UpdateOneID ¶
func (c *NodeClient) UpdateOneID(id string) *NodeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*NodeClient) Use ¶
func (c *NodeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `node.Hooks(f(g(h())))`.
type NodeCreate ¶
type NodeCreate struct {
// contains filtered or unexported fields
}
NodeCreate is the builder for creating a Node entity.
func (*NodeCreate) AddEdgeTypeIDs ¶
func (nc *NodeCreate) AddEdgeTypeIDs(ids ...int) *NodeCreate
AddEdgeTypeIDs adds the "edge_types" edge to the EdgeType entity by IDs.
func (*NodeCreate) AddEdgeTypes ¶
func (nc *NodeCreate) AddEdgeTypes(e ...*EdgeType) *NodeCreate
AddEdgeTypes adds the "edge_types" edges to the EdgeType entity.
func (*NodeCreate) AddExternalReferenceIDs ¶
func (nc *NodeCreate) AddExternalReferenceIDs(ids ...int) *NodeCreate
AddExternalReferenceIDs adds the "external_references" edge to the ExternalReference entity by IDs.
func (*NodeCreate) AddExternalReferences ¶
func (nc *NodeCreate) AddExternalReferences(e ...*ExternalReference) *NodeCreate
AddExternalReferences adds the "external_references" edges to the ExternalReference entity.
func (*NodeCreate) AddHashIDs ¶
func (nc *NodeCreate) AddHashIDs(ids ...int) *NodeCreate
AddHashIDs adds the "hashes" edge to the HashesEntry entity by IDs.
func (*NodeCreate) AddHashes ¶
func (nc *NodeCreate) AddHashes(h ...*HashesEntry) *NodeCreate
AddHashes adds the "hashes" edges to the HashesEntry entity.
func (*NodeCreate) AddIdentifierIDs ¶
func (nc *NodeCreate) AddIdentifierIDs(ids ...int) *NodeCreate
AddIdentifierIDs adds the "identifiers" edge to the IdentifiersEntry entity by IDs.
func (*NodeCreate) AddIdentifiers ¶
func (nc *NodeCreate) AddIdentifiers(i ...*IdentifiersEntry) *NodeCreate
AddIdentifiers adds the "identifiers" edges to the IdentifiersEntry entity.
func (*NodeCreate) AddNodeIDs ¶
func (nc *NodeCreate) AddNodeIDs(ids ...string) *NodeCreate
AddNodeIDs adds the "nodes" edge to the Node entity by IDs.
func (*NodeCreate) AddNodes ¶
func (nc *NodeCreate) AddNodes(n ...*Node) *NodeCreate
AddNodes adds the "nodes" edges to the Node entity.
func (*NodeCreate) AddOriginatorIDs ¶
func (nc *NodeCreate) AddOriginatorIDs(ids ...int) *NodeCreate
AddOriginatorIDs adds the "originators" edge to the Person entity by IDs.
func (*NodeCreate) AddOriginators ¶
func (nc *NodeCreate) AddOriginators(p ...*Person) *NodeCreate
AddOriginators adds the "originators" edges to the Person entity.
func (*NodeCreate) AddPrimaryPurpose ¶
func (nc *NodeCreate) AddPrimaryPurpose(p ...*Purpose) *NodeCreate
AddPrimaryPurpose adds the "primary_purpose" edges to the Purpose entity.
func (*NodeCreate) AddPrimaryPurposeIDs ¶
func (nc *NodeCreate) AddPrimaryPurposeIDs(ids ...int) *NodeCreate
AddPrimaryPurposeIDs adds the "primary_purpose" edge to the Purpose entity by IDs.
func (*NodeCreate) AddSupplierIDs ¶
func (nc *NodeCreate) AddSupplierIDs(ids ...int) *NodeCreate
AddSupplierIDs adds the "suppliers" edge to the Person entity by IDs.
func (*NodeCreate) AddSuppliers ¶
func (nc *NodeCreate) AddSuppliers(p ...*Person) *NodeCreate
AddSuppliers adds the "suppliers" edges to the Person entity.
func (*NodeCreate) Exec ¶
func (nc *NodeCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeCreate) ExecX ¶
func (nc *NodeCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeCreate) Mutation ¶
func (nc *NodeCreate) Mutation() *NodeMutation
Mutation returns the NodeMutation object of the builder.
func (*NodeCreate) OnConflict ¶
func (nc *NodeCreate) OnConflict(opts ...sql.ConflictOption) *NodeUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Node.Create(). SetType(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.NodeUpsert) { SetType(v+v). }). Exec(ctx)
func (*NodeCreate) OnConflictColumns ¶
func (nc *NodeCreate) OnConflictColumns(columns ...string) *NodeUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Node.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*NodeCreate) Save ¶
func (nc *NodeCreate) Save(ctx context.Context) (*Node, error)
Save creates the Node in the database.
func (*NodeCreate) SaveX ¶
func (nc *NodeCreate) SaveX(ctx context.Context) *Node
SaveX calls Save and panics if Save returns an error.
func (*NodeCreate) SetAttribution ¶
func (nc *NodeCreate) SetAttribution(s []string) *NodeCreate
SetAttribution sets the "attribution" field.
func (*NodeCreate) SetBuildDate ¶
func (nc *NodeCreate) SetBuildDate(t time.Time) *NodeCreate
SetBuildDate sets the "build_date" field.
func (*NodeCreate) SetComment ¶
func (nc *NodeCreate) SetComment(s string) *NodeCreate
SetComment sets the "comment" field.
func (*NodeCreate) SetCopyright ¶
func (nc *NodeCreate) SetCopyright(s string) *NodeCreate
SetCopyright sets the "copyright" field.
func (*NodeCreate) SetDescription ¶
func (nc *NodeCreate) SetDescription(s string) *NodeCreate
SetDescription sets the "description" field.
func (*NodeCreate) SetFileName ¶
func (nc *NodeCreate) SetFileName(s string) *NodeCreate
SetFileName sets the "file_name" field.
func (*NodeCreate) SetFileTypes ¶
func (nc *NodeCreate) SetFileTypes(s []string) *NodeCreate
SetFileTypes sets the "file_types" field.
func (*NodeCreate) SetID ¶
func (nc *NodeCreate) SetID(s string) *NodeCreate
SetID sets the "id" field.
func (*NodeCreate) SetLicenseComments ¶
func (nc *NodeCreate) SetLicenseComments(s string) *NodeCreate
SetLicenseComments sets the "license_comments" field.
func (*NodeCreate) SetLicenseConcluded ¶
func (nc *NodeCreate) SetLicenseConcluded(s string) *NodeCreate
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeCreate) SetLicenses ¶
func (nc *NodeCreate) SetLicenses(s []string) *NodeCreate
SetLicenses sets the "licenses" field.
func (*NodeCreate) SetName ¶
func (nc *NodeCreate) SetName(s string) *NodeCreate
SetName sets the "name" field.
func (*NodeCreate) SetNodeList ¶
func (nc *NodeCreate) SetNodeList(n *NodeList) *NodeCreate
SetNodeList sets the "node_list" edge to the NodeList entity.
func (*NodeCreate) SetNodeListID ¶
func (nc *NodeCreate) SetNodeListID(id int) *NodeCreate
SetNodeListID sets the "node_list" edge to the NodeList entity by ID.
func (*NodeCreate) SetReleaseDate ¶
func (nc *NodeCreate) SetReleaseDate(t time.Time) *NodeCreate
SetReleaseDate sets the "release_date" field.
func (*NodeCreate) SetSourceInfo ¶
func (nc *NodeCreate) SetSourceInfo(s string) *NodeCreate
SetSourceInfo sets the "source_info" field.
func (*NodeCreate) SetSummary ¶
func (nc *NodeCreate) SetSummary(s string) *NodeCreate
SetSummary sets the "summary" field.
func (*NodeCreate) SetType ¶
func (nc *NodeCreate) SetType(n node.Type) *NodeCreate
SetType sets the "type" field.
func (*NodeCreate) SetURLDownload ¶
func (nc *NodeCreate) SetURLDownload(s string) *NodeCreate
SetURLDownload sets the "url_download" field.
func (*NodeCreate) SetURLHome ¶
func (nc *NodeCreate) SetURLHome(s string) *NodeCreate
SetURLHome sets the "url_home" field.
func (*NodeCreate) SetValidUntilDate ¶
func (nc *NodeCreate) SetValidUntilDate(t time.Time) *NodeCreate
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeCreate) SetVersion ¶
func (nc *NodeCreate) SetVersion(s string) *NodeCreate
SetVersion sets the "version" field.
type NodeCreateBulk ¶
type NodeCreateBulk struct {
// contains filtered or unexported fields
}
NodeCreateBulk is the builder for creating many Node entities in bulk.
func (*NodeCreateBulk) Exec ¶
func (ncb *NodeCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeCreateBulk) ExecX ¶
func (ncb *NodeCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeCreateBulk) OnConflict ¶
func (ncb *NodeCreateBulk) OnConflict(opts ...sql.ConflictOption) *NodeUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Node.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.NodeUpsert) { SetType(v+v). }). Exec(ctx)
func (*NodeCreateBulk) OnConflictColumns ¶
func (ncb *NodeCreateBulk) OnConflictColumns(columns ...string) *NodeUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Node.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type NodeDelete ¶
type NodeDelete struct {
// contains filtered or unexported fields
}
NodeDelete is the builder for deleting a Node entity.
func (*NodeDelete) Exec ¶
func (nd *NodeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*NodeDelete) ExecX ¶
func (nd *NodeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*NodeDelete) Where ¶
func (nd *NodeDelete) Where(ps ...predicate.Node) *NodeDelete
Where appends a list predicates to the NodeDelete builder.
type NodeDeleteOne ¶
type NodeDeleteOne struct {
// contains filtered or unexported fields
}
NodeDeleteOne is the builder for deleting a single Node entity.
func (*NodeDeleteOne) Exec ¶
func (ndo *NodeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*NodeDeleteOne) ExecX ¶
func (ndo *NodeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeDeleteOne) Where ¶
func (ndo *NodeDeleteOne) Where(ps ...predicate.Node) *NodeDeleteOne
Where appends a list predicates to the NodeDelete builder.
type NodeEdges ¶
type NodeEdges struct { // Suppliers holds the value of the suppliers edge. Suppliers []*Person `json:"suppliers,omitempty"` // Originators holds the value of the originators edge. Originators []*Person `json:"originators,omitempty"` // ExternalReferences holds the value of the external_references edge. ExternalReferences []*ExternalReference `json:"external_references,omitempty"` // Identifiers holds the value of the identifiers edge. Identifiers []*IdentifiersEntry `json:"identifiers,omitempty"` // Hashes holds the value of the hashes edge. Hashes []*HashesEntry `json:"hashes,omitempty"` // PrimaryPurpose holds the value of the primary_purpose edge. PrimaryPurpose []*Purpose `json:"primary_purpose,omitempty"` // Nodes holds the value of the nodes edge. Nodes []*Node `json:"nodes,omitempty"` // NodeList holds the value of the node_list edge. NodeList *NodeList `json:"node_list,omitempty"` // EdgeTypes holds the value of the edge_types edge. EdgeTypes []*EdgeType `json:"edge_types,omitempty"` // contains filtered or unexported fields }
NodeEdges holds the relations/edges for other nodes in the graph.
func (NodeEdges) EdgeTypesOrErr ¶
EdgeTypesOrErr returns the EdgeTypes value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) ExternalReferencesOrErr ¶
func (e NodeEdges) ExternalReferencesOrErr() ([]*ExternalReference, error)
ExternalReferencesOrErr returns the ExternalReferences value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) HashesOrErr ¶
func (e NodeEdges) HashesOrErr() ([]*HashesEntry, error)
HashesOrErr returns the Hashes value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) IdentifiersOrErr ¶
func (e NodeEdges) IdentifiersOrErr() ([]*IdentifiersEntry, error)
IdentifiersOrErr returns the Identifiers value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) NodeListOrErr ¶
NodeListOrErr returns the NodeList value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (NodeEdges) NodesOrErr ¶
NodesOrErr returns the Nodes value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) OriginatorsOrErr ¶
OriginatorsOrErr returns the Originators value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) PrimaryPurposeOrErr ¶
PrimaryPurposeOrErr returns the PrimaryPurpose value or an error if the edge was not loaded in eager-loading.
func (NodeEdges) SuppliersOrErr ¶
SuppliersOrErr returns the Suppliers value or an error if the edge was not loaded in eager-loading.
type NodeGroupBy ¶
type NodeGroupBy struct {
// contains filtered or unexported fields
}
NodeGroupBy is the group-by builder for Node entities.
func (*NodeGroupBy) Aggregate ¶
func (ngb *NodeGroupBy) Aggregate(fns ...AggregateFunc) *NodeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*NodeGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*NodeGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*NodeGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*NodeGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*NodeGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*NodeGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*NodeGroupBy) Scan ¶
func (ngb *NodeGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*NodeGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type NodeList ¶
type NodeList struct { // ID of the ent. ID int `json:"id,omitempty"` // RootElements holds the value of the "root_elements" field. RootElements []string `json:"root_elements,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the NodeListQuery when eager-loading is set. Edges NodeListEdges `json:"edges"` // contains filtered or unexported fields }
NodeList is the model entity for the NodeList schema.
func (*NodeList) QueryDocument ¶
func (nl *NodeList) QueryDocument() *DocumentQuery
QueryDocument queries the "document" edge of the NodeList entity.
func (*NodeList) QueryNodes ¶
QueryNodes queries the "nodes" edge of the NodeList entity.
func (*NodeList) Unwrap ¶
Unwrap unwraps the NodeList 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 (*NodeList) Update ¶
func (nl *NodeList) Update() *NodeListUpdateOne
Update returns a builder for updating this NodeList. Note that you need to call NodeList.Unwrap() before calling this method if this NodeList was returned from a transaction, and the transaction was committed or rolled back.
type NodeListClient ¶
type NodeListClient struct {
// contains filtered or unexported fields
}
NodeListClient is a client for the NodeList schema.
func NewNodeListClient ¶
func NewNodeListClient(c config) *NodeListClient
NewNodeListClient returns a client for the NodeList from the given config.
func (*NodeListClient) Create ¶
func (c *NodeListClient) Create() *NodeListCreate
Create returns a builder for creating a NodeList entity.
func (*NodeListClient) CreateBulk ¶
func (c *NodeListClient) CreateBulk(builders ...*NodeListCreate) *NodeListCreateBulk
CreateBulk returns a builder for creating a bulk of NodeList entities.
func (*NodeListClient) Delete ¶
func (c *NodeListClient) Delete() *NodeListDelete
Delete returns a delete builder for NodeList.
func (*NodeListClient) DeleteOne ¶
func (c *NodeListClient) DeleteOne(nl *NodeList) *NodeListDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*NodeListClient) DeleteOneID ¶
func (c *NodeListClient) DeleteOneID(id int) *NodeListDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*NodeListClient) GetX ¶
func (c *NodeListClient) GetX(ctx context.Context, id int) *NodeList
GetX is like Get, but panics if an error occurs.
func (*NodeListClient) Hooks ¶
func (c *NodeListClient) Hooks() []Hook
Hooks returns the client hooks.
func (*NodeListClient) Intercept ¶
func (c *NodeListClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `nodelist.Intercept(f(g(h())))`.
func (*NodeListClient) Interceptors ¶
func (c *NodeListClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*NodeListClient) MapCreateBulk ¶
func (c *NodeListClient) MapCreateBulk(slice any, setFunc func(*NodeListCreate, int)) *NodeListCreateBulk
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 (*NodeListClient) Query ¶
func (c *NodeListClient) Query() *NodeListQuery
Query returns a query builder for NodeList.
func (*NodeListClient) QueryDocument ¶
func (c *NodeListClient) QueryDocument(nl *NodeList) *DocumentQuery
QueryDocument queries the document edge of a NodeList.
func (*NodeListClient) QueryNodes ¶
func (c *NodeListClient) QueryNodes(nl *NodeList) *NodeQuery
QueryNodes queries the nodes edge of a NodeList.
func (*NodeListClient) Update ¶
func (c *NodeListClient) Update() *NodeListUpdate
Update returns an update builder for NodeList.
func (*NodeListClient) UpdateOne ¶
func (c *NodeListClient) UpdateOne(nl *NodeList) *NodeListUpdateOne
UpdateOne returns an update builder for the given entity.
func (*NodeListClient) UpdateOneID ¶
func (c *NodeListClient) UpdateOneID(id int) *NodeListUpdateOne
UpdateOneID returns an update builder for the given id.
func (*NodeListClient) Use ¶
func (c *NodeListClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `nodelist.Hooks(f(g(h())))`.
type NodeListCreate ¶
type NodeListCreate struct {
// contains filtered or unexported fields
}
NodeListCreate is the builder for creating a NodeList entity.
func (*NodeListCreate) AddNodeIDs ¶
func (nlc *NodeListCreate) AddNodeIDs(ids ...string) *NodeListCreate
AddNodeIDs adds the "nodes" edge to the Node entity by IDs.
func (*NodeListCreate) AddNodes ¶
func (nlc *NodeListCreate) AddNodes(n ...*Node) *NodeListCreate
AddNodes adds the "nodes" edges to the Node entity.
func (*NodeListCreate) Exec ¶
func (nlc *NodeListCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeListCreate) ExecX ¶
func (nlc *NodeListCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListCreate) Mutation ¶
func (nlc *NodeListCreate) Mutation() *NodeListMutation
Mutation returns the NodeListMutation object of the builder.
func (*NodeListCreate) OnConflict ¶
func (nlc *NodeListCreate) OnConflict(opts ...sql.ConflictOption) *NodeListUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.NodeList.Create(). SetRootElements(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.NodeListUpsert) { SetRootElements(v+v). }). Exec(ctx)
func (*NodeListCreate) OnConflictColumns ¶
func (nlc *NodeListCreate) OnConflictColumns(columns ...string) *NodeListUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.NodeList.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*NodeListCreate) Save ¶
func (nlc *NodeListCreate) Save(ctx context.Context) (*NodeList, error)
Save creates the NodeList in the database.
func (*NodeListCreate) SaveX ¶
func (nlc *NodeListCreate) SaveX(ctx context.Context) *NodeList
SaveX calls Save and panics if Save returns an error.
func (*NodeListCreate) SetDocument ¶
func (nlc *NodeListCreate) SetDocument(d *Document) *NodeListCreate
SetDocument sets the "document" edge to the Document entity.
func (*NodeListCreate) SetDocumentID ¶
func (nlc *NodeListCreate) SetDocumentID(id int) *NodeListCreate
SetDocumentID sets the "document" edge to the Document entity by ID.
func (*NodeListCreate) SetNillableDocumentID ¶
func (nlc *NodeListCreate) SetNillableDocumentID(id *int) *NodeListCreate
SetNillableDocumentID sets the "document" edge to the Document entity by ID if the given value is not nil.
func (*NodeListCreate) SetRootElements ¶
func (nlc *NodeListCreate) SetRootElements(s []string) *NodeListCreate
SetRootElements sets the "root_elements" field.
type NodeListCreateBulk ¶
type NodeListCreateBulk struct {
// contains filtered or unexported fields
}
NodeListCreateBulk is the builder for creating many NodeList entities in bulk.
func (*NodeListCreateBulk) Exec ¶
func (nlcb *NodeListCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeListCreateBulk) ExecX ¶
func (nlcb *NodeListCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListCreateBulk) OnConflict ¶
func (nlcb *NodeListCreateBulk) OnConflict(opts ...sql.ConflictOption) *NodeListUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.NodeList.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.NodeListUpsert) { SetRootElements(v+v). }). Exec(ctx)
func (*NodeListCreateBulk) OnConflictColumns ¶
func (nlcb *NodeListCreateBulk) OnConflictColumns(columns ...string) *NodeListUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.NodeList.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type NodeListDelete ¶
type NodeListDelete struct {
// contains filtered or unexported fields
}
NodeListDelete is the builder for deleting a NodeList entity.
func (*NodeListDelete) Exec ¶
func (nld *NodeListDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*NodeListDelete) ExecX ¶
func (nld *NodeListDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*NodeListDelete) Where ¶
func (nld *NodeListDelete) Where(ps ...predicate.NodeList) *NodeListDelete
Where appends a list predicates to the NodeListDelete builder.
type NodeListDeleteOne ¶
type NodeListDeleteOne struct {
// contains filtered or unexported fields
}
NodeListDeleteOne is the builder for deleting a single NodeList entity.
func (*NodeListDeleteOne) Exec ¶
func (nldo *NodeListDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*NodeListDeleteOne) ExecX ¶
func (nldo *NodeListDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListDeleteOne) Where ¶
func (nldo *NodeListDeleteOne) Where(ps ...predicate.NodeList) *NodeListDeleteOne
Where appends a list predicates to the NodeListDelete builder.
type NodeListEdges ¶
type NodeListEdges struct { // Nodes holds the value of the nodes edge. Nodes []*Node `json:"nodes,omitempty"` // Document holds the value of the document edge. Document *Document `json:"document,omitempty"` // contains filtered or unexported fields }
NodeListEdges holds the relations/edges for other nodes in the graph.
func (NodeListEdges) DocumentOrErr ¶
func (e NodeListEdges) DocumentOrErr() (*Document, error)
DocumentOrErr returns the Document value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (NodeListEdges) NodesOrErr ¶
func (e NodeListEdges) NodesOrErr() ([]*Node, error)
NodesOrErr returns the Nodes value or an error if the edge was not loaded in eager-loading.
type NodeListGroupBy ¶
type NodeListGroupBy struct {
// contains filtered or unexported fields
}
NodeListGroupBy is the group-by builder for NodeList entities.
func (*NodeListGroupBy) Aggregate ¶
func (nlgb *NodeListGroupBy) Aggregate(fns ...AggregateFunc) *NodeListGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*NodeListGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*NodeListGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*NodeListGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*NodeListGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*NodeListGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*NodeListGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*NodeListGroupBy) Scan ¶
func (nlgb *NodeListGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*NodeListGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type NodeListMutation ¶
type NodeListMutation struct {
// contains filtered or unexported fields
}
NodeListMutation represents an operation that mutates the NodeList nodes in the graph.
func (*NodeListMutation) AddField ¶
func (m *NodeListMutation) 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 (*NodeListMutation) AddNodeIDs ¶
func (m *NodeListMutation) AddNodeIDs(ids ...string)
AddNodeIDs adds the "nodes" edge to the Node entity by ids.
func (*NodeListMutation) AddedEdges ¶
func (m *NodeListMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*NodeListMutation) AddedField ¶
func (m *NodeListMutation) 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 (*NodeListMutation) AddedFields ¶
func (m *NodeListMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*NodeListMutation) AddedIDs ¶
func (m *NodeListMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*NodeListMutation) AppendRootElements ¶
func (m *NodeListMutation) AppendRootElements(s []string)
AppendRootElements adds s to the "root_elements" field.
func (*NodeListMutation) AppendedRootElements ¶
func (m *NodeListMutation) AppendedRootElements() ([]string, bool)
AppendedRootElements returns the list of values that were appended to the "root_elements" field in this mutation.
func (*NodeListMutation) ClearDocument ¶
func (m *NodeListMutation) ClearDocument()
ClearDocument clears the "document" edge to the Document entity.
func (*NodeListMutation) ClearEdge ¶
func (m *NodeListMutation) 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 (*NodeListMutation) ClearField ¶
func (m *NodeListMutation) 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 (*NodeListMutation) ClearNodes ¶
func (m *NodeListMutation) ClearNodes()
ClearNodes clears the "nodes" edge to the Node entity.
func (*NodeListMutation) ClearedEdges ¶
func (m *NodeListMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*NodeListMutation) ClearedFields ¶
func (m *NodeListMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (NodeListMutation) Client ¶
func (m NodeListMutation) 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 (*NodeListMutation) DocumentCleared ¶
func (m *NodeListMutation) DocumentCleared() bool
DocumentCleared reports if the "document" edge to the Document entity was cleared.
func (*NodeListMutation) DocumentID ¶
func (m *NodeListMutation) DocumentID() (id int, exists bool)
DocumentID returns the "document" edge ID in the mutation.
func (*NodeListMutation) DocumentIDs ¶
func (m *NodeListMutation) DocumentIDs() (ids []int)
DocumentIDs returns the "document" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use DocumentID instead. It exists only for internal usage by the builders.
func (*NodeListMutation) EdgeCleared ¶
func (m *NodeListMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*NodeListMutation) Field ¶
func (m *NodeListMutation) 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 (*NodeListMutation) FieldCleared ¶
func (m *NodeListMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*NodeListMutation) Fields ¶
func (m *NodeListMutation) 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 (*NodeListMutation) ID ¶
func (m *NodeListMutation) 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 (*NodeListMutation) IDs ¶
func (m *NodeListMutation) 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 (*NodeListMutation) NodesCleared ¶
func (m *NodeListMutation) NodesCleared() bool
NodesCleared reports if the "nodes" edge to the Node entity was cleared.
func (*NodeListMutation) NodesIDs ¶
func (m *NodeListMutation) NodesIDs() (ids []string)
NodesIDs returns the "nodes" edge IDs in the mutation.
func (*NodeListMutation) 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 (*NodeListMutation) OldRootElements ¶
func (m *NodeListMutation) OldRootElements(ctx context.Context) (v []string, err error)
OldRootElements returns the old "root_elements" field's value of the NodeList entity. If the NodeList 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 (*NodeListMutation) RemoveNodeIDs ¶
func (m *NodeListMutation) RemoveNodeIDs(ids ...string)
RemoveNodeIDs removes the "nodes" edge to the Node entity by IDs.
func (*NodeListMutation) RemovedEdges ¶
func (m *NodeListMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*NodeListMutation) RemovedIDs ¶
func (m *NodeListMutation) 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 (*NodeListMutation) RemovedNodesIDs ¶
func (m *NodeListMutation) RemovedNodesIDs() (ids []string)
RemovedNodes returns the removed IDs of the "nodes" edge to the Node entity.
func (*NodeListMutation) ResetDocument ¶
func (m *NodeListMutation) ResetDocument()
ResetDocument resets all changes to the "document" edge.
func (*NodeListMutation) ResetEdge ¶
func (m *NodeListMutation) 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 (*NodeListMutation) ResetField ¶
func (m *NodeListMutation) 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 (*NodeListMutation) ResetNodes ¶
func (m *NodeListMutation) ResetNodes()
ResetNodes resets all changes to the "nodes" edge.
func (*NodeListMutation) ResetRootElements ¶
func (m *NodeListMutation) ResetRootElements()
ResetRootElements resets all changes to the "root_elements" field.
func (*NodeListMutation) RootElements ¶
func (m *NodeListMutation) RootElements() (r []string, exists bool)
RootElements returns the value of the "root_elements" field in the mutation.
func (*NodeListMutation) SetDocumentID ¶
func (m *NodeListMutation) SetDocumentID(id int)
SetDocumentID sets the "document" edge to the Document entity by id.
func (*NodeListMutation) SetField ¶
func (m *NodeListMutation) 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 (*NodeListMutation) SetOp ¶
func (m *NodeListMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*NodeListMutation) SetRootElements ¶
func (m *NodeListMutation) SetRootElements(s []string)
SetRootElements sets the "root_elements" field.
func (NodeListMutation) Tx ¶
func (m NodeListMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*NodeListMutation) Type ¶
func (m *NodeListMutation) Type() string
Type returns the node type of this mutation (NodeList).
func (*NodeListMutation) Where ¶
func (m *NodeListMutation) Where(ps ...predicate.NodeList)
Where appends a list predicates to the NodeListMutation builder.
func (*NodeListMutation) WhereP ¶
func (m *NodeListMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the NodeListMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type NodeListQuery ¶
type NodeListQuery struct {
// contains filtered or unexported fields
}
NodeListQuery is the builder for querying NodeList entities.
func (*NodeListQuery) Aggregate ¶
func (nlq *NodeListQuery) Aggregate(fns ...AggregateFunc) *NodeListSelect
Aggregate returns a NodeListSelect configured with the given aggregations.
func (*NodeListQuery) All ¶
func (nlq *NodeListQuery) All(ctx context.Context) ([]*NodeList, error)
All executes the query and returns a list of NodeLists.
func (*NodeListQuery) AllX ¶
func (nlq *NodeListQuery) AllX(ctx context.Context) []*NodeList
AllX is like All, but panics if an error occurs.
func (*NodeListQuery) Clone ¶
func (nlq *NodeListQuery) Clone() *NodeListQuery
Clone returns a duplicate of the NodeListQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*NodeListQuery) Count ¶
func (nlq *NodeListQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*NodeListQuery) CountX ¶
func (nlq *NodeListQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*NodeListQuery) Exist ¶
func (nlq *NodeListQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*NodeListQuery) ExistX ¶
func (nlq *NodeListQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*NodeListQuery) First ¶
func (nlq *NodeListQuery) First(ctx context.Context) (*NodeList, error)
First returns the first NodeList entity from the query. Returns a *NotFoundError when no NodeList was found.
func (*NodeListQuery) FirstID ¶
func (nlq *NodeListQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first NodeList ID from the query. Returns a *NotFoundError when no NodeList ID was found.
func (*NodeListQuery) FirstIDX ¶
func (nlq *NodeListQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*NodeListQuery) FirstX ¶
func (nlq *NodeListQuery) FirstX(ctx context.Context) *NodeList
FirstX is like First, but panics if an error occurs.
func (*NodeListQuery) GroupBy ¶
func (nlq *NodeListQuery) GroupBy(field string, fields ...string) *NodeListGroupBy
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 { RootElements []string `json:"root_elements,omitempty"` Count int `json:"count,omitempty"` } client.NodeList.Query(). GroupBy(nodelist.FieldRootElements). Aggregate(ent.Count()). Scan(ctx, &v)
func (*NodeListQuery) IDs ¶
func (nlq *NodeListQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of NodeList IDs.
func (*NodeListQuery) IDsX ¶
func (nlq *NodeListQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*NodeListQuery) Limit ¶
func (nlq *NodeListQuery) Limit(limit int) *NodeListQuery
Limit the number of records to be returned by this query.
func (*NodeListQuery) Offset ¶
func (nlq *NodeListQuery) Offset(offset int) *NodeListQuery
Offset to start from.
func (*NodeListQuery) Only ¶
func (nlq *NodeListQuery) Only(ctx context.Context) (*NodeList, error)
Only returns a single NodeList entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one NodeList entity is found. Returns a *NotFoundError when no NodeList entities are found.
func (*NodeListQuery) OnlyID ¶
func (nlq *NodeListQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only NodeList ID in the query. Returns a *NotSingularError when more than one NodeList ID is found. Returns a *NotFoundError when no entities are found.
func (*NodeListQuery) OnlyIDX ¶
func (nlq *NodeListQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*NodeListQuery) OnlyX ¶
func (nlq *NodeListQuery) OnlyX(ctx context.Context) *NodeList
OnlyX is like Only, but panics if an error occurs.
func (*NodeListQuery) Order ¶
func (nlq *NodeListQuery) Order(o ...nodelist.OrderOption) *NodeListQuery
Order specifies how the records should be ordered.
func (*NodeListQuery) QueryDocument ¶
func (nlq *NodeListQuery) QueryDocument() *DocumentQuery
QueryDocument chains the current query on the "document" edge.
func (*NodeListQuery) QueryNodes ¶
func (nlq *NodeListQuery) QueryNodes() *NodeQuery
QueryNodes chains the current query on the "nodes" edge.
func (*NodeListQuery) Select ¶
func (nlq *NodeListQuery) Select(fields ...string) *NodeListSelect
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 { RootElements []string `json:"root_elements,omitempty"` } client.NodeList.Query(). Select(nodelist.FieldRootElements). Scan(ctx, &v)
func (*NodeListQuery) Unique ¶
func (nlq *NodeListQuery) Unique(unique bool) *NodeListQuery
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 (*NodeListQuery) Where ¶
func (nlq *NodeListQuery) Where(ps ...predicate.NodeList) *NodeListQuery
Where adds a new predicate for the NodeListQuery builder.
func (*NodeListQuery) WithDocument ¶
func (nlq *NodeListQuery) WithDocument(opts ...func(*DocumentQuery)) *NodeListQuery
WithDocument tells the query-builder to eager-load the nodes that are connected to the "document" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeListQuery) WithNodes ¶
func (nlq *NodeListQuery) WithNodes(opts ...func(*NodeQuery)) *NodeListQuery
WithNodes tells the query-builder to eager-load the nodes that are connected to the "nodes" edge. The optional arguments are used to configure the query builder of the edge.
type NodeListSelect ¶
type NodeListSelect struct { *NodeListQuery // contains filtered or unexported fields }
NodeListSelect is the builder for selecting fields of NodeList entities.
func (*NodeListSelect) Aggregate ¶
func (nls *NodeListSelect) Aggregate(fns ...AggregateFunc) *NodeListSelect
Aggregate adds the given aggregation functions to the selector query.
func (*NodeListSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*NodeListSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*NodeListSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*NodeListSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*NodeListSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*NodeListSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*NodeListSelect) Scan ¶
func (nls *NodeListSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*NodeListSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type NodeListUpdate ¶
type NodeListUpdate struct {
// contains filtered or unexported fields
}
NodeListUpdate is the builder for updating NodeList entities.
func (*NodeListUpdate) AddNodeIDs ¶
func (nlu *NodeListUpdate) AddNodeIDs(ids ...string) *NodeListUpdate
AddNodeIDs adds the "nodes" edge to the Node entity by IDs.
func (*NodeListUpdate) AddNodes ¶
func (nlu *NodeListUpdate) AddNodes(n ...*Node) *NodeListUpdate
AddNodes adds the "nodes" edges to the Node entity.
func (*NodeListUpdate) AppendRootElements ¶
func (nlu *NodeListUpdate) AppendRootElements(s []string) *NodeListUpdate
AppendRootElements appends s to the "root_elements" field.
func (*NodeListUpdate) ClearDocument ¶
func (nlu *NodeListUpdate) ClearDocument() *NodeListUpdate
ClearDocument clears the "document" edge to the Document entity.
func (*NodeListUpdate) ClearNodes ¶
func (nlu *NodeListUpdate) ClearNodes() *NodeListUpdate
ClearNodes clears all "nodes" edges to the Node entity.
func (*NodeListUpdate) Exec ¶
func (nlu *NodeListUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeListUpdate) ExecX ¶
func (nlu *NodeListUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListUpdate) Mutation ¶
func (nlu *NodeListUpdate) Mutation() *NodeListMutation
Mutation returns the NodeListMutation object of the builder.
func (*NodeListUpdate) RemoveNodeIDs ¶
func (nlu *NodeListUpdate) RemoveNodeIDs(ids ...string) *NodeListUpdate
RemoveNodeIDs removes the "nodes" edge to Node entities by IDs.
func (*NodeListUpdate) RemoveNodes ¶
func (nlu *NodeListUpdate) RemoveNodes(n ...*Node) *NodeListUpdate
RemoveNodes removes "nodes" edges to Node entities.
func (*NodeListUpdate) Save ¶
func (nlu *NodeListUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*NodeListUpdate) SaveX ¶
func (nlu *NodeListUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*NodeListUpdate) SetDocument ¶
func (nlu *NodeListUpdate) SetDocument(d *Document) *NodeListUpdate
SetDocument sets the "document" edge to the Document entity.
func (*NodeListUpdate) SetDocumentID ¶
func (nlu *NodeListUpdate) SetDocumentID(id int) *NodeListUpdate
SetDocumentID sets the "document" edge to the Document entity by ID.
func (*NodeListUpdate) SetNillableDocumentID ¶
func (nlu *NodeListUpdate) SetNillableDocumentID(id *int) *NodeListUpdate
SetNillableDocumentID sets the "document" edge to the Document entity by ID if the given value is not nil.
func (*NodeListUpdate) SetRootElements ¶
func (nlu *NodeListUpdate) SetRootElements(s []string) *NodeListUpdate
SetRootElements sets the "root_elements" field.
func (*NodeListUpdate) Where ¶
func (nlu *NodeListUpdate) Where(ps ...predicate.NodeList) *NodeListUpdate
Where appends a list predicates to the NodeListUpdate builder.
type NodeListUpdateOne ¶
type NodeListUpdateOne struct {
// contains filtered or unexported fields
}
NodeListUpdateOne is the builder for updating a single NodeList entity.
func (*NodeListUpdateOne) AddNodeIDs ¶
func (nluo *NodeListUpdateOne) AddNodeIDs(ids ...string) *NodeListUpdateOne
AddNodeIDs adds the "nodes" edge to the Node entity by IDs.
func (*NodeListUpdateOne) AddNodes ¶
func (nluo *NodeListUpdateOne) AddNodes(n ...*Node) *NodeListUpdateOne
AddNodes adds the "nodes" edges to the Node entity.
func (*NodeListUpdateOne) AppendRootElements ¶
func (nluo *NodeListUpdateOne) AppendRootElements(s []string) *NodeListUpdateOne
AppendRootElements appends s to the "root_elements" field.
func (*NodeListUpdateOne) ClearDocument ¶
func (nluo *NodeListUpdateOne) ClearDocument() *NodeListUpdateOne
ClearDocument clears the "document" edge to the Document entity.
func (*NodeListUpdateOne) ClearNodes ¶
func (nluo *NodeListUpdateOne) ClearNodes() *NodeListUpdateOne
ClearNodes clears all "nodes" edges to the Node entity.
func (*NodeListUpdateOne) Exec ¶
func (nluo *NodeListUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*NodeListUpdateOne) ExecX ¶
func (nluo *NodeListUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListUpdateOne) Mutation ¶
func (nluo *NodeListUpdateOne) Mutation() *NodeListMutation
Mutation returns the NodeListMutation object of the builder.
func (*NodeListUpdateOne) RemoveNodeIDs ¶
func (nluo *NodeListUpdateOne) RemoveNodeIDs(ids ...string) *NodeListUpdateOne
RemoveNodeIDs removes the "nodes" edge to Node entities by IDs.
func (*NodeListUpdateOne) RemoveNodes ¶
func (nluo *NodeListUpdateOne) RemoveNodes(n ...*Node) *NodeListUpdateOne
RemoveNodes removes "nodes" edges to Node entities.
func (*NodeListUpdateOne) Save ¶
func (nluo *NodeListUpdateOne) Save(ctx context.Context) (*NodeList, error)
Save executes the query and returns the updated NodeList entity.
func (*NodeListUpdateOne) SaveX ¶
func (nluo *NodeListUpdateOne) SaveX(ctx context.Context) *NodeList
SaveX is like Save, but panics if an error occurs.
func (*NodeListUpdateOne) Select ¶
func (nluo *NodeListUpdateOne) Select(field string, fields ...string) *NodeListUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*NodeListUpdateOne) SetDocument ¶
func (nluo *NodeListUpdateOne) SetDocument(d *Document) *NodeListUpdateOne
SetDocument sets the "document" edge to the Document entity.
func (*NodeListUpdateOne) SetDocumentID ¶
func (nluo *NodeListUpdateOne) SetDocumentID(id int) *NodeListUpdateOne
SetDocumentID sets the "document" edge to the Document entity by ID.
func (*NodeListUpdateOne) SetNillableDocumentID ¶
func (nluo *NodeListUpdateOne) SetNillableDocumentID(id *int) *NodeListUpdateOne
SetNillableDocumentID sets the "document" edge to the Document entity by ID if the given value is not nil.
func (*NodeListUpdateOne) SetRootElements ¶
func (nluo *NodeListUpdateOne) SetRootElements(s []string) *NodeListUpdateOne
SetRootElements sets the "root_elements" field.
func (*NodeListUpdateOne) Where ¶
func (nluo *NodeListUpdateOne) Where(ps ...predicate.NodeList) *NodeListUpdateOne
Where appends a list predicates to the NodeListUpdate builder.
type NodeListUpsert ¶
NodeListUpsert is the "OnConflict" setter.
func (*NodeListUpsert) SetRootElements ¶
func (u *NodeListUpsert) SetRootElements(v []string) *NodeListUpsert
SetRootElements sets the "root_elements" field.
func (*NodeListUpsert) UpdateRootElements ¶
func (u *NodeListUpsert) UpdateRootElements() *NodeListUpsert
UpdateRootElements sets the "root_elements" field to the value that was provided on create.
type NodeListUpsertBulk ¶
type NodeListUpsertBulk struct {
// contains filtered or unexported fields
}
NodeListUpsertBulk is the builder for "upsert"-ing a bulk of NodeList nodes.
func (*NodeListUpsertBulk) DoNothing ¶
func (u *NodeListUpsertBulk) DoNothing() *NodeListUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*NodeListUpsertBulk) Exec ¶
func (u *NodeListUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeListUpsertBulk) ExecX ¶
func (u *NodeListUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListUpsertBulk) Ignore ¶
func (u *NodeListUpsertBulk) Ignore() *NodeListUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.NodeList.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*NodeListUpsertBulk) SetRootElements ¶
func (u *NodeListUpsertBulk) SetRootElements(v []string) *NodeListUpsertBulk
SetRootElements sets the "root_elements" field.
func (*NodeListUpsertBulk) Update ¶
func (u *NodeListUpsertBulk) Update(set func(*NodeListUpsert)) *NodeListUpsertBulk
Update allows overriding fields `UPDATE` values. See the NodeListCreateBulk.OnConflict documentation for more info.
func (*NodeListUpsertBulk) UpdateNewValues ¶
func (u *NodeListUpsertBulk) UpdateNewValues() *NodeListUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.NodeList.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*NodeListUpsertBulk) UpdateRootElements ¶
func (u *NodeListUpsertBulk) UpdateRootElements() *NodeListUpsertBulk
UpdateRootElements sets the "root_elements" field to the value that was provided on create.
type NodeListUpsertOne ¶
type NodeListUpsertOne struct {
// contains filtered or unexported fields
}
NodeListUpsertOne is the builder for "upsert"-ing
one NodeList node.
func (*NodeListUpsertOne) DoNothing ¶
func (u *NodeListUpsertOne) DoNothing() *NodeListUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*NodeListUpsertOne) Exec ¶
func (u *NodeListUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeListUpsertOne) ExecX ¶
func (u *NodeListUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeListUpsertOne) ID ¶
func (u *NodeListUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*NodeListUpsertOne) IDX ¶
func (u *NodeListUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*NodeListUpsertOne) Ignore ¶
func (u *NodeListUpsertOne) Ignore() *NodeListUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.NodeList.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*NodeListUpsertOne) SetRootElements ¶
func (u *NodeListUpsertOne) SetRootElements(v []string) *NodeListUpsertOne
SetRootElements sets the "root_elements" field.
func (*NodeListUpsertOne) Update ¶
func (u *NodeListUpsertOne) Update(set func(*NodeListUpsert)) *NodeListUpsertOne
Update allows overriding fields `UPDATE` values. See the NodeListCreate.OnConflict documentation for more info.
func (*NodeListUpsertOne) UpdateNewValues ¶
func (u *NodeListUpsertOne) UpdateNewValues() *NodeListUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.NodeList.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*NodeListUpsertOne) UpdateRootElements ¶
func (u *NodeListUpsertOne) UpdateRootElements() *NodeListUpsertOne
UpdateRootElements sets the "root_elements" field to the value that was provided on create.
type NodeMutation ¶
type NodeMutation struct {
// contains filtered or unexported fields
}
NodeMutation represents an operation that mutates the Node nodes in the graph.
func (*NodeMutation) AddEdgeTypeIDs ¶
func (m *NodeMutation) AddEdgeTypeIDs(ids ...int)
AddEdgeTypeIDs adds the "edge_types" edge to the EdgeType entity by ids.
func (*NodeMutation) AddExternalReferenceIDs ¶
func (m *NodeMutation) AddExternalReferenceIDs(ids ...int)
AddExternalReferenceIDs adds the "external_references" edge to the ExternalReference entity by ids.
func (*NodeMutation) AddField ¶
func (m *NodeMutation) 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 (*NodeMutation) AddHashIDs ¶
func (m *NodeMutation) AddHashIDs(ids ...int)
AddHashIDs adds the "hashes" edge to the HashesEntry entity by ids.
func (*NodeMutation) AddIdentifierIDs ¶
func (m *NodeMutation) AddIdentifierIDs(ids ...int)
AddIdentifierIDs adds the "identifiers" edge to the IdentifiersEntry entity by ids.
func (*NodeMutation) AddNodeIDs ¶
func (m *NodeMutation) AddNodeIDs(ids ...string)
AddNodeIDs adds the "nodes" edge to the Node entity by ids.
func (*NodeMutation) AddOriginatorIDs ¶
func (m *NodeMutation) AddOriginatorIDs(ids ...int)
AddOriginatorIDs adds the "originators" edge to the Person entity by ids.
func (*NodeMutation) AddPrimaryPurposeIDs ¶
func (m *NodeMutation) AddPrimaryPurposeIDs(ids ...int)
AddPrimaryPurposeIDs adds the "primary_purpose" edge to the Purpose entity by ids.
func (*NodeMutation) AddSupplierIDs ¶
func (m *NodeMutation) AddSupplierIDs(ids ...int)
AddSupplierIDs adds the "suppliers" edge to the Person entity by ids.
func (*NodeMutation) AddedEdges ¶
func (m *NodeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*NodeMutation) AddedField ¶
func (m *NodeMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was 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 (*NodeMutation) AddedFields ¶
func (m *NodeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*NodeMutation) AddedIDs ¶
func (m *NodeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*NodeMutation) AppendAttribution ¶
func (m *NodeMutation) AppendAttribution(s []string)
AppendAttribution adds s to the "attribution" field.
func (*NodeMutation) AppendFileTypes ¶
func (m *NodeMutation) AppendFileTypes(s []string)
AppendFileTypes adds s to the "file_types" field.
func (*NodeMutation) AppendLicenses ¶
func (m *NodeMutation) AppendLicenses(s []string)
AppendLicenses adds s to the "licenses" field.
func (*NodeMutation) AppendedAttribution ¶
func (m *NodeMutation) AppendedAttribution() ([]string, bool)
AppendedAttribution returns the list of values that were appended to the "attribution" field in this mutation.
func (*NodeMutation) AppendedFileTypes ¶
func (m *NodeMutation) AppendedFileTypes() ([]string, bool)
AppendedFileTypes returns the list of values that were appended to the "file_types" field in this mutation.
func (*NodeMutation) AppendedLicenses ¶
func (m *NodeMutation) AppendedLicenses() ([]string, bool)
AppendedLicenses returns the list of values that were appended to the "licenses" field in this mutation.
func (*NodeMutation) Attribution ¶
func (m *NodeMutation) Attribution() (r []string, exists bool)
Attribution returns the value of the "attribution" field in the mutation.
func (*NodeMutation) BuildDate ¶
func (m *NodeMutation) BuildDate() (r time.Time, exists bool)
BuildDate returns the value of the "build_date" field in the mutation.
func (*NodeMutation) ClearEdge ¶
func (m *NodeMutation) 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 (*NodeMutation) ClearEdgeTypes ¶
func (m *NodeMutation) ClearEdgeTypes()
ClearEdgeTypes clears the "edge_types" edge to the EdgeType entity.
func (*NodeMutation) ClearExternalReferences ¶
func (m *NodeMutation) ClearExternalReferences()
ClearExternalReferences clears the "external_references" edge to the ExternalReference entity.
func (*NodeMutation) ClearField ¶
func (m *NodeMutation) 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 (*NodeMutation) ClearHashes ¶
func (m *NodeMutation) ClearHashes()
ClearHashes clears the "hashes" edge to the HashesEntry entity.
func (*NodeMutation) ClearIdentifiers ¶
func (m *NodeMutation) ClearIdentifiers()
ClearIdentifiers clears the "identifiers" edge to the IdentifiersEntry entity.
func (*NodeMutation) ClearNodeList ¶
func (m *NodeMutation) ClearNodeList()
ClearNodeList clears the "node_list" edge to the NodeList entity.
func (*NodeMutation) ClearNodes ¶
func (m *NodeMutation) ClearNodes()
ClearNodes clears the "nodes" edge to the Node entity.
func (*NodeMutation) ClearOriginators ¶
func (m *NodeMutation) ClearOriginators()
ClearOriginators clears the "originators" edge to the Person entity.
func (*NodeMutation) ClearPrimaryPurpose ¶
func (m *NodeMutation) ClearPrimaryPurpose()
ClearPrimaryPurpose clears the "primary_purpose" edge to the Purpose entity.
func (*NodeMutation) ClearSuppliers ¶
func (m *NodeMutation) ClearSuppliers()
ClearSuppliers clears the "suppliers" edge to the Person entity.
func (*NodeMutation) ClearedEdges ¶
func (m *NodeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*NodeMutation) ClearedFields ¶
func (m *NodeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (NodeMutation) Client ¶
func (m NodeMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*NodeMutation) Comment ¶
func (m *NodeMutation) Comment() (r string, exists bool)
Comment returns the value of the "comment" field in the mutation.
func (*NodeMutation) Copyright ¶
func (m *NodeMutation) Copyright() (r string, exists bool)
Copyright returns the value of the "copyright" field in the mutation.
func (*NodeMutation) Description ¶
func (m *NodeMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*NodeMutation) EdgeCleared ¶
func (m *NodeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*NodeMutation) EdgeTypesCleared ¶
func (m *NodeMutation) EdgeTypesCleared() bool
EdgeTypesCleared reports if the "edge_types" edge to the EdgeType entity was cleared.
func (*NodeMutation) EdgeTypesIDs ¶
func (m *NodeMutation) EdgeTypesIDs() (ids []int)
EdgeTypesIDs returns the "edge_types" edge IDs in the mutation.
func (*NodeMutation) ExternalReferencesCleared ¶
func (m *NodeMutation) ExternalReferencesCleared() bool
ExternalReferencesCleared reports if the "external_references" edge to the ExternalReference entity was cleared.
func (*NodeMutation) ExternalReferencesIDs ¶
func (m *NodeMutation) ExternalReferencesIDs() (ids []int)
ExternalReferencesIDs returns the "external_references" edge IDs in the mutation.
func (*NodeMutation) Field ¶
func (m *NodeMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*NodeMutation) FieldCleared ¶
func (m *NodeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*NodeMutation) Fields ¶
func (m *NodeMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*NodeMutation) FileName ¶
func (m *NodeMutation) FileName() (r string, exists bool)
FileName returns the value of the "file_name" field in the mutation.
func (*NodeMutation) FileTypes ¶
func (m *NodeMutation) FileTypes() (r []string, exists bool)
FileTypes returns the value of the "file_types" field in the mutation.
func (*NodeMutation) GetType ¶
func (m *NodeMutation) GetType() (r node.Type, exists bool)
GetType returns the value of the "type" field in the mutation.
func (*NodeMutation) HashesCleared ¶
func (m *NodeMutation) HashesCleared() bool
HashesCleared reports if the "hashes" edge to the HashesEntry entity was cleared.
func (*NodeMutation) HashesIDs ¶
func (m *NodeMutation) HashesIDs() (ids []int)
HashesIDs returns the "hashes" edge IDs in the mutation.
func (*NodeMutation) ID ¶
func (m *NodeMutation) ID() (id string, 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 (*NodeMutation) IDs ¶
func (m *NodeMutation) IDs(ctx context.Context) ([]string, 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 (*NodeMutation) IdentifiersCleared ¶
func (m *NodeMutation) IdentifiersCleared() bool
IdentifiersCleared reports if the "identifiers" edge to the IdentifiersEntry entity was cleared.
func (*NodeMutation) IdentifiersIDs ¶
func (m *NodeMutation) IdentifiersIDs() (ids []int)
IdentifiersIDs returns the "identifiers" edge IDs in the mutation.
func (*NodeMutation) LicenseComments ¶
func (m *NodeMutation) LicenseComments() (r string, exists bool)
LicenseComments returns the value of the "license_comments" field in the mutation.
func (*NodeMutation) LicenseConcluded ¶
func (m *NodeMutation) LicenseConcluded() (r string, exists bool)
LicenseConcluded returns the value of the "license_concluded" field in the mutation.
func (*NodeMutation) Licenses ¶
func (m *NodeMutation) Licenses() (r []string, exists bool)
Licenses returns the value of the "licenses" field in the mutation.
func (*NodeMutation) Name ¶
func (m *NodeMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*NodeMutation) NodeListCleared ¶
func (m *NodeMutation) NodeListCleared() bool
NodeListCleared reports if the "node_list" edge to the NodeList entity was cleared.
func (*NodeMutation) NodeListID ¶
func (m *NodeMutation) NodeListID() (id int, exists bool)
NodeListID returns the "node_list" edge ID in the mutation.
func (*NodeMutation) NodeListIDs ¶
func (m *NodeMutation) NodeListIDs() (ids []int)
NodeListIDs returns the "node_list" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use NodeListID instead. It exists only for internal usage by the builders.
func (*NodeMutation) NodesCleared ¶
func (m *NodeMutation) NodesCleared() bool
NodesCleared reports if the "nodes" edge to the Node entity was cleared.
func (*NodeMutation) NodesIDs ¶
func (m *NodeMutation) NodesIDs() (ids []string)
NodesIDs returns the "nodes" edge IDs in the mutation.
func (*NodeMutation) OldAttribution ¶
func (m *NodeMutation) OldAttribution(ctx context.Context) (v []string, err error)
OldAttribution returns the old "attribution" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldBuildDate ¶
OldBuildDate returns the old "build_date" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldComment ¶
func (m *NodeMutation) OldComment(ctx context.Context) (v string, err error)
OldComment returns the old "comment" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldCopyright ¶
func (m *NodeMutation) OldCopyright(ctx context.Context) (v string, err error)
OldCopyright returns the old "copyright" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldDescription ¶
func (m *NodeMutation) OldDescription(ctx context.Context) (v string, err error)
OldDescription returns the old "description" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*NodeMutation) OldFileName ¶
func (m *NodeMutation) OldFileName(ctx context.Context) (v string, err error)
OldFileName returns the old "file_name" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldFileTypes ¶
func (m *NodeMutation) OldFileTypes(ctx context.Context) (v []string, err error)
OldFileTypes returns the old "file_types" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldLicenseComments ¶
func (m *NodeMutation) OldLicenseComments(ctx context.Context) (v string, err error)
OldLicenseComments returns the old "license_comments" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldLicenseConcluded ¶
func (m *NodeMutation) OldLicenseConcluded(ctx context.Context) (v string, err error)
OldLicenseConcluded returns the old "license_concluded" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldLicenses ¶
func (m *NodeMutation) OldLicenses(ctx context.Context) (v []string, err error)
OldLicenses returns the old "licenses" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldName ¶
func (m *NodeMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldReleaseDate ¶
OldReleaseDate returns the old "release_date" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldSourceInfo ¶
func (m *NodeMutation) OldSourceInfo(ctx context.Context) (v string, err error)
OldSourceInfo returns the old "source_info" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldSummary ¶
func (m *NodeMutation) OldSummary(ctx context.Context) (v string, err error)
OldSummary returns the old "summary" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldType ¶
OldType returns the old "type" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldURLDownload ¶
func (m *NodeMutation) OldURLDownload(ctx context.Context) (v string, err error)
OldURLDownload returns the old "url_download" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldURLHome ¶
func (m *NodeMutation) OldURLHome(ctx context.Context) (v string, err error)
OldURLHome returns the old "url_home" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldValidUntilDate ¶
OldValidUntilDate returns the old "valid_until_date" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OldVersion ¶
func (m *NodeMutation) OldVersion(ctx context.Context) (v string, err error)
OldVersion returns the old "version" field's value of the Node entity. If the Node object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*NodeMutation) OriginatorsCleared ¶
func (m *NodeMutation) OriginatorsCleared() bool
OriginatorsCleared reports if the "originators" edge to the Person entity was cleared.
func (*NodeMutation) OriginatorsIDs ¶
func (m *NodeMutation) OriginatorsIDs() (ids []int)
OriginatorsIDs returns the "originators" edge IDs in the mutation.
func (*NodeMutation) PrimaryPurposeCleared ¶
func (m *NodeMutation) PrimaryPurposeCleared() bool
PrimaryPurposeCleared reports if the "primary_purpose" edge to the Purpose entity was cleared.
func (*NodeMutation) PrimaryPurposeIDs ¶
func (m *NodeMutation) PrimaryPurposeIDs() (ids []int)
PrimaryPurposeIDs returns the "primary_purpose" edge IDs in the mutation.
func (*NodeMutation) ReleaseDate ¶
func (m *NodeMutation) ReleaseDate() (r time.Time, exists bool)
ReleaseDate returns the value of the "release_date" field in the mutation.
func (*NodeMutation) RemoveEdgeTypeIDs ¶
func (m *NodeMutation) RemoveEdgeTypeIDs(ids ...int)
RemoveEdgeTypeIDs removes the "edge_types" edge to the EdgeType entity by IDs.
func (*NodeMutation) RemoveExternalReferenceIDs ¶
func (m *NodeMutation) RemoveExternalReferenceIDs(ids ...int)
RemoveExternalReferenceIDs removes the "external_references" edge to the ExternalReference entity by IDs.
func (*NodeMutation) RemoveHashIDs ¶
func (m *NodeMutation) RemoveHashIDs(ids ...int)
RemoveHashIDs removes the "hashes" edge to the HashesEntry entity by IDs.
func (*NodeMutation) RemoveIdentifierIDs ¶
func (m *NodeMutation) RemoveIdentifierIDs(ids ...int)
RemoveIdentifierIDs removes the "identifiers" edge to the IdentifiersEntry entity by IDs.
func (*NodeMutation) RemoveNodeIDs ¶
func (m *NodeMutation) RemoveNodeIDs(ids ...string)
RemoveNodeIDs removes the "nodes" edge to the Node entity by IDs.
func (*NodeMutation) RemoveOriginatorIDs ¶
func (m *NodeMutation) RemoveOriginatorIDs(ids ...int)
RemoveOriginatorIDs removes the "originators" edge to the Person entity by IDs.
func (*NodeMutation) RemovePrimaryPurposeIDs ¶
func (m *NodeMutation) RemovePrimaryPurposeIDs(ids ...int)
RemovePrimaryPurposeIDs removes the "primary_purpose" edge to the Purpose entity by IDs.
func (*NodeMutation) RemoveSupplierIDs ¶
func (m *NodeMutation) RemoveSupplierIDs(ids ...int)
RemoveSupplierIDs removes the "suppliers" edge to the Person entity by IDs.
func (*NodeMutation) RemovedEdgeTypesIDs ¶
func (m *NodeMutation) RemovedEdgeTypesIDs() (ids []int)
RemovedEdgeTypes returns the removed IDs of the "edge_types" edge to the EdgeType entity.
func (*NodeMutation) RemovedEdges ¶
func (m *NodeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*NodeMutation) RemovedExternalReferencesIDs ¶
func (m *NodeMutation) RemovedExternalReferencesIDs() (ids []int)
RemovedExternalReferences returns the removed IDs of the "external_references" edge to the ExternalReference entity.
func (*NodeMutation) RemovedHashesIDs ¶
func (m *NodeMutation) RemovedHashesIDs() (ids []int)
RemovedHashes returns the removed IDs of the "hashes" edge to the HashesEntry entity.
func (*NodeMutation) RemovedIDs ¶
func (m *NodeMutation) 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 (*NodeMutation) RemovedIdentifiersIDs ¶
func (m *NodeMutation) RemovedIdentifiersIDs() (ids []int)
RemovedIdentifiers returns the removed IDs of the "identifiers" edge to the IdentifiersEntry entity.
func (*NodeMutation) RemovedNodesIDs ¶
func (m *NodeMutation) RemovedNodesIDs() (ids []string)
RemovedNodes returns the removed IDs of the "nodes" edge to the Node entity.
func (*NodeMutation) RemovedOriginatorsIDs ¶
func (m *NodeMutation) RemovedOriginatorsIDs() (ids []int)
RemovedOriginators returns the removed IDs of the "originators" edge to the Person entity.
func (*NodeMutation) RemovedPrimaryPurposeIDs ¶
func (m *NodeMutation) RemovedPrimaryPurposeIDs() (ids []int)
RemovedPrimaryPurpose returns the removed IDs of the "primary_purpose" edge to the Purpose entity.
func (*NodeMutation) RemovedSuppliersIDs ¶
func (m *NodeMutation) RemovedSuppliersIDs() (ids []int)
RemovedSuppliers returns the removed IDs of the "suppliers" edge to the Person entity.
func (*NodeMutation) ResetAttribution ¶
func (m *NodeMutation) ResetAttribution()
ResetAttribution resets all changes to the "attribution" field.
func (*NodeMutation) ResetBuildDate ¶
func (m *NodeMutation) ResetBuildDate()
ResetBuildDate resets all changes to the "build_date" field.
func (*NodeMutation) ResetComment ¶
func (m *NodeMutation) ResetComment()
ResetComment resets all changes to the "comment" field.
func (*NodeMutation) ResetCopyright ¶
func (m *NodeMutation) ResetCopyright()
ResetCopyright resets all changes to the "copyright" field.
func (*NodeMutation) ResetDescription ¶
func (m *NodeMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*NodeMutation) ResetEdge ¶
func (m *NodeMutation) 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 (*NodeMutation) ResetEdgeTypes ¶
func (m *NodeMutation) ResetEdgeTypes()
ResetEdgeTypes resets all changes to the "edge_types" edge.
func (*NodeMutation) ResetExternalReferences ¶
func (m *NodeMutation) ResetExternalReferences()
ResetExternalReferences resets all changes to the "external_references" edge.
func (*NodeMutation) ResetField ¶
func (m *NodeMutation) 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 (*NodeMutation) ResetFileName ¶
func (m *NodeMutation) ResetFileName()
ResetFileName resets all changes to the "file_name" field.
func (*NodeMutation) ResetFileTypes ¶
func (m *NodeMutation) ResetFileTypes()
ResetFileTypes resets all changes to the "file_types" field.
func (*NodeMutation) ResetHashes ¶
func (m *NodeMutation) ResetHashes()
ResetHashes resets all changes to the "hashes" edge.
func (*NodeMutation) ResetIdentifiers ¶
func (m *NodeMutation) ResetIdentifiers()
ResetIdentifiers resets all changes to the "identifiers" edge.
func (*NodeMutation) ResetLicenseComments ¶
func (m *NodeMutation) ResetLicenseComments()
ResetLicenseComments resets all changes to the "license_comments" field.
func (*NodeMutation) ResetLicenseConcluded ¶
func (m *NodeMutation) ResetLicenseConcluded()
ResetLicenseConcluded resets all changes to the "license_concluded" field.
func (*NodeMutation) ResetLicenses ¶
func (m *NodeMutation) ResetLicenses()
ResetLicenses resets all changes to the "licenses" field.
func (*NodeMutation) ResetName ¶
func (m *NodeMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*NodeMutation) ResetNodeList ¶
func (m *NodeMutation) ResetNodeList()
ResetNodeList resets all changes to the "node_list" edge.
func (*NodeMutation) ResetNodes ¶
func (m *NodeMutation) ResetNodes()
ResetNodes resets all changes to the "nodes" edge.
func (*NodeMutation) ResetOriginators ¶
func (m *NodeMutation) ResetOriginators()
ResetOriginators resets all changes to the "originators" edge.
func (*NodeMutation) ResetPrimaryPurpose ¶
func (m *NodeMutation) ResetPrimaryPurpose()
ResetPrimaryPurpose resets all changes to the "primary_purpose" edge.
func (*NodeMutation) ResetReleaseDate ¶
func (m *NodeMutation) ResetReleaseDate()
ResetReleaseDate resets all changes to the "release_date" field.
func (*NodeMutation) ResetSourceInfo ¶
func (m *NodeMutation) ResetSourceInfo()
ResetSourceInfo resets all changes to the "source_info" field.
func (*NodeMutation) ResetSummary ¶
func (m *NodeMutation) ResetSummary()
ResetSummary resets all changes to the "summary" field.
func (*NodeMutation) ResetSuppliers ¶
func (m *NodeMutation) ResetSuppliers()
ResetSuppliers resets all changes to the "suppliers" edge.
func (*NodeMutation) ResetType ¶
func (m *NodeMutation) ResetType()
ResetType resets all changes to the "type" field.
func (*NodeMutation) ResetURLDownload ¶
func (m *NodeMutation) ResetURLDownload()
ResetURLDownload resets all changes to the "url_download" field.
func (*NodeMutation) ResetURLHome ¶
func (m *NodeMutation) ResetURLHome()
ResetURLHome resets all changes to the "url_home" field.
func (*NodeMutation) ResetValidUntilDate ¶
func (m *NodeMutation) ResetValidUntilDate()
ResetValidUntilDate resets all changes to the "valid_until_date" field.
func (*NodeMutation) ResetVersion ¶
func (m *NodeMutation) ResetVersion()
ResetVersion resets all changes to the "version" field.
func (*NodeMutation) SetAttribution ¶
func (m *NodeMutation) SetAttribution(s []string)
SetAttribution sets the "attribution" field.
func (*NodeMutation) SetBuildDate ¶
func (m *NodeMutation) SetBuildDate(t time.Time)
SetBuildDate sets the "build_date" field.
func (*NodeMutation) SetComment ¶
func (m *NodeMutation) SetComment(s string)
SetComment sets the "comment" field.
func (*NodeMutation) SetCopyright ¶
func (m *NodeMutation) SetCopyright(s string)
SetCopyright sets the "copyright" field.
func (*NodeMutation) SetDescription ¶
func (m *NodeMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*NodeMutation) SetField ¶
func (m *NodeMutation) 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 (*NodeMutation) SetFileName ¶
func (m *NodeMutation) SetFileName(s string)
SetFileName sets the "file_name" field.
func (*NodeMutation) SetFileTypes ¶
func (m *NodeMutation) SetFileTypes(s []string)
SetFileTypes sets the "file_types" field.
func (*NodeMutation) SetID ¶
func (m *NodeMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Node entities.
func (*NodeMutation) SetLicenseComments ¶
func (m *NodeMutation) SetLicenseComments(s string)
SetLicenseComments sets the "license_comments" field.
func (*NodeMutation) SetLicenseConcluded ¶
func (m *NodeMutation) SetLicenseConcluded(s string)
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeMutation) SetLicenses ¶
func (m *NodeMutation) SetLicenses(s []string)
SetLicenses sets the "licenses" field.
func (*NodeMutation) SetName ¶
func (m *NodeMutation) SetName(s string)
SetName sets the "name" field.
func (*NodeMutation) SetNodeListID ¶
func (m *NodeMutation) SetNodeListID(id int)
SetNodeListID sets the "node_list" edge to the NodeList entity by id.
func (*NodeMutation) SetOp ¶
func (m *NodeMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*NodeMutation) SetReleaseDate ¶
func (m *NodeMutation) SetReleaseDate(t time.Time)
SetReleaseDate sets the "release_date" field.
func (*NodeMutation) SetSourceInfo ¶
func (m *NodeMutation) SetSourceInfo(s string)
SetSourceInfo sets the "source_info" field.
func (*NodeMutation) SetSummary ¶
func (m *NodeMutation) SetSummary(s string)
SetSummary sets the "summary" field.
func (*NodeMutation) SetType ¶
func (m *NodeMutation) SetType(n node.Type)
SetType sets the "type" field.
func (*NodeMutation) SetURLDownload ¶
func (m *NodeMutation) SetURLDownload(s string)
SetURLDownload sets the "url_download" field.
func (*NodeMutation) SetURLHome ¶
func (m *NodeMutation) SetURLHome(s string)
SetURLHome sets the "url_home" field.
func (*NodeMutation) SetValidUntilDate ¶
func (m *NodeMutation) SetValidUntilDate(t time.Time)
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeMutation) SetVersion ¶
func (m *NodeMutation) SetVersion(s string)
SetVersion sets the "version" field.
func (*NodeMutation) SourceInfo ¶
func (m *NodeMutation) SourceInfo() (r string, exists bool)
SourceInfo returns the value of the "source_info" field in the mutation.
func (*NodeMutation) Summary ¶
func (m *NodeMutation) Summary() (r string, exists bool)
Summary returns the value of the "summary" field in the mutation.
func (*NodeMutation) SuppliersCleared ¶
func (m *NodeMutation) SuppliersCleared() bool
SuppliersCleared reports if the "suppliers" edge to the Person entity was cleared.
func (*NodeMutation) SuppliersIDs ¶
func (m *NodeMutation) SuppliersIDs() (ids []int)
SuppliersIDs returns the "suppliers" edge IDs in the mutation.
func (NodeMutation) Tx ¶
func (m NodeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*NodeMutation) Type ¶
func (m *NodeMutation) Type() string
Type returns the node type of this mutation (Node).
func (*NodeMutation) URLDownload ¶
func (m *NodeMutation) URLDownload() (r string, exists bool)
URLDownload returns the value of the "url_download" field in the mutation.
func (*NodeMutation) URLHome ¶
func (m *NodeMutation) URLHome() (r string, exists bool)
URLHome returns the value of the "url_home" field in the mutation.
func (*NodeMutation) ValidUntilDate ¶
func (m *NodeMutation) ValidUntilDate() (r time.Time, exists bool)
ValidUntilDate returns the value of the "valid_until_date" field in the mutation.
func (*NodeMutation) Version ¶
func (m *NodeMutation) Version() (r string, exists bool)
Version returns the value of the "version" field in the mutation.
func (*NodeMutation) Where ¶
func (m *NodeMutation) Where(ps ...predicate.Node)
Where appends a list predicates to the NodeMutation builder.
func (*NodeMutation) WhereP ¶
func (m *NodeMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the NodeMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type NodeQuery ¶
type NodeQuery struct {
// contains filtered or unexported fields
}
NodeQuery is the builder for querying Node entities.
func (*NodeQuery) Aggregate ¶
func (nq *NodeQuery) Aggregate(fns ...AggregateFunc) *NodeSelect
Aggregate returns a NodeSelect configured with the given aggregations.
func (*NodeQuery) Clone ¶
Clone returns a duplicate of the NodeQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*NodeQuery) First ¶
First returns the first Node entity from the query. Returns a *NotFoundError when no Node was found.
func (*NodeQuery) FirstID ¶
FirstID returns the first Node ID from the query. Returns a *NotFoundError when no Node ID was found.
func (*NodeQuery) GroupBy ¶
func (nq *NodeQuery) GroupBy(field string, fields ...string) *NodeGroupBy
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 { Type node.Type `json:"type,omitempty"` Count int `json:"count,omitempty"` } client.Node.Query(). GroupBy(node.FieldType). Aggregate(ent.Count()). Scan(ctx, &v)
func (*NodeQuery) Only ¶
Only returns a single Node entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Node entity is found. Returns a *NotFoundError when no Node entities are found.
func (*NodeQuery) OnlyID ¶
OnlyID is like Only, but returns the only Node ID in the query. Returns a *NotSingularError when more than one Node ID is found. Returns a *NotFoundError when no entities are found.
func (*NodeQuery) Order ¶
func (nq *NodeQuery) Order(o ...node.OrderOption) *NodeQuery
Order specifies how the records should be ordered.
func (*NodeQuery) QueryEdgeTypes ¶
func (nq *NodeQuery) QueryEdgeTypes() *EdgeTypeQuery
QueryEdgeTypes chains the current query on the "edge_types" edge.
func (*NodeQuery) QueryExternalReferences ¶
func (nq *NodeQuery) QueryExternalReferences() *ExternalReferenceQuery
QueryExternalReferences chains the current query on the "external_references" edge.
func (*NodeQuery) QueryHashes ¶
func (nq *NodeQuery) QueryHashes() *HashesEntryQuery
QueryHashes chains the current query on the "hashes" edge.
func (*NodeQuery) QueryIdentifiers ¶
func (nq *NodeQuery) QueryIdentifiers() *IdentifiersEntryQuery
QueryIdentifiers chains the current query on the "identifiers" edge.
func (*NodeQuery) QueryNodeList ¶
func (nq *NodeQuery) QueryNodeList() *NodeListQuery
QueryNodeList chains the current query on the "node_list" edge.
func (*NodeQuery) QueryNodes ¶
QueryNodes chains the current query on the "nodes" edge.
func (*NodeQuery) QueryOriginators ¶
func (nq *NodeQuery) QueryOriginators() *PersonQuery
QueryOriginators chains the current query on the "originators" edge.
func (*NodeQuery) QueryPrimaryPurpose ¶
func (nq *NodeQuery) QueryPrimaryPurpose() *PurposeQuery
QueryPrimaryPurpose chains the current query on the "primary_purpose" edge.
func (*NodeQuery) QuerySuppliers ¶
func (nq *NodeQuery) QuerySuppliers() *PersonQuery
QuerySuppliers chains the current query on the "suppliers" edge.
func (*NodeQuery) Select ¶
func (nq *NodeQuery) Select(fields ...string) *NodeSelect
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 { Type node.Type `json:"type,omitempty"` } client.Node.Query(). Select(node.FieldType). Scan(ctx, &v)
func (*NodeQuery) 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 (*NodeQuery) WithEdgeTypes ¶
func (nq *NodeQuery) WithEdgeTypes(opts ...func(*EdgeTypeQuery)) *NodeQuery
WithEdgeTypes tells the query-builder to eager-load the nodes that are connected to the "edge_types" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithExternalReferences ¶
func (nq *NodeQuery) WithExternalReferences(opts ...func(*ExternalReferenceQuery)) *NodeQuery
WithExternalReferences tells the query-builder to eager-load the nodes that are connected to the "external_references" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithHashes ¶
func (nq *NodeQuery) WithHashes(opts ...func(*HashesEntryQuery)) *NodeQuery
WithHashes tells the query-builder to eager-load the nodes that are connected to the "hashes" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithIdentifiers ¶
func (nq *NodeQuery) WithIdentifiers(opts ...func(*IdentifiersEntryQuery)) *NodeQuery
WithIdentifiers tells the query-builder to eager-load the nodes that are connected to the "identifiers" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithNodeList ¶
func (nq *NodeQuery) WithNodeList(opts ...func(*NodeListQuery)) *NodeQuery
WithNodeList tells the query-builder to eager-load the nodes that are connected to the "node_list" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithNodes ¶
WithNodes tells the query-builder to eager-load the nodes that are connected to the "nodes" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithOriginators ¶
func (nq *NodeQuery) WithOriginators(opts ...func(*PersonQuery)) *NodeQuery
WithOriginators tells the query-builder to eager-load the nodes that are connected to the "originators" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithPrimaryPurpose ¶
func (nq *NodeQuery) WithPrimaryPurpose(opts ...func(*PurposeQuery)) *NodeQuery
WithPrimaryPurpose tells the query-builder to eager-load the nodes that are connected to the "primary_purpose" edge. The optional arguments are used to configure the query builder of the edge.
func (*NodeQuery) WithSuppliers ¶
func (nq *NodeQuery) WithSuppliers(opts ...func(*PersonQuery)) *NodeQuery
WithSuppliers tells the query-builder to eager-load the nodes that are connected to the "suppliers" edge. The optional arguments are used to configure the query builder of the edge.
type NodeSelect ¶
type NodeSelect struct { *NodeQuery // contains filtered or unexported fields }
NodeSelect is the builder for selecting fields of Node entities.
func (*NodeSelect) Aggregate ¶
func (ns *NodeSelect) Aggregate(fns ...AggregateFunc) *NodeSelect
Aggregate adds the given aggregation functions to the selector query.
func (*NodeSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*NodeSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*NodeSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*NodeSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*NodeSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*NodeSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*NodeSelect) Scan ¶
func (ns *NodeSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*NodeSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type NodeUpdate ¶
type NodeUpdate struct {
// contains filtered or unexported fields
}
NodeUpdate is the builder for updating Node entities.
func (*NodeUpdate) AddEdgeTypeIDs ¶
func (nu *NodeUpdate) AddEdgeTypeIDs(ids ...int) *NodeUpdate
AddEdgeTypeIDs adds the "edge_types" edge to the EdgeType entity by IDs.
func (*NodeUpdate) AddEdgeTypes ¶
func (nu *NodeUpdate) AddEdgeTypes(e ...*EdgeType) *NodeUpdate
AddEdgeTypes adds the "edge_types" edges to the EdgeType entity.
func (*NodeUpdate) AddExternalReferenceIDs ¶
func (nu *NodeUpdate) AddExternalReferenceIDs(ids ...int) *NodeUpdate
AddExternalReferenceIDs adds the "external_references" edge to the ExternalReference entity by IDs.
func (*NodeUpdate) AddExternalReferences ¶
func (nu *NodeUpdate) AddExternalReferences(e ...*ExternalReference) *NodeUpdate
AddExternalReferences adds the "external_references" edges to the ExternalReference entity.
func (*NodeUpdate) AddHashIDs ¶
func (nu *NodeUpdate) AddHashIDs(ids ...int) *NodeUpdate
AddHashIDs adds the "hashes" edge to the HashesEntry entity by IDs.
func (*NodeUpdate) AddHashes ¶
func (nu *NodeUpdate) AddHashes(h ...*HashesEntry) *NodeUpdate
AddHashes adds the "hashes" edges to the HashesEntry entity.
func (*NodeUpdate) AddIdentifierIDs ¶
func (nu *NodeUpdate) AddIdentifierIDs(ids ...int) *NodeUpdate
AddIdentifierIDs adds the "identifiers" edge to the IdentifiersEntry entity by IDs.
func (*NodeUpdate) AddIdentifiers ¶
func (nu *NodeUpdate) AddIdentifiers(i ...*IdentifiersEntry) *NodeUpdate
AddIdentifiers adds the "identifiers" edges to the IdentifiersEntry entity.
func (*NodeUpdate) AddNodeIDs ¶
func (nu *NodeUpdate) AddNodeIDs(ids ...string) *NodeUpdate
AddNodeIDs adds the "nodes" edge to the Node entity by IDs.
func (*NodeUpdate) AddNodes ¶
func (nu *NodeUpdate) AddNodes(n ...*Node) *NodeUpdate
AddNodes adds the "nodes" edges to the Node entity.
func (*NodeUpdate) AddOriginatorIDs ¶
func (nu *NodeUpdate) AddOriginatorIDs(ids ...int) *NodeUpdate
AddOriginatorIDs adds the "originators" edge to the Person entity by IDs.
func (*NodeUpdate) AddOriginators ¶
func (nu *NodeUpdate) AddOriginators(p ...*Person) *NodeUpdate
AddOriginators adds the "originators" edges to the Person entity.
func (*NodeUpdate) AddPrimaryPurpose ¶
func (nu *NodeUpdate) AddPrimaryPurpose(p ...*Purpose) *NodeUpdate
AddPrimaryPurpose adds the "primary_purpose" edges to the Purpose entity.
func (*NodeUpdate) AddPrimaryPurposeIDs ¶
func (nu *NodeUpdate) AddPrimaryPurposeIDs(ids ...int) *NodeUpdate
AddPrimaryPurposeIDs adds the "primary_purpose" edge to the Purpose entity by IDs.
func (*NodeUpdate) AddSupplierIDs ¶
func (nu *NodeUpdate) AddSupplierIDs(ids ...int) *NodeUpdate
AddSupplierIDs adds the "suppliers" edge to the Person entity by IDs.
func (*NodeUpdate) AddSuppliers ¶
func (nu *NodeUpdate) AddSuppliers(p ...*Person) *NodeUpdate
AddSuppliers adds the "suppliers" edges to the Person entity.
func (*NodeUpdate) AppendAttribution ¶
func (nu *NodeUpdate) AppendAttribution(s []string) *NodeUpdate
AppendAttribution appends s to the "attribution" field.
func (*NodeUpdate) AppendFileTypes ¶
func (nu *NodeUpdate) AppendFileTypes(s []string) *NodeUpdate
AppendFileTypes appends s to the "file_types" field.
func (*NodeUpdate) AppendLicenses ¶
func (nu *NodeUpdate) AppendLicenses(s []string) *NodeUpdate
AppendLicenses appends s to the "licenses" field.
func (*NodeUpdate) ClearEdgeTypes ¶
func (nu *NodeUpdate) ClearEdgeTypes() *NodeUpdate
ClearEdgeTypes clears all "edge_types" edges to the EdgeType entity.
func (*NodeUpdate) ClearExternalReferences ¶
func (nu *NodeUpdate) ClearExternalReferences() *NodeUpdate
ClearExternalReferences clears all "external_references" edges to the ExternalReference entity.
func (*NodeUpdate) ClearHashes ¶
func (nu *NodeUpdate) ClearHashes() *NodeUpdate
ClearHashes clears all "hashes" edges to the HashesEntry entity.
func (*NodeUpdate) ClearIdentifiers ¶
func (nu *NodeUpdate) ClearIdentifiers() *NodeUpdate
ClearIdentifiers clears all "identifiers" edges to the IdentifiersEntry entity.
func (*NodeUpdate) ClearNodeList ¶
func (nu *NodeUpdate) ClearNodeList() *NodeUpdate
ClearNodeList clears the "node_list" edge to the NodeList entity.
func (*NodeUpdate) ClearNodes ¶
func (nu *NodeUpdate) ClearNodes() *NodeUpdate
ClearNodes clears all "nodes" edges to the Node entity.
func (*NodeUpdate) ClearOriginators ¶
func (nu *NodeUpdate) ClearOriginators() *NodeUpdate
ClearOriginators clears all "originators" edges to the Person entity.
func (*NodeUpdate) ClearPrimaryPurpose ¶
func (nu *NodeUpdate) ClearPrimaryPurpose() *NodeUpdate
ClearPrimaryPurpose clears all "primary_purpose" edges to the Purpose entity.
func (*NodeUpdate) ClearSuppliers ¶
func (nu *NodeUpdate) ClearSuppliers() *NodeUpdate
ClearSuppliers clears all "suppliers" edges to the Person entity.
func (*NodeUpdate) Exec ¶
func (nu *NodeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeUpdate) ExecX ¶
func (nu *NodeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeUpdate) Mutation ¶
func (nu *NodeUpdate) Mutation() *NodeMutation
Mutation returns the NodeMutation object of the builder.
func (*NodeUpdate) RemoveEdgeTypeIDs ¶
func (nu *NodeUpdate) RemoveEdgeTypeIDs(ids ...int) *NodeUpdate
RemoveEdgeTypeIDs removes the "edge_types" edge to EdgeType entities by IDs.
func (*NodeUpdate) RemoveEdgeTypes ¶
func (nu *NodeUpdate) RemoveEdgeTypes(e ...*EdgeType) *NodeUpdate
RemoveEdgeTypes removes "edge_types" edges to EdgeType entities.
func (*NodeUpdate) RemoveExternalReferenceIDs ¶
func (nu *NodeUpdate) RemoveExternalReferenceIDs(ids ...int) *NodeUpdate
RemoveExternalReferenceIDs removes the "external_references" edge to ExternalReference entities by IDs.
func (*NodeUpdate) RemoveExternalReferences ¶
func (nu *NodeUpdate) RemoveExternalReferences(e ...*ExternalReference) *NodeUpdate
RemoveExternalReferences removes "external_references" edges to ExternalReference entities.
func (*NodeUpdate) RemoveHashIDs ¶
func (nu *NodeUpdate) RemoveHashIDs(ids ...int) *NodeUpdate
RemoveHashIDs removes the "hashes" edge to HashesEntry entities by IDs.
func (*NodeUpdate) RemoveHashes ¶
func (nu *NodeUpdate) RemoveHashes(h ...*HashesEntry) *NodeUpdate
RemoveHashes removes "hashes" edges to HashesEntry entities.
func (*NodeUpdate) RemoveIdentifierIDs ¶
func (nu *NodeUpdate) RemoveIdentifierIDs(ids ...int) *NodeUpdate
RemoveIdentifierIDs removes the "identifiers" edge to IdentifiersEntry entities by IDs.
func (*NodeUpdate) RemoveIdentifiers ¶
func (nu *NodeUpdate) RemoveIdentifiers(i ...*IdentifiersEntry) *NodeUpdate
RemoveIdentifiers removes "identifiers" edges to IdentifiersEntry entities.
func (*NodeUpdate) RemoveNodeIDs ¶
func (nu *NodeUpdate) RemoveNodeIDs(ids ...string) *NodeUpdate
RemoveNodeIDs removes the "nodes" edge to Node entities by IDs.
func (*NodeUpdate) RemoveNodes ¶
func (nu *NodeUpdate) RemoveNodes(n ...*Node) *NodeUpdate
RemoveNodes removes "nodes" edges to Node entities.
func (*NodeUpdate) RemoveOriginatorIDs ¶
func (nu *NodeUpdate) RemoveOriginatorIDs(ids ...int) *NodeUpdate
RemoveOriginatorIDs removes the "originators" edge to Person entities by IDs.
func (*NodeUpdate) RemoveOriginators ¶
func (nu *NodeUpdate) RemoveOriginators(p ...*Person) *NodeUpdate
RemoveOriginators removes "originators" edges to Person entities.
func (*NodeUpdate) RemovePrimaryPurpose ¶
func (nu *NodeUpdate) RemovePrimaryPurpose(p ...*Purpose) *NodeUpdate
RemovePrimaryPurpose removes "primary_purpose" edges to Purpose entities.
func (*NodeUpdate) RemovePrimaryPurposeIDs ¶
func (nu *NodeUpdate) RemovePrimaryPurposeIDs(ids ...int) *NodeUpdate
RemovePrimaryPurposeIDs removes the "primary_purpose" edge to Purpose entities by IDs.
func (*NodeUpdate) RemoveSupplierIDs ¶
func (nu *NodeUpdate) RemoveSupplierIDs(ids ...int) *NodeUpdate
RemoveSupplierIDs removes the "suppliers" edge to Person entities by IDs.
func (*NodeUpdate) RemoveSuppliers ¶
func (nu *NodeUpdate) RemoveSuppliers(p ...*Person) *NodeUpdate
RemoveSuppliers removes "suppliers" edges to Person entities.
func (*NodeUpdate) Save ¶
func (nu *NodeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*NodeUpdate) SaveX ¶
func (nu *NodeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*NodeUpdate) SetAttribution ¶
func (nu *NodeUpdate) SetAttribution(s []string) *NodeUpdate
SetAttribution sets the "attribution" field.
func (*NodeUpdate) SetBuildDate ¶
func (nu *NodeUpdate) SetBuildDate(t time.Time) *NodeUpdate
SetBuildDate sets the "build_date" field.
func (*NodeUpdate) SetComment ¶
func (nu *NodeUpdate) SetComment(s string) *NodeUpdate
SetComment sets the "comment" field.
func (*NodeUpdate) SetCopyright ¶
func (nu *NodeUpdate) SetCopyright(s string) *NodeUpdate
SetCopyright sets the "copyright" field.
func (*NodeUpdate) SetDescription ¶
func (nu *NodeUpdate) SetDescription(s string) *NodeUpdate
SetDescription sets the "description" field.
func (*NodeUpdate) SetFileName ¶
func (nu *NodeUpdate) SetFileName(s string) *NodeUpdate
SetFileName sets the "file_name" field.
func (*NodeUpdate) SetFileTypes ¶
func (nu *NodeUpdate) SetFileTypes(s []string) *NodeUpdate
SetFileTypes sets the "file_types" field.
func (*NodeUpdate) SetLicenseComments ¶
func (nu *NodeUpdate) SetLicenseComments(s string) *NodeUpdate
SetLicenseComments sets the "license_comments" field.
func (*NodeUpdate) SetLicenseConcluded ¶
func (nu *NodeUpdate) SetLicenseConcluded(s string) *NodeUpdate
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeUpdate) SetLicenses ¶
func (nu *NodeUpdate) SetLicenses(s []string) *NodeUpdate
SetLicenses sets the "licenses" field.
func (*NodeUpdate) SetName ¶
func (nu *NodeUpdate) SetName(s string) *NodeUpdate
SetName sets the "name" field.
func (*NodeUpdate) SetNillableBuildDate ¶
func (nu *NodeUpdate) SetNillableBuildDate(t *time.Time) *NodeUpdate
SetNillableBuildDate sets the "build_date" field if the given value is not nil.
func (*NodeUpdate) SetNillableComment ¶
func (nu *NodeUpdate) SetNillableComment(s *string) *NodeUpdate
SetNillableComment sets the "comment" field if the given value is not nil.
func (*NodeUpdate) SetNillableCopyright ¶
func (nu *NodeUpdate) SetNillableCopyright(s *string) *NodeUpdate
SetNillableCopyright sets the "copyright" field if the given value is not nil.
func (*NodeUpdate) SetNillableDescription ¶
func (nu *NodeUpdate) SetNillableDescription(s *string) *NodeUpdate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*NodeUpdate) SetNillableFileName ¶
func (nu *NodeUpdate) SetNillableFileName(s *string) *NodeUpdate
SetNillableFileName sets the "file_name" field if the given value is not nil.
func (*NodeUpdate) SetNillableLicenseComments ¶
func (nu *NodeUpdate) SetNillableLicenseComments(s *string) *NodeUpdate
SetNillableLicenseComments sets the "license_comments" field if the given value is not nil.
func (*NodeUpdate) SetNillableLicenseConcluded ¶
func (nu *NodeUpdate) SetNillableLicenseConcluded(s *string) *NodeUpdate
SetNillableLicenseConcluded sets the "license_concluded" field if the given value is not nil.
func (*NodeUpdate) SetNillableName ¶
func (nu *NodeUpdate) SetNillableName(s *string) *NodeUpdate
SetNillableName sets the "name" field if the given value is not nil.
func (*NodeUpdate) SetNillableReleaseDate ¶
func (nu *NodeUpdate) SetNillableReleaseDate(t *time.Time) *NodeUpdate
SetNillableReleaseDate sets the "release_date" field if the given value is not nil.
func (*NodeUpdate) SetNillableSourceInfo ¶
func (nu *NodeUpdate) SetNillableSourceInfo(s *string) *NodeUpdate
SetNillableSourceInfo sets the "source_info" field if the given value is not nil.
func (*NodeUpdate) SetNillableSummary ¶
func (nu *NodeUpdate) SetNillableSummary(s *string) *NodeUpdate
SetNillableSummary sets the "summary" field if the given value is not nil.
func (*NodeUpdate) SetNillableType ¶
func (nu *NodeUpdate) SetNillableType(n *node.Type) *NodeUpdate
SetNillableType sets the "type" field if the given value is not nil.
func (*NodeUpdate) SetNillableURLDownload ¶
func (nu *NodeUpdate) SetNillableURLDownload(s *string) *NodeUpdate
SetNillableURLDownload sets the "url_download" field if the given value is not nil.
func (*NodeUpdate) SetNillableURLHome ¶
func (nu *NodeUpdate) SetNillableURLHome(s *string) *NodeUpdate
SetNillableURLHome sets the "url_home" field if the given value is not nil.
func (*NodeUpdate) SetNillableValidUntilDate ¶
func (nu *NodeUpdate) SetNillableValidUntilDate(t *time.Time) *NodeUpdate
SetNillableValidUntilDate sets the "valid_until_date" field if the given value is not nil.
func (*NodeUpdate) SetNillableVersion ¶
func (nu *NodeUpdate) SetNillableVersion(s *string) *NodeUpdate
SetNillableVersion sets the "version" field if the given value is not nil.
func (*NodeUpdate) SetNodeList ¶
func (nu *NodeUpdate) SetNodeList(n *NodeList) *NodeUpdate
SetNodeList sets the "node_list" edge to the NodeList entity.
func (*NodeUpdate) SetNodeListID ¶
func (nu *NodeUpdate) SetNodeListID(id int) *NodeUpdate
SetNodeListID sets the "node_list" edge to the NodeList entity by ID.
func (*NodeUpdate) SetReleaseDate ¶
func (nu *NodeUpdate) SetReleaseDate(t time.Time) *NodeUpdate
SetReleaseDate sets the "release_date" field.
func (*NodeUpdate) SetSourceInfo ¶
func (nu *NodeUpdate) SetSourceInfo(s string) *NodeUpdate
SetSourceInfo sets the "source_info" field.
func (*NodeUpdate) SetSummary ¶
func (nu *NodeUpdate) SetSummary(s string) *NodeUpdate
SetSummary sets the "summary" field.
func (*NodeUpdate) SetType ¶
func (nu *NodeUpdate) SetType(n node.Type) *NodeUpdate
SetType sets the "type" field.
func (*NodeUpdate) SetURLDownload ¶
func (nu *NodeUpdate) SetURLDownload(s string) *NodeUpdate
SetURLDownload sets the "url_download" field.
func (*NodeUpdate) SetURLHome ¶
func (nu *NodeUpdate) SetURLHome(s string) *NodeUpdate
SetURLHome sets the "url_home" field.
func (*NodeUpdate) SetValidUntilDate ¶
func (nu *NodeUpdate) SetValidUntilDate(t time.Time) *NodeUpdate
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeUpdate) SetVersion ¶
func (nu *NodeUpdate) SetVersion(s string) *NodeUpdate
SetVersion sets the "version" field.
func (*NodeUpdate) Where ¶
func (nu *NodeUpdate) Where(ps ...predicate.Node) *NodeUpdate
Where appends a list predicates to the NodeUpdate builder.
type NodeUpdateOne ¶
type NodeUpdateOne struct {
// contains filtered or unexported fields
}
NodeUpdateOne is the builder for updating a single Node entity.
func (*NodeUpdateOne) AddEdgeTypeIDs ¶
func (nuo *NodeUpdateOne) AddEdgeTypeIDs(ids ...int) *NodeUpdateOne
AddEdgeTypeIDs adds the "edge_types" edge to the EdgeType entity by IDs.
func (*NodeUpdateOne) AddEdgeTypes ¶
func (nuo *NodeUpdateOne) AddEdgeTypes(e ...*EdgeType) *NodeUpdateOne
AddEdgeTypes adds the "edge_types" edges to the EdgeType entity.
func (*NodeUpdateOne) AddExternalReferenceIDs ¶
func (nuo *NodeUpdateOne) AddExternalReferenceIDs(ids ...int) *NodeUpdateOne
AddExternalReferenceIDs adds the "external_references" edge to the ExternalReference entity by IDs.
func (*NodeUpdateOne) AddExternalReferences ¶
func (nuo *NodeUpdateOne) AddExternalReferences(e ...*ExternalReference) *NodeUpdateOne
AddExternalReferences adds the "external_references" edges to the ExternalReference entity.
func (*NodeUpdateOne) AddHashIDs ¶
func (nuo *NodeUpdateOne) AddHashIDs(ids ...int) *NodeUpdateOne
AddHashIDs adds the "hashes" edge to the HashesEntry entity by IDs.
func (*NodeUpdateOne) AddHashes ¶
func (nuo *NodeUpdateOne) AddHashes(h ...*HashesEntry) *NodeUpdateOne
AddHashes adds the "hashes" edges to the HashesEntry entity.
func (*NodeUpdateOne) AddIdentifierIDs ¶
func (nuo *NodeUpdateOne) AddIdentifierIDs(ids ...int) *NodeUpdateOne
AddIdentifierIDs adds the "identifiers" edge to the IdentifiersEntry entity by IDs.
func (*NodeUpdateOne) AddIdentifiers ¶
func (nuo *NodeUpdateOne) AddIdentifiers(i ...*IdentifiersEntry) *NodeUpdateOne
AddIdentifiers adds the "identifiers" edges to the IdentifiersEntry entity.
func (*NodeUpdateOne) AddNodeIDs ¶
func (nuo *NodeUpdateOne) AddNodeIDs(ids ...string) *NodeUpdateOne
AddNodeIDs adds the "nodes" edge to the Node entity by IDs.
func (*NodeUpdateOne) AddNodes ¶
func (nuo *NodeUpdateOne) AddNodes(n ...*Node) *NodeUpdateOne
AddNodes adds the "nodes" edges to the Node entity.
func (*NodeUpdateOne) AddOriginatorIDs ¶
func (nuo *NodeUpdateOne) AddOriginatorIDs(ids ...int) *NodeUpdateOne
AddOriginatorIDs adds the "originators" edge to the Person entity by IDs.
func (*NodeUpdateOne) AddOriginators ¶
func (nuo *NodeUpdateOne) AddOriginators(p ...*Person) *NodeUpdateOne
AddOriginators adds the "originators" edges to the Person entity.
func (*NodeUpdateOne) AddPrimaryPurpose ¶
func (nuo *NodeUpdateOne) AddPrimaryPurpose(p ...*Purpose) *NodeUpdateOne
AddPrimaryPurpose adds the "primary_purpose" edges to the Purpose entity.
func (*NodeUpdateOne) AddPrimaryPurposeIDs ¶
func (nuo *NodeUpdateOne) AddPrimaryPurposeIDs(ids ...int) *NodeUpdateOne
AddPrimaryPurposeIDs adds the "primary_purpose" edge to the Purpose entity by IDs.
func (*NodeUpdateOne) AddSupplierIDs ¶
func (nuo *NodeUpdateOne) AddSupplierIDs(ids ...int) *NodeUpdateOne
AddSupplierIDs adds the "suppliers" edge to the Person entity by IDs.
func (*NodeUpdateOne) AddSuppliers ¶
func (nuo *NodeUpdateOne) AddSuppliers(p ...*Person) *NodeUpdateOne
AddSuppliers adds the "suppliers" edges to the Person entity.
func (*NodeUpdateOne) AppendAttribution ¶
func (nuo *NodeUpdateOne) AppendAttribution(s []string) *NodeUpdateOne
AppendAttribution appends s to the "attribution" field.
func (*NodeUpdateOne) AppendFileTypes ¶
func (nuo *NodeUpdateOne) AppendFileTypes(s []string) *NodeUpdateOne
AppendFileTypes appends s to the "file_types" field.
func (*NodeUpdateOne) AppendLicenses ¶
func (nuo *NodeUpdateOne) AppendLicenses(s []string) *NodeUpdateOne
AppendLicenses appends s to the "licenses" field.
func (*NodeUpdateOne) ClearEdgeTypes ¶
func (nuo *NodeUpdateOne) ClearEdgeTypes() *NodeUpdateOne
ClearEdgeTypes clears all "edge_types" edges to the EdgeType entity.
func (*NodeUpdateOne) ClearExternalReferences ¶
func (nuo *NodeUpdateOne) ClearExternalReferences() *NodeUpdateOne
ClearExternalReferences clears all "external_references" edges to the ExternalReference entity.
func (*NodeUpdateOne) ClearHashes ¶
func (nuo *NodeUpdateOne) ClearHashes() *NodeUpdateOne
ClearHashes clears all "hashes" edges to the HashesEntry entity.
func (*NodeUpdateOne) ClearIdentifiers ¶
func (nuo *NodeUpdateOne) ClearIdentifiers() *NodeUpdateOne
ClearIdentifiers clears all "identifiers" edges to the IdentifiersEntry entity.
func (*NodeUpdateOne) ClearNodeList ¶
func (nuo *NodeUpdateOne) ClearNodeList() *NodeUpdateOne
ClearNodeList clears the "node_list" edge to the NodeList entity.
func (*NodeUpdateOne) ClearNodes ¶
func (nuo *NodeUpdateOne) ClearNodes() *NodeUpdateOne
ClearNodes clears all "nodes" edges to the Node entity.
func (*NodeUpdateOne) ClearOriginators ¶
func (nuo *NodeUpdateOne) ClearOriginators() *NodeUpdateOne
ClearOriginators clears all "originators" edges to the Person entity.
func (*NodeUpdateOne) ClearPrimaryPurpose ¶
func (nuo *NodeUpdateOne) ClearPrimaryPurpose() *NodeUpdateOne
ClearPrimaryPurpose clears all "primary_purpose" edges to the Purpose entity.
func (*NodeUpdateOne) ClearSuppliers ¶
func (nuo *NodeUpdateOne) ClearSuppliers() *NodeUpdateOne
ClearSuppliers clears all "suppliers" edges to the Person entity.
func (*NodeUpdateOne) Exec ¶
func (nuo *NodeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*NodeUpdateOne) ExecX ¶
func (nuo *NodeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeUpdateOne) Mutation ¶
func (nuo *NodeUpdateOne) Mutation() *NodeMutation
Mutation returns the NodeMutation object of the builder.
func (*NodeUpdateOne) RemoveEdgeTypeIDs ¶
func (nuo *NodeUpdateOne) RemoveEdgeTypeIDs(ids ...int) *NodeUpdateOne
RemoveEdgeTypeIDs removes the "edge_types" edge to EdgeType entities by IDs.
func (*NodeUpdateOne) RemoveEdgeTypes ¶
func (nuo *NodeUpdateOne) RemoveEdgeTypes(e ...*EdgeType) *NodeUpdateOne
RemoveEdgeTypes removes "edge_types" edges to EdgeType entities.
func (*NodeUpdateOne) RemoveExternalReferenceIDs ¶
func (nuo *NodeUpdateOne) RemoveExternalReferenceIDs(ids ...int) *NodeUpdateOne
RemoveExternalReferenceIDs removes the "external_references" edge to ExternalReference entities by IDs.
func (*NodeUpdateOne) RemoveExternalReferences ¶
func (nuo *NodeUpdateOne) RemoveExternalReferences(e ...*ExternalReference) *NodeUpdateOne
RemoveExternalReferences removes "external_references" edges to ExternalReference entities.
func (*NodeUpdateOne) RemoveHashIDs ¶
func (nuo *NodeUpdateOne) RemoveHashIDs(ids ...int) *NodeUpdateOne
RemoveHashIDs removes the "hashes" edge to HashesEntry entities by IDs.
func (*NodeUpdateOne) RemoveHashes ¶
func (nuo *NodeUpdateOne) RemoveHashes(h ...*HashesEntry) *NodeUpdateOne
RemoveHashes removes "hashes" edges to HashesEntry entities.
func (*NodeUpdateOne) RemoveIdentifierIDs ¶
func (nuo *NodeUpdateOne) RemoveIdentifierIDs(ids ...int) *NodeUpdateOne
RemoveIdentifierIDs removes the "identifiers" edge to IdentifiersEntry entities by IDs.
func (*NodeUpdateOne) RemoveIdentifiers ¶
func (nuo *NodeUpdateOne) RemoveIdentifiers(i ...*IdentifiersEntry) *NodeUpdateOne
RemoveIdentifiers removes "identifiers" edges to IdentifiersEntry entities.
func (*NodeUpdateOne) RemoveNodeIDs ¶
func (nuo *NodeUpdateOne) RemoveNodeIDs(ids ...string) *NodeUpdateOne
RemoveNodeIDs removes the "nodes" edge to Node entities by IDs.
func (*NodeUpdateOne) RemoveNodes ¶
func (nuo *NodeUpdateOne) RemoveNodes(n ...*Node) *NodeUpdateOne
RemoveNodes removes "nodes" edges to Node entities.
func (*NodeUpdateOne) RemoveOriginatorIDs ¶
func (nuo *NodeUpdateOne) RemoveOriginatorIDs(ids ...int) *NodeUpdateOne
RemoveOriginatorIDs removes the "originators" edge to Person entities by IDs.
func (*NodeUpdateOne) RemoveOriginators ¶
func (nuo *NodeUpdateOne) RemoveOriginators(p ...*Person) *NodeUpdateOne
RemoveOriginators removes "originators" edges to Person entities.
func (*NodeUpdateOne) RemovePrimaryPurpose ¶
func (nuo *NodeUpdateOne) RemovePrimaryPurpose(p ...*Purpose) *NodeUpdateOne
RemovePrimaryPurpose removes "primary_purpose" edges to Purpose entities.
func (*NodeUpdateOne) RemovePrimaryPurposeIDs ¶
func (nuo *NodeUpdateOne) RemovePrimaryPurposeIDs(ids ...int) *NodeUpdateOne
RemovePrimaryPurposeIDs removes the "primary_purpose" edge to Purpose entities by IDs.
func (*NodeUpdateOne) RemoveSupplierIDs ¶
func (nuo *NodeUpdateOne) RemoveSupplierIDs(ids ...int) *NodeUpdateOne
RemoveSupplierIDs removes the "suppliers" edge to Person entities by IDs.
func (*NodeUpdateOne) RemoveSuppliers ¶
func (nuo *NodeUpdateOne) RemoveSuppliers(p ...*Person) *NodeUpdateOne
RemoveSuppliers removes "suppliers" edges to Person entities.
func (*NodeUpdateOne) Save ¶
func (nuo *NodeUpdateOne) Save(ctx context.Context) (*Node, error)
Save executes the query and returns the updated Node entity.
func (*NodeUpdateOne) SaveX ¶
func (nuo *NodeUpdateOne) SaveX(ctx context.Context) *Node
SaveX is like Save, but panics if an error occurs.
func (*NodeUpdateOne) Select ¶
func (nuo *NodeUpdateOne) Select(field string, fields ...string) *NodeUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*NodeUpdateOne) SetAttribution ¶
func (nuo *NodeUpdateOne) SetAttribution(s []string) *NodeUpdateOne
SetAttribution sets the "attribution" field.
func (*NodeUpdateOne) SetBuildDate ¶
func (nuo *NodeUpdateOne) SetBuildDate(t time.Time) *NodeUpdateOne
SetBuildDate sets the "build_date" field.
func (*NodeUpdateOne) SetComment ¶
func (nuo *NodeUpdateOne) SetComment(s string) *NodeUpdateOne
SetComment sets the "comment" field.
func (*NodeUpdateOne) SetCopyright ¶
func (nuo *NodeUpdateOne) SetCopyright(s string) *NodeUpdateOne
SetCopyright sets the "copyright" field.
func (*NodeUpdateOne) SetDescription ¶
func (nuo *NodeUpdateOne) SetDescription(s string) *NodeUpdateOne
SetDescription sets the "description" field.
func (*NodeUpdateOne) SetFileName ¶
func (nuo *NodeUpdateOne) SetFileName(s string) *NodeUpdateOne
SetFileName sets the "file_name" field.
func (*NodeUpdateOne) SetFileTypes ¶
func (nuo *NodeUpdateOne) SetFileTypes(s []string) *NodeUpdateOne
SetFileTypes sets the "file_types" field.
func (*NodeUpdateOne) SetLicenseComments ¶
func (nuo *NodeUpdateOne) SetLicenseComments(s string) *NodeUpdateOne
SetLicenseComments sets the "license_comments" field.
func (*NodeUpdateOne) SetLicenseConcluded ¶
func (nuo *NodeUpdateOne) SetLicenseConcluded(s string) *NodeUpdateOne
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeUpdateOne) SetLicenses ¶
func (nuo *NodeUpdateOne) SetLicenses(s []string) *NodeUpdateOne
SetLicenses sets the "licenses" field.
func (*NodeUpdateOne) SetName ¶
func (nuo *NodeUpdateOne) SetName(s string) *NodeUpdateOne
SetName sets the "name" field.
func (*NodeUpdateOne) SetNillableBuildDate ¶
func (nuo *NodeUpdateOne) SetNillableBuildDate(t *time.Time) *NodeUpdateOne
SetNillableBuildDate sets the "build_date" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableComment ¶
func (nuo *NodeUpdateOne) SetNillableComment(s *string) *NodeUpdateOne
SetNillableComment sets the "comment" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableCopyright ¶
func (nuo *NodeUpdateOne) SetNillableCopyright(s *string) *NodeUpdateOne
SetNillableCopyright sets the "copyright" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableDescription ¶
func (nuo *NodeUpdateOne) SetNillableDescription(s *string) *NodeUpdateOne
SetNillableDescription sets the "description" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableFileName ¶
func (nuo *NodeUpdateOne) SetNillableFileName(s *string) *NodeUpdateOne
SetNillableFileName sets the "file_name" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableLicenseComments ¶
func (nuo *NodeUpdateOne) SetNillableLicenseComments(s *string) *NodeUpdateOne
SetNillableLicenseComments sets the "license_comments" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableLicenseConcluded ¶
func (nuo *NodeUpdateOne) SetNillableLicenseConcluded(s *string) *NodeUpdateOne
SetNillableLicenseConcluded sets the "license_concluded" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableName ¶
func (nuo *NodeUpdateOne) SetNillableName(s *string) *NodeUpdateOne
SetNillableName sets the "name" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableReleaseDate ¶
func (nuo *NodeUpdateOne) SetNillableReleaseDate(t *time.Time) *NodeUpdateOne
SetNillableReleaseDate sets the "release_date" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableSourceInfo ¶
func (nuo *NodeUpdateOne) SetNillableSourceInfo(s *string) *NodeUpdateOne
SetNillableSourceInfo sets the "source_info" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableSummary ¶
func (nuo *NodeUpdateOne) SetNillableSummary(s *string) *NodeUpdateOne
SetNillableSummary sets the "summary" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableType ¶
func (nuo *NodeUpdateOne) SetNillableType(n *node.Type) *NodeUpdateOne
SetNillableType sets the "type" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableURLDownload ¶
func (nuo *NodeUpdateOne) SetNillableURLDownload(s *string) *NodeUpdateOne
SetNillableURLDownload sets the "url_download" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableURLHome ¶
func (nuo *NodeUpdateOne) SetNillableURLHome(s *string) *NodeUpdateOne
SetNillableURLHome sets the "url_home" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableValidUntilDate ¶
func (nuo *NodeUpdateOne) SetNillableValidUntilDate(t *time.Time) *NodeUpdateOne
SetNillableValidUntilDate sets the "valid_until_date" field if the given value is not nil.
func (*NodeUpdateOne) SetNillableVersion ¶
func (nuo *NodeUpdateOne) SetNillableVersion(s *string) *NodeUpdateOne
SetNillableVersion sets the "version" field if the given value is not nil.
func (*NodeUpdateOne) SetNodeList ¶
func (nuo *NodeUpdateOne) SetNodeList(n *NodeList) *NodeUpdateOne
SetNodeList sets the "node_list" edge to the NodeList entity.
func (*NodeUpdateOne) SetNodeListID ¶
func (nuo *NodeUpdateOne) SetNodeListID(id int) *NodeUpdateOne
SetNodeListID sets the "node_list" edge to the NodeList entity by ID.
func (*NodeUpdateOne) SetReleaseDate ¶
func (nuo *NodeUpdateOne) SetReleaseDate(t time.Time) *NodeUpdateOne
SetReleaseDate sets the "release_date" field.
func (*NodeUpdateOne) SetSourceInfo ¶
func (nuo *NodeUpdateOne) SetSourceInfo(s string) *NodeUpdateOne
SetSourceInfo sets the "source_info" field.
func (*NodeUpdateOne) SetSummary ¶
func (nuo *NodeUpdateOne) SetSummary(s string) *NodeUpdateOne
SetSummary sets the "summary" field.
func (*NodeUpdateOne) SetType ¶
func (nuo *NodeUpdateOne) SetType(n node.Type) *NodeUpdateOne
SetType sets the "type" field.
func (*NodeUpdateOne) SetURLDownload ¶
func (nuo *NodeUpdateOne) SetURLDownload(s string) *NodeUpdateOne
SetURLDownload sets the "url_download" field.
func (*NodeUpdateOne) SetURLHome ¶
func (nuo *NodeUpdateOne) SetURLHome(s string) *NodeUpdateOne
SetURLHome sets the "url_home" field.
func (*NodeUpdateOne) SetValidUntilDate ¶
func (nuo *NodeUpdateOne) SetValidUntilDate(t time.Time) *NodeUpdateOne
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeUpdateOne) SetVersion ¶
func (nuo *NodeUpdateOne) SetVersion(s string) *NodeUpdateOne
SetVersion sets the "version" field.
func (*NodeUpdateOne) Where ¶
func (nuo *NodeUpdateOne) Where(ps ...predicate.Node) *NodeUpdateOne
Where appends a list predicates to the NodeUpdate builder.
type NodeUpsert ¶
NodeUpsert is the "OnConflict" setter.
func (*NodeUpsert) SetAttribution ¶
func (u *NodeUpsert) SetAttribution(v []string) *NodeUpsert
SetAttribution sets the "attribution" field.
func (*NodeUpsert) SetBuildDate ¶
func (u *NodeUpsert) SetBuildDate(v time.Time) *NodeUpsert
SetBuildDate sets the "build_date" field.
func (*NodeUpsert) SetComment ¶
func (u *NodeUpsert) SetComment(v string) *NodeUpsert
SetComment sets the "comment" field.
func (*NodeUpsert) SetCopyright ¶
func (u *NodeUpsert) SetCopyright(v string) *NodeUpsert
SetCopyright sets the "copyright" field.
func (*NodeUpsert) SetDescription ¶
func (u *NodeUpsert) SetDescription(v string) *NodeUpsert
SetDescription sets the "description" field.
func (*NodeUpsert) SetFileName ¶
func (u *NodeUpsert) SetFileName(v string) *NodeUpsert
SetFileName sets the "file_name" field.
func (*NodeUpsert) SetFileTypes ¶
func (u *NodeUpsert) SetFileTypes(v []string) *NodeUpsert
SetFileTypes sets the "file_types" field.
func (*NodeUpsert) SetLicenseComments ¶
func (u *NodeUpsert) SetLicenseComments(v string) *NodeUpsert
SetLicenseComments sets the "license_comments" field.
func (*NodeUpsert) SetLicenseConcluded ¶
func (u *NodeUpsert) SetLicenseConcluded(v string) *NodeUpsert
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeUpsert) SetLicenses ¶
func (u *NodeUpsert) SetLicenses(v []string) *NodeUpsert
SetLicenses sets the "licenses" field.
func (*NodeUpsert) SetName ¶
func (u *NodeUpsert) SetName(v string) *NodeUpsert
SetName sets the "name" field.
func (*NodeUpsert) SetReleaseDate ¶
func (u *NodeUpsert) SetReleaseDate(v time.Time) *NodeUpsert
SetReleaseDate sets the "release_date" field.
func (*NodeUpsert) SetSourceInfo ¶
func (u *NodeUpsert) SetSourceInfo(v string) *NodeUpsert
SetSourceInfo sets the "source_info" field.
func (*NodeUpsert) SetSummary ¶
func (u *NodeUpsert) SetSummary(v string) *NodeUpsert
SetSummary sets the "summary" field.
func (*NodeUpsert) SetType ¶
func (u *NodeUpsert) SetType(v node.Type) *NodeUpsert
SetType sets the "type" field.
func (*NodeUpsert) SetURLDownload ¶
func (u *NodeUpsert) SetURLDownload(v string) *NodeUpsert
SetURLDownload sets the "url_download" field.
func (*NodeUpsert) SetURLHome ¶
func (u *NodeUpsert) SetURLHome(v string) *NodeUpsert
SetURLHome sets the "url_home" field.
func (*NodeUpsert) SetValidUntilDate ¶
func (u *NodeUpsert) SetValidUntilDate(v time.Time) *NodeUpsert
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeUpsert) SetVersion ¶
func (u *NodeUpsert) SetVersion(v string) *NodeUpsert
SetVersion sets the "version" field.
func (*NodeUpsert) UpdateAttribution ¶
func (u *NodeUpsert) UpdateAttribution() *NodeUpsert
UpdateAttribution sets the "attribution" field to the value that was provided on create.
func (*NodeUpsert) UpdateBuildDate ¶
func (u *NodeUpsert) UpdateBuildDate() *NodeUpsert
UpdateBuildDate sets the "build_date" field to the value that was provided on create.
func (*NodeUpsert) UpdateComment ¶
func (u *NodeUpsert) UpdateComment() *NodeUpsert
UpdateComment sets the "comment" field to the value that was provided on create.
func (*NodeUpsert) UpdateCopyright ¶
func (u *NodeUpsert) UpdateCopyright() *NodeUpsert
UpdateCopyright sets the "copyright" field to the value that was provided on create.
func (*NodeUpsert) UpdateDescription ¶
func (u *NodeUpsert) UpdateDescription() *NodeUpsert
UpdateDescription sets the "description" field to the value that was provided on create.
func (*NodeUpsert) UpdateFileName ¶
func (u *NodeUpsert) UpdateFileName() *NodeUpsert
UpdateFileName sets the "file_name" field to the value that was provided on create.
func (*NodeUpsert) UpdateFileTypes ¶
func (u *NodeUpsert) UpdateFileTypes() *NodeUpsert
UpdateFileTypes sets the "file_types" field to the value that was provided on create.
func (*NodeUpsert) UpdateLicenseComments ¶
func (u *NodeUpsert) UpdateLicenseComments() *NodeUpsert
UpdateLicenseComments sets the "license_comments" field to the value that was provided on create.
func (*NodeUpsert) UpdateLicenseConcluded ¶
func (u *NodeUpsert) UpdateLicenseConcluded() *NodeUpsert
UpdateLicenseConcluded sets the "license_concluded" field to the value that was provided on create.
func (*NodeUpsert) UpdateLicenses ¶
func (u *NodeUpsert) UpdateLicenses() *NodeUpsert
UpdateLicenses sets the "licenses" field to the value that was provided on create.
func (*NodeUpsert) UpdateName ¶
func (u *NodeUpsert) UpdateName() *NodeUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*NodeUpsert) UpdateReleaseDate ¶
func (u *NodeUpsert) UpdateReleaseDate() *NodeUpsert
UpdateReleaseDate sets the "release_date" field to the value that was provided on create.
func (*NodeUpsert) UpdateSourceInfo ¶
func (u *NodeUpsert) UpdateSourceInfo() *NodeUpsert
UpdateSourceInfo sets the "source_info" field to the value that was provided on create.
func (*NodeUpsert) UpdateSummary ¶
func (u *NodeUpsert) UpdateSummary() *NodeUpsert
UpdateSummary sets the "summary" field to the value that was provided on create.
func (*NodeUpsert) UpdateType ¶
func (u *NodeUpsert) UpdateType() *NodeUpsert
UpdateType sets the "type" field to the value that was provided on create.
func (*NodeUpsert) UpdateURLDownload ¶
func (u *NodeUpsert) UpdateURLDownload() *NodeUpsert
UpdateURLDownload sets the "url_download" field to the value that was provided on create.
func (*NodeUpsert) UpdateURLHome ¶
func (u *NodeUpsert) UpdateURLHome() *NodeUpsert
UpdateURLHome sets the "url_home" field to the value that was provided on create.
func (*NodeUpsert) UpdateValidUntilDate ¶
func (u *NodeUpsert) UpdateValidUntilDate() *NodeUpsert
UpdateValidUntilDate sets the "valid_until_date" field to the value that was provided on create.
func (*NodeUpsert) UpdateVersion ¶
func (u *NodeUpsert) UpdateVersion() *NodeUpsert
UpdateVersion sets the "version" field to the value that was provided on create.
type NodeUpsertBulk ¶
type NodeUpsertBulk struct {
// contains filtered or unexported fields
}
NodeUpsertBulk is the builder for "upsert"-ing a bulk of Node nodes.
func (*NodeUpsertBulk) DoNothing ¶
func (u *NodeUpsertBulk) DoNothing() *NodeUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*NodeUpsertBulk) Exec ¶
func (u *NodeUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeUpsertBulk) ExecX ¶
func (u *NodeUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeUpsertBulk) Ignore ¶
func (u *NodeUpsertBulk) Ignore() *NodeUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Node.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*NodeUpsertBulk) SetAttribution ¶
func (u *NodeUpsertBulk) SetAttribution(v []string) *NodeUpsertBulk
SetAttribution sets the "attribution" field.
func (*NodeUpsertBulk) SetBuildDate ¶
func (u *NodeUpsertBulk) SetBuildDate(v time.Time) *NodeUpsertBulk
SetBuildDate sets the "build_date" field.
func (*NodeUpsertBulk) SetComment ¶
func (u *NodeUpsertBulk) SetComment(v string) *NodeUpsertBulk
SetComment sets the "comment" field.
func (*NodeUpsertBulk) SetCopyright ¶
func (u *NodeUpsertBulk) SetCopyright(v string) *NodeUpsertBulk
SetCopyright sets the "copyright" field.
func (*NodeUpsertBulk) SetDescription ¶
func (u *NodeUpsertBulk) SetDescription(v string) *NodeUpsertBulk
SetDescription sets the "description" field.
func (*NodeUpsertBulk) SetFileName ¶
func (u *NodeUpsertBulk) SetFileName(v string) *NodeUpsertBulk
SetFileName sets the "file_name" field.
func (*NodeUpsertBulk) SetFileTypes ¶
func (u *NodeUpsertBulk) SetFileTypes(v []string) *NodeUpsertBulk
SetFileTypes sets the "file_types" field.
func (*NodeUpsertBulk) SetLicenseComments ¶
func (u *NodeUpsertBulk) SetLicenseComments(v string) *NodeUpsertBulk
SetLicenseComments sets the "license_comments" field.
func (*NodeUpsertBulk) SetLicenseConcluded ¶
func (u *NodeUpsertBulk) SetLicenseConcluded(v string) *NodeUpsertBulk
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeUpsertBulk) SetLicenses ¶
func (u *NodeUpsertBulk) SetLicenses(v []string) *NodeUpsertBulk
SetLicenses sets the "licenses" field.
func (*NodeUpsertBulk) SetName ¶
func (u *NodeUpsertBulk) SetName(v string) *NodeUpsertBulk
SetName sets the "name" field.
func (*NodeUpsertBulk) SetReleaseDate ¶
func (u *NodeUpsertBulk) SetReleaseDate(v time.Time) *NodeUpsertBulk
SetReleaseDate sets the "release_date" field.
func (*NodeUpsertBulk) SetSourceInfo ¶
func (u *NodeUpsertBulk) SetSourceInfo(v string) *NodeUpsertBulk
SetSourceInfo sets the "source_info" field.
func (*NodeUpsertBulk) SetSummary ¶
func (u *NodeUpsertBulk) SetSummary(v string) *NodeUpsertBulk
SetSummary sets the "summary" field.
func (*NodeUpsertBulk) SetType ¶
func (u *NodeUpsertBulk) SetType(v node.Type) *NodeUpsertBulk
SetType sets the "type" field.
func (*NodeUpsertBulk) SetURLDownload ¶
func (u *NodeUpsertBulk) SetURLDownload(v string) *NodeUpsertBulk
SetURLDownload sets the "url_download" field.
func (*NodeUpsertBulk) SetURLHome ¶
func (u *NodeUpsertBulk) SetURLHome(v string) *NodeUpsertBulk
SetURLHome sets the "url_home" field.
func (*NodeUpsertBulk) SetValidUntilDate ¶
func (u *NodeUpsertBulk) SetValidUntilDate(v time.Time) *NodeUpsertBulk
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeUpsertBulk) SetVersion ¶
func (u *NodeUpsertBulk) SetVersion(v string) *NodeUpsertBulk
SetVersion sets the "version" field.
func (*NodeUpsertBulk) Update ¶
func (u *NodeUpsertBulk) Update(set func(*NodeUpsert)) *NodeUpsertBulk
Update allows overriding fields `UPDATE` values. See the NodeCreateBulk.OnConflict documentation for more info.
func (*NodeUpsertBulk) UpdateAttribution ¶
func (u *NodeUpsertBulk) UpdateAttribution() *NodeUpsertBulk
UpdateAttribution sets the "attribution" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateBuildDate ¶
func (u *NodeUpsertBulk) UpdateBuildDate() *NodeUpsertBulk
UpdateBuildDate sets the "build_date" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateComment ¶
func (u *NodeUpsertBulk) UpdateComment() *NodeUpsertBulk
UpdateComment sets the "comment" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateCopyright ¶
func (u *NodeUpsertBulk) UpdateCopyright() *NodeUpsertBulk
UpdateCopyright sets the "copyright" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateDescription ¶
func (u *NodeUpsertBulk) UpdateDescription() *NodeUpsertBulk
UpdateDescription sets the "description" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateFileName ¶
func (u *NodeUpsertBulk) UpdateFileName() *NodeUpsertBulk
UpdateFileName sets the "file_name" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateFileTypes ¶
func (u *NodeUpsertBulk) UpdateFileTypes() *NodeUpsertBulk
UpdateFileTypes sets the "file_types" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateLicenseComments ¶
func (u *NodeUpsertBulk) UpdateLicenseComments() *NodeUpsertBulk
UpdateLicenseComments sets the "license_comments" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateLicenseConcluded ¶
func (u *NodeUpsertBulk) UpdateLicenseConcluded() *NodeUpsertBulk
UpdateLicenseConcluded sets the "license_concluded" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateLicenses ¶
func (u *NodeUpsertBulk) UpdateLicenses() *NodeUpsertBulk
UpdateLicenses sets the "licenses" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateName ¶
func (u *NodeUpsertBulk) UpdateName() *NodeUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateNewValues ¶
func (u *NodeUpsertBulk) UpdateNewValues() *NodeUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Node.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(node.FieldID) }), ). Exec(ctx)
func (*NodeUpsertBulk) UpdateReleaseDate ¶
func (u *NodeUpsertBulk) UpdateReleaseDate() *NodeUpsertBulk
UpdateReleaseDate sets the "release_date" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateSourceInfo ¶
func (u *NodeUpsertBulk) UpdateSourceInfo() *NodeUpsertBulk
UpdateSourceInfo sets the "source_info" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateSummary ¶
func (u *NodeUpsertBulk) UpdateSummary() *NodeUpsertBulk
UpdateSummary sets the "summary" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateType ¶
func (u *NodeUpsertBulk) UpdateType() *NodeUpsertBulk
UpdateType sets the "type" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateURLDownload ¶
func (u *NodeUpsertBulk) UpdateURLDownload() *NodeUpsertBulk
UpdateURLDownload sets the "url_download" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateURLHome ¶
func (u *NodeUpsertBulk) UpdateURLHome() *NodeUpsertBulk
UpdateURLHome sets the "url_home" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateValidUntilDate ¶
func (u *NodeUpsertBulk) UpdateValidUntilDate() *NodeUpsertBulk
UpdateValidUntilDate sets the "valid_until_date" field to the value that was provided on create.
func (*NodeUpsertBulk) UpdateVersion ¶
func (u *NodeUpsertBulk) UpdateVersion() *NodeUpsertBulk
UpdateVersion sets the "version" field to the value that was provided on create.
type NodeUpsertOne ¶
type NodeUpsertOne struct {
// contains filtered or unexported fields
}
NodeUpsertOne is the builder for "upsert"-ing
one Node node.
func (*NodeUpsertOne) DoNothing ¶
func (u *NodeUpsertOne) DoNothing() *NodeUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*NodeUpsertOne) Exec ¶
func (u *NodeUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*NodeUpsertOne) ExecX ¶
func (u *NodeUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*NodeUpsertOne) ID ¶
func (u *NodeUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*NodeUpsertOne) IDX ¶
func (u *NodeUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*NodeUpsertOne) Ignore ¶
func (u *NodeUpsertOne) Ignore() *NodeUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Node.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*NodeUpsertOne) SetAttribution ¶
func (u *NodeUpsertOne) SetAttribution(v []string) *NodeUpsertOne
SetAttribution sets the "attribution" field.
func (*NodeUpsertOne) SetBuildDate ¶
func (u *NodeUpsertOne) SetBuildDate(v time.Time) *NodeUpsertOne
SetBuildDate sets the "build_date" field.
func (*NodeUpsertOne) SetComment ¶
func (u *NodeUpsertOne) SetComment(v string) *NodeUpsertOne
SetComment sets the "comment" field.
func (*NodeUpsertOne) SetCopyright ¶
func (u *NodeUpsertOne) SetCopyright(v string) *NodeUpsertOne
SetCopyright sets the "copyright" field.
func (*NodeUpsertOne) SetDescription ¶
func (u *NodeUpsertOne) SetDescription(v string) *NodeUpsertOne
SetDescription sets the "description" field.
func (*NodeUpsertOne) SetFileName ¶
func (u *NodeUpsertOne) SetFileName(v string) *NodeUpsertOne
SetFileName sets the "file_name" field.
func (*NodeUpsertOne) SetFileTypes ¶
func (u *NodeUpsertOne) SetFileTypes(v []string) *NodeUpsertOne
SetFileTypes sets the "file_types" field.
func (*NodeUpsertOne) SetLicenseComments ¶
func (u *NodeUpsertOne) SetLicenseComments(v string) *NodeUpsertOne
SetLicenseComments sets the "license_comments" field.
func (*NodeUpsertOne) SetLicenseConcluded ¶
func (u *NodeUpsertOne) SetLicenseConcluded(v string) *NodeUpsertOne
SetLicenseConcluded sets the "license_concluded" field.
func (*NodeUpsertOne) SetLicenses ¶
func (u *NodeUpsertOne) SetLicenses(v []string) *NodeUpsertOne
SetLicenses sets the "licenses" field.
func (*NodeUpsertOne) SetName ¶
func (u *NodeUpsertOne) SetName(v string) *NodeUpsertOne
SetName sets the "name" field.
func (*NodeUpsertOne) SetReleaseDate ¶
func (u *NodeUpsertOne) SetReleaseDate(v time.Time) *NodeUpsertOne
SetReleaseDate sets the "release_date" field.
func (*NodeUpsertOne) SetSourceInfo ¶
func (u *NodeUpsertOne) SetSourceInfo(v string) *NodeUpsertOne
SetSourceInfo sets the "source_info" field.
func (*NodeUpsertOne) SetSummary ¶
func (u *NodeUpsertOne) SetSummary(v string) *NodeUpsertOne
SetSummary sets the "summary" field.
func (*NodeUpsertOne) SetType ¶
func (u *NodeUpsertOne) SetType(v node.Type) *NodeUpsertOne
SetType sets the "type" field.
func (*NodeUpsertOne) SetURLDownload ¶
func (u *NodeUpsertOne) SetURLDownload(v string) *NodeUpsertOne
SetURLDownload sets the "url_download" field.
func (*NodeUpsertOne) SetURLHome ¶
func (u *NodeUpsertOne) SetURLHome(v string) *NodeUpsertOne
SetURLHome sets the "url_home" field.
func (*NodeUpsertOne) SetValidUntilDate ¶
func (u *NodeUpsertOne) SetValidUntilDate(v time.Time) *NodeUpsertOne
SetValidUntilDate sets the "valid_until_date" field.
func (*NodeUpsertOne) SetVersion ¶
func (u *NodeUpsertOne) SetVersion(v string) *NodeUpsertOne
SetVersion sets the "version" field.
func (*NodeUpsertOne) Update ¶
func (u *NodeUpsertOne) Update(set func(*NodeUpsert)) *NodeUpsertOne
Update allows overriding fields `UPDATE` values. See the NodeCreate.OnConflict documentation for more info.
func (*NodeUpsertOne) UpdateAttribution ¶
func (u *NodeUpsertOne) UpdateAttribution() *NodeUpsertOne
UpdateAttribution sets the "attribution" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateBuildDate ¶
func (u *NodeUpsertOne) UpdateBuildDate() *NodeUpsertOne
UpdateBuildDate sets the "build_date" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateComment ¶
func (u *NodeUpsertOne) UpdateComment() *NodeUpsertOne
UpdateComment sets the "comment" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateCopyright ¶
func (u *NodeUpsertOne) UpdateCopyright() *NodeUpsertOne
UpdateCopyright sets the "copyright" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateDescription ¶
func (u *NodeUpsertOne) UpdateDescription() *NodeUpsertOne
UpdateDescription sets the "description" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateFileName ¶
func (u *NodeUpsertOne) UpdateFileName() *NodeUpsertOne
UpdateFileName sets the "file_name" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateFileTypes ¶
func (u *NodeUpsertOne) UpdateFileTypes() *NodeUpsertOne
UpdateFileTypes sets the "file_types" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateLicenseComments ¶
func (u *NodeUpsertOne) UpdateLicenseComments() *NodeUpsertOne
UpdateLicenseComments sets the "license_comments" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateLicenseConcluded ¶
func (u *NodeUpsertOne) UpdateLicenseConcluded() *NodeUpsertOne
UpdateLicenseConcluded sets the "license_concluded" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateLicenses ¶
func (u *NodeUpsertOne) UpdateLicenses() *NodeUpsertOne
UpdateLicenses sets the "licenses" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateName ¶
func (u *NodeUpsertOne) UpdateName() *NodeUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateNewValues ¶
func (u *NodeUpsertOne) UpdateNewValues() *NodeUpsertOne
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.Node.Create(). OnConflict( sql.ResolveWithNewValues(), sql.ResolveWith(func(u *sql.UpdateSet) { u.SetIgnore(node.FieldID) }), ). Exec(ctx)
func (*NodeUpsertOne) UpdateReleaseDate ¶
func (u *NodeUpsertOne) UpdateReleaseDate() *NodeUpsertOne
UpdateReleaseDate sets the "release_date" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateSourceInfo ¶
func (u *NodeUpsertOne) UpdateSourceInfo() *NodeUpsertOne
UpdateSourceInfo sets the "source_info" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateSummary ¶
func (u *NodeUpsertOne) UpdateSummary() *NodeUpsertOne
UpdateSummary sets the "summary" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateType ¶
func (u *NodeUpsertOne) UpdateType() *NodeUpsertOne
UpdateType sets the "type" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateURLDownload ¶
func (u *NodeUpsertOne) UpdateURLDownload() *NodeUpsertOne
UpdateURLDownload sets the "url_download" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateURLHome ¶
func (u *NodeUpsertOne) UpdateURLHome() *NodeUpsertOne
UpdateURLHome sets the "url_home" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateValidUntilDate ¶
func (u *NodeUpsertOne) UpdateValidUntilDate() *NodeUpsertOne
UpdateValidUntilDate sets the "valid_until_date" field to the value that was provided on create.
func (*NodeUpsertOne) UpdateVersion ¶
func (u *NodeUpsertOne) UpdateVersion() *NodeUpsertOne
UpdateVersion sets the "version" field to the value that was provided on create.
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 OrderFunc ¶
OrderFunc applies an ordering on the sql selector. Deprecated: Use Asc/Desc functions or the package builders instead.
type Person ¶
type Person struct { // ID of the ent. ID int `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // IsOrg holds the value of the "is_org" field. IsOrg bool `json:"is_org,omitempty"` // Email holds the value of the "email" field. Email string `json:"email,omitempty"` // URL holds the value of the "url" field. URL string `json:"url,omitempty"` // Phone holds the value of the "phone" field. Phone string `json:"phone,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the PersonQuery when eager-loading is set. Edges PersonEdges `json:"edges"` // contains filtered or unexported fields }
Person is the model entity for the Person schema.
func (*Person) QueryContactOwner ¶
func (pe *Person) QueryContactOwner() *PersonQuery
QueryContactOwner queries the "contact_owner" edge of the Person entity.
func (*Person) QueryContacts ¶
func (pe *Person) QueryContacts() *PersonQuery
QueryContacts queries the "contacts" edge of the Person entity.
func (*Person) QueryMetadata ¶
func (pe *Person) QueryMetadata() *MetadataQuery
QueryMetadata queries the "metadata" edge of the Person entity.
func (*Person) Unwrap ¶
Unwrap unwraps the Person 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 (*Person) Update ¶
func (pe *Person) Update() *PersonUpdateOne
Update returns a builder for updating this Person. Note that you need to call Person.Unwrap() before calling this method if this Person was returned from a transaction, and the transaction was committed or rolled back.
type PersonClient ¶
type PersonClient struct {
// contains filtered or unexported fields
}
PersonClient is a client for the Person schema.
func NewPersonClient ¶
func NewPersonClient(c config) *PersonClient
NewPersonClient returns a client for the Person from the given config.
func (*PersonClient) Create ¶
func (c *PersonClient) Create() *PersonCreate
Create returns a builder for creating a Person entity.
func (*PersonClient) CreateBulk ¶
func (c *PersonClient) CreateBulk(builders ...*PersonCreate) *PersonCreateBulk
CreateBulk returns a builder for creating a bulk of Person entities.
func (*PersonClient) Delete ¶
func (c *PersonClient) Delete() *PersonDelete
Delete returns a delete builder for Person.
func (*PersonClient) DeleteOne ¶
func (c *PersonClient) DeleteOne(pe *Person) *PersonDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*PersonClient) DeleteOneID ¶
func (c *PersonClient) DeleteOneID(id int) *PersonDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*PersonClient) GetX ¶
func (c *PersonClient) GetX(ctx context.Context, id int) *Person
GetX is like Get, but panics if an error occurs.
func (*PersonClient) Intercept ¶
func (c *PersonClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `person.Intercept(f(g(h())))`.
func (*PersonClient) Interceptors ¶
func (c *PersonClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*PersonClient) MapCreateBulk ¶
func (c *PersonClient) MapCreateBulk(slice any, setFunc func(*PersonCreate, int)) *PersonCreateBulk
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 (*PersonClient) Query ¶
func (c *PersonClient) Query() *PersonQuery
Query returns a query builder for Person.
func (*PersonClient) QueryContactOwner ¶
func (c *PersonClient) QueryContactOwner(pe *Person) *PersonQuery
QueryContactOwner queries the contact_owner edge of a Person.
func (*PersonClient) QueryContacts ¶
func (c *PersonClient) QueryContacts(pe *Person) *PersonQuery
QueryContacts queries the contacts edge of a Person.
func (*PersonClient) QueryMetadata ¶
func (c *PersonClient) QueryMetadata(pe *Person) *MetadataQuery
QueryMetadata queries the metadata edge of a Person.
func (*PersonClient) QueryNode ¶
func (c *PersonClient) QueryNode(pe *Person) *NodeQuery
QueryNode queries the node edge of a Person.
func (*PersonClient) Update ¶
func (c *PersonClient) Update() *PersonUpdate
Update returns an update builder for Person.
func (*PersonClient) UpdateOne ¶
func (c *PersonClient) UpdateOne(pe *Person) *PersonUpdateOne
UpdateOne returns an update builder for the given entity.
func (*PersonClient) UpdateOneID ¶
func (c *PersonClient) UpdateOneID(id int) *PersonUpdateOne
UpdateOneID returns an update builder for the given id.
func (*PersonClient) Use ¶
func (c *PersonClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `person.Hooks(f(g(h())))`.
type PersonCreate ¶
type PersonCreate struct {
// contains filtered or unexported fields
}
PersonCreate is the builder for creating a Person entity.
func (*PersonCreate) AddContactIDs ¶
func (pc *PersonCreate) AddContactIDs(ids ...int) *PersonCreate
AddContactIDs adds the "contacts" edge to the Person entity by IDs.
func (*PersonCreate) AddContacts ¶
func (pc *PersonCreate) AddContacts(p ...*Person) *PersonCreate
AddContacts adds the "contacts" edges to the Person entity.
func (*PersonCreate) Exec ¶
func (pc *PersonCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*PersonCreate) ExecX ¶
func (pc *PersonCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonCreate) Mutation ¶
func (pc *PersonCreate) Mutation() *PersonMutation
Mutation returns the PersonMutation object of the builder.
func (*PersonCreate) OnConflict ¶
func (pc *PersonCreate) OnConflict(opts ...sql.ConflictOption) *PersonUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Person.Create(). SetName(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.PersonUpsert) { SetName(v+v). }). Exec(ctx)
func (*PersonCreate) OnConflictColumns ¶
func (pc *PersonCreate) OnConflictColumns(columns ...string) *PersonUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Person.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*PersonCreate) Save ¶
func (pc *PersonCreate) Save(ctx context.Context) (*Person, error)
Save creates the Person in the database.
func (*PersonCreate) SaveX ¶
func (pc *PersonCreate) SaveX(ctx context.Context) *Person
SaveX calls Save and panics if Save returns an error.
func (*PersonCreate) SetContactOwner ¶
func (pc *PersonCreate) SetContactOwner(p *Person) *PersonCreate
SetContactOwner sets the "contact_owner" edge to the Person entity.
func (*PersonCreate) SetContactOwnerID ¶
func (pc *PersonCreate) SetContactOwnerID(id int) *PersonCreate
SetContactOwnerID sets the "contact_owner" edge to the Person entity by ID.
func (*PersonCreate) SetEmail ¶
func (pc *PersonCreate) SetEmail(s string) *PersonCreate
SetEmail sets the "email" field.
func (*PersonCreate) SetIsOrg ¶
func (pc *PersonCreate) SetIsOrg(b bool) *PersonCreate
SetIsOrg sets the "is_org" field.
func (*PersonCreate) SetMetadata ¶
func (pc *PersonCreate) SetMetadata(m *Metadata) *PersonCreate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*PersonCreate) SetMetadataID ¶
func (pc *PersonCreate) SetMetadataID(id string) *PersonCreate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*PersonCreate) SetName ¶
func (pc *PersonCreate) SetName(s string) *PersonCreate
SetName sets the "name" field.
func (*PersonCreate) SetNillableContactOwnerID ¶
func (pc *PersonCreate) SetNillableContactOwnerID(id *int) *PersonCreate
SetNillableContactOwnerID sets the "contact_owner" edge to the Person entity by ID if the given value is not nil.
func (*PersonCreate) SetNillableMetadataID ¶
func (pc *PersonCreate) SetNillableMetadataID(id *string) *PersonCreate
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*PersonCreate) SetNillableNodeID ¶
func (pc *PersonCreate) SetNillableNodeID(id *string) *PersonCreate
SetNillableNodeID sets the "node" edge to the Node entity by ID if the given value is not nil.
func (*PersonCreate) SetNode ¶
func (pc *PersonCreate) SetNode(n *Node) *PersonCreate
SetNode sets the "node" edge to the Node entity.
func (*PersonCreate) SetNodeID ¶
func (pc *PersonCreate) SetNodeID(id string) *PersonCreate
SetNodeID sets the "node" edge to the Node entity by ID.
func (*PersonCreate) SetPhone ¶
func (pc *PersonCreate) SetPhone(s string) *PersonCreate
SetPhone sets the "phone" field.
func (*PersonCreate) SetURL ¶
func (pc *PersonCreate) SetURL(s string) *PersonCreate
SetURL sets the "url" field.
type PersonCreateBulk ¶
type PersonCreateBulk struct {
// contains filtered or unexported fields
}
PersonCreateBulk is the builder for creating many Person entities in bulk.
func (*PersonCreateBulk) Exec ¶
func (pcb *PersonCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*PersonCreateBulk) ExecX ¶
func (pcb *PersonCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonCreateBulk) OnConflict ¶
func (pcb *PersonCreateBulk) OnConflict(opts ...sql.ConflictOption) *PersonUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Person.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.PersonUpsert) { SetName(v+v). }). Exec(ctx)
func (*PersonCreateBulk) OnConflictColumns ¶
func (pcb *PersonCreateBulk) OnConflictColumns(columns ...string) *PersonUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Person.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type PersonDelete ¶
type PersonDelete struct {
// contains filtered or unexported fields
}
PersonDelete is the builder for deleting a Person entity.
func (*PersonDelete) Exec ¶
func (pd *PersonDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*PersonDelete) ExecX ¶
func (pd *PersonDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*PersonDelete) Where ¶
func (pd *PersonDelete) Where(ps ...predicate.Person) *PersonDelete
Where appends a list predicates to the PersonDelete builder.
type PersonDeleteOne ¶
type PersonDeleteOne struct {
// contains filtered or unexported fields
}
PersonDeleteOne is the builder for deleting a single Person entity.
func (*PersonDeleteOne) Exec ¶
func (pdo *PersonDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*PersonDeleteOne) ExecX ¶
func (pdo *PersonDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonDeleteOne) Where ¶
func (pdo *PersonDeleteOne) Where(ps ...predicate.Person) *PersonDeleteOne
Where appends a list predicates to the PersonDelete builder.
type PersonEdges ¶
type PersonEdges struct { // ContactOwner holds the value of the contact_owner edge. ContactOwner *Person `json:"contact_owner,omitempty"` // Contacts holds the value of the contacts edge. Contacts []*Person `json:"contacts,omitempty"` // Metadata holds the value of the metadata edge. Metadata *Metadata `json:"metadata,omitempty"` // Node holds the value of the node edge. Node *Node `json:"node,omitempty"` // contains filtered or unexported fields }
PersonEdges holds the relations/edges for other nodes in the graph.
func (PersonEdges) ContactOwnerOrErr ¶
func (e PersonEdges) ContactOwnerOrErr() (*Person, error)
ContactOwnerOrErr returns the ContactOwner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (PersonEdges) ContactsOrErr ¶
func (e PersonEdges) ContactsOrErr() ([]*Person, error)
ContactsOrErr returns the Contacts value or an error if the edge was not loaded in eager-loading.
func (PersonEdges) MetadataOrErr ¶
func (e PersonEdges) MetadataOrErr() (*Metadata, error)
MetadataOrErr returns the Metadata value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (PersonEdges) NodeOrErr ¶
func (e PersonEdges) NodeOrErr() (*Node, error)
NodeOrErr returns the Node value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type PersonGroupBy ¶
type PersonGroupBy struct {
// contains filtered or unexported fields
}
PersonGroupBy is the group-by builder for Person entities.
func (*PersonGroupBy) Aggregate ¶
func (pgb *PersonGroupBy) Aggregate(fns ...AggregateFunc) *PersonGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*PersonGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*PersonGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*PersonGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*PersonGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*PersonGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*PersonGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*PersonGroupBy) Scan ¶
func (pgb *PersonGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*PersonGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type PersonMutation ¶
type PersonMutation struct {
// contains filtered or unexported fields
}
PersonMutation represents an operation that mutates the Person nodes in the graph.
func (*PersonMutation) AddContactIDs ¶
func (m *PersonMutation) AddContactIDs(ids ...int)
AddContactIDs adds the "contacts" edge to the Person entity by ids.
func (*PersonMutation) AddField ¶
func (m *PersonMutation) 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 (*PersonMutation) AddedEdges ¶
func (m *PersonMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*PersonMutation) AddedField ¶
func (m *PersonMutation) 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 (*PersonMutation) AddedFields ¶
func (m *PersonMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*PersonMutation) AddedIDs ¶
func (m *PersonMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*PersonMutation) ClearContactOwner ¶
func (m *PersonMutation) ClearContactOwner()
ClearContactOwner clears the "contact_owner" edge to the Person entity.
func (*PersonMutation) ClearContacts ¶
func (m *PersonMutation) ClearContacts()
ClearContacts clears the "contacts" edge to the Person entity.
func (*PersonMutation) ClearEdge ¶
func (m *PersonMutation) 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 (*PersonMutation) ClearField ¶
func (m *PersonMutation) 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 (*PersonMutation) ClearMetadata ¶
func (m *PersonMutation) ClearMetadata()
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*PersonMutation) ClearNode ¶
func (m *PersonMutation) ClearNode()
ClearNode clears the "node" edge to the Node entity.
func (*PersonMutation) ClearedEdges ¶
func (m *PersonMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*PersonMutation) ClearedFields ¶
func (m *PersonMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (PersonMutation) Client ¶
func (m PersonMutation) 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 (*PersonMutation) ContactOwnerCleared ¶
func (m *PersonMutation) ContactOwnerCleared() bool
ContactOwnerCleared reports if the "contact_owner" edge to the Person entity was cleared.
func (*PersonMutation) ContactOwnerID ¶
func (m *PersonMutation) ContactOwnerID() (id int, exists bool)
ContactOwnerID returns the "contact_owner" edge ID in the mutation.
func (*PersonMutation) ContactOwnerIDs ¶
func (m *PersonMutation) ContactOwnerIDs() (ids []int)
ContactOwnerIDs returns the "contact_owner" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ContactOwnerID instead. It exists only for internal usage by the builders.
func (*PersonMutation) ContactsCleared ¶
func (m *PersonMutation) ContactsCleared() bool
ContactsCleared reports if the "contacts" edge to the Person entity was cleared.
func (*PersonMutation) ContactsIDs ¶
func (m *PersonMutation) ContactsIDs() (ids []int)
ContactsIDs returns the "contacts" edge IDs in the mutation.
func (*PersonMutation) EdgeCleared ¶
func (m *PersonMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*PersonMutation) Email ¶
func (m *PersonMutation) Email() (r string, exists bool)
Email returns the value of the "email" field in the mutation.
func (*PersonMutation) Field ¶
func (m *PersonMutation) 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 (*PersonMutation) FieldCleared ¶
func (m *PersonMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*PersonMutation) Fields ¶
func (m *PersonMutation) 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 (*PersonMutation) ID ¶
func (m *PersonMutation) 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 (*PersonMutation) IDs ¶
func (m *PersonMutation) 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 (*PersonMutation) IsOrg ¶
func (m *PersonMutation) IsOrg() (r bool, exists bool)
IsOrg returns the value of the "is_org" field in the mutation.
func (*PersonMutation) MetadataCleared ¶
func (m *PersonMutation) MetadataCleared() bool
MetadataCleared reports if the "metadata" edge to the Metadata entity was cleared.
func (*PersonMutation) MetadataID ¶
func (m *PersonMutation) MetadataID() (id string, exists bool)
MetadataID returns the "metadata" edge ID in the mutation.
func (*PersonMutation) MetadataIDs ¶
func (m *PersonMutation) MetadataIDs() (ids []string)
MetadataIDs returns the "metadata" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use MetadataID instead. It exists only for internal usage by the builders.
func (*PersonMutation) Name ¶
func (m *PersonMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*PersonMutation) NodeCleared ¶
func (m *PersonMutation) NodeCleared() bool
NodeCleared reports if the "node" edge to the Node entity was cleared.
func (*PersonMutation) NodeID ¶
func (m *PersonMutation) NodeID() (id string, exists bool)
NodeID returns the "node" edge ID in the mutation.
func (*PersonMutation) NodeIDs ¶
func (m *PersonMutation) NodeIDs() (ids []string)
NodeIDs returns the "node" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use NodeID instead. It exists only for internal usage by the builders.
func (*PersonMutation) OldEmail ¶
func (m *PersonMutation) OldEmail(ctx context.Context) (v string, err error)
OldEmail returns the old "email" field's value of the Person entity. If the Person 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 (*PersonMutation) 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 (*PersonMutation) OldIsOrg ¶
func (m *PersonMutation) OldIsOrg(ctx context.Context) (v bool, err error)
OldIsOrg returns the old "is_org" field's value of the Person entity. If the Person 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 (*PersonMutation) OldName ¶
func (m *PersonMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Person entity. If the Person 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 (*PersonMutation) OldPhone ¶
func (m *PersonMutation) OldPhone(ctx context.Context) (v string, err error)
OldPhone returns the old "phone" field's value of the Person entity. If the Person 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 (*PersonMutation) OldURL ¶
func (m *PersonMutation) OldURL(ctx context.Context) (v string, err error)
OldURL returns the old "url" field's value of the Person entity. If the Person 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 (*PersonMutation) Phone ¶
func (m *PersonMutation) Phone() (r string, exists bool)
Phone returns the value of the "phone" field in the mutation.
func (*PersonMutation) RemoveContactIDs ¶
func (m *PersonMutation) RemoveContactIDs(ids ...int)
RemoveContactIDs removes the "contacts" edge to the Person entity by IDs.
func (*PersonMutation) RemovedContactsIDs ¶
func (m *PersonMutation) RemovedContactsIDs() (ids []int)
RemovedContacts returns the removed IDs of the "contacts" edge to the Person entity.
func (*PersonMutation) RemovedEdges ¶
func (m *PersonMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*PersonMutation) RemovedIDs ¶
func (m *PersonMutation) 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 (*PersonMutation) ResetContactOwner ¶
func (m *PersonMutation) ResetContactOwner()
ResetContactOwner resets all changes to the "contact_owner" edge.
func (*PersonMutation) ResetContacts ¶
func (m *PersonMutation) ResetContacts()
ResetContacts resets all changes to the "contacts" edge.
func (*PersonMutation) ResetEdge ¶
func (m *PersonMutation) 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 (*PersonMutation) ResetEmail ¶
func (m *PersonMutation) ResetEmail()
ResetEmail resets all changes to the "email" field.
func (*PersonMutation) ResetField ¶
func (m *PersonMutation) 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 (*PersonMutation) ResetIsOrg ¶
func (m *PersonMutation) ResetIsOrg()
ResetIsOrg resets all changes to the "is_org" field.
func (*PersonMutation) ResetMetadata ¶
func (m *PersonMutation) ResetMetadata()
ResetMetadata resets all changes to the "metadata" edge.
func (*PersonMutation) ResetName ¶
func (m *PersonMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*PersonMutation) ResetNode ¶
func (m *PersonMutation) ResetNode()
ResetNode resets all changes to the "node" edge.
func (*PersonMutation) ResetPhone ¶
func (m *PersonMutation) ResetPhone()
ResetPhone resets all changes to the "phone" field.
func (*PersonMutation) ResetURL ¶
func (m *PersonMutation) ResetURL()
ResetURL resets all changes to the "url" field.
func (*PersonMutation) SetContactOwnerID ¶
func (m *PersonMutation) SetContactOwnerID(id int)
SetContactOwnerID sets the "contact_owner" edge to the Person entity by id.
func (*PersonMutation) SetEmail ¶
func (m *PersonMutation) SetEmail(s string)
SetEmail sets the "email" field.
func (*PersonMutation) SetField ¶
func (m *PersonMutation) 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 (*PersonMutation) SetIsOrg ¶
func (m *PersonMutation) SetIsOrg(b bool)
SetIsOrg sets the "is_org" field.
func (*PersonMutation) SetMetadataID ¶
func (m *PersonMutation) SetMetadataID(id string)
SetMetadataID sets the "metadata" edge to the Metadata entity by id.
func (*PersonMutation) SetName ¶
func (m *PersonMutation) SetName(s string)
SetName sets the "name" field.
func (*PersonMutation) SetNodeID ¶
func (m *PersonMutation) SetNodeID(id string)
SetNodeID sets the "node" edge to the Node entity by id.
func (*PersonMutation) SetOp ¶
func (m *PersonMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*PersonMutation) SetPhone ¶
func (m *PersonMutation) SetPhone(s string)
SetPhone sets the "phone" field.
func (*PersonMutation) SetURL ¶
func (m *PersonMutation) SetURL(s string)
SetURL sets the "url" field.
func (PersonMutation) Tx ¶
func (m PersonMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*PersonMutation) Type ¶
func (m *PersonMutation) Type() string
Type returns the node type of this mutation (Person).
func (*PersonMutation) URL ¶
func (m *PersonMutation) URL() (r string, exists bool)
URL returns the value of the "url" field in the mutation.
func (*PersonMutation) Where ¶
func (m *PersonMutation) Where(ps ...predicate.Person)
Where appends a list predicates to the PersonMutation builder.
func (*PersonMutation) WhereP ¶
func (m *PersonMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the PersonMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type PersonQuery ¶
type PersonQuery struct {
// contains filtered or unexported fields
}
PersonQuery is the builder for querying Person entities.
func (*PersonQuery) Aggregate ¶
func (pq *PersonQuery) Aggregate(fns ...AggregateFunc) *PersonSelect
Aggregate returns a PersonSelect configured with the given aggregations.
func (*PersonQuery) All ¶
func (pq *PersonQuery) All(ctx context.Context) ([]*Person, error)
All executes the query and returns a list of Persons.
func (*PersonQuery) AllX ¶
func (pq *PersonQuery) AllX(ctx context.Context) []*Person
AllX is like All, but panics if an error occurs.
func (*PersonQuery) Clone ¶
func (pq *PersonQuery) Clone() *PersonQuery
Clone returns a duplicate of the PersonQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*PersonQuery) Count ¶
func (pq *PersonQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*PersonQuery) CountX ¶
func (pq *PersonQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*PersonQuery) Exist ¶
func (pq *PersonQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*PersonQuery) ExistX ¶
func (pq *PersonQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*PersonQuery) First ¶
func (pq *PersonQuery) First(ctx context.Context) (*Person, error)
First returns the first Person entity from the query. Returns a *NotFoundError when no Person was found.
func (*PersonQuery) FirstID ¶
func (pq *PersonQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Person ID from the query. Returns a *NotFoundError when no Person ID was found.
func (*PersonQuery) FirstIDX ¶
func (pq *PersonQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*PersonQuery) FirstX ¶
func (pq *PersonQuery) FirstX(ctx context.Context) *Person
FirstX is like First, but panics if an error occurs.
func (*PersonQuery) GroupBy ¶
func (pq *PersonQuery) GroupBy(field string, fields ...string) *PersonGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Name string `json:"name,omitempty"` Count int `json:"count,omitempty"` } client.Person.Query(). GroupBy(person.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*PersonQuery) IDs ¶
func (pq *PersonQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of Person IDs.
func (*PersonQuery) IDsX ¶
func (pq *PersonQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*PersonQuery) Limit ¶
func (pq *PersonQuery) Limit(limit int) *PersonQuery
Limit the number of records to be returned by this query.
func (*PersonQuery) Offset ¶
func (pq *PersonQuery) Offset(offset int) *PersonQuery
Offset to start from.
func (*PersonQuery) Only ¶
func (pq *PersonQuery) Only(ctx context.Context) (*Person, error)
Only returns a single Person entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Person entity is found. Returns a *NotFoundError when no Person entities are found.
func (*PersonQuery) OnlyID ¶
func (pq *PersonQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Person ID in the query. Returns a *NotSingularError when more than one Person ID is found. Returns a *NotFoundError when no entities are found.
func (*PersonQuery) OnlyIDX ¶
func (pq *PersonQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*PersonQuery) OnlyX ¶
func (pq *PersonQuery) OnlyX(ctx context.Context) *Person
OnlyX is like Only, but panics if an error occurs.
func (*PersonQuery) Order ¶
func (pq *PersonQuery) Order(o ...person.OrderOption) *PersonQuery
Order specifies how the records should be ordered.
func (*PersonQuery) QueryContactOwner ¶
func (pq *PersonQuery) QueryContactOwner() *PersonQuery
QueryContactOwner chains the current query on the "contact_owner" edge.
func (*PersonQuery) QueryContacts ¶
func (pq *PersonQuery) QueryContacts() *PersonQuery
QueryContacts chains the current query on the "contacts" edge.
func (*PersonQuery) QueryMetadata ¶
func (pq *PersonQuery) QueryMetadata() *MetadataQuery
QueryMetadata chains the current query on the "metadata" edge.
func (*PersonQuery) QueryNode ¶
func (pq *PersonQuery) QueryNode() *NodeQuery
QueryNode chains the current query on the "node" edge.
func (*PersonQuery) Select ¶
func (pq *PersonQuery) Select(fields ...string) *PersonSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.Person.Query(). Select(person.FieldName). Scan(ctx, &v)
func (*PersonQuery) Unique ¶
func (pq *PersonQuery) Unique(unique bool) *PersonQuery
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 (*PersonQuery) Where ¶
func (pq *PersonQuery) Where(ps ...predicate.Person) *PersonQuery
Where adds a new predicate for the PersonQuery builder.
func (*PersonQuery) WithContactOwner ¶
func (pq *PersonQuery) WithContactOwner(opts ...func(*PersonQuery)) *PersonQuery
WithContactOwner tells the query-builder to eager-load the nodes that are connected to the "contact_owner" edge. The optional arguments are used to configure the query builder of the edge.
func (*PersonQuery) WithContacts ¶
func (pq *PersonQuery) WithContacts(opts ...func(*PersonQuery)) *PersonQuery
WithContacts tells the query-builder to eager-load the nodes that are connected to the "contacts" edge. The optional arguments are used to configure the query builder of the edge.
func (*PersonQuery) WithMetadata ¶
func (pq *PersonQuery) WithMetadata(opts ...func(*MetadataQuery)) *PersonQuery
WithMetadata tells the query-builder to eager-load the nodes that are connected to the "metadata" edge. The optional arguments are used to configure the query builder of the edge.
func (*PersonQuery) WithNode ¶
func (pq *PersonQuery) WithNode(opts ...func(*NodeQuery)) *PersonQuery
WithNode tells the query-builder to eager-load the nodes that are connected to the "node" edge. The optional arguments are used to configure the query builder of the edge.
type PersonSelect ¶
type PersonSelect struct { *PersonQuery // contains filtered or unexported fields }
PersonSelect is the builder for selecting fields of Person entities.
func (*PersonSelect) Aggregate ¶
func (ps *PersonSelect) Aggregate(fns ...AggregateFunc) *PersonSelect
Aggregate adds the given aggregation functions to the selector query.
func (*PersonSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*PersonSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*PersonSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*PersonSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*PersonSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*PersonSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*PersonSelect) Scan ¶
func (ps *PersonSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*PersonSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type PersonUpdate ¶
type PersonUpdate struct {
// contains filtered or unexported fields
}
PersonUpdate is the builder for updating Person entities.
func (*PersonUpdate) AddContactIDs ¶
func (pu *PersonUpdate) AddContactIDs(ids ...int) *PersonUpdate
AddContactIDs adds the "contacts" edge to the Person entity by IDs.
func (*PersonUpdate) AddContacts ¶
func (pu *PersonUpdate) AddContacts(p ...*Person) *PersonUpdate
AddContacts adds the "contacts" edges to the Person entity.
func (*PersonUpdate) ClearContactOwner ¶
func (pu *PersonUpdate) ClearContactOwner() *PersonUpdate
ClearContactOwner clears the "contact_owner" edge to the Person entity.
func (*PersonUpdate) ClearContacts ¶
func (pu *PersonUpdate) ClearContacts() *PersonUpdate
ClearContacts clears all "contacts" edges to the Person entity.
func (*PersonUpdate) ClearMetadata ¶
func (pu *PersonUpdate) ClearMetadata() *PersonUpdate
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*PersonUpdate) ClearNode ¶
func (pu *PersonUpdate) ClearNode() *PersonUpdate
ClearNode clears the "node" edge to the Node entity.
func (*PersonUpdate) Exec ¶
func (pu *PersonUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*PersonUpdate) ExecX ¶
func (pu *PersonUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonUpdate) Mutation ¶
func (pu *PersonUpdate) Mutation() *PersonMutation
Mutation returns the PersonMutation object of the builder.
func (*PersonUpdate) RemoveContactIDs ¶
func (pu *PersonUpdate) RemoveContactIDs(ids ...int) *PersonUpdate
RemoveContactIDs removes the "contacts" edge to Person entities by IDs.
func (*PersonUpdate) RemoveContacts ¶
func (pu *PersonUpdate) RemoveContacts(p ...*Person) *PersonUpdate
RemoveContacts removes "contacts" edges to Person entities.
func (*PersonUpdate) Save ¶
func (pu *PersonUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*PersonUpdate) SaveX ¶
func (pu *PersonUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*PersonUpdate) SetContactOwner ¶
func (pu *PersonUpdate) SetContactOwner(p *Person) *PersonUpdate
SetContactOwner sets the "contact_owner" edge to the Person entity.
func (*PersonUpdate) SetContactOwnerID ¶
func (pu *PersonUpdate) SetContactOwnerID(id int) *PersonUpdate
SetContactOwnerID sets the "contact_owner" edge to the Person entity by ID.
func (*PersonUpdate) SetEmail ¶
func (pu *PersonUpdate) SetEmail(s string) *PersonUpdate
SetEmail sets the "email" field.
func (*PersonUpdate) SetIsOrg ¶
func (pu *PersonUpdate) SetIsOrg(b bool) *PersonUpdate
SetIsOrg sets the "is_org" field.
func (*PersonUpdate) SetMetadata ¶
func (pu *PersonUpdate) SetMetadata(m *Metadata) *PersonUpdate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*PersonUpdate) SetMetadataID ¶
func (pu *PersonUpdate) SetMetadataID(id string) *PersonUpdate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*PersonUpdate) SetName ¶
func (pu *PersonUpdate) SetName(s string) *PersonUpdate
SetName sets the "name" field.
func (*PersonUpdate) SetNillableContactOwnerID ¶
func (pu *PersonUpdate) SetNillableContactOwnerID(id *int) *PersonUpdate
SetNillableContactOwnerID sets the "contact_owner" edge to the Person entity by ID if the given value is not nil.
func (*PersonUpdate) SetNillableEmail ¶
func (pu *PersonUpdate) SetNillableEmail(s *string) *PersonUpdate
SetNillableEmail sets the "email" field if the given value is not nil.
func (*PersonUpdate) SetNillableIsOrg ¶
func (pu *PersonUpdate) SetNillableIsOrg(b *bool) *PersonUpdate
SetNillableIsOrg sets the "is_org" field if the given value is not nil.
func (*PersonUpdate) SetNillableMetadataID ¶
func (pu *PersonUpdate) SetNillableMetadataID(id *string) *PersonUpdate
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*PersonUpdate) SetNillableName ¶
func (pu *PersonUpdate) SetNillableName(s *string) *PersonUpdate
SetNillableName sets the "name" field if the given value is not nil.
func (*PersonUpdate) SetNillableNodeID ¶
func (pu *PersonUpdate) SetNillableNodeID(id *string) *PersonUpdate
SetNillableNodeID sets the "node" edge to the Node entity by ID if the given value is not nil.
func (*PersonUpdate) SetNillablePhone ¶
func (pu *PersonUpdate) SetNillablePhone(s *string) *PersonUpdate
SetNillablePhone sets the "phone" field if the given value is not nil.
func (*PersonUpdate) SetNillableURL ¶
func (pu *PersonUpdate) SetNillableURL(s *string) *PersonUpdate
SetNillableURL sets the "url" field if the given value is not nil.
func (*PersonUpdate) SetNode ¶
func (pu *PersonUpdate) SetNode(n *Node) *PersonUpdate
SetNode sets the "node" edge to the Node entity.
func (*PersonUpdate) SetNodeID ¶
func (pu *PersonUpdate) SetNodeID(id string) *PersonUpdate
SetNodeID sets the "node" edge to the Node entity by ID.
func (*PersonUpdate) SetPhone ¶
func (pu *PersonUpdate) SetPhone(s string) *PersonUpdate
SetPhone sets the "phone" field.
func (*PersonUpdate) SetURL ¶
func (pu *PersonUpdate) SetURL(s string) *PersonUpdate
SetURL sets the "url" field.
func (*PersonUpdate) Where ¶
func (pu *PersonUpdate) Where(ps ...predicate.Person) *PersonUpdate
Where appends a list predicates to the PersonUpdate builder.
type PersonUpdateOne ¶
type PersonUpdateOne struct {
// contains filtered or unexported fields
}
PersonUpdateOne is the builder for updating a single Person entity.
func (*PersonUpdateOne) AddContactIDs ¶
func (puo *PersonUpdateOne) AddContactIDs(ids ...int) *PersonUpdateOne
AddContactIDs adds the "contacts" edge to the Person entity by IDs.
func (*PersonUpdateOne) AddContacts ¶
func (puo *PersonUpdateOne) AddContacts(p ...*Person) *PersonUpdateOne
AddContacts adds the "contacts" edges to the Person entity.
func (*PersonUpdateOne) ClearContactOwner ¶
func (puo *PersonUpdateOne) ClearContactOwner() *PersonUpdateOne
ClearContactOwner clears the "contact_owner" edge to the Person entity.
func (*PersonUpdateOne) ClearContacts ¶
func (puo *PersonUpdateOne) ClearContacts() *PersonUpdateOne
ClearContacts clears all "contacts" edges to the Person entity.
func (*PersonUpdateOne) ClearMetadata ¶
func (puo *PersonUpdateOne) ClearMetadata() *PersonUpdateOne
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*PersonUpdateOne) ClearNode ¶
func (puo *PersonUpdateOne) ClearNode() *PersonUpdateOne
ClearNode clears the "node" edge to the Node entity.
func (*PersonUpdateOne) Exec ¶
func (puo *PersonUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*PersonUpdateOne) ExecX ¶
func (puo *PersonUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonUpdateOne) Mutation ¶
func (puo *PersonUpdateOne) Mutation() *PersonMutation
Mutation returns the PersonMutation object of the builder.
func (*PersonUpdateOne) RemoveContactIDs ¶
func (puo *PersonUpdateOne) RemoveContactIDs(ids ...int) *PersonUpdateOne
RemoveContactIDs removes the "contacts" edge to Person entities by IDs.
func (*PersonUpdateOne) RemoveContacts ¶
func (puo *PersonUpdateOne) RemoveContacts(p ...*Person) *PersonUpdateOne
RemoveContacts removes "contacts" edges to Person entities.
func (*PersonUpdateOne) Save ¶
func (puo *PersonUpdateOne) Save(ctx context.Context) (*Person, error)
Save executes the query and returns the updated Person entity.
func (*PersonUpdateOne) SaveX ¶
func (puo *PersonUpdateOne) SaveX(ctx context.Context) *Person
SaveX is like Save, but panics if an error occurs.
func (*PersonUpdateOne) Select ¶
func (puo *PersonUpdateOne) Select(field string, fields ...string) *PersonUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*PersonUpdateOne) SetContactOwner ¶
func (puo *PersonUpdateOne) SetContactOwner(p *Person) *PersonUpdateOne
SetContactOwner sets the "contact_owner" edge to the Person entity.
func (*PersonUpdateOne) SetContactOwnerID ¶
func (puo *PersonUpdateOne) SetContactOwnerID(id int) *PersonUpdateOne
SetContactOwnerID sets the "contact_owner" edge to the Person entity by ID.
func (*PersonUpdateOne) SetEmail ¶
func (puo *PersonUpdateOne) SetEmail(s string) *PersonUpdateOne
SetEmail sets the "email" field.
func (*PersonUpdateOne) SetIsOrg ¶
func (puo *PersonUpdateOne) SetIsOrg(b bool) *PersonUpdateOne
SetIsOrg sets the "is_org" field.
func (*PersonUpdateOne) SetMetadata ¶
func (puo *PersonUpdateOne) SetMetadata(m *Metadata) *PersonUpdateOne
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*PersonUpdateOne) SetMetadataID ¶
func (puo *PersonUpdateOne) SetMetadataID(id string) *PersonUpdateOne
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*PersonUpdateOne) SetName ¶
func (puo *PersonUpdateOne) SetName(s string) *PersonUpdateOne
SetName sets the "name" field.
func (*PersonUpdateOne) SetNillableContactOwnerID ¶
func (puo *PersonUpdateOne) SetNillableContactOwnerID(id *int) *PersonUpdateOne
SetNillableContactOwnerID sets the "contact_owner" edge to the Person entity by ID if the given value is not nil.
func (*PersonUpdateOne) SetNillableEmail ¶
func (puo *PersonUpdateOne) SetNillableEmail(s *string) *PersonUpdateOne
SetNillableEmail sets the "email" field if the given value is not nil.
func (*PersonUpdateOne) SetNillableIsOrg ¶
func (puo *PersonUpdateOne) SetNillableIsOrg(b *bool) *PersonUpdateOne
SetNillableIsOrg sets the "is_org" field if the given value is not nil.
func (*PersonUpdateOne) SetNillableMetadataID ¶
func (puo *PersonUpdateOne) SetNillableMetadataID(id *string) *PersonUpdateOne
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*PersonUpdateOne) SetNillableName ¶
func (puo *PersonUpdateOne) SetNillableName(s *string) *PersonUpdateOne
SetNillableName sets the "name" field if the given value is not nil.
func (*PersonUpdateOne) SetNillableNodeID ¶
func (puo *PersonUpdateOne) SetNillableNodeID(id *string) *PersonUpdateOne
SetNillableNodeID sets the "node" edge to the Node entity by ID if the given value is not nil.
func (*PersonUpdateOne) SetNillablePhone ¶
func (puo *PersonUpdateOne) SetNillablePhone(s *string) *PersonUpdateOne
SetNillablePhone sets the "phone" field if the given value is not nil.
func (*PersonUpdateOne) SetNillableURL ¶
func (puo *PersonUpdateOne) SetNillableURL(s *string) *PersonUpdateOne
SetNillableURL sets the "url" field if the given value is not nil.
func (*PersonUpdateOne) SetNode ¶
func (puo *PersonUpdateOne) SetNode(n *Node) *PersonUpdateOne
SetNode sets the "node" edge to the Node entity.
func (*PersonUpdateOne) SetNodeID ¶
func (puo *PersonUpdateOne) SetNodeID(id string) *PersonUpdateOne
SetNodeID sets the "node" edge to the Node entity by ID.
func (*PersonUpdateOne) SetPhone ¶
func (puo *PersonUpdateOne) SetPhone(s string) *PersonUpdateOne
SetPhone sets the "phone" field.
func (*PersonUpdateOne) SetURL ¶
func (puo *PersonUpdateOne) SetURL(s string) *PersonUpdateOne
SetURL sets the "url" field.
func (*PersonUpdateOne) Where ¶
func (puo *PersonUpdateOne) Where(ps ...predicate.Person) *PersonUpdateOne
Where appends a list predicates to the PersonUpdate builder.
type PersonUpsert ¶
PersonUpsert is the "OnConflict" setter.
func (*PersonUpsert) SetEmail ¶
func (u *PersonUpsert) SetEmail(v string) *PersonUpsert
SetEmail sets the "email" field.
func (*PersonUpsert) SetIsOrg ¶
func (u *PersonUpsert) SetIsOrg(v bool) *PersonUpsert
SetIsOrg sets the "is_org" field.
func (*PersonUpsert) SetName ¶
func (u *PersonUpsert) SetName(v string) *PersonUpsert
SetName sets the "name" field.
func (*PersonUpsert) SetPhone ¶
func (u *PersonUpsert) SetPhone(v string) *PersonUpsert
SetPhone sets the "phone" field.
func (*PersonUpsert) SetURL ¶
func (u *PersonUpsert) SetURL(v string) *PersonUpsert
SetURL sets the "url" field.
func (*PersonUpsert) UpdateEmail ¶
func (u *PersonUpsert) UpdateEmail() *PersonUpsert
UpdateEmail sets the "email" field to the value that was provided on create.
func (*PersonUpsert) UpdateIsOrg ¶
func (u *PersonUpsert) UpdateIsOrg() *PersonUpsert
UpdateIsOrg sets the "is_org" field to the value that was provided on create.
func (*PersonUpsert) UpdateName ¶
func (u *PersonUpsert) UpdateName() *PersonUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*PersonUpsert) UpdatePhone ¶
func (u *PersonUpsert) UpdatePhone() *PersonUpsert
UpdatePhone sets the "phone" field to the value that was provided on create.
func (*PersonUpsert) UpdateURL ¶
func (u *PersonUpsert) UpdateURL() *PersonUpsert
UpdateURL sets the "url" field to the value that was provided on create.
type PersonUpsertBulk ¶
type PersonUpsertBulk struct {
// contains filtered or unexported fields
}
PersonUpsertBulk is the builder for "upsert"-ing a bulk of Person nodes.
func (*PersonUpsertBulk) DoNothing ¶
func (u *PersonUpsertBulk) DoNothing() *PersonUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*PersonUpsertBulk) Exec ¶
func (u *PersonUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*PersonUpsertBulk) ExecX ¶
func (u *PersonUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonUpsertBulk) Ignore ¶
func (u *PersonUpsertBulk) Ignore() *PersonUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Person.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*PersonUpsertBulk) SetEmail ¶
func (u *PersonUpsertBulk) SetEmail(v string) *PersonUpsertBulk
SetEmail sets the "email" field.
func (*PersonUpsertBulk) SetIsOrg ¶
func (u *PersonUpsertBulk) SetIsOrg(v bool) *PersonUpsertBulk
SetIsOrg sets the "is_org" field.
func (*PersonUpsertBulk) SetName ¶
func (u *PersonUpsertBulk) SetName(v string) *PersonUpsertBulk
SetName sets the "name" field.
func (*PersonUpsertBulk) SetPhone ¶
func (u *PersonUpsertBulk) SetPhone(v string) *PersonUpsertBulk
SetPhone sets the "phone" field.
func (*PersonUpsertBulk) SetURL ¶
func (u *PersonUpsertBulk) SetURL(v string) *PersonUpsertBulk
SetURL sets the "url" field.
func (*PersonUpsertBulk) Update ¶
func (u *PersonUpsertBulk) Update(set func(*PersonUpsert)) *PersonUpsertBulk
Update allows overriding fields `UPDATE` values. See the PersonCreateBulk.OnConflict documentation for more info.
func (*PersonUpsertBulk) UpdateEmail ¶
func (u *PersonUpsertBulk) UpdateEmail() *PersonUpsertBulk
UpdateEmail sets the "email" field to the value that was provided on create.
func (*PersonUpsertBulk) UpdateIsOrg ¶
func (u *PersonUpsertBulk) UpdateIsOrg() *PersonUpsertBulk
UpdateIsOrg sets the "is_org" field to the value that was provided on create.
func (*PersonUpsertBulk) UpdateName ¶
func (u *PersonUpsertBulk) UpdateName() *PersonUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*PersonUpsertBulk) UpdateNewValues ¶
func (u *PersonUpsertBulk) UpdateNewValues() *PersonUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Person.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*PersonUpsertBulk) UpdatePhone ¶
func (u *PersonUpsertBulk) UpdatePhone() *PersonUpsertBulk
UpdatePhone sets the "phone" field to the value that was provided on create.
func (*PersonUpsertBulk) UpdateURL ¶
func (u *PersonUpsertBulk) UpdateURL() *PersonUpsertBulk
UpdateURL sets the "url" field to the value that was provided on create.
type PersonUpsertOne ¶
type PersonUpsertOne struct {
// contains filtered or unexported fields
}
PersonUpsertOne is the builder for "upsert"-ing
one Person node.
func (*PersonUpsertOne) DoNothing ¶
func (u *PersonUpsertOne) DoNothing() *PersonUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*PersonUpsertOne) Exec ¶
func (u *PersonUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*PersonUpsertOne) ExecX ¶
func (u *PersonUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PersonUpsertOne) ID ¶
func (u *PersonUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*PersonUpsertOne) IDX ¶
func (u *PersonUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*PersonUpsertOne) Ignore ¶
func (u *PersonUpsertOne) Ignore() *PersonUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Person.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*PersonUpsertOne) SetEmail ¶
func (u *PersonUpsertOne) SetEmail(v string) *PersonUpsertOne
SetEmail sets the "email" field.
func (*PersonUpsertOne) SetIsOrg ¶
func (u *PersonUpsertOne) SetIsOrg(v bool) *PersonUpsertOne
SetIsOrg sets the "is_org" field.
func (*PersonUpsertOne) SetName ¶
func (u *PersonUpsertOne) SetName(v string) *PersonUpsertOne
SetName sets the "name" field.
func (*PersonUpsertOne) SetPhone ¶
func (u *PersonUpsertOne) SetPhone(v string) *PersonUpsertOne
SetPhone sets the "phone" field.
func (*PersonUpsertOne) SetURL ¶
func (u *PersonUpsertOne) SetURL(v string) *PersonUpsertOne
SetURL sets the "url" field.
func (*PersonUpsertOne) Update ¶
func (u *PersonUpsertOne) Update(set func(*PersonUpsert)) *PersonUpsertOne
Update allows overriding fields `UPDATE` values. See the PersonCreate.OnConflict documentation for more info.
func (*PersonUpsertOne) UpdateEmail ¶
func (u *PersonUpsertOne) UpdateEmail() *PersonUpsertOne
UpdateEmail sets the "email" field to the value that was provided on create.
func (*PersonUpsertOne) UpdateIsOrg ¶
func (u *PersonUpsertOne) UpdateIsOrg() *PersonUpsertOne
UpdateIsOrg sets the "is_org" field to the value that was provided on create.
func (*PersonUpsertOne) UpdateName ¶
func (u *PersonUpsertOne) UpdateName() *PersonUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*PersonUpsertOne) UpdateNewValues ¶
func (u *PersonUpsertOne) UpdateNewValues() *PersonUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Person.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*PersonUpsertOne) UpdatePhone ¶
func (u *PersonUpsertOne) UpdatePhone() *PersonUpsertOne
UpdatePhone sets the "phone" field to the value that was provided on create.
func (*PersonUpsertOne) UpdateURL ¶
func (u *PersonUpsertOne) UpdateURL() *PersonUpsertOne
UpdateURL sets the "url" field to the value that was provided on create.
type Purpose ¶
type Purpose struct { // ID of the ent. ID int `json:"id,omitempty"` // PrimaryPurpose holds the value of the "primary_purpose" field. PrimaryPurpose purpose.PrimaryPurpose `json:"primary_purpose,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the PurposeQuery when eager-loading is set. Edges PurposeEdges `json:"edges"` // contains filtered or unexported fields }
Purpose is the model entity for the Purpose schema.
func (*Purpose) Unwrap ¶
Unwrap unwraps the Purpose 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 (*Purpose) Update ¶
func (pu *Purpose) Update() *PurposeUpdateOne
Update returns a builder for updating this Purpose. Note that you need to call Purpose.Unwrap() before calling this method if this Purpose was returned from a transaction, and the transaction was committed or rolled back.
type PurposeClient ¶
type PurposeClient struct {
// contains filtered or unexported fields
}
PurposeClient is a client for the Purpose schema.
func NewPurposeClient ¶
func NewPurposeClient(c config) *PurposeClient
NewPurposeClient returns a client for the Purpose from the given config.
func (*PurposeClient) Create ¶
func (c *PurposeClient) Create() *PurposeCreate
Create returns a builder for creating a Purpose entity.
func (*PurposeClient) CreateBulk ¶
func (c *PurposeClient) CreateBulk(builders ...*PurposeCreate) *PurposeCreateBulk
CreateBulk returns a builder for creating a bulk of Purpose entities.
func (*PurposeClient) Delete ¶
func (c *PurposeClient) Delete() *PurposeDelete
Delete returns a delete builder for Purpose.
func (*PurposeClient) DeleteOne ¶
func (c *PurposeClient) DeleteOne(pu *Purpose) *PurposeDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*PurposeClient) DeleteOneID ¶
func (c *PurposeClient) DeleteOneID(id int) *PurposeDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*PurposeClient) GetX ¶
func (c *PurposeClient) GetX(ctx context.Context, id int) *Purpose
GetX is like Get, but panics if an error occurs.
func (*PurposeClient) Hooks ¶
func (c *PurposeClient) Hooks() []Hook
Hooks returns the client hooks.
func (*PurposeClient) Intercept ¶
func (c *PurposeClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `purpose.Intercept(f(g(h())))`.
func (*PurposeClient) Interceptors ¶
func (c *PurposeClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*PurposeClient) MapCreateBulk ¶
func (c *PurposeClient) MapCreateBulk(slice any, setFunc func(*PurposeCreate, int)) *PurposeCreateBulk
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 (*PurposeClient) Query ¶
func (c *PurposeClient) Query() *PurposeQuery
Query returns a query builder for Purpose.
func (*PurposeClient) QueryNode ¶
func (c *PurposeClient) QueryNode(pu *Purpose) *NodeQuery
QueryNode queries the node edge of a Purpose.
func (*PurposeClient) Update ¶
func (c *PurposeClient) Update() *PurposeUpdate
Update returns an update builder for Purpose.
func (*PurposeClient) UpdateOne ¶
func (c *PurposeClient) UpdateOne(pu *Purpose) *PurposeUpdateOne
UpdateOne returns an update builder for the given entity.
func (*PurposeClient) UpdateOneID ¶
func (c *PurposeClient) UpdateOneID(id int) *PurposeUpdateOne
UpdateOneID returns an update builder for the given id.
func (*PurposeClient) Use ¶
func (c *PurposeClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `purpose.Hooks(f(g(h())))`.
type PurposeCreate ¶
type PurposeCreate struct {
// contains filtered or unexported fields
}
PurposeCreate is the builder for creating a Purpose entity.
func (*PurposeCreate) AddNode ¶
func (pc *PurposeCreate) AddNode(n ...*Node) *PurposeCreate
AddNode adds the "node" edges to the Node entity.
func (*PurposeCreate) AddNodeIDs ¶
func (pc *PurposeCreate) AddNodeIDs(ids ...string) *PurposeCreate
AddNodeIDs adds the "node" edge to the Node entity by IDs.
func (*PurposeCreate) Exec ¶
func (pc *PurposeCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*PurposeCreate) ExecX ¶
func (pc *PurposeCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeCreate) Mutation ¶
func (pc *PurposeCreate) Mutation() *PurposeMutation
Mutation returns the PurposeMutation object of the builder.
func (*PurposeCreate) OnConflict ¶
func (pc *PurposeCreate) OnConflict(opts ...sql.ConflictOption) *PurposeUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Purpose.Create(). SetPrimaryPurpose(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.PurposeUpsert) { SetPrimaryPurpose(v+v). }). Exec(ctx)
func (*PurposeCreate) OnConflictColumns ¶
func (pc *PurposeCreate) OnConflictColumns(columns ...string) *PurposeUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Purpose.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*PurposeCreate) Save ¶
func (pc *PurposeCreate) Save(ctx context.Context) (*Purpose, error)
Save creates the Purpose in the database.
func (*PurposeCreate) SaveX ¶
func (pc *PurposeCreate) SaveX(ctx context.Context) *Purpose
SaveX calls Save and panics if Save returns an error.
func (*PurposeCreate) SetPrimaryPurpose ¶
func (pc *PurposeCreate) SetPrimaryPurpose(pp purpose.PrimaryPurpose) *PurposeCreate
SetPrimaryPurpose sets the "primary_purpose" field.
type PurposeCreateBulk ¶
type PurposeCreateBulk struct {
// contains filtered or unexported fields
}
PurposeCreateBulk is the builder for creating many Purpose entities in bulk.
func (*PurposeCreateBulk) Exec ¶
func (pcb *PurposeCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*PurposeCreateBulk) ExecX ¶
func (pcb *PurposeCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeCreateBulk) OnConflict ¶
func (pcb *PurposeCreateBulk) OnConflict(opts ...sql.ConflictOption) *PurposeUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Purpose.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.PurposeUpsert) { SetPrimaryPurpose(v+v). }). Exec(ctx)
func (*PurposeCreateBulk) OnConflictColumns ¶
func (pcb *PurposeCreateBulk) OnConflictColumns(columns ...string) *PurposeUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Purpose.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type PurposeDelete ¶
type PurposeDelete struct {
// contains filtered or unexported fields
}
PurposeDelete is the builder for deleting a Purpose entity.
func (*PurposeDelete) Exec ¶
func (pd *PurposeDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*PurposeDelete) ExecX ¶
func (pd *PurposeDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*PurposeDelete) Where ¶
func (pd *PurposeDelete) Where(ps ...predicate.Purpose) *PurposeDelete
Where appends a list predicates to the PurposeDelete builder.
type PurposeDeleteOne ¶
type PurposeDeleteOne struct {
// contains filtered or unexported fields
}
PurposeDeleteOne is the builder for deleting a single Purpose entity.
func (*PurposeDeleteOne) Exec ¶
func (pdo *PurposeDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*PurposeDeleteOne) ExecX ¶
func (pdo *PurposeDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeDeleteOne) Where ¶
func (pdo *PurposeDeleteOne) Where(ps ...predicate.Purpose) *PurposeDeleteOne
Where appends a list predicates to the PurposeDelete builder.
type PurposeEdges ¶
type PurposeEdges struct { // Node holds the value of the node edge. Node []*Node `json:"node,omitempty"` // contains filtered or unexported fields }
PurposeEdges holds the relations/edges for other nodes in the graph.
func (PurposeEdges) NodeOrErr ¶
func (e PurposeEdges) NodeOrErr() ([]*Node, error)
NodeOrErr returns the Node value or an error if the edge was not loaded in eager-loading.
type PurposeGroupBy ¶
type PurposeGroupBy struct {
// contains filtered or unexported fields
}
PurposeGroupBy is the group-by builder for Purpose entities.
func (*PurposeGroupBy) Aggregate ¶
func (pgb *PurposeGroupBy) Aggregate(fns ...AggregateFunc) *PurposeGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*PurposeGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*PurposeGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*PurposeGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*PurposeGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*PurposeGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*PurposeGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*PurposeGroupBy) Scan ¶
func (pgb *PurposeGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*PurposeGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type PurposeMutation ¶
type PurposeMutation struct {
// contains filtered or unexported fields
}
PurposeMutation represents an operation that mutates the Purpose nodes in the graph.
func (*PurposeMutation) AddField ¶
func (m *PurposeMutation) 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 (*PurposeMutation) AddNodeIDs ¶
func (m *PurposeMutation) AddNodeIDs(ids ...string)
AddNodeIDs adds the "node" edge to the Node entity by ids.
func (*PurposeMutation) AddedEdges ¶
func (m *PurposeMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*PurposeMutation) AddedField ¶
func (m *PurposeMutation) 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 (*PurposeMutation) AddedFields ¶
func (m *PurposeMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*PurposeMutation) AddedIDs ¶
func (m *PurposeMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*PurposeMutation) ClearEdge ¶
func (m *PurposeMutation) 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 (*PurposeMutation) ClearField ¶
func (m *PurposeMutation) 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 (*PurposeMutation) ClearNode ¶
func (m *PurposeMutation) ClearNode()
ClearNode clears the "node" edge to the Node entity.
func (*PurposeMutation) ClearedEdges ¶
func (m *PurposeMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*PurposeMutation) ClearedFields ¶
func (m *PurposeMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (PurposeMutation) Client ¶
func (m PurposeMutation) 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 (*PurposeMutation) EdgeCleared ¶
func (m *PurposeMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*PurposeMutation) Field ¶
func (m *PurposeMutation) 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 (*PurposeMutation) FieldCleared ¶
func (m *PurposeMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*PurposeMutation) Fields ¶
func (m *PurposeMutation) 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 (*PurposeMutation) ID ¶
func (m *PurposeMutation) 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 (*PurposeMutation) IDs ¶
func (m *PurposeMutation) 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 (*PurposeMutation) NodeCleared ¶
func (m *PurposeMutation) NodeCleared() bool
NodeCleared reports if the "node" edge to the Node entity was cleared.
func (*PurposeMutation) NodeIDs ¶
func (m *PurposeMutation) NodeIDs() (ids []string)
NodeIDs returns the "node" edge IDs in the mutation.
func (*PurposeMutation) 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 (*PurposeMutation) OldPrimaryPurpose ¶
func (m *PurposeMutation) OldPrimaryPurpose(ctx context.Context) (v purpose.PrimaryPurpose, err error)
OldPrimaryPurpose returns the old "primary_purpose" field's value of the Purpose entity. If the Purpose 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 (*PurposeMutation) PrimaryPurpose ¶
func (m *PurposeMutation) PrimaryPurpose() (r purpose.PrimaryPurpose, exists bool)
PrimaryPurpose returns the value of the "primary_purpose" field in the mutation.
func (*PurposeMutation) RemoveNodeIDs ¶
func (m *PurposeMutation) RemoveNodeIDs(ids ...string)
RemoveNodeIDs removes the "node" edge to the Node entity by IDs.
func (*PurposeMutation) RemovedEdges ¶
func (m *PurposeMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*PurposeMutation) RemovedIDs ¶
func (m *PurposeMutation) 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 (*PurposeMutation) RemovedNodeIDs ¶
func (m *PurposeMutation) RemovedNodeIDs() (ids []string)
RemovedNode returns the removed IDs of the "node" edge to the Node entity.
func (*PurposeMutation) ResetEdge ¶
func (m *PurposeMutation) 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 (*PurposeMutation) ResetField ¶
func (m *PurposeMutation) 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 (*PurposeMutation) ResetNode ¶
func (m *PurposeMutation) ResetNode()
ResetNode resets all changes to the "node" edge.
func (*PurposeMutation) ResetPrimaryPurpose ¶
func (m *PurposeMutation) ResetPrimaryPurpose()
ResetPrimaryPurpose resets all changes to the "primary_purpose" field.
func (*PurposeMutation) SetField ¶
func (m *PurposeMutation) 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 (*PurposeMutation) SetOp ¶
func (m *PurposeMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*PurposeMutation) SetPrimaryPurpose ¶
func (m *PurposeMutation) SetPrimaryPurpose(pp purpose.PrimaryPurpose)
SetPrimaryPurpose sets the "primary_purpose" field.
func (PurposeMutation) Tx ¶
func (m PurposeMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*PurposeMutation) Type ¶
func (m *PurposeMutation) Type() string
Type returns the node type of this mutation (Purpose).
func (*PurposeMutation) Where ¶
func (m *PurposeMutation) Where(ps ...predicate.Purpose)
Where appends a list predicates to the PurposeMutation builder.
func (*PurposeMutation) WhereP ¶
func (m *PurposeMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the PurposeMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type PurposeQuery ¶
type PurposeQuery struct {
// contains filtered or unexported fields
}
PurposeQuery is the builder for querying Purpose entities.
func (*PurposeQuery) Aggregate ¶
func (pq *PurposeQuery) Aggregate(fns ...AggregateFunc) *PurposeSelect
Aggregate returns a PurposeSelect configured with the given aggregations.
func (*PurposeQuery) All ¶
func (pq *PurposeQuery) All(ctx context.Context) ([]*Purpose, error)
All executes the query and returns a list of Purposes.
func (*PurposeQuery) AllX ¶
func (pq *PurposeQuery) AllX(ctx context.Context) []*Purpose
AllX is like All, but panics if an error occurs.
func (*PurposeQuery) Clone ¶
func (pq *PurposeQuery) Clone() *PurposeQuery
Clone returns a duplicate of the PurposeQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*PurposeQuery) Count ¶
func (pq *PurposeQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*PurposeQuery) CountX ¶
func (pq *PurposeQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*PurposeQuery) Exist ¶
func (pq *PurposeQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*PurposeQuery) ExistX ¶
func (pq *PurposeQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*PurposeQuery) First ¶
func (pq *PurposeQuery) First(ctx context.Context) (*Purpose, error)
First returns the first Purpose entity from the query. Returns a *NotFoundError when no Purpose was found.
func (*PurposeQuery) FirstID ¶
func (pq *PurposeQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Purpose ID from the query. Returns a *NotFoundError when no Purpose ID was found.
func (*PurposeQuery) FirstIDX ¶
func (pq *PurposeQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*PurposeQuery) FirstX ¶
func (pq *PurposeQuery) FirstX(ctx context.Context) *Purpose
FirstX is like First, but panics if an error occurs.
func (*PurposeQuery) GroupBy ¶
func (pq *PurposeQuery) GroupBy(field string, fields ...string) *PurposeGroupBy
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 { PrimaryPurpose purpose.PrimaryPurpose `json:"primary_purpose,omitempty"` Count int `json:"count,omitempty"` } client.Purpose.Query(). GroupBy(purpose.FieldPrimaryPurpose). Aggregate(ent.Count()). Scan(ctx, &v)
func (*PurposeQuery) IDs ¶
func (pq *PurposeQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of Purpose IDs.
func (*PurposeQuery) IDsX ¶
func (pq *PurposeQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*PurposeQuery) Limit ¶
func (pq *PurposeQuery) Limit(limit int) *PurposeQuery
Limit the number of records to be returned by this query.
func (*PurposeQuery) Offset ¶
func (pq *PurposeQuery) Offset(offset int) *PurposeQuery
Offset to start from.
func (*PurposeQuery) Only ¶
func (pq *PurposeQuery) Only(ctx context.Context) (*Purpose, error)
Only returns a single Purpose entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Purpose entity is found. Returns a *NotFoundError when no Purpose entities are found.
func (*PurposeQuery) OnlyID ¶
func (pq *PurposeQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Purpose ID in the query. Returns a *NotSingularError when more than one Purpose ID is found. Returns a *NotFoundError when no entities are found.
func (*PurposeQuery) OnlyIDX ¶
func (pq *PurposeQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*PurposeQuery) OnlyX ¶
func (pq *PurposeQuery) OnlyX(ctx context.Context) *Purpose
OnlyX is like Only, but panics if an error occurs.
func (*PurposeQuery) Order ¶
func (pq *PurposeQuery) Order(o ...purpose.OrderOption) *PurposeQuery
Order specifies how the records should be ordered.
func (*PurposeQuery) QueryNode ¶
func (pq *PurposeQuery) QueryNode() *NodeQuery
QueryNode chains the current query on the "node" edge.
func (*PurposeQuery) Select ¶
func (pq *PurposeQuery) Select(fields ...string) *PurposeSelect
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 { PrimaryPurpose purpose.PrimaryPurpose `json:"primary_purpose,omitempty"` } client.Purpose.Query(). Select(purpose.FieldPrimaryPurpose). Scan(ctx, &v)
func (*PurposeQuery) Unique ¶
func (pq *PurposeQuery) Unique(unique bool) *PurposeQuery
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 (*PurposeQuery) Where ¶
func (pq *PurposeQuery) Where(ps ...predicate.Purpose) *PurposeQuery
Where adds a new predicate for the PurposeQuery builder.
func (*PurposeQuery) WithNode ¶
func (pq *PurposeQuery) WithNode(opts ...func(*NodeQuery)) *PurposeQuery
WithNode tells the query-builder to eager-load the nodes that are connected to the "node" edge. The optional arguments are used to configure the query builder of the edge.
type PurposeSelect ¶
type PurposeSelect struct { *PurposeQuery // contains filtered or unexported fields }
PurposeSelect is the builder for selecting fields of Purpose entities.
func (*PurposeSelect) Aggregate ¶
func (ps *PurposeSelect) Aggregate(fns ...AggregateFunc) *PurposeSelect
Aggregate adds the given aggregation functions to the selector query.
func (*PurposeSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*PurposeSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*PurposeSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*PurposeSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*PurposeSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*PurposeSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*PurposeSelect) Scan ¶
func (ps *PurposeSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*PurposeSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type PurposeUpdate ¶
type PurposeUpdate struct {
// contains filtered or unexported fields
}
PurposeUpdate is the builder for updating Purpose entities.
func (*PurposeUpdate) AddNode ¶
func (pu *PurposeUpdate) AddNode(n ...*Node) *PurposeUpdate
AddNode adds the "node" edges to the Node entity.
func (*PurposeUpdate) AddNodeIDs ¶
func (pu *PurposeUpdate) AddNodeIDs(ids ...string) *PurposeUpdate
AddNodeIDs adds the "node" edge to the Node entity by IDs.
func (*PurposeUpdate) ClearNode ¶
func (pu *PurposeUpdate) ClearNode() *PurposeUpdate
ClearNode clears all "node" edges to the Node entity.
func (*PurposeUpdate) Exec ¶
func (pu *PurposeUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*PurposeUpdate) ExecX ¶
func (pu *PurposeUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeUpdate) Mutation ¶
func (pu *PurposeUpdate) Mutation() *PurposeMutation
Mutation returns the PurposeMutation object of the builder.
func (*PurposeUpdate) RemoveNode ¶
func (pu *PurposeUpdate) RemoveNode(n ...*Node) *PurposeUpdate
RemoveNode removes "node" edges to Node entities.
func (*PurposeUpdate) RemoveNodeIDs ¶
func (pu *PurposeUpdate) RemoveNodeIDs(ids ...string) *PurposeUpdate
RemoveNodeIDs removes the "node" edge to Node entities by IDs.
func (*PurposeUpdate) Save ¶
func (pu *PurposeUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*PurposeUpdate) SaveX ¶
func (pu *PurposeUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*PurposeUpdate) SetNillablePrimaryPurpose ¶
func (pu *PurposeUpdate) SetNillablePrimaryPurpose(pp *purpose.PrimaryPurpose) *PurposeUpdate
SetNillablePrimaryPurpose sets the "primary_purpose" field if the given value is not nil.
func (*PurposeUpdate) SetPrimaryPurpose ¶
func (pu *PurposeUpdate) SetPrimaryPurpose(pp purpose.PrimaryPurpose) *PurposeUpdate
SetPrimaryPurpose sets the "primary_purpose" field.
func (*PurposeUpdate) Where ¶
func (pu *PurposeUpdate) Where(ps ...predicate.Purpose) *PurposeUpdate
Where appends a list predicates to the PurposeUpdate builder.
type PurposeUpdateOne ¶
type PurposeUpdateOne struct {
// contains filtered or unexported fields
}
PurposeUpdateOne is the builder for updating a single Purpose entity.
func (*PurposeUpdateOne) AddNode ¶
func (puo *PurposeUpdateOne) AddNode(n ...*Node) *PurposeUpdateOne
AddNode adds the "node" edges to the Node entity.
func (*PurposeUpdateOne) AddNodeIDs ¶
func (puo *PurposeUpdateOne) AddNodeIDs(ids ...string) *PurposeUpdateOne
AddNodeIDs adds the "node" edge to the Node entity by IDs.
func (*PurposeUpdateOne) ClearNode ¶
func (puo *PurposeUpdateOne) ClearNode() *PurposeUpdateOne
ClearNode clears all "node" edges to the Node entity.
func (*PurposeUpdateOne) Exec ¶
func (puo *PurposeUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*PurposeUpdateOne) ExecX ¶
func (puo *PurposeUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeUpdateOne) Mutation ¶
func (puo *PurposeUpdateOne) Mutation() *PurposeMutation
Mutation returns the PurposeMutation object of the builder.
func (*PurposeUpdateOne) RemoveNode ¶
func (puo *PurposeUpdateOne) RemoveNode(n ...*Node) *PurposeUpdateOne
RemoveNode removes "node" edges to Node entities.
func (*PurposeUpdateOne) RemoveNodeIDs ¶
func (puo *PurposeUpdateOne) RemoveNodeIDs(ids ...string) *PurposeUpdateOne
RemoveNodeIDs removes the "node" edge to Node entities by IDs.
func (*PurposeUpdateOne) Save ¶
func (puo *PurposeUpdateOne) Save(ctx context.Context) (*Purpose, error)
Save executes the query and returns the updated Purpose entity.
func (*PurposeUpdateOne) SaveX ¶
func (puo *PurposeUpdateOne) SaveX(ctx context.Context) *Purpose
SaveX is like Save, but panics if an error occurs.
func (*PurposeUpdateOne) Select ¶
func (puo *PurposeUpdateOne) Select(field string, fields ...string) *PurposeUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*PurposeUpdateOne) SetNillablePrimaryPurpose ¶
func (puo *PurposeUpdateOne) SetNillablePrimaryPurpose(pp *purpose.PrimaryPurpose) *PurposeUpdateOne
SetNillablePrimaryPurpose sets the "primary_purpose" field if the given value is not nil.
func (*PurposeUpdateOne) SetPrimaryPurpose ¶
func (puo *PurposeUpdateOne) SetPrimaryPurpose(pp purpose.PrimaryPurpose) *PurposeUpdateOne
SetPrimaryPurpose sets the "primary_purpose" field.
func (*PurposeUpdateOne) Where ¶
func (puo *PurposeUpdateOne) Where(ps ...predicate.Purpose) *PurposeUpdateOne
Where appends a list predicates to the PurposeUpdate builder.
type PurposeUpsert ¶
PurposeUpsert is the "OnConflict" setter.
func (*PurposeUpsert) SetPrimaryPurpose ¶
func (u *PurposeUpsert) SetPrimaryPurpose(v purpose.PrimaryPurpose) *PurposeUpsert
SetPrimaryPurpose sets the "primary_purpose" field.
func (*PurposeUpsert) UpdatePrimaryPurpose ¶
func (u *PurposeUpsert) UpdatePrimaryPurpose() *PurposeUpsert
UpdatePrimaryPurpose sets the "primary_purpose" field to the value that was provided on create.
type PurposeUpsertBulk ¶
type PurposeUpsertBulk struct {
// contains filtered or unexported fields
}
PurposeUpsertBulk is the builder for "upsert"-ing a bulk of Purpose nodes.
func (*PurposeUpsertBulk) DoNothing ¶
func (u *PurposeUpsertBulk) DoNothing() *PurposeUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*PurposeUpsertBulk) Exec ¶
func (u *PurposeUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*PurposeUpsertBulk) ExecX ¶
func (u *PurposeUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeUpsertBulk) Ignore ¶
func (u *PurposeUpsertBulk) Ignore() *PurposeUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Purpose.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*PurposeUpsertBulk) SetPrimaryPurpose ¶
func (u *PurposeUpsertBulk) SetPrimaryPurpose(v purpose.PrimaryPurpose) *PurposeUpsertBulk
SetPrimaryPurpose sets the "primary_purpose" field.
func (*PurposeUpsertBulk) Update ¶
func (u *PurposeUpsertBulk) Update(set func(*PurposeUpsert)) *PurposeUpsertBulk
Update allows overriding fields `UPDATE` values. See the PurposeCreateBulk.OnConflict documentation for more info.
func (*PurposeUpsertBulk) UpdateNewValues ¶
func (u *PurposeUpsertBulk) UpdateNewValues() *PurposeUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Purpose.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*PurposeUpsertBulk) UpdatePrimaryPurpose ¶
func (u *PurposeUpsertBulk) UpdatePrimaryPurpose() *PurposeUpsertBulk
UpdatePrimaryPurpose sets the "primary_purpose" field to the value that was provided on create.
type PurposeUpsertOne ¶
type PurposeUpsertOne struct {
// contains filtered or unexported fields
}
PurposeUpsertOne is the builder for "upsert"-ing
one Purpose node.
func (*PurposeUpsertOne) DoNothing ¶
func (u *PurposeUpsertOne) DoNothing() *PurposeUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*PurposeUpsertOne) Exec ¶
func (u *PurposeUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*PurposeUpsertOne) ExecX ¶
func (u *PurposeUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PurposeUpsertOne) ID ¶
func (u *PurposeUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*PurposeUpsertOne) IDX ¶
func (u *PurposeUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*PurposeUpsertOne) Ignore ¶
func (u *PurposeUpsertOne) Ignore() *PurposeUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Purpose.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*PurposeUpsertOne) SetPrimaryPurpose ¶
func (u *PurposeUpsertOne) SetPrimaryPurpose(v purpose.PrimaryPurpose) *PurposeUpsertOne
SetPrimaryPurpose sets the "primary_purpose" field.
func (*PurposeUpsertOne) Update ¶
func (u *PurposeUpsertOne) Update(set func(*PurposeUpsert)) *PurposeUpsertOne
Update allows overriding fields `UPDATE` values. See the PurposeCreate.OnConflict documentation for more info.
func (*PurposeUpsertOne) UpdateNewValues ¶
func (u *PurposeUpsertOne) UpdateNewValues() *PurposeUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Purpose.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*PurposeUpsertOne) UpdatePrimaryPurpose ¶
func (u *PurposeUpsertOne) UpdatePrimaryPurpose() *PurposeUpsertOne
UpdatePrimaryPurpose sets the "primary_purpose" field to the value that was provided on create.
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 Tool ¶
type Tool struct { // ID of the ent. ID int `json:"id,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // Version holds the value of the "version" field. Version string `json:"version,omitempty"` // Vendor holds the value of the "vendor" field. Vendor string `json:"vendor,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the ToolQuery when eager-loading is set. Edges ToolEdges `json:"edges"` // contains filtered or unexported fields }
Tool is the model entity for the Tool schema.
func (*Tool) QueryMetadata ¶
func (t *Tool) QueryMetadata() *MetadataQuery
QueryMetadata queries the "metadata" edge of the Tool entity.
func (*Tool) Unwrap ¶
Unwrap unwraps the Tool 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 (*Tool) Update ¶
func (t *Tool) Update() *ToolUpdateOne
Update returns a builder for updating this Tool. Note that you need to call Tool.Unwrap() before calling this method if this Tool was returned from a transaction, and the transaction was committed or rolled back.
type ToolClient ¶
type ToolClient struct {
// contains filtered or unexported fields
}
ToolClient is a client for the Tool schema.
func NewToolClient ¶
func NewToolClient(c config) *ToolClient
NewToolClient returns a client for the Tool from the given config.
func (*ToolClient) Create ¶
func (c *ToolClient) Create() *ToolCreate
Create returns a builder for creating a Tool entity.
func (*ToolClient) CreateBulk ¶
func (c *ToolClient) CreateBulk(builders ...*ToolCreate) *ToolCreateBulk
CreateBulk returns a builder for creating a bulk of Tool entities.
func (*ToolClient) Delete ¶
func (c *ToolClient) Delete() *ToolDelete
Delete returns a delete builder for Tool.
func (*ToolClient) DeleteOne ¶
func (c *ToolClient) DeleteOne(t *Tool) *ToolDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*ToolClient) DeleteOneID ¶
func (c *ToolClient) DeleteOneID(id int) *ToolDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*ToolClient) GetX ¶
func (c *ToolClient) GetX(ctx context.Context, id int) *Tool
GetX is like Get, but panics if an error occurs.
func (*ToolClient) Intercept ¶
func (c *ToolClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `tool.Intercept(f(g(h())))`.
func (*ToolClient) Interceptors ¶
func (c *ToolClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*ToolClient) MapCreateBulk ¶
func (c *ToolClient) MapCreateBulk(slice any, setFunc func(*ToolCreate, int)) *ToolCreateBulk
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 (*ToolClient) Query ¶
func (c *ToolClient) Query() *ToolQuery
Query returns a query builder for Tool.
func (*ToolClient) QueryMetadata ¶
func (c *ToolClient) QueryMetadata(t *Tool) *MetadataQuery
QueryMetadata queries the metadata edge of a Tool.
func (*ToolClient) Update ¶
func (c *ToolClient) Update() *ToolUpdate
Update returns an update builder for Tool.
func (*ToolClient) UpdateOne ¶
func (c *ToolClient) UpdateOne(t *Tool) *ToolUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ToolClient) UpdateOneID ¶
func (c *ToolClient) UpdateOneID(id int) *ToolUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ToolClient) Use ¶
func (c *ToolClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `tool.Hooks(f(g(h())))`.
type ToolCreate ¶
type ToolCreate struct {
// contains filtered or unexported fields
}
ToolCreate is the builder for creating a Tool entity.
func (*ToolCreate) Exec ¶
func (tc *ToolCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ToolCreate) ExecX ¶
func (tc *ToolCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolCreate) Mutation ¶
func (tc *ToolCreate) Mutation() *ToolMutation
Mutation returns the ToolMutation object of the builder.
func (*ToolCreate) OnConflict ¶
func (tc *ToolCreate) OnConflict(opts ...sql.ConflictOption) *ToolUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Tool.Create(). SetName(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.ToolUpsert) { SetName(v+v). }). Exec(ctx)
func (*ToolCreate) OnConflictColumns ¶
func (tc *ToolCreate) OnConflictColumns(columns ...string) *ToolUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Tool.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*ToolCreate) Save ¶
func (tc *ToolCreate) Save(ctx context.Context) (*Tool, error)
Save creates the Tool in the database.
func (*ToolCreate) SaveX ¶
func (tc *ToolCreate) SaveX(ctx context.Context) *Tool
SaveX calls Save and panics if Save returns an error.
func (*ToolCreate) SetMetadata ¶
func (tc *ToolCreate) SetMetadata(m *Metadata) *ToolCreate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*ToolCreate) SetMetadataID ¶
func (tc *ToolCreate) SetMetadataID(id string) *ToolCreate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*ToolCreate) SetName ¶
func (tc *ToolCreate) SetName(s string) *ToolCreate
SetName sets the "name" field.
func (*ToolCreate) SetNillableMetadataID ¶
func (tc *ToolCreate) SetNillableMetadataID(id *string) *ToolCreate
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*ToolCreate) SetVendor ¶
func (tc *ToolCreate) SetVendor(s string) *ToolCreate
SetVendor sets the "vendor" field.
func (*ToolCreate) SetVersion ¶
func (tc *ToolCreate) SetVersion(s string) *ToolCreate
SetVersion sets the "version" field.
type ToolCreateBulk ¶
type ToolCreateBulk struct {
// contains filtered or unexported fields
}
ToolCreateBulk is the builder for creating many Tool entities in bulk.
func (*ToolCreateBulk) Exec ¶
func (tcb *ToolCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ToolCreateBulk) ExecX ¶
func (tcb *ToolCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolCreateBulk) OnConflict ¶
func (tcb *ToolCreateBulk) OnConflict(opts ...sql.ConflictOption) *ToolUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Tool.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.ToolUpsert) { SetName(v+v). }). Exec(ctx)
func (*ToolCreateBulk) OnConflictColumns ¶
func (tcb *ToolCreateBulk) OnConflictColumns(columns ...string) *ToolUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Tool.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type ToolDelete ¶
type ToolDelete struct {
// contains filtered or unexported fields
}
ToolDelete is the builder for deleting a Tool entity.
func (*ToolDelete) Exec ¶
func (td *ToolDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ToolDelete) ExecX ¶
func (td *ToolDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ToolDelete) Where ¶
func (td *ToolDelete) Where(ps ...predicate.Tool) *ToolDelete
Where appends a list predicates to the ToolDelete builder.
type ToolDeleteOne ¶
type ToolDeleteOne struct {
// contains filtered or unexported fields
}
ToolDeleteOne is the builder for deleting a single Tool entity.
func (*ToolDeleteOne) Exec ¶
func (tdo *ToolDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ToolDeleteOne) ExecX ¶
func (tdo *ToolDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolDeleteOne) Where ¶
func (tdo *ToolDeleteOne) Where(ps ...predicate.Tool) *ToolDeleteOne
Where appends a list predicates to the ToolDelete builder.
type ToolEdges ¶
type ToolEdges struct { // Metadata holds the value of the metadata edge. Metadata *Metadata `json:"metadata,omitempty"` // contains filtered or unexported fields }
ToolEdges holds the relations/edges for other nodes in the graph.
func (ToolEdges) MetadataOrErr ¶
MetadataOrErr returns the Metadata value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type ToolGroupBy ¶
type ToolGroupBy struct {
// contains filtered or unexported fields
}
ToolGroupBy is the group-by builder for Tool entities.
func (*ToolGroupBy) Aggregate ¶
func (tgb *ToolGroupBy) Aggregate(fns ...AggregateFunc) *ToolGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ToolGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ToolGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ToolGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ToolGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ToolGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ToolGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ToolGroupBy) Scan ¶
func (tgb *ToolGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ToolGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ToolMutation ¶
type ToolMutation struct {
// contains filtered or unexported fields
}
ToolMutation represents an operation that mutates the Tool nodes in the graph.
func (*ToolMutation) AddField ¶
func (m *ToolMutation) 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 (*ToolMutation) AddedEdges ¶
func (m *ToolMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ToolMutation) AddedField ¶
func (m *ToolMutation) 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 (*ToolMutation) AddedFields ¶
func (m *ToolMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ToolMutation) AddedIDs ¶
func (m *ToolMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ToolMutation) ClearEdge ¶
func (m *ToolMutation) 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 (*ToolMutation) ClearField ¶
func (m *ToolMutation) 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 (*ToolMutation) ClearMetadata ¶
func (m *ToolMutation) ClearMetadata()
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*ToolMutation) ClearedEdges ¶
func (m *ToolMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ToolMutation) ClearedFields ¶
func (m *ToolMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ToolMutation) Client ¶
func (m ToolMutation) 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 (*ToolMutation) EdgeCleared ¶
func (m *ToolMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ToolMutation) Field ¶
func (m *ToolMutation) 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 (*ToolMutation) FieldCleared ¶
func (m *ToolMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ToolMutation) Fields ¶
func (m *ToolMutation) 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 (*ToolMutation) ID ¶
func (m *ToolMutation) 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 (*ToolMutation) IDs ¶
func (m *ToolMutation) 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 (*ToolMutation) MetadataCleared ¶
func (m *ToolMutation) MetadataCleared() bool
MetadataCleared reports if the "metadata" edge to the Metadata entity was cleared.
func (*ToolMutation) MetadataID ¶
func (m *ToolMutation) MetadataID() (id string, exists bool)
MetadataID returns the "metadata" edge ID in the mutation.
func (*ToolMutation) MetadataIDs ¶
func (m *ToolMutation) MetadataIDs() (ids []string)
MetadataIDs returns the "metadata" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use MetadataID instead. It exists only for internal usage by the builders.
func (*ToolMutation) Name ¶
func (m *ToolMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*ToolMutation) 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 (*ToolMutation) OldName ¶
func (m *ToolMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Tool entity. If the Tool 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 (*ToolMutation) OldVendor ¶
func (m *ToolMutation) OldVendor(ctx context.Context) (v string, err error)
OldVendor returns the old "vendor" field's value of the Tool entity. If the Tool 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 (*ToolMutation) OldVersion ¶
func (m *ToolMutation) OldVersion(ctx context.Context) (v string, err error)
OldVersion returns the old "version" field's value of the Tool entity. If the Tool 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 (*ToolMutation) RemovedEdges ¶
func (m *ToolMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ToolMutation) RemovedIDs ¶
func (m *ToolMutation) 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 (*ToolMutation) ResetEdge ¶
func (m *ToolMutation) 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 (*ToolMutation) ResetField ¶
func (m *ToolMutation) 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 (*ToolMutation) ResetMetadata ¶
func (m *ToolMutation) ResetMetadata()
ResetMetadata resets all changes to the "metadata" edge.
func (*ToolMutation) ResetName ¶
func (m *ToolMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*ToolMutation) ResetVendor ¶
func (m *ToolMutation) ResetVendor()
ResetVendor resets all changes to the "vendor" field.
func (*ToolMutation) ResetVersion ¶
func (m *ToolMutation) ResetVersion()
ResetVersion resets all changes to the "version" field.
func (*ToolMutation) SetField ¶
func (m *ToolMutation) 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 (*ToolMutation) SetMetadataID ¶
func (m *ToolMutation) SetMetadataID(id string)
SetMetadataID sets the "metadata" edge to the Metadata entity by id.
func (*ToolMutation) SetName ¶
func (m *ToolMutation) SetName(s string)
SetName sets the "name" field.
func (*ToolMutation) SetOp ¶
func (m *ToolMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*ToolMutation) SetVendor ¶
func (m *ToolMutation) SetVendor(s string)
SetVendor sets the "vendor" field.
func (*ToolMutation) SetVersion ¶
func (m *ToolMutation) SetVersion(s string)
SetVersion sets the "version" field.
func (ToolMutation) Tx ¶
func (m ToolMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ToolMutation) Type ¶
func (m *ToolMutation) Type() string
Type returns the node type of this mutation (Tool).
func (*ToolMutation) Vendor ¶
func (m *ToolMutation) Vendor() (r string, exists bool)
Vendor returns the value of the "vendor" field in the mutation.
func (*ToolMutation) Version ¶
func (m *ToolMutation) Version() (r string, exists bool)
Version returns the value of the "version" field in the mutation.
func (*ToolMutation) Where ¶
func (m *ToolMutation) Where(ps ...predicate.Tool)
Where appends a list predicates to the ToolMutation builder.
func (*ToolMutation) WhereP ¶
func (m *ToolMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the ToolMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type ToolQuery ¶
type ToolQuery struct {
// contains filtered or unexported fields
}
ToolQuery is the builder for querying Tool entities.
func (*ToolQuery) Aggregate ¶
func (tq *ToolQuery) Aggregate(fns ...AggregateFunc) *ToolSelect
Aggregate returns a ToolSelect configured with the given aggregations.
func (*ToolQuery) Clone ¶
Clone returns a duplicate of the ToolQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ToolQuery) First ¶
First returns the first Tool entity from the query. Returns a *NotFoundError when no Tool was found.
func (*ToolQuery) FirstID ¶
FirstID returns the first Tool ID from the query. Returns a *NotFoundError when no Tool ID was found.
func (*ToolQuery) GroupBy ¶
func (tq *ToolQuery) GroupBy(field string, fields ...string) *ToolGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { Name string `json:"name,omitempty"` Count int `json:"count,omitempty"` } client.Tool.Query(). GroupBy(tool.FieldName). Aggregate(ent.Count()). Scan(ctx, &v)
func (*ToolQuery) Only ¶
Only returns a single Tool entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Tool entity is found. Returns a *NotFoundError when no Tool entities are found.
func (*ToolQuery) OnlyID ¶
OnlyID is like Only, but returns the only Tool ID in the query. Returns a *NotSingularError when more than one Tool ID is found. Returns a *NotFoundError when no entities are found.
func (*ToolQuery) Order ¶
func (tq *ToolQuery) Order(o ...tool.OrderOption) *ToolQuery
Order specifies how the records should be ordered.
func (*ToolQuery) QueryMetadata ¶
func (tq *ToolQuery) QueryMetadata() *MetadataQuery
QueryMetadata chains the current query on the "metadata" edge.
func (*ToolQuery) Select ¶
func (tq *ToolQuery) Select(fields ...string) *ToolSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { Name string `json:"name,omitempty"` } client.Tool.Query(). Select(tool.FieldName). Scan(ctx, &v)
func (*ToolQuery) 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 (*ToolQuery) WithMetadata ¶
func (tq *ToolQuery) WithMetadata(opts ...func(*MetadataQuery)) *ToolQuery
WithMetadata tells the query-builder to eager-load the nodes that are connected to the "metadata" edge. The optional arguments are used to configure the query builder of the edge.
type ToolSelect ¶
type ToolSelect struct { *ToolQuery // contains filtered or unexported fields }
ToolSelect is the builder for selecting fields of Tool entities.
func (*ToolSelect) Aggregate ¶
func (ts *ToolSelect) Aggregate(fns ...AggregateFunc) *ToolSelect
Aggregate adds the given aggregation functions to the selector query.
func (*ToolSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ToolSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ToolSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ToolSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ToolSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ToolSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ToolSelect) Scan ¶
func (ts *ToolSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ToolSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ToolUpdate ¶
type ToolUpdate struct {
// contains filtered or unexported fields
}
ToolUpdate is the builder for updating Tool entities.
func (*ToolUpdate) ClearMetadata ¶
func (tu *ToolUpdate) ClearMetadata() *ToolUpdate
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*ToolUpdate) Exec ¶
func (tu *ToolUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ToolUpdate) ExecX ¶
func (tu *ToolUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolUpdate) Mutation ¶
func (tu *ToolUpdate) Mutation() *ToolMutation
Mutation returns the ToolMutation object of the builder.
func (*ToolUpdate) Save ¶
func (tu *ToolUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ToolUpdate) SaveX ¶
func (tu *ToolUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ToolUpdate) SetMetadata ¶
func (tu *ToolUpdate) SetMetadata(m *Metadata) *ToolUpdate
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*ToolUpdate) SetMetadataID ¶
func (tu *ToolUpdate) SetMetadataID(id string) *ToolUpdate
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*ToolUpdate) SetName ¶
func (tu *ToolUpdate) SetName(s string) *ToolUpdate
SetName sets the "name" field.
func (*ToolUpdate) SetNillableMetadataID ¶
func (tu *ToolUpdate) SetNillableMetadataID(id *string) *ToolUpdate
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*ToolUpdate) SetNillableName ¶
func (tu *ToolUpdate) SetNillableName(s *string) *ToolUpdate
SetNillableName sets the "name" field if the given value is not nil.
func (*ToolUpdate) SetNillableVendor ¶
func (tu *ToolUpdate) SetNillableVendor(s *string) *ToolUpdate
SetNillableVendor sets the "vendor" field if the given value is not nil.
func (*ToolUpdate) SetNillableVersion ¶
func (tu *ToolUpdate) SetNillableVersion(s *string) *ToolUpdate
SetNillableVersion sets the "version" field if the given value is not nil.
func (*ToolUpdate) SetVendor ¶
func (tu *ToolUpdate) SetVendor(s string) *ToolUpdate
SetVendor sets the "vendor" field.
func (*ToolUpdate) SetVersion ¶
func (tu *ToolUpdate) SetVersion(s string) *ToolUpdate
SetVersion sets the "version" field.
func (*ToolUpdate) Where ¶
func (tu *ToolUpdate) Where(ps ...predicate.Tool) *ToolUpdate
Where appends a list predicates to the ToolUpdate builder.
type ToolUpdateOne ¶
type ToolUpdateOne struct {
// contains filtered or unexported fields
}
ToolUpdateOne is the builder for updating a single Tool entity.
func (*ToolUpdateOne) ClearMetadata ¶
func (tuo *ToolUpdateOne) ClearMetadata() *ToolUpdateOne
ClearMetadata clears the "metadata" edge to the Metadata entity.
func (*ToolUpdateOne) Exec ¶
func (tuo *ToolUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ToolUpdateOne) ExecX ¶
func (tuo *ToolUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolUpdateOne) Mutation ¶
func (tuo *ToolUpdateOne) Mutation() *ToolMutation
Mutation returns the ToolMutation object of the builder.
func (*ToolUpdateOne) Save ¶
func (tuo *ToolUpdateOne) Save(ctx context.Context) (*Tool, error)
Save executes the query and returns the updated Tool entity.
func (*ToolUpdateOne) SaveX ¶
func (tuo *ToolUpdateOne) SaveX(ctx context.Context) *Tool
SaveX is like Save, but panics if an error occurs.
func (*ToolUpdateOne) Select ¶
func (tuo *ToolUpdateOne) Select(field string, fields ...string) *ToolUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ToolUpdateOne) SetMetadata ¶
func (tuo *ToolUpdateOne) SetMetadata(m *Metadata) *ToolUpdateOne
SetMetadata sets the "metadata" edge to the Metadata entity.
func (*ToolUpdateOne) SetMetadataID ¶
func (tuo *ToolUpdateOne) SetMetadataID(id string) *ToolUpdateOne
SetMetadataID sets the "metadata" edge to the Metadata entity by ID.
func (*ToolUpdateOne) SetName ¶
func (tuo *ToolUpdateOne) SetName(s string) *ToolUpdateOne
SetName sets the "name" field.
func (*ToolUpdateOne) SetNillableMetadataID ¶
func (tuo *ToolUpdateOne) SetNillableMetadataID(id *string) *ToolUpdateOne
SetNillableMetadataID sets the "metadata" edge to the Metadata entity by ID if the given value is not nil.
func (*ToolUpdateOne) SetNillableName ¶
func (tuo *ToolUpdateOne) SetNillableName(s *string) *ToolUpdateOne
SetNillableName sets the "name" field if the given value is not nil.
func (*ToolUpdateOne) SetNillableVendor ¶
func (tuo *ToolUpdateOne) SetNillableVendor(s *string) *ToolUpdateOne
SetNillableVendor sets the "vendor" field if the given value is not nil.
func (*ToolUpdateOne) SetNillableVersion ¶
func (tuo *ToolUpdateOne) SetNillableVersion(s *string) *ToolUpdateOne
SetNillableVersion sets the "version" field if the given value is not nil.
func (*ToolUpdateOne) SetVendor ¶
func (tuo *ToolUpdateOne) SetVendor(s string) *ToolUpdateOne
SetVendor sets the "vendor" field.
func (*ToolUpdateOne) SetVersion ¶
func (tuo *ToolUpdateOne) SetVersion(s string) *ToolUpdateOne
SetVersion sets the "version" field.
func (*ToolUpdateOne) Where ¶
func (tuo *ToolUpdateOne) Where(ps ...predicate.Tool) *ToolUpdateOne
Where appends a list predicates to the ToolUpdate builder.
type ToolUpsert ¶
ToolUpsert is the "OnConflict" setter.
func (*ToolUpsert) SetName ¶
func (u *ToolUpsert) SetName(v string) *ToolUpsert
SetName sets the "name" field.
func (*ToolUpsert) SetVendor ¶
func (u *ToolUpsert) SetVendor(v string) *ToolUpsert
SetVendor sets the "vendor" field.
func (*ToolUpsert) SetVersion ¶
func (u *ToolUpsert) SetVersion(v string) *ToolUpsert
SetVersion sets the "version" field.
func (*ToolUpsert) UpdateName ¶
func (u *ToolUpsert) UpdateName() *ToolUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*ToolUpsert) UpdateVendor ¶
func (u *ToolUpsert) UpdateVendor() *ToolUpsert
UpdateVendor sets the "vendor" field to the value that was provided on create.
func (*ToolUpsert) UpdateVersion ¶
func (u *ToolUpsert) UpdateVersion() *ToolUpsert
UpdateVersion sets the "version" field to the value that was provided on create.
type ToolUpsertBulk ¶
type ToolUpsertBulk struct {
// contains filtered or unexported fields
}
ToolUpsertBulk is the builder for "upsert"-ing a bulk of Tool nodes.
func (*ToolUpsertBulk) DoNothing ¶
func (u *ToolUpsertBulk) DoNothing() *ToolUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ToolUpsertBulk) Exec ¶
func (u *ToolUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ToolUpsertBulk) ExecX ¶
func (u *ToolUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolUpsertBulk) Ignore ¶
func (u *ToolUpsertBulk) Ignore() *ToolUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Tool.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ToolUpsertBulk) SetName ¶
func (u *ToolUpsertBulk) SetName(v string) *ToolUpsertBulk
SetName sets the "name" field.
func (*ToolUpsertBulk) SetVendor ¶
func (u *ToolUpsertBulk) SetVendor(v string) *ToolUpsertBulk
SetVendor sets the "vendor" field.
func (*ToolUpsertBulk) SetVersion ¶
func (u *ToolUpsertBulk) SetVersion(v string) *ToolUpsertBulk
SetVersion sets the "version" field.
func (*ToolUpsertBulk) Update ¶
func (u *ToolUpsertBulk) Update(set func(*ToolUpsert)) *ToolUpsertBulk
Update allows overriding fields `UPDATE` values. See the ToolCreateBulk.OnConflict documentation for more info.
func (*ToolUpsertBulk) UpdateName ¶
func (u *ToolUpsertBulk) UpdateName() *ToolUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*ToolUpsertBulk) UpdateNewValues ¶
func (u *ToolUpsertBulk) UpdateNewValues() *ToolUpsertBulk
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Tool.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*ToolUpsertBulk) UpdateVendor ¶
func (u *ToolUpsertBulk) UpdateVendor() *ToolUpsertBulk
UpdateVendor sets the "vendor" field to the value that was provided on create.
func (*ToolUpsertBulk) UpdateVersion ¶
func (u *ToolUpsertBulk) UpdateVersion() *ToolUpsertBulk
UpdateVersion sets the "version" field to the value that was provided on create.
type ToolUpsertOne ¶
type ToolUpsertOne struct {
// contains filtered or unexported fields
}
ToolUpsertOne is the builder for "upsert"-ing
one Tool node.
func (*ToolUpsertOne) DoNothing ¶
func (u *ToolUpsertOne) DoNothing() *ToolUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ToolUpsertOne) Exec ¶
func (u *ToolUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*ToolUpsertOne) ExecX ¶
func (u *ToolUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ToolUpsertOne) ID ¶
func (u *ToolUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*ToolUpsertOne) IDX ¶
func (u *ToolUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*ToolUpsertOne) Ignore ¶
func (u *ToolUpsertOne) Ignore() *ToolUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Tool.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ToolUpsertOne) SetName ¶
func (u *ToolUpsertOne) SetName(v string) *ToolUpsertOne
SetName sets the "name" field.
func (*ToolUpsertOne) SetVendor ¶
func (u *ToolUpsertOne) SetVendor(v string) *ToolUpsertOne
SetVendor sets the "vendor" field.
func (*ToolUpsertOne) SetVersion ¶
func (u *ToolUpsertOne) SetVersion(v string) *ToolUpsertOne
SetVersion sets the "version" field.
func (*ToolUpsertOne) Update ¶
func (u *ToolUpsertOne) Update(set func(*ToolUpsert)) *ToolUpsertOne
Update allows overriding fields `UPDATE` values. See the ToolCreate.OnConflict documentation for more info.
func (*ToolUpsertOne) UpdateName ¶
func (u *ToolUpsertOne) UpdateName() *ToolUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*ToolUpsertOne) UpdateNewValues ¶
func (u *ToolUpsertOne) UpdateNewValues() *ToolUpsertOne
UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:
client.Tool.Create(). OnConflict( sql.ResolveWithNewValues(), ). Exec(ctx)
func (*ToolUpsertOne) UpdateVendor ¶
func (u *ToolUpsertOne) UpdateVendor() *ToolUpsertOne
UpdateVendor sets the "vendor" field to the value that was provided on create.
func (*ToolUpsertOne) UpdateVersion ¶
func (u *ToolUpsertOne) UpdateVersion() *ToolUpsertOne
UpdateVersion sets the "version" field to the value that was provided on create.
type TraverseFunc ¶
type TraverseFunc = ent.TraverseFunc
ent aliases to avoid import conflicts in user's code.
type Tx ¶
type Tx struct { // Document is the client for interacting with the Document builders. Document *DocumentClient // DocumentType is the client for interacting with the DocumentType builders. DocumentType *DocumentTypeClient // EdgeType is the client for interacting with the EdgeType builders. EdgeType *EdgeTypeClient // ExternalReference is the client for interacting with the ExternalReference builders. ExternalReference *ExternalReferenceClient // HashesEntry is the client for interacting with the HashesEntry builders. HashesEntry *HashesEntryClient // IdentifiersEntry is the client for interacting with the IdentifiersEntry builders. IdentifiersEntry *IdentifiersEntryClient // Metadata is the client for interacting with the Metadata builders. Metadata *MetadataClient // Node is the client for interacting with the Node builders. Node *NodeClient // NodeList is the client for interacting with the NodeList builders. NodeList *NodeListClient // Person is the client for interacting with the Person builders. Person *PersonClient // Purpose is the client for interacting with the Purpose builders. Purpose *PurposeClient // Tool is the client for interacting with the Tool builders. Tool *ToolClient // 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 ValidationError ¶
type ValidationError struct { Name string // Field or edge name. // contains filtered or unexported fields }
ValidationError returns when validating a field or edge fails.
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
Error implements the error interface.
func (*ValidationError) Unwrap ¶
func (e *ValidationError) Unwrap() error
Unwrap implements the errors.Wrapper interface.
Source Files ¶
- client.go
- document.go
- document_create.go
- document_delete.go
- document_query.go
- document_update.go
- documenttype.go
- documenttype_create.go
- documenttype_delete.go
- documenttype_query.go
- documenttype_update.go
- edgetype.go
- edgetype_create.go
- edgetype_delete.go
- edgetype_query.go
- edgetype_update.go
- ent.go
- externalreference.go
- externalreference_create.go
- externalreference_delete.go
- externalreference_query.go
- externalreference_update.go
- generate.go
- hashesentry.go
- hashesentry_create.go
- hashesentry_delete.go
- hashesentry_query.go
- hashesentry_update.go
- identifiersentry.go
- identifiersentry_create.go
- identifiersentry_delete.go
- identifiersentry_query.go
- identifiersentry_update.go
- metadata.go
- metadata_create.go
- metadata_delete.go
- metadata_query.go
- metadata_update.go
- mutation.go
- node.go
- node_create.go
- node_delete.go
- node_query.go
- node_update.go
- nodelist.go
- nodelist_create.go
- nodelist_delete.go
- nodelist_query.go
- nodelist_update.go
- person.go
- person_create.go
- person_delete.go
- person_query.go
- person_update.go
- purpose.go
- purpose_create.go
- purpose_delete.go
- purpose_query.go
- purpose_update.go
- runtime.go
- tool.go
- tool_create.go
- tool_delete.go
- tool_query.go
- tool_update.go
- tx.go
Directories ¶
Path | Synopsis |
---|---|
-------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 --------------------------------------------------------------
|
-------------------------------------------------------------- SPDX-FileCopyrightText: Copyright © 2024 The Protobom Authors SPDX-FileType: SOURCE SPDX-License-Identifier: Apache-2.0 -------------------------------------------------------------- |