Documentation ¶
Index ¶
- Constants
- func IsConstraintError(err error) bool
- func IsNotFound(err error) bool
- func IsNotLoaded(err error) bool
- func IsNotSingular(err error) bool
- func IsValidationError(err error) bool
- func MaskNotFound(err error) error
- func NewContext(parent context.Context, c *Client) context.Context
- func NewTxContext(parent context.Context, tx *Tx) context.Context
- type AggregateFunc
- type AuthStateCache
- type AuthStateCacheClient
- func (c *AuthStateCacheClient) Create() *AuthStateCacheCreate
- func (c *AuthStateCacheClient) CreateBulk(builders ...*AuthStateCacheCreate) *AuthStateCacheCreateBulk
- func (c *AuthStateCacheClient) Delete() *AuthStateCacheDelete
- func (c *AuthStateCacheClient) DeleteOne(asc *AuthStateCache) *AuthStateCacheDeleteOne
- func (c *AuthStateCacheClient) DeleteOneID(id string) *AuthStateCacheDeleteOne
- func (c *AuthStateCacheClient) Get(ctx context.Context, id string) (*AuthStateCache, error)
- func (c *AuthStateCacheClient) GetX(ctx context.Context, id string) *AuthStateCache
- func (c *AuthStateCacheClient) Hooks() []Hook
- func (c *AuthStateCacheClient) Query() *AuthStateCacheQuery
- func (c *AuthStateCacheClient) Update() *AuthStateCacheUpdate
- func (c *AuthStateCacheClient) UpdateOne(asc *AuthStateCache) *AuthStateCacheUpdateOne
- func (c *AuthStateCacheClient) UpdateOneID(id string) *AuthStateCacheUpdateOne
- func (c *AuthStateCacheClient) Use(hooks ...Hook)
- type AuthStateCacheCreate
- func (ascc *AuthStateCacheCreate) Exec(ctx context.Context) error
- func (ascc *AuthStateCacheCreate) ExecX(ctx context.Context)
- func (ascc *AuthStateCacheCreate) Mutation() *AuthStateCacheMutation
- func (ascc *AuthStateCacheCreate) OnConflict(opts ...sql.ConflictOption) *AuthStateCacheUpsertOne
- func (ascc *AuthStateCacheCreate) OnConflictColumns(columns ...string) *AuthStateCacheUpsertOne
- func (ascc *AuthStateCacheCreate) Save(ctx context.Context) (*AuthStateCache, error)
- func (ascc *AuthStateCacheCreate) SaveX(ctx context.Context) *AuthStateCache
- func (ascc *AuthStateCacheCreate) SetExpiresAt(i int64) *AuthStateCacheCreate
- func (ascc *AuthStateCacheCreate) SetID(s string) *AuthStateCacheCreate
- type AuthStateCacheCreateBulk
- func (asccb *AuthStateCacheCreateBulk) Exec(ctx context.Context) error
- func (asccb *AuthStateCacheCreateBulk) ExecX(ctx context.Context)
- func (asccb *AuthStateCacheCreateBulk) OnConflict(opts ...sql.ConflictOption) *AuthStateCacheUpsertBulk
- func (asccb *AuthStateCacheCreateBulk) OnConflictColumns(columns ...string) *AuthStateCacheUpsertBulk
- func (asccb *AuthStateCacheCreateBulk) Save(ctx context.Context) ([]*AuthStateCache, error)
- func (asccb *AuthStateCacheCreateBulk) SaveX(ctx context.Context) []*AuthStateCache
- type AuthStateCacheDelete
- type AuthStateCacheDeleteOne
- type AuthStateCacheGroupBy
- func (ascgb *AuthStateCacheGroupBy) Aggregate(fns ...AggregateFunc) *AuthStateCacheGroupBy
- func (ascgb *AuthStateCacheGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ascgb *AuthStateCacheGroupBy) BoolX(ctx context.Context) bool
- func (ascgb *AuthStateCacheGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ascgb *AuthStateCacheGroupBy) BoolsX(ctx context.Context) []bool
- func (ascgb *AuthStateCacheGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ascgb *AuthStateCacheGroupBy) Float64X(ctx context.Context) float64
- func (ascgb *AuthStateCacheGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ascgb *AuthStateCacheGroupBy) Float64sX(ctx context.Context) []float64
- func (ascgb *AuthStateCacheGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ascgb *AuthStateCacheGroupBy) IntX(ctx context.Context) int
- func (ascgb *AuthStateCacheGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ascgb *AuthStateCacheGroupBy) IntsX(ctx context.Context) []int
- func (ascgb *AuthStateCacheGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ascgb *AuthStateCacheGroupBy) ScanX(ctx context.Context, v interface{})
- func (ascgb *AuthStateCacheGroupBy) String(ctx context.Context) (_ string, err error)
- func (ascgb *AuthStateCacheGroupBy) StringX(ctx context.Context) string
- func (ascgb *AuthStateCacheGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ascgb *AuthStateCacheGroupBy) StringsX(ctx context.Context) []string
- type AuthStateCacheMutation
- func (m *AuthStateCacheMutation) AddExpiresAt(i int64)
- func (m *AuthStateCacheMutation) AddField(name string, value ent.Value) error
- func (m *AuthStateCacheMutation) AddedEdges() []string
- func (m *AuthStateCacheMutation) AddedExpiresAt() (r int64, exists bool)
- func (m *AuthStateCacheMutation) AddedField(name string) (ent.Value, bool)
- func (m *AuthStateCacheMutation) AddedFields() []string
- func (m *AuthStateCacheMutation) AddedIDs(name string) []ent.Value
- func (m *AuthStateCacheMutation) ClearEdge(name string) error
- func (m *AuthStateCacheMutation) ClearField(name string) error
- func (m *AuthStateCacheMutation) ClearedEdges() []string
- func (m *AuthStateCacheMutation) ClearedFields() []string
- func (m AuthStateCacheMutation) Client() *Client
- func (m *AuthStateCacheMutation) EdgeCleared(name string) bool
- func (m *AuthStateCacheMutation) ExpiresAt() (r int64, exists bool)
- func (m *AuthStateCacheMutation) Field(name string) (ent.Value, bool)
- func (m *AuthStateCacheMutation) FieldCleared(name string) bool
- func (m *AuthStateCacheMutation) Fields() []string
- func (m *AuthStateCacheMutation) ID() (id string, exists bool)
- func (m *AuthStateCacheMutation) OldExpiresAt(ctx context.Context) (v int64, err error)
- func (m *AuthStateCacheMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *AuthStateCacheMutation) Op() Op
- func (m *AuthStateCacheMutation) RemovedEdges() []string
- func (m *AuthStateCacheMutation) RemovedIDs(name string) []ent.Value
- func (m *AuthStateCacheMutation) ResetEdge(name string) error
- func (m *AuthStateCacheMutation) ResetExpiresAt()
- func (m *AuthStateCacheMutation) ResetField(name string) error
- func (m *AuthStateCacheMutation) SetExpiresAt(i int64)
- func (m *AuthStateCacheMutation) SetField(name string, value ent.Value) error
- func (m *AuthStateCacheMutation) SetID(id string)
- func (m AuthStateCacheMutation) Tx() (*Tx, error)
- func (m *AuthStateCacheMutation) Type() string
- func (m *AuthStateCacheMutation) Where(ps ...predicate.AuthStateCache)
- type AuthStateCacheQuery
- func (ascq *AuthStateCacheQuery) All(ctx context.Context) ([]*AuthStateCache, error)
- func (ascq *AuthStateCacheQuery) AllX(ctx context.Context) []*AuthStateCache
- func (ascq *AuthStateCacheQuery) Clone() *AuthStateCacheQuery
- func (ascq *AuthStateCacheQuery) Count(ctx context.Context) (int, error)
- func (ascq *AuthStateCacheQuery) CountX(ctx context.Context) int
- func (ascq *AuthStateCacheQuery) Exist(ctx context.Context) (bool, error)
- func (ascq *AuthStateCacheQuery) ExistX(ctx context.Context) bool
- func (ascq *AuthStateCacheQuery) First(ctx context.Context) (*AuthStateCache, error)
- func (ascq *AuthStateCacheQuery) FirstID(ctx context.Context) (id string, err error)
- func (ascq *AuthStateCacheQuery) FirstIDX(ctx context.Context) string
- func (ascq *AuthStateCacheQuery) FirstX(ctx context.Context) *AuthStateCache
- func (ascq *AuthStateCacheQuery) GroupBy(field string, fields ...string) *AuthStateCacheGroupBy
- func (ascq *AuthStateCacheQuery) IDs(ctx context.Context) ([]string, error)
- func (ascq *AuthStateCacheQuery) IDsX(ctx context.Context) []string
- func (ascq *AuthStateCacheQuery) Limit(limit int) *AuthStateCacheQuery
- func (ascq *AuthStateCacheQuery) Offset(offset int) *AuthStateCacheQuery
- func (ascq *AuthStateCacheQuery) Only(ctx context.Context) (*AuthStateCache, error)
- func (ascq *AuthStateCacheQuery) OnlyID(ctx context.Context) (id string, err error)
- func (ascq *AuthStateCacheQuery) OnlyIDX(ctx context.Context) string
- func (ascq *AuthStateCacheQuery) OnlyX(ctx context.Context) *AuthStateCache
- func (ascq *AuthStateCacheQuery) Order(o ...OrderFunc) *AuthStateCacheQuery
- func (ascq *AuthStateCacheQuery) Select(fields ...string) *AuthStateCacheSelect
- func (ascq *AuthStateCacheQuery) Unique(unique bool) *AuthStateCacheQuery
- func (ascq *AuthStateCacheQuery) Where(ps ...predicate.AuthStateCache) *AuthStateCacheQuery
- type AuthStateCacheSelect
- func (ascs *AuthStateCacheSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ascs *AuthStateCacheSelect) BoolX(ctx context.Context) bool
- func (ascs *AuthStateCacheSelect) Bools(ctx context.Context) ([]bool, error)
- func (ascs *AuthStateCacheSelect) BoolsX(ctx context.Context) []bool
- func (ascs *AuthStateCacheSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ascs *AuthStateCacheSelect) Float64X(ctx context.Context) float64
- func (ascs *AuthStateCacheSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ascs *AuthStateCacheSelect) Float64sX(ctx context.Context) []float64
- func (ascs *AuthStateCacheSelect) Int(ctx context.Context) (_ int, err error)
- func (ascs *AuthStateCacheSelect) IntX(ctx context.Context) int
- func (ascs *AuthStateCacheSelect) Ints(ctx context.Context) ([]int, error)
- func (ascs *AuthStateCacheSelect) IntsX(ctx context.Context) []int
- func (ascs *AuthStateCacheSelect) Scan(ctx context.Context, v interface{}) error
- func (ascs *AuthStateCacheSelect) ScanX(ctx context.Context, v interface{})
- func (ascs *AuthStateCacheSelect) String(ctx context.Context) (_ string, err error)
- func (ascs *AuthStateCacheSelect) StringX(ctx context.Context) string
- func (ascs *AuthStateCacheSelect) Strings(ctx context.Context) ([]string, error)
- func (ascs *AuthStateCacheSelect) StringsX(ctx context.Context) []string
- type AuthStateCacheUpdate
- func (ascu *AuthStateCacheUpdate) AddExpiresAt(i int64) *AuthStateCacheUpdate
- func (ascu *AuthStateCacheUpdate) Exec(ctx context.Context) error
- func (ascu *AuthStateCacheUpdate) ExecX(ctx context.Context)
- func (ascu *AuthStateCacheUpdate) Mutation() *AuthStateCacheMutation
- func (ascu *AuthStateCacheUpdate) Save(ctx context.Context) (int, error)
- func (ascu *AuthStateCacheUpdate) SaveX(ctx context.Context) int
- func (ascu *AuthStateCacheUpdate) SetExpiresAt(i int64) *AuthStateCacheUpdate
- func (ascu *AuthStateCacheUpdate) Where(ps ...predicate.AuthStateCache) *AuthStateCacheUpdate
- type AuthStateCacheUpdateOne
- func (ascuo *AuthStateCacheUpdateOne) AddExpiresAt(i int64) *AuthStateCacheUpdateOne
- func (ascuo *AuthStateCacheUpdateOne) Exec(ctx context.Context) error
- func (ascuo *AuthStateCacheUpdateOne) ExecX(ctx context.Context)
- func (ascuo *AuthStateCacheUpdateOne) Mutation() *AuthStateCacheMutation
- func (ascuo *AuthStateCacheUpdateOne) Save(ctx context.Context) (*AuthStateCache, error)
- func (ascuo *AuthStateCacheUpdateOne) SaveX(ctx context.Context) *AuthStateCache
- func (ascuo *AuthStateCacheUpdateOne) Select(field string, fields ...string) *AuthStateCacheUpdateOne
- func (ascuo *AuthStateCacheUpdateOne) SetExpiresAt(i int64) *AuthStateCacheUpdateOne
- type AuthStateCacheUpsert
- type AuthStateCacheUpsertBulk
- func (u *AuthStateCacheUpsertBulk) DoNothing() *AuthStateCacheUpsertBulk
- func (u *AuthStateCacheUpsertBulk) Exec(ctx context.Context) error
- func (u *AuthStateCacheUpsertBulk) ExecX(ctx context.Context)
- func (u *AuthStateCacheUpsertBulk) Ignore() *AuthStateCacheUpsertBulk
- func (u *AuthStateCacheUpsertBulk) SetExpiresAt(v int64) *AuthStateCacheUpsertBulk
- func (u *AuthStateCacheUpsertBulk) Update(set func(*AuthStateCacheUpsert)) *AuthStateCacheUpsertBulk
- func (u *AuthStateCacheUpsertBulk) UpdateExpiresAt() *AuthStateCacheUpsertBulk
- func (u *AuthStateCacheUpsertBulk) UpdateNewValues() *AuthStateCacheUpsertBulk
- type AuthStateCacheUpsertOne
- func (u *AuthStateCacheUpsertOne) DoNothing() *AuthStateCacheUpsertOne
- func (u *AuthStateCacheUpsertOne) Exec(ctx context.Context) error
- func (u *AuthStateCacheUpsertOne) ExecX(ctx context.Context)
- func (u *AuthStateCacheUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *AuthStateCacheUpsertOne) IDX(ctx context.Context) string
- func (u *AuthStateCacheUpsertOne) Ignore() *AuthStateCacheUpsertOne
- func (u *AuthStateCacheUpsertOne) SetExpiresAt(v int64) *AuthStateCacheUpsertOne
- func (u *AuthStateCacheUpsertOne) Update(set func(*AuthStateCacheUpsert)) *AuthStateCacheUpsertOne
- func (u *AuthStateCacheUpsertOne) UpdateExpiresAt() *AuthStateCacheUpsertOne
- func (u *AuthStateCacheUpsertOne) UpdateNewValues() *AuthStateCacheUpsertOne
- type AuthStateCaches
- type Client
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type Hook
- type MutateFunc
- type Mutation
- type Mutator
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Op
- type Option
- type OrderFunc
- type PackageRecord
- type PackageRecordClient
- func (c *PackageRecordClient) Create() *PackageRecordCreate
- func (c *PackageRecordClient) CreateBulk(builders ...*PackageRecordCreate) *PackageRecordCreateBulk
- func (c *PackageRecordClient) Delete() *PackageRecordDelete
- func (c *PackageRecordClient) DeleteOne(pr *PackageRecord) *PackageRecordDeleteOne
- func (c *PackageRecordClient) DeleteOneID(id int) *PackageRecordDeleteOne
- func (c *PackageRecordClient) Get(ctx context.Context, id int) (*PackageRecord, error)
- func (c *PackageRecordClient) GetX(ctx context.Context, id int) *PackageRecord
- func (c *PackageRecordClient) Hooks() []Hook
- func (c *PackageRecordClient) Query() *PackageRecordQuery
- func (c *PackageRecordClient) QueryScan(pr *PackageRecord) *ScanQuery
- func (c *PackageRecordClient) QueryVulnerabilities(pr *PackageRecord) *VulnerabilityQuery
- func (c *PackageRecordClient) Update() *PackageRecordUpdate
- func (c *PackageRecordClient) UpdateOne(pr *PackageRecord) *PackageRecordUpdateOne
- func (c *PackageRecordClient) UpdateOneID(id int) *PackageRecordUpdateOne
- func (c *PackageRecordClient) Use(hooks ...Hook)
- type PackageRecordCreate
- func (prc *PackageRecordCreate) AddScan(s ...*Scan) *PackageRecordCreate
- func (prc *PackageRecordCreate) AddScanIDs(ids ...string) *PackageRecordCreate
- func (prc *PackageRecordCreate) AddVulnerabilities(v ...*Vulnerability) *PackageRecordCreate
- func (prc *PackageRecordCreate) AddVulnerabilityIDs(ids ...string) *PackageRecordCreate
- func (prc *PackageRecordCreate) Exec(ctx context.Context) error
- func (prc *PackageRecordCreate) ExecX(ctx context.Context)
- func (prc *PackageRecordCreate) Mutation() *PackageRecordMutation
- func (prc *PackageRecordCreate) OnConflict(opts ...sql.ConflictOption) *PackageRecordUpsertOne
- func (prc *PackageRecordCreate) OnConflictColumns(columns ...string) *PackageRecordUpsertOne
- func (prc *PackageRecordCreate) Save(ctx context.Context) (*PackageRecord, error)
- func (prc *PackageRecordCreate) SaveX(ctx context.Context) *PackageRecord
- func (prc *PackageRecordCreate) SetName(s string) *PackageRecordCreate
- func (prc *PackageRecordCreate) SetSource(s string) *PackageRecordCreate
- func (prc *PackageRecordCreate) SetType(s string) *PackageRecordCreate
- func (prc *PackageRecordCreate) SetVersion(s string) *PackageRecordCreate
- func (prc *PackageRecordCreate) SetVulnIds(s []string) *PackageRecordCreate
- type PackageRecordCreateBulk
- func (prcb *PackageRecordCreateBulk) Exec(ctx context.Context) error
- func (prcb *PackageRecordCreateBulk) ExecX(ctx context.Context)
- func (prcb *PackageRecordCreateBulk) OnConflict(opts ...sql.ConflictOption) *PackageRecordUpsertBulk
- func (prcb *PackageRecordCreateBulk) OnConflictColumns(columns ...string) *PackageRecordUpsertBulk
- func (prcb *PackageRecordCreateBulk) Save(ctx context.Context) ([]*PackageRecord, error)
- func (prcb *PackageRecordCreateBulk) SaveX(ctx context.Context) []*PackageRecord
- type PackageRecordDelete
- type PackageRecordDeleteOne
- type PackageRecordEdges
- type PackageRecordGroupBy
- func (prgb *PackageRecordGroupBy) Aggregate(fns ...AggregateFunc) *PackageRecordGroupBy
- func (prgb *PackageRecordGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (prgb *PackageRecordGroupBy) BoolX(ctx context.Context) bool
- func (prgb *PackageRecordGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (prgb *PackageRecordGroupBy) BoolsX(ctx context.Context) []bool
- func (prgb *PackageRecordGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (prgb *PackageRecordGroupBy) Float64X(ctx context.Context) float64
- func (prgb *PackageRecordGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (prgb *PackageRecordGroupBy) Float64sX(ctx context.Context) []float64
- func (prgb *PackageRecordGroupBy) Int(ctx context.Context) (_ int, err error)
- func (prgb *PackageRecordGroupBy) IntX(ctx context.Context) int
- func (prgb *PackageRecordGroupBy) Ints(ctx context.Context) ([]int, error)
- func (prgb *PackageRecordGroupBy) IntsX(ctx context.Context) []int
- func (prgb *PackageRecordGroupBy) Scan(ctx context.Context, v interface{}) error
- func (prgb *PackageRecordGroupBy) ScanX(ctx context.Context, v interface{})
- func (prgb *PackageRecordGroupBy) String(ctx context.Context) (_ string, err error)
- func (prgb *PackageRecordGroupBy) StringX(ctx context.Context) string
- func (prgb *PackageRecordGroupBy) Strings(ctx context.Context) ([]string, error)
- func (prgb *PackageRecordGroupBy) StringsX(ctx context.Context) []string
- type PackageRecordMutation
- func (m *PackageRecordMutation) AddField(name string, value ent.Value) error
- func (m *PackageRecordMutation) AddScanIDs(ids ...string)
- func (m *PackageRecordMutation) AddVulnerabilityIDs(ids ...string)
- func (m *PackageRecordMutation) AddedEdges() []string
- func (m *PackageRecordMutation) AddedField(name string) (ent.Value, bool)
- func (m *PackageRecordMutation) AddedFields() []string
- func (m *PackageRecordMutation) AddedIDs(name string) []ent.Value
- func (m *PackageRecordMutation) ClearEdge(name string) error
- func (m *PackageRecordMutation) ClearField(name string) error
- func (m *PackageRecordMutation) ClearScan()
- func (m *PackageRecordMutation) ClearVulnerabilities()
- func (m *PackageRecordMutation) ClearedEdges() []string
- func (m *PackageRecordMutation) ClearedFields() []string
- func (m PackageRecordMutation) Client() *Client
- func (m *PackageRecordMutation) EdgeCleared(name string) bool
- func (m *PackageRecordMutation) Field(name string) (ent.Value, bool)
- func (m *PackageRecordMutation) FieldCleared(name string) bool
- func (m *PackageRecordMutation) Fields() []string
- func (m *PackageRecordMutation) GetType() (r string, exists bool)
- func (m *PackageRecordMutation) ID() (id int, exists bool)
- func (m *PackageRecordMutation) Name() (r string, exists bool)
- func (m *PackageRecordMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *PackageRecordMutation) OldName(ctx context.Context) (v string, err error)
- func (m *PackageRecordMutation) OldSource(ctx context.Context) (v string, err error)
- func (m *PackageRecordMutation) OldType(ctx context.Context) (v string, err error)
- func (m *PackageRecordMutation) OldVersion(ctx context.Context) (v string, err error)
- func (m *PackageRecordMutation) OldVulnIds(ctx context.Context) (v []string, err error)
- func (m *PackageRecordMutation) Op() Op
- func (m *PackageRecordMutation) RemoveScanIDs(ids ...string)
- func (m *PackageRecordMutation) RemoveVulnerabilityIDs(ids ...string)
- func (m *PackageRecordMutation) RemovedEdges() []string
- func (m *PackageRecordMutation) RemovedIDs(name string) []ent.Value
- func (m *PackageRecordMutation) RemovedScanIDs() (ids []string)
- func (m *PackageRecordMutation) RemovedVulnerabilitiesIDs() (ids []string)
- func (m *PackageRecordMutation) ResetEdge(name string) error
- func (m *PackageRecordMutation) ResetField(name string) error
- func (m *PackageRecordMutation) ResetName()
- func (m *PackageRecordMutation) ResetScan()
- func (m *PackageRecordMutation) ResetSource()
- func (m *PackageRecordMutation) ResetType()
- func (m *PackageRecordMutation) ResetVersion()
- func (m *PackageRecordMutation) ResetVulnIds()
- func (m *PackageRecordMutation) ResetVulnerabilities()
- func (m *PackageRecordMutation) ScanCleared() bool
- func (m *PackageRecordMutation) ScanIDs() (ids []string)
- func (m *PackageRecordMutation) SetField(name string, value ent.Value) error
- func (m *PackageRecordMutation) SetName(s string)
- func (m *PackageRecordMutation) SetSource(s string)
- func (m *PackageRecordMutation) SetType(s string)
- func (m *PackageRecordMutation) SetVersion(s string)
- func (m *PackageRecordMutation) SetVulnIds(s []string)
- func (m *PackageRecordMutation) Source() (r string, exists bool)
- func (m PackageRecordMutation) Tx() (*Tx, error)
- func (m *PackageRecordMutation) Type() string
- func (m *PackageRecordMutation) Version() (r string, exists bool)
- func (m *PackageRecordMutation) VulnIds() (r []string, exists bool)
- func (m *PackageRecordMutation) VulnerabilitiesCleared() bool
- func (m *PackageRecordMutation) VulnerabilitiesIDs() (ids []string)
- func (m *PackageRecordMutation) Where(ps ...predicate.PackageRecord)
- type PackageRecordQuery
- func (prq *PackageRecordQuery) All(ctx context.Context) ([]*PackageRecord, error)
- func (prq *PackageRecordQuery) AllX(ctx context.Context) []*PackageRecord
- func (prq *PackageRecordQuery) Clone() *PackageRecordQuery
- func (prq *PackageRecordQuery) Count(ctx context.Context) (int, error)
- func (prq *PackageRecordQuery) CountX(ctx context.Context) int
- func (prq *PackageRecordQuery) Exist(ctx context.Context) (bool, error)
- func (prq *PackageRecordQuery) ExistX(ctx context.Context) bool
- func (prq *PackageRecordQuery) First(ctx context.Context) (*PackageRecord, error)
- func (prq *PackageRecordQuery) FirstID(ctx context.Context) (id int, err error)
- func (prq *PackageRecordQuery) FirstIDX(ctx context.Context) int
- func (prq *PackageRecordQuery) FirstX(ctx context.Context) *PackageRecord
- func (prq *PackageRecordQuery) GroupBy(field string, fields ...string) *PackageRecordGroupBy
- func (prq *PackageRecordQuery) IDs(ctx context.Context) ([]int, error)
- func (prq *PackageRecordQuery) IDsX(ctx context.Context) []int
- func (prq *PackageRecordQuery) Limit(limit int) *PackageRecordQuery
- func (prq *PackageRecordQuery) Offset(offset int) *PackageRecordQuery
- func (prq *PackageRecordQuery) Only(ctx context.Context) (*PackageRecord, error)
- func (prq *PackageRecordQuery) OnlyID(ctx context.Context) (id int, err error)
- func (prq *PackageRecordQuery) OnlyIDX(ctx context.Context) int
- func (prq *PackageRecordQuery) OnlyX(ctx context.Context) *PackageRecord
- func (prq *PackageRecordQuery) Order(o ...OrderFunc) *PackageRecordQuery
- func (prq *PackageRecordQuery) QueryScan() *ScanQuery
- func (prq *PackageRecordQuery) QueryVulnerabilities() *VulnerabilityQuery
- func (prq *PackageRecordQuery) Select(fields ...string) *PackageRecordSelect
- func (prq *PackageRecordQuery) Unique(unique bool) *PackageRecordQuery
- func (prq *PackageRecordQuery) Where(ps ...predicate.PackageRecord) *PackageRecordQuery
- func (prq *PackageRecordQuery) WithScan(opts ...func(*ScanQuery)) *PackageRecordQuery
- func (prq *PackageRecordQuery) WithVulnerabilities(opts ...func(*VulnerabilityQuery)) *PackageRecordQuery
- type PackageRecordSelect
- func (prs *PackageRecordSelect) Bool(ctx context.Context) (_ bool, err error)
- func (prs *PackageRecordSelect) BoolX(ctx context.Context) bool
- func (prs *PackageRecordSelect) Bools(ctx context.Context) ([]bool, error)
- func (prs *PackageRecordSelect) BoolsX(ctx context.Context) []bool
- func (prs *PackageRecordSelect) Float64(ctx context.Context) (_ float64, err error)
- func (prs *PackageRecordSelect) Float64X(ctx context.Context) float64
- func (prs *PackageRecordSelect) Float64s(ctx context.Context) ([]float64, error)
- func (prs *PackageRecordSelect) Float64sX(ctx context.Context) []float64
- func (prs *PackageRecordSelect) Int(ctx context.Context) (_ int, err error)
- func (prs *PackageRecordSelect) IntX(ctx context.Context) int
- func (prs *PackageRecordSelect) Ints(ctx context.Context) ([]int, error)
- func (prs *PackageRecordSelect) IntsX(ctx context.Context) []int
- func (prs *PackageRecordSelect) Scan(ctx context.Context, v interface{}) error
- func (prs *PackageRecordSelect) ScanX(ctx context.Context, v interface{})
- func (prs *PackageRecordSelect) String(ctx context.Context) (_ string, err error)
- func (prs *PackageRecordSelect) StringX(ctx context.Context) string
- func (prs *PackageRecordSelect) Strings(ctx context.Context) ([]string, error)
- func (prs *PackageRecordSelect) StringsX(ctx context.Context) []string
- type PackageRecordUpdate
- func (pru *PackageRecordUpdate) AddScan(s ...*Scan) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) AddScanIDs(ids ...string) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) AddVulnerabilities(v ...*Vulnerability) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) AddVulnerabilityIDs(ids ...string) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) ClearScan() *PackageRecordUpdate
- func (pru *PackageRecordUpdate) ClearVulnerabilities() *PackageRecordUpdate
- func (pru *PackageRecordUpdate) Exec(ctx context.Context) error
- func (pru *PackageRecordUpdate) ExecX(ctx context.Context)
- func (pru *PackageRecordUpdate) Mutation() *PackageRecordMutation
- func (pru *PackageRecordUpdate) RemoveScan(s ...*Scan) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) RemoveScanIDs(ids ...string) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) RemoveVulnerabilities(v ...*Vulnerability) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) RemoveVulnerabilityIDs(ids ...string) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) Save(ctx context.Context) (int, error)
- func (pru *PackageRecordUpdate) SaveX(ctx context.Context) int
- func (pru *PackageRecordUpdate) SetVulnIds(s []string) *PackageRecordUpdate
- func (pru *PackageRecordUpdate) Where(ps ...predicate.PackageRecord) *PackageRecordUpdate
- type PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) AddScan(s ...*Scan) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) AddScanIDs(ids ...string) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) AddVulnerabilities(v ...*Vulnerability) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) AddVulnerabilityIDs(ids ...string) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) ClearScan() *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) ClearVulnerabilities() *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) Exec(ctx context.Context) error
- func (pruo *PackageRecordUpdateOne) ExecX(ctx context.Context)
- func (pruo *PackageRecordUpdateOne) Mutation() *PackageRecordMutation
- func (pruo *PackageRecordUpdateOne) RemoveScan(s ...*Scan) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) RemoveScanIDs(ids ...string) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) RemoveVulnerabilities(v ...*Vulnerability) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) RemoveVulnerabilityIDs(ids ...string) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) Save(ctx context.Context) (*PackageRecord, error)
- func (pruo *PackageRecordUpdateOne) SaveX(ctx context.Context) *PackageRecord
- func (pruo *PackageRecordUpdateOne) Select(field string, fields ...string) *PackageRecordUpdateOne
- func (pruo *PackageRecordUpdateOne) SetVulnIds(s []string) *PackageRecordUpdateOne
- type PackageRecordUpsert
- func (u *PackageRecordUpsert) SetName(v string) *PackageRecordUpsert
- func (u *PackageRecordUpsert) SetSource(v string) *PackageRecordUpsert
- func (u *PackageRecordUpsert) SetType(v string) *PackageRecordUpsert
- func (u *PackageRecordUpsert) SetVersion(v string) *PackageRecordUpsert
- func (u *PackageRecordUpsert) SetVulnIds(v []string) *PackageRecordUpsert
- func (u *PackageRecordUpsert) UpdateName() *PackageRecordUpsert
- func (u *PackageRecordUpsert) UpdateSource() *PackageRecordUpsert
- func (u *PackageRecordUpsert) UpdateType() *PackageRecordUpsert
- func (u *PackageRecordUpsert) UpdateVersion() *PackageRecordUpsert
- func (u *PackageRecordUpsert) UpdateVulnIds() *PackageRecordUpsert
- type PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) DoNothing() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) Exec(ctx context.Context) error
- func (u *PackageRecordUpsertBulk) ExecX(ctx context.Context)
- func (u *PackageRecordUpsertBulk) Ignore() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) SetName(v string) *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) SetSource(v string) *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) SetType(v string) *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) SetVersion(v string) *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) SetVulnIds(v []string) *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) Update(set func(*PackageRecordUpsert)) *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) UpdateName() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) UpdateNewValues() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) UpdateSource() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) UpdateType() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) UpdateVersion() *PackageRecordUpsertBulk
- func (u *PackageRecordUpsertBulk) UpdateVulnIds() *PackageRecordUpsertBulk
- type PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) DoNothing() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) Exec(ctx context.Context) error
- func (u *PackageRecordUpsertOne) ExecX(ctx context.Context)
- func (u *PackageRecordUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *PackageRecordUpsertOne) IDX(ctx context.Context) int
- func (u *PackageRecordUpsertOne) Ignore() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) SetName(v string) *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) SetSource(v string) *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) SetType(v string) *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) SetVersion(v string) *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) SetVulnIds(v []string) *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) Update(set func(*PackageRecordUpsert)) *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) UpdateName() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) UpdateNewValues() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) UpdateSource() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) UpdateType() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) UpdateVersion() *PackageRecordUpsertOne
- func (u *PackageRecordUpsertOne) UpdateVulnIds() *PackageRecordUpsertOne
- type PackageRecords
- type Policy
- type Query
- type Repositories
- type Repository
- func (r *Repository) QueryLatest() *ScanQuery
- func (r *Repository) QueryMain() *ScanQuery
- func (r *Repository) QueryScan() *ScanQuery
- func (r *Repository) QueryStatus() *VulnStatusIndexQuery
- func (r *Repository) String() string
- func (r *Repository) Unwrap() *Repository
- func (r *Repository) Update() *RepositoryUpdateOne
- type RepositoryClient
- func (c *RepositoryClient) Create() *RepositoryCreate
- func (c *RepositoryClient) CreateBulk(builders ...*RepositoryCreate) *RepositoryCreateBulk
- func (c *RepositoryClient) Delete() *RepositoryDelete
- func (c *RepositoryClient) DeleteOne(r *Repository) *RepositoryDeleteOne
- func (c *RepositoryClient) DeleteOneID(id int) *RepositoryDeleteOne
- func (c *RepositoryClient) Get(ctx context.Context, id int) (*Repository, error)
- func (c *RepositoryClient) GetX(ctx context.Context, id int) *Repository
- func (c *RepositoryClient) Hooks() []Hook
- func (c *RepositoryClient) Query() *RepositoryQuery
- func (c *RepositoryClient) QueryLatest(r *Repository) *ScanQuery
- func (c *RepositoryClient) QueryMain(r *Repository) *ScanQuery
- func (c *RepositoryClient) QueryScan(r *Repository) *ScanQuery
- func (c *RepositoryClient) QueryStatus(r *Repository) *VulnStatusIndexQuery
- func (c *RepositoryClient) Update() *RepositoryUpdate
- func (c *RepositoryClient) UpdateOne(r *Repository) *RepositoryUpdateOne
- func (c *RepositoryClient) UpdateOneID(id int) *RepositoryUpdateOne
- func (c *RepositoryClient) Use(hooks ...Hook)
- type RepositoryCreate
- func (rc *RepositoryCreate) AddMain(s ...*Scan) *RepositoryCreate
- func (rc *RepositoryCreate) AddMainIDs(ids ...string) *RepositoryCreate
- func (rc *RepositoryCreate) AddScan(s ...*Scan) *RepositoryCreate
- func (rc *RepositoryCreate) AddScanIDs(ids ...string) *RepositoryCreate
- func (rc *RepositoryCreate) AddStatuIDs(ids ...string) *RepositoryCreate
- func (rc *RepositoryCreate) AddStatus(v ...*VulnStatusIndex) *RepositoryCreate
- func (rc *RepositoryCreate) Exec(ctx context.Context) error
- func (rc *RepositoryCreate) ExecX(ctx context.Context)
- func (rc *RepositoryCreate) Mutation() *RepositoryMutation
- func (rc *RepositoryCreate) OnConflict(opts ...sql.ConflictOption) *RepositoryUpsertOne
- func (rc *RepositoryCreate) OnConflictColumns(columns ...string) *RepositoryUpsertOne
- func (rc *RepositoryCreate) Save(ctx context.Context) (*Repository, error)
- func (rc *RepositoryCreate) SaveX(ctx context.Context) *Repository
- func (rc *RepositoryCreate) SetAvatarURL(s string) *RepositoryCreate
- func (rc *RepositoryCreate) SetDefaultBranch(s string) *RepositoryCreate
- func (rc *RepositoryCreate) SetInstallID(i int64) *RepositoryCreate
- func (rc *RepositoryCreate) SetLatest(s *Scan) *RepositoryCreate
- func (rc *RepositoryCreate) SetLatestID(id string) *RepositoryCreate
- func (rc *RepositoryCreate) SetName(s string) *RepositoryCreate
- func (rc *RepositoryCreate) SetNillableAvatarURL(s *string) *RepositoryCreate
- func (rc *RepositoryCreate) SetNillableDefaultBranch(s *string) *RepositoryCreate
- func (rc *RepositoryCreate) SetNillableInstallID(i *int64) *RepositoryCreate
- func (rc *RepositoryCreate) SetNillableLatestID(id *string) *RepositoryCreate
- func (rc *RepositoryCreate) SetNillableURL(s *string) *RepositoryCreate
- func (rc *RepositoryCreate) SetOwner(s string) *RepositoryCreate
- func (rc *RepositoryCreate) SetURL(s string) *RepositoryCreate
- type RepositoryCreateBulk
- func (rcb *RepositoryCreateBulk) Exec(ctx context.Context) error
- func (rcb *RepositoryCreateBulk) ExecX(ctx context.Context)
- func (rcb *RepositoryCreateBulk) OnConflict(opts ...sql.ConflictOption) *RepositoryUpsertBulk
- func (rcb *RepositoryCreateBulk) OnConflictColumns(columns ...string) *RepositoryUpsertBulk
- func (rcb *RepositoryCreateBulk) Save(ctx context.Context) ([]*Repository, error)
- func (rcb *RepositoryCreateBulk) SaveX(ctx context.Context) []*Repository
- type RepositoryDelete
- type RepositoryDeleteOne
- type RepositoryEdges
- type RepositoryGroupBy
- func (rgb *RepositoryGroupBy) Aggregate(fns ...AggregateFunc) *RepositoryGroupBy
- func (rgb *RepositoryGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (rgb *RepositoryGroupBy) BoolX(ctx context.Context) bool
- func (rgb *RepositoryGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (rgb *RepositoryGroupBy) BoolsX(ctx context.Context) []bool
- func (rgb *RepositoryGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (rgb *RepositoryGroupBy) Float64X(ctx context.Context) float64
- func (rgb *RepositoryGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (rgb *RepositoryGroupBy) Float64sX(ctx context.Context) []float64
- func (rgb *RepositoryGroupBy) Int(ctx context.Context) (_ int, err error)
- func (rgb *RepositoryGroupBy) IntX(ctx context.Context) int
- func (rgb *RepositoryGroupBy) Ints(ctx context.Context) ([]int, error)
- func (rgb *RepositoryGroupBy) IntsX(ctx context.Context) []int
- func (rgb *RepositoryGroupBy) Scan(ctx context.Context, v interface{}) error
- func (rgb *RepositoryGroupBy) ScanX(ctx context.Context, v interface{})
- func (rgb *RepositoryGroupBy) String(ctx context.Context) (_ string, err error)
- func (rgb *RepositoryGroupBy) StringX(ctx context.Context) string
- func (rgb *RepositoryGroupBy) Strings(ctx context.Context) ([]string, error)
- func (rgb *RepositoryGroupBy) StringsX(ctx context.Context) []string
- type RepositoryMutation
- func (m *RepositoryMutation) AddField(name string, value ent.Value) error
- func (m *RepositoryMutation) AddInstallID(i int64)
- func (m *RepositoryMutation) AddMainIDs(ids ...string)
- func (m *RepositoryMutation) AddScanIDs(ids ...string)
- func (m *RepositoryMutation) AddStatuIDs(ids ...string)
- func (m *RepositoryMutation) AddedEdges() []string
- func (m *RepositoryMutation) AddedField(name string) (ent.Value, bool)
- func (m *RepositoryMutation) AddedFields() []string
- func (m *RepositoryMutation) AddedIDs(name string) []ent.Value
- func (m *RepositoryMutation) AddedInstallID() (r int64, exists bool)
- func (m *RepositoryMutation) AvatarURL() (r string, exists bool)
- func (m *RepositoryMutation) AvatarURLCleared() bool
- func (m *RepositoryMutation) ClearAvatarURL()
- func (m *RepositoryMutation) ClearDefaultBranch()
- func (m *RepositoryMutation) ClearEdge(name string) error
- func (m *RepositoryMutation) ClearField(name string) error
- func (m *RepositoryMutation) ClearInstallID()
- func (m *RepositoryMutation) ClearLatest()
- func (m *RepositoryMutation) ClearMain()
- func (m *RepositoryMutation) ClearScan()
- func (m *RepositoryMutation) ClearStatus()
- func (m *RepositoryMutation) ClearURL()
- func (m *RepositoryMutation) ClearedEdges() []string
- func (m *RepositoryMutation) ClearedFields() []string
- func (m RepositoryMutation) Client() *Client
- func (m *RepositoryMutation) DefaultBranch() (r string, exists bool)
- func (m *RepositoryMutation) DefaultBranchCleared() bool
- func (m *RepositoryMutation) EdgeCleared(name string) bool
- func (m *RepositoryMutation) Field(name string) (ent.Value, bool)
- func (m *RepositoryMutation) FieldCleared(name string) bool
- func (m *RepositoryMutation) Fields() []string
- func (m *RepositoryMutation) ID() (id int, exists bool)
- func (m *RepositoryMutation) InstallID() (r int64, exists bool)
- func (m *RepositoryMutation) InstallIDCleared() bool
- func (m *RepositoryMutation) LatestCleared() bool
- func (m *RepositoryMutation) LatestID() (id string, exists bool)
- func (m *RepositoryMutation) LatestIDs() (ids []string)
- func (m *RepositoryMutation) MainCleared() bool
- func (m *RepositoryMutation) MainIDs() (ids []string)
- func (m *RepositoryMutation) Name() (r string, exists bool)
- func (m *RepositoryMutation) OldAvatarURL(ctx context.Context) (v *string, err error)
- func (m *RepositoryMutation) OldDefaultBranch(ctx context.Context) (v *string, err error)
- func (m *RepositoryMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *RepositoryMutation) OldInstallID(ctx context.Context) (v int64, err error)
- func (m *RepositoryMutation) OldName(ctx context.Context) (v string, err error)
- func (m *RepositoryMutation) OldOwner(ctx context.Context) (v string, err error)
- func (m *RepositoryMutation) OldURL(ctx context.Context) (v string, err error)
- func (m *RepositoryMutation) Op() Op
- func (m *RepositoryMutation) Owner() (r string, exists bool)
- func (m *RepositoryMutation) RemoveMainIDs(ids ...string)
- func (m *RepositoryMutation) RemoveScanIDs(ids ...string)
- func (m *RepositoryMutation) RemoveStatuIDs(ids ...string)
- func (m *RepositoryMutation) RemovedEdges() []string
- func (m *RepositoryMutation) RemovedIDs(name string) []ent.Value
- func (m *RepositoryMutation) RemovedMainIDs() (ids []string)
- func (m *RepositoryMutation) RemovedScanIDs() (ids []string)
- func (m *RepositoryMutation) RemovedStatusIDs() (ids []string)
- func (m *RepositoryMutation) ResetAvatarURL()
- func (m *RepositoryMutation) ResetDefaultBranch()
- func (m *RepositoryMutation) ResetEdge(name string) error
- func (m *RepositoryMutation) ResetField(name string) error
- func (m *RepositoryMutation) ResetInstallID()
- func (m *RepositoryMutation) ResetLatest()
- func (m *RepositoryMutation) ResetMain()
- func (m *RepositoryMutation) ResetName()
- func (m *RepositoryMutation) ResetOwner()
- func (m *RepositoryMutation) ResetScan()
- func (m *RepositoryMutation) ResetStatus()
- func (m *RepositoryMutation) ResetURL()
- func (m *RepositoryMutation) ScanCleared() bool
- func (m *RepositoryMutation) ScanIDs() (ids []string)
- func (m *RepositoryMutation) SetAvatarURL(s string)
- func (m *RepositoryMutation) SetDefaultBranch(s string)
- func (m *RepositoryMutation) SetField(name string, value ent.Value) error
- func (m *RepositoryMutation) SetInstallID(i int64)
- func (m *RepositoryMutation) SetLatestID(id string)
- func (m *RepositoryMutation) SetName(s string)
- func (m *RepositoryMutation) SetOwner(s string)
- func (m *RepositoryMutation) SetURL(s string)
- func (m *RepositoryMutation) StatusCleared() bool
- func (m *RepositoryMutation) StatusIDs() (ids []string)
- func (m RepositoryMutation) Tx() (*Tx, error)
- func (m *RepositoryMutation) Type() string
- func (m *RepositoryMutation) URL() (r string, exists bool)
- func (m *RepositoryMutation) URLCleared() bool
- func (m *RepositoryMutation) Where(ps ...predicate.Repository)
- type RepositoryQuery
- func (rq *RepositoryQuery) All(ctx context.Context) ([]*Repository, error)
- func (rq *RepositoryQuery) AllX(ctx context.Context) []*Repository
- func (rq *RepositoryQuery) Clone() *RepositoryQuery
- func (rq *RepositoryQuery) Count(ctx context.Context) (int, error)
- func (rq *RepositoryQuery) CountX(ctx context.Context) int
- func (rq *RepositoryQuery) Exist(ctx context.Context) (bool, error)
- func (rq *RepositoryQuery) ExistX(ctx context.Context) bool
- func (rq *RepositoryQuery) First(ctx context.Context) (*Repository, error)
- func (rq *RepositoryQuery) FirstID(ctx context.Context) (id int, err error)
- func (rq *RepositoryQuery) FirstIDX(ctx context.Context) int
- func (rq *RepositoryQuery) FirstX(ctx context.Context) *Repository
- func (rq *RepositoryQuery) GroupBy(field string, fields ...string) *RepositoryGroupBy
- func (rq *RepositoryQuery) IDs(ctx context.Context) ([]int, error)
- func (rq *RepositoryQuery) IDsX(ctx context.Context) []int
- func (rq *RepositoryQuery) Limit(limit int) *RepositoryQuery
- func (rq *RepositoryQuery) Offset(offset int) *RepositoryQuery
- func (rq *RepositoryQuery) Only(ctx context.Context) (*Repository, error)
- func (rq *RepositoryQuery) OnlyID(ctx context.Context) (id int, err error)
- func (rq *RepositoryQuery) OnlyIDX(ctx context.Context) int
- func (rq *RepositoryQuery) OnlyX(ctx context.Context) *Repository
- func (rq *RepositoryQuery) Order(o ...OrderFunc) *RepositoryQuery
- func (rq *RepositoryQuery) QueryLatest() *ScanQuery
- func (rq *RepositoryQuery) QueryMain() *ScanQuery
- func (rq *RepositoryQuery) QueryScan() *ScanQuery
- func (rq *RepositoryQuery) QueryStatus() *VulnStatusIndexQuery
- func (rq *RepositoryQuery) Select(fields ...string) *RepositorySelect
- func (rq *RepositoryQuery) Unique(unique bool) *RepositoryQuery
- func (rq *RepositoryQuery) Where(ps ...predicate.Repository) *RepositoryQuery
- func (rq *RepositoryQuery) WithLatest(opts ...func(*ScanQuery)) *RepositoryQuery
- func (rq *RepositoryQuery) WithMain(opts ...func(*ScanQuery)) *RepositoryQuery
- func (rq *RepositoryQuery) WithScan(opts ...func(*ScanQuery)) *RepositoryQuery
- func (rq *RepositoryQuery) WithStatus(opts ...func(*VulnStatusIndexQuery)) *RepositoryQuery
- type RepositorySelect
- func (rs *RepositorySelect) Bool(ctx context.Context) (_ bool, err error)
- func (rs *RepositorySelect) BoolX(ctx context.Context) bool
- func (rs *RepositorySelect) Bools(ctx context.Context) ([]bool, error)
- func (rs *RepositorySelect) BoolsX(ctx context.Context) []bool
- func (rs *RepositorySelect) Float64(ctx context.Context) (_ float64, err error)
- func (rs *RepositorySelect) Float64X(ctx context.Context) float64
- func (rs *RepositorySelect) Float64s(ctx context.Context) ([]float64, error)
- func (rs *RepositorySelect) Float64sX(ctx context.Context) []float64
- func (rs *RepositorySelect) Int(ctx context.Context) (_ int, err error)
- func (rs *RepositorySelect) IntX(ctx context.Context) int
- func (rs *RepositorySelect) Ints(ctx context.Context) ([]int, error)
- func (rs *RepositorySelect) IntsX(ctx context.Context) []int
- func (rs *RepositorySelect) Scan(ctx context.Context, v interface{}) error
- func (rs *RepositorySelect) ScanX(ctx context.Context, v interface{})
- func (rs *RepositorySelect) String(ctx context.Context) (_ string, err error)
- func (rs *RepositorySelect) StringX(ctx context.Context) string
- func (rs *RepositorySelect) Strings(ctx context.Context) ([]string, error)
- func (rs *RepositorySelect) StringsX(ctx context.Context) []string
- type RepositoryUpdate
- func (ru *RepositoryUpdate) AddInstallID(i int64) *RepositoryUpdate
- func (ru *RepositoryUpdate) AddMain(s ...*Scan) *RepositoryUpdate
- func (ru *RepositoryUpdate) AddMainIDs(ids ...string) *RepositoryUpdate
- func (ru *RepositoryUpdate) AddScan(s ...*Scan) *RepositoryUpdate
- func (ru *RepositoryUpdate) AddScanIDs(ids ...string) *RepositoryUpdate
- func (ru *RepositoryUpdate) AddStatuIDs(ids ...string) *RepositoryUpdate
- func (ru *RepositoryUpdate) AddStatus(v ...*VulnStatusIndex) *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearAvatarURL() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearDefaultBranch() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearInstallID() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearLatest() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearMain() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearScan() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearStatus() *RepositoryUpdate
- func (ru *RepositoryUpdate) ClearURL() *RepositoryUpdate
- func (ru *RepositoryUpdate) Exec(ctx context.Context) error
- func (ru *RepositoryUpdate) ExecX(ctx context.Context)
- func (ru *RepositoryUpdate) Mutation() *RepositoryMutation
- func (ru *RepositoryUpdate) RemoveMain(s ...*Scan) *RepositoryUpdate
- func (ru *RepositoryUpdate) RemoveMainIDs(ids ...string) *RepositoryUpdate
- func (ru *RepositoryUpdate) RemoveScan(s ...*Scan) *RepositoryUpdate
- func (ru *RepositoryUpdate) RemoveScanIDs(ids ...string) *RepositoryUpdate
- func (ru *RepositoryUpdate) RemoveStatuIDs(ids ...string) *RepositoryUpdate
- func (ru *RepositoryUpdate) RemoveStatus(v ...*VulnStatusIndex) *RepositoryUpdate
- func (ru *RepositoryUpdate) Save(ctx context.Context) (int, error)
- func (ru *RepositoryUpdate) SaveX(ctx context.Context) int
- func (ru *RepositoryUpdate) SetAvatarURL(s string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetDefaultBranch(s string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetInstallID(i int64) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetLatest(s *Scan) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetLatestID(id string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetName(s string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetNillableAvatarURL(s *string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetNillableDefaultBranch(s *string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetNillableInstallID(i *int64) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetNillableLatestID(id *string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetNillableURL(s *string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetOwner(s string) *RepositoryUpdate
- func (ru *RepositoryUpdate) SetURL(s string) *RepositoryUpdate
- func (ru *RepositoryUpdate) Where(ps ...predicate.Repository) *RepositoryUpdate
- type RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddInstallID(i int64) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddMain(s ...*Scan) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddMainIDs(ids ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddScan(s ...*Scan) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddScanIDs(ids ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddStatuIDs(ids ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) AddStatus(v ...*VulnStatusIndex) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearAvatarURL() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearDefaultBranch() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearInstallID() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearLatest() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearMain() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearScan() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearStatus() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) ClearURL() *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) Exec(ctx context.Context) error
- func (ruo *RepositoryUpdateOne) ExecX(ctx context.Context)
- func (ruo *RepositoryUpdateOne) Mutation() *RepositoryMutation
- func (ruo *RepositoryUpdateOne) RemoveMain(s ...*Scan) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) RemoveMainIDs(ids ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) RemoveScan(s ...*Scan) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) RemoveScanIDs(ids ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) RemoveStatuIDs(ids ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) RemoveStatus(v ...*VulnStatusIndex) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) Save(ctx context.Context) (*Repository, error)
- func (ruo *RepositoryUpdateOne) SaveX(ctx context.Context) *Repository
- func (ruo *RepositoryUpdateOne) Select(field string, fields ...string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetAvatarURL(s string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetDefaultBranch(s string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetInstallID(i int64) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetLatest(s *Scan) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetLatestID(id string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetName(s string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetNillableAvatarURL(s *string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetNillableDefaultBranch(s *string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetNillableInstallID(i *int64) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetNillableLatestID(id *string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetNillableURL(s *string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetOwner(s string) *RepositoryUpdateOne
- func (ruo *RepositoryUpdateOne) SetURL(s string) *RepositoryUpdateOne
- type RepositoryUpsert
- func (u *RepositoryUpsert) ClearAvatarURL() *RepositoryUpsert
- func (u *RepositoryUpsert) ClearDefaultBranch() *RepositoryUpsert
- func (u *RepositoryUpsert) ClearInstallID() *RepositoryUpsert
- func (u *RepositoryUpsert) ClearURL() *RepositoryUpsert
- func (u *RepositoryUpsert) SetAvatarURL(v string) *RepositoryUpsert
- func (u *RepositoryUpsert) SetDefaultBranch(v string) *RepositoryUpsert
- func (u *RepositoryUpsert) SetInstallID(v int64) *RepositoryUpsert
- func (u *RepositoryUpsert) SetName(v string) *RepositoryUpsert
- func (u *RepositoryUpsert) SetOwner(v string) *RepositoryUpsert
- func (u *RepositoryUpsert) SetURL(v string) *RepositoryUpsert
- func (u *RepositoryUpsert) UpdateAvatarURL() *RepositoryUpsert
- func (u *RepositoryUpsert) UpdateDefaultBranch() *RepositoryUpsert
- func (u *RepositoryUpsert) UpdateInstallID() *RepositoryUpsert
- func (u *RepositoryUpsert) UpdateName() *RepositoryUpsert
- func (u *RepositoryUpsert) UpdateOwner() *RepositoryUpsert
- func (u *RepositoryUpsert) UpdateURL() *RepositoryUpsert
- type RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) ClearAvatarURL() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) ClearDefaultBranch() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) ClearInstallID() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) ClearURL() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) DoNothing() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) Exec(ctx context.Context) error
- func (u *RepositoryUpsertBulk) ExecX(ctx context.Context)
- func (u *RepositoryUpsertBulk) Ignore() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) SetAvatarURL(v string) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) SetDefaultBranch(v string) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) SetInstallID(v int64) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) SetName(v string) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) SetOwner(v string) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) SetURL(v string) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) Update(set func(*RepositoryUpsert)) *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateAvatarURL() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateDefaultBranch() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateInstallID() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateName() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateNewValues() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateOwner() *RepositoryUpsertBulk
- func (u *RepositoryUpsertBulk) UpdateURL() *RepositoryUpsertBulk
- type RepositoryUpsertOne
- func (u *RepositoryUpsertOne) ClearAvatarURL() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) ClearDefaultBranch() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) ClearInstallID() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) ClearURL() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) DoNothing() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) Exec(ctx context.Context) error
- func (u *RepositoryUpsertOne) ExecX(ctx context.Context)
- func (u *RepositoryUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *RepositoryUpsertOne) IDX(ctx context.Context) int
- func (u *RepositoryUpsertOne) Ignore() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) SetAvatarURL(v string) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) SetDefaultBranch(v string) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) SetInstallID(v int64) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) SetName(v string) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) SetOwner(v string) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) SetURL(v string) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) Update(set func(*RepositoryUpsert)) *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateAvatarURL() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateDefaultBranch() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateInstallID() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateName() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateNewValues() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateOwner() *RepositoryUpsertOne
- func (u *RepositoryUpsertOne) UpdateURL() *RepositoryUpsertOne
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type Scan
- type ScanClient
- func (c *ScanClient) Create() *ScanCreate
- func (c *ScanClient) CreateBulk(builders ...*ScanCreate) *ScanCreateBulk
- func (c *ScanClient) Delete() *ScanDelete
- func (c *ScanClient) DeleteOne(s *Scan) *ScanDeleteOne
- func (c *ScanClient) DeleteOneID(id string) *ScanDeleteOne
- func (c *ScanClient) Get(ctx context.Context, id string) (*Scan, error)
- func (c *ScanClient) GetX(ctx context.Context, id string) *Scan
- func (c *ScanClient) Hooks() []Hook
- func (c *ScanClient) Query() *ScanQuery
- func (c *ScanClient) QueryPackages(s *Scan) *PackageRecordQuery
- func (c *ScanClient) QueryRepository(s *Scan) *RepositoryQuery
- func (c *ScanClient) Update() *ScanUpdate
- func (c *ScanClient) UpdateOne(s *Scan) *ScanUpdateOne
- func (c *ScanClient) UpdateOneID(id string) *ScanUpdateOne
- func (c *ScanClient) Use(hooks ...Hook)
- type ScanCreate
- func (sc *ScanCreate) AddPackageIDs(ids ...int) *ScanCreate
- func (sc *ScanCreate) AddPackages(p ...*PackageRecord) *ScanCreate
- func (sc *ScanCreate) AddRepository(r ...*Repository) *ScanCreate
- func (sc *ScanCreate) AddRepositoryIDs(ids ...int) *ScanCreate
- func (sc *ScanCreate) Exec(ctx context.Context) error
- func (sc *ScanCreate) ExecX(ctx context.Context)
- func (sc *ScanCreate) Mutation() *ScanMutation
- func (sc *ScanCreate) OnConflict(opts ...sql.ConflictOption) *ScanUpsertOne
- func (sc *ScanCreate) OnConflictColumns(columns ...string) *ScanUpsertOne
- func (sc *ScanCreate) Save(ctx context.Context) (*Scan, error)
- func (sc *ScanCreate) SaveX(ctx context.Context) *Scan
- func (sc *ScanCreate) SetBranch(s string) *ScanCreate
- func (sc *ScanCreate) SetCheckID(i int64) *ScanCreate
- func (sc *ScanCreate) SetCommitID(s string) *ScanCreate
- func (sc *ScanCreate) SetID(s string) *ScanCreate
- func (sc *ScanCreate) SetNillableCheckID(i *int64) *ScanCreate
- func (sc *ScanCreate) SetNillablePullRequestTarget(s *string) *ScanCreate
- func (sc *ScanCreate) SetPullRequestTarget(s string) *ScanCreate
- func (sc *ScanCreate) SetRequestedAt(i int64) *ScanCreate
- func (sc *ScanCreate) SetScannedAt(i int64) *ScanCreate
- type ScanCreateBulk
- func (scb *ScanCreateBulk) Exec(ctx context.Context) error
- func (scb *ScanCreateBulk) ExecX(ctx context.Context)
- func (scb *ScanCreateBulk) OnConflict(opts ...sql.ConflictOption) *ScanUpsertBulk
- func (scb *ScanCreateBulk) OnConflictColumns(columns ...string) *ScanUpsertBulk
- func (scb *ScanCreateBulk) Save(ctx context.Context) ([]*Scan, error)
- func (scb *ScanCreateBulk) SaveX(ctx context.Context) []*Scan
- type ScanDelete
- type ScanDeleteOne
- type ScanEdges
- type ScanGroupBy
- func (sgb *ScanGroupBy) Aggregate(fns ...AggregateFunc) *ScanGroupBy
- func (sgb *ScanGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (sgb *ScanGroupBy) BoolX(ctx context.Context) bool
- func (sgb *ScanGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (sgb *ScanGroupBy) BoolsX(ctx context.Context) []bool
- func (sgb *ScanGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (sgb *ScanGroupBy) Float64X(ctx context.Context) float64
- func (sgb *ScanGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (sgb *ScanGroupBy) Float64sX(ctx context.Context) []float64
- func (sgb *ScanGroupBy) Int(ctx context.Context) (_ int, err error)
- func (sgb *ScanGroupBy) IntX(ctx context.Context) int
- func (sgb *ScanGroupBy) Ints(ctx context.Context) ([]int, error)
- func (sgb *ScanGroupBy) IntsX(ctx context.Context) []int
- func (sgb *ScanGroupBy) Scan(ctx context.Context, v interface{}) error
- func (sgb *ScanGroupBy) ScanX(ctx context.Context, v interface{})
- func (sgb *ScanGroupBy) String(ctx context.Context) (_ string, err error)
- func (sgb *ScanGroupBy) StringX(ctx context.Context) string
- func (sgb *ScanGroupBy) Strings(ctx context.Context) ([]string, error)
- func (sgb *ScanGroupBy) StringsX(ctx context.Context) []string
- type ScanMutation
- func (m *ScanMutation) AddCheckID(i int64)
- func (m *ScanMutation) AddField(name string, value ent.Value) error
- func (m *ScanMutation) AddPackageIDs(ids ...int)
- func (m *ScanMutation) AddRepositoryIDs(ids ...int)
- func (m *ScanMutation) AddRequestedAt(i int64)
- func (m *ScanMutation) AddScannedAt(i int64)
- func (m *ScanMutation) AddedCheckID() (r int64, exists bool)
- func (m *ScanMutation) AddedEdges() []string
- func (m *ScanMutation) AddedField(name string) (ent.Value, bool)
- func (m *ScanMutation) AddedFields() []string
- func (m *ScanMutation) AddedIDs(name string) []ent.Value
- func (m *ScanMutation) AddedRequestedAt() (r int64, exists bool)
- func (m *ScanMutation) AddedScannedAt() (r int64, exists bool)
- func (m *ScanMutation) Branch() (r string, exists bool)
- func (m *ScanMutation) CheckID() (r int64, exists bool)
- func (m *ScanMutation) CheckIDCleared() bool
- func (m *ScanMutation) ClearCheckID()
- func (m *ScanMutation) ClearEdge(name string) error
- func (m *ScanMutation) ClearField(name string) error
- func (m *ScanMutation) ClearPackages()
- func (m *ScanMutation) ClearPullRequestTarget()
- func (m *ScanMutation) ClearRepository()
- func (m *ScanMutation) ClearedEdges() []string
- func (m *ScanMutation) ClearedFields() []string
- func (m ScanMutation) Client() *Client
- func (m *ScanMutation) CommitID() (r string, exists bool)
- func (m *ScanMutation) EdgeCleared(name string) bool
- func (m *ScanMutation) Field(name string) (ent.Value, bool)
- func (m *ScanMutation) FieldCleared(name string) bool
- func (m *ScanMutation) Fields() []string
- func (m *ScanMutation) ID() (id string, exists bool)
- func (m *ScanMutation) OldBranch(ctx context.Context) (v string, err error)
- func (m *ScanMutation) OldCheckID(ctx context.Context) (v int64, err error)
- func (m *ScanMutation) OldCommitID(ctx context.Context) (v string, err error)
- func (m *ScanMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ScanMutation) OldPullRequestTarget(ctx context.Context) (v string, err error)
- func (m *ScanMutation) OldRequestedAt(ctx context.Context) (v int64, err error)
- func (m *ScanMutation) OldScannedAt(ctx context.Context) (v int64, err error)
- func (m *ScanMutation) Op() Op
- func (m *ScanMutation) PackagesCleared() bool
- func (m *ScanMutation) PackagesIDs() (ids []int)
- func (m *ScanMutation) PullRequestTarget() (r string, exists bool)
- func (m *ScanMutation) PullRequestTargetCleared() bool
- func (m *ScanMutation) RemovePackageIDs(ids ...int)
- func (m *ScanMutation) RemoveRepositoryIDs(ids ...int)
- func (m *ScanMutation) RemovedEdges() []string
- func (m *ScanMutation) RemovedIDs(name string) []ent.Value
- func (m *ScanMutation) RemovedPackagesIDs() (ids []int)
- func (m *ScanMutation) RemovedRepositoryIDs() (ids []int)
- func (m *ScanMutation) RepositoryCleared() bool
- func (m *ScanMutation) RepositoryIDs() (ids []int)
- func (m *ScanMutation) RequestedAt() (r int64, exists bool)
- func (m *ScanMutation) ResetBranch()
- func (m *ScanMutation) ResetCheckID()
- func (m *ScanMutation) ResetCommitID()
- func (m *ScanMutation) ResetEdge(name string) error
- func (m *ScanMutation) ResetField(name string) error
- func (m *ScanMutation) ResetPackages()
- func (m *ScanMutation) ResetPullRequestTarget()
- func (m *ScanMutation) ResetRepository()
- func (m *ScanMutation) ResetRequestedAt()
- func (m *ScanMutation) ResetScannedAt()
- func (m *ScanMutation) ScannedAt() (r int64, exists bool)
- func (m *ScanMutation) SetBranch(s string)
- func (m *ScanMutation) SetCheckID(i int64)
- func (m *ScanMutation) SetCommitID(s string)
- func (m *ScanMutation) SetField(name string, value ent.Value) error
- func (m *ScanMutation) SetID(id string)
- func (m *ScanMutation) SetPullRequestTarget(s string)
- func (m *ScanMutation) SetRequestedAt(i int64)
- func (m *ScanMutation) SetScannedAt(i int64)
- func (m ScanMutation) Tx() (*Tx, error)
- func (m *ScanMutation) Type() string
- func (m *ScanMutation) Where(ps ...predicate.Scan)
- type ScanQuery
- func (sq *ScanQuery) All(ctx context.Context) ([]*Scan, error)
- func (sq *ScanQuery) AllX(ctx context.Context) []*Scan
- func (sq *ScanQuery) Clone() *ScanQuery
- func (sq *ScanQuery) Count(ctx context.Context) (int, error)
- func (sq *ScanQuery) CountX(ctx context.Context) int
- func (sq *ScanQuery) Exist(ctx context.Context) (bool, error)
- func (sq *ScanQuery) ExistX(ctx context.Context) bool
- func (sq *ScanQuery) First(ctx context.Context) (*Scan, error)
- func (sq *ScanQuery) FirstID(ctx context.Context) (id string, err error)
- func (sq *ScanQuery) FirstIDX(ctx context.Context) string
- func (sq *ScanQuery) FirstX(ctx context.Context) *Scan
- func (sq *ScanQuery) GroupBy(field string, fields ...string) *ScanGroupBy
- func (sq *ScanQuery) IDs(ctx context.Context) ([]string, error)
- func (sq *ScanQuery) IDsX(ctx context.Context) []string
- func (sq *ScanQuery) Limit(limit int) *ScanQuery
- func (sq *ScanQuery) Offset(offset int) *ScanQuery
- func (sq *ScanQuery) Only(ctx context.Context) (*Scan, error)
- func (sq *ScanQuery) OnlyID(ctx context.Context) (id string, err error)
- func (sq *ScanQuery) OnlyIDX(ctx context.Context) string
- func (sq *ScanQuery) OnlyX(ctx context.Context) *Scan
- func (sq *ScanQuery) Order(o ...OrderFunc) *ScanQuery
- func (sq *ScanQuery) QueryPackages() *PackageRecordQuery
- func (sq *ScanQuery) QueryRepository() *RepositoryQuery
- func (sq *ScanQuery) Select(fields ...string) *ScanSelect
- func (sq *ScanQuery) Unique(unique bool) *ScanQuery
- func (sq *ScanQuery) Where(ps ...predicate.Scan) *ScanQuery
- func (sq *ScanQuery) WithPackages(opts ...func(*PackageRecordQuery)) *ScanQuery
- func (sq *ScanQuery) WithRepository(opts ...func(*RepositoryQuery)) *ScanQuery
- type ScanSelect
- func (ss *ScanSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ss *ScanSelect) BoolX(ctx context.Context) bool
- func (ss *ScanSelect) Bools(ctx context.Context) ([]bool, error)
- func (ss *ScanSelect) BoolsX(ctx context.Context) []bool
- func (ss *ScanSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ss *ScanSelect) Float64X(ctx context.Context) float64
- func (ss *ScanSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ss *ScanSelect) Float64sX(ctx context.Context) []float64
- func (ss *ScanSelect) Int(ctx context.Context) (_ int, err error)
- func (ss *ScanSelect) IntX(ctx context.Context) int
- func (ss *ScanSelect) Ints(ctx context.Context) ([]int, error)
- func (ss *ScanSelect) IntsX(ctx context.Context) []int
- func (ss *ScanSelect) Scan(ctx context.Context, v interface{}) error
- func (ss *ScanSelect) ScanX(ctx context.Context, v interface{})
- func (ss *ScanSelect) String(ctx context.Context) (_ string, err error)
- func (ss *ScanSelect) StringX(ctx context.Context) string
- func (ss *ScanSelect) Strings(ctx context.Context) ([]string, error)
- func (ss *ScanSelect) StringsX(ctx context.Context) []string
- type ScanUpdate
- func (su *ScanUpdate) AddCheckID(i int64) *ScanUpdate
- func (su *ScanUpdate) AddPackageIDs(ids ...int) *ScanUpdate
- func (su *ScanUpdate) AddPackages(p ...*PackageRecord) *ScanUpdate
- func (su *ScanUpdate) AddRepository(r ...*Repository) *ScanUpdate
- func (su *ScanUpdate) AddRepositoryIDs(ids ...int) *ScanUpdate
- func (su *ScanUpdate) AddRequestedAt(i int64) *ScanUpdate
- func (su *ScanUpdate) AddScannedAt(i int64) *ScanUpdate
- func (su *ScanUpdate) ClearCheckID() *ScanUpdate
- func (su *ScanUpdate) ClearPackages() *ScanUpdate
- func (su *ScanUpdate) ClearPullRequestTarget() *ScanUpdate
- func (su *ScanUpdate) ClearRepository() *ScanUpdate
- func (su *ScanUpdate) Exec(ctx context.Context) error
- func (su *ScanUpdate) ExecX(ctx context.Context)
- func (su *ScanUpdate) Mutation() *ScanMutation
- func (su *ScanUpdate) RemovePackageIDs(ids ...int) *ScanUpdate
- func (su *ScanUpdate) RemovePackages(p ...*PackageRecord) *ScanUpdate
- func (su *ScanUpdate) RemoveRepository(r ...*Repository) *ScanUpdate
- func (su *ScanUpdate) RemoveRepositoryIDs(ids ...int) *ScanUpdate
- func (su *ScanUpdate) Save(ctx context.Context) (int, error)
- func (su *ScanUpdate) SaveX(ctx context.Context) int
- func (su *ScanUpdate) SetCheckID(i int64) *ScanUpdate
- func (su *ScanUpdate) SetNillableCheckID(i *int64) *ScanUpdate
- func (su *ScanUpdate) SetNillablePullRequestTarget(s *string) *ScanUpdate
- func (su *ScanUpdate) SetPullRequestTarget(s string) *ScanUpdate
- func (su *ScanUpdate) SetRequestedAt(i int64) *ScanUpdate
- func (su *ScanUpdate) SetScannedAt(i int64) *ScanUpdate
- func (su *ScanUpdate) Where(ps ...predicate.Scan) *ScanUpdate
- type ScanUpdateOne
- func (suo *ScanUpdateOne) AddCheckID(i int64) *ScanUpdateOne
- func (suo *ScanUpdateOne) AddPackageIDs(ids ...int) *ScanUpdateOne
- func (suo *ScanUpdateOne) AddPackages(p ...*PackageRecord) *ScanUpdateOne
- func (suo *ScanUpdateOne) AddRepository(r ...*Repository) *ScanUpdateOne
- func (suo *ScanUpdateOne) AddRepositoryIDs(ids ...int) *ScanUpdateOne
- func (suo *ScanUpdateOne) AddRequestedAt(i int64) *ScanUpdateOne
- func (suo *ScanUpdateOne) AddScannedAt(i int64) *ScanUpdateOne
- func (suo *ScanUpdateOne) ClearCheckID() *ScanUpdateOne
- func (suo *ScanUpdateOne) ClearPackages() *ScanUpdateOne
- func (suo *ScanUpdateOne) ClearPullRequestTarget() *ScanUpdateOne
- func (suo *ScanUpdateOne) ClearRepository() *ScanUpdateOne
- func (suo *ScanUpdateOne) Exec(ctx context.Context) error
- func (suo *ScanUpdateOne) ExecX(ctx context.Context)
- func (suo *ScanUpdateOne) Mutation() *ScanMutation
- func (suo *ScanUpdateOne) RemovePackageIDs(ids ...int) *ScanUpdateOne
- func (suo *ScanUpdateOne) RemovePackages(p ...*PackageRecord) *ScanUpdateOne
- func (suo *ScanUpdateOne) RemoveRepository(r ...*Repository) *ScanUpdateOne
- func (suo *ScanUpdateOne) RemoveRepositoryIDs(ids ...int) *ScanUpdateOne
- func (suo *ScanUpdateOne) Save(ctx context.Context) (*Scan, error)
- func (suo *ScanUpdateOne) SaveX(ctx context.Context) *Scan
- func (suo *ScanUpdateOne) Select(field string, fields ...string) *ScanUpdateOne
- func (suo *ScanUpdateOne) SetCheckID(i int64) *ScanUpdateOne
- func (suo *ScanUpdateOne) SetNillableCheckID(i *int64) *ScanUpdateOne
- func (suo *ScanUpdateOne) SetNillablePullRequestTarget(s *string) *ScanUpdateOne
- func (suo *ScanUpdateOne) SetPullRequestTarget(s string) *ScanUpdateOne
- func (suo *ScanUpdateOne) SetRequestedAt(i int64) *ScanUpdateOne
- func (suo *ScanUpdateOne) SetScannedAt(i int64) *ScanUpdateOne
- type ScanUpsert
- func (u *ScanUpsert) ClearCheckID() *ScanUpsert
- func (u *ScanUpsert) ClearPullRequestTarget() *ScanUpsert
- func (u *ScanUpsert) SetBranch(v string) *ScanUpsert
- func (u *ScanUpsert) SetCheckID(v int64) *ScanUpsert
- func (u *ScanUpsert) SetCommitID(v string) *ScanUpsert
- func (u *ScanUpsert) SetPullRequestTarget(v string) *ScanUpsert
- func (u *ScanUpsert) SetRequestedAt(v int64) *ScanUpsert
- func (u *ScanUpsert) SetScannedAt(v int64) *ScanUpsert
- func (u *ScanUpsert) UpdateBranch() *ScanUpsert
- func (u *ScanUpsert) UpdateCheckID() *ScanUpsert
- func (u *ScanUpsert) UpdateCommitID() *ScanUpsert
- func (u *ScanUpsert) UpdatePullRequestTarget() *ScanUpsert
- func (u *ScanUpsert) UpdateRequestedAt() *ScanUpsert
- func (u *ScanUpsert) UpdateScannedAt() *ScanUpsert
- type ScanUpsertBulk
- func (u *ScanUpsertBulk) ClearCheckID() *ScanUpsertBulk
- func (u *ScanUpsertBulk) ClearPullRequestTarget() *ScanUpsertBulk
- func (u *ScanUpsertBulk) DoNothing() *ScanUpsertBulk
- func (u *ScanUpsertBulk) Exec(ctx context.Context) error
- func (u *ScanUpsertBulk) ExecX(ctx context.Context)
- func (u *ScanUpsertBulk) Ignore() *ScanUpsertBulk
- func (u *ScanUpsertBulk) SetBranch(v string) *ScanUpsertBulk
- func (u *ScanUpsertBulk) SetCheckID(v int64) *ScanUpsertBulk
- func (u *ScanUpsertBulk) SetCommitID(v string) *ScanUpsertBulk
- func (u *ScanUpsertBulk) SetPullRequestTarget(v string) *ScanUpsertBulk
- func (u *ScanUpsertBulk) SetRequestedAt(v int64) *ScanUpsertBulk
- func (u *ScanUpsertBulk) SetScannedAt(v int64) *ScanUpsertBulk
- func (u *ScanUpsertBulk) Update(set func(*ScanUpsert)) *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdateBranch() *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdateCheckID() *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdateCommitID() *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdateNewValues() *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdatePullRequestTarget() *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdateRequestedAt() *ScanUpsertBulk
- func (u *ScanUpsertBulk) UpdateScannedAt() *ScanUpsertBulk
- type ScanUpsertOne
- func (u *ScanUpsertOne) ClearCheckID() *ScanUpsertOne
- func (u *ScanUpsertOne) ClearPullRequestTarget() *ScanUpsertOne
- func (u *ScanUpsertOne) DoNothing() *ScanUpsertOne
- func (u *ScanUpsertOne) Exec(ctx context.Context) error
- func (u *ScanUpsertOne) ExecX(ctx context.Context)
- func (u *ScanUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *ScanUpsertOne) IDX(ctx context.Context) string
- func (u *ScanUpsertOne) Ignore() *ScanUpsertOne
- func (u *ScanUpsertOne) SetBranch(v string) *ScanUpsertOne
- func (u *ScanUpsertOne) SetCheckID(v int64) *ScanUpsertOne
- func (u *ScanUpsertOne) SetCommitID(v string) *ScanUpsertOne
- func (u *ScanUpsertOne) SetPullRequestTarget(v string) *ScanUpsertOne
- func (u *ScanUpsertOne) SetRequestedAt(v int64) *ScanUpsertOne
- func (u *ScanUpsertOne) SetScannedAt(v int64) *ScanUpsertOne
- func (u *ScanUpsertOne) Update(set func(*ScanUpsert)) *ScanUpsertOne
- func (u *ScanUpsertOne) UpdateBranch() *ScanUpsertOne
- func (u *ScanUpsertOne) UpdateCheckID() *ScanUpsertOne
- func (u *ScanUpsertOne) UpdateCommitID() *ScanUpsertOne
- func (u *ScanUpsertOne) UpdateNewValues() *ScanUpsertOne
- func (u *ScanUpsertOne) UpdatePullRequestTarget() *ScanUpsertOne
- func (u *ScanUpsertOne) UpdateRequestedAt() *ScanUpsertOne
- func (u *ScanUpsertOne) UpdateScannedAt() *ScanUpsertOne
- type Scans
- type Session
- type SessionClient
- func (c *SessionClient) Create() *SessionCreate
- func (c *SessionClient) CreateBulk(builders ...*SessionCreate) *SessionCreateBulk
- func (c *SessionClient) Delete() *SessionDelete
- func (c *SessionClient) DeleteOne(s *Session) *SessionDeleteOne
- func (c *SessionClient) DeleteOneID(id string) *SessionDeleteOne
- func (c *SessionClient) Get(ctx context.Context, id string) (*Session, error)
- func (c *SessionClient) GetX(ctx context.Context, id string) *Session
- func (c *SessionClient) Hooks() []Hook
- func (c *SessionClient) Query() *SessionQuery
- func (c *SessionClient) QueryLogin(s *Session) *UserQuery
- func (c *SessionClient) Update() *SessionUpdate
- func (c *SessionClient) UpdateOne(s *Session) *SessionUpdateOne
- func (c *SessionClient) UpdateOneID(id string) *SessionUpdateOne
- func (c *SessionClient) Use(hooks ...Hook)
- type SessionCreate
- func (sc *SessionCreate) Exec(ctx context.Context) error
- func (sc *SessionCreate) ExecX(ctx context.Context)
- func (sc *SessionCreate) Mutation() *SessionMutation
- func (sc *SessionCreate) OnConflict(opts ...sql.ConflictOption) *SessionUpsertOne
- func (sc *SessionCreate) OnConflictColumns(columns ...string) *SessionUpsertOne
- func (sc *SessionCreate) Save(ctx context.Context) (*Session, error)
- func (sc *SessionCreate) SaveX(ctx context.Context) *Session
- func (sc *SessionCreate) SetCreatedAt(i int64) *SessionCreate
- func (sc *SessionCreate) SetExpiresAt(i int64) *SessionCreate
- func (sc *SessionCreate) SetID(s string) *SessionCreate
- func (sc *SessionCreate) SetLogin(u *User) *SessionCreate
- func (sc *SessionCreate) SetLoginID(id int) *SessionCreate
- func (sc *SessionCreate) SetNillableLoginID(id *int) *SessionCreate
- func (sc *SessionCreate) SetToken(s string) *SessionCreate
- func (sc *SessionCreate) SetUserID(i int) *SessionCreate
- type SessionCreateBulk
- func (scb *SessionCreateBulk) Exec(ctx context.Context) error
- func (scb *SessionCreateBulk) ExecX(ctx context.Context)
- func (scb *SessionCreateBulk) OnConflict(opts ...sql.ConflictOption) *SessionUpsertBulk
- func (scb *SessionCreateBulk) OnConflictColumns(columns ...string) *SessionUpsertBulk
- func (scb *SessionCreateBulk) Save(ctx context.Context) ([]*Session, error)
- func (scb *SessionCreateBulk) SaveX(ctx context.Context) []*Session
- type SessionDelete
- type SessionDeleteOne
- type SessionEdges
- type SessionGroupBy
- func (sgb *SessionGroupBy) Aggregate(fns ...AggregateFunc) *SessionGroupBy
- func (sgb *SessionGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (sgb *SessionGroupBy) BoolX(ctx context.Context) bool
- func (sgb *SessionGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (sgb *SessionGroupBy) BoolsX(ctx context.Context) []bool
- func (sgb *SessionGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (sgb *SessionGroupBy) Float64X(ctx context.Context) float64
- func (sgb *SessionGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (sgb *SessionGroupBy) Float64sX(ctx context.Context) []float64
- func (sgb *SessionGroupBy) Int(ctx context.Context) (_ int, err error)
- func (sgb *SessionGroupBy) IntX(ctx context.Context) int
- func (sgb *SessionGroupBy) Ints(ctx context.Context) ([]int, error)
- func (sgb *SessionGroupBy) IntsX(ctx context.Context) []int
- func (sgb *SessionGroupBy) Scan(ctx context.Context, v interface{}) error
- func (sgb *SessionGroupBy) ScanX(ctx context.Context, v interface{})
- func (sgb *SessionGroupBy) String(ctx context.Context) (_ string, err error)
- func (sgb *SessionGroupBy) StringX(ctx context.Context) string
- func (sgb *SessionGroupBy) Strings(ctx context.Context) ([]string, error)
- func (sgb *SessionGroupBy) StringsX(ctx context.Context) []string
- type SessionMutation
- func (m *SessionMutation) AddCreatedAt(i int64)
- func (m *SessionMutation) AddExpiresAt(i int64)
- func (m *SessionMutation) AddField(name string, value ent.Value) error
- func (m *SessionMutation) AddUserID(i int)
- func (m *SessionMutation) AddedCreatedAt() (r int64, exists bool)
- func (m *SessionMutation) AddedEdges() []string
- func (m *SessionMutation) AddedExpiresAt() (r int64, exists bool)
- func (m *SessionMutation) AddedField(name string) (ent.Value, bool)
- func (m *SessionMutation) AddedFields() []string
- func (m *SessionMutation) AddedIDs(name string) []ent.Value
- func (m *SessionMutation) AddedUserID() (r int, exists bool)
- func (m *SessionMutation) ClearEdge(name string) error
- func (m *SessionMutation) ClearField(name string) error
- func (m *SessionMutation) ClearLogin()
- func (m *SessionMutation) ClearedEdges() []string
- func (m *SessionMutation) ClearedFields() []string
- func (m SessionMutation) Client() *Client
- func (m *SessionMutation) CreatedAt() (r int64, exists bool)
- func (m *SessionMutation) EdgeCleared(name string) bool
- func (m *SessionMutation) ExpiresAt() (r int64, exists bool)
- func (m *SessionMutation) Field(name string) (ent.Value, bool)
- func (m *SessionMutation) FieldCleared(name string) bool
- func (m *SessionMutation) Fields() []string
- func (m *SessionMutation) ID() (id string, exists bool)
- func (m *SessionMutation) LoginCleared() bool
- func (m *SessionMutation) LoginID() (id int, exists bool)
- func (m *SessionMutation) LoginIDs() (ids []int)
- func (m *SessionMutation) OldCreatedAt(ctx context.Context) (v int64, err error)
- func (m *SessionMutation) OldExpiresAt(ctx context.Context) (v int64, err error)
- func (m *SessionMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *SessionMutation) OldToken(ctx context.Context) (v string, err error)
- func (m *SessionMutation) OldUserID(ctx context.Context) (v int, err error)
- func (m *SessionMutation) Op() Op
- func (m *SessionMutation) RemovedEdges() []string
- func (m *SessionMutation) RemovedIDs(name string) []ent.Value
- func (m *SessionMutation) ResetCreatedAt()
- func (m *SessionMutation) ResetEdge(name string) error
- func (m *SessionMutation) ResetExpiresAt()
- func (m *SessionMutation) ResetField(name string) error
- func (m *SessionMutation) ResetLogin()
- func (m *SessionMutation) ResetToken()
- func (m *SessionMutation) ResetUserID()
- func (m *SessionMutation) SetCreatedAt(i int64)
- func (m *SessionMutation) SetExpiresAt(i int64)
- func (m *SessionMutation) SetField(name string, value ent.Value) error
- func (m *SessionMutation) SetID(id string)
- func (m *SessionMutation) SetLoginID(id int)
- func (m *SessionMutation) SetToken(s string)
- func (m *SessionMutation) SetUserID(i int)
- func (m *SessionMutation) Token() (r string, exists bool)
- func (m SessionMutation) Tx() (*Tx, error)
- func (m *SessionMutation) Type() string
- func (m *SessionMutation) UserID() (r int, exists bool)
- func (m *SessionMutation) Where(ps ...predicate.Session)
- type SessionQuery
- func (sq *SessionQuery) All(ctx context.Context) ([]*Session, error)
- func (sq *SessionQuery) AllX(ctx context.Context) []*Session
- func (sq *SessionQuery) Clone() *SessionQuery
- func (sq *SessionQuery) Count(ctx context.Context) (int, error)
- func (sq *SessionQuery) CountX(ctx context.Context) int
- func (sq *SessionQuery) Exist(ctx context.Context) (bool, error)
- func (sq *SessionQuery) ExistX(ctx context.Context) bool
- func (sq *SessionQuery) First(ctx context.Context) (*Session, error)
- func (sq *SessionQuery) FirstID(ctx context.Context) (id string, err error)
- func (sq *SessionQuery) FirstIDX(ctx context.Context) string
- func (sq *SessionQuery) FirstX(ctx context.Context) *Session
- func (sq *SessionQuery) GroupBy(field string, fields ...string) *SessionGroupBy
- func (sq *SessionQuery) IDs(ctx context.Context) ([]string, error)
- func (sq *SessionQuery) IDsX(ctx context.Context) []string
- func (sq *SessionQuery) Limit(limit int) *SessionQuery
- func (sq *SessionQuery) Offset(offset int) *SessionQuery
- func (sq *SessionQuery) Only(ctx context.Context) (*Session, error)
- func (sq *SessionQuery) OnlyID(ctx context.Context) (id string, err error)
- func (sq *SessionQuery) OnlyIDX(ctx context.Context) string
- func (sq *SessionQuery) OnlyX(ctx context.Context) *Session
- func (sq *SessionQuery) Order(o ...OrderFunc) *SessionQuery
- func (sq *SessionQuery) QueryLogin() *UserQuery
- func (sq *SessionQuery) Select(fields ...string) *SessionSelect
- func (sq *SessionQuery) Unique(unique bool) *SessionQuery
- func (sq *SessionQuery) Where(ps ...predicate.Session) *SessionQuery
- func (sq *SessionQuery) WithLogin(opts ...func(*UserQuery)) *SessionQuery
- type SessionSelect
- func (ss *SessionSelect) Bool(ctx context.Context) (_ bool, err error)
- func (ss *SessionSelect) BoolX(ctx context.Context) bool
- func (ss *SessionSelect) Bools(ctx context.Context) ([]bool, error)
- func (ss *SessionSelect) BoolsX(ctx context.Context) []bool
- func (ss *SessionSelect) Float64(ctx context.Context) (_ float64, err error)
- func (ss *SessionSelect) Float64X(ctx context.Context) float64
- func (ss *SessionSelect) Float64s(ctx context.Context) ([]float64, error)
- func (ss *SessionSelect) Float64sX(ctx context.Context) []float64
- func (ss *SessionSelect) Int(ctx context.Context) (_ int, err error)
- func (ss *SessionSelect) IntX(ctx context.Context) int
- func (ss *SessionSelect) Ints(ctx context.Context) ([]int, error)
- func (ss *SessionSelect) IntsX(ctx context.Context) []int
- func (ss *SessionSelect) Scan(ctx context.Context, v interface{}) error
- func (ss *SessionSelect) ScanX(ctx context.Context, v interface{})
- func (ss *SessionSelect) String(ctx context.Context) (_ string, err error)
- func (ss *SessionSelect) StringX(ctx context.Context) string
- func (ss *SessionSelect) Strings(ctx context.Context) ([]string, error)
- func (ss *SessionSelect) StringsX(ctx context.Context) []string
- type SessionUpdate
- func (su *SessionUpdate) AddUserID(i int) *SessionUpdate
- func (su *SessionUpdate) ClearLogin() *SessionUpdate
- func (su *SessionUpdate) Exec(ctx context.Context) error
- func (su *SessionUpdate) ExecX(ctx context.Context)
- func (su *SessionUpdate) Mutation() *SessionMutation
- func (su *SessionUpdate) Save(ctx context.Context) (int, error)
- func (su *SessionUpdate) SaveX(ctx context.Context) int
- func (su *SessionUpdate) SetLogin(u *User) *SessionUpdate
- func (su *SessionUpdate) SetLoginID(id int) *SessionUpdate
- func (su *SessionUpdate) SetNillableLoginID(id *int) *SessionUpdate
- func (su *SessionUpdate) SetUserID(i int) *SessionUpdate
- func (su *SessionUpdate) Where(ps ...predicate.Session) *SessionUpdate
- type SessionUpdateOne
- func (suo *SessionUpdateOne) AddUserID(i int) *SessionUpdateOne
- func (suo *SessionUpdateOne) ClearLogin() *SessionUpdateOne
- func (suo *SessionUpdateOne) Exec(ctx context.Context) error
- func (suo *SessionUpdateOne) ExecX(ctx context.Context)
- func (suo *SessionUpdateOne) Mutation() *SessionMutation
- func (suo *SessionUpdateOne) Save(ctx context.Context) (*Session, error)
- func (suo *SessionUpdateOne) SaveX(ctx context.Context) *Session
- func (suo *SessionUpdateOne) Select(field string, fields ...string) *SessionUpdateOne
- func (suo *SessionUpdateOne) SetLogin(u *User) *SessionUpdateOne
- func (suo *SessionUpdateOne) SetLoginID(id int) *SessionUpdateOne
- func (suo *SessionUpdateOne) SetNillableLoginID(id *int) *SessionUpdateOne
- func (suo *SessionUpdateOne) SetUserID(i int) *SessionUpdateOne
- type SessionUpsert
- func (u *SessionUpsert) SetCreatedAt(v int64) *SessionUpsert
- func (u *SessionUpsert) SetExpiresAt(v int64) *SessionUpsert
- func (u *SessionUpsert) SetToken(v string) *SessionUpsert
- func (u *SessionUpsert) SetUserID(v int) *SessionUpsert
- func (u *SessionUpsert) UpdateCreatedAt() *SessionUpsert
- func (u *SessionUpsert) UpdateExpiresAt() *SessionUpsert
- func (u *SessionUpsert) UpdateToken() *SessionUpsert
- func (u *SessionUpsert) UpdateUserID() *SessionUpsert
- type SessionUpsertBulk
- func (u *SessionUpsertBulk) DoNothing() *SessionUpsertBulk
- func (u *SessionUpsertBulk) Exec(ctx context.Context) error
- func (u *SessionUpsertBulk) ExecX(ctx context.Context)
- func (u *SessionUpsertBulk) Ignore() *SessionUpsertBulk
- func (u *SessionUpsertBulk) SetCreatedAt(v int64) *SessionUpsertBulk
- func (u *SessionUpsertBulk) SetExpiresAt(v int64) *SessionUpsertBulk
- func (u *SessionUpsertBulk) SetToken(v string) *SessionUpsertBulk
- func (u *SessionUpsertBulk) SetUserID(v int) *SessionUpsertBulk
- func (u *SessionUpsertBulk) Update(set func(*SessionUpsert)) *SessionUpsertBulk
- func (u *SessionUpsertBulk) UpdateCreatedAt() *SessionUpsertBulk
- func (u *SessionUpsertBulk) UpdateExpiresAt() *SessionUpsertBulk
- func (u *SessionUpsertBulk) UpdateNewValues() *SessionUpsertBulk
- func (u *SessionUpsertBulk) UpdateToken() *SessionUpsertBulk
- func (u *SessionUpsertBulk) UpdateUserID() *SessionUpsertBulk
- type SessionUpsertOne
- func (u *SessionUpsertOne) DoNothing() *SessionUpsertOne
- func (u *SessionUpsertOne) Exec(ctx context.Context) error
- func (u *SessionUpsertOne) ExecX(ctx context.Context)
- func (u *SessionUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *SessionUpsertOne) IDX(ctx context.Context) string
- func (u *SessionUpsertOne) Ignore() *SessionUpsertOne
- func (u *SessionUpsertOne) SetCreatedAt(v int64) *SessionUpsertOne
- func (u *SessionUpsertOne) SetExpiresAt(v int64) *SessionUpsertOne
- func (u *SessionUpsertOne) SetToken(v string) *SessionUpsertOne
- func (u *SessionUpsertOne) SetUserID(v int) *SessionUpsertOne
- func (u *SessionUpsertOne) Update(set func(*SessionUpsert)) *SessionUpsertOne
- func (u *SessionUpsertOne) UpdateCreatedAt() *SessionUpsertOne
- func (u *SessionUpsertOne) UpdateExpiresAt() *SessionUpsertOne
- func (u *SessionUpsertOne) UpdateNewValues() *SessionUpsertOne
- func (u *SessionUpsertOne) UpdateToken() *SessionUpsertOne
- func (u *SessionUpsertOne) UpdateUserID() *SessionUpsertOne
- type Sessions
- type Severities
- type Severity
- type SeverityClient
- func (c *SeverityClient) Create() *SeverityCreate
- func (c *SeverityClient) CreateBulk(builders ...*SeverityCreate) *SeverityCreateBulk
- func (c *SeverityClient) Delete() *SeverityDelete
- func (c *SeverityClient) DeleteOne(s *Severity) *SeverityDeleteOne
- func (c *SeverityClient) DeleteOneID(id int) *SeverityDeleteOne
- func (c *SeverityClient) Get(ctx context.Context, id int) (*Severity, error)
- func (c *SeverityClient) GetX(ctx context.Context, id int) *Severity
- func (c *SeverityClient) Hooks() []Hook
- func (c *SeverityClient) Query() *SeverityQuery
- func (c *SeverityClient) QueryVulnerabilities(s *Severity) *VulnerabilityQuery
- func (c *SeverityClient) Update() *SeverityUpdate
- func (c *SeverityClient) UpdateOne(s *Severity) *SeverityUpdateOne
- func (c *SeverityClient) UpdateOneID(id int) *SeverityUpdateOne
- func (c *SeverityClient) Use(hooks ...Hook)
- type SeverityCreate
- func (sc *SeverityCreate) AddVulnerabilities(v ...*Vulnerability) *SeverityCreate
- func (sc *SeverityCreate) AddVulnerabilityIDs(ids ...string) *SeverityCreate
- func (sc *SeverityCreate) Exec(ctx context.Context) error
- func (sc *SeverityCreate) ExecX(ctx context.Context)
- func (sc *SeverityCreate) Mutation() *SeverityMutation
- func (sc *SeverityCreate) OnConflict(opts ...sql.ConflictOption) *SeverityUpsertOne
- func (sc *SeverityCreate) OnConflictColumns(columns ...string) *SeverityUpsertOne
- func (sc *SeverityCreate) Save(ctx context.Context) (*Severity, error)
- func (sc *SeverityCreate) SaveX(ctx context.Context) *Severity
- func (sc *SeverityCreate) SetColor(s string) *SeverityCreate
- func (sc *SeverityCreate) SetLabel(s string) *SeverityCreate
- func (sc *SeverityCreate) SetNillableColor(s *string) *SeverityCreate
- type SeverityCreateBulk
- func (scb *SeverityCreateBulk) Exec(ctx context.Context) error
- func (scb *SeverityCreateBulk) ExecX(ctx context.Context)
- func (scb *SeverityCreateBulk) OnConflict(opts ...sql.ConflictOption) *SeverityUpsertBulk
- func (scb *SeverityCreateBulk) OnConflictColumns(columns ...string) *SeverityUpsertBulk
- func (scb *SeverityCreateBulk) Save(ctx context.Context) ([]*Severity, error)
- func (scb *SeverityCreateBulk) SaveX(ctx context.Context) []*Severity
- type SeverityDelete
- type SeverityDeleteOne
- type SeverityEdges
- type SeverityGroupBy
- func (sgb *SeverityGroupBy) Aggregate(fns ...AggregateFunc) *SeverityGroupBy
- func (sgb *SeverityGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (sgb *SeverityGroupBy) BoolX(ctx context.Context) bool
- func (sgb *SeverityGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (sgb *SeverityGroupBy) BoolsX(ctx context.Context) []bool
- func (sgb *SeverityGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (sgb *SeverityGroupBy) Float64X(ctx context.Context) float64
- func (sgb *SeverityGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (sgb *SeverityGroupBy) Float64sX(ctx context.Context) []float64
- func (sgb *SeverityGroupBy) Int(ctx context.Context) (_ int, err error)
- func (sgb *SeverityGroupBy) IntX(ctx context.Context) int
- func (sgb *SeverityGroupBy) Ints(ctx context.Context) ([]int, error)
- func (sgb *SeverityGroupBy) IntsX(ctx context.Context) []int
- func (sgb *SeverityGroupBy) Scan(ctx context.Context, v interface{}) error
- func (sgb *SeverityGroupBy) ScanX(ctx context.Context, v interface{})
- func (sgb *SeverityGroupBy) String(ctx context.Context) (_ string, err error)
- func (sgb *SeverityGroupBy) StringX(ctx context.Context) string
- func (sgb *SeverityGroupBy) Strings(ctx context.Context) ([]string, error)
- func (sgb *SeverityGroupBy) StringsX(ctx context.Context) []string
- type SeverityMutation
- func (m *SeverityMutation) AddField(name string, value ent.Value) error
- func (m *SeverityMutation) AddVulnerabilityIDs(ids ...string)
- func (m *SeverityMutation) AddedEdges() []string
- func (m *SeverityMutation) AddedField(name string) (ent.Value, bool)
- func (m *SeverityMutation) AddedFields() []string
- func (m *SeverityMutation) AddedIDs(name string) []ent.Value
- func (m *SeverityMutation) ClearColor()
- func (m *SeverityMutation) ClearEdge(name string) error
- func (m *SeverityMutation) ClearField(name string) error
- func (m *SeverityMutation) ClearVulnerabilities()
- func (m *SeverityMutation) ClearedEdges() []string
- func (m *SeverityMutation) ClearedFields() []string
- func (m SeverityMutation) Client() *Client
- func (m *SeverityMutation) Color() (r string, exists bool)
- func (m *SeverityMutation) ColorCleared() bool
- func (m *SeverityMutation) EdgeCleared(name string) bool
- func (m *SeverityMutation) Field(name string) (ent.Value, bool)
- func (m *SeverityMutation) FieldCleared(name string) bool
- func (m *SeverityMutation) Fields() []string
- func (m *SeverityMutation) ID() (id int, exists bool)
- func (m *SeverityMutation) Label() (r string, exists bool)
- func (m *SeverityMutation) OldColor(ctx context.Context) (v string, err error)
- func (m *SeverityMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *SeverityMutation) OldLabel(ctx context.Context) (v string, err error)
- func (m *SeverityMutation) Op() Op
- func (m *SeverityMutation) RemoveVulnerabilityIDs(ids ...string)
- func (m *SeverityMutation) RemovedEdges() []string
- func (m *SeverityMutation) RemovedIDs(name string) []ent.Value
- func (m *SeverityMutation) RemovedVulnerabilitiesIDs() (ids []string)
- func (m *SeverityMutation) ResetColor()
- func (m *SeverityMutation) ResetEdge(name string) error
- func (m *SeverityMutation) ResetField(name string) error
- func (m *SeverityMutation) ResetLabel()
- func (m *SeverityMutation) ResetVulnerabilities()
- func (m *SeverityMutation) SetColor(s string)
- func (m *SeverityMutation) SetField(name string, value ent.Value) error
- func (m *SeverityMutation) SetLabel(s string)
- func (m SeverityMutation) Tx() (*Tx, error)
- func (m *SeverityMutation) Type() string
- func (m *SeverityMutation) VulnerabilitiesCleared() bool
- func (m *SeverityMutation) VulnerabilitiesIDs() (ids []string)
- func (m *SeverityMutation) Where(ps ...predicate.Severity)
- type SeverityQuery
- func (sq *SeverityQuery) All(ctx context.Context) ([]*Severity, error)
- func (sq *SeverityQuery) AllX(ctx context.Context) []*Severity
- func (sq *SeverityQuery) Clone() *SeverityQuery
- func (sq *SeverityQuery) Count(ctx context.Context) (int, error)
- func (sq *SeverityQuery) CountX(ctx context.Context) int
- func (sq *SeverityQuery) Exist(ctx context.Context) (bool, error)
- func (sq *SeverityQuery) ExistX(ctx context.Context) bool
- func (sq *SeverityQuery) First(ctx context.Context) (*Severity, error)
- func (sq *SeverityQuery) FirstID(ctx context.Context) (id int, err error)
- func (sq *SeverityQuery) FirstIDX(ctx context.Context) int
- func (sq *SeverityQuery) FirstX(ctx context.Context) *Severity
- func (sq *SeverityQuery) GroupBy(field string, fields ...string) *SeverityGroupBy
- func (sq *SeverityQuery) IDs(ctx context.Context) ([]int, error)
- func (sq *SeverityQuery) IDsX(ctx context.Context) []int
- func (sq *SeverityQuery) Limit(limit int) *SeverityQuery
- func (sq *SeverityQuery) Offset(offset int) *SeverityQuery
- func (sq *SeverityQuery) Only(ctx context.Context) (*Severity, error)
- func (sq *SeverityQuery) OnlyID(ctx context.Context) (id int, err error)
- func (sq *SeverityQuery) OnlyIDX(ctx context.Context) int
- func (sq *SeverityQuery) OnlyX(ctx context.Context) *Severity
- func (sq *SeverityQuery) Order(o ...OrderFunc) *SeverityQuery
- func (sq *SeverityQuery) QueryVulnerabilities() *VulnerabilityQuery
- func (sq *SeverityQuery) Select(fields ...string) *SeveritySelect
- func (sq *SeverityQuery) Unique(unique bool) *SeverityQuery
- func (sq *SeverityQuery) Where(ps ...predicate.Severity) *SeverityQuery
- func (sq *SeverityQuery) WithVulnerabilities(opts ...func(*VulnerabilityQuery)) *SeverityQuery
- type SeveritySelect
- func (ss *SeveritySelect) Bool(ctx context.Context) (_ bool, err error)
- func (ss *SeveritySelect) BoolX(ctx context.Context) bool
- func (ss *SeveritySelect) Bools(ctx context.Context) ([]bool, error)
- func (ss *SeveritySelect) BoolsX(ctx context.Context) []bool
- func (ss *SeveritySelect) Float64(ctx context.Context) (_ float64, err error)
- func (ss *SeveritySelect) Float64X(ctx context.Context) float64
- func (ss *SeveritySelect) Float64s(ctx context.Context) ([]float64, error)
- func (ss *SeveritySelect) Float64sX(ctx context.Context) []float64
- func (ss *SeveritySelect) Int(ctx context.Context) (_ int, err error)
- func (ss *SeveritySelect) IntX(ctx context.Context) int
- func (ss *SeveritySelect) Ints(ctx context.Context) ([]int, error)
- func (ss *SeveritySelect) IntsX(ctx context.Context) []int
- func (ss *SeveritySelect) Scan(ctx context.Context, v interface{}) error
- func (ss *SeveritySelect) ScanX(ctx context.Context, v interface{})
- func (ss *SeveritySelect) String(ctx context.Context) (_ string, err error)
- func (ss *SeveritySelect) StringX(ctx context.Context) string
- func (ss *SeveritySelect) Strings(ctx context.Context) ([]string, error)
- func (ss *SeveritySelect) StringsX(ctx context.Context) []string
- type SeverityUpdate
- func (su *SeverityUpdate) AddVulnerabilities(v ...*Vulnerability) *SeverityUpdate
- func (su *SeverityUpdate) AddVulnerabilityIDs(ids ...string) *SeverityUpdate
- func (su *SeverityUpdate) ClearColor() *SeverityUpdate
- func (su *SeverityUpdate) ClearVulnerabilities() *SeverityUpdate
- func (su *SeverityUpdate) Exec(ctx context.Context) error
- func (su *SeverityUpdate) ExecX(ctx context.Context)
- func (su *SeverityUpdate) Mutation() *SeverityMutation
- func (su *SeverityUpdate) RemoveVulnerabilities(v ...*Vulnerability) *SeverityUpdate
- func (su *SeverityUpdate) RemoveVulnerabilityIDs(ids ...string) *SeverityUpdate
- func (su *SeverityUpdate) Save(ctx context.Context) (int, error)
- func (su *SeverityUpdate) SaveX(ctx context.Context) int
- func (su *SeverityUpdate) SetColor(s string) *SeverityUpdate
- func (su *SeverityUpdate) SetLabel(s string) *SeverityUpdate
- func (su *SeverityUpdate) SetNillableColor(s *string) *SeverityUpdate
- func (su *SeverityUpdate) Where(ps ...predicate.Severity) *SeverityUpdate
- type SeverityUpdateOne
- func (suo *SeverityUpdateOne) AddVulnerabilities(v ...*Vulnerability) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) AddVulnerabilityIDs(ids ...string) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) ClearColor() *SeverityUpdateOne
- func (suo *SeverityUpdateOne) ClearVulnerabilities() *SeverityUpdateOne
- func (suo *SeverityUpdateOne) Exec(ctx context.Context) error
- func (suo *SeverityUpdateOne) ExecX(ctx context.Context)
- func (suo *SeverityUpdateOne) Mutation() *SeverityMutation
- func (suo *SeverityUpdateOne) RemoveVulnerabilities(v ...*Vulnerability) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) RemoveVulnerabilityIDs(ids ...string) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) Save(ctx context.Context) (*Severity, error)
- func (suo *SeverityUpdateOne) SaveX(ctx context.Context) *Severity
- func (suo *SeverityUpdateOne) Select(field string, fields ...string) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) SetColor(s string) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) SetLabel(s string) *SeverityUpdateOne
- func (suo *SeverityUpdateOne) SetNillableColor(s *string) *SeverityUpdateOne
- type SeverityUpsert
- type SeverityUpsertBulk
- func (u *SeverityUpsertBulk) ClearColor() *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) DoNothing() *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) Exec(ctx context.Context) error
- func (u *SeverityUpsertBulk) ExecX(ctx context.Context)
- func (u *SeverityUpsertBulk) Ignore() *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) SetColor(v string) *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) SetLabel(v string) *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) Update(set func(*SeverityUpsert)) *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) UpdateColor() *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) UpdateLabel() *SeverityUpsertBulk
- func (u *SeverityUpsertBulk) UpdateNewValues() *SeverityUpsertBulk
- type SeverityUpsertOne
- func (u *SeverityUpsertOne) ClearColor() *SeverityUpsertOne
- func (u *SeverityUpsertOne) DoNothing() *SeverityUpsertOne
- func (u *SeverityUpsertOne) Exec(ctx context.Context) error
- func (u *SeverityUpsertOne) ExecX(ctx context.Context)
- func (u *SeverityUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *SeverityUpsertOne) IDX(ctx context.Context) int
- func (u *SeverityUpsertOne) Ignore() *SeverityUpsertOne
- func (u *SeverityUpsertOne) SetColor(v string) *SeverityUpsertOne
- func (u *SeverityUpsertOne) SetLabel(v string) *SeverityUpsertOne
- func (u *SeverityUpsertOne) Update(set func(*SeverityUpsert)) *SeverityUpsertOne
- func (u *SeverityUpsertOne) UpdateColor() *SeverityUpsertOne
- func (u *SeverityUpsertOne) UpdateLabel() *SeverityUpsertOne
- func (u *SeverityUpsertOne) UpdateNewValues() *SeverityUpsertOne
- type Tx
- type User
- type UserClient
- func (c *UserClient) Create() *UserCreate
- func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
- func (c *UserClient) Delete() *UserDelete
- func (c *UserClient) DeleteOne(u *User) *UserDeleteOne
- func (c *UserClient) DeleteOneID(id int) *UserDeleteOne
- func (c *UserClient) Get(ctx context.Context, id int) (*User, error)
- func (c *UserClient) GetX(ctx context.Context, id int) *User
- func (c *UserClient) Hooks() []Hook
- func (c *UserClient) Query() *UserQuery
- func (c *UserClient) QueryEditedStatus(u *User) *VulnStatusQuery
- func (c *UserClient) Update() *UserUpdate
- func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
- func (c *UserClient) UpdateOneID(id int) *UserUpdateOne
- func (c *UserClient) Use(hooks ...Hook)
- type UserCreate
- func (uc *UserCreate) AddEditedStatuIDs(ids ...int) *UserCreate
- func (uc *UserCreate) AddEditedStatus(v ...*VulnStatus) *UserCreate
- func (uc *UserCreate) Exec(ctx context.Context) error
- func (uc *UserCreate) ExecX(ctx context.Context)
- func (uc *UserCreate) Mutation() *UserMutation
- func (uc *UserCreate) OnConflict(opts ...sql.ConflictOption) *UserUpsertOne
- func (uc *UserCreate) OnConflictColumns(columns ...string) *UserUpsertOne
- func (uc *UserCreate) Save(ctx context.Context) (*User, error)
- func (uc *UserCreate) SaveX(ctx context.Context) *User
- func (uc *UserCreate) SetAvatarURL(s string) *UserCreate
- func (uc *UserCreate) SetGithubID(i int64) *UserCreate
- func (uc *UserCreate) SetLogin(s string) *UserCreate
- func (uc *UserCreate) SetName(s string) *UserCreate
- func (uc *UserCreate) SetURL(s string) *UserCreate
- type UserCreateBulk
- func (ucb *UserCreateBulk) Exec(ctx context.Context) error
- func (ucb *UserCreateBulk) ExecX(ctx context.Context)
- func (ucb *UserCreateBulk) OnConflict(opts ...sql.ConflictOption) *UserUpsertBulk
- func (ucb *UserCreateBulk) OnConflictColumns(columns ...string) *UserUpsertBulk
- func (ucb *UserCreateBulk) Save(ctx context.Context) ([]*User, error)
- func (ucb *UserCreateBulk) SaveX(ctx context.Context) []*User
- type UserDelete
- type UserDeleteOne
- type UserEdges
- type UserGroupBy
- func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
- func (ugb *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (ugb *UserGroupBy) BoolX(ctx context.Context) bool
- func (ugb *UserGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (ugb *UserGroupBy) BoolsX(ctx context.Context) []bool
- func (ugb *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (ugb *UserGroupBy) Float64X(ctx context.Context) float64
- func (ugb *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (ugb *UserGroupBy) Float64sX(ctx context.Context) []float64
- func (ugb *UserGroupBy) Int(ctx context.Context) (_ int, err error)
- func (ugb *UserGroupBy) IntX(ctx context.Context) int
- func (ugb *UserGroupBy) Ints(ctx context.Context) ([]int, error)
- func (ugb *UserGroupBy) IntsX(ctx context.Context) []int
- func (ugb *UserGroupBy) Scan(ctx context.Context, v interface{}) error
- func (ugb *UserGroupBy) ScanX(ctx context.Context, v interface{})
- func (ugb *UserGroupBy) String(ctx context.Context) (_ string, err error)
- func (ugb *UserGroupBy) StringX(ctx context.Context) string
- func (ugb *UserGroupBy) Strings(ctx context.Context) ([]string, error)
- func (ugb *UserGroupBy) StringsX(ctx context.Context) []string
- type UserMutation
- func (m *UserMutation) AddEditedStatuIDs(ids ...int)
- func (m *UserMutation) AddField(name string, value ent.Value) error
- func (m *UserMutation) AddGithubID(i int64)
- func (m *UserMutation) AddedEdges() []string
- func (m *UserMutation) AddedField(name string) (ent.Value, bool)
- func (m *UserMutation) AddedFields() []string
- func (m *UserMutation) AddedGithubID() (r int64, exists bool)
- func (m *UserMutation) AddedIDs(name string) []ent.Value
- func (m *UserMutation) AvatarURL() (r string, exists bool)
- func (m *UserMutation) ClearEdge(name string) error
- func (m *UserMutation) ClearEditedStatus()
- func (m *UserMutation) ClearField(name string) error
- func (m *UserMutation) ClearedEdges() []string
- func (m *UserMutation) ClearedFields() []string
- func (m UserMutation) Client() *Client
- func (m *UserMutation) EdgeCleared(name string) bool
- func (m *UserMutation) EditedStatusCleared() bool
- func (m *UserMutation) EditedStatusIDs() (ids []int)
- func (m *UserMutation) Field(name string) (ent.Value, bool)
- func (m *UserMutation) FieldCleared(name string) bool
- func (m *UserMutation) Fields() []string
- func (m *UserMutation) GithubID() (r int64, exists bool)
- func (m *UserMutation) ID() (id int, exists bool)
- func (m *UserMutation) Login() (r string, exists bool)
- func (m *UserMutation) Name() (r string, exists bool)
- func (m *UserMutation) OldAvatarURL(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *UserMutation) OldGithubID(ctx context.Context) (v int64, err error)
- func (m *UserMutation) OldLogin(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldName(ctx context.Context) (v string, err error)
- func (m *UserMutation) OldURL(ctx context.Context) (v string, err error)
- func (m *UserMutation) Op() Op
- func (m *UserMutation) RemoveEditedStatuIDs(ids ...int)
- func (m *UserMutation) RemovedEdges() []string
- func (m *UserMutation) RemovedEditedStatusIDs() (ids []int)
- func (m *UserMutation) RemovedIDs(name string) []ent.Value
- func (m *UserMutation) ResetAvatarURL()
- func (m *UserMutation) ResetEdge(name string) error
- func (m *UserMutation) ResetEditedStatus()
- func (m *UserMutation) ResetField(name string) error
- func (m *UserMutation) ResetGithubID()
- func (m *UserMutation) ResetLogin()
- func (m *UserMutation) ResetName()
- func (m *UserMutation) ResetURL()
- func (m *UserMutation) SetAvatarURL(s string)
- func (m *UserMutation) SetField(name string, value ent.Value) error
- func (m *UserMutation) SetGithubID(i int64)
- func (m *UserMutation) SetLogin(s string)
- func (m *UserMutation) SetName(s string)
- func (m *UserMutation) SetURL(s string)
- func (m UserMutation) Tx() (*Tx, error)
- func (m *UserMutation) Type() string
- func (m *UserMutation) URL() (r string, exists bool)
- func (m *UserMutation) Where(ps ...predicate.User)
- type UserQuery
- func (uq *UserQuery) All(ctx context.Context) ([]*User, error)
- func (uq *UserQuery) AllX(ctx context.Context) []*User
- func (uq *UserQuery) Clone() *UserQuery
- func (uq *UserQuery) Count(ctx context.Context) (int, error)
- func (uq *UserQuery) CountX(ctx context.Context) int
- func (uq *UserQuery) Exist(ctx context.Context) (bool, error)
- func (uq *UserQuery) ExistX(ctx context.Context) bool
- func (uq *UserQuery) First(ctx context.Context) (*User, error)
- func (uq *UserQuery) FirstID(ctx context.Context) (id int, err error)
- func (uq *UserQuery) FirstIDX(ctx context.Context) int
- func (uq *UserQuery) FirstX(ctx context.Context) *User
- func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
- func (uq *UserQuery) IDs(ctx context.Context) ([]int, error)
- func (uq *UserQuery) IDsX(ctx context.Context) []int
- func (uq *UserQuery) Limit(limit int) *UserQuery
- func (uq *UserQuery) Offset(offset int) *UserQuery
- func (uq *UserQuery) Only(ctx context.Context) (*User, error)
- func (uq *UserQuery) OnlyID(ctx context.Context) (id int, err error)
- func (uq *UserQuery) OnlyIDX(ctx context.Context) int
- func (uq *UserQuery) OnlyX(ctx context.Context) *User
- func (uq *UserQuery) Order(o ...OrderFunc) *UserQuery
- func (uq *UserQuery) QueryEditedStatus() *VulnStatusQuery
- func (uq *UserQuery) Select(fields ...string) *UserSelect
- func (uq *UserQuery) Unique(unique bool) *UserQuery
- func (uq *UserQuery) Where(ps ...predicate.User) *UserQuery
- func (uq *UserQuery) WithEditedStatus(opts ...func(*VulnStatusQuery)) *UserQuery
- type UserSelect
- func (us *UserSelect) Bool(ctx context.Context) (_ bool, err error)
- func (us *UserSelect) BoolX(ctx context.Context) bool
- func (us *UserSelect) Bools(ctx context.Context) ([]bool, error)
- func (us *UserSelect) BoolsX(ctx context.Context) []bool
- func (us *UserSelect) Float64(ctx context.Context) (_ float64, err error)
- func (us *UserSelect) Float64X(ctx context.Context) float64
- func (us *UserSelect) Float64s(ctx context.Context) ([]float64, error)
- func (us *UserSelect) Float64sX(ctx context.Context) []float64
- func (us *UserSelect) Int(ctx context.Context) (_ int, err error)
- func (us *UserSelect) IntX(ctx context.Context) int
- func (us *UserSelect) Ints(ctx context.Context) ([]int, error)
- func (us *UserSelect) IntsX(ctx context.Context) []int
- func (us *UserSelect) Scan(ctx context.Context, v interface{}) error
- func (us *UserSelect) ScanX(ctx context.Context, v interface{})
- func (us *UserSelect) String(ctx context.Context) (_ string, err error)
- func (us *UserSelect) StringX(ctx context.Context) string
- func (us *UserSelect) Strings(ctx context.Context) ([]string, error)
- func (us *UserSelect) StringsX(ctx context.Context) []string
- type UserUpdate
- func (uu *UserUpdate) AddEditedStatuIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) AddEditedStatus(v ...*VulnStatus) *UserUpdate
- func (uu *UserUpdate) ClearEditedStatus() *UserUpdate
- func (uu *UserUpdate) Exec(ctx context.Context) error
- func (uu *UserUpdate) ExecX(ctx context.Context)
- func (uu *UserUpdate) Mutation() *UserMutation
- func (uu *UserUpdate) RemoveEditedStatuIDs(ids ...int) *UserUpdate
- func (uu *UserUpdate) RemoveEditedStatus(v ...*VulnStatus) *UserUpdate
- func (uu *UserUpdate) Save(ctx context.Context) (int, error)
- func (uu *UserUpdate) SaveX(ctx context.Context) int
- func (uu *UserUpdate) SetAvatarURL(s string) *UserUpdate
- func (uu *UserUpdate) SetLogin(s string) *UserUpdate
- func (uu *UserUpdate) SetName(s string) *UserUpdate
- func (uu *UserUpdate) SetURL(s string) *UserUpdate
- func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
- type UserUpdateOne
- func (uuo *UserUpdateOne) AddEditedStatuIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) AddEditedStatus(v ...*VulnStatus) *UserUpdateOne
- func (uuo *UserUpdateOne) ClearEditedStatus() *UserUpdateOne
- func (uuo *UserUpdateOne) Exec(ctx context.Context) error
- func (uuo *UserUpdateOne) ExecX(ctx context.Context)
- func (uuo *UserUpdateOne) Mutation() *UserMutation
- func (uuo *UserUpdateOne) RemoveEditedStatuIDs(ids ...int) *UserUpdateOne
- func (uuo *UserUpdateOne) RemoveEditedStatus(v ...*VulnStatus) *UserUpdateOne
- func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
- func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
- func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetAvatarURL(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetLogin(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne
- func (uuo *UserUpdateOne) SetURL(s string) *UserUpdateOne
- type UserUpsert
- func (u *UserUpsert) SetAvatarURL(v string) *UserUpsert
- func (u *UserUpsert) SetGithubID(v int64) *UserUpsert
- func (u *UserUpsert) SetLogin(v string) *UserUpsert
- func (u *UserUpsert) SetName(v string) *UserUpsert
- func (u *UserUpsert) SetURL(v string) *UserUpsert
- func (u *UserUpsert) UpdateAvatarURL() *UserUpsert
- func (u *UserUpsert) UpdateGithubID() *UserUpsert
- func (u *UserUpsert) UpdateLogin() *UserUpsert
- func (u *UserUpsert) UpdateName() *UserUpsert
- func (u *UserUpsert) UpdateURL() *UserUpsert
- type UserUpsertBulk
- func (u *UserUpsertBulk) DoNothing() *UserUpsertBulk
- func (u *UserUpsertBulk) Exec(ctx context.Context) error
- func (u *UserUpsertBulk) ExecX(ctx context.Context)
- func (u *UserUpsertBulk) Ignore() *UserUpsertBulk
- func (u *UserUpsertBulk) SetAvatarURL(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetGithubID(v int64) *UserUpsertBulk
- func (u *UserUpsertBulk) SetLogin(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetName(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) SetURL(v string) *UserUpsertBulk
- func (u *UserUpsertBulk) Update(set func(*UserUpsert)) *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateAvatarURL() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateGithubID() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateLogin() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateName() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateNewValues() *UserUpsertBulk
- func (u *UserUpsertBulk) UpdateURL() *UserUpsertBulk
- type UserUpsertOne
- func (u *UserUpsertOne) DoNothing() *UserUpsertOne
- func (u *UserUpsertOne) Exec(ctx context.Context) error
- func (u *UserUpsertOne) ExecX(ctx context.Context)
- func (u *UserUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *UserUpsertOne) IDX(ctx context.Context) int
- func (u *UserUpsertOne) Ignore() *UserUpsertOne
- func (u *UserUpsertOne) SetAvatarURL(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetGithubID(v int64) *UserUpsertOne
- func (u *UserUpsertOne) SetLogin(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetName(v string) *UserUpsertOne
- func (u *UserUpsertOne) SetURL(v string) *UserUpsertOne
- func (u *UserUpsertOne) Update(set func(*UserUpsert)) *UserUpsertOne
- func (u *UserUpsertOne) UpdateAvatarURL() *UserUpsertOne
- func (u *UserUpsertOne) UpdateGithubID() *UserUpsertOne
- func (u *UserUpsertOne) UpdateLogin() *UserUpsertOne
- func (u *UserUpsertOne) UpdateName() *UserUpsertOne
- func (u *UserUpsertOne) UpdateNewValues() *UserUpsertOne
- func (u *UserUpsertOne) UpdateURL() *UserUpsertOne
- type Users
- type ValidationError
- type Value
- type VulnStatus
- type VulnStatusClient
- func (c *VulnStatusClient) Create() *VulnStatusCreate
- func (c *VulnStatusClient) CreateBulk(builders ...*VulnStatusCreate) *VulnStatusCreateBulk
- func (c *VulnStatusClient) Delete() *VulnStatusDelete
- func (c *VulnStatusClient) DeleteOne(vs *VulnStatus) *VulnStatusDeleteOne
- func (c *VulnStatusClient) DeleteOneID(id int) *VulnStatusDeleteOne
- func (c *VulnStatusClient) Get(ctx context.Context, id int) (*VulnStatus, error)
- func (c *VulnStatusClient) GetX(ctx context.Context, id int) *VulnStatus
- func (c *VulnStatusClient) Hooks() []Hook
- func (c *VulnStatusClient) Query() *VulnStatusQuery
- func (c *VulnStatusClient) QueryAuthor(vs *VulnStatus) *UserQuery
- func (c *VulnStatusClient) Update() *VulnStatusUpdate
- func (c *VulnStatusClient) UpdateOne(vs *VulnStatus) *VulnStatusUpdateOne
- func (c *VulnStatusClient) UpdateOneID(id int) *VulnStatusUpdateOne
- func (c *VulnStatusClient) Use(hooks ...Hook)
- type VulnStatusCreate
- func (vsc *VulnStatusCreate) Exec(ctx context.Context) error
- func (vsc *VulnStatusCreate) ExecX(ctx context.Context)
- func (vsc *VulnStatusCreate) Mutation() *VulnStatusMutation
- func (vsc *VulnStatusCreate) OnConflict(opts ...sql.ConflictOption) *VulnStatusUpsertOne
- func (vsc *VulnStatusCreate) OnConflictColumns(columns ...string) *VulnStatusUpsertOne
- func (vsc *VulnStatusCreate) Save(ctx context.Context) (*VulnStatus, error)
- func (vsc *VulnStatusCreate) SaveX(ctx context.Context) *VulnStatus
- func (vsc *VulnStatusCreate) SetAuthor(u *User) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetAuthorID(id int) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetComment(s string) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetCreatedAt(i int64) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetExpiresAt(i int64) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetNillableAuthorID(id *int) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetPkgName(s string) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetPkgType(s string) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetSource(s string) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetStatus(tst types.VulnStatusType) *VulnStatusCreate
- func (vsc *VulnStatusCreate) SetVulnID(s string) *VulnStatusCreate
- type VulnStatusCreateBulk
- func (vscb *VulnStatusCreateBulk) Exec(ctx context.Context) error
- func (vscb *VulnStatusCreateBulk) ExecX(ctx context.Context)
- func (vscb *VulnStatusCreateBulk) OnConflict(opts ...sql.ConflictOption) *VulnStatusUpsertBulk
- func (vscb *VulnStatusCreateBulk) OnConflictColumns(columns ...string) *VulnStatusUpsertBulk
- func (vscb *VulnStatusCreateBulk) Save(ctx context.Context) ([]*VulnStatus, error)
- func (vscb *VulnStatusCreateBulk) SaveX(ctx context.Context) []*VulnStatus
- type VulnStatusDelete
- type VulnStatusDeleteOne
- type VulnStatusEdges
- type VulnStatusGroupBy
- func (vsgb *VulnStatusGroupBy) Aggregate(fns ...AggregateFunc) *VulnStatusGroupBy
- func (vsgb *VulnStatusGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (vsgb *VulnStatusGroupBy) BoolX(ctx context.Context) bool
- func (vsgb *VulnStatusGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (vsgb *VulnStatusGroupBy) BoolsX(ctx context.Context) []bool
- func (vsgb *VulnStatusGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (vsgb *VulnStatusGroupBy) Float64X(ctx context.Context) float64
- func (vsgb *VulnStatusGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (vsgb *VulnStatusGroupBy) Float64sX(ctx context.Context) []float64
- func (vsgb *VulnStatusGroupBy) Int(ctx context.Context) (_ int, err error)
- func (vsgb *VulnStatusGroupBy) IntX(ctx context.Context) int
- func (vsgb *VulnStatusGroupBy) Ints(ctx context.Context) ([]int, error)
- func (vsgb *VulnStatusGroupBy) IntsX(ctx context.Context) []int
- func (vsgb *VulnStatusGroupBy) Scan(ctx context.Context, v interface{}) error
- func (vsgb *VulnStatusGroupBy) ScanX(ctx context.Context, v interface{})
- func (vsgb *VulnStatusGroupBy) String(ctx context.Context) (_ string, err error)
- func (vsgb *VulnStatusGroupBy) StringX(ctx context.Context) string
- func (vsgb *VulnStatusGroupBy) Strings(ctx context.Context) ([]string, error)
- func (vsgb *VulnStatusGroupBy) StringsX(ctx context.Context) []string
- type VulnStatusIndex
- type VulnStatusIndexClient
- func (c *VulnStatusIndexClient) Create() *VulnStatusIndexCreate
- func (c *VulnStatusIndexClient) CreateBulk(builders ...*VulnStatusIndexCreate) *VulnStatusIndexCreateBulk
- func (c *VulnStatusIndexClient) Delete() *VulnStatusIndexDelete
- func (c *VulnStatusIndexClient) DeleteOne(vsi *VulnStatusIndex) *VulnStatusIndexDeleteOne
- func (c *VulnStatusIndexClient) DeleteOneID(id string) *VulnStatusIndexDeleteOne
- func (c *VulnStatusIndexClient) Get(ctx context.Context, id string) (*VulnStatusIndex, error)
- func (c *VulnStatusIndexClient) GetX(ctx context.Context, id string) *VulnStatusIndex
- func (c *VulnStatusIndexClient) Hooks() []Hook
- func (c *VulnStatusIndexClient) Query() *VulnStatusIndexQuery
- func (c *VulnStatusIndexClient) QueryLatest(vsi *VulnStatusIndex) *VulnStatusQuery
- func (c *VulnStatusIndexClient) QueryStatus(vsi *VulnStatusIndex) *VulnStatusQuery
- func (c *VulnStatusIndexClient) Update() *VulnStatusIndexUpdate
- func (c *VulnStatusIndexClient) UpdateOne(vsi *VulnStatusIndex) *VulnStatusIndexUpdateOne
- func (c *VulnStatusIndexClient) UpdateOneID(id string) *VulnStatusIndexUpdateOne
- func (c *VulnStatusIndexClient) Use(hooks ...Hook)
- type VulnStatusIndexCreate
- func (vsic *VulnStatusIndexCreate) AddStatuIDs(ids ...int) *VulnStatusIndexCreate
- func (vsic *VulnStatusIndexCreate) AddStatus(v ...*VulnStatus) *VulnStatusIndexCreate
- func (vsic *VulnStatusIndexCreate) Exec(ctx context.Context) error
- func (vsic *VulnStatusIndexCreate) ExecX(ctx context.Context)
- func (vsic *VulnStatusIndexCreate) Mutation() *VulnStatusIndexMutation
- func (vsic *VulnStatusIndexCreate) OnConflict(opts ...sql.ConflictOption) *VulnStatusIndexUpsertOne
- func (vsic *VulnStatusIndexCreate) OnConflictColumns(columns ...string) *VulnStatusIndexUpsertOne
- func (vsic *VulnStatusIndexCreate) Save(ctx context.Context) (*VulnStatusIndex, error)
- func (vsic *VulnStatusIndexCreate) SaveX(ctx context.Context) *VulnStatusIndex
- func (vsic *VulnStatusIndexCreate) SetID(s string) *VulnStatusIndexCreate
- func (vsic *VulnStatusIndexCreate) SetLatest(v *VulnStatus) *VulnStatusIndexCreate
- func (vsic *VulnStatusIndexCreate) SetLatestID(id int) *VulnStatusIndexCreate
- func (vsic *VulnStatusIndexCreate) SetNillableLatestID(id *int) *VulnStatusIndexCreate
- type VulnStatusIndexCreateBulk
- func (vsicb *VulnStatusIndexCreateBulk) Exec(ctx context.Context) error
- func (vsicb *VulnStatusIndexCreateBulk) ExecX(ctx context.Context)
- func (vsicb *VulnStatusIndexCreateBulk) OnConflict(opts ...sql.ConflictOption) *VulnStatusIndexUpsertBulk
- func (vsicb *VulnStatusIndexCreateBulk) OnConflictColumns(columns ...string) *VulnStatusIndexUpsertBulk
- func (vsicb *VulnStatusIndexCreateBulk) Save(ctx context.Context) ([]*VulnStatusIndex, error)
- func (vsicb *VulnStatusIndexCreateBulk) SaveX(ctx context.Context) []*VulnStatusIndex
- type VulnStatusIndexDelete
- type VulnStatusIndexDeleteOne
- type VulnStatusIndexEdges
- type VulnStatusIndexGroupBy
- func (vsigb *VulnStatusIndexGroupBy) Aggregate(fns ...AggregateFunc) *VulnStatusIndexGroupBy
- func (vsigb *VulnStatusIndexGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (vsigb *VulnStatusIndexGroupBy) BoolX(ctx context.Context) bool
- func (vsigb *VulnStatusIndexGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (vsigb *VulnStatusIndexGroupBy) BoolsX(ctx context.Context) []bool
- func (vsigb *VulnStatusIndexGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (vsigb *VulnStatusIndexGroupBy) Float64X(ctx context.Context) float64
- func (vsigb *VulnStatusIndexGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (vsigb *VulnStatusIndexGroupBy) Float64sX(ctx context.Context) []float64
- func (vsigb *VulnStatusIndexGroupBy) Int(ctx context.Context) (_ int, err error)
- func (vsigb *VulnStatusIndexGroupBy) IntX(ctx context.Context) int
- func (vsigb *VulnStatusIndexGroupBy) Ints(ctx context.Context) ([]int, error)
- func (vsigb *VulnStatusIndexGroupBy) IntsX(ctx context.Context) []int
- func (vsigb *VulnStatusIndexGroupBy) Scan(ctx context.Context, v interface{}) error
- func (vsigb *VulnStatusIndexGroupBy) ScanX(ctx context.Context, v interface{})
- func (vsigb *VulnStatusIndexGroupBy) String(ctx context.Context) (_ string, err error)
- func (vsigb *VulnStatusIndexGroupBy) StringX(ctx context.Context) string
- func (vsigb *VulnStatusIndexGroupBy) Strings(ctx context.Context) ([]string, error)
- func (vsigb *VulnStatusIndexGroupBy) StringsX(ctx context.Context) []string
- type VulnStatusIndexMutation
- func (m *VulnStatusIndexMutation) AddField(name string, value ent.Value) error
- func (m *VulnStatusIndexMutation) AddStatuIDs(ids ...int)
- func (m *VulnStatusIndexMutation) AddedEdges() []string
- func (m *VulnStatusIndexMutation) AddedField(name string) (ent.Value, bool)
- func (m *VulnStatusIndexMutation) AddedFields() []string
- func (m *VulnStatusIndexMutation) AddedIDs(name string) []ent.Value
- func (m *VulnStatusIndexMutation) ClearEdge(name string) error
- func (m *VulnStatusIndexMutation) ClearField(name string) error
- func (m *VulnStatusIndexMutation) ClearLatest()
- func (m *VulnStatusIndexMutation) ClearStatus()
- func (m *VulnStatusIndexMutation) ClearedEdges() []string
- func (m *VulnStatusIndexMutation) ClearedFields() []string
- func (m VulnStatusIndexMutation) Client() *Client
- func (m *VulnStatusIndexMutation) EdgeCleared(name string) bool
- func (m *VulnStatusIndexMutation) Field(name string) (ent.Value, bool)
- func (m *VulnStatusIndexMutation) FieldCleared(name string) bool
- func (m *VulnStatusIndexMutation) Fields() []string
- func (m *VulnStatusIndexMutation) ID() (id string, exists bool)
- func (m *VulnStatusIndexMutation) LatestCleared() bool
- func (m *VulnStatusIndexMutation) LatestID() (id int, exists bool)
- func (m *VulnStatusIndexMutation) LatestIDs() (ids []int)
- func (m *VulnStatusIndexMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *VulnStatusIndexMutation) Op() Op
- func (m *VulnStatusIndexMutation) RemoveStatuIDs(ids ...int)
- func (m *VulnStatusIndexMutation) RemovedEdges() []string
- func (m *VulnStatusIndexMutation) RemovedIDs(name string) []ent.Value
- func (m *VulnStatusIndexMutation) RemovedStatusIDs() (ids []int)
- func (m *VulnStatusIndexMutation) ResetEdge(name string) error
- func (m *VulnStatusIndexMutation) ResetField(name string) error
- func (m *VulnStatusIndexMutation) ResetLatest()
- func (m *VulnStatusIndexMutation) ResetStatus()
- func (m *VulnStatusIndexMutation) SetField(name string, value ent.Value) error
- func (m *VulnStatusIndexMutation) SetID(id string)
- func (m *VulnStatusIndexMutation) SetLatestID(id int)
- func (m *VulnStatusIndexMutation) StatusCleared() bool
- func (m *VulnStatusIndexMutation) StatusIDs() (ids []int)
- func (m VulnStatusIndexMutation) Tx() (*Tx, error)
- func (m *VulnStatusIndexMutation) Type() string
- func (m *VulnStatusIndexMutation) Where(ps ...predicate.VulnStatusIndex)
- type VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) All(ctx context.Context) ([]*VulnStatusIndex, error)
- func (vsiq *VulnStatusIndexQuery) AllX(ctx context.Context) []*VulnStatusIndex
- func (vsiq *VulnStatusIndexQuery) Clone() *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) Count(ctx context.Context) (int, error)
- func (vsiq *VulnStatusIndexQuery) CountX(ctx context.Context) int
- func (vsiq *VulnStatusIndexQuery) Exist(ctx context.Context) (bool, error)
- func (vsiq *VulnStatusIndexQuery) ExistX(ctx context.Context) bool
- func (vsiq *VulnStatusIndexQuery) First(ctx context.Context) (*VulnStatusIndex, error)
- func (vsiq *VulnStatusIndexQuery) FirstID(ctx context.Context) (id string, err error)
- func (vsiq *VulnStatusIndexQuery) FirstIDX(ctx context.Context) string
- func (vsiq *VulnStatusIndexQuery) FirstX(ctx context.Context) *VulnStatusIndex
- func (vsiq *VulnStatusIndexQuery) GroupBy(field string, fields ...string) *VulnStatusIndexGroupBy
- func (vsiq *VulnStatusIndexQuery) IDs(ctx context.Context) ([]string, error)
- func (vsiq *VulnStatusIndexQuery) IDsX(ctx context.Context) []string
- func (vsiq *VulnStatusIndexQuery) Limit(limit int) *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) Offset(offset int) *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) Only(ctx context.Context) (*VulnStatusIndex, error)
- func (vsiq *VulnStatusIndexQuery) OnlyID(ctx context.Context) (id string, err error)
- func (vsiq *VulnStatusIndexQuery) OnlyIDX(ctx context.Context) string
- func (vsiq *VulnStatusIndexQuery) OnlyX(ctx context.Context) *VulnStatusIndex
- func (vsiq *VulnStatusIndexQuery) Order(o ...OrderFunc) *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) QueryLatest() *VulnStatusQuery
- func (vsiq *VulnStatusIndexQuery) QueryStatus() *VulnStatusQuery
- func (vsiq *VulnStatusIndexQuery) Select(fields ...string) *VulnStatusIndexSelect
- func (vsiq *VulnStatusIndexQuery) Unique(unique bool) *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) Where(ps ...predicate.VulnStatusIndex) *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) WithLatest(opts ...func(*VulnStatusQuery)) *VulnStatusIndexQuery
- func (vsiq *VulnStatusIndexQuery) WithStatus(opts ...func(*VulnStatusQuery)) *VulnStatusIndexQuery
- type VulnStatusIndexSelect
- func (vsis *VulnStatusIndexSelect) Bool(ctx context.Context) (_ bool, err error)
- func (vsis *VulnStatusIndexSelect) BoolX(ctx context.Context) bool
- func (vsis *VulnStatusIndexSelect) Bools(ctx context.Context) ([]bool, error)
- func (vsis *VulnStatusIndexSelect) BoolsX(ctx context.Context) []bool
- func (vsis *VulnStatusIndexSelect) Float64(ctx context.Context) (_ float64, err error)
- func (vsis *VulnStatusIndexSelect) Float64X(ctx context.Context) float64
- func (vsis *VulnStatusIndexSelect) Float64s(ctx context.Context) ([]float64, error)
- func (vsis *VulnStatusIndexSelect) Float64sX(ctx context.Context) []float64
- func (vsis *VulnStatusIndexSelect) Int(ctx context.Context) (_ int, err error)
- func (vsis *VulnStatusIndexSelect) IntX(ctx context.Context) int
- func (vsis *VulnStatusIndexSelect) Ints(ctx context.Context) ([]int, error)
- func (vsis *VulnStatusIndexSelect) IntsX(ctx context.Context) []int
- func (vsis *VulnStatusIndexSelect) Scan(ctx context.Context, v interface{}) error
- func (vsis *VulnStatusIndexSelect) ScanX(ctx context.Context, v interface{})
- func (vsis *VulnStatusIndexSelect) String(ctx context.Context) (_ string, err error)
- func (vsis *VulnStatusIndexSelect) StringX(ctx context.Context) string
- func (vsis *VulnStatusIndexSelect) Strings(ctx context.Context) ([]string, error)
- func (vsis *VulnStatusIndexSelect) StringsX(ctx context.Context) []string
- type VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) AddStatuIDs(ids ...int) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) AddStatus(v ...*VulnStatus) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) ClearLatest() *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) ClearStatus() *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) Exec(ctx context.Context) error
- func (vsiu *VulnStatusIndexUpdate) ExecX(ctx context.Context)
- func (vsiu *VulnStatusIndexUpdate) Mutation() *VulnStatusIndexMutation
- func (vsiu *VulnStatusIndexUpdate) RemoveStatuIDs(ids ...int) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) RemoveStatus(v ...*VulnStatus) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) Save(ctx context.Context) (int, error)
- func (vsiu *VulnStatusIndexUpdate) SaveX(ctx context.Context) int
- func (vsiu *VulnStatusIndexUpdate) SetLatest(v *VulnStatus) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) SetLatestID(id int) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) SetNillableLatestID(id *int) *VulnStatusIndexUpdate
- func (vsiu *VulnStatusIndexUpdate) Where(ps ...predicate.VulnStatusIndex) *VulnStatusIndexUpdate
- type VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) AddStatuIDs(ids ...int) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) AddStatus(v ...*VulnStatus) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) ClearLatest() *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) ClearStatus() *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) Exec(ctx context.Context) error
- func (vsiuo *VulnStatusIndexUpdateOne) ExecX(ctx context.Context)
- func (vsiuo *VulnStatusIndexUpdateOne) Mutation() *VulnStatusIndexMutation
- func (vsiuo *VulnStatusIndexUpdateOne) RemoveStatuIDs(ids ...int) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) RemoveStatus(v ...*VulnStatus) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) Save(ctx context.Context) (*VulnStatusIndex, error)
- func (vsiuo *VulnStatusIndexUpdateOne) SaveX(ctx context.Context) *VulnStatusIndex
- func (vsiuo *VulnStatusIndexUpdateOne) Select(field string, fields ...string) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) SetLatest(v *VulnStatus) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) SetLatestID(id int) *VulnStatusIndexUpdateOne
- func (vsiuo *VulnStatusIndexUpdateOne) SetNillableLatestID(id *int) *VulnStatusIndexUpdateOne
- type VulnStatusIndexUpsert
- type VulnStatusIndexUpsertBulk
- func (u *VulnStatusIndexUpsertBulk) DoNothing() *VulnStatusIndexUpsertBulk
- func (u *VulnStatusIndexUpsertBulk) Exec(ctx context.Context) error
- func (u *VulnStatusIndexUpsertBulk) ExecX(ctx context.Context)
- func (u *VulnStatusIndexUpsertBulk) Ignore() *VulnStatusIndexUpsertBulk
- func (u *VulnStatusIndexUpsertBulk) Update(set func(*VulnStatusIndexUpsert)) *VulnStatusIndexUpsertBulk
- func (u *VulnStatusIndexUpsertBulk) UpdateNewValues() *VulnStatusIndexUpsertBulk
- type VulnStatusIndexUpsertOne
- func (u *VulnStatusIndexUpsertOne) DoNothing() *VulnStatusIndexUpsertOne
- func (u *VulnStatusIndexUpsertOne) Exec(ctx context.Context) error
- func (u *VulnStatusIndexUpsertOne) ExecX(ctx context.Context)
- func (u *VulnStatusIndexUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *VulnStatusIndexUpsertOne) IDX(ctx context.Context) string
- func (u *VulnStatusIndexUpsertOne) Ignore() *VulnStatusIndexUpsertOne
- func (u *VulnStatusIndexUpsertOne) Update(set func(*VulnStatusIndexUpsert)) *VulnStatusIndexUpsertOne
- func (u *VulnStatusIndexUpsertOne) UpdateNewValues() *VulnStatusIndexUpsertOne
- type VulnStatusIndexes
- type VulnStatusMutation
- func (m *VulnStatusMutation) AddCreatedAt(i int64)
- func (m *VulnStatusMutation) AddExpiresAt(i int64)
- func (m *VulnStatusMutation) AddField(name string, value ent.Value) error
- func (m *VulnStatusMutation) AddedCreatedAt() (r int64, exists bool)
- func (m *VulnStatusMutation) AddedEdges() []string
- func (m *VulnStatusMutation) AddedExpiresAt() (r int64, exists bool)
- func (m *VulnStatusMutation) AddedField(name string) (ent.Value, bool)
- func (m *VulnStatusMutation) AddedFields() []string
- func (m *VulnStatusMutation) AddedIDs(name string) []ent.Value
- func (m *VulnStatusMutation) AuthorCleared() bool
- func (m *VulnStatusMutation) AuthorID() (id int, exists bool)
- func (m *VulnStatusMutation) AuthorIDs() (ids []int)
- func (m *VulnStatusMutation) ClearAuthor()
- func (m *VulnStatusMutation) ClearEdge(name string) error
- func (m *VulnStatusMutation) ClearField(name string) error
- func (m *VulnStatusMutation) ClearedEdges() []string
- func (m *VulnStatusMutation) ClearedFields() []string
- func (m VulnStatusMutation) Client() *Client
- func (m *VulnStatusMutation) Comment() (r string, exists bool)
- func (m *VulnStatusMutation) CreatedAt() (r int64, exists bool)
- func (m *VulnStatusMutation) EdgeCleared(name string) bool
- func (m *VulnStatusMutation) ExpiresAt() (r int64, exists bool)
- func (m *VulnStatusMutation) Field(name string) (ent.Value, bool)
- func (m *VulnStatusMutation) FieldCleared(name string) bool
- func (m *VulnStatusMutation) Fields() []string
- func (m *VulnStatusMutation) ID() (id int, exists bool)
- func (m *VulnStatusMutation) OldComment(ctx context.Context) (v string, err error)
- func (m *VulnStatusMutation) OldCreatedAt(ctx context.Context) (v int64, err error)
- func (m *VulnStatusMutation) OldExpiresAt(ctx context.Context) (v int64, err error)
- func (m *VulnStatusMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *VulnStatusMutation) OldPkgName(ctx context.Context) (v string, err error)
- func (m *VulnStatusMutation) OldPkgType(ctx context.Context) (v string, err error)
- func (m *VulnStatusMutation) OldSource(ctx context.Context) (v string, err error)
- func (m *VulnStatusMutation) OldStatus(ctx context.Context) (v types.VulnStatusType, err error)
- func (m *VulnStatusMutation) OldVulnID(ctx context.Context) (v string, err error)
- func (m *VulnStatusMutation) Op() Op
- func (m *VulnStatusMutation) PkgName() (r string, exists bool)
- func (m *VulnStatusMutation) PkgType() (r string, exists bool)
- func (m *VulnStatusMutation) RemovedEdges() []string
- func (m *VulnStatusMutation) RemovedIDs(name string) []ent.Value
- func (m *VulnStatusMutation) ResetAuthor()
- func (m *VulnStatusMutation) ResetComment()
- func (m *VulnStatusMutation) ResetCreatedAt()
- func (m *VulnStatusMutation) ResetEdge(name string) error
- func (m *VulnStatusMutation) ResetExpiresAt()
- func (m *VulnStatusMutation) ResetField(name string) error
- func (m *VulnStatusMutation) ResetPkgName()
- func (m *VulnStatusMutation) ResetPkgType()
- func (m *VulnStatusMutation) ResetSource()
- func (m *VulnStatusMutation) ResetStatus()
- func (m *VulnStatusMutation) ResetVulnID()
- func (m *VulnStatusMutation) SetAuthorID(id int)
- func (m *VulnStatusMutation) SetComment(s string)
- func (m *VulnStatusMutation) SetCreatedAt(i int64)
- func (m *VulnStatusMutation) SetExpiresAt(i int64)
- func (m *VulnStatusMutation) SetField(name string, value ent.Value) error
- func (m *VulnStatusMutation) SetPkgName(s string)
- func (m *VulnStatusMutation) SetPkgType(s string)
- func (m *VulnStatusMutation) SetSource(s string)
- func (m *VulnStatusMutation) SetStatus(tst types.VulnStatusType)
- func (m *VulnStatusMutation) SetVulnID(s string)
- func (m *VulnStatusMutation) Source() (r string, exists bool)
- func (m *VulnStatusMutation) Status() (r types.VulnStatusType, exists bool)
- func (m VulnStatusMutation) Tx() (*Tx, error)
- func (m *VulnStatusMutation) Type() string
- func (m *VulnStatusMutation) VulnID() (r string, exists bool)
- func (m *VulnStatusMutation) Where(ps ...predicate.VulnStatus)
- type VulnStatusQuery
- func (vsq *VulnStatusQuery) All(ctx context.Context) ([]*VulnStatus, error)
- func (vsq *VulnStatusQuery) AllX(ctx context.Context) []*VulnStatus
- func (vsq *VulnStatusQuery) Clone() *VulnStatusQuery
- func (vsq *VulnStatusQuery) Count(ctx context.Context) (int, error)
- func (vsq *VulnStatusQuery) CountX(ctx context.Context) int
- func (vsq *VulnStatusQuery) Exist(ctx context.Context) (bool, error)
- func (vsq *VulnStatusQuery) ExistX(ctx context.Context) bool
- func (vsq *VulnStatusQuery) First(ctx context.Context) (*VulnStatus, error)
- func (vsq *VulnStatusQuery) FirstID(ctx context.Context) (id int, err error)
- func (vsq *VulnStatusQuery) FirstIDX(ctx context.Context) int
- func (vsq *VulnStatusQuery) FirstX(ctx context.Context) *VulnStatus
- func (vsq *VulnStatusQuery) GroupBy(field string, fields ...string) *VulnStatusGroupBy
- func (vsq *VulnStatusQuery) IDs(ctx context.Context) ([]int, error)
- func (vsq *VulnStatusQuery) IDsX(ctx context.Context) []int
- func (vsq *VulnStatusQuery) Limit(limit int) *VulnStatusQuery
- func (vsq *VulnStatusQuery) Offset(offset int) *VulnStatusQuery
- func (vsq *VulnStatusQuery) Only(ctx context.Context) (*VulnStatus, error)
- func (vsq *VulnStatusQuery) OnlyID(ctx context.Context) (id int, err error)
- func (vsq *VulnStatusQuery) OnlyIDX(ctx context.Context) int
- func (vsq *VulnStatusQuery) OnlyX(ctx context.Context) *VulnStatus
- func (vsq *VulnStatusQuery) Order(o ...OrderFunc) *VulnStatusQuery
- func (vsq *VulnStatusQuery) QueryAuthor() *UserQuery
- func (vsq *VulnStatusQuery) Select(fields ...string) *VulnStatusSelect
- func (vsq *VulnStatusQuery) Unique(unique bool) *VulnStatusQuery
- func (vsq *VulnStatusQuery) Where(ps ...predicate.VulnStatus) *VulnStatusQuery
- func (vsq *VulnStatusQuery) WithAuthor(opts ...func(*UserQuery)) *VulnStatusQuery
- type VulnStatusSelect
- func (vss *VulnStatusSelect) Bool(ctx context.Context) (_ bool, err error)
- func (vss *VulnStatusSelect) BoolX(ctx context.Context) bool
- func (vss *VulnStatusSelect) Bools(ctx context.Context) ([]bool, error)
- func (vss *VulnStatusSelect) BoolsX(ctx context.Context) []bool
- func (vss *VulnStatusSelect) Float64(ctx context.Context) (_ float64, err error)
- func (vss *VulnStatusSelect) Float64X(ctx context.Context) float64
- func (vss *VulnStatusSelect) Float64s(ctx context.Context) ([]float64, error)
- func (vss *VulnStatusSelect) Float64sX(ctx context.Context) []float64
- func (vss *VulnStatusSelect) Int(ctx context.Context) (_ int, err error)
- func (vss *VulnStatusSelect) IntX(ctx context.Context) int
- func (vss *VulnStatusSelect) Ints(ctx context.Context) ([]int, error)
- func (vss *VulnStatusSelect) IntsX(ctx context.Context) []int
- func (vss *VulnStatusSelect) Scan(ctx context.Context, v interface{}) error
- func (vss *VulnStatusSelect) ScanX(ctx context.Context, v interface{})
- func (vss *VulnStatusSelect) String(ctx context.Context) (_ string, err error)
- func (vss *VulnStatusSelect) StringX(ctx context.Context) string
- func (vss *VulnStatusSelect) Strings(ctx context.Context) ([]string, error)
- func (vss *VulnStatusSelect) StringsX(ctx context.Context) []string
- type VulnStatusSlice
- type VulnStatusUpdate
- func (vsu *VulnStatusUpdate) AddCreatedAt(i int64) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) AddExpiresAt(i int64) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) ClearAuthor() *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) Exec(ctx context.Context) error
- func (vsu *VulnStatusUpdate) ExecX(ctx context.Context)
- func (vsu *VulnStatusUpdate) Mutation() *VulnStatusMutation
- func (vsu *VulnStatusUpdate) Save(ctx context.Context) (int, error)
- func (vsu *VulnStatusUpdate) SaveX(ctx context.Context) int
- func (vsu *VulnStatusUpdate) SetAuthor(u *User) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetAuthorID(id int) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetComment(s string) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetCreatedAt(i int64) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetExpiresAt(i int64) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetNillableAuthorID(id *int) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetPkgName(s string) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetPkgType(s string) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetSource(s string) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetStatus(tst types.VulnStatusType) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) SetVulnID(s string) *VulnStatusUpdate
- func (vsu *VulnStatusUpdate) Where(ps ...predicate.VulnStatus) *VulnStatusUpdate
- type VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) AddCreatedAt(i int64) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) AddExpiresAt(i int64) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) ClearAuthor() *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) Exec(ctx context.Context) error
- func (vsuo *VulnStatusUpdateOne) ExecX(ctx context.Context)
- func (vsuo *VulnStatusUpdateOne) Mutation() *VulnStatusMutation
- func (vsuo *VulnStatusUpdateOne) Save(ctx context.Context) (*VulnStatus, error)
- func (vsuo *VulnStatusUpdateOne) SaveX(ctx context.Context) *VulnStatus
- func (vsuo *VulnStatusUpdateOne) Select(field string, fields ...string) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetAuthor(u *User) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetAuthorID(id int) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetComment(s string) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetCreatedAt(i int64) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetExpiresAt(i int64) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetNillableAuthorID(id *int) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetPkgName(s string) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetPkgType(s string) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetSource(s string) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetStatus(tst types.VulnStatusType) *VulnStatusUpdateOne
- func (vsuo *VulnStatusUpdateOne) SetVulnID(s string) *VulnStatusUpdateOne
- type VulnStatusUpsert
- func (u *VulnStatusUpsert) SetComment(v string) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetCreatedAt(v int64) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetExpiresAt(v int64) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetPkgName(v string) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetPkgType(v string) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetSource(v string) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetStatus(v types.VulnStatusType) *VulnStatusUpsert
- func (u *VulnStatusUpsert) SetVulnID(v string) *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdateComment() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdateCreatedAt() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdateExpiresAt() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdatePkgName() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdatePkgType() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdateSource() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdateStatus() *VulnStatusUpsert
- func (u *VulnStatusUpsert) UpdateVulnID() *VulnStatusUpsert
- type VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) DoNothing() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) Exec(ctx context.Context) error
- func (u *VulnStatusUpsertBulk) ExecX(ctx context.Context)
- func (u *VulnStatusUpsertBulk) Ignore() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetComment(v string) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetCreatedAt(v int64) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetExpiresAt(v int64) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetPkgName(v string) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetPkgType(v string) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetSource(v string) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetStatus(v types.VulnStatusType) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) SetVulnID(v string) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) Update(set func(*VulnStatusUpsert)) *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateComment() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateCreatedAt() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateExpiresAt() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateNewValues() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdatePkgName() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdatePkgType() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateSource() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateStatus() *VulnStatusUpsertBulk
- func (u *VulnStatusUpsertBulk) UpdateVulnID() *VulnStatusUpsertBulk
- type VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) DoNothing() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) Exec(ctx context.Context) error
- func (u *VulnStatusUpsertOne) ExecX(ctx context.Context)
- func (u *VulnStatusUpsertOne) ID(ctx context.Context) (id int, err error)
- func (u *VulnStatusUpsertOne) IDX(ctx context.Context) int
- func (u *VulnStatusUpsertOne) Ignore() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetComment(v string) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetCreatedAt(v int64) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetExpiresAt(v int64) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetPkgName(v string) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetPkgType(v string) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetSource(v string) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetStatus(v types.VulnStatusType) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) SetVulnID(v string) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) Update(set func(*VulnStatusUpsert)) *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateComment() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateCreatedAt() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateExpiresAt() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateNewValues() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdatePkgName() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdatePkgType() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateSource() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateStatus() *VulnStatusUpsertOne
- func (u *VulnStatusUpsertOne) UpdateVulnID() *VulnStatusUpsertOne
- type Vulnerabilities
- type Vulnerability
- type VulnerabilityClient
- func (c *VulnerabilityClient) Create() *VulnerabilityCreate
- func (c *VulnerabilityClient) CreateBulk(builders ...*VulnerabilityCreate) *VulnerabilityCreateBulk
- func (c *VulnerabilityClient) Delete() *VulnerabilityDelete
- func (c *VulnerabilityClient) DeleteOne(v *Vulnerability) *VulnerabilityDeleteOne
- func (c *VulnerabilityClient) DeleteOneID(id string) *VulnerabilityDeleteOne
- func (c *VulnerabilityClient) Get(ctx context.Context, id string) (*Vulnerability, error)
- func (c *VulnerabilityClient) GetX(ctx context.Context, id string) *Vulnerability
- func (c *VulnerabilityClient) Hooks() []Hook
- func (c *VulnerabilityClient) Query() *VulnerabilityQuery
- func (c *VulnerabilityClient) QueryCustomSeverity(v *Vulnerability) *SeverityQuery
- func (c *VulnerabilityClient) QueryPackages(v *Vulnerability) *PackageRecordQuery
- func (c *VulnerabilityClient) Update() *VulnerabilityUpdate
- func (c *VulnerabilityClient) UpdateOne(v *Vulnerability) *VulnerabilityUpdateOne
- func (c *VulnerabilityClient) UpdateOneID(id string) *VulnerabilityUpdateOne
- func (c *VulnerabilityClient) Use(hooks ...Hook)
- type VulnerabilityCreate
- func (vc *VulnerabilityCreate) AddPackageIDs(ids ...int) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) AddPackages(p ...*PackageRecord) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) Exec(ctx context.Context) error
- func (vc *VulnerabilityCreate) ExecX(ctx context.Context)
- func (vc *VulnerabilityCreate) Mutation() *VulnerabilityMutation
- func (vc *VulnerabilityCreate) OnConflict(opts ...sql.ConflictOption) *VulnerabilityUpsertOne
- func (vc *VulnerabilityCreate) OnConflictColumns(columns ...string) *VulnerabilityUpsertOne
- func (vc *VulnerabilityCreate) Save(ctx context.Context) (*Vulnerability, error)
- func (vc *VulnerabilityCreate) SaveX(ctx context.Context) *Vulnerability
- func (vc *VulnerabilityCreate) SetCustomSeverity(s *Severity) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetCustomSeverityID(id int) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetCvss(s []string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetCweID(s []string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetDescription(s string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetFirstSeenAt(i int64) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetID(s string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetLastModifiedAt(i int64) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetNillableCustomSeverityID(id *int) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetNillableDescription(s *string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetNillableSeverity(s *string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetNillableTitle(s *string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetReferences(s []string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetSeverity(s string) *VulnerabilityCreate
- func (vc *VulnerabilityCreate) SetTitle(s string) *VulnerabilityCreate
- type VulnerabilityCreateBulk
- func (vcb *VulnerabilityCreateBulk) Exec(ctx context.Context) error
- func (vcb *VulnerabilityCreateBulk) ExecX(ctx context.Context)
- func (vcb *VulnerabilityCreateBulk) OnConflict(opts ...sql.ConflictOption) *VulnerabilityUpsertBulk
- func (vcb *VulnerabilityCreateBulk) OnConflictColumns(columns ...string) *VulnerabilityUpsertBulk
- func (vcb *VulnerabilityCreateBulk) Save(ctx context.Context) ([]*Vulnerability, error)
- func (vcb *VulnerabilityCreateBulk) SaveX(ctx context.Context) []*Vulnerability
- type VulnerabilityDelete
- type VulnerabilityDeleteOne
- type VulnerabilityEdges
- type VulnerabilityGroupBy
- func (vgb *VulnerabilityGroupBy) Aggregate(fns ...AggregateFunc) *VulnerabilityGroupBy
- func (vgb *VulnerabilityGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (vgb *VulnerabilityGroupBy) BoolX(ctx context.Context) bool
- func (vgb *VulnerabilityGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (vgb *VulnerabilityGroupBy) BoolsX(ctx context.Context) []bool
- func (vgb *VulnerabilityGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (vgb *VulnerabilityGroupBy) Float64X(ctx context.Context) float64
- func (vgb *VulnerabilityGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (vgb *VulnerabilityGroupBy) Float64sX(ctx context.Context) []float64
- func (vgb *VulnerabilityGroupBy) Int(ctx context.Context) (_ int, err error)
- func (vgb *VulnerabilityGroupBy) IntX(ctx context.Context) int
- func (vgb *VulnerabilityGroupBy) Ints(ctx context.Context) ([]int, error)
- func (vgb *VulnerabilityGroupBy) IntsX(ctx context.Context) []int
- func (vgb *VulnerabilityGroupBy) Scan(ctx context.Context, v interface{}) error
- func (vgb *VulnerabilityGroupBy) ScanX(ctx context.Context, v interface{})
- func (vgb *VulnerabilityGroupBy) String(ctx context.Context) (_ string, err error)
- func (vgb *VulnerabilityGroupBy) StringX(ctx context.Context) string
- func (vgb *VulnerabilityGroupBy) Strings(ctx context.Context) ([]string, error)
- func (vgb *VulnerabilityGroupBy) StringsX(ctx context.Context) []string
- type VulnerabilityMutation
- func (m *VulnerabilityMutation) AddField(name string, value ent.Value) error
- func (m *VulnerabilityMutation) AddFirstSeenAt(i int64)
- func (m *VulnerabilityMutation) AddLastModifiedAt(i int64)
- func (m *VulnerabilityMutation) AddPackageIDs(ids ...int)
- func (m *VulnerabilityMutation) AddedEdges() []string
- func (m *VulnerabilityMutation) AddedField(name string) (ent.Value, bool)
- func (m *VulnerabilityMutation) AddedFields() []string
- func (m *VulnerabilityMutation) AddedFirstSeenAt() (r int64, exists bool)
- func (m *VulnerabilityMutation) AddedIDs(name string) []ent.Value
- func (m *VulnerabilityMutation) AddedLastModifiedAt() (r int64, exists bool)
- func (m *VulnerabilityMutation) ClearCustomSeverity()
- func (m *VulnerabilityMutation) ClearCvss()
- func (m *VulnerabilityMutation) ClearCweID()
- func (m *VulnerabilityMutation) ClearDescription()
- func (m *VulnerabilityMutation) ClearEdge(name string) error
- func (m *VulnerabilityMutation) ClearField(name string) error
- func (m *VulnerabilityMutation) ClearPackages()
- func (m *VulnerabilityMutation) ClearReferences()
- func (m *VulnerabilityMutation) ClearSeverity()
- func (m *VulnerabilityMutation) ClearTitle()
- func (m *VulnerabilityMutation) ClearedEdges() []string
- func (m *VulnerabilityMutation) ClearedFields() []string
- func (m VulnerabilityMutation) Client() *Client
- func (m *VulnerabilityMutation) CustomSeverityCleared() bool
- func (m *VulnerabilityMutation) CustomSeverityID() (id int, exists bool)
- func (m *VulnerabilityMutation) CustomSeverityIDs() (ids []int)
- func (m *VulnerabilityMutation) Cvss() (r []string, exists bool)
- func (m *VulnerabilityMutation) CvssCleared() bool
- func (m *VulnerabilityMutation) CweID() (r []string, exists bool)
- func (m *VulnerabilityMutation) CweIDCleared() bool
- func (m *VulnerabilityMutation) Description() (r string, exists bool)
- func (m *VulnerabilityMutation) DescriptionCleared() bool
- func (m *VulnerabilityMutation) EdgeCleared(name string) bool
- func (m *VulnerabilityMutation) Field(name string) (ent.Value, bool)
- func (m *VulnerabilityMutation) FieldCleared(name string) bool
- func (m *VulnerabilityMutation) Fields() []string
- func (m *VulnerabilityMutation) FirstSeenAt() (r int64, exists bool)
- func (m *VulnerabilityMutation) ID() (id string, exists bool)
- func (m *VulnerabilityMutation) LastModifiedAt() (r int64, exists bool)
- func (m *VulnerabilityMutation) OldCvss(ctx context.Context) (v []string, err error)
- func (m *VulnerabilityMutation) OldCweID(ctx context.Context) (v []string, err error)
- func (m *VulnerabilityMutation) OldDescription(ctx context.Context) (v string, err error)
- func (m *VulnerabilityMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *VulnerabilityMutation) OldFirstSeenAt(ctx context.Context) (v int64, err error)
- func (m *VulnerabilityMutation) OldLastModifiedAt(ctx context.Context) (v int64, err error)
- func (m *VulnerabilityMutation) OldReferences(ctx context.Context) (v []string, err error)
- func (m *VulnerabilityMutation) OldSeverity(ctx context.Context) (v string, err error)
- func (m *VulnerabilityMutation) OldTitle(ctx context.Context) (v string, err error)
- func (m *VulnerabilityMutation) Op() Op
- func (m *VulnerabilityMutation) PackagesCleared() bool
- func (m *VulnerabilityMutation) PackagesIDs() (ids []int)
- func (m *VulnerabilityMutation) References() (r []string, exists bool)
- func (m *VulnerabilityMutation) ReferencesCleared() bool
- func (m *VulnerabilityMutation) RemovePackageIDs(ids ...int)
- func (m *VulnerabilityMutation) RemovedEdges() []string
- func (m *VulnerabilityMutation) RemovedIDs(name string) []ent.Value
- func (m *VulnerabilityMutation) RemovedPackagesIDs() (ids []int)
- func (m *VulnerabilityMutation) ResetCustomSeverity()
- func (m *VulnerabilityMutation) ResetCvss()
- func (m *VulnerabilityMutation) ResetCweID()
- func (m *VulnerabilityMutation) ResetDescription()
- func (m *VulnerabilityMutation) ResetEdge(name string) error
- func (m *VulnerabilityMutation) ResetField(name string) error
- func (m *VulnerabilityMutation) ResetFirstSeenAt()
- func (m *VulnerabilityMutation) ResetLastModifiedAt()
- func (m *VulnerabilityMutation) ResetPackages()
- func (m *VulnerabilityMutation) ResetReferences()
- func (m *VulnerabilityMutation) ResetSeverity()
- func (m *VulnerabilityMutation) ResetTitle()
- func (m *VulnerabilityMutation) SetCustomSeverityID(id int)
- func (m *VulnerabilityMutation) SetCvss(s []string)
- func (m *VulnerabilityMutation) SetCweID(s []string)
- func (m *VulnerabilityMutation) SetDescription(s string)
- func (m *VulnerabilityMutation) SetField(name string, value ent.Value) error
- func (m *VulnerabilityMutation) SetFirstSeenAt(i int64)
- func (m *VulnerabilityMutation) SetID(id string)
- func (m *VulnerabilityMutation) SetLastModifiedAt(i int64)
- func (m *VulnerabilityMutation) SetReferences(s []string)
- func (m *VulnerabilityMutation) SetSeverity(s string)
- func (m *VulnerabilityMutation) SetTitle(s string)
- func (m *VulnerabilityMutation) Severity() (r string, exists bool)
- func (m *VulnerabilityMutation) SeverityCleared() bool
- func (m *VulnerabilityMutation) Title() (r string, exists bool)
- func (m *VulnerabilityMutation) TitleCleared() bool
- func (m VulnerabilityMutation) Tx() (*Tx, error)
- func (m *VulnerabilityMutation) Type() string
- func (m *VulnerabilityMutation) Where(ps ...predicate.Vulnerability)
- type VulnerabilityQuery
- func (vq *VulnerabilityQuery) All(ctx context.Context) ([]*Vulnerability, error)
- func (vq *VulnerabilityQuery) AllX(ctx context.Context) []*Vulnerability
- func (vq *VulnerabilityQuery) Clone() *VulnerabilityQuery
- func (vq *VulnerabilityQuery) Count(ctx context.Context) (int, error)
- func (vq *VulnerabilityQuery) CountX(ctx context.Context) int
- func (vq *VulnerabilityQuery) Exist(ctx context.Context) (bool, error)
- func (vq *VulnerabilityQuery) ExistX(ctx context.Context) bool
- func (vq *VulnerabilityQuery) First(ctx context.Context) (*Vulnerability, error)
- func (vq *VulnerabilityQuery) FirstID(ctx context.Context) (id string, err error)
- func (vq *VulnerabilityQuery) FirstIDX(ctx context.Context) string
- func (vq *VulnerabilityQuery) FirstX(ctx context.Context) *Vulnerability
- func (vq *VulnerabilityQuery) GroupBy(field string, fields ...string) *VulnerabilityGroupBy
- func (vq *VulnerabilityQuery) IDs(ctx context.Context) ([]string, error)
- func (vq *VulnerabilityQuery) IDsX(ctx context.Context) []string
- func (vq *VulnerabilityQuery) Limit(limit int) *VulnerabilityQuery
- func (vq *VulnerabilityQuery) Offset(offset int) *VulnerabilityQuery
- func (vq *VulnerabilityQuery) Only(ctx context.Context) (*Vulnerability, error)
- func (vq *VulnerabilityQuery) OnlyID(ctx context.Context) (id string, err error)
- func (vq *VulnerabilityQuery) OnlyIDX(ctx context.Context) string
- func (vq *VulnerabilityQuery) OnlyX(ctx context.Context) *Vulnerability
- func (vq *VulnerabilityQuery) Order(o ...OrderFunc) *VulnerabilityQuery
- func (vq *VulnerabilityQuery) QueryCustomSeverity() *SeverityQuery
- func (vq *VulnerabilityQuery) QueryPackages() *PackageRecordQuery
- func (vq *VulnerabilityQuery) Select(fields ...string) *VulnerabilitySelect
- func (vq *VulnerabilityQuery) Unique(unique bool) *VulnerabilityQuery
- func (vq *VulnerabilityQuery) Where(ps ...predicate.Vulnerability) *VulnerabilityQuery
- func (vq *VulnerabilityQuery) WithCustomSeverity(opts ...func(*SeverityQuery)) *VulnerabilityQuery
- func (vq *VulnerabilityQuery) WithPackages(opts ...func(*PackageRecordQuery)) *VulnerabilityQuery
- type VulnerabilitySelect
- func (vs *VulnerabilitySelect) Bool(ctx context.Context) (_ bool, err error)
- func (vs *VulnerabilitySelect) BoolX(ctx context.Context) bool
- func (vs *VulnerabilitySelect) Bools(ctx context.Context) ([]bool, error)
- func (vs *VulnerabilitySelect) BoolsX(ctx context.Context) []bool
- func (vs *VulnerabilitySelect) Float64(ctx context.Context) (_ float64, err error)
- func (vs *VulnerabilitySelect) Float64X(ctx context.Context) float64
- func (vs *VulnerabilitySelect) Float64s(ctx context.Context) ([]float64, error)
- func (vs *VulnerabilitySelect) Float64sX(ctx context.Context) []float64
- func (vs *VulnerabilitySelect) Int(ctx context.Context) (_ int, err error)
- func (vs *VulnerabilitySelect) IntX(ctx context.Context) int
- func (vs *VulnerabilitySelect) Ints(ctx context.Context) ([]int, error)
- func (vs *VulnerabilitySelect) IntsX(ctx context.Context) []int
- func (vs *VulnerabilitySelect) Scan(ctx context.Context, v interface{}) error
- func (vs *VulnerabilitySelect) ScanX(ctx context.Context, v interface{})
- func (vs *VulnerabilitySelect) String(ctx context.Context) (_ string, err error)
- func (vs *VulnerabilitySelect) StringX(ctx context.Context) string
- func (vs *VulnerabilitySelect) Strings(ctx context.Context) ([]string, error)
- func (vs *VulnerabilitySelect) StringsX(ctx context.Context) []string
- type VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) AddFirstSeenAt(i int64) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) AddLastModifiedAt(i int64) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) AddPackageIDs(ids ...int) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) AddPackages(p ...*PackageRecord) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearCustomSeverity() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearCvss() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearCweID() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearDescription() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearPackages() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearReferences() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearSeverity() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) ClearTitle() *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) Exec(ctx context.Context) error
- func (vu *VulnerabilityUpdate) ExecX(ctx context.Context)
- func (vu *VulnerabilityUpdate) Mutation() *VulnerabilityMutation
- func (vu *VulnerabilityUpdate) RemovePackageIDs(ids ...int) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) RemovePackages(p ...*PackageRecord) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) Save(ctx context.Context) (int, error)
- func (vu *VulnerabilityUpdate) SaveX(ctx context.Context) int
- func (vu *VulnerabilityUpdate) SetCustomSeverity(s *Severity) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetCustomSeverityID(id int) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetCvss(s []string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetCweID(s []string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetDescription(s string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetFirstSeenAt(i int64) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetLastModifiedAt(i int64) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetNillableCustomSeverityID(id *int) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetNillableDescription(s *string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetNillableSeverity(s *string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetNillableTitle(s *string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetReferences(s []string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetSeverity(s string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) SetTitle(s string) *VulnerabilityUpdate
- func (vu *VulnerabilityUpdate) Where(ps ...predicate.Vulnerability) *VulnerabilityUpdate
- type VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) AddFirstSeenAt(i int64) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) AddLastModifiedAt(i int64) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) AddPackageIDs(ids ...int) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) AddPackages(p ...*PackageRecord) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearCustomSeverity() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearCvss() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearCweID() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearDescription() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearPackages() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearReferences() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearSeverity() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) ClearTitle() *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) Exec(ctx context.Context) error
- func (vuo *VulnerabilityUpdateOne) ExecX(ctx context.Context)
- func (vuo *VulnerabilityUpdateOne) Mutation() *VulnerabilityMutation
- func (vuo *VulnerabilityUpdateOne) RemovePackageIDs(ids ...int) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) RemovePackages(p ...*PackageRecord) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) Save(ctx context.Context) (*Vulnerability, error)
- func (vuo *VulnerabilityUpdateOne) SaveX(ctx context.Context) *Vulnerability
- func (vuo *VulnerabilityUpdateOne) Select(field string, fields ...string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetCustomSeverity(s *Severity) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetCustomSeverityID(id int) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetCvss(s []string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetCweID(s []string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetDescription(s string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetFirstSeenAt(i int64) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetLastModifiedAt(i int64) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetNillableCustomSeverityID(id *int) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetNillableDescription(s *string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetNillableSeverity(s *string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetNillableTitle(s *string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetReferences(s []string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetSeverity(s string) *VulnerabilityUpdateOne
- func (vuo *VulnerabilityUpdateOne) SetTitle(s string) *VulnerabilityUpdateOne
- type VulnerabilityUpsert
- func (u *VulnerabilityUpsert) ClearCvss() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) ClearCweID() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) ClearDescription() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) ClearReferences() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) ClearSeverity() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) ClearTitle() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetCvss(v []string) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetCweID(v []string) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetDescription(v string) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetFirstSeenAt(v int64) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetLastModifiedAt(v int64) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetReferences(v []string) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetSeverity(v string) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) SetTitle(v string) *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateCvss() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateCweID() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateDescription() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateFirstSeenAt() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateLastModifiedAt() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateReferences() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateSeverity() *VulnerabilityUpsert
- func (u *VulnerabilityUpsert) UpdateTitle() *VulnerabilityUpsert
- type VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) ClearCvss() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) ClearCweID() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) ClearDescription() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) ClearReferences() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) ClearSeverity() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) ClearTitle() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) DoNothing() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) Exec(ctx context.Context) error
- func (u *VulnerabilityUpsertBulk) ExecX(ctx context.Context)
- func (u *VulnerabilityUpsertBulk) Ignore() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetCvss(v []string) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetCweID(v []string) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetDescription(v string) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetFirstSeenAt(v int64) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetLastModifiedAt(v int64) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetReferences(v []string) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetSeverity(v string) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) SetTitle(v string) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) Update(set func(*VulnerabilityUpsert)) *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateCvss() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateCweID() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateDescription() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateFirstSeenAt() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateLastModifiedAt() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateNewValues() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateReferences() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateSeverity() *VulnerabilityUpsertBulk
- func (u *VulnerabilityUpsertBulk) UpdateTitle() *VulnerabilityUpsertBulk
- type VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) ClearCvss() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) ClearCweID() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) ClearDescription() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) ClearReferences() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) ClearSeverity() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) ClearTitle() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) DoNothing() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) Exec(ctx context.Context) error
- func (u *VulnerabilityUpsertOne) ExecX(ctx context.Context)
- func (u *VulnerabilityUpsertOne) ID(ctx context.Context) (id string, err error)
- func (u *VulnerabilityUpsertOne) IDX(ctx context.Context) string
- func (u *VulnerabilityUpsertOne) Ignore() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetCvss(v []string) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetCweID(v []string) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetDescription(v string) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetFirstSeenAt(v int64) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetLastModifiedAt(v int64) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetReferences(v []string) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetSeverity(v string) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) SetTitle(v string) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) Update(set func(*VulnerabilityUpsert)) *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateCvss() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateCweID() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateDescription() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateFirstSeenAt() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateLastModifiedAt() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateNewValues() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateReferences() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateSeverity() *VulnerabilityUpsertOne
- func (u *VulnerabilityUpsertOne) UpdateTitle() *VulnerabilityUpsertOne
Constants ¶
const ( // Operation types. OpCreate = ent.OpCreate OpDelete = ent.OpDelete OpDeleteOne = ent.OpDeleteOne OpUpdate = ent.OpUpdate OpUpdateOne = ent.OpUpdateOne // Node types. TypeAuthStateCache = "AuthStateCache" TypePackageRecord = "PackageRecord" TypeRepository = "Repository" TypeScan = "Scan" TypeSession = "Session" TypeSeverity = "Severity" TypeUser = "User" TypeVulnStatus = "VulnStatus" TypeVulnStatusIndex = "VulnStatusIndex" TypeVulnerability = "Vulnerability" )
Variables ¶
This section is empty.
Functions ¶
func IsConstraintError ¶
IsConstraintError returns a boolean indicating whether the error is a constraint failure.
func IsNotFound ¶
IsNotFound returns a boolean indicating whether the error is a not found error.
func IsNotLoaded ¶
IsNotLoaded returns a boolean indicating whether the error is a not loaded error.
func IsNotSingular ¶
IsNotSingular returns a boolean indicating whether the error is a not singular error.
func IsValidationError ¶
IsValidationError returns a boolean indicating whether the error is a validation error.
func NewContext ¶
NewContext returns a new context with the given Client attached.
Types ¶
type AggregateFunc ¶
AggregateFunc applies an aggregation step on the group-by traversal/selector.
func As ¶
func As(fn AggregateFunc, end string) AggregateFunc
As is a pseudo aggregation function for renaming another other functions with custom names. For example:
GroupBy(field1, field2). Aggregate(ent.As(ent.Sum(field1), "sum_field1"), (ent.As(ent.Sum(field2), "sum_field2")). Scan(ctx, &v)
func Count ¶
func Count() AggregateFunc
Count applies the "count" aggregation function on each group.
func Max ¶
func Max(field string) AggregateFunc
Max applies the "max" aggregation function on the given field of each group.
func Mean ¶
func Mean(field string) AggregateFunc
Mean applies the "mean" aggregation function on the given field of each group.
func Min ¶
func Min(field string) AggregateFunc
Min applies the "min" aggregation function on the given field of each group.
func Sum ¶
func Sum(field string) AggregateFunc
Sum applies the "sum" aggregation function on the given field of each group.
type AuthStateCache ¶
type AuthStateCache struct { // ID of the ent. ID string `json:"id,omitempty"` // ExpiresAt holds the value of the "expires_at" field. ExpiresAt int64 `json:"expires_at,omitempty"` // contains filtered or unexported fields }
AuthStateCache is the model entity for the AuthStateCache schema.
func (*AuthStateCache) String ¶
func (asc *AuthStateCache) String() string
String implements the fmt.Stringer.
func (*AuthStateCache) Unwrap ¶
func (asc *AuthStateCache) Unwrap() *AuthStateCache
Unwrap unwraps the AuthStateCache 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 (*AuthStateCache) Update ¶
func (asc *AuthStateCache) Update() *AuthStateCacheUpdateOne
Update returns a builder for updating this AuthStateCache. Note that you need to call AuthStateCache.Unwrap() before calling this method if this AuthStateCache was returned from a transaction, and the transaction was committed or rolled back.
type AuthStateCacheClient ¶
type AuthStateCacheClient struct {
// contains filtered or unexported fields
}
AuthStateCacheClient is a client for the AuthStateCache schema.
func NewAuthStateCacheClient ¶
func NewAuthStateCacheClient(c config) *AuthStateCacheClient
NewAuthStateCacheClient returns a client for the AuthStateCache from the given config.
func (*AuthStateCacheClient) Create ¶
func (c *AuthStateCacheClient) Create() *AuthStateCacheCreate
Create returns a create builder for AuthStateCache.
func (*AuthStateCacheClient) CreateBulk ¶
func (c *AuthStateCacheClient) CreateBulk(builders ...*AuthStateCacheCreate) *AuthStateCacheCreateBulk
CreateBulk returns a builder for creating a bulk of AuthStateCache entities.
func (*AuthStateCacheClient) Delete ¶
func (c *AuthStateCacheClient) Delete() *AuthStateCacheDelete
Delete returns a delete builder for AuthStateCache.
func (*AuthStateCacheClient) DeleteOne ¶
func (c *AuthStateCacheClient) DeleteOne(asc *AuthStateCache) *AuthStateCacheDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*AuthStateCacheClient) DeleteOneID ¶
func (c *AuthStateCacheClient) DeleteOneID(id string) *AuthStateCacheDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*AuthStateCacheClient) Get ¶
func (c *AuthStateCacheClient) Get(ctx context.Context, id string) (*AuthStateCache, error)
Get returns a AuthStateCache entity by its id.
func (*AuthStateCacheClient) GetX ¶
func (c *AuthStateCacheClient) GetX(ctx context.Context, id string) *AuthStateCache
GetX is like Get, but panics if an error occurs.
func (*AuthStateCacheClient) Hooks ¶
func (c *AuthStateCacheClient) Hooks() []Hook
Hooks returns the client hooks.
func (*AuthStateCacheClient) Query ¶
func (c *AuthStateCacheClient) Query() *AuthStateCacheQuery
Query returns a query builder for AuthStateCache.
func (*AuthStateCacheClient) Update ¶
func (c *AuthStateCacheClient) Update() *AuthStateCacheUpdate
Update returns an update builder for AuthStateCache.
func (*AuthStateCacheClient) UpdateOne ¶
func (c *AuthStateCacheClient) UpdateOne(asc *AuthStateCache) *AuthStateCacheUpdateOne
UpdateOne returns an update builder for the given entity.
func (*AuthStateCacheClient) UpdateOneID ¶
func (c *AuthStateCacheClient) UpdateOneID(id string) *AuthStateCacheUpdateOne
UpdateOneID returns an update builder for the given id.
func (*AuthStateCacheClient) Use ¶
func (c *AuthStateCacheClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `authstatecache.Hooks(f(g(h())))`.
type AuthStateCacheCreate ¶
type AuthStateCacheCreate struct {
// contains filtered or unexported fields
}
AuthStateCacheCreate is the builder for creating a AuthStateCache entity.
func (*AuthStateCacheCreate) Exec ¶
func (ascc *AuthStateCacheCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*AuthStateCacheCreate) ExecX ¶
func (ascc *AuthStateCacheCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheCreate) Mutation ¶
func (ascc *AuthStateCacheCreate) Mutation() *AuthStateCacheMutation
Mutation returns the AuthStateCacheMutation object of the builder.
func (*AuthStateCacheCreate) OnConflict ¶
func (ascc *AuthStateCacheCreate) OnConflict(opts ...sql.ConflictOption) *AuthStateCacheUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.AuthStateCache.Create(). SetExpiresAt(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.AuthStateCacheUpsert) { SetExpiresAt(v+v). }). Exec(ctx)
func (*AuthStateCacheCreate) OnConflictColumns ¶
func (ascc *AuthStateCacheCreate) OnConflictColumns(columns ...string) *AuthStateCacheUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.AuthStateCache.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*AuthStateCacheCreate) Save ¶
func (ascc *AuthStateCacheCreate) Save(ctx context.Context) (*AuthStateCache, error)
Save creates the AuthStateCache in the database.
func (*AuthStateCacheCreate) SaveX ¶
func (ascc *AuthStateCacheCreate) SaveX(ctx context.Context) *AuthStateCache
SaveX calls Save and panics if Save returns an error.
func (*AuthStateCacheCreate) SetExpiresAt ¶
func (ascc *AuthStateCacheCreate) SetExpiresAt(i int64) *AuthStateCacheCreate
SetExpiresAt sets the "expires_at" field.
func (*AuthStateCacheCreate) SetID ¶
func (ascc *AuthStateCacheCreate) SetID(s string) *AuthStateCacheCreate
SetID sets the "id" field.
type AuthStateCacheCreateBulk ¶
type AuthStateCacheCreateBulk struct {
// contains filtered or unexported fields
}
AuthStateCacheCreateBulk is the builder for creating many AuthStateCache entities in bulk.
func (*AuthStateCacheCreateBulk) Exec ¶
func (asccb *AuthStateCacheCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*AuthStateCacheCreateBulk) ExecX ¶
func (asccb *AuthStateCacheCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheCreateBulk) OnConflict ¶
func (asccb *AuthStateCacheCreateBulk) OnConflict(opts ...sql.ConflictOption) *AuthStateCacheUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.AuthStateCache.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.AuthStateCacheUpsert) { SetExpiresAt(v+v). }). Exec(ctx)
func (*AuthStateCacheCreateBulk) OnConflictColumns ¶
func (asccb *AuthStateCacheCreateBulk) OnConflictColumns(columns ...string) *AuthStateCacheUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.AuthStateCache.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*AuthStateCacheCreateBulk) Save ¶
func (asccb *AuthStateCacheCreateBulk) Save(ctx context.Context) ([]*AuthStateCache, error)
Save creates the AuthStateCache entities in the database.
func (*AuthStateCacheCreateBulk) SaveX ¶
func (asccb *AuthStateCacheCreateBulk) SaveX(ctx context.Context) []*AuthStateCache
SaveX is like Save, but panics if an error occurs.
type AuthStateCacheDelete ¶
type AuthStateCacheDelete struct {
// contains filtered or unexported fields
}
AuthStateCacheDelete is the builder for deleting a AuthStateCache entity.
func (*AuthStateCacheDelete) Exec ¶
func (ascd *AuthStateCacheDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*AuthStateCacheDelete) ExecX ¶
func (ascd *AuthStateCacheDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheDelete) Where ¶
func (ascd *AuthStateCacheDelete) Where(ps ...predicate.AuthStateCache) *AuthStateCacheDelete
Where appends a list predicates to the AuthStateCacheDelete builder.
type AuthStateCacheDeleteOne ¶
type AuthStateCacheDeleteOne struct {
// contains filtered or unexported fields
}
AuthStateCacheDeleteOne is the builder for deleting a single AuthStateCache entity.
func (*AuthStateCacheDeleteOne) Exec ¶
func (ascdo *AuthStateCacheDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*AuthStateCacheDeleteOne) ExecX ¶
func (ascdo *AuthStateCacheDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type AuthStateCacheGroupBy ¶
type AuthStateCacheGroupBy struct {
// contains filtered or unexported fields
}
AuthStateCacheGroupBy is the group-by builder for AuthStateCache entities.
func (*AuthStateCacheGroupBy) Aggregate ¶
func (ascgb *AuthStateCacheGroupBy) Aggregate(fns ...AggregateFunc) *AuthStateCacheGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*AuthStateCacheGroupBy) Bool ¶
func (ascgb *AuthStateCacheGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) BoolX ¶
func (ascgb *AuthStateCacheGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*AuthStateCacheGroupBy) Bools ¶
func (ascgb *AuthStateCacheGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) BoolsX ¶
func (ascgb *AuthStateCacheGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*AuthStateCacheGroupBy) Float64 ¶
func (ascgb *AuthStateCacheGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) Float64X ¶
func (ascgb *AuthStateCacheGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*AuthStateCacheGroupBy) Float64s ¶
func (ascgb *AuthStateCacheGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) Float64sX ¶
func (ascgb *AuthStateCacheGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*AuthStateCacheGroupBy) Int ¶
func (ascgb *AuthStateCacheGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) IntX ¶
func (ascgb *AuthStateCacheGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*AuthStateCacheGroupBy) Ints ¶
func (ascgb *AuthStateCacheGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) IntsX ¶
func (ascgb *AuthStateCacheGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*AuthStateCacheGroupBy) Scan ¶
func (ascgb *AuthStateCacheGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*AuthStateCacheGroupBy) ScanX ¶
func (ascgb *AuthStateCacheGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*AuthStateCacheGroupBy) String ¶
func (ascgb *AuthStateCacheGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*AuthStateCacheGroupBy) StringX ¶
func (ascgb *AuthStateCacheGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type AuthStateCacheMutation ¶
type AuthStateCacheMutation struct {
// contains filtered or unexported fields
}
AuthStateCacheMutation represents an operation that mutates the AuthStateCache nodes in the graph.
func (*AuthStateCacheMutation) AddExpiresAt ¶
func (m *AuthStateCacheMutation) AddExpiresAt(i int64)
AddExpiresAt adds i to the "expires_at" field.
func (*AuthStateCacheMutation) AddField ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) AddedEdges ¶
func (m *AuthStateCacheMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*AuthStateCacheMutation) AddedExpiresAt ¶
func (m *AuthStateCacheMutation) AddedExpiresAt() (r int64, exists bool)
AddedExpiresAt returns the value that was added to the "expires_at" field in this mutation.
func (*AuthStateCacheMutation) AddedField ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) AddedFields ¶
func (m *AuthStateCacheMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*AuthStateCacheMutation) AddedIDs ¶
func (m *AuthStateCacheMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*AuthStateCacheMutation) ClearEdge ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) ClearField ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) ClearedEdges ¶
func (m *AuthStateCacheMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*AuthStateCacheMutation) ClearedFields ¶
func (m *AuthStateCacheMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (AuthStateCacheMutation) Client ¶
func (m AuthStateCacheMutation) 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 (*AuthStateCacheMutation) EdgeCleared ¶
func (m *AuthStateCacheMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*AuthStateCacheMutation) ExpiresAt ¶
func (m *AuthStateCacheMutation) ExpiresAt() (r int64, exists bool)
ExpiresAt returns the value of the "expires_at" field in the mutation.
func (*AuthStateCacheMutation) Field ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) FieldCleared ¶
func (m *AuthStateCacheMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*AuthStateCacheMutation) Fields ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) ID ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) OldExpiresAt ¶
func (m *AuthStateCacheMutation) OldExpiresAt(ctx context.Context) (v int64, err error)
OldExpiresAt returns the old "expires_at" field's value of the AuthStateCache entity. If the AuthStateCache 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 (*AuthStateCacheMutation) 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 (*AuthStateCacheMutation) Op ¶
func (m *AuthStateCacheMutation) Op() Op
Op returns the operation name.
func (*AuthStateCacheMutation) RemovedEdges ¶
func (m *AuthStateCacheMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*AuthStateCacheMutation) RemovedIDs ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) ResetEdge ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) ResetExpiresAt ¶
func (m *AuthStateCacheMutation) ResetExpiresAt()
ResetExpiresAt resets all changes to the "expires_at" field.
func (*AuthStateCacheMutation) ResetField ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) SetExpiresAt ¶
func (m *AuthStateCacheMutation) SetExpiresAt(i int64)
SetExpiresAt sets the "expires_at" field.
func (*AuthStateCacheMutation) SetField ¶
func (m *AuthStateCacheMutation) 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 (*AuthStateCacheMutation) SetID ¶
func (m *AuthStateCacheMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of AuthStateCache entities.
func (AuthStateCacheMutation) Tx ¶
func (m AuthStateCacheMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*AuthStateCacheMutation) Type ¶
func (m *AuthStateCacheMutation) Type() string
Type returns the node type of this mutation (AuthStateCache).
func (*AuthStateCacheMutation) Where ¶
func (m *AuthStateCacheMutation) Where(ps ...predicate.AuthStateCache)
Where appends a list predicates to the AuthStateCacheMutation builder.
type AuthStateCacheQuery ¶
type AuthStateCacheQuery struct {
// contains filtered or unexported fields
}
AuthStateCacheQuery is the builder for querying AuthStateCache entities.
func (*AuthStateCacheQuery) All ¶
func (ascq *AuthStateCacheQuery) All(ctx context.Context) ([]*AuthStateCache, error)
All executes the query and returns a list of AuthStateCaches.
func (*AuthStateCacheQuery) AllX ¶
func (ascq *AuthStateCacheQuery) AllX(ctx context.Context) []*AuthStateCache
AllX is like All, but panics if an error occurs.
func (*AuthStateCacheQuery) Clone ¶
func (ascq *AuthStateCacheQuery) Clone() *AuthStateCacheQuery
Clone returns a duplicate of the AuthStateCacheQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*AuthStateCacheQuery) Count ¶
func (ascq *AuthStateCacheQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*AuthStateCacheQuery) CountX ¶
func (ascq *AuthStateCacheQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*AuthStateCacheQuery) Exist ¶
func (ascq *AuthStateCacheQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*AuthStateCacheQuery) ExistX ¶
func (ascq *AuthStateCacheQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*AuthStateCacheQuery) First ¶
func (ascq *AuthStateCacheQuery) First(ctx context.Context) (*AuthStateCache, error)
First returns the first AuthStateCache entity from the query. Returns a *NotFoundError when no AuthStateCache was found.
func (*AuthStateCacheQuery) FirstID ¶
func (ascq *AuthStateCacheQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first AuthStateCache ID from the query. Returns a *NotFoundError when no AuthStateCache ID was found.
func (*AuthStateCacheQuery) FirstIDX ¶
func (ascq *AuthStateCacheQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*AuthStateCacheQuery) FirstX ¶
func (ascq *AuthStateCacheQuery) FirstX(ctx context.Context) *AuthStateCache
FirstX is like First, but panics if an error occurs.
func (*AuthStateCacheQuery) GroupBy ¶
func (ascq *AuthStateCacheQuery) GroupBy(field string, fields ...string) *AuthStateCacheGroupBy
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 { ExpiresAt int64 `json:"expires_at,omitempty"` Count int `json:"count,omitempty"` } client.AuthStateCache.Query(). GroupBy(authstatecache.FieldExpiresAt). Aggregate(ent.Count()). Scan(ctx, &v)
func (*AuthStateCacheQuery) IDs ¶
func (ascq *AuthStateCacheQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of AuthStateCache IDs.
func (*AuthStateCacheQuery) IDsX ¶
func (ascq *AuthStateCacheQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*AuthStateCacheQuery) Limit ¶
func (ascq *AuthStateCacheQuery) Limit(limit int) *AuthStateCacheQuery
Limit adds a limit step to the query.
func (*AuthStateCacheQuery) Offset ¶
func (ascq *AuthStateCacheQuery) Offset(offset int) *AuthStateCacheQuery
Offset adds an offset step to the query.
func (*AuthStateCacheQuery) Only ¶
func (ascq *AuthStateCacheQuery) Only(ctx context.Context) (*AuthStateCache, error)
Only returns a single AuthStateCache entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one AuthStateCache entity is not found. Returns a *NotFoundError when no AuthStateCache entities are found.
func (*AuthStateCacheQuery) OnlyID ¶
func (ascq *AuthStateCacheQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID is like Only, but returns the only AuthStateCache ID in the query. Returns a *NotSingularError when exactly one AuthStateCache ID is not found. Returns a *NotFoundError when no entities are found.
func (*AuthStateCacheQuery) OnlyIDX ¶
func (ascq *AuthStateCacheQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*AuthStateCacheQuery) OnlyX ¶
func (ascq *AuthStateCacheQuery) OnlyX(ctx context.Context) *AuthStateCache
OnlyX is like Only, but panics if an error occurs.
func (*AuthStateCacheQuery) Order ¶
func (ascq *AuthStateCacheQuery) Order(o ...OrderFunc) *AuthStateCacheQuery
Order adds an order step to the query.
func (*AuthStateCacheQuery) Select ¶
func (ascq *AuthStateCacheQuery) Select(fields ...string) *AuthStateCacheSelect
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 { ExpiresAt int64 `json:"expires_at,omitempty"` } client.AuthStateCache.Query(). Select(authstatecache.FieldExpiresAt). Scan(ctx, &v)
func (*AuthStateCacheQuery) Unique ¶
func (ascq *AuthStateCacheQuery) Unique(unique bool) *AuthStateCacheQuery
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 (*AuthStateCacheQuery) Where ¶
func (ascq *AuthStateCacheQuery) Where(ps ...predicate.AuthStateCache) *AuthStateCacheQuery
Where adds a new predicate for the AuthStateCacheQuery builder.
type AuthStateCacheSelect ¶
type AuthStateCacheSelect struct { *AuthStateCacheQuery // contains filtered or unexported fields }
AuthStateCacheSelect is the builder for selecting fields of AuthStateCache entities.
func (*AuthStateCacheSelect) Bool ¶
func (ascs *AuthStateCacheSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) BoolX ¶
func (ascs *AuthStateCacheSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*AuthStateCacheSelect) Bools ¶
func (ascs *AuthStateCacheSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) BoolsX ¶
func (ascs *AuthStateCacheSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*AuthStateCacheSelect) Float64 ¶
func (ascs *AuthStateCacheSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) Float64X ¶
func (ascs *AuthStateCacheSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*AuthStateCacheSelect) Float64s ¶
func (ascs *AuthStateCacheSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) Float64sX ¶
func (ascs *AuthStateCacheSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*AuthStateCacheSelect) Int ¶
func (ascs *AuthStateCacheSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) IntX ¶
func (ascs *AuthStateCacheSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*AuthStateCacheSelect) Ints ¶
func (ascs *AuthStateCacheSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) IntsX ¶
func (ascs *AuthStateCacheSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*AuthStateCacheSelect) Scan ¶
func (ascs *AuthStateCacheSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*AuthStateCacheSelect) ScanX ¶
func (ascs *AuthStateCacheSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*AuthStateCacheSelect) String ¶
func (ascs *AuthStateCacheSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*AuthStateCacheSelect) StringX ¶
func (ascs *AuthStateCacheSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type AuthStateCacheUpdate ¶
type AuthStateCacheUpdate struct {
// contains filtered or unexported fields
}
AuthStateCacheUpdate is the builder for updating AuthStateCache entities.
func (*AuthStateCacheUpdate) AddExpiresAt ¶
func (ascu *AuthStateCacheUpdate) AddExpiresAt(i int64) *AuthStateCacheUpdate
AddExpiresAt adds i to the "expires_at" field.
func (*AuthStateCacheUpdate) Exec ¶
func (ascu *AuthStateCacheUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*AuthStateCacheUpdate) ExecX ¶
func (ascu *AuthStateCacheUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheUpdate) Mutation ¶
func (ascu *AuthStateCacheUpdate) Mutation() *AuthStateCacheMutation
Mutation returns the AuthStateCacheMutation object of the builder.
func (*AuthStateCacheUpdate) Save ¶
func (ascu *AuthStateCacheUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*AuthStateCacheUpdate) SaveX ¶
func (ascu *AuthStateCacheUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*AuthStateCacheUpdate) SetExpiresAt ¶
func (ascu *AuthStateCacheUpdate) SetExpiresAt(i int64) *AuthStateCacheUpdate
SetExpiresAt sets the "expires_at" field.
func (*AuthStateCacheUpdate) Where ¶
func (ascu *AuthStateCacheUpdate) Where(ps ...predicate.AuthStateCache) *AuthStateCacheUpdate
Where appends a list predicates to the AuthStateCacheUpdate builder.
type AuthStateCacheUpdateOne ¶
type AuthStateCacheUpdateOne struct {
// contains filtered or unexported fields
}
AuthStateCacheUpdateOne is the builder for updating a single AuthStateCache entity.
func (*AuthStateCacheUpdateOne) AddExpiresAt ¶
func (ascuo *AuthStateCacheUpdateOne) AddExpiresAt(i int64) *AuthStateCacheUpdateOne
AddExpiresAt adds i to the "expires_at" field.
func (*AuthStateCacheUpdateOne) Exec ¶
func (ascuo *AuthStateCacheUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*AuthStateCacheUpdateOne) ExecX ¶
func (ascuo *AuthStateCacheUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheUpdateOne) Mutation ¶
func (ascuo *AuthStateCacheUpdateOne) Mutation() *AuthStateCacheMutation
Mutation returns the AuthStateCacheMutation object of the builder.
func (*AuthStateCacheUpdateOne) Save ¶
func (ascuo *AuthStateCacheUpdateOne) Save(ctx context.Context) (*AuthStateCache, error)
Save executes the query and returns the updated AuthStateCache entity.
func (*AuthStateCacheUpdateOne) SaveX ¶
func (ascuo *AuthStateCacheUpdateOne) SaveX(ctx context.Context) *AuthStateCache
SaveX is like Save, but panics if an error occurs.
func (*AuthStateCacheUpdateOne) Select ¶
func (ascuo *AuthStateCacheUpdateOne) Select(field string, fields ...string) *AuthStateCacheUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*AuthStateCacheUpdateOne) SetExpiresAt ¶
func (ascuo *AuthStateCacheUpdateOne) SetExpiresAt(i int64) *AuthStateCacheUpdateOne
SetExpiresAt sets the "expires_at" field.
type AuthStateCacheUpsert ¶
AuthStateCacheUpsert is the "OnConflict" setter.
func (*AuthStateCacheUpsert) SetExpiresAt ¶
func (u *AuthStateCacheUpsert) SetExpiresAt(v int64) *AuthStateCacheUpsert
SetExpiresAt sets the "expires_at" field.
func (*AuthStateCacheUpsert) UpdateExpiresAt ¶
func (u *AuthStateCacheUpsert) UpdateExpiresAt() *AuthStateCacheUpsert
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
type AuthStateCacheUpsertBulk ¶
type AuthStateCacheUpsertBulk struct {
// contains filtered or unexported fields
}
AuthStateCacheUpsertBulk is the builder for "upsert"-ing a bulk of AuthStateCache nodes.
func (*AuthStateCacheUpsertBulk) DoNothing ¶
func (u *AuthStateCacheUpsertBulk) DoNothing() *AuthStateCacheUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*AuthStateCacheUpsertBulk) Exec ¶
func (u *AuthStateCacheUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*AuthStateCacheUpsertBulk) ExecX ¶
func (u *AuthStateCacheUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheUpsertBulk) Ignore ¶
func (u *AuthStateCacheUpsertBulk) Ignore() *AuthStateCacheUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.AuthStateCache.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*AuthStateCacheUpsertBulk) SetExpiresAt ¶
func (u *AuthStateCacheUpsertBulk) SetExpiresAt(v int64) *AuthStateCacheUpsertBulk
SetExpiresAt sets the "expires_at" field.
func (*AuthStateCacheUpsertBulk) Update ¶
func (u *AuthStateCacheUpsertBulk) Update(set func(*AuthStateCacheUpsert)) *AuthStateCacheUpsertBulk
Update allows overriding fields `UPDATE` values. See the AuthStateCacheCreateBulk.OnConflict documentation for more info.
func (*AuthStateCacheUpsertBulk) UpdateExpiresAt ¶
func (u *AuthStateCacheUpsertBulk) UpdateExpiresAt() *AuthStateCacheUpsertBulk
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*AuthStateCacheUpsertBulk) UpdateNewValues ¶
func (u *AuthStateCacheUpsertBulk) UpdateNewValues() *AuthStateCacheUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.AuthStateCache.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
type AuthStateCacheUpsertOne ¶
type AuthStateCacheUpsertOne struct {
// contains filtered or unexported fields
}
AuthStateCacheUpsertOne is the builder for "upsert"-ing
one AuthStateCache node.
func (*AuthStateCacheUpsertOne) DoNothing ¶
func (u *AuthStateCacheUpsertOne) DoNothing() *AuthStateCacheUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*AuthStateCacheUpsertOne) Exec ¶
func (u *AuthStateCacheUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*AuthStateCacheUpsertOne) ExecX ¶
func (u *AuthStateCacheUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*AuthStateCacheUpsertOne) ID ¶
func (u *AuthStateCacheUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*AuthStateCacheUpsertOne) IDX ¶
func (u *AuthStateCacheUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*AuthStateCacheUpsertOne) Ignore ¶
func (u *AuthStateCacheUpsertOne) Ignore() *AuthStateCacheUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.AuthStateCache.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*AuthStateCacheUpsertOne) SetExpiresAt ¶
func (u *AuthStateCacheUpsertOne) SetExpiresAt(v int64) *AuthStateCacheUpsertOne
SetExpiresAt sets the "expires_at" field.
func (*AuthStateCacheUpsertOne) Update ¶
func (u *AuthStateCacheUpsertOne) Update(set func(*AuthStateCacheUpsert)) *AuthStateCacheUpsertOne
Update allows overriding fields `UPDATE` values. See the AuthStateCacheCreate.OnConflict documentation for more info.
func (*AuthStateCacheUpsertOne) UpdateExpiresAt ¶
func (u *AuthStateCacheUpsertOne) UpdateExpiresAt() *AuthStateCacheUpsertOne
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*AuthStateCacheUpsertOne) UpdateNewValues ¶
func (u *AuthStateCacheUpsertOne) UpdateNewValues() *AuthStateCacheUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.AuthStateCache.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
type AuthStateCaches ¶
type AuthStateCaches []*AuthStateCache
AuthStateCaches is a parsable slice of AuthStateCache.
type Client ¶
type Client struct { // Schema is the client for creating, migrating and dropping schema. Schema *migrate.Schema // AuthStateCache is the client for interacting with the AuthStateCache builders. AuthStateCache *AuthStateCacheClient // PackageRecord is the client for interacting with the PackageRecord builders. PackageRecord *PackageRecordClient // Repository is the client for interacting with the Repository builders. Repository *RepositoryClient // Scan is the client for interacting with the Scan builders. Scan *ScanClient // Session is the client for interacting with the Session builders. Session *SessionClient // Severity is the client for interacting with the Severity builders. Severity *SeverityClient // User is the client for interacting with the User builders. User *UserClient // VulnStatus is the client for interacting with the VulnStatus builders. VulnStatus *VulnStatusClient // VulnStatusIndex is the client for interacting with the VulnStatusIndex builders. VulnStatusIndex *VulnStatusIndexClient // Vulnerability is the client for interacting with the Vulnerability builders. Vulnerability *VulnerabilityClient // 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(). AuthStateCache. Query(). Count(ctx)
type CommitFunc ¶
The CommitFunc type is an adapter to allow the use of ordinary function as a Committer. If f is a function with the appropriate signature, CommitFunc(f) is a Committer that calls f.
type CommitHook ¶
CommitHook defines the "commit middleware". A function that gets a Committer and returns a Committer. For example:
hook := func(next ent.Committer) ent.Committer { return ent.CommitFunc(func(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 MutateFunc ¶
type MutateFunc = ent.MutateFunc
ent aliases to avoid import conflicts in user's code.
type NotFoundError ¶
type NotFoundError struct {
// contains filtered or unexported fields
}
NotFoundError returns when trying to fetch a specific entity and it was not found in the database.
func (*NotFoundError) Error ¶
func (e *NotFoundError) Error() string
Error implements the error interface.
type NotLoadedError ¶
type NotLoadedError struct {
// contains filtered or unexported fields
}
NotLoadedError returns when trying to get a node that was not loaded by the query.
func (*NotLoadedError) Error ¶
func (e *NotLoadedError) Error() string
Error implements the error interface.
type NotSingularError ¶
type NotSingularError struct {
// contains filtered or unexported fields
}
NotSingularError returns when trying to fetch a singular entity and more then one was found in the database.
func (*NotSingularError) Error ¶
func (e *NotSingularError) Error() string
Error implements the error interface.
type PackageRecord ¶
type PackageRecord struct { // ID of the ent. ID int `json:"id,omitempty"` // Type holds the value of the "type" field. Type string `json:"type,omitempty"` // Source holds the value of the "source" field. Source string `json:"source,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"` // VulnIds holds the value of the "vuln_ids" field. VulnIds []string `json:"vuln_ids,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the PackageRecordQuery when eager-loading is set. Edges PackageRecordEdges `json:"edges"` // contains filtered or unexported fields }
PackageRecord is the model entity for the PackageRecord schema.
func (*PackageRecord) QueryScan ¶
func (pr *PackageRecord) QueryScan() *ScanQuery
QueryScan queries the "scan" edge of the PackageRecord entity.
func (*PackageRecord) QueryVulnerabilities ¶
func (pr *PackageRecord) QueryVulnerabilities() *VulnerabilityQuery
QueryVulnerabilities queries the "vulnerabilities" edge of the PackageRecord entity.
func (*PackageRecord) String ¶
func (pr *PackageRecord) String() string
String implements the fmt.Stringer.
func (*PackageRecord) Unwrap ¶
func (pr *PackageRecord) Unwrap() *PackageRecord
Unwrap unwraps the PackageRecord 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 (*PackageRecord) Update ¶
func (pr *PackageRecord) Update() *PackageRecordUpdateOne
Update returns a builder for updating this PackageRecord. Note that you need to call PackageRecord.Unwrap() before calling this method if this PackageRecord was returned from a transaction, and the transaction was committed or rolled back.
type PackageRecordClient ¶
type PackageRecordClient struct {
// contains filtered or unexported fields
}
PackageRecordClient is a client for the PackageRecord schema.
func NewPackageRecordClient ¶
func NewPackageRecordClient(c config) *PackageRecordClient
NewPackageRecordClient returns a client for the PackageRecord from the given config.
func (*PackageRecordClient) Create ¶
func (c *PackageRecordClient) Create() *PackageRecordCreate
Create returns a create builder for PackageRecord.
func (*PackageRecordClient) CreateBulk ¶
func (c *PackageRecordClient) CreateBulk(builders ...*PackageRecordCreate) *PackageRecordCreateBulk
CreateBulk returns a builder for creating a bulk of PackageRecord entities.
func (*PackageRecordClient) Delete ¶
func (c *PackageRecordClient) Delete() *PackageRecordDelete
Delete returns a delete builder for PackageRecord.
func (*PackageRecordClient) DeleteOne ¶
func (c *PackageRecordClient) DeleteOne(pr *PackageRecord) *PackageRecordDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*PackageRecordClient) DeleteOneID ¶
func (c *PackageRecordClient) DeleteOneID(id int) *PackageRecordDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*PackageRecordClient) Get ¶
func (c *PackageRecordClient) Get(ctx context.Context, id int) (*PackageRecord, error)
Get returns a PackageRecord entity by its id.
func (*PackageRecordClient) GetX ¶
func (c *PackageRecordClient) GetX(ctx context.Context, id int) *PackageRecord
GetX is like Get, but panics if an error occurs.
func (*PackageRecordClient) Hooks ¶
func (c *PackageRecordClient) Hooks() []Hook
Hooks returns the client hooks.
func (*PackageRecordClient) Query ¶
func (c *PackageRecordClient) Query() *PackageRecordQuery
Query returns a query builder for PackageRecord.
func (*PackageRecordClient) QueryScan ¶
func (c *PackageRecordClient) QueryScan(pr *PackageRecord) *ScanQuery
QueryScan queries the scan edge of a PackageRecord.
func (*PackageRecordClient) QueryVulnerabilities ¶
func (c *PackageRecordClient) QueryVulnerabilities(pr *PackageRecord) *VulnerabilityQuery
QueryVulnerabilities queries the vulnerabilities edge of a PackageRecord.
func (*PackageRecordClient) Update ¶
func (c *PackageRecordClient) Update() *PackageRecordUpdate
Update returns an update builder for PackageRecord.
func (*PackageRecordClient) UpdateOne ¶
func (c *PackageRecordClient) UpdateOne(pr *PackageRecord) *PackageRecordUpdateOne
UpdateOne returns an update builder for the given entity.
func (*PackageRecordClient) UpdateOneID ¶
func (c *PackageRecordClient) UpdateOneID(id int) *PackageRecordUpdateOne
UpdateOneID returns an update builder for the given id.
func (*PackageRecordClient) Use ¶
func (c *PackageRecordClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `packagerecord.Hooks(f(g(h())))`.
type PackageRecordCreate ¶
type PackageRecordCreate struct {
// contains filtered or unexported fields
}
PackageRecordCreate is the builder for creating a PackageRecord entity.
func (*PackageRecordCreate) AddScan ¶
func (prc *PackageRecordCreate) AddScan(s ...*Scan) *PackageRecordCreate
AddScan adds the "scan" edges to the Scan entity.
func (*PackageRecordCreate) AddScanIDs ¶
func (prc *PackageRecordCreate) AddScanIDs(ids ...string) *PackageRecordCreate
AddScanIDs adds the "scan" edge to the Scan entity by IDs.
func (*PackageRecordCreate) AddVulnerabilities ¶
func (prc *PackageRecordCreate) AddVulnerabilities(v ...*Vulnerability) *PackageRecordCreate
AddVulnerabilities adds the "vulnerabilities" edges to the Vulnerability entity.
func (*PackageRecordCreate) AddVulnerabilityIDs ¶
func (prc *PackageRecordCreate) AddVulnerabilityIDs(ids ...string) *PackageRecordCreate
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*PackageRecordCreate) Exec ¶
func (prc *PackageRecordCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*PackageRecordCreate) ExecX ¶
func (prc *PackageRecordCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordCreate) Mutation ¶
func (prc *PackageRecordCreate) Mutation() *PackageRecordMutation
Mutation returns the PackageRecordMutation object of the builder.
func (*PackageRecordCreate) OnConflict ¶
func (prc *PackageRecordCreate) OnConflict(opts ...sql.ConflictOption) *PackageRecordUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.PackageRecord.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.PackageRecordUpsert) { SetType(v+v). }). Exec(ctx)
func (*PackageRecordCreate) OnConflictColumns ¶
func (prc *PackageRecordCreate) OnConflictColumns(columns ...string) *PackageRecordUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.PackageRecord.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*PackageRecordCreate) Save ¶
func (prc *PackageRecordCreate) Save(ctx context.Context) (*PackageRecord, error)
Save creates the PackageRecord in the database.
func (*PackageRecordCreate) SaveX ¶
func (prc *PackageRecordCreate) SaveX(ctx context.Context) *PackageRecord
SaveX calls Save and panics if Save returns an error.
func (*PackageRecordCreate) SetName ¶
func (prc *PackageRecordCreate) SetName(s string) *PackageRecordCreate
SetName sets the "name" field.
func (*PackageRecordCreate) SetSource ¶
func (prc *PackageRecordCreate) SetSource(s string) *PackageRecordCreate
SetSource sets the "source" field.
func (*PackageRecordCreate) SetType ¶
func (prc *PackageRecordCreate) SetType(s string) *PackageRecordCreate
SetType sets the "type" field.
func (*PackageRecordCreate) SetVersion ¶
func (prc *PackageRecordCreate) SetVersion(s string) *PackageRecordCreate
SetVersion sets the "version" field.
func (*PackageRecordCreate) SetVulnIds ¶
func (prc *PackageRecordCreate) SetVulnIds(s []string) *PackageRecordCreate
SetVulnIds sets the "vuln_ids" field.
type PackageRecordCreateBulk ¶
type PackageRecordCreateBulk struct {
// contains filtered or unexported fields
}
PackageRecordCreateBulk is the builder for creating many PackageRecord entities in bulk.
func (*PackageRecordCreateBulk) Exec ¶
func (prcb *PackageRecordCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*PackageRecordCreateBulk) ExecX ¶
func (prcb *PackageRecordCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordCreateBulk) OnConflict ¶
func (prcb *PackageRecordCreateBulk) OnConflict(opts ...sql.ConflictOption) *PackageRecordUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.PackageRecord.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.PackageRecordUpsert) { SetType(v+v). }). Exec(ctx)
func (*PackageRecordCreateBulk) OnConflictColumns ¶
func (prcb *PackageRecordCreateBulk) OnConflictColumns(columns ...string) *PackageRecordUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.PackageRecord.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*PackageRecordCreateBulk) Save ¶
func (prcb *PackageRecordCreateBulk) Save(ctx context.Context) ([]*PackageRecord, error)
Save creates the PackageRecord entities in the database.
func (*PackageRecordCreateBulk) SaveX ¶
func (prcb *PackageRecordCreateBulk) SaveX(ctx context.Context) []*PackageRecord
SaveX is like Save, but panics if an error occurs.
type PackageRecordDelete ¶
type PackageRecordDelete struct {
// contains filtered or unexported fields
}
PackageRecordDelete is the builder for deleting a PackageRecord entity.
func (*PackageRecordDelete) Exec ¶
func (prd *PackageRecordDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*PackageRecordDelete) ExecX ¶
func (prd *PackageRecordDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordDelete) Where ¶
func (prd *PackageRecordDelete) Where(ps ...predicate.PackageRecord) *PackageRecordDelete
Where appends a list predicates to the PackageRecordDelete builder.
type PackageRecordDeleteOne ¶
type PackageRecordDeleteOne struct {
// contains filtered or unexported fields
}
PackageRecordDeleteOne is the builder for deleting a single PackageRecord entity.
func (*PackageRecordDeleteOne) Exec ¶
func (prdo *PackageRecordDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*PackageRecordDeleteOne) ExecX ¶
func (prdo *PackageRecordDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type PackageRecordEdges ¶
type PackageRecordEdges struct { // Scan holds the value of the scan edge. Scan []*Scan `json:"scan,omitempty"` // Vulnerabilities holds the value of the vulnerabilities edge. Vulnerabilities []*Vulnerability `json:"vulnerabilities,omitempty"` // contains filtered or unexported fields }
PackageRecordEdges holds the relations/edges for other nodes in the graph.
func (PackageRecordEdges) ScanOrErr ¶
func (e PackageRecordEdges) ScanOrErr() ([]*Scan, error)
ScanOrErr returns the Scan value or an error if the edge was not loaded in eager-loading.
func (PackageRecordEdges) VulnerabilitiesOrErr ¶
func (e PackageRecordEdges) VulnerabilitiesOrErr() ([]*Vulnerability, error)
VulnerabilitiesOrErr returns the Vulnerabilities value or an error if the edge was not loaded in eager-loading.
type PackageRecordGroupBy ¶
type PackageRecordGroupBy struct {
// contains filtered or unexported fields
}
PackageRecordGroupBy is the group-by builder for PackageRecord entities.
func (*PackageRecordGroupBy) Aggregate ¶
func (prgb *PackageRecordGroupBy) Aggregate(fns ...AggregateFunc) *PackageRecordGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*PackageRecordGroupBy) Bool ¶
func (prgb *PackageRecordGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) BoolX ¶
func (prgb *PackageRecordGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*PackageRecordGroupBy) Bools ¶
func (prgb *PackageRecordGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) BoolsX ¶
func (prgb *PackageRecordGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*PackageRecordGroupBy) Float64 ¶
func (prgb *PackageRecordGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) Float64X ¶
func (prgb *PackageRecordGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*PackageRecordGroupBy) Float64s ¶
func (prgb *PackageRecordGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) Float64sX ¶
func (prgb *PackageRecordGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*PackageRecordGroupBy) Int ¶
func (prgb *PackageRecordGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) IntX ¶
func (prgb *PackageRecordGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*PackageRecordGroupBy) Ints ¶
func (prgb *PackageRecordGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) IntsX ¶
func (prgb *PackageRecordGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*PackageRecordGroupBy) Scan ¶
func (prgb *PackageRecordGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*PackageRecordGroupBy) ScanX ¶
func (prgb *PackageRecordGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*PackageRecordGroupBy) String ¶
func (prgb *PackageRecordGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*PackageRecordGroupBy) StringX ¶
func (prgb *PackageRecordGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type PackageRecordMutation ¶
type PackageRecordMutation struct {
// contains filtered or unexported fields
}
PackageRecordMutation represents an operation that mutates the PackageRecord nodes in the graph.
func (*PackageRecordMutation) AddField ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) AddScanIDs ¶
func (m *PackageRecordMutation) AddScanIDs(ids ...string)
AddScanIDs adds the "scan" edge to the Scan entity by ids.
func (*PackageRecordMutation) AddVulnerabilityIDs ¶
func (m *PackageRecordMutation) AddVulnerabilityIDs(ids ...string)
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by ids.
func (*PackageRecordMutation) AddedEdges ¶
func (m *PackageRecordMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*PackageRecordMutation) AddedField ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) AddedFields ¶
func (m *PackageRecordMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*PackageRecordMutation) AddedIDs ¶
func (m *PackageRecordMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*PackageRecordMutation) ClearEdge ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) ClearField ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) ClearScan ¶
func (m *PackageRecordMutation) ClearScan()
ClearScan clears the "scan" edge to the Scan entity.
func (*PackageRecordMutation) ClearVulnerabilities ¶
func (m *PackageRecordMutation) ClearVulnerabilities()
ClearVulnerabilities clears the "vulnerabilities" edge to the Vulnerability entity.
func (*PackageRecordMutation) ClearedEdges ¶
func (m *PackageRecordMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*PackageRecordMutation) ClearedFields ¶
func (m *PackageRecordMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (PackageRecordMutation) Client ¶
func (m PackageRecordMutation) 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 (*PackageRecordMutation) EdgeCleared ¶
func (m *PackageRecordMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*PackageRecordMutation) Field ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) FieldCleared ¶
func (m *PackageRecordMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*PackageRecordMutation) Fields ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) GetType ¶
func (m *PackageRecordMutation) GetType() (r string, exists bool)
GetType returns the value of the "type" field in the mutation.
func (*PackageRecordMutation) ID ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) Name ¶
func (m *PackageRecordMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*PackageRecordMutation) 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 (*PackageRecordMutation) OldName ¶
func (m *PackageRecordMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the PackageRecord entity. If the PackageRecord 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 (*PackageRecordMutation) OldSource ¶
func (m *PackageRecordMutation) OldSource(ctx context.Context) (v string, err error)
OldSource returns the old "source" field's value of the PackageRecord entity. If the PackageRecord 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 (*PackageRecordMutation) OldType ¶
func (m *PackageRecordMutation) OldType(ctx context.Context) (v string, err error)
OldType returns the old "type" field's value of the PackageRecord entity. If the PackageRecord 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 (*PackageRecordMutation) OldVersion ¶
func (m *PackageRecordMutation) OldVersion(ctx context.Context) (v string, err error)
OldVersion returns the old "version" field's value of the PackageRecord entity. If the PackageRecord 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 (*PackageRecordMutation) OldVulnIds ¶
func (m *PackageRecordMutation) OldVulnIds(ctx context.Context) (v []string, err error)
OldVulnIds returns the old "vuln_ids" field's value of the PackageRecord entity. If the PackageRecord 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 (*PackageRecordMutation) Op ¶
func (m *PackageRecordMutation) Op() Op
Op returns the operation name.
func (*PackageRecordMutation) RemoveScanIDs ¶
func (m *PackageRecordMutation) RemoveScanIDs(ids ...string)
RemoveScanIDs removes the "scan" edge to the Scan entity by IDs.
func (*PackageRecordMutation) RemoveVulnerabilityIDs ¶
func (m *PackageRecordMutation) RemoveVulnerabilityIDs(ids ...string)
RemoveVulnerabilityIDs removes the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*PackageRecordMutation) RemovedEdges ¶
func (m *PackageRecordMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*PackageRecordMutation) RemovedIDs ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) RemovedScanIDs ¶
func (m *PackageRecordMutation) RemovedScanIDs() (ids []string)
RemovedScan returns the removed IDs of the "scan" edge to the Scan entity.
func (*PackageRecordMutation) RemovedVulnerabilitiesIDs ¶
func (m *PackageRecordMutation) RemovedVulnerabilitiesIDs() (ids []string)
RemovedVulnerabilities returns the removed IDs of the "vulnerabilities" edge to the Vulnerability entity.
func (*PackageRecordMutation) ResetEdge ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) ResetField ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) ResetName ¶
func (m *PackageRecordMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*PackageRecordMutation) ResetScan ¶
func (m *PackageRecordMutation) ResetScan()
ResetScan resets all changes to the "scan" edge.
func (*PackageRecordMutation) ResetSource ¶
func (m *PackageRecordMutation) ResetSource()
ResetSource resets all changes to the "source" field.
func (*PackageRecordMutation) ResetType ¶
func (m *PackageRecordMutation) ResetType()
ResetType resets all changes to the "type" field.
func (*PackageRecordMutation) ResetVersion ¶
func (m *PackageRecordMutation) ResetVersion()
ResetVersion resets all changes to the "version" field.
func (*PackageRecordMutation) ResetVulnIds ¶
func (m *PackageRecordMutation) ResetVulnIds()
ResetVulnIds resets all changes to the "vuln_ids" field.
func (*PackageRecordMutation) ResetVulnerabilities ¶
func (m *PackageRecordMutation) ResetVulnerabilities()
ResetVulnerabilities resets all changes to the "vulnerabilities" edge.
func (*PackageRecordMutation) ScanCleared ¶
func (m *PackageRecordMutation) ScanCleared() bool
ScanCleared reports if the "scan" edge to the Scan entity was cleared.
func (*PackageRecordMutation) ScanIDs ¶
func (m *PackageRecordMutation) ScanIDs() (ids []string)
ScanIDs returns the "scan" edge IDs in the mutation.
func (*PackageRecordMutation) SetField ¶
func (m *PackageRecordMutation) 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 (*PackageRecordMutation) SetName ¶
func (m *PackageRecordMutation) SetName(s string)
SetName sets the "name" field.
func (*PackageRecordMutation) SetSource ¶
func (m *PackageRecordMutation) SetSource(s string)
SetSource sets the "source" field.
func (*PackageRecordMutation) SetType ¶
func (m *PackageRecordMutation) SetType(s string)
SetType sets the "type" field.
func (*PackageRecordMutation) SetVersion ¶
func (m *PackageRecordMutation) SetVersion(s string)
SetVersion sets the "version" field.
func (*PackageRecordMutation) SetVulnIds ¶
func (m *PackageRecordMutation) SetVulnIds(s []string)
SetVulnIds sets the "vuln_ids" field.
func (*PackageRecordMutation) Source ¶
func (m *PackageRecordMutation) Source() (r string, exists bool)
Source returns the value of the "source" field in the mutation.
func (PackageRecordMutation) Tx ¶
func (m PackageRecordMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*PackageRecordMutation) Type ¶
func (m *PackageRecordMutation) Type() string
Type returns the node type of this mutation (PackageRecord).
func (*PackageRecordMutation) Version ¶
func (m *PackageRecordMutation) Version() (r string, exists bool)
Version returns the value of the "version" field in the mutation.
func (*PackageRecordMutation) VulnIds ¶
func (m *PackageRecordMutation) VulnIds() (r []string, exists bool)
VulnIds returns the value of the "vuln_ids" field in the mutation.
func (*PackageRecordMutation) VulnerabilitiesCleared ¶
func (m *PackageRecordMutation) VulnerabilitiesCleared() bool
VulnerabilitiesCleared reports if the "vulnerabilities" edge to the Vulnerability entity was cleared.
func (*PackageRecordMutation) VulnerabilitiesIDs ¶
func (m *PackageRecordMutation) VulnerabilitiesIDs() (ids []string)
VulnerabilitiesIDs returns the "vulnerabilities" edge IDs in the mutation.
func (*PackageRecordMutation) Where ¶
func (m *PackageRecordMutation) Where(ps ...predicate.PackageRecord)
Where appends a list predicates to the PackageRecordMutation builder.
type PackageRecordQuery ¶
type PackageRecordQuery struct {
// contains filtered or unexported fields
}
PackageRecordQuery is the builder for querying PackageRecord entities.
func (*PackageRecordQuery) All ¶
func (prq *PackageRecordQuery) All(ctx context.Context) ([]*PackageRecord, error)
All executes the query and returns a list of PackageRecords.
func (*PackageRecordQuery) AllX ¶
func (prq *PackageRecordQuery) AllX(ctx context.Context) []*PackageRecord
AllX is like All, but panics if an error occurs.
func (*PackageRecordQuery) Clone ¶
func (prq *PackageRecordQuery) Clone() *PackageRecordQuery
Clone returns a duplicate of the PackageRecordQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*PackageRecordQuery) Count ¶
func (prq *PackageRecordQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*PackageRecordQuery) CountX ¶
func (prq *PackageRecordQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*PackageRecordQuery) Exist ¶
func (prq *PackageRecordQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*PackageRecordQuery) ExistX ¶
func (prq *PackageRecordQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*PackageRecordQuery) First ¶
func (prq *PackageRecordQuery) First(ctx context.Context) (*PackageRecord, error)
First returns the first PackageRecord entity from the query. Returns a *NotFoundError when no PackageRecord was found.
func (*PackageRecordQuery) FirstID ¶
func (prq *PackageRecordQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first PackageRecord ID from the query. Returns a *NotFoundError when no PackageRecord ID was found.
func (*PackageRecordQuery) FirstIDX ¶
func (prq *PackageRecordQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*PackageRecordQuery) FirstX ¶
func (prq *PackageRecordQuery) FirstX(ctx context.Context) *PackageRecord
FirstX is like First, but panics if an error occurs.
func (*PackageRecordQuery) GroupBy ¶
func (prq *PackageRecordQuery) GroupBy(field string, fields ...string) *PackageRecordGroupBy
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 string `json:"type,omitempty"` Count int `json:"count,omitempty"` } client.PackageRecord.Query(). GroupBy(packagerecord.FieldType). Aggregate(ent.Count()). Scan(ctx, &v)
func (*PackageRecordQuery) IDs ¶
func (prq *PackageRecordQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of PackageRecord IDs.
func (*PackageRecordQuery) IDsX ¶
func (prq *PackageRecordQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*PackageRecordQuery) Limit ¶
func (prq *PackageRecordQuery) Limit(limit int) *PackageRecordQuery
Limit adds a limit step to the query.
func (*PackageRecordQuery) Offset ¶
func (prq *PackageRecordQuery) Offset(offset int) *PackageRecordQuery
Offset adds an offset step to the query.
func (*PackageRecordQuery) Only ¶
func (prq *PackageRecordQuery) Only(ctx context.Context) (*PackageRecord, error)
Only returns a single PackageRecord entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one PackageRecord entity is not found. Returns a *NotFoundError when no PackageRecord entities are found.
func (*PackageRecordQuery) OnlyID ¶
func (prq *PackageRecordQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only PackageRecord ID in the query. Returns a *NotSingularError when exactly one PackageRecord ID is not found. Returns a *NotFoundError when no entities are found.
func (*PackageRecordQuery) OnlyIDX ¶
func (prq *PackageRecordQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*PackageRecordQuery) OnlyX ¶
func (prq *PackageRecordQuery) OnlyX(ctx context.Context) *PackageRecord
OnlyX is like Only, but panics if an error occurs.
func (*PackageRecordQuery) Order ¶
func (prq *PackageRecordQuery) Order(o ...OrderFunc) *PackageRecordQuery
Order adds an order step to the query.
func (*PackageRecordQuery) QueryScan ¶
func (prq *PackageRecordQuery) QueryScan() *ScanQuery
QueryScan chains the current query on the "scan" edge.
func (*PackageRecordQuery) QueryVulnerabilities ¶
func (prq *PackageRecordQuery) QueryVulnerabilities() *VulnerabilityQuery
QueryVulnerabilities chains the current query on the "vulnerabilities" edge.
func (*PackageRecordQuery) Select ¶
func (prq *PackageRecordQuery) Select(fields ...string) *PackageRecordSelect
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 string `json:"type,omitempty"` } client.PackageRecord.Query(). Select(packagerecord.FieldType). Scan(ctx, &v)
func (*PackageRecordQuery) Unique ¶
func (prq *PackageRecordQuery) Unique(unique bool) *PackageRecordQuery
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 (*PackageRecordQuery) Where ¶
func (prq *PackageRecordQuery) Where(ps ...predicate.PackageRecord) *PackageRecordQuery
Where adds a new predicate for the PackageRecordQuery builder.
func (*PackageRecordQuery) WithScan ¶
func (prq *PackageRecordQuery) WithScan(opts ...func(*ScanQuery)) *PackageRecordQuery
WithScan tells the query-builder to eager-load the nodes that are connected to the "scan" edge. The optional arguments are used to configure the query builder of the edge.
func (*PackageRecordQuery) WithVulnerabilities ¶
func (prq *PackageRecordQuery) WithVulnerabilities(opts ...func(*VulnerabilityQuery)) *PackageRecordQuery
WithVulnerabilities tells the query-builder to eager-load the nodes that are connected to the "vulnerabilities" edge. The optional arguments are used to configure the query builder of the edge.
type PackageRecordSelect ¶
type PackageRecordSelect struct { *PackageRecordQuery // contains filtered or unexported fields }
PackageRecordSelect is the builder for selecting fields of PackageRecord entities.
func (*PackageRecordSelect) Bool ¶
func (prs *PackageRecordSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) BoolX ¶
func (prs *PackageRecordSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*PackageRecordSelect) Bools ¶
func (prs *PackageRecordSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) BoolsX ¶
func (prs *PackageRecordSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*PackageRecordSelect) Float64 ¶
func (prs *PackageRecordSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) Float64X ¶
func (prs *PackageRecordSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*PackageRecordSelect) Float64s ¶
func (prs *PackageRecordSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) Float64sX ¶
func (prs *PackageRecordSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*PackageRecordSelect) Int ¶
func (prs *PackageRecordSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) IntX ¶
func (prs *PackageRecordSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*PackageRecordSelect) Ints ¶
func (prs *PackageRecordSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) IntsX ¶
func (prs *PackageRecordSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*PackageRecordSelect) Scan ¶
func (prs *PackageRecordSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*PackageRecordSelect) ScanX ¶
func (prs *PackageRecordSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*PackageRecordSelect) String ¶
func (prs *PackageRecordSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*PackageRecordSelect) StringX ¶
func (prs *PackageRecordSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type PackageRecordUpdate ¶
type PackageRecordUpdate struct {
// contains filtered or unexported fields
}
PackageRecordUpdate is the builder for updating PackageRecord entities.
func (*PackageRecordUpdate) AddScan ¶
func (pru *PackageRecordUpdate) AddScan(s ...*Scan) *PackageRecordUpdate
AddScan adds the "scan" edges to the Scan entity.
func (*PackageRecordUpdate) AddScanIDs ¶
func (pru *PackageRecordUpdate) AddScanIDs(ids ...string) *PackageRecordUpdate
AddScanIDs adds the "scan" edge to the Scan entity by IDs.
func (*PackageRecordUpdate) AddVulnerabilities ¶
func (pru *PackageRecordUpdate) AddVulnerabilities(v ...*Vulnerability) *PackageRecordUpdate
AddVulnerabilities adds the "vulnerabilities" edges to the Vulnerability entity.
func (*PackageRecordUpdate) AddVulnerabilityIDs ¶
func (pru *PackageRecordUpdate) AddVulnerabilityIDs(ids ...string) *PackageRecordUpdate
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*PackageRecordUpdate) ClearScan ¶
func (pru *PackageRecordUpdate) ClearScan() *PackageRecordUpdate
ClearScan clears all "scan" edges to the Scan entity.
func (*PackageRecordUpdate) ClearVulnerabilities ¶
func (pru *PackageRecordUpdate) ClearVulnerabilities() *PackageRecordUpdate
ClearVulnerabilities clears all "vulnerabilities" edges to the Vulnerability entity.
func (*PackageRecordUpdate) Exec ¶
func (pru *PackageRecordUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*PackageRecordUpdate) ExecX ¶
func (pru *PackageRecordUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordUpdate) Mutation ¶
func (pru *PackageRecordUpdate) Mutation() *PackageRecordMutation
Mutation returns the PackageRecordMutation object of the builder.
func (*PackageRecordUpdate) RemoveScan ¶
func (pru *PackageRecordUpdate) RemoveScan(s ...*Scan) *PackageRecordUpdate
RemoveScan removes "scan" edges to Scan entities.
func (*PackageRecordUpdate) RemoveScanIDs ¶
func (pru *PackageRecordUpdate) RemoveScanIDs(ids ...string) *PackageRecordUpdate
RemoveScanIDs removes the "scan" edge to Scan entities by IDs.
func (*PackageRecordUpdate) RemoveVulnerabilities ¶
func (pru *PackageRecordUpdate) RemoveVulnerabilities(v ...*Vulnerability) *PackageRecordUpdate
RemoveVulnerabilities removes "vulnerabilities" edges to Vulnerability entities.
func (*PackageRecordUpdate) RemoveVulnerabilityIDs ¶
func (pru *PackageRecordUpdate) RemoveVulnerabilityIDs(ids ...string) *PackageRecordUpdate
RemoveVulnerabilityIDs removes the "vulnerabilities" edge to Vulnerability entities by IDs.
func (*PackageRecordUpdate) Save ¶
func (pru *PackageRecordUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*PackageRecordUpdate) SaveX ¶
func (pru *PackageRecordUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*PackageRecordUpdate) SetVulnIds ¶
func (pru *PackageRecordUpdate) SetVulnIds(s []string) *PackageRecordUpdate
SetVulnIds sets the "vuln_ids" field.
func (*PackageRecordUpdate) Where ¶
func (pru *PackageRecordUpdate) Where(ps ...predicate.PackageRecord) *PackageRecordUpdate
Where appends a list predicates to the PackageRecordUpdate builder.
type PackageRecordUpdateOne ¶
type PackageRecordUpdateOne struct {
// contains filtered or unexported fields
}
PackageRecordUpdateOne is the builder for updating a single PackageRecord entity.
func (*PackageRecordUpdateOne) AddScan ¶
func (pruo *PackageRecordUpdateOne) AddScan(s ...*Scan) *PackageRecordUpdateOne
AddScan adds the "scan" edges to the Scan entity.
func (*PackageRecordUpdateOne) AddScanIDs ¶
func (pruo *PackageRecordUpdateOne) AddScanIDs(ids ...string) *PackageRecordUpdateOne
AddScanIDs adds the "scan" edge to the Scan entity by IDs.
func (*PackageRecordUpdateOne) AddVulnerabilities ¶
func (pruo *PackageRecordUpdateOne) AddVulnerabilities(v ...*Vulnerability) *PackageRecordUpdateOne
AddVulnerabilities adds the "vulnerabilities" edges to the Vulnerability entity.
func (*PackageRecordUpdateOne) AddVulnerabilityIDs ¶
func (pruo *PackageRecordUpdateOne) AddVulnerabilityIDs(ids ...string) *PackageRecordUpdateOne
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*PackageRecordUpdateOne) ClearScan ¶
func (pruo *PackageRecordUpdateOne) ClearScan() *PackageRecordUpdateOne
ClearScan clears all "scan" edges to the Scan entity.
func (*PackageRecordUpdateOne) ClearVulnerabilities ¶
func (pruo *PackageRecordUpdateOne) ClearVulnerabilities() *PackageRecordUpdateOne
ClearVulnerabilities clears all "vulnerabilities" edges to the Vulnerability entity.
func (*PackageRecordUpdateOne) Exec ¶
func (pruo *PackageRecordUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*PackageRecordUpdateOne) ExecX ¶
func (pruo *PackageRecordUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordUpdateOne) Mutation ¶
func (pruo *PackageRecordUpdateOne) Mutation() *PackageRecordMutation
Mutation returns the PackageRecordMutation object of the builder.
func (*PackageRecordUpdateOne) RemoveScan ¶
func (pruo *PackageRecordUpdateOne) RemoveScan(s ...*Scan) *PackageRecordUpdateOne
RemoveScan removes "scan" edges to Scan entities.
func (*PackageRecordUpdateOne) RemoveScanIDs ¶
func (pruo *PackageRecordUpdateOne) RemoveScanIDs(ids ...string) *PackageRecordUpdateOne
RemoveScanIDs removes the "scan" edge to Scan entities by IDs.
func (*PackageRecordUpdateOne) RemoveVulnerabilities ¶
func (pruo *PackageRecordUpdateOne) RemoveVulnerabilities(v ...*Vulnerability) *PackageRecordUpdateOne
RemoveVulnerabilities removes "vulnerabilities" edges to Vulnerability entities.
func (*PackageRecordUpdateOne) RemoveVulnerabilityIDs ¶
func (pruo *PackageRecordUpdateOne) RemoveVulnerabilityIDs(ids ...string) *PackageRecordUpdateOne
RemoveVulnerabilityIDs removes the "vulnerabilities" edge to Vulnerability entities by IDs.
func (*PackageRecordUpdateOne) Save ¶
func (pruo *PackageRecordUpdateOne) Save(ctx context.Context) (*PackageRecord, error)
Save executes the query and returns the updated PackageRecord entity.
func (*PackageRecordUpdateOne) SaveX ¶
func (pruo *PackageRecordUpdateOne) SaveX(ctx context.Context) *PackageRecord
SaveX is like Save, but panics if an error occurs.
func (*PackageRecordUpdateOne) Select ¶
func (pruo *PackageRecordUpdateOne) Select(field string, fields ...string) *PackageRecordUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*PackageRecordUpdateOne) SetVulnIds ¶
func (pruo *PackageRecordUpdateOne) SetVulnIds(s []string) *PackageRecordUpdateOne
SetVulnIds sets the "vuln_ids" field.
type PackageRecordUpsert ¶
PackageRecordUpsert is the "OnConflict" setter.
func (*PackageRecordUpsert) SetName ¶
func (u *PackageRecordUpsert) SetName(v string) *PackageRecordUpsert
SetName sets the "name" field.
func (*PackageRecordUpsert) SetSource ¶
func (u *PackageRecordUpsert) SetSource(v string) *PackageRecordUpsert
SetSource sets the "source" field.
func (*PackageRecordUpsert) SetType ¶
func (u *PackageRecordUpsert) SetType(v string) *PackageRecordUpsert
SetType sets the "type" field.
func (*PackageRecordUpsert) SetVersion ¶
func (u *PackageRecordUpsert) SetVersion(v string) *PackageRecordUpsert
SetVersion sets the "version" field.
func (*PackageRecordUpsert) SetVulnIds ¶
func (u *PackageRecordUpsert) SetVulnIds(v []string) *PackageRecordUpsert
SetVulnIds sets the "vuln_ids" field.
func (*PackageRecordUpsert) UpdateName ¶
func (u *PackageRecordUpsert) UpdateName() *PackageRecordUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*PackageRecordUpsert) UpdateSource ¶
func (u *PackageRecordUpsert) UpdateSource() *PackageRecordUpsert
UpdateSource sets the "source" field to the value that was provided on create.
func (*PackageRecordUpsert) UpdateType ¶
func (u *PackageRecordUpsert) UpdateType() *PackageRecordUpsert
UpdateType sets the "type" field to the value that was provided on create.
func (*PackageRecordUpsert) UpdateVersion ¶
func (u *PackageRecordUpsert) UpdateVersion() *PackageRecordUpsert
UpdateVersion sets the "version" field to the value that was provided on create.
func (*PackageRecordUpsert) UpdateVulnIds ¶
func (u *PackageRecordUpsert) UpdateVulnIds() *PackageRecordUpsert
UpdateVulnIds sets the "vuln_ids" field to the value that was provided on create.
type PackageRecordUpsertBulk ¶
type PackageRecordUpsertBulk struct {
// contains filtered or unexported fields
}
PackageRecordUpsertBulk is the builder for "upsert"-ing a bulk of PackageRecord nodes.
func (*PackageRecordUpsertBulk) DoNothing ¶
func (u *PackageRecordUpsertBulk) DoNothing() *PackageRecordUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*PackageRecordUpsertBulk) Exec ¶
func (u *PackageRecordUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*PackageRecordUpsertBulk) ExecX ¶
func (u *PackageRecordUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordUpsertBulk) Ignore ¶
func (u *PackageRecordUpsertBulk) Ignore() *PackageRecordUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.PackageRecord.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*PackageRecordUpsertBulk) SetName ¶
func (u *PackageRecordUpsertBulk) SetName(v string) *PackageRecordUpsertBulk
SetName sets the "name" field.
func (*PackageRecordUpsertBulk) SetSource ¶
func (u *PackageRecordUpsertBulk) SetSource(v string) *PackageRecordUpsertBulk
SetSource sets the "source" field.
func (*PackageRecordUpsertBulk) SetType ¶
func (u *PackageRecordUpsertBulk) SetType(v string) *PackageRecordUpsertBulk
SetType sets the "type" field.
func (*PackageRecordUpsertBulk) SetVersion ¶
func (u *PackageRecordUpsertBulk) SetVersion(v string) *PackageRecordUpsertBulk
SetVersion sets the "version" field.
func (*PackageRecordUpsertBulk) SetVulnIds ¶
func (u *PackageRecordUpsertBulk) SetVulnIds(v []string) *PackageRecordUpsertBulk
SetVulnIds sets the "vuln_ids" field.
func (*PackageRecordUpsertBulk) Update ¶
func (u *PackageRecordUpsertBulk) Update(set func(*PackageRecordUpsert)) *PackageRecordUpsertBulk
Update allows overriding fields `UPDATE` values. See the PackageRecordCreateBulk.OnConflict documentation for more info.
func (*PackageRecordUpsertBulk) UpdateName ¶
func (u *PackageRecordUpsertBulk) UpdateName() *PackageRecordUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*PackageRecordUpsertBulk) UpdateNewValues ¶
func (u *PackageRecordUpsertBulk) UpdateNewValues() *PackageRecordUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.PackageRecord.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*PackageRecordUpsertBulk) UpdateSource ¶
func (u *PackageRecordUpsertBulk) UpdateSource() *PackageRecordUpsertBulk
UpdateSource sets the "source" field to the value that was provided on create.
func (*PackageRecordUpsertBulk) UpdateType ¶
func (u *PackageRecordUpsertBulk) UpdateType() *PackageRecordUpsertBulk
UpdateType sets the "type" field to the value that was provided on create.
func (*PackageRecordUpsertBulk) UpdateVersion ¶
func (u *PackageRecordUpsertBulk) UpdateVersion() *PackageRecordUpsertBulk
UpdateVersion sets the "version" field to the value that was provided on create.
func (*PackageRecordUpsertBulk) UpdateVulnIds ¶
func (u *PackageRecordUpsertBulk) UpdateVulnIds() *PackageRecordUpsertBulk
UpdateVulnIds sets the "vuln_ids" field to the value that was provided on create.
type PackageRecordUpsertOne ¶
type PackageRecordUpsertOne struct {
// contains filtered or unexported fields
}
PackageRecordUpsertOne is the builder for "upsert"-ing
one PackageRecord node.
func (*PackageRecordUpsertOne) DoNothing ¶
func (u *PackageRecordUpsertOne) DoNothing() *PackageRecordUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*PackageRecordUpsertOne) Exec ¶
func (u *PackageRecordUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*PackageRecordUpsertOne) ExecX ¶
func (u *PackageRecordUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*PackageRecordUpsertOne) ID ¶
func (u *PackageRecordUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*PackageRecordUpsertOne) IDX ¶
func (u *PackageRecordUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*PackageRecordUpsertOne) Ignore ¶
func (u *PackageRecordUpsertOne) Ignore() *PackageRecordUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.PackageRecord.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*PackageRecordUpsertOne) SetName ¶
func (u *PackageRecordUpsertOne) SetName(v string) *PackageRecordUpsertOne
SetName sets the "name" field.
func (*PackageRecordUpsertOne) SetSource ¶
func (u *PackageRecordUpsertOne) SetSource(v string) *PackageRecordUpsertOne
SetSource sets the "source" field.
func (*PackageRecordUpsertOne) SetType ¶
func (u *PackageRecordUpsertOne) SetType(v string) *PackageRecordUpsertOne
SetType sets the "type" field.
func (*PackageRecordUpsertOne) SetVersion ¶
func (u *PackageRecordUpsertOne) SetVersion(v string) *PackageRecordUpsertOne
SetVersion sets the "version" field.
func (*PackageRecordUpsertOne) SetVulnIds ¶
func (u *PackageRecordUpsertOne) SetVulnIds(v []string) *PackageRecordUpsertOne
SetVulnIds sets the "vuln_ids" field.
func (*PackageRecordUpsertOne) Update ¶
func (u *PackageRecordUpsertOne) Update(set func(*PackageRecordUpsert)) *PackageRecordUpsertOne
Update allows overriding fields `UPDATE` values. See the PackageRecordCreate.OnConflict documentation for more info.
func (*PackageRecordUpsertOne) UpdateName ¶
func (u *PackageRecordUpsertOne) UpdateName() *PackageRecordUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*PackageRecordUpsertOne) UpdateNewValues ¶
func (u *PackageRecordUpsertOne) UpdateNewValues() *PackageRecordUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.PackageRecord.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*PackageRecordUpsertOne) UpdateSource ¶
func (u *PackageRecordUpsertOne) UpdateSource() *PackageRecordUpsertOne
UpdateSource sets the "source" field to the value that was provided on create.
func (*PackageRecordUpsertOne) UpdateType ¶
func (u *PackageRecordUpsertOne) UpdateType() *PackageRecordUpsertOne
UpdateType sets the "type" field to the value that was provided on create.
func (*PackageRecordUpsertOne) UpdateVersion ¶
func (u *PackageRecordUpsertOne) UpdateVersion() *PackageRecordUpsertOne
UpdateVersion sets the "version" field to the value that was provided on create.
func (*PackageRecordUpsertOne) UpdateVulnIds ¶
func (u *PackageRecordUpsertOne) UpdateVulnIds() *PackageRecordUpsertOne
UpdateVulnIds sets the "vuln_ids" field to the value that was provided on create.
type PackageRecords ¶
type PackageRecords []*PackageRecord
PackageRecords is a parsable slice of PackageRecord.
type Repository ¶
type Repository struct { // ID of the ent. ID int `json:"id,omitempty"` // Owner holds the value of the "owner" field. Owner string `json:"owner,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // InstallID holds the value of the "install_id" field. InstallID int64 `json:"install_id,omitempty"` // URL holds the value of the "url" field. URL string `json:"url,omitempty"` // AvatarURL holds the value of the "avatar_url" field. AvatarURL *string `json:"avatar_url,omitempty"` // DefaultBranch holds the value of the "default_branch" field. DefaultBranch *string `json:"default_branch,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the RepositoryQuery when eager-loading is set. Edges RepositoryEdges `json:"edges"` // contains filtered or unexported fields }
Repository is the model entity for the Repository schema.
func (*Repository) QueryLatest ¶
func (r *Repository) QueryLatest() *ScanQuery
QueryLatest queries the "latest" edge of the Repository entity.
func (*Repository) QueryMain ¶
func (r *Repository) QueryMain() *ScanQuery
QueryMain queries the "main" edge of the Repository entity.
func (*Repository) QueryScan ¶
func (r *Repository) QueryScan() *ScanQuery
QueryScan queries the "scan" edge of the Repository entity.
func (*Repository) QueryStatus ¶
func (r *Repository) QueryStatus() *VulnStatusIndexQuery
QueryStatus queries the "status" edge of the Repository entity.
func (*Repository) String ¶
func (r *Repository) String() string
String implements the fmt.Stringer.
func (*Repository) Unwrap ¶
func (r *Repository) Unwrap() *Repository
Unwrap unwraps the Repository 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 (*Repository) Update ¶
func (r *Repository) Update() *RepositoryUpdateOne
Update returns a builder for updating this Repository. Note that you need to call Repository.Unwrap() before calling this method if this Repository was returned from a transaction, and the transaction was committed or rolled back.
type RepositoryClient ¶
type RepositoryClient struct {
// contains filtered or unexported fields
}
RepositoryClient is a client for the Repository schema.
func NewRepositoryClient ¶
func NewRepositoryClient(c config) *RepositoryClient
NewRepositoryClient returns a client for the Repository from the given config.
func (*RepositoryClient) Create ¶
func (c *RepositoryClient) Create() *RepositoryCreate
Create returns a create builder for Repository.
func (*RepositoryClient) CreateBulk ¶
func (c *RepositoryClient) CreateBulk(builders ...*RepositoryCreate) *RepositoryCreateBulk
CreateBulk returns a builder for creating a bulk of Repository entities.
func (*RepositoryClient) Delete ¶
func (c *RepositoryClient) Delete() *RepositoryDelete
Delete returns a delete builder for Repository.
func (*RepositoryClient) DeleteOne ¶
func (c *RepositoryClient) DeleteOne(r *Repository) *RepositoryDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*RepositoryClient) DeleteOneID ¶
func (c *RepositoryClient) DeleteOneID(id int) *RepositoryDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*RepositoryClient) Get ¶
func (c *RepositoryClient) Get(ctx context.Context, id int) (*Repository, error)
Get returns a Repository entity by its id.
func (*RepositoryClient) GetX ¶
func (c *RepositoryClient) GetX(ctx context.Context, id int) *Repository
GetX is like Get, but panics if an error occurs.
func (*RepositoryClient) Hooks ¶
func (c *RepositoryClient) Hooks() []Hook
Hooks returns the client hooks.
func (*RepositoryClient) Query ¶
func (c *RepositoryClient) Query() *RepositoryQuery
Query returns a query builder for Repository.
func (*RepositoryClient) QueryLatest ¶
func (c *RepositoryClient) QueryLatest(r *Repository) *ScanQuery
QueryLatest queries the latest edge of a Repository.
func (*RepositoryClient) QueryMain ¶
func (c *RepositoryClient) QueryMain(r *Repository) *ScanQuery
QueryMain queries the main edge of a Repository.
func (*RepositoryClient) QueryScan ¶
func (c *RepositoryClient) QueryScan(r *Repository) *ScanQuery
QueryScan queries the scan edge of a Repository.
func (*RepositoryClient) QueryStatus ¶
func (c *RepositoryClient) QueryStatus(r *Repository) *VulnStatusIndexQuery
QueryStatus queries the status edge of a Repository.
func (*RepositoryClient) Update ¶
func (c *RepositoryClient) Update() *RepositoryUpdate
Update returns an update builder for Repository.
func (*RepositoryClient) UpdateOne ¶
func (c *RepositoryClient) UpdateOne(r *Repository) *RepositoryUpdateOne
UpdateOne returns an update builder for the given entity.
func (*RepositoryClient) UpdateOneID ¶
func (c *RepositoryClient) UpdateOneID(id int) *RepositoryUpdateOne
UpdateOneID returns an update builder for the given id.
func (*RepositoryClient) Use ¶
func (c *RepositoryClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `repository.Hooks(f(g(h())))`.
type RepositoryCreate ¶
type RepositoryCreate struct {
// contains filtered or unexported fields
}
RepositoryCreate is the builder for creating a Repository entity.
func (*RepositoryCreate) AddMain ¶
func (rc *RepositoryCreate) AddMain(s ...*Scan) *RepositoryCreate
AddMain adds the "main" edges to the Scan entity.
func (*RepositoryCreate) AddMainIDs ¶
func (rc *RepositoryCreate) AddMainIDs(ids ...string) *RepositoryCreate
AddMainIDs adds the "main" edge to the Scan entity by IDs.
func (*RepositoryCreate) AddScan ¶
func (rc *RepositoryCreate) AddScan(s ...*Scan) *RepositoryCreate
AddScan adds the "scan" edges to the Scan entity.
func (*RepositoryCreate) AddScanIDs ¶
func (rc *RepositoryCreate) AddScanIDs(ids ...string) *RepositoryCreate
AddScanIDs adds the "scan" edge to the Scan entity by IDs.
func (*RepositoryCreate) AddStatuIDs ¶
func (rc *RepositoryCreate) AddStatuIDs(ids ...string) *RepositoryCreate
AddStatuIDs adds the "status" edge to the VulnStatusIndex entity by IDs.
func (*RepositoryCreate) AddStatus ¶
func (rc *RepositoryCreate) AddStatus(v ...*VulnStatusIndex) *RepositoryCreate
AddStatus adds the "status" edges to the VulnStatusIndex entity.
func (*RepositoryCreate) Exec ¶
func (rc *RepositoryCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*RepositoryCreate) ExecX ¶
func (rc *RepositoryCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryCreate) Mutation ¶
func (rc *RepositoryCreate) Mutation() *RepositoryMutation
Mutation returns the RepositoryMutation object of the builder.
func (*RepositoryCreate) OnConflict ¶
func (rc *RepositoryCreate) OnConflict(opts ...sql.ConflictOption) *RepositoryUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Repository.Create(). SetOwner(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.RepositoryUpsert) { SetOwner(v+v). }). Exec(ctx)
func (*RepositoryCreate) OnConflictColumns ¶
func (rc *RepositoryCreate) OnConflictColumns(columns ...string) *RepositoryUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Repository.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*RepositoryCreate) Save ¶
func (rc *RepositoryCreate) Save(ctx context.Context) (*Repository, error)
Save creates the Repository in the database.
func (*RepositoryCreate) SaveX ¶
func (rc *RepositoryCreate) SaveX(ctx context.Context) *Repository
SaveX calls Save and panics if Save returns an error.
func (*RepositoryCreate) SetAvatarURL ¶
func (rc *RepositoryCreate) SetAvatarURL(s string) *RepositoryCreate
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryCreate) SetDefaultBranch ¶
func (rc *RepositoryCreate) SetDefaultBranch(s string) *RepositoryCreate
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryCreate) SetInstallID ¶
func (rc *RepositoryCreate) SetInstallID(i int64) *RepositoryCreate
SetInstallID sets the "install_id" field.
func (*RepositoryCreate) SetLatest ¶
func (rc *RepositoryCreate) SetLatest(s *Scan) *RepositoryCreate
SetLatest sets the "latest" edge to the Scan entity.
func (*RepositoryCreate) SetLatestID ¶
func (rc *RepositoryCreate) SetLatestID(id string) *RepositoryCreate
SetLatestID sets the "latest" edge to the Scan entity by ID.
func (*RepositoryCreate) SetName ¶
func (rc *RepositoryCreate) SetName(s string) *RepositoryCreate
SetName sets the "name" field.
func (*RepositoryCreate) SetNillableAvatarURL ¶
func (rc *RepositoryCreate) SetNillableAvatarURL(s *string) *RepositoryCreate
SetNillableAvatarURL sets the "avatar_url" field if the given value is not nil.
func (*RepositoryCreate) SetNillableDefaultBranch ¶
func (rc *RepositoryCreate) SetNillableDefaultBranch(s *string) *RepositoryCreate
SetNillableDefaultBranch sets the "default_branch" field if the given value is not nil.
func (*RepositoryCreate) SetNillableInstallID ¶
func (rc *RepositoryCreate) SetNillableInstallID(i *int64) *RepositoryCreate
SetNillableInstallID sets the "install_id" field if the given value is not nil.
func (*RepositoryCreate) SetNillableLatestID ¶
func (rc *RepositoryCreate) SetNillableLatestID(id *string) *RepositoryCreate
SetNillableLatestID sets the "latest" edge to the Scan entity by ID if the given value is not nil.
func (*RepositoryCreate) SetNillableURL ¶
func (rc *RepositoryCreate) SetNillableURL(s *string) *RepositoryCreate
SetNillableURL sets the "url" field if the given value is not nil.
func (*RepositoryCreate) SetOwner ¶
func (rc *RepositoryCreate) SetOwner(s string) *RepositoryCreate
SetOwner sets the "owner" field.
func (*RepositoryCreate) SetURL ¶
func (rc *RepositoryCreate) SetURL(s string) *RepositoryCreate
SetURL sets the "url" field.
type RepositoryCreateBulk ¶
type RepositoryCreateBulk struct {
// contains filtered or unexported fields
}
RepositoryCreateBulk is the builder for creating many Repository entities in bulk.
func (*RepositoryCreateBulk) Exec ¶
func (rcb *RepositoryCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*RepositoryCreateBulk) ExecX ¶
func (rcb *RepositoryCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryCreateBulk) OnConflict ¶
func (rcb *RepositoryCreateBulk) OnConflict(opts ...sql.ConflictOption) *RepositoryUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Repository.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.RepositoryUpsert) { SetOwner(v+v). }). Exec(ctx)
func (*RepositoryCreateBulk) OnConflictColumns ¶
func (rcb *RepositoryCreateBulk) OnConflictColumns(columns ...string) *RepositoryUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Repository.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*RepositoryCreateBulk) Save ¶
func (rcb *RepositoryCreateBulk) Save(ctx context.Context) ([]*Repository, error)
Save creates the Repository entities in the database.
func (*RepositoryCreateBulk) SaveX ¶
func (rcb *RepositoryCreateBulk) SaveX(ctx context.Context) []*Repository
SaveX is like Save, but panics if an error occurs.
type RepositoryDelete ¶
type RepositoryDelete struct {
// contains filtered or unexported fields
}
RepositoryDelete is the builder for deleting a Repository entity.
func (*RepositoryDelete) Exec ¶
func (rd *RepositoryDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*RepositoryDelete) ExecX ¶
func (rd *RepositoryDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryDelete) Where ¶
func (rd *RepositoryDelete) Where(ps ...predicate.Repository) *RepositoryDelete
Where appends a list predicates to the RepositoryDelete builder.
type RepositoryDeleteOne ¶
type RepositoryDeleteOne struct {
// contains filtered or unexported fields
}
RepositoryDeleteOne is the builder for deleting a single Repository entity.
func (*RepositoryDeleteOne) Exec ¶
func (rdo *RepositoryDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*RepositoryDeleteOne) ExecX ¶
func (rdo *RepositoryDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type RepositoryEdges ¶
type RepositoryEdges struct { // Scan holds the value of the scan edge. Scan []*Scan `json:"scan,omitempty"` // Main holds the value of the main edge. Main []*Scan `json:"main,omitempty"` // Latest holds the value of the latest edge. Latest *Scan `json:"latest,omitempty"` // Status holds the value of the status edge. Status []*VulnStatusIndex `json:"status,omitempty"` // contains filtered or unexported fields }
RepositoryEdges holds the relations/edges for other nodes in the graph.
func (RepositoryEdges) LatestOrErr ¶
func (e RepositoryEdges) LatestOrErr() (*Scan, error)
LatestOrErr returns the Latest value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (RepositoryEdges) MainOrErr ¶
func (e RepositoryEdges) MainOrErr() ([]*Scan, error)
MainOrErr returns the Main value or an error if the edge was not loaded in eager-loading.
func (RepositoryEdges) ScanOrErr ¶
func (e RepositoryEdges) ScanOrErr() ([]*Scan, error)
ScanOrErr returns the Scan value or an error if the edge was not loaded in eager-loading.
func (RepositoryEdges) StatusOrErr ¶
func (e RepositoryEdges) StatusOrErr() ([]*VulnStatusIndex, error)
StatusOrErr returns the Status value or an error if the edge was not loaded in eager-loading.
type RepositoryGroupBy ¶
type RepositoryGroupBy struct {
// contains filtered or unexported fields
}
RepositoryGroupBy is the group-by builder for Repository entities.
func (*RepositoryGroupBy) Aggregate ¶
func (rgb *RepositoryGroupBy) Aggregate(fns ...AggregateFunc) *RepositoryGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*RepositoryGroupBy) Bool ¶
func (rgb *RepositoryGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) BoolX ¶
func (rgb *RepositoryGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*RepositoryGroupBy) Bools ¶
func (rgb *RepositoryGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) BoolsX ¶
func (rgb *RepositoryGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*RepositoryGroupBy) Float64 ¶
func (rgb *RepositoryGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) Float64X ¶
func (rgb *RepositoryGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*RepositoryGroupBy) Float64s ¶
func (rgb *RepositoryGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) Float64sX ¶
func (rgb *RepositoryGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*RepositoryGroupBy) Int ¶
func (rgb *RepositoryGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) IntX ¶
func (rgb *RepositoryGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*RepositoryGroupBy) Ints ¶
func (rgb *RepositoryGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) IntsX ¶
func (rgb *RepositoryGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*RepositoryGroupBy) Scan ¶
func (rgb *RepositoryGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*RepositoryGroupBy) ScanX ¶
func (rgb *RepositoryGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*RepositoryGroupBy) String ¶
func (rgb *RepositoryGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*RepositoryGroupBy) StringX ¶
func (rgb *RepositoryGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type RepositoryMutation ¶
type RepositoryMutation struct {
// contains filtered or unexported fields
}
RepositoryMutation represents an operation that mutates the Repository nodes in the graph.
func (*RepositoryMutation) AddField ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) AddInstallID ¶
func (m *RepositoryMutation) AddInstallID(i int64)
AddInstallID adds i to the "install_id" field.
func (*RepositoryMutation) AddMainIDs ¶
func (m *RepositoryMutation) AddMainIDs(ids ...string)
AddMainIDs adds the "main" edge to the Scan entity by ids.
func (*RepositoryMutation) AddScanIDs ¶
func (m *RepositoryMutation) AddScanIDs(ids ...string)
AddScanIDs adds the "scan" edge to the Scan entity by ids.
func (*RepositoryMutation) AddStatuIDs ¶
func (m *RepositoryMutation) AddStatuIDs(ids ...string)
AddStatuIDs adds the "status" edge to the VulnStatusIndex entity by ids.
func (*RepositoryMutation) AddedEdges ¶
func (m *RepositoryMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*RepositoryMutation) AddedField ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) AddedFields ¶
func (m *RepositoryMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*RepositoryMutation) AddedIDs ¶
func (m *RepositoryMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*RepositoryMutation) AddedInstallID ¶
func (m *RepositoryMutation) AddedInstallID() (r int64, exists bool)
AddedInstallID returns the value that was added to the "install_id" field in this mutation.
func (*RepositoryMutation) AvatarURL ¶
func (m *RepositoryMutation) AvatarURL() (r string, exists bool)
AvatarURL returns the value of the "avatar_url" field in the mutation.
func (*RepositoryMutation) AvatarURLCleared ¶
func (m *RepositoryMutation) AvatarURLCleared() bool
AvatarURLCleared returns if the "avatar_url" field was cleared in this mutation.
func (*RepositoryMutation) ClearAvatarURL ¶
func (m *RepositoryMutation) ClearAvatarURL()
ClearAvatarURL clears the value of the "avatar_url" field.
func (*RepositoryMutation) ClearDefaultBranch ¶
func (m *RepositoryMutation) ClearDefaultBranch()
ClearDefaultBranch clears the value of the "default_branch" field.
func (*RepositoryMutation) ClearEdge ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) ClearField ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) ClearInstallID ¶
func (m *RepositoryMutation) ClearInstallID()
ClearInstallID clears the value of the "install_id" field.
func (*RepositoryMutation) ClearLatest ¶
func (m *RepositoryMutation) ClearLatest()
ClearLatest clears the "latest" edge to the Scan entity.
func (*RepositoryMutation) ClearMain ¶
func (m *RepositoryMutation) ClearMain()
ClearMain clears the "main" edge to the Scan entity.
func (*RepositoryMutation) ClearScan ¶
func (m *RepositoryMutation) ClearScan()
ClearScan clears the "scan" edge to the Scan entity.
func (*RepositoryMutation) ClearStatus ¶
func (m *RepositoryMutation) ClearStatus()
ClearStatus clears the "status" edge to the VulnStatusIndex entity.
func (*RepositoryMutation) ClearURL ¶
func (m *RepositoryMutation) ClearURL()
ClearURL clears the value of the "url" field.
func (*RepositoryMutation) ClearedEdges ¶
func (m *RepositoryMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*RepositoryMutation) ClearedFields ¶
func (m *RepositoryMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (RepositoryMutation) Client ¶
func (m RepositoryMutation) 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 (*RepositoryMutation) DefaultBranch ¶
func (m *RepositoryMutation) DefaultBranch() (r string, exists bool)
DefaultBranch returns the value of the "default_branch" field in the mutation.
func (*RepositoryMutation) DefaultBranchCleared ¶
func (m *RepositoryMutation) DefaultBranchCleared() bool
DefaultBranchCleared returns if the "default_branch" field was cleared in this mutation.
func (*RepositoryMutation) EdgeCleared ¶
func (m *RepositoryMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*RepositoryMutation) Field ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) FieldCleared ¶
func (m *RepositoryMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*RepositoryMutation) Fields ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) ID ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) InstallID ¶
func (m *RepositoryMutation) InstallID() (r int64, exists bool)
InstallID returns the value of the "install_id" field in the mutation.
func (*RepositoryMutation) InstallIDCleared ¶
func (m *RepositoryMutation) InstallIDCleared() bool
InstallIDCleared returns if the "install_id" field was cleared in this mutation.
func (*RepositoryMutation) LatestCleared ¶
func (m *RepositoryMutation) LatestCleared() bool
LatestCleared reports if the "latest" edge to the Scan entity was cleared.
func (*RepositoryMutation) LatestID ¶
func (m *RepositoryMutation) LatestID() (id string, exists bool)
LatestID returns the "latest" edge ID in the mutation.
func (*RepositoryMutation) LatestIDs ¶
func (m *RepositoryMutation) LatestIDs() (ids []string)
LatestIDs returns the "latest" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use LatestID instead. It exists only for internal usage by the builders.
func (*RepositoryMutation) MainCleared ¶
func (m *RepositoryMutation) MainCleared() bool
MainCleared reports if the "main" edge to the Scan entity was cleared.
func (*RepositoryMutation) MainIDs ¶
func (m *RepositoryMutation) MainIDs() (ids []string)
MainIDs returns the "main" edge IDs in the mutation.
func (*RepositoryMutation) Name ¶
func (m *RepositoryMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*RepositoryMutation) OldAvatarURL ¶
func (m *RepositoryMutation) OldAvatarURL(ctx context.Context) (v *string, err error)
OldAvatarURL returns the old "avatar_url" field's value of the Repository entity. If the Repository 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 (*RepositoryMutation) OldDefaultBranch ¶
func (m *RepositoryMutation) OldDefaultBranch(ctx context.Context) (v *string, err error)
OldDefaultBranch returns the old "default_branch" field's value of the Repository entity. If the Repository 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 (*RepositoryMutation) 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 (*RepositoryMutation) OldInstallID ¶
func (m *RepositoryMutation) OldInstallID(ctx context.Context) (v int64, err error)
OldInstallID returns the old "install_id" field's value of the Repository entity. If the Repository 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 (*RepositoryMutation) OldName ¶
func (m *RepositoryMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the Repository entity. If the Repository 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 (*RepositoryMutation) OldOwner ¶
func (m *RepositoryMutation) OldOwner(ctx context.Context) (v string, err error)
OldOwner returns the old "owner" field's value of the Repository entity. If the Repository 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 (*RepositoryMutation) OldURL ¶
func (m *RepositoryMutation) OldURL(ctx context.Context) (v string, err error)
OldURL returns the old "url" field's value of the Repository entity. If the Repository 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 (*RepositoryMutation) Owner ¶
func (m *RepositoryMutation) Owner() (r string, exists bool)
Owner returns the value of the "owner" field in the mutation.
func (*RepositoryMutation) RemoveMainIDs ¶
func (m *RepositoryMutation) RemoveMainIDs(ids ...string)
RemoveMainIDs removes the "main" edge to the Scan entity by IDs.
func (*RepositoryMutation) RemoveScanIDs ¶
func (m *RepositoryMutation) RemoveScanIDs(ids ...string)
RemoveScanIDs removes the "scan" edge to the Scan entity by IDs.
func (*RepositoryMutation) RemoveStatuIDs ¶
func (m *RepositoryMutation) RemoveStatuIDs(ids ...string)
RemoveStatuIDs removes the "status" edge to the VulnStatusIndex entity by IDs.
func (*RepositoryMutation) RemovedEdges ¶
func (m *RepositoryMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*RepositoryMutation) RemovedIDs ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) RemovedMainIDs ¶
func (m *RepositoryMutation) RemovedMainIDs() (ids []string)
RemovedMain returns the removed IDs of the "main" edge to the Scan entity.
func (*RepositoryMutation) RemovedScanIDs ¶
func (m *RepositoryMutation) RemovedScanIDs() (ids []string)
RemovedScan returns the removed IDs of the "scan" edge to the Scan entity.
func (*RepositoryMutation) RemovedStatusIDs ¶
func (m *RepositoryMutation) RemovedStatusIDs() (ids []string)
RemovedStatus returns the removed IDs of the "status" edge to the VulnStatusIndex entity.
func (*RepositoryMutation) ResetAvatarURL ¶
func (m *RepositoryMutation) ResetAvatarURL()
ResetAvatarURL resets all changes to the "avatar_url" field.
func (*RepositoryMutation) ResetDefaultBranch ¶
func (m *RepositoryMutation) ResetDefaultBranch()
ResetDefaultBranch resets all changes to the "default_branch" field.
func (*RepositoryMutation) ResetEdge ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) ResetField ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) ResetInstallID ¶
func (m *RepositoryMutation) ResetInstallID()
ResetInstallID resets all changes to the "install_id" field.
func (*RepositoryMutation) ResetLatest ¶
func (m *RepositoryMutation) ResetLatest()
ResetLatest resets all changes to the "latest" edge.
func (*RepositoryMutation) ResetMain ¶
func (m *RepositoryMutation) ResetMain()
ResetMain resets all changes to the "main" edge.
func (*RepositoryMutation) ResetName ¶
func (m *RepositoryMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*RepositoryMutation) ResetOwner ¶
func (m *RepositoryMutation) ResetOwner()
ResetOwner resets all changes to the "owner" field.
func (*RepositoryMutation) ResetScan ¶
func (m *RepositoryMutation) ResetScan()
ResetScan resets all changes to the "scan" edge.
func (*RepositoryMutation) ResetStatus ¶
func (m *RepositoryMutation) ResetStatus()
ResetStatus resets all changes to the "status" edge.
func (*RepositoryMutation) ResetURL ¶
func (m *RepositoryMutation) ResetURL()
ResetURL resets all changes to the "url" field.
func (*RepositoryMutation) ScanCleared ¶
func (m *RepositoryMutation) ScanCleared() bool
ScanCleared reports if the "scan" edge to the Scan entity was cleared.
func (*RepositoryMutation) ScanIDs ¶
func (m *RepositoryMutation) ScanIDs() (ids []string)
ScanIDs returns the "scan" edge IDs in the mutation.
func (*RepositoryMutation) SetAvatarURL ¶
func (m *RepositoryMutation) SetAvatarURL(s string)
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryMutation) SetDefaultBranch ¶
func (m *RepositoryMutation) SetDefaultBranch(s string)
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryMutation) SetField ¶
func (m *RepositoryMutation) 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 (*RepositoryMutation) SetInstallID ¶
func (m *RepositoryMutation) SetInstallID(i int64)
SetInstallID sets the "install_id" field.
func (*RepositoryMutation) SetLatestID ¶
func (m *RepositoryMutation) SetLatestID(id string)
SetLatestID sets the "latest" edge to the Scan entity by id.
func (*RepositoryMutation) SetName ¶
func (m *RepositoryMutation) SetName(s string)
SetName sets the "name" field.
func (*RepositoryMutation) SetOwner ¶
func (m *RepositoryMutation) SetOwner(s string)
SetOwner sets the "owner" field.
func (*RepositoryMutation) SetURL ¶
func (m *RepositoryMutation) SetURL(s string)
SetURL sets the "url" field.
func (*RepositoryMutation) StatusCleared ¶
func (m *RepositoryMutation) StatusCleared() bool
StatusCleared reports if the "status" edge to the VulnStatusIndex entity was cleared.
func (*RepositoryMutation) StatusIDs ¶
func (m *RepositoryMutation) StatusIDs() (ids []string)
StatusIDs returns the "status" edge IDs in the mutation.
func (RepositoryMutation) Tx ¶
func (m RepositoryMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*RepositoryMutation) Type ¶
func (m *RepositoryMutation) Type() string
Type returns the node type of this mutation (Repository).
func (*RepositoryMutation) URL ¶
func (m *RepositoryMutation) URL() (r string, exists bool)
URL returns the value of the "url" field in the mutation.
func (*RepositoryMutation) URLCleared ¶
func (m *RepositoryMutation) URLCleared() bool
URLCleared returns if the "url" field was cleared in this mutation.
func (*RepositoryMutation) Where ¶
func (m *RepositoryMutation) Where(ps ...predicate.Repository)
Where appends a list predicates to the RepositoryMutation builder.
type RepositoryQuery ¶
type RepositoryQuery struct {
// contains filtered or unexported fields
}
RepositoryQuery is the builder for querying Repository entities.
func (*RepositoryQuery) All ¶
func (rq *RepositoryQuery) All(ctx context.Context) ([]*Repository, error)
All executes the query and returns a list of Repositories.
func (*RepositoryQuery) AllX ¶
func (rq *RepositoryQuery) AllX(ctx context.Context) []*Repository
AllX is like All, but panics if an error occurs.
func (*RepositoryQuery) Clone ¶
func (rq *RepositoryQuery) Clone() *RepositoryQuery
Clone returns a duplicate of the RepositoryQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*RepositoryQuery) Count ¶
func (rq *RepositoryQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*RepositoryQuery) CountX ¶
func (rq *RepositoryQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*RepositoryQuery) Exist ¶
func (rq *RepositoryQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*RepositoryQuery) ExistX ¶
func (rq *RepositoryQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*RepositoryQuery) First ¶
func (rq *RepositoryQuery) First(ctx context.Context) (*Repository, error)
First returns the first Repository entity from the query. Returns a *NotFoundError when no Repository was found.
func (*RepositoryQuery) FirstID ¶
func (rq *RepositoryQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Repository ID from the query. Returns a *NotFoundError when no Repository ID was found.
func (*RepositoryQuery) FirstIDX ¶
func (rq *RepositoryQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*RepositoryQuery) FirstX ¶
func (rq *RepositoryQuery) FirstX(ctx context.Context) *Repository
FirstX is like First, but panics if an error occurs.
func (*RepositoryQuery) GroupBy ¶
func (rq *RepositoryQuery) GroupBy(field string, fields ...string) *RepositoryGroupBy
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 { Owner string `json:"owner,omitempty"` Count int `json:"count,omitempty"` } client.Repository.Query(). GroupBy(repository.FieldOwner). Aggregate(ent.Count()). Scan(ctx, &v)
func (*RepositoryQuery) IDs ¶
func (rq *RepositoryQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of Repository IDs.
func (*RepositoryQuery) IDsX ¶
func (rq *RepositoryQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*RepositoryQuery) Limit ¶
func (rq *RepositoryQuery) Limit(limit int) *RepositoryQuery
Limit adds a limit step to the query.
func (*RepositoryQuery) Offset ¶
func (rq *RepositoryQuery) Offset(offset int) *RepositoryQuery
Offset adds an offset step to the query.
func (*RepositoryQuery) Only ¶
func (rq *RepositoryQuery) Only(ctx context.Context) (*Repository, error)
Only returns a single Repository entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one Repository entity is not found. Returns a *NotFoundError when no Repository entities are found.
func (*RepositoryQuery) OnlyID ¶
func (rq *RepositoryQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Repository ID in the query. Returns a *NotSingularError when exactly one Repository ID is not found. Returns a *NotFoundError when no entities are found.
func (*RepositoryQuery) OnlyIDX ¶
func (rq *RepositoryQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*RepositoryQuery) OnlyX ¶
func (rq *RepositoryQuery) OnlyX(ctx context.Context) *Repository
OnlyX is like Only, but panics if an error occurs.
func (*RepositoryQuery) Order ¶
func (rq *RepositoryQuery) Order(o ...OrderFunc) *RepositoryQuery
Order adds an order step to the query.
func (*RepositoryQuery) QueryLatest ¶
func (rq *RepositoryQuery) QueryLatest() *ScanQuery
QueryLatest chains the current query on the "latest" edge.
func (*RepositoryQuery) QueryMain ¶
func (rq *RepositoryQuery) QueryMain() *ScanQuery
QueryMain chains the current query on the "main" edge.
func (*RepositoryQuery) QueryScan ¶
func (rq *RepositoryQuery) QueryScan() *ScanQuery
QueryScan chains the current query on the "scan" edge.
func (*RepositoryQuery) QueryStatus ¶
func (rq *RepositoryQuery) QueryStatus() *VulnStatusIndexQuery
QueryStatus chains the current query on the "status" edge.
func (*RepositoryQuery) Select ¶
func (rq *RepositoryQuery) Select(fields ...string) *RepositorySelect
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 { Owner string `json:"owner,omitempty"` } client.Repository.Query(). Select(repository.FieldOwner). Scan(ctx, &v)
func (*RepositoryQuery) Unique ¶
func (rq *RepositoryQuery) Unique(unique bool) *RepositoryQuery
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 (*RepositoryQuery) Where ¶
func (rq *RepositoryQuery) Where(ps ...predicate.Repository) *RepositoryQuery
Where adds a new predicate for the RepositoryQuery builder.
func (*RepositoryQuery) WithLatest ¶
func (rq *RepositoryQuery) WithLatest(opts ...func(*ScanQuery)) *RepositoryQuery
WithLatest tells the query-builder to eager-load the nodes that are connected to the "latest" edge. The optional arguments are used to configure the query builder of the edge.
func (*RepositoryQuery) WithMain ¶
func (rq *RepositoryQuery) WithMain(opts ...func(*ScanQuery)) *RepositoryQuery
WithMain tells the query-builder to eager-load the nodes that are connected to the "main" edge. The optional arguments are used to configure the query builder of the edge.
func (*RepositoryQuery) WithScan ¶
func (rq *RepositoryQuery) WithScan(opts ...func(*ScanQuery)) *RepositoryQuery
WithScan tells the query-builder to eager-load the nodes that are connected to the "scan" edge. The optional arguments are used to configure the query builder of the edge.
func (*RepositoryQuery) WithStatus ¶
func (rq *RepositoryQuery) WithStatus(opts ...func(*VulnStatusIndexQuery)) *RepositoryQuery
WithStatus tells the query-builder to eager-load the nodes that are connected to the "status" edge. The optional arguments are used to configure the query builder of the edge.
type RepositorySelect ¶
type RepositorySelect struct { *RepositoryQuery // contains filtered or unexported fields }
RepositorySelect is the builder for selecting fields of Repository entities.
func (*RepositorySelect) Bool ¶
func (rs *RepositorySelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) BoolX ¶
func (rs *RepositorySelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*RepositorySelect) Bools ¶
func (rs *RepositorySelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) BoolsX ¶
func (rs *RepositorySelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*RepositorySelect) Float64 ¶
func (rs *RepositorySelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) Float64X ¶
func (rs *RepositorySelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*RepositorySelect) Float64s ¶
func (rs *RepositorySelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) Float64sX ¶
func (rs *RepositorySelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*RepositorySelect) Int ¶
func (rs *RepositorySelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) IntX ¶
func (rs *RepositorySelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*RepositorySelect) Ints ¶
func (rs *RepositorySelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) IntsX ¶
func (rs *RepositorySelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*RepositorySelect) Scan ¶
func (rs *RepositorySelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*RepositorySelect) ScanX ¶
func (rs *RepositorySelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*RepositorySelect) String ¶
func (rs *RepositorySelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*RepositorySelect) StringX ¶
func (rs *RepositorySelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type RepositoryUpdate ¶
type RepositoryUpdate struct {
// contains filtered or unexported fields
}
RepositoryUpdate is the builder for updating Repository entities.
func (*RepositoryUpdate) AddInstallID ¶
func (ru *RepositoryUpdate) AddInstallID(i int64) *RepositoryUpdate
AddInstallID adds i to the "install_id" field.
func (*RepositoryUpdate) AddMain ¶
func (ru *RepositoryUpdate) AddMain(s ...*Scan) *RepositoryUpdate
AddMain adds the "main" edges to the Scan entity.
func (*RepositoryUpdate) AddMainIDs ¶
func (ru *RepositoryUpdate) AddMainIDs(ids ...string) *RepositoryUpdate
AddMainIDs adds the "main" edge to the Scan entity by IDs.
func (*RepositoryUpdate) AddScan ¶
func (ru *RepositoryUpdate) AddScan(s ...*Scan) *RepositoryUpdate
AddScan adds the "scan" edges to the Scan entity.
func (*RepositoryUpdate) AddScanIDs ¶
func (ru *RepositoryUpdate) AddScanIDs(ids ...string) *RepositoryUpdate
AddScanIDs adds the "scan" edge to the Scan entity by IDs.
func (*RepositoryUpdate) AddStatuIDs ¶
func (ru *RepositoryUpdate) AddStatuIDs(ids ...string) *RepositoryUpdate
AddStatuIDs adds the "status" edge to the VulnStatusIndex entity by IDs.
func (*RepositoryUpdate) AddStatus ¶
func (ru *RepositoryUpdate) AddStatus(v ...*VulnStatusIndex) *RepositoryUpdate
AddStatus adds the "status" edges to the VulnStatusIndex entity.
func (*RepositoryUpdate) ClearAvatarURL ¶
func (ru *RepositoryUpdate) ClearAvatarURL() *RepositoryUpdate
ClearAvatarURL clears the value of the "avatar_url" field.
func (*RepositoryUpdate) ClearDefaultBranch ¶
func (ru *RepositoryUpdate) ClearDefaultBranch() *RepositoryUpdate
ClearDefaultBranch clears the value of the "default_branch" field.
func (*RepositoryUpdate) ClearInstallID ¶
func (ru *RepositoryUpdate) ClearInstallID() *RepositoryUpdate
ClearInstallID clears the value of the "install_id" field.
func (*RepositoryUpdate) ClearLatest ¶
func (ru *RepositoryUpdate) ClearLatest() *RepositoryUpdate
ClearLatest clears the "latest" edge to the Scan entity.
func (*RepositoryUpdate) ClearMain ¶
func (ru *RepositoryUpdate) ClearMain() *RepositoryUpdate
ClearMain clears all "main" edges to the Scan entity.
func (*RepositoryUpdate) ClearScan ¶
func (ru *RepositoryUpdate) ClearScan() *RepositoryUpdate
ClearScan clears all "scan" edges to the Scan entity.
func (*RepositoryUpdate) ClearStatus ¶
func (ru *RepositoryUpdate) ClearStatus() *RepositoryUpdate
ClearStatus clears all "status" edges to the VulnStatusIndex entity.
func (*RepositoryUpdate) ClearURL ¶
func (ru *RepositoryUpdate) ClearURL() *RepositoryUpdate
ClearURL clears the value of the "url" field.
func (*RepositoryUpdate) Exec ¶
func (ru *RepositoryUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*RepositoryUpdate) ExecX ¶
func (ru *RepositoryUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryUpdate) Mutation ¶
func (ru *RepositoryUpdate) Mutation() *RepositoryMutation
Mutation returns the RepositoryMutation object of the builder.
func (*RepositoryUpdate) RemoveMain ¶
func (ru *RepositoryUpdate) RemoveMain(s ...*Scan) *RepositoryUpdate
RemoveMain removes "main" edges to Scan entities.
func (*RepositoryUpdate) RemoveMainIDs ¶
func (ru *RepositoryUpdate) RemoveMainIDs(ids ...string) *RepositoryUpdate
RemoveMainIDs removes the "main" edge to Scan entities by IDs.
func (*RepositoryUpdate) RemoveScan ¶
func (ru *RepositoryUpdate) RemoveScan(s ...*Scan) *RepositoryUpdate
RemoveScan removes "scan" edges to Scan entities.
func (*RepositoryUpdate) RemoveScanIDs ¶
func (ru *RepositoryUpdate) RemoveScanIDs(ids ...string) *RepositoryUpdate
RemoveScanIDs removes the "scan" edge to Scan entities by IDs.
func (*RepositoryUpdate) RemoveStatuIDs ¶
func (ru *RepositoryUpdate) RemoveStatuIDs(ids ...string) *RepositoryUpdate
RemoveStatuIDs removes the "status" edge to VulnStatusIndex entities by IDs.
func (*RepositoryUpdate) RemoveStatus ¶
func (ru *RepositoryUpdate) RemoveStatus(v ...*VulnStatusIndex) *RepositoryUpdate
RemoveStatus removes "status" edges to VulnStatusIndex entities.
func (*RepositoryUpdate) Save ¶
func (ru *RepositoryUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*RepositoryUpdate) SaveX ¶
func (ru *RepositoryUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*RepositoryUpdate) SetAvatarURL ¶
func (ru *RepositoryUpdate) SetAvatarURL(s string) *RepositoryUpdate
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryUpdate) SetDefaultBranch ¶
func (ru *RepositoryUpdate) SetDefaultBranch(s string) *RepositoryUpdate
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryUpdate) SetInstallID ¶
func (ru *RepositoryUpdate) SetInstallID(i int64) *RepositoryUpdate
SetInstallID sets the "install_id" field.
func (*RepositoryUpdate) SetLatest ¶
func (ru *RepositoryUpdate) SetLatest(s *Scan) *RepositoryUpdate
SetLatest sets the "latest" edge to the Scan entity.
func (*RepositoryUpdate) SetLatestID ¶
func (ru *RepositoryUpdate) SetLatestID(id string) *RepositoryUpdate
SetLatestID sets the "latest" edge to the Scan entity by ID.
func (*RepositoryUpdate) SetName ¶
func (ru *RepositoryUpdate) SetName(s string) *RepositoryUpdate
SetName sets the "name" field.
func (*RepositoryUpdate) SetNillableAvatarURL ¶
func (ru *RepositoryUpdate) SetNillableAvatarURL(s *string) *RepositoryUpdate
SetNillableAvatarURL sets the "avatar_url" field if the given value is not nil.
func (*RepositoryUpdate) SetNillableDefaultBranch ¶
func (ru *RepositoryUpdate) SetNillableDefaultBranch(s *string) *RepositoryUpdate
SetNillableDefaultBranch sets the "default_branch" field if the given value is not nil.
func (*RepositoryUpdate) SetNillableInstallID ¶
func (ru *RepositoryUpdate) SetNillableInstallID(i *int64) *RepositoryUpdate
SetNillableInstallID sets the "install_id" field if the given value is not nil.
func (*RepositoryUpdate) SetNillableLatestID ¶
func (ru *RepositoryUpdate) SetNillableLatestID(id *string) *RepositoryUpdate
SetNillableLatestID sets the "latest" edge to the Scan entity by ID if the given value is not nil.
func (*RepositoryUpdate) SetNillableURL ¶
func (ru *RepositoryUpdate) SetNillableURL(s *string) *RepositoryUpdate
SetNillableURL sets the "url" field if the given value is not nil.
func (*RepositoryUpdate) SetOwner ¶
func (ru *RepositoryUpdate) SetOwner(s string) *RepositoryUpdate
SetOwner sets the "owner" field.
func (*RepositoryUpdate) SetURL ¶
func (ru *RepositoryUpdate) SetURL(s string) *RepositoryUpdate
SetURL sets the "url" field.
func (*RepositoryUpdate) Where ¶
func (ru *RepositoryUpdate) Where(ps ...predicate.Repository) *RepositoryUpdate
Where appends a list predicates to the RepositoryUpdate builder.
type RepositoryUpdateOne ¶
type RepositoryUpdateOne struct {
// contains filtered or unexported fields
}
RepositoryUpdateOne is the builder for updating a single Repository entity.
func (*RepositoryUpdateOne) AddInstallID ¶
func (ruo *RepositoryUpdateOne) AddInstallID(i int64) *RepositoryUpdateOne
AddInstallID adds i to the "install_id" field.
func (*RepositoryUpdateOne) AddMain ¶
func (ruo *RepositoryUpdateOne) AddMain(s ...*Scan) *RepositoryUpdateOne
AddMain adds the "main" edges to the Scan entity.
func (*RepositoryUpdateOne) AddMainIDs ¶
func (ruo *RepositoryUpdateOne) AddMainIDs(ids ...string) *RepositoryUpdateOne
AddMainIDs adds the "main" edge to the Scan entity by IDs.
func (*RepositoryUpdateOne) AddScan ¶
func (ruo *RepositoryUpdateOne) AddScan(s ...*Scan) *RepositoryUpdateOne
AddScan adds the "scan" edges to the Scan entity.
func (*RepositoryUpdateOne) AddScanIDs ¶
func (ruo *RepositoryUpdateOne) AddScanIDs(ids ...string) *RepositoryUpdateOne
AddScanIDs adds the "scan" edge to the Scan entity by IDs.
func (*RepositoryUpdateOne) AddStatuIDs ¶
func (ruo *RepositoryUpdateOne) AddStatuIDs(ids ...string) *RepositoryUpdateOne
AddStatuIDs adds the "status" edge to the VulnStatusIndex entity by IDs.
func (*RepositoryUpdateOne) AddStatus ¶
func (ruo *RepositoryUpdateOne) AddStatus(v ...*VulnStatusIndex) *RepositoryUpdateOne
AddStatus adds the "status" edges to the VulnStatusIndex entity.
func (*RepositoryUpdateOne) ClearAvatarURL ¶
func (ruo *RepositoryUpdateOne) ClearAvatarURL() *RepositoryUpdateOne
ClearAvatarURL clears the value of the "avatar_url" field.
func (*RepositoryUpdateOne) ClearDefaultBranch ¶
func (ruo *RepositoryUpdateOne) ClearDefaultBranch() *RepositoryUpdateOne
ClearDefaultBranch clears the value of the "default_branch" field.
func (*RepositoryUpdateOne) ClearInstallID ¶
func (ruo *RepositoryUpdateOne) ClearInstallID() *RepositoryUpdateOne
ClearInstallID clears the value of the "install_id" field.
func (*RepositoryUpdateOne) ClearLatest ¶
func (ruo *RepositoryUpdateOne) ClearLatest() *RepositoryUpdateOne
ClearLatest clears the "latest" edge to the Scan entity.
func (*RepositoryUpdateOne) ClearMain ¶
func (ruo *RepositoryUpdateOne) ClearMain() *RepositoryUpdateOne
ClearMain clears all "main" edges to the Scan entity.
func (*RepositoryUpdateOne) ClearScan ¶
func (ruo *RepositoryUpdateOne) ClearScan() *RepositoryUpdateOne
ClearScan clears all "scan" edges to the Scan entity.
func (*RepositoryUpdateOne) ClearStatus ¶
func (ruo *RepositoryUpdateOne) ClearStatus() *RepositoryUpdateOne
ClearStatus clears all "status" edges to the VulnStatusIndex entity.
func (*RepositoryUpdateOne) ClearURL ¶
func (ruo *RepositoryUpdateOne) ClearURL() *RepositoryUpdateOne
ClearURL clears the value of the "url" field.
func (*RepositoryUpdateOne) Exec ¶
func (ruo *RepositoryUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*RepositoryUpdateOne) ExecX ¶
func (ruo *RepositoryUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryUpdateOne) Mutation ¶
func (ruo *RepositoryUpdateOne) Mutation() *RepositoryMutation
Mutation returns the RepositoryMutation object of the builder.
func (*RepositoryUpdateOne) RemoveMain ¶
func (ruo *RepositoryUpdateOne) RemoveMain(s ...*Scan) *RepositoryUpdateOne
RemoveMain removes "main" edges to Scan entities.
func (*RepositoryUpdateOne) RemoveMainIDs ¶
func (ruo *RepositoryUpdateOne) RemoveMainIDs(ids ...string) *RepositoryUpdateOne
RemoveMainIDs removes the "main" edge to Scan entities by IDs.
func (*RepositoryUpdateOne) RemoveScan ¶
func (ruo *RepositoryUpdateOne) RemoveScan(s ...*Scan) *RepositoryUpdateOne
RemoveScan removes "scan" edges to Scan entities.
func (*RepositoryUpdateOne) RemoveScanIDs ¶
func (ruo *RepositoryUpdateOne) RemoveScanIDs(ids ...string) *RepositoryUpdateOne
RemoveScanIDs removes the "scan" edge to Scan entities by IDs.
func (*RepositoryUpdateOne) RemoveStatuIDs ¶
func (ruo *RepositoryUpdateOne) RemoveStatuIDs(ids ...string) *RepositoryUpdateOne
RemoveStatuIDs removes the "status" edge to VulnStatusIndex entities by IDs.
func (*RepositoryUpdateOne) RemoveStatus ¶
func (ruo *RepositoryUpdateOne) RemoveStatus(v ...*VulnStatusIndex) *RepositoryUpdateOne
RemoveStatus removes "status" edges to VulnStatusIndex entities.
func (*RepositoryUpdateOne) Save ¶
func (ruo *RepositoryUpdateOne) Save(ctx context.Context) (*Repository, error)
Save executes the query and returns the updated Repository entity.
func (*RepositoryUpdateOne) SaveX ¶
func (ruo *RepositoryUpdateOne) SaveX(ctx context.Context) *Repository
SaveX is like Save, but panics if an error occurs.
func (*RepositoryUpdateOne) Select ¶
func (ruo *RepositoryUpdateOne) Select(field string, fields ...string) *RepositoryUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*RepositoryUpdateOne) SetAvatarURL ¶
func (ruo *RepositoryUpdateOne) SetAvatarURL(s string) *RepositoryUpdateOne
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryUpdateOne) SetDefaultBranch ¶
func (ruo *RepositoryUpdateOne) SetDefaultBranch(s string) *RepositoryUpdateOne
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryUpdateOne) SetInstallID ¶
func (ruo *RepositoryUpdateOne) SetInstallID(i int64) *RepositoryUpdateOne
SetInstallID sets the "install_id" field.
func (*RepositoryUpdateOne) SetLatest ¶
func (ruo *RepositoryUpdateOne) SetLatest(s *Scan) *RepositoryUpdateOne
SetLatest sets the "latest" edge to the Scan entity.
func (*RepositoryUpdateOne) SetLatestID ¶
func (ruo *RepositoryUpdateOne) SetLatestID(id string) *RepositoryUpdateOne
SetLatestID sets the "latest" edge to the Scan entity by ID.
func (*RepositoryUpdateOne) SetName ¶
func (ruo *RepositoryUpdateOne) SetName(s string) *RepositoryUpdateOne
SetName sets the "name" field.
func (*RepositoryUpdateOne) SetNillableAvatarURL ¶
func (ruo *RepositoryUpdateOne) SetNillableAvatarURL(s *string) *RepositoryUpdateOne
SetNillableAvatarURL sets the "avatar_url" field if the given value is not nil.
func (*RepositoryUpdateOne) SetNillableDefaultBranch ¶
func (ruo *RepositoryUpdateOne) SetNillableDefaultBranch(s *string) *RepositoryUpdateOne
SetNillableDefaultBranch sets the "default_branch" field if the given value is not nil.
func (*RepositoryUpdateOne) SetNillableInstallID ¶
func (ruo *RepositoryUpdateOne) SetNillableInstallID(i *int64) *RepositoryUpdateOne
SetNillableInstallID sets the "install_id" field if the given value is not nil.
func (*RepositoryUpdateOne) SetNillableLatestID ¶
func (ruo *RepositoryUpdateOne) SetNillableLatestID(id *string) *RepositoryUpdateOne
SetNillableLatestID sets the "latest" edge to the Scan entity by ID if the given value is not nil.
func (*RepositoryUpdateOne) SetNillableURL ¶
func (ruo *RepositoryUpdateOne) SetNillableURL(s *string) *RepositoryUpdateOne
SetNillableURL sets the "url" field if the given value is not nil.
func (*RepositoryUpdateOne) SetOwner ¶
func (ruo *RepositoryUpdateOne) SetOwner(s string) *RepositoryUpdateOne
SetOwner sets the "owner" field.
func (*RepositoryUpdateOne) SetURL ¶
func (ruo *RepositoryUpdateOne) SetURL(s string) *RepositoryUpdateOne
SetURL sets the "url" field.
type RepositoryUpsert ¶
RepositoryUpsert is the "OnConflict" setter.
func (*RepositoryUpsert) ClearAvatarURL ¶
func (u *RepositoryUpsert) ClearAvatarURL() *RepositoryUpsert
ClearAvatarURL clears the value of the "avatar_url" field.
func (*RepositoryUpsert) ClearDefaultBranch ¶
func (u *RepositoryUpsert) ClearDefaultBranch() *RepositoryUpsert
ClearDefaultBranch clears the value of the "default_branch" field.
func (*RepositoryUpsert) ClearInstallID ¶
func (u *RepositoryUpsert) ClearInstallID() *RepositoryUpsert
ClearInstallID clears the value of the "install_id" field.
func (*RepositoryUpsert) ClearURL ¶
func (u *RepositoryUpsert) ClearURL() *RepositoryUpsert
ClearURL clears the value of the "url" field.
func (*RepositoryUpsert) SetAvatarURL ¶
func (u *RepositoryUpsert) SetAvatarURL(v string) *RepositoryUpsert
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryUpsert) SetDefaultBranch ¶
func (u *RepositoryUpsert) SetDefaultBranch(v string) *RepositoryUpsert
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryUpsert) SetInstallID ¶
func (u *RepositoryUpsert) SetInstallID(v int64) *RepositoryUpsert
SetInstallID sets the "install_id" field.
func (*RepositoryUpsert) SetName ¶
func (u *RepositoryUpsert) SetName(v string) *RepositoryUpsert
SetName sets the "name" field.
func (*RepositoryUpsert) SetOwner ¶
func (u *RepositoryUpsert) SetOwner(v string) *RepositoryUpsert
SetOwner sets the "owner" field.
func (*RepositoryUpsert) SetURL ¶
func (u *RepositoryUpsert) SetURL(v string) *RepositoryUpsert
SetURL sets the "url" field.
func (*RepositoryUpsert) UpdateAvatarURL ¶
func (u *RepositoryUpsert) UpdateAvatarURL() *RepositoryUpsert
UpdateAvatarURL sets the "avatar_url" field to the value that was provided on create.
func (*RepositoryUpsert) UpdateDefaultBranch ¶
func (u *RepositoryUpsert) UpdateDefaultBranch() *RepositoryUpsert
UpdateDefaultBranch sets the "default_branch" field to the value that was provided on create.
func (*RepositoryUpsert) UpdateInstallID ¶
func (u *RepositoryUpsert) UpdateInstallID() *RepositoryUpsert
UpdateInstallID sets the "install_id" field to the value that was provided on create.
func (*RepositoryUpsert) UpdateName ¶
func (u *RepositoryUpsert) UpdateName() *RepositoryUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*RepositoryUpsert) UpdateOwner ¶
func (u *RepositoryUpsert) UpdateOwner() *RepositoryUpsert
UpdateOwner sets the "owner" field to the value that was provided on create.
func (*RepositoryUpsert) UpdateURL ¶
func (u *RepositoryUpsert) UpdateURL() *RepositoryUpsert
UpdateURL sets the "url" field to the value that was provided on create.
type RepositoryUpsertBulk ¶
type RepositoryUpsertBulk struct {
// contains filtered or unexported fields
}
RepositoryUpsertBulk is the builder for "upsert"-ing a bulk of Repository nodes.
func (*RepositoryUpsertBulk) ClearAvatarURL ¶
func (u *RepositoryUpsertBulk) ClearAvatarURL() *RepositoryUpsertBulk
ClearAvatarURL clears the value of the "avatar_url" field.
func (*RepositoryUpsertBulk) ClearDefaultBranch ¶
func (u *RepositoryUpsertBulk) ClearDefaultBranch() *RepositoryUpsertBulk
ClearDefaultBranch clears the value of the "default_branch" field.
func (*RepositoryUpsertBulk) ClearInstallID ¶
func (u *RepositoryUpsertBulk) ClearInstallID() *RepositoryUpsertBulk
ClearInstallID clears the value of the "install_id" field.
func (*RepositoryUpsertBulk) ClearURL ¶
func (u *RepositoryUpsertBulk) ClearURL() *RepositoryUpsertBulk
ClearURL clears the value of the "url" field.
func (*RepositoryUpsertBulk) DoNothing ¶
func (u *RepositoryUpsertBulk) DoNothing() *RepositoryUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*RepositoryUpsertBulk) Exec ¶
func (u *RepositoryUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*RepositoryUpsertBulk) ExecX ¶
func (u *RepositoryUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryUpsertBulk) Ignore ¶
func (u *RepositoryUpsertBulk) Ignore() *RepositoryUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Repository.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*RepositoryUpsertBulk) SetAvatarURL ¶
func (u *RepositoryUpsertBulk) SetAvatarURL(v string) *RepositoryUpsertBulk
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryUpsertBulk) SetDefaultBranch ¶
func (u *RepositoryUpsertBulk) SetDefaultBranch(v string) *RepositoryUpsertBulk
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryUpsertBulk) SetInstallID ¶
func (u *RepositoryUpsertBulk) SetInstallID(v int64) *RepositoryUpsertBulk
SetInstallID sets the "install_id" field.
func (*RepositoryUpsertBulk) SetName ¶
func (u *RepositoryUpsertBulk) SetName(v string) *RepositoryUpsertBulk
SetName sets the "name" field.
func (*RepositoryUpsertBulk) SetOwner ¶
func (u *RepositoryUpsertBulk) SetOwner(v string) *RepositoryUpsertBulk
SetOwner sets the "owner" field.
func (*RepositoryUpsertBulk) SetURL ¶
func (u *RepositoryUpsertBulk) SetURL(v string) *RepositoryUpsertBulk
SetURL sets the "url" field.
func (*RepositoryUpsertBulk) Update ¶
func (u *RepositoryUpsertBulk) Update(set func(*RepositoryUpsert)) *RepositoryUpsertBulk
Update allows overriding fields `UPDATE` values. See the RepositoryCreateBulk.OnConflict documentation for more info.
func (*RepositoryUpsertBulk) UpdateAvatarURL ¶
func (u *RepositoryUpsertBulk) UpdateAvatarURL() *RepositoryUpsertBulk
UpdateAvatarURL sets the "avatar_url" field to the value that was provided on create.
func (*RepositoryUpsertBulk) UpdateDefaultBranch ¶
func (u *RepositoryUpsertBulk) UpdateDefaultBranch() *RepositoryUpsertBulk
UpdateDefaultBranch sets the "default_branch" field to the value that was provided on create.
func (*RepositoryUpsertBulk) UpdateInstallID ¶
func (u *RepositoryUpsertBulk) UpdateInstallID() *RepositoryUpsertBulk
UpdateInstallID sets the "install_id" field to the value that was provided on create.
func (*RepositoryUpsertBulk) UpdateName ¶
func (u *RepositoryUpsertBulk) UpdateName() *RepositoryUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*RepositoryUpsertBulk) UpdateNewValues ¶
func (u *RepositoryUpsertBulk) UpdateNewValues() *RepositoryUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Repository.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*RepositoryUpsertBulk) UpdateOwner ¶
func (u *RepositoryUpsertBulk) UpdateOwner() *RepositoryUpsertBulk
UpdateOwner sets the "owner" field to the value that was provided on create.
func (*RepositoryUpsertBulk) UpdateURL ¶
func (u *RepositoryUpsertBulk) UpdateURL() *RepositoryUpsertBulk
UpdateURL sets the "url" field to the value that was provided on create.
type RepositoryUpsertOne ¶
type RepositoryUpsertOne struct {
// contains filtered or unexported fields
}
RepositoryUpsertOne is the builder for "upsert"-ing
one Repository node.
func (*RepositoryUpsertOne) ClearAvatarURL ¶
func (u *RepositoryUpsertOne) ClearAvatarURL() *RepositoryUpsertOne
ClearAvatarURL clears the value of the "avatar_url" field.
func (*RepositoryUpsertOne) ClearDefaultBranch ¶
func (u *RepositoryUpsertOne) ClearDefaultBranch() *RepositoryUpsertOne
ClearDefaultBranch clears the value of the "default_branch" field.
func (*RepositoryUpsertOne) ClearInstallID ¶
func (u *RepositoryUpsertOne) ClearInstallID() *RepositoryUpsertOne
ClearInstallID clears the value of the "install_id" field.
func (*RepositoryUpsertOne) ClearURL ¶
func (u *RepositoryUpsertOne) ClearURL() *RepositoryUpsertOne
ClearURL clears the value of the "url" field.
func (*RepositoryUpsertOne) DoNothing ¶
func (u *RepositoryUpsertOne) DoNothing() *RepositoryUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*RepositoryUpsertOne) Exec ¶
func (u *RepositoryUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*RepositoryUpsertOne) ExecX ¶
func (u *RepositoryUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*RepositoryUpsertOne) ID ¶
func (u *RepositoryUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*RepositoryUpsertOne) IDX ¶
func (u *RepositoryUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*RepositoryUpsertOne) Ignore ¶
func (u *RepositoryUpsertOne) Ignore() *RepositoryUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Repository.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*RepositoryUpsertOne) SetAvatarURL ¶
func (u *RepositoryUpsertOne) SetAvatarURL(v string) *RepositoryUpsertOne
SetAvatarURL sets the "avatar_url" field.
func (*RepositoryUpsertOne) SetDefaultBranch ¶
func (u *RepositoryUpsertOne) SetDefaultBranch(v string) *RepositoryUpsertOne
SetDefaultBranch sets the "default_branch" field.
func (*RepositoryUpsertOne) SetInstallID ¶
func (u *RepositoryUpsertOne) SetInstallID(v int64) *RepositoryUpsertOne
SetInstallID sets the "install_id" field.
func (*RepositoryUpsertOne) SetName ¶
func (u *RepositoryUpsertOne) SetName(v string) *RepositoryUpsertOne
SetName sets the "name" field.
func (*RepositoryUpsertOne) SetOwner ¶
func (u *RepositoryUpsertOne) SetOwner(v string) *RepositoryUpsertOne
SetOwner sets the "owner" field.
func (*RepositoryUpsertOne) SetURL ¶
func (u *RepositoryUpsertOne) SetURL(v string) *RepositoryUpsertOne
SetURL sets the "url" field.
func (*RepositoryUpsertOne) Update ¶
func (u *RepositoryUpsertOne) Update(set func(*RepositoryUpsert)) *RepositoryUpsertOne
Update allows overriding fields `UPDATE` values. See the RepositoryCreate.OnConflict documentation for more info.
func (*RepositoryUpsertOne) UpdateAvatarURL ¶
func (u *RepositoryUpsertOne) UpdateAvatarURL() *RepositoryUpsertOne
UpdateAvatarURL sets the "avatar_url" field to the value that was provided on create.
func (*RepositoryUpsertOne) UpdateDefaultBranch ¶
func (u *RepositoryUpsertOne) UpdateDefaultBranch() *RepositoryUpsertOne
UpdateDefaultBranch sets the "default_branch" field to the value that was provided on create.
func (*RepositoryUpsertOne) UpdateInstallID ¶
func (u *RepositoryUpsertOne) UpdateInstallID() *RepositoryUpsertOne
UpdateInstallID sets the "install_id" field to the value that was provided on create.
func (*RepositoryUpsertOne) UpdateName ¶
func (u *RepositoryUpsertOne) UpdateName() *RepositoryUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*RepositoryUpsertOne) UpdateNewValues ¶
func (u *RepositoryUpsertOne) UpdateNewValues() *RepositoryUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Repository.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*RepositoryUpsertOne) UpdateOwner ¶
func (u *RepositoryUpsertOne) UpdateOwner() *RepositoryUpsertOne
UpdateOwner sets the "owner" field to the value that was provided on create.
func (*RepositoryUpsertOne) UpdateURL ¶
func (u *RepositoryUpsertOne) UpdateURL() *RepositoryUpsertOne
UpdateURL sets the "url" field to the value that was provided on create.
type RollbackFunc ¶
The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.
type RollbackHook ¶
type RollbackHook func(Rollbacker) Rollbacker
RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:
hook := func(next ent.Rollbacker) ent.Rollbacker { return ent.RollbackFunc(func(context.Context, tx *ent.Tx) error { // Do some stuff before. if err := next.Rollback(ctx, tx); err != nil { return err } // Do some stuff after. return nil }) }
type Rollbacker ¶
Rollbacker is the interface that wraps the Rollbacker method.
type Scan ¶
type Scan struct { // ID of the ent. ID string `json:"id,omitempty"` // Branch holds the value of the "branch" field. Branch string `json:"branch,omitempty"` // CommitID holds the value of the "commit_id" field. CommitID string `json:"commit_id,omitempty"` // RequestedAt holds the value of the "requested_at" field. RequestedAt int64 `json:"requested_at,omitempty"` // ScannedAt holds the value of the "scanned_at" field. ScannedAt int64 `json:"scanned_at,omitempty"` // CheckID holds the value of the "check_id" field. CheckID int64 `json:"check_id,omitempty"` // PullRequestTarget holds the value of the "pull_request_target" field. PullRequestTarget string `json:"pull_request_target,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the ScanQuery when eager-loading is set. Edges ScanEdges `json:"edges"` // contains filtered or unexported fields }
Scan is the model entity for the Scan schema.
func (*Scan) QueryPackages ¶
func (s *Scan) QueryPackages() *PackageRecordQuery
QueryPackages queries the "packages" edge of the Scan entity.
func (*Scan) QueryRepository ¶
func (s *Scan) QueryRepository() *RepositoryQuery
QueryRepository queries the "repository" edge of the Scan entity.
func (*Scan) Unwrap ¶
Unwrap unwraps the Scan 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 (*Scan) Update ¶
func (s *Scan) Update() *ScanUpdateOne
Update returns a builder for updating this Scan. Note that you need to call Scan.Unwrap() before calling this method if this Scan was returned from a transaction, and the transaction was committed or rolled back.
type ScanClient ¶
type ScanClient struct {
// contains filtered or unexported fields
}
ScanClient is a client for the Scan schema.
func NewScanClient ¶
func NewScanClient(c config) *ScanClient
NewScanClient returns a client for the Scan from the given config.
func (*ScanClient) Create ¶
func (c *ScanClient) Create() *ScanCreate
Create returns a create builder for Scan.
func (*ScanClient) CreateBulk ¶
func (c *ScanClient) CreateBulk(builders ...*ScanCreate) *ScanCreateBulk
CreateBulk returns a builder for creating a bulk of Scan entities.
func (*ScanClient) Delete ¶
func (c *ScanClient) Delete() *ScanDelete
Delete returns a delete builder for Scan.
func (*ScanClient) DeleteOne ¶
func (c *ScanClient) DeleteOne(s *Scan) *ScanDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*ScanClient) DeleteOneID ¶
func (c *ScanClient) DeleteOneID(id string) *ScanDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*ScanClient) GetX ¶
func (c *ScanClient) GetX(ctx context.Context, id string) *Scan
GetX is like Get, but panics if an error occurs.
func (*ScanClient) Query ¶
func (c *ScanClient) Query() *ScanQuery
Query returns a query builder for Scan.
func (*ScanClient) QueryPackages ¶
func (c *ScanClient) QueryPackages(s *Scan) *PackageRecordQuery
QueryPackages queries the packages edge of a Scan.
func (*ScanClient) QueryRepository ¶
func (c *ScanClient) QueryRepository(s *Scan) *RepositoryQuery
QueryRepository queries the repository edge of a Scan.
func (*ScanClient) Update ¶
func (c *ScanClient) Update() *ScanUpdate
Update returns an update builder for Scan.
func (*ScanClient) UpdateOne ¶
func (c *ScanClient) UpdateOne(s *Scan) *ScanUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ScanClient) UpdateOneID ¶
func (c *ScanClient) UpdateOneID(id string) *ScanUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ScanClient) Use ¶
func (c *ScanClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `scan.Hooks(f(g(h())))`.
type ScanCreate ¶
type ScanCreate struct {
// contains filtered or unexported fields
}
ScanCreate is the builder for creating a Scan entity.
func (*ScanCreate) AddPackageIDs ¶
func (sc *ScanCreate) AddPackageIDs(ids ...int) *ScanCreate
AddPackageIDs adds the "packages" edge to the PackageRecord entity by IDs.
func (*ScanCreate) AddPackages ¶
func (sc *ScanCreate) AddPackages(p ...*PackageRecord) *ScanCreate
AddPackages adds the "packages" edges to the PackageRecord entity.
func (*ScanCreate) AddRepository ¶
func (sc *ScanCreate) AddRepository(r ...*Repository) *ScanCreate
AddRepository adds the "repository" edges to the Repository entity.
func (*ScanCreate) AddRepositoryIDs ¶
func (sc *ScanCreate) AddRepositoryIDs(ids ...int) *ScanCreate
AddRepositoryIDs adds the "repository" edge to the Repository entity by IDs.
func (*ScanCreate) Exec ¶
func (sc *ScanCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ScanCreate) ExecX ¶
func (sc *ScanCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ScanCreate) Mutation ¶
func (sc *ScanCreate) Mutation() *ScanMutation
Mutation returns the ScanMutation object of the builder.
func (*ScanCreate) OnConflict ¶
func (sc *ScanCreate) OnConflict(opts ...sql.ConflictOption) *ScanUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Scan.Create(). SetBranch(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.ScanUpsert) { SetBranch(v+v). }). Exec(ctx)
func (*ScanCreate) OnConflictColumns ¶
func (sc *ScanCreate) OnConflictColumns(columns ...string) *ScanUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Scan.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*ScanCreate) Save ¶
func (sc *ScanCreate) Save(ctx context.Context) (*Scan, error)
Save creates the Scan in the database.
func (*ScanCreate) SaveX ¶
func (sc *ScanCreate) SaveX(ctx context.Context) *Scan
SaveX calls Save and panics if Save returns an error.
func (*ScanCreate) SetBranch ¶
func (sc *ScanCreate) SetBranch(s string) *ScanCreate
SetBranch sets the "branch" field.
func (*ScanCreate) SetCheckID ¶
func (sc *ScanCreate) SetCheckID(i int64) *ScanCreate
SetCheckID sets the "check_id" field.
func (*ScanCreate) SetCommitID ¶
func (sc *ScanCreate) SetCommitID(s string) *ScanCreate
SetCommitID sets the "commit_id" field.
func (*ScanCreate) SetID ¶
func (sc *ScanCreate) SetID(s string) *ScanCreate
SetID sets the "id" field.
func (*ScanCreate) SetNillableCheckID ¶
func (sc *ScanCreate) SetNillableCheckID(i *int64) *ScanCreate
SetNillableCheckID sets the "check_id" field if the given value is not nil.
func (*ScanCreate) SetNillablePullRequestTarget ¶
func (sc *ScanCreate) SetNillablePullRequestTarget(s *string) *ScanCreate
SetNillablePullRequestTarget sets the "pull_request_target" field if the given value is not nil.
func (*ScanCreate) SetPullRequestTarget ¶
func (sc *ScanCreate) SetPullRequestTarget(s string) *ScanCreate
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanCreate) SetRequestedAt ¶
func (sc *ScanCreate) SetRequestedAt(i int64) *ScanCreate
SetRequestedAt sets the "requested_at" field.
func (*ScanCreate) SetScannedAt ¶
func (sc *ScanCreate) SetScannedAt(i int64) *ScanCreate
SetScannedAt sets the "scanned_at" field.
type ScanCreateBulk ¶
type ScanCreateBulk struct {
// contains filtered or unexported fields
}
ScanCreateBulk is the builder for creating many Scan entities in bulk.
func (*ScanCreateBulk) Exec ¶
func (scb *ScanCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ScanCreateBulk) ExecX ¶
func (scb *ScanCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ScanCreateBulk) OnConflict ¶
func (scb *ScanCreateBulk) OnConflict(opts ...sql.ConflictOption) *ScanUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Scan.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.ScanUpsert) { SetBranch(v+v). }). Exec(ctx)
func (*ScanCreateBulk) OnConflictColumns ¶
func (scb *ScanCreateBulk) OnConflictColumns(columns ...string) *ScanUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Scan.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type ScanDelete ¶
type ScanDelete struct {
// contains filtered or unexported fields
}
ScanDelete is the builder for deleting a Scan entity.
func (*ScanDelete) Exec ¶
func (sd *ScanDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ScanDelete) ExecX ¶
func (sd *ScanDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ScanDelete) Where ¶
func (sd *ScanDelete) Where(ps ...predicate.Scan) *ScanDelete
Where appends a list predicates to the ScanDelete builder.
type ScanDeleteOne ¶
type ScanDeleteOne struct {
// contains filtered or unexported fields
}
ScanDeleteOne is the builder for deleting a single Scan entity.
func (*ScanDeleteOne) Exec ¶
func (sdo *ScanDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ScanDeleteOne) ExecX ¶
func (sdo *ScanDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type ScanEdges ¶
type ScanEdges struct { // Repository holds the value of the repository edge. Repository []*Repository `json:"repository,omitempty"` // Packages holds the value of the packages edge. Packages []*PackageRecord `json:"packages,omitempty"` // contains filtered or unexported fields }
ScanEdges holds the relations/edges for other nodes in the graph.
func (ScanEdges) PackagesOrErr ¶
func (e ScanEdges) PackagesOrErr() ([]*PackageRecord, error)
PackagesOrErr returns the Packages value or an error if the edge was not loaded in eager-loading.
func (ScanEdges) RepositoryOrErr ¶
func (e ScanEdges) RepositoryOrErr() ([]*Repository, error)
RepositoryOrErr returns the Repository value or an error if the edge was not loaded in eager-loading.
type ScanGroupBy ¶
type ScanGroupBy struct {
// contains filtered or unexported fields
}
ScanGroupBy is the group-by builder for Scan entities.
func (*ScanGroupBy) Aggregate ¶
func (sgb *ScanGroupBy) Aggregate(fns ...AggregateFunc) *ScanGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ScanGroupBy) Bool ¶
func (sgb *ScanGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) BoolX ¶
func (sgb *ScanGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*ScanGroupBy) Bools ¶
func (sgb *ScanGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) BoolsX ¶
func (sgb *ScanGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*ScanGroupBy) Float64 ¶
func (sgb *ScanGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) Float64X ¶
func (sgb *ScanGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*ScanGroupBy) Float64s ¶
func (sgb *ScanGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) Float64sX ¶
func (sgb *ScanGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*ScanGroupBy) Int ¶
func (sgb *ScanGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) IntX ¶
func (sgb *ScanGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*ScanGroupBy) Ints ¶
func (sgb *ScanGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) IntsX ¶
func (sgb *ScanGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*ScanGroupBy) Scan ¶
func (sgb *ScanGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*ScanGroupBy) ScanX ¶
func (sgb *ScanGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*ScanGroupBy) String ¶
func (sgb *ScanGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*ScanGroupBy) StringX ¶
func (sgb *ScanGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type ScanMutation ¶
type ScanMutation struct {
// contains filtered or unexported fields
}
ScanMutation represents an operation that mutates the Scan nodes in the graph.
func (*ScanMutation) AddCheckID ¶
func (m *ScanMutation) AddCheckID(i int64)
AddCheckID adds i to the "check_id" field.
func (*ScanMutation) AddField ¶
func (m *ScanMutation) 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 (*ScanMutation) AddPackageIDs ¶
func (m *ScanMutation) AddPackageIDs(ids ...int)
AddPackageIDs adds the "packages" edge to the PackageRecord entity by ids.
func (*ScanMutation) AddRepositoryIDs ¶
func (m *ScanMutation) AddRepositoryIDs(ids ...int)
AddRepositoryIDs adds the "repository" edge to the Repository entity by ids.
func (*ScanMutation) AddRequestedAt ¶
func (m *ScanMutation) AddRequestedAt(i int64)
AddRequestedAt adds i to the "requested_at" field.
func (*ScanMutation) AddScannedAt ¶
func (m *ScanMutation) AddScannedAt(i int64)
AddScannedAt adds i to the "scanned_at" field.
func (*ScanMutation) AddedCheckID ¶
func (m *ScanMutation) AddedCheckID() (r int64, exists bool)
AddedCheckID returns the value that was added to the "check_id" field in this mutation.
func (*ScanMutation) AddedEdges ¶
func (m *ScanMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ScanMutation) AddedField ¶
func (m *ScanMutation) 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 (*ScanMutation) AddedFields ¶
func (m *ScanMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ScanMutation) AddedIDs ¶
func (m *ScanMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ScanMutation) AddedRequestedAt ¶
func (m *ScanMutation) AddedRequestedAt() (r int64, exists bool)
AddedRequestedAt returns the value that was added to the "requested_at" field in this mutation.
func (*ScanMutation) AddedScannedAt ¶
func (m *ScanMutation) AddedScannedAt() (r int64, exists bool)
AddedScannedAt returns the value that was added to the "scanned_at" field in this mutation.
func (*ScanMutation) Branch ¶
func (m *ScanMutation) Branch() (r string, exists bool)
Branch returns the value of the "branch" field in the mutation.
func (*ScanMutation) CheckID ¶
func (m *ScanMutation) CheckID() (r int64, exists bool)
CheckID returns the value of the "check_id" field in the mutation.
func (*ScanMutation) CheckIDCleared ¶
func (m *ScanMutation) CheckIDCleared() bool
CheckIDCleared returns if the "check_id" field was cleared in this mutation.
func (*ScanMutation) ClearCheckID ¶
func (m *ScanMutation) ClearCheckID()
ClearCheckID clears the value of the "check_id" field.
func (*ScanMutation) ClearEdge ¶
func (m *ScanMutation) 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 (*ScanMutation) ClearField ¶
func (m *ScanMutation) 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 (*ScanMutation) ClearPackages ¶
func (m *ScanMutation) ClearPackages()
ClearPackages clears the "packages" edge to the PackageRecord entity.
func (*ScanMutation) ClearPullRequestTarget ¶
func (m *ScanMutation) ClearPullRequestTarget()
ClearPullRequestTarget clears the value of the "pull_request_target" field.
func (*ScanMutation) ClearRepository ¶
func (m *ScanMutation) ClearRepository()
ClearRepository clears the "repository" edge to the Repository entity.
func (*ScanMutation) ClearedEdges ¶
func (m *ScanMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ScanMutation) ClearedFields ¶
func (m *ScanMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ScanMutation) Client ¶
func (m ScanMutation) 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 (*ScanMutation) CommitID ¶
func (m *ScanMutation) CommitID() (r string, exists bool)
CommitID returns the value of the "commit_id" field in the mutation.
func (*ScanMutation) EdgeCleared ¶
func (m *ScanMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ScanMutation) Field ¶
func (m *ScanMutation) 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 (*ScanMutation) FieldCleared ¶
func (m *ScanMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ScanMutation) Fields ¶
func (m *ScanMutation) 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 (*ScanMutation) ID ¶
func (m *ScanMutation) 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 (*ScanMutation) OldBranch ¶
func (m *ScanMutation) OldBranch(ctx context.Context) (v string, err error)
OldBranch returns the old "branch" field's value of the Scan entity. If the Scan 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 (*ScanMutation) OldCheckID ¶
func (m *ScanMutation) OldCheckID(ctx context.Context) (v int64, err error)
OldCheckID returns the old "check_id" field's value of the Scan entity. If the Scan 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 (*ScanMutation) OldCommitID ¶
func (m *ScanMutation) OldCommitID(ctx context.Context) (v string, err error)
OldCommitID returns the old "commit_id" field's value of the Scan entity. If the Scan 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 (*ScanMutation) 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 (*ScanMutation) OldPullRequestTarget ¶
func (m *ScanMutation) OldPullRequestTarget(ctx context.Context) (v string, err error)
OldPullRequestTarget returns the old "pull_request_target" field's value of the Scan entity. If the Scan 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 (*ScanMutation) OldRequestedAt ¶
func (m *ScanMutation) OldRequestedAt(ctx context.Context) (v int64, err error)
OldRequestedAt returns the old "requested_at" field's value of the Scan entity. If the Scan 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 (*ScanMutation) OldScannedAt ¶
func (m *ScanMutation) OldScannedAt(ctx context.Context) (v int64, err error)
OldScannedAt returns the old "scanned_at" field's value of the Scan entity. If the Scan 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 (*ScanMutation) PackagesCleared ¶
func (m *ScanMutation) PackagesCleared() bool
PackagesCleared reports if the "packages" edge to the PackageRecord entity was cleared.
func (*ScanMutation) PackagesIDs ¶
func (m *ScanMutation) PackagesIDs() (ids []int)
PackagesIDs returns the "packages" edge IDs in the mutation.
func (*ScanMutation) PullRequestTarget ¶
func (m *ScanMutation) PullRequestTarget() (r string, exists bool)
PullRequestTarget returns the value of the "pull_request_target" field in the mutation.
func (*ScanMutation) PullRequestTargetCleared ¶
func (m *ScanMutation) PullRequestTargetCleared() bool
PullRequestTargetCleared returns if the "pull_request_target" field was cleared in this mutation.
func (*ScanMutation) RemovePackageIDs ¶
func (m *ScanMutation) RemovePackageIDs(ids ...int)
RemovePackageIDs removes the "packages" edge to the PackageRecord entity by IDs.
func (*ScanMutation) RemoveRepositoryIDs ¶
func (m *ScanMutation) RemoveRepositoryIDs(ids ...int)
RemoveRepositoryIDs removes the "repository" edge to the Repository entity by IDs.
func (*ScanMutation) RemovedEdges ¶
func (m *ScanMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ScanMutation) RemovedIDs ¶
func (m *ScanMutation) 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 (*ScanMutation) RemovedPackagesIDs ¶
func (m *ScanMutation) RemovedPackagesIDs() (ids []int)
RemovedPackages returns the removed IDs of the "packages" edge to the PackageRecord entity.
func (*ScanMutation) RemovedRepositoryIDs ¶
func (m *ScanMutation) RemovedRepositoryIDs() (ids []int)
RemovedRepository returns the removed IDs of the "repository" edge to the Repository entity.
func (*ScanMutation) RepositoryCleared ¶
func (m *ScanMutation) RepositoryCleared() bool
RepositoryCleared reports if the "repository" edge to the Repository entity was cleared.
func (*ScanMutation) RepositoryIDs ¶
func (m *ScanMutation) RepositoryIDs() (ids []int)
RepositoryIDs returns the "repository" edge IDs in the mutation.
func (*ScanMutation) RequestedAt ¶
func (m *ScanMutation) RequestedAt() (r int64, exists bool)
RequestedAt returns the value of the "requested_at" field in the mutation.
func (*ScanMutation) ResetBranch ¶
func (m *ScanMutation) ResetBranch()
ResetBranch resets all changes to the "branch" field.
func (*ScanMutation) ResetCheckID ¶
func (m *ScanMutation) ResetCheckID()
ResetCheckID resets all changes to the "check_id" field.
func (*ScanMutation) ResetCommitID ¶
func (m *ScanMutation) ResetCommitID()
ResetCommitID resets all changes to the "commit_id" field.
func (*ScanMutation) ResetEdge ¶
func (m *ScanMutation) 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 (*ScanMutation) ResetField ¶
func (m *ScanMutation) 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 (*ScanMutation) ResetPackages ¶
func (m *ScanMutation) ResetPackages()
ResetPackages resets all changes to the "packages" edge.
func (*ScanMutation) ResetPullRequestTarget ¶
func (m *ScanMutation) ResetPullRequestTarget()
ResetPullRequestTarget resets all changes to the "pull_request_target" field.
func (*ScanMutation) ResetRepository ¶
func (m *ScanMutation) ResetRepository()
ResetRepository resets all changes to the "repository" edge.
func (*ScanMutation) ResetRequestedAt ¶
func (m *ScanMutation) ResetRequestedAt()
ResetRequestedAt resets all changes to the "requested_at" field.
func (*ScanMutation) ResetScannedAt ¶
func (m *ScanMutation) ResetScannedAt()
ResetScannedAt resets all changes to the "scanned_at" field.
func (*ScanMutation) ScannedAt ¶
func (m *ScanMutation) ScannedAt() (r int64, exists bool)
ScannedAt returns the value of the "scanned_at" field in the mutation.
func (*ScanMutation) SetBranch ¶
func (m *ScanMutation) SetBranch(s string)
SetBranch sets the "branch" field.
func (*ScanMutation) SetCheckID ¶
func (m *ScanMutation) SetCheckID(i int64)
SetCheckID sets the "check_id" field.
func (*ScanMutation) SetCommitID ¶
func (m *ScanMutation) SetCommitID(s string)
SetCommitID sets the "commit_id" field.
func (*ScanMutation) SetField ¶
func (m *ScanMutation) 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 (*ScanMutation) SetID ¶
func (m *ScanMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Scan entities.
func (*ScanMutation) SetPullRequestTarget ¶
func (m *ScanMutation) SetPullRequestTarget(s string)
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanMutation) SetRequestedAt ¶
func (m *ScanMutation) SetRequestedAt(i int64)
SetRequestedAt sets the "requested_at" field.
func (*ScanMutation) SetScannedAt ¶
func (m *ScanMutation) SetScannedAt(i int64)
SetScannedAt sets the "scanned_at" field.
func (ScanMutation) Tx ¶
func (m ScanMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ScanMutation) Type ¶
func (m *ScanMutation) Type() string
Type returns the node type of this mutation (Scan).
func (*ScanMutation) Where ¶
func (m *ScanMutation) Where(ps ...predicate.Scan)
Where appends a list predicates to the ScanMutation builder.
type ScanQuery ¶
type ScanQuery struct {
// contains filtered or unexported fields
}
ScanQuery is the builder for querying Scan entities.
func (*ScanQuery) Clone ¶
Clone returns a duplicate of the ScanQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ScanQuery) First ¶
First returns the first Scan entity from the query. Returns a *NotFoundError when no Scan was found.
func (*ScanQuery) FirstID ¶
FirstID returns the first Scan ID from the query. Returns a *NotFoundError when no Scan ID was found.
func (*ScanQuery) GroupBy ¶
func (sq *ScanQuery) GroupBy(field string, fields ...string) *ScanGroupBy
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 { Branch string `json:"branch,omitempty"` Count int `json:"count,omitempty"` } client.Scan.Query(). GroupBy(scan.FieldBranch). Aggregate(ent.Count()). Scan(ctx, &v)
func (*ScanQuery) Only ¶
Only returns a single Scan entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one Scan entity is not found. Returns a *NotFoundError when no Scan entities are found.
func (*ScanQuery) OnlyID ¶
OnlyID is like Only, but returns the only Scan ID in the query. Returns a *NotSingularError when exactly one Scan ID is not found. Returns a *NotFoundError when no entities are found.
func (*ScanQuery) QueryPackages ¶
func (sq *ScanQuery) QueryPackages() *PackageRecordQuery
QueryPackages chains the current query on the "packages" edge.
func (*ScanQuery) QueryRepository ¶
func (sq *ScanQuery) QueryRepository() *RepositoryQuery
QueryRepository chains the current query on the "repository" edge.
func (*ScanQuery) Select ¶
func (sq *ScanQuery) Select(fields ...string) *ScanSelect
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 { Branch string `json:"branch,omitempty"` } client.Scan.Query(). Select(scan.FieldBranch). Scan(ctx, &v)
func (*ScanQuery) 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 (*ScanQuery) WithPackages ¶
func (sq *ScanQuery) WithPackages(opts ...func(*PackageRecordQuery)) *ScanQuery
WithPackages tells the query-builder to eager-load the nodes that are connected to the "packages" edge. The optional arguments are used to configure the query builder of the edge.
func (*ScanQuery) WithRepository ¶
func (sq *ScanQuery) WithRepository(opts ...func(*RepositoryQuery)) *ScanQuery
WithRepository tells the query-builder to eager-load the nodes that are connected to the "repository" edge. The optional arguments are used to configure the query builder of the edge.
type ScanSelect ¶
type ScanSelect struct { *ScanQuery // contains filtered or unexported fields }
ScanSelect is the builder for selecting fields of Scan entities.
func (*ScanSelect) Bool ¶
func (ss *ScanSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ScanSelect) BoolX ¶
func (ss *ScanSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*ScanSelect) Bools ¶
func (ss *ScanSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ScanSelect) BoolsX ¶
func (ss *ScanSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*ScanSelect) Float64 ¶
func (ss *ScanSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ScanSelect) Float64X ¶
func (ss *ScanSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*ScanSelect) Float64s ¶
func (ss *ScanSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ScanSelect) Float64sX ¶
func (ss *ScanSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*ScanSelect) Int ¶
func (ss *ScanSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ScanSelect) IntX ¶
func (ss *ScanSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*ScanSelect) Ints ¶
func (ss *ScanSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ScanSelect) IntsX ¶
func (ss *ScanSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*ScanSelect) Scan ¶
func (ss *ScanSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*ScanSelect) ScanX ¶
func (ss *ScanSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*ScanSelect) String ¶
func (ss *ScanSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*ScanSelect) StringX ¶
func (ss *ScanSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type ScanUpdate ¶
type ScanUpdate struct {
// contains filtered or unexported fields
}
ScanUpdate is the builder for updating Scan entities.
func (*ScanUpdate) AddCheckID ¶
func (su *ScanUpdate) AddCheckID(i int64) *ScanUpdate
AddCheckID adds i to the "check_id" field.
func (*ScanUpdate) AddPackageIDs ¶
func (su *ScanUpdate) AddPackageIDs(ids ...int) *ScanUpdate
AddPackageIDs adds the "packages" edge to the PackageRecord entity by IDs.
func (*ScanUpdate) AddPackages ¶
func (su *ScanUpdate) AddPackages(p ...*PackageRecord) *ScanUpdate
AddPackages adds the "packages" edges to the PackageRecord entity.
func (*ScanUpdate) AddRepository ¶
func (su *ScanUpdate) AddRepository(r ...*Repository) *ScanUpdate
AddRepository adds the "repository" edges to the Repository entity.
func (*ScanUpdate) AddRepositoryIDs ¶
func (su *ScanUpdate) AddRepositoryIDs(ids ...int) *ScanUpdate
AddRepositoryIDs adds the "repository" edge to the Repository entity by IDs.
func (*ScanUpdate) AddRequestedAt ¶
func (su *ScanUpdate) AddRequestedAt(i int64) *ScanUpdate
AddRequestedAt adds i to the "requested_at" field.
func (*ScanUpdate) AddScannedAt ¶
func (su *ScanUpdate) AddScannedAt(i int64) *ScanUpdate
AddScannedAt adds i to the "scanned_at" field.
func (*ScanUpdate) ClearCheckID ¶
func (su *ScanUpdate) ClearCheckID() *ScanUpdate
ClearCheckID clears the value of the "check_id" field.
func (*ScanUpdate) ClearPackages ¶
func (su *ScanUpdate) ClearPackages() *ScanUpdate
ClearPackages clears all "packages" edges to the PackageRecord entity.
func (*ScanUpdate) ClearPullRequestTarget ¶
func (su *ScanUpdate) ClearPullRequestTarget() *ScanUpdate
ClearPullRequestTarget clears the value of the "pull_request_target" field.
func (*ScanUpdate) ClearRepository ¶
func (su *ScanUpdate) ClearRepository() *ScanUpdate
ClearRepository clears all "repository" edges to the Repository entity.
func (*ScanUpdate) Exec ¶
func (su *ScanUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ScanUpdate) ExecX ¶
func (su *ScanUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ScanUpdate) Mutation ¶
func (su *ScanUpdate) Mutation() *ScanMutation
Mutation returns the ScanMutation object of the builder.
func (*ScanUpdate) RemovePackageIDs ¶
func (su *ScanUpdate) RemovePackageIDs(ids ...int) *ScanUpdate
RemovePackageIDs removes the "packages" edge to PackageRecord entities by IDs.
func (*ScanUpdate) RemovePackages ¶
func (su *ScanUpdate) RemovePackages(p ...*PackageRecord) *ScanUpdate
RemovePackages removes "packages" edges to PackageRecord entities.
func (*ScanUpdate) RemoveRepository ¶
func (su *ScanUpdate) RemoveRepository(r ...*Repository) *ScanUpdate
RemoveRepository removes "repository" edges to Repository entities.
func (*ScanUpdate) RemoveRepositoryIDs ¶
func (su *ScanUpdate) RemoveRepositoryIDs(ids ...int) *ScanUpdate
RemoveRepositoryIDs removes the "repository" edge to Repository entities by IDs.
func (*ScanUpdate) Save ¶
func (su *ScanUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ScanUpdate) SaveX ¶
func (su *ScanUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ScanUpdate) SetCheckID ¶
func (su *ScanUpdate) SetCheckID(i int64) *ScanUpdate
SetCheckID sets the "check_id" field.
func (*ScanUpdate) SetNillableCheckID ¶
func (su *ScanUpdate) SetNillableCheckID(i *int64) *ScanUpdate
SetNillableCheckID sets the "check_id" field if the given value is not nil.
func (*ScanUpdate) SetNillablePullRequestTarget ¶
func (su *ScanUpdate) SetNillablePullRequestTarget(s *string) *ScanUpdate
SetNillablePullRequestTarget sets the "pull_request_target" field if the given value is not nil.
func (*ScanUpdate) SetPullRequestTarget ¶
func (su *ScanUpdate) SetPullRequestTarget(s string) *ScanUpdate
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanUpdate) SetRequestedAt ¶
func (su *ScanUpdate) SetRequestedAt(i int64) *ScanUpdate
SetRequestedAt sets the "requested_at" field.
func (*ScanUpdate) SetScannedAt ¶
func (su *ScanUpdate) SetScannedAt(i int64) *ScanUpdate
SetScannedAt sets the "scanned_at" field.
func (*ScanUpdate) Where ¶
func (su *ScanUpdate) Where(ps ...predicate.Scan) *ScanUpdate
Where appends a list predicates to the ScanUpdate builder.
type ScanUpdateOne ¶
type ScanUpdateOne struct {
// contains filtered or unexported fields
}
ScanUpdateOne is the builder for updating a single Scan entity.
func (*ScanUpdateOne) AddCheckID ¶
func (suo *ScanUpdateOne) AddCheckID(i int64) *ScanUpdateOne
AddCheckID adds i to the "check_id" field.
func (*ScanUpdateOne) AddPackageIDs ¶
func (suo *ScanUpdateOne) AddPackageIDs(ids ...int) *ScanUpdateOne
AddPackageIDs adds the "packages" edge to the PackageRecord entity by IDs.
func (*ScanUpdateOne) AddPackages ¶
func (suo *ScanUpdateOne) AddPackages(p ...*PackageRecord) *ScanUpdateOne
AddPackages adds the "packages" edges to the PackageRecord entity.
func (*ScanUpdateOne) AddRepository ¶
func (suo *ScanUpdateOne) AddRepository(r ...*Repository) *ScanUpdateOne
AddRepository adds the "repository" edges to the Repository entity.
func (*ScanUpdateOne) AddRepositoryIDs ¶
func (suo *ScanUpdateOne) AddRepositoryIDs(ids ...int) *ScanUpdateOne
AddRepositoryIDs adds the "repository" edge to the Repository entity by IDs.
func (*ScanUpdateOne) AddRequestedAt ¶
func (suo *ScanUpdateOne) AddRequestedAt(i int64) *ScanUpdateOne
AddRequestedAt adds i to the "requested_at" field.
func (*ScanUpdateOne) AddScannedAt ¶
func (suo *ScanUpdateOne) AddScannedAt(i int64) *ScanUpdateOne
AddScannedAt adds i to the "scanned_at" field.
func (*ScanUpdateOne) ClearCheckID ¶
func (suo *ScanUpdateOne) ClearCheckID() *ScanUpdateOne
ClearCheckID clears the value of the "check_id" field.
func (*ScanUpdateOne) ClearPackages ¶
func (suo *ScanUpdateOne) ClearPackages() *ScanUpdateOne
ClearPackages clears all "packages" edges to the PackageRecord entity.
func (*ScanUpdateOne) ClearPullRequestTarget ¶
func (suo *ScanUpdateOne) ClearPullRequestTarget() *ScanUpdateOne
ClearPullRequestTarget clears the value of the "pull_request_target" field.
func (*ScanUpdateOne) ClearRepository ¶
func (suo *ScanUpdateOne) ClearRepository() *ScanUpdateOne
ClearRepository clears all "repository" edges to the Repository entity.
func (*ScanUpdateOne) Exec ¶
func (suo *ScanUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ScanUpdateOne) ExecX ¶
func (suo *ScanUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ScanUpdateOne) Mutation ¶
func (suo *ScanUpdateOne) Mutation() *ScanMutation
Mutation returns the ScanMutation object of the builder.
func (*ScanUpdateOne) RemovePackageIDs ¶
func (suo *ScanUpdateOne) RemovePackageIDs(ids ...int) *ScanUpdateOne
RemovePackageIDs removes the "packages" edge to PackageRecord entities by IDs.
func (*ScanUpdateOne) RemovePackages ¶
func (suo *ScanUpdateOne) RemovePackages(p ...*PackageRecord) *ScanUpdateOne
RemovePackages removes "packages" edges to PackageRecord entities.
func (*ScanUpdateOne) RemoveRepository ¶
func (suo *ScanUpdateOne) RemoveRepository(r ...*Repository) *ScanUpdateOne
RemoveRepository removes "repository" edges to Repository entities.
func (*ScanUpdateOne) RemoveRepositoryIDs ¶
func (suo *ScanUpdateOne) RemoveRepositoryIDs(ids ...int) *ScanUpdateOne
RemoveRepositoryIDs removes the "repository" edge to Repository entities by IDs.
func (*ScanUpdateOne) Save ¶
func (suo *ScanUpdateOne) Save(ctx context.Context) (*Scan, error)
Save executes the query and returns the updated Scan entity.
func (*ScanUpdateOne) SaveX ¶
func (suo *ScanUpdateOne) SaveX(ctx context.Context) *Scan
SaveX is like Save, but panics if an error occurs.
func (*ScanUpdateOne) Select ¶
func (suo *ScanUpdateOne) Select(field string, fields ...string) *ScanUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ScanUpdateOne) SetCheckID ¶
func (suo *ScanUpdateOne) SetCheckID(i int64) *ScanUpdateOne
SetCheckID sets the "check_id" field.
func (*ScanUpdateOne) SetNillableCheckID ¶
func (suo *ScanUpdateOne) SetNillableCheckID(i *int64) *ScanUpdateOne
SetNillableCheckID sets the "check_id" field if the given value is not nil.
func (*ScanUpdateOne) SetNillablePullRequestTarget ¶
func (suo *ScanUpdateOne) SetNillablePullRequestTarget(s *string) *ScanUpdateOne
SetNillablePullRequestTarget sets the "pull_request_target" field if the given value is not nil.
func (*ScanUpdateOne) SetPullRequestTarget ¶
func (suo *ScanUpdateOne) SetPullRequestTarget(s string) *ScanUpdateOne
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanUpdateOne) SetRequestedAt ¶
func (suo *ScanUpdateOne) SetRequestedAt(i int64) *ScanUpdateOne
SetRequestedAt sets the "requested_at" field.
func (*ScanUpdateOne) SetScannedAt ¶
func (suo *ScanUpdateOne) SetScannedAt(i int64) *ScanUpdateOne
SetScannedAt sets the "scanned_at" field.
type ScanUpsert ¶
ScanUpsert is the "OnConflict" setter.
func (*ScanUpsert) ClearCheckID ¶
func (u *ScanUpsert) ClearCheckID() *ScanUpsert
ClearCheckID clears the value of the "check_id" field.
func (*ScanUpsert) ClearPullRequestTarget ¶
func (u *ScanUpsert) ClearPullRequestTarget() *ScanUpsert
ClearPullRequestTarget clears the value of the "pull_request_target" field.
func (*ScanUpsert) SetBranch ¶
func (u *ScanUpsert) SetBranch(v string) *ScanUpsert
SetBranch sets the "branch" field.
func (*ScanUpsert) SetCheckID ¶
func (u *ScanUpsert) SetCheckID(v int64) *ScanUpsert
SetCheckID sets the "check_id" field.
func (*ScanUpsert) SetCommitID ¶
func (u *ScanUpsert) SetCommitID(v string) *ScanUpsert
SetCommitID sets the "commit_id" field.
func (*ScanUpsert) SetPullRequestTarget ¶
func (u *ScanUpsert) SetPullRequestTarget(v string) *ScanUpsert
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanUpsert) SetRequestedAt ¶
func (u *ScanUpsert) SetRequestedAt(v int64) *ScanUpsert
SetRequestedAt sets the "requested_at" field.
func (*ScanUpsert) SetScannedAt ¶
func (u *ScanUpsert) SetScannedAt(v int64) *ScanUpsert
SetScannedAt sets the "scanned_at" field.
func (*ScanUpsert) UpdateBranch ¶
func (u *ScanUpsert) UpdateBranch() *ScanUpsert
UpdateBranch sets the "branch" field to the value that was provided on create.
func (*ScanUpsert) UpdateCheckID ¶
func (u *ScanUpsert) UpdateCheckID() *ScanUpsert
UpdateCheckID sets the "check_id" field to the value that was provided on create.
func (*ScanUpsert) UpdateCommitID ¶
func (u *ScanUpsert) UpdateCommitID() *ScanUpsert
UpdateCommitID sets the "commit_id" field to the value that was provided on create.
func (*ScanUpsert) UpdatePullRequestTarget ¶
func (u *ScanUpsert) UpdatePullRequestTarget() *ScanUpsert
UpdatePullRequestTarget sets the "pull_request_target" field to the value that was provided on create.
func (*ScanUpsert) UpdateRequestedAt ¶
func (u *ScanUpsert) UpdateRequestedAt() *ScanUpsert
UpdateRequestedAt sets the "requested_at" field to the value that was provided on create.
func (*ScanUpsert) UpdateScannedAt ¶
func (u *ScanUpsert) UpdateScannedAt() *ScanUpsert
UpdateScannedAt sets the "scanned_at" field to the value that was provided on create.
type ScanUpsertBulk ¶
type ScanUpsertBulk struct {
// contains filtered or unexported fields
}
ScanUpsertBulk is the builder for "upsert"-ing a bulk of Scan nodes.
func (*ScanUpsertBulk) ClearCheckID ¶
func (u *ScanUpsertBulk) ClearCheckID() *ScanUpsertBulk
ClearCheckID clears the value of the "check_id" field.
func (*ScanUpsertBulk) ClearPullRequestTarget ¶
func (u *ScanUpsertBulk) ClearPullRequestTarget() *ScanUpsertBulk
ClearPullRequestTarget clears the value of the "pull_request_target" field.
func (*ScanUpsertBulk) DoNothing ¶
func (u *ScanUpsertBulk) DoNothing() *ScanUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ScanUpsertBulk) Exec ¶
func (u *ScanUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ScanUpsertBulk) ExecX ¶
func (u *ScanUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ScanUpsertBulk) Ignore ¶
func (u *ScanUpsertBulk) Ignore() *ScanUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Scan.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ScanUpsertBulk) SetBranch ¶
func (u *ScanUpsertBulk) SetBranch(v string) *ScanUpsertBulk
SetBranch sets the "branch" field.
func (*ScanUpsertBulk) SetCheckID ¶
func (u *ScanUpsertBulk) SetCheckID(v int64) *ScanUpsertBulk
SetCheckID sets the "check_id" field.
func (*ScanUpsertBulk) SetCommitID ¶
func (u *ScanUpsertBulk) SetCommitID(v string) *ScanUpsertBulk
SetCommitID sets the "commit_id" field.
func (*ScanUpsertBulk) SetPullRequestTarget ¶
func (u *ScanUpsertBulk) SetPullRequestTarget(v string) *ScanUpsertBulk
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanUpsertBulk) SetRequestedAt ¶
func (u *ScanUpsertBulk) SetRequestedAt(v int64) *ScanUpsertBulk
SetRequestedAt sets the "requested_at" field.
func (*ScanUpsertBulk) SetScannedAt ¶
func (u *ScanUpsertBulk) SetScannedAt(v int64) *ScanUpsertBulk
SetScannedAt sets the "scanned_at" field.
func (*ScanUpsertBulk) Update ¶
func (u *ScanUpsertBulk) Update(set func(*ScanUpsert)) *ScanUpsertBulk
Update allows overriding fields `UPDATE` values. See the ScanCreateBulk.OnConflict documentation for more info.
func (*ScanUpsertBulk) UpdateBranch ¶
func (u *ScanUpsertBulk) UpdateBranch() *ScanUpsertBulk
UpdateBranch sets the "branch" field to the value that was provided on create.
func (*ScanUpsertBulk) UpdateCheckID ¶
func (u *ScanUpsertBulk) UpdateCheckID() *ScanUpsertBulk
UpdateCheckID sets the "check_id" field to the value that was provided on create.
func (*ScanUpsertBulk) UpdateCommitID ¶
func (u *ScanUpsertBulk) UpdateCommitID() *ScanUpsertBulk
UpdateCommitID sets the "commit_id" field to the value that was provided on create.
func (*ScanUpsertBulk) UpdateNewValues ¶
func (u *ScanUpsertBulk) UpdateNewValues() *ScanUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Scan.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*ScanUpsertBulk) UpdatePullRequestTarget ¶
func (u *ScanUpsertBulk) UpdatePullRequestTarget() *ScanUpsertBulk
UpdatePullRequestTarget sets the "pull_request_target" field to the value that was provided on create.
func (*ScanUpsertBulk) UpdateRequestedAt ¶
func (u *ScanUpsertBulk) UpdateRequestedAt() *ScanUpsertBulk
UpdateRequestedAt sets the "requested_at" field to the value that was provided on create.
func (*ScanUpsertBulk) UpdateScannedAt ¶
func (u *ScanUpsertBulk) UpdateScannedAt() *ScanUpsertBulk
UpdateScannedAt sets the "scanned_at" field to the value that was provided on create.
type ScanUpsertOne ¶
type ScanUpsertOne struct {
// contains filtered or unexported fields
}
ScanUpsertOne is the builder for "upsert"-ing
one Scan node.
func (*ScanUpsertOne) ClearCheckID ¶
func (u *ScanUpsertOne) ClearCheckID() *ScanUpsertOne
ClearCheckID clears the value of the "check_id" field.
func (*ScanUpsertOne) ClearPullRequestTarget ¶
func (u *ScanUpsertOne) ClearPullRequestTarget() *ScanUpsertOne
ClearPullRequestTarget clears the value of the "pull_request_target" field.
func (*ScanUpsertOne) DoNothing ¶
func (u *ScanUpsertOne) DoNothing() *ScanUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*ScanUpsertOne) Exec ¶
func (u *ScanUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*ScanUpsertOne) ExecX ¶
func (u *ScanUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ScanUpsertOne) ID ¶
func (u *ScanUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*ScanUpsertOne) IDX ¶
func (u *ScanUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*ScanUpsertOne) Ignore ¶
func (u *ScanUpsertOne) Ignore() *ScanUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Scan.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*ScanUpsertOne) SetBranch ¶
func (u *ScanUpsertOne) SetBranch(v string) *ScanUpsertOne
SetBranch sets the "branch" field.
func (*ScanUpsertOne) SetCheckID ¶
func (u *ScanUpsertOne) SetCheckID(v int64) *ScanUpsertOne
SetCheckID sets the "check_id" field.
func (*ScanUpsertOne) SetCommitID ¶
func (u *ScanUpsertOne) SetCommitID(v string) *ScanUpsertOne
SetCommitID sets the "commit_id" field.
func (*ScanUpsertOne) SetPullRequestTarget ¶
func (u *ScanUpsertOne) SetPullRequestTarget(v string) *ScanUpsertOne
SetPullRequestTarget sets the "pull_request_target" field.
func (*ScanUpsertOne) SetRequestedAt ¶
func (u *ScanUpsertOne) SetRequestedAt(v int64) *ScanUpsertOne
SetRequestedAt sets the "requested_at" field.
func (*ScanUpsertOne) SetScannedAt ¶
func (u *ScanUpsertOne) SetScannedAt(v int64) *ScanUpsertOne
SetScannedAt sets the "scanned_at" field.
func (*ScanUpsertOne) Update ¶
func (u *ScanUpsertOne) Update(set func(*ScanUpsert)) *ScanUpsertOne
Update allows overriding fields `UPDATE` values. See the ScanCreate.OnConflict documentation for more info.
func (*ScanUpsertOne) UpdateBranch ¶
func (u *ScanUpsertOne) UpdateBranch() *ScanUpsertOne
UpdateBranch sets the "branch" field to the value that was provided on create.
func (*ScanUpsertOne) UpdateCheckID ¶
func (u *ScanUpsertOne) UpdateCheckID() *ScanUpsertOne
UpdateCheckID sets the "check_id" field to the value that was provided on create.
func (*ScanUpsertOne) UpdateCommitID ¶
func (u *ScanUpsertOne) UpdateCommitID() *ScanUpsertOne
UpdateCommitID sets the "commit_id" field to the value that was provided on create.
func (*ScanUpsertOne) UpdateNewValues ¶
func (u *ScanUpsertOne) UpdateNewValues() *ScanUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Scan.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*ScanUpsertOne) UpdatePullRequestTarget ¶
func (u *ScanUpsertOne) UpdatePullRequestTarget() *ScanUpsertOne
UpdatePullRequestTarget sets the "pull_request_target" field to the value that was provided on create.
func (*ScanUpsertOne) UpdateRequestedAt ¶
func (u *ScanUpsertOne) UpdateRequestedAt() *ScanUpsertOne
UpdateRequestedAt sets the "requested_at" field to the value that was provided on create.
func (*ScanUpsertOne) UpdateScannedAt ¶
func (u *ScanUpsertOne) UpdateScannedAt() *ScanUpsertOne
UpdateScannedAt sets the "scanned_at" field to the value that was provided on create.
type Session ¶
type Session struct { // ID of the ent. ID string `json:"id,omitempty"` // UserID holds the value of the "user_id" field. UserID int `json:"user_id,omitempty"` // Token holds the value of the "token" field. Token string `json:"-"` // CreatedAt holds the value of the "created_at" field. CreatedAt int64 `json:"created_at,omitempty"` // ExpiresAt holds the value of the "expires_at" field. ExpiresAt int64 `json:"expires_at,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the SessionQuery when eager-loading is set. Edges SessionEdges `json:"edges"` // contains filtered or unexported fields }
Session is the model entity for the Session schema.
func (*Session) QueryLogin ¶
QueryLogin queries the "login" edge of the Session entity.
func (*Session) Unwrap ¶
Unwrap unwraps the Session 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 (*Session) Update ¶
func (s *Session) Update() *SessionUpdateOne
Update returns a builder for updating this Session. Note that you need to call Session.Unwrap() before calling this method if this Session was returned from a transaction, and the transaction was committed or rolled back.
type SessionClient ¶
type SessionClient struct {
// contains filtered or unexported fields
}
SessionClient is a client for the Session schema.
func NewSessionClient ¶
func NewSessionClient(c config) *SessionClient
NewSessionClient returns a client for the Session from the given config.
func (*SessionClient) Create ¶
func (c *SessionClient) Create() *SessionCreate
Create returns a create builder for Session.
func (*SessionClient) CreateBulk ¶
func (c *SessionClient) CreateBulk(builders ...*SessionCreate) *SessionCreateBulk
CreateBulk returns a builder for creating a bulk of Session entities.
func (*SessionClient) Delete ¶
func (c *SessionClient) Delete() *SessionDelete
Delete returns a delete builder for Session.
func (*SessionClient) DeleteOne ¶
func (c *SessionClient) DeleteOne(s *Session) *SessionDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*SessionClient) DeleteOneID ¶
func (c *SessionClient) DeleteOneID(id string) *SessionDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*SessionClient) GetX ¶
func (c *SessionClient) GetX(ctx context.Context, id string) *Session
GetX is like Get, but panics if an error occurs.
func (*SessionClient) Hooks ¶
func (c *SessionClient) Hooks() []Hook
Hooks returns the client hooks.
func (*SessionClient) Query ¶
func (c *SessionClient) Query() *SessionQuery
Query returns a query builder for Session.
func (*SessionClient) QueryLogin ¶
func (c *SessionClient) QueryLogin(s *Session) *UserQuery
QueryLogin queries the login edge of a Session.
func (*SessionClient) Update ¶
func (c *SessionClient) Update() *SessionUpdate
Update returns an update builder for Session.
func (*SessionClient) UpdateOne ¶
func (c *SessionClient) UpdateOne(s *Session) *SessionUpdateOne
UpdateOne returns an update builder for the given entity.
func (*SessionClient) UpdateOneID ¶
func (c *SessionClient) UpdateOneID(id string) *SessionUpdateOne
UpdateOneID returns an update builder for the given id.
func (*SessionClient) Use ¶
func (c *SessionClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `session.Hooks(f(g(h())))`.
type SessionCreate ¶
type SessionCreate struct {
// contains filtered or unexported fields
}
SessionCreate is the builder for creating a Session entity.
func (*SessionCreate) Exec ¶
func (sc *SessionCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*SessionCreate) ExecX ¶
func (sc *SessionCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SessionCreate) Mutation ¶
func (sc *SessionCreate) Mutation() *SessionMutation
Mutation returns the SessionMutation object of the builder.
func (*SessionCreate) OnConflict ¶
func (sc *SessionCreate) OnConflict(opts ...sql.ConflictOption) *SessionUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Session.Create(). SetUserID(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.SessionUpsert) { SetUserID(v+v). }). Exec(ctx)
func (*SessionCreate) OnConflictColumns ¶
func (sc *SessionCreate) OnConflictColumns(columns ...string) *SessionUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Session.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*SessionCreate) Save ¶
func (sc *SessionCreate) Save(ctx context.Context) (*Session, error)
Save creates the Session in the database.
func (*SessionCreate) SaveX ¶
func (sc *SessionCreate) SaveX(ctx context.Context) *Session
SaveX calls Save and panics if Save returns an error.
func (*SessionCreate) SetCreatedAt ¶
func (sc *SessionCreate) SetCreatedAt(i int64) *SessionCreate
SetCreatedAt sets the "created_at" field.
func (*SessionCreate) SetExpiresAt ¶
func (sc *SessionCreate) SetExpiresAt(i int64) *SessionCreate
SetExpiresAt sets the "expires_at" field.
func (*SessionCreate) SetID ¶
func (sc *SessionCreate) SetID(s string) *SessionCreate
SetID sets the "id" field.
func (*SessionCreate) SetLogin ¶
func (sc *SessionCreate) SetLogin(u *User) *SessionCreate
SetLogin sets the "login" edge to the User entity.
func (*SessionCreate) SetLoginID ¶
func (sc *SessionCreate) SetLoginID(id int) *SessionCreate
SetLoginID sets the "login" edge to the User entity by ID.
func (*SessionCreate) SetNillableLoginID ¶
func (sc *SessionCreate) SetNillableLoginID(id *int) *SessionCreate
SetNillableLoginID sets the "login" edge to the User entity by ID if the given value is not nil.
func (*SessionCreate) SetToken ¶
func (sc *SessionCreate) SetToken(s string) *SessionCreate
SetToken sets the "token" field.
func (*SessionCreate) SetUserID ¶
func (sc *SessionCreate) SetUserID(i int) *SessionCreate
SetUserID sets the "user_id" field.
type SessionCreateBulk ¶
type SessionCreateBulk struct {
// contains filtered or unexported fields
}
SessionCreateBulk is the builder for creating many Session entities in bulk.
func (*SessionCreateBulk) Exec ¶
func (scb *SessionCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*SessionCreateBulk) ExecX ¶
func (scb *SessionCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SessionCreateBulk) OnConflict ¶
func (scb *SessionCreateBulk) OnConflict(opts ...sql.ConflictOption) *SessionUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Session.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.SessionUpsert) { SetUserID(v+v). }). Exec(ctx)
func (*SessionCreateBulk) OnConflictColumns ¶
func (scb *SessionCreateBulk) OnConflictColumns(columns ...string) *SessionUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Session.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type SessionDelete ¶
type SessionDelete struct {
// contains filtered or unexported fields
}
SessionDelete is the builder for deleting a Session entity.
func (*SessionDelete) Exec ¶
func (sd *SessionDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*SessionDelete) ExecX ¶
func (sd *SessionDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*SessionDelete) Where ¶
func (sd *SessionDelete) Where(ps ...predicate.Session) *SessionDelete
Where appends a list predicates to the SessionDelete builder.
type SessionDeleteOne ¶
type SessionDeleteOne struct {
// contains filtered or unexported fields
}
SessionDeleteOne is the builder for deleting a single Session entity.
func (*SessionDeleteOne) Exec ¶
func (sdo *SessionDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*SessionDeleteOne) ExecX ¶
func (sdo *SessionDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type SessionEdges ¶
type SessionEdges struct { // Login holds the value of the login edge. Login *User `json:"login,omitempty"` // contains filtered or unexported fields }
SessionEdges holds the relations/edges for other nodes in the graph.
func (SessionEdges) LoginOrErr ¶
func (e SessionEdges) LoginOrErr() (*User, error)
LoginOrErr returns the Login value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type SessionGroupBy ¶
type SessionGroupBy struct {
// contains filtered or unexported fields
}
SessionGroupBy is the group-by builder for Session entities.
func (*SessionGroupBy) Aggregate ¶
func (sgb *SessionGroupBy) Aggregate(fns ...AggregateFunc) *SessionGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*SessionGroupBy) Bool ¶
func (sgb *SessionGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) BoolX ¶
func (sgb *SessionGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*SessionGroupBy) Bools ¶
func (sgb *SessionGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) BoolsX ¶
func (sgb *SessionGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*SessionGroupBy) Float64 ¶
func (sgb *SessionGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) Float64X ¶
func (sgb *SessionGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*SessionGroupBy) Float64s ¶
func (sgb *SessionGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) Float64sX ¶
func (sgb *SessionGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*SessionGroupBy) Int ¶
func (sgb *SessionGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) IntX ¶
func (sgb *SessionGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*SessionGroupBy) Ints ¶
func (sgb *SessionGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) IntsX ¶
func (sgb *SessionGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*SessionGroupBy) Scan ¶
func (sgb *SessionGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*SessionGroupBy) ScanX ¶
func (sgb *SessionGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*SessionGroupBy) String ¶
func (sgb *SessionGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SessionGroupBy) StringX ¶
func (sgb *SessionGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type SessionMutation ¶
type SessionMutation struct {
// contains filtered or unexported fields
}
SessionMutation represents an operation that mutates the Session nodes in the graph.
func (*SessionMutation) AddCreatedAt ¶
func (m *SessionMutation) AddCreatedAt(i int64)
AddCreatedAt adds i to the "created_at" field.
func (*SessionMutation) AddExpiresAt ¶
func (m *SessionMutation) AddExpiresAt(i int64)
AddExpiresAt adds i to the "expires_at" field.
func (*SessionMutation) AddField ¶
func (m *SessionMutation) 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 (*SessionMutation) AddUserID ¶
func (m *SessionMutation) AddUserID(i int)
AddUserID adds i to the "user_id" field.
func (*SessionMutation) AddedCreatedAt ¶
func (m *SessionMutation) AddedCreatedAt() (r int64, exists bool)
AddedCreatedAt returns the value that was added to the "created_at" field in this mutation.
func (*SessionMutation) AddedEdges ¶
func (m *SessionMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*SessionMutation) AddedExpiresAt ¶
func (m *SessionMutation) AddedExpiresAt() (r int64, exists bool)
AddedExpiresAt returns the value that was added to the "expires_at" field in this mutation.
func (*SessionMutation) AddedField ¶
func (m *SessionMutation) 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 (*SessionMutation) AddedFields ¶
func (m *SessionMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*SessionMutation) AddedIDs ¶
func (m *SessionMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*SessionMutation) AddedUserID ¶
func (m *SessionMutation) AddedUserID() (r int, exists bool)
AddedUserID returns the value that was added to the "user_id" field in this mutation.
func (*SessionMutation) ClearEdge ¶
func (m *SessionMutation) 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 (*SessionMutation) ClearField ¶
func (m *SessionMutation) 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 (*SessionMutation) ClearLogin ¶
func (m *SessionMutation) ClearLogin()
ClearLogin clears the "login" edge to the User entity.
func (*SessionMutation) ClearedEdges ¶
func (m *SessionMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*SessionMutation) ClearedFields ¶
func (m *SessionMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (SessionMutation) Client ¶
func (m SessionMutation) 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 (*SessionMutation) CreatedAt ¶
func (m *SessionMutation) CreatedAt() (r int64, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*SessionMutation) EdgeCleared ¶
func (m *SessionMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*SessionMutation) ExpiresAt ¶
func (m *SessionMutation) ExpiresAt() (r int64, exists bool)
ExpiresAt returns the value of the "expires_at" field in the mutation.
func (*SessionMutation) Field ¶
func (m *SessionMutation) 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 (*SessionMutation) FieldCleared ¶
func (m *SessionMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*SessionMutation) Fields ¶
func (m *SessionMutation) 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 (*SessionMutation) ID ¶
func (m *SessionMutation) 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 (*SessionMutation) LoginCleared ¶
func (m *SessionMutation) LoginCleared() bool
LoginCleared reports if the "login" edge to the User entity was cleared.
func (*SessionMutation) LoginID ¶
func (m *SessionMutation) LoginID() (id int, exists bool)
LoginID returns the "login" edge ID in the mutation.
func (*SessionMutation) LoginIDs ¶
func (m *SessionMutation) LoginIDs() (ids []int)
LoginIDs returns the "login" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use LoginID instead. It exists only for internal usage by the builders.
func (*SessionMutation) OldCreatedAt ¶
func (m *SessionMutation) OldCreatedAt(ctx context.Context) (v int64, err error)
OldCreatedAt returns the old "created_at" field's value of the Session entity. If the Session 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 (*SessionMutation) OldExpiresAt ¶
func (m *SessionMutation) OldExpiresAt(ctx context.Context) (v int64, err error)
OldExpiresAt returns the old "expires_at" field's value of the Session entity. If the Session 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 (*SessionMutation) 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 (*SessionMutation) OldToken ¶
func (m *SessionMutation) OldToken(ctx context.Context) (v string, err error)
OldToken returns the old "token" field's value of the Session entity. If the Session 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 (*SessionMutation) OldUserID ¶
func (m *SessionMutation) OldUserID(ctx context.Context) (v int, err error)
OldUserID returns the old "user_id" field's value of the Session entity. If the Session 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 (*SessionMutation) RemovedEdges ¶
func (m *SessionMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*SessionMutation) RemovedIDs ¶
func (m *SessionMutation) 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 (*SessionMutation) ResetCreatedAt ¶
func (m *SessionMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*SessionMutation) ResetEdge ¶
func (m *SessionMutation) 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 (*SessionMutation) ResetExpiresAt ¶
func (m *SessionMutation) ResetExpiresAt()
ResetExpiresAt resets all changes to the "expires_at" field.
func (*SessionMutation) ResetField ¶
func (m *SessionMutation) 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 (*SessionMutation) ResetLogin ¶
func (m *SessionMutation) ResetLogin()
ResetLogin resets all changes to the "login" edge.
func (*SessionMutation) ResetToken ¶
func (m *SessionMutation) ResetToken()
ResetToken resets all changes to the "token" field.
func (*SessionMutation) ResetUserID ¶
func (m *SessionMutation) ResetUserID()
ResetUserID resets all changes to the "user_id" field.
func (*SessionMutation) SetCreatedAt ¶
func (m *SessionMutation) SetCreatedAt(i int64)
SetCreatedAt sets the "created_at" field.
func (*SessionMutation) SetExpiresAt ¶
func (m *SessionMutation) SetExpiresAt(i int64)
SetExpiresAt sets the "expires_at" field.
func (*SessionMutation) SetField ¶
func (m *SessionMutation) 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 (*SessionMutation) SetID ¶
func (m *SessionMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Session entities.
func (*SessionMutation) SetLoginID ¶
func (m *SessionMutation) SetLoginID(id int)
SetLoginID sets the "login" edge to the User entity by id.
func (*SessionMutation) SetToken ¶
func (m *SessionMutation) SetToken(s string)
SetToken sets the "token" field.
func (*SessionMutation) SetUserID ¶
func (m *SessionMutation) SetUserID(i int)
SetUserID sets the "user_id" field.
func (*SessionMutation) Token ¶
func (m *SessionMutation) Token() (r string, exists bool)
Token returns the value of the "token" field in the mutation.
func (SessionMutation) Tx ¶
func (m SessionMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*SessionMutation) Type ¶
func (m *SessionMutation) Type() string
Type returns the node type of this mutation (Session).
func (*SessionMutation) UserID ¶
func (m *SessionMutation) UserID() (r int, exists bool)
UserID returns the value of the "user_id" field in the mutation.
func (*SessionMutation) Where ¶
func (m *SessionMutation) Where(ps ...predicate.Session)
Where appends a list predicates to the SessionMutation builder.
type SessionQuery ¶
type SessionQuery struct {
// contains filtered or unexported fields
}
SessionQuery is the builder for querying Session entities.
func (*SessionQuery) All ¶
func (sq *SessionQuery) All(ctx context.Context) ([]*Session, error)
All executes the query and returns a list of Sessions.
func (*SessionQuery) AllX ¶
func (sq *SessionQuery) AllX(ctx context.Context) []*Session
AllX is like All, but panics if an error occurs.
func (*SessionQuery) Clone ¶
func (sq *SessionQuery) Clone() *SessionQuery
Clone returns a duplicate of the SessionQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*SessionQuery) Count ¶
func (sq *SessionQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*SessionQuery) CountX ¶
func (sq *SessionQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*SessionQuery) Exist ¶
func (sq *SessionQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*SessionQuery) ExistX ¶
func (sq *SessionQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*SessionQuery) First ¶
func (sq *SessionQuery) First(ctx context.Context) (*Session, error)
First returns the first Session entity from the query. Returns a *NotFoundError when no Session was found.
func (*SessionQuery) FirstID ¶
func (sq *SessionQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first Session ID from the query. Returns a *NotFoundError when no Session ID was found.
func (*SessionQuery) FirstIDX ¶
func (sq *SessionQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*SessionQuery) FirstX ¶
func (sq *SessionQuery) FirstX(ctx context.Context) *Session
FirstX is like First, but panics if an error occurs.
func (*SessionQuery) GroupBy ¶
func (sq *SessionQuery) GroupBy(field string, fields ...string) *SessionGroupBy
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 { UserID int `json:"user_id,omitempty"` Count int `json:"count,omitempty"` } client.Session.Query(). GroupBy(session.FieldUserID). Aggregate(ent.Count()). Scan(ctx, &v)
func (*SessionQuery) IDs ¶
func (sq *SessionQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of Session IDs.
func (*SessionQuery) IDsX ¶
func (sq *SessionQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*SessionQuery) Limit ¶
func (sq *SessionQuery) Limit(limit int) *SessionQuery
Limit adds a limit step to the query.
func (*SessionQuery) Offset ¶
func (sq *SessionQuery) Offset(offset int) *SessionQuery
Offset adds an offset step to the query.
func (*SessionQuery) Only ¶
func (sq *SessionQuery) Only(ctx context.Context) (*Session, error)
Only returns a single Session entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one Session entity is not found. Returns a *NotFoundError when no Session entities are found.
func (*SessionQuery) OnlyID ¶
func (sq *SessionQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID is like Only, but returns the only Session ID in the query. Returns a *NotSingularError when exactly one Session ID is not found. Returns a *NotFoundError when no entities are found.
func (*SessionQuery) OnlyIDX ¶
func (sq *SessionQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*SessionQuery) OnlyX ¶
func (sq *SessionQuery) OnlyX(ctx context.Context) *Session
OnlyX is like Only, but panics if an error occurs.
func (*SessionQuery) Order ¶
func (sq *SessionQuery) Order(o ...OrderFunc) *SessionQuery
Order adds an order step to the query.
func (*SessionQuery) QueryLogin ¶
func (sq *SessionQuery) QueryLogin() *UserQuery
QueryLogin chains the current query on the "login" edge.
func (*SessionQuery) Select ¶
func (sq *SessionQuery) Select(fields ...string) *SessionSelect
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 { UserID int `json:"user_id,omitempty"` } client.Session.Query(). Select(session.FieldUserID). Scan(ctx, &v)
func (*SessionQuery) Unique ¶
func (sq *SessionQuery) Unique(unique bool) *SessionQuery
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 (*SessionQuery) Where ¶
func (sq *SessionQuery) Where(ps ...predicate.Session) *SessionQuery
Where adds a new predicate for the SessionQuery builder.
func (*SessionQuery) WithLogin ¶
func (sq *SessionQuery) WithLogin(opts ...func(*UserQuery)) *SessionQuery
WithLogin tells the query-builder to eager-load the nodes that are connected to the "login" edge. The optional arguments are used to configure the query builder of the edge.
type SessionSelect ¶
type SessionSelect struct { *SessionQuery // contains filtered or unexported fields }
SessionSelect is the builder for selecting fields of Session entities.
func (*SessionSelect) Bool ¶
func (ss *SessionSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*SessionSelect) BoolX ¶
func (ss *SessionSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*SessionSelect) Bools ¶
func (ss *SessionSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*SessionSelect) BoolsX ¶
func (ss *SessionSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*SessionSelect) Float64 ¶
func (ss *SessionSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*SessionSelect) Float64X ¶
func (ss *SessionSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*SessionSelect) Float64s ¶
func (ss *SessionSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*SessionSelect) Float64sX ¶
func (ss *SessionSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*SessionSelect) Int ¶
func (ss *SessionSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*SessionSelect) IntX ¶
func (ss *SessionSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*SessionSelect) Ints ¶
func (ss *SessionSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*SessionSelect) IntsX ¶
func (ss *SessionSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*SessionSelect) Scan ¶
func (ss *SessionSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*SessionSelect) ScanX ¶
func (ss *SessionSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*SessionSelect) String ¶
func (ss *SessionSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*SessionSelect) StringX ¶
func (ss *SessionSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type SessionUpdate ¶
type SessionUpdate struct {
// contains filtered or unexported fields
}
SessionUpdate is the builder for updating Session entities.
func (*SessionUpdate) AddUserID ¶
func (su *SessionUpdate) AddUserID(i int) *SessionUpdate
AddUserID adds i to the "user_id" field.
func (*SessionUpdate) ClearLogin ¶
func (su *SessionUpdate) ClearLogin() *SessionUpdate
ClearLogin clears the "login" edge to the User entity.
func (*SessionUpdate) Exec ¶
func (su *SessionUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*SessionUpdate) ExecX ¶
func (su *SessionUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SessionUpdate) Mutation ¶
func (su *SessionUpdate) Mutation() *SessionMutation
Mutation returns the SessionMutation object of the builder.
func (*SessionUpdate) Save ¶
func (su *SessionUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*SessionUpdate) SaveX ¶
func (su *SessionUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*SessionUpdate) SetLogin ¶
func (su *SessionUpdate) SetLogin(u *User) *SessionUpdate
SetLogin sets the "login" edge to the User entity.
func (*SessionUpdate) SetLoginID ¶
func (su *SessionUpdate) SetLoginID(id int) *SessionUpdate
SetLoginID sets the "login" edge to the User entity by ID.
func (*SessionUpdate) SetNillableLoginID ¶
func (su *SessionUpdate) SetNillableLoginID(id *int) *SessionUpdate
SetNillableLoginID sets the "login" edge to the User entity by ID if the given value is not nil.
func (*SessionUpdate) SetUserID ¶
func (su *SessionUpdate) SetUserID(i int) *SessionUpdate
SetUserID sets the "user_id" field.
func (*SessionUpdate) Where ¶
func (su *SessionUpdate) Where(ps ...predicate.Session) *SessionUpdate
Where appends a list predicates to the SessionUpdate builder.
type SessionUpdateOne ¶
type SessionUpdateOne struct {
// contains filtered or unexported fields
}
SessionUpdateOne is the builder for updating a single Session entity.
func (*SessionUpdateOne) AddUserID ¶
func (suo *SessionUpdateOne) AddUserID(i int) *SessionUpdateOne
AddUserID adds i to the "user_id" field.
func (*SessionUpdateOne) ClearLogin ¶
func (suo *SessionUpdateOne) ClearLogin() *SessionUpdateOne
ClearLogin clears the "login" edge to the User entity.
func (*SessionUpdateOne) Exec ¶
func (suo *SessionUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*SessionUpdateOne) ExecX ¶
func (suo *SessionUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SessionUpdateOne) Mutation ¶
func (suo *SessionUpdateOne) Mutation() *SessionMutation
Mutation returns the SessionMutation object of the builder.
func (*SessionUpdateOne) Save ¶
func (suo *SessionUpdateOne) Save(ctx context.Context) (*Session, error)
Save executes the query and returns the updated Session entity.
func (*SessionUpdateOne) SaveX ¶
func (suo *SessionUpdateOne) SaveX(ctx context.Context) *Session
SaveX is like Save, but panics if an error occurs.
func (*SessionUpdateOne) Select ¶
func (suo *SessionUpdateOne) Select(field string, fields ...string) *SessionUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*SessionUpdateOne) SetLogin ¶
func (suo *SessionUpdateOne) SetLogin(u *User) *SessionUpdateOne
SetLogin sets the "login" edge to the User entity.
func (*SessionUpdateOne) SetLoginID ¶
func (suo *SessionUpdateOne) SetLoginID(id int) *SessionUpdateOne
SetLoginID sets the "login" edge to the User entity by ID.
func (*SessionUpdateOne) SetNillableLoginID ¶
func (suo *SessionUpdateOne) SetNillableLoginID(id *int) *SessionUpdateOne
SetNillableLoginID sets the "login" edge to the User entity by ID if the given value is not nil.
func (*SessionUpdateOne) SetUserID ¶
func (suo *SessionUpdateOne) SetUserID(i int) *SessionUpdateOne
SetUserID sets the "user_id" field.
type SessionUpsert ¶
SessionUpsert is the "OnConflict" setter.
func (*SessionUpsert) SetCreatedAt ¶
func (u *SessionUpsert) SetCreatedAt(v int64) *SessionUpsert
SetCreatedAt sets the "created_at" field.
func (*SessionUpsert) SetExpiresAt ¶
func (u *SessionUpsert) SetExpiresAt(v int64) *SessionUpsert
SetExpiresAt sets the "expires_at" field.
func (*SessionUpsert) SetToken ¶
func (u *SessionUpsert) SetToken(v string) *SessionUpsert
SetToken sets the "token" field.
func (*SessionUpsert) SetUserID ¶
func (u *SessionUpsert) SetUserID(v int) *SessionUpsert
SetUserID sets the "user_id" field.
func (*SessionUpsert) UpdateCreatedAt ¶
func (u *SessionUpsert) UpdateCreatedAt() *SessionUpsert
UpdateCreatedAt sets the "created_at" field to the value that was provided on create.
func (*SessionUpsert) UpdateExpiresAt ¶
func (u *SessionUpsert) UpdateExpiresAt() *SessionUpsert
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*SessionUpsert) UpdateToken ¶
func (u *SessionUpsert) UpdateToken() *SessionUpsert
UpdateToken sets the "token" field to the value that was provided on create.
func (*SessionUpsert) UpdateUserID ¶
func (u *SessionUpsert) UpdateUserID() *SessionUpsert
UpdateUserID sets the "user_id" field to the value that was provided on create.
type SessionUpsertBulk ¶
type SessionUpsertBulk struct {
// contains filtered or unexported fields
}
SessionUpsertBulk is the builder for "upsert"-ing a bulk of Session nodes.
func (*SessionUpsertBulk) DoNothing ¶
func (u *SessionUpsertBulk) DoNothing() *SessionUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*SessionUpsertBulk) Exec ¶
func (u *SessionUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*SessionUpsertBulk) ExecX ¶
func (u *SessionUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SessionUpsertBulk) Ignore ¶
func (u *SessionUpsertBulk) Ignore() *SessionUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Session.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*SessionUpsertBulk) SetCreatedAt ¶
func (u *SessionUpsertBulk) SetCreatedAt(v int64) *SessionUpsertBulk
SetCreatedAt sets the "created_at" field.
func (*SessionUpsertBulk) SetExpiresAt ¶
func (u *SessionUpsertBulk) SetExpiresAt(v int64) *SessionUpsertBulk
SetExpiresAt sets the "expires_at" field.
func (*SessionUpsertBulk) SetToken ¶
func (u *SessionUpsertBulk) SetToken(v string) *SessionUpsertBulk
SetToken sets the "token" field.
func (*SessionUpsertBulk) SetUserID ¶
func (u *SessionUpsertBulk) SetUserID(v int) *SessionUpsertBulk
SetUserID sets the "user_id" field.
func (*SessionUpsertBulk) Update ¶
func (u *SessionUpsertBulk) Update(set func(*SessionUpsert)) *SessionUpsertBulk
Update allows overriding fields `UPDATE` values. See the SessionCreateBulk.OnConflict documentation for more info.
func (*SessionUpsertBulk) UpdateCreatedAt ¶
func (u *SessionUpsertBulk) UpdateCreatedAt() *SessionUpsertBulk
UpdateCreatedAt sets the "created_at" field to the value that was provided on create.
func (*SessionUpsertBulk) UpdateExpiresAt ¶
func (u *SessionUpsertBulk) UpdateExpiresAt() *SessionUpsertBulk
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*SessionUpsertBulk) UpdateNewValues ¶
func (u *SessionUpsertBulk) UpdateNewValues() *SessionUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Session.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*SessionUpsertBulk) UpdateToken ¶
func (u *SessionUpsertBulk) UpdateToken() *SessionUpsertBulk
UpdateToken sets the "token" field to the value that was provided on create.
func (*SessionUpsertBulk) UpdateUserID ¶
func (u *SessionUpsertBulk) UpdateUserID() *SessionUpsertBulk
UpdateUserID sets the "user_id" field to the value that was provided on create.
type SessionUpsertOne ¶
type SessionUpsertOne struct {
// contains filtered or unexported fields
}
SessionUpsertOne is the builder for "upsert"-ing
one Session node.
func (*SessionUpsertOne) DoNothing ¶
func (u *SessionUpsertOne) DoNothing() *SessionUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*SessionUpsertOne) Exec ¶
func (u *SessionUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*SessionUpsertOne) ExecX ¶
func (u *SessionUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SessionUpsertOne) ID ¶
func (u *SessionUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*SessionUpsertOne) IDX ¶
func (u *SessionUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*SessionUpsertOne) Ignore ¶
func (u *SessionUpsertOne) Ignore() *SessionUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Session.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*SessionUpsertOne) SetCreatedAt ¶
func (u *SessionUpsertOne) SetCreatedAt(v int64) *SessionUpsertOne
SetCreatedAt sets the "created_at" field.
func (*SessionUpsertOne) SetExpiresAt ¶
func (u *SessionUpsertOne) SetExpiresAt(v int64) *SessionUpsertOne
SetExpiresAt sets the "expires_at" field.
func (*SessionUpsertOne) SetToken ¶
func (u *SessionUpsertOne) SetToken(v string) *SessionUpsertOne
SetToken sets the "token" field.
func (*SessionUpsertOne) SetUserID ¶
func (u *SessionUpsertOne) SetUserID(v int) *SessionUpsertOne
SetUserID sets the "user_id" field.
func (*SessionUpsertOne) Update ¶
func (u *SessionUpsertOne) Update(set func(*SessionUpsert)) *SessionUpsertOne
Update allows overriding fields `UPDATE` values. See the SessionCreate.OnConflict documentation for more info.
func (*SessionUpsertOne) UpdateCreatedAt ¶
func (u *SessionUpsertOne) UpdateCreatedAt() *SessionUpsertOne
UpdateCreatedAt sets the "created_at" field to the value that was provided on create.
func (*SessionUpsertOne) UpdateExpiresAt ¶
func (u *SessionUpsertOne) UpdateExpiresAt() *SessionUpsertOne
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*SessionUpsertOne) UpdateNewValues ¶
func (u *SessionUpsertOne) UpdateNewValues() *SessionUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Session.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*SessionUpsertOne) UpdateToken ¶
func (u *SessionUpsertOne) UpdateToken() *SessionUpsertOne
UpdateToken sets the "token" field to the value that was provided on create.
func (*SessionUpsertOne) UpdateUserID ¶
func (u *SessionUpsertOne) UpdateUserID() *SessionUpsertOne
UpdateUserID sets the "user_id" field to the value that was provided on create.
type Severities ¶ added in v0.1.1
type Severities []*Severity
Severities is a parsable slice of Severity.
type Severity ¶ added in v0.1.1
type Severity struct { // ID of the ent. ID int `json:"id,omitempty"` // Label holds the value of the "label" field. Label string `json:"label,omitempty"` // Color holds the value of the "color" field. Color string `json:"color,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the SeverityQuery when eager-loading is set. Edges SeverityEdges `json:"edges"` // contains filtered or unexported fields }
Severity is the model entity for the Severity schema.
func (*Severity) QueryVulnerabilities ¶ added in v0.1.1
func (s *Severity) QueryVulnerabilities() *VulnerabilityQuery
QueryVulnerabilities queries the "vulnerabilities" edge of the Severity entity.
func (*Severity) Unwrap ¶ added in v0.1.1
Unwrap unwraps the Severity 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 (*Severity) Update ¶ added in v0.1.1
func (s *Severity) Update() *SeverityUpdateOne
Update returns a builder for updating this Severity. Note that you need to call Severity.Unwrap() before calling this method if this Severity was returned from a transaction, and the transaction was committed or rolled back.
type SeverityClient ¶ added in v0.1.1
type SeverityClient struct {
// contains filtered or unexported fields
}
SeverityClient is a client for the Severity schema.
func NewSeverityClient ¶ added in v0.1.1
func NewSeverityClient(c config) *SeverityClient
NewSeverityClient returns a client for the Severity from the given config.
func (*SeverityClient) Create ¶ added in v0.1.1
func (c *SeverityClient) Create() *SeverityCreate
Create returns a create builder for Severity.
func (*SeverityClient) CreateBulk ¶ added in v0.1.1
func (c *SeverityClient) CreateBulk(builders ...*SeverityCreate) *SeverityCreateBulk
CreateBulk returns a builder for creating a bulk of Severity entities.
func (*SeverityClient) Delete ¶ added in v0.1.1
func (c *SeverityClient) Delete() *SeverityDelete
Delete returns a delete builder for Severity.
func (*SeverityClient) DeleteOne ¶ added in v0.1.1
func (c *SeverityClient) DeleteOne(s *Severity) *SeverityDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*SeverityClient) DeleteOneID ¶ added in v0.1.1
func (c *SeverityClient) DeleteOneID(id int) *SeverityDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*SeverityClient) GetX ¶ added in v0.1.1
func (c *SeverityClient) GetX(ctx context.Context, id int) *Severity
GetX is like Get, but panics if an error occurs.
func (*SeverityClient) Hooks ¶ added in v0.1.1
func (c *SeverityClient) Hooks() []Hook
Hooks returns the client hooks.
func (*SeverityClient) Query ¶ added in v0.1.1
func (c *SeverityClient) Query() *SeverityQuery
Query returns a query builder for Severity.
func (*SeverityClient) QueryVulnerabilities ¶ added in v0.1.1
func (c *SeverityClient) QueryVulnerabilities(s *Severity) *VulnerabilityQuery
QueryVulnerabilities queries the vulnerabilities edge of a Severity.
func (*SeverityClient) Update ¶ added in v0.1.1
func (c *SeverityClient) Update() *SeverityUpdate
Update returns an update builder for Severity.
func (*SeverityClient) UpdateOne ¶ added in v0.1.1
func (c *SeverityClient) UpdateOne(s *Severity) *SeverityUpdateOne
UpdateOne returns an update builder for the given entity.
func (*SeverityClient) UpdateOneID ¶ added in v0.1.1
func (c *SeverityClient) UpdateOneID(id int) *SeverityUpdateOne
UpdateOneID returns an update builder for the given id.
func (*SeverityClient) Use ¶ added in v0.1.1
func (c *SeverityClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `severity.Hooks(f(g(h())))`.
type SeverityCreate ¶ added in v0.1.1
type SeverityCreate struct {
// contains filtered or unexported fields
}
SeverityCreate is the builder for creating a Severity entity.
func (*SeverityCreate) AddVulnerabilities ¶ added in v0.1.1
func (sc *SeverityCreate) AddVulnerabilities(v ...*Vulnerability) *SeverityCreate
AddVulnerabilities adds the "vulnerabilities" edges to the Vulnerability entity.
func (*SeverityCreate) AddVulnerabilityIDs ¶ added in v0.1.1
func (sc *SeverityCreate) AddVulnerabilityIDs(ids ...string) *SeverityCreate
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*SeverityCreate) Exec ¶ added in v0.1.1
func (sc *SeverityCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*SeverityCreate) ExecX ¶ added in v0.1.1
func (sc *SeverityCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SeverityCreate) Mutation ¶ added in v0.1.1
func (sc *SeverityCreate) Mutation() *SeverityMutation
Mutation returns the SeverityMutation object of the builder.
func (*SeverityCreate) OnConflict ¶ added in v0.1.1
func (sc *SeverityCreate) OnConflict(opts ...sql.ConflictOption) *SeverityUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Severity.Create(). SetLabel(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.SeverityUpsert) { SetLabel(v+v). }). Exec(ctx)
func (*SeverityCreate) OnConflictColumns ¶ added in v0.1.1
func (sc *SeverityCreate) OnConflictColumns(columns ...string) *SeverityUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Severity.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*SeverityCreate) Save ¶ added in v0.1.1
func (sc *SeverityCreate) Save(ctx context.Context) (*Severity, error)
Save creates the Severity in the database.
func (*SeverityCreate) SaveX ¶ added in v0.1.1
func (sc *SeverityCreate) SaveX(ctx context.Context) *Severity
SaveX calls Save and panics if Save returns an error.
func (*SeverityCreate) SetColor ¶ added in v0.1.1
func (sc *SeverityCreate) SetColor(s string) *SeverityCreate
SetColor sets the "color" field.
func (*SeverityCreate) SetLabel ¶ added in v0.1.1
func (sc *SeverityCreate) SetLabel(s string) *SeverityCreate
SetLabel sets the "label" field.
func (*SeverityCreate) SetNillableColor ¶ added in v0.1.1
func (sc *SeverityCreate) SetNillableColor(s *string) *SeverityCreate
SetNillableColor sets the "color" field if the given value is not nil.
type SeverityCreateBulk ¶ added in v0.1.1
type SeverityCreateBulk struct {
// contains filtered or unexported fields
}
SeverityCreateBulk is the builder for creating many Severity entities in bulk.
func (*SeverityCreateBulk) Exec ¶ added in v0.1.1
func (scb *SeverityCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*SeverityCreateBulk) ExecX ¶ added in v0.1.1
func (scb *SeverityCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SeverityCreateBulk) OnConflict ¶ added in v0.1.1
func (scb *SeverityCreateBulk) OnConflict(opts ...sql.ConflictOption) *SeverityUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Severity.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.SeverityUpsert) { SetLabel(v+v). }). Exec(ctx)
func (*SeverityCreateBulk) OnConflictColumns ¶ added in v0.1.1
func (scb *SeverityCreateBulk) OnConflictColumns(columns ...string) *SeverityUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Severity.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type SeverityDelete ¶ added in v0.1.1
type SeverityDelete struct {
// contains filtered or unexported fields
}
SeverityDelete is the builder for deleting a Severity entity.
func (*SeverityDelete) Exec ¶ added in v0.1.1
func (sd *SeverityDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*SeverityDelete) ExecX ¶ added in v0.1.1
func (sd *SeverityDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*SeverityDelete) Where ¶ added in v0.1.1
func (sd *SeverityDelete) Where(ps ...predicate.Severity) *SeverityDelete
Where appends a list predicates to the SeverityDelete builder.
type SeverityDeleteOne ¶ added in v0.1.1
type SeverityDeleteOne struct {
// contains filtered or unexported fields
}
SeverityDeleteOne is the builder for deleting a single Severity entity.
func (*SeverityDeleteOne) Exec ¶ added in v0.1.1
func (sdo *SeverityDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*SeverityDeleteOne) ExecX ¶ added in v0.1.1
func (sdo *SeverityDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type SeverityEdges ¶ added in v0.1.1
type SeverityEdges struct { // Vulnerabilities holds the value of the vulnerabilities edge. Vulnerabilities []*Vulnerability `json:"vulnerabilities,omitempty"` // contains filtered or unexported fields }
SeverityEdges holds the relations/edges for other nodes in the graph.
func (SeverityEdges) VulnerabilitiesOrErr ¶ added in v0.1.1
func (e SeverityEdges) VulnerabilitiesOrErr() ([]*Vulnerability, error)
VulnerabilitiesOrErr returns the Vulnerabilities value or an error if the edge was not loaded in eager-loading.
type SeverityGroupBy ¶ added in v0.1.1
type SeverityGroupBy struct {
// contains filtered or unexported fields
}
SeverityGroupBy is the group-by builder for Severity entities.
func (*SeverityGroupBy) Aggregate ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Aggregate(fns ...AggregateFunc) *SeverityGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*SeverityGroupBy) Bool ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) BoolX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*SeverityGroupBy) Bools ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) BoolsX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*SeverityGroupBy) Float64 ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) Float64X ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*SeverityGroupBy) Float64s ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) Float64sX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*SeverityGroupBy) Int ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) IntX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*SeverityGroupBy) Ints ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) IntsX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*SeverityGroupBy) Scan ¶ added in v0.1.1
func (sgb *SeverityGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*SeverityGroupBy) ScanX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*SeverityGroupBy) String ¶ added in v0.1.1
func (sgb *SeverityGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*SeverityGroupBy) StringX ¶ added in v0.1.1
func (sgb *SeverityGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type SeverityMutation ¶ added in v0.1.1
type SeverityMutation struct {
// contains filtered or unexported fields
}
SeverityMutation represents an operation that mutates the Severity nodes in the graph.
func (*SeverityMutation) AddField ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) AddVulnerabilityIDs ¶ added in v0.1.1
func (m *SeverityMutation) AddVulnerabilityIDs(ids ...string)
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by ids.
func (*SeverityMutation) AddedEdges ¶ added in v0.1.1
func (m *SeverityMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*SeverityMutation) AddedField ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) AddedFields ¶ added in v0.1.1
func (m *SeverityMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*SeverityMutation) AddedIDs ¶ added in v0.1.1
func (m *SeverityMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*SeverityMutation) ClearColor ¶ added in v0.1.1
func (m *SeverityMutation) ClearColor()
ClearColor clears the value of the "color" field.
func (*SeverityMutation) ClearEdge ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) ClearField ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) ClearVulnerabilities ¶ added in v0.1.1
func (m *SeverityMutation) ClearVulnerabilities()
ClearVulnerabilities clears the "vulnerabilities" edge to the Vulnerability entity.
func (*SeverityMutation) ClearedEdges ¶ added in v0.1.1
func (m *SeverityMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*SeverityMutation) ClearedFields ¶ added in v0.1.1
func (m *SeverityMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (SeverityMutation) Client ¶ added in v0.1.1
func (m SeverityMutation) 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 (*SeverityMutation) Color ¶ added in v0.1.1
func (m *SeverityMutation) Color() (r string, exists bool)
Color returns the value of the "color" field in the mutation.
func (*SeverityMutation) ColorCleared ¶ added in v0.1.1
func (m *SeverityMutation) ColorCleared() bool
ColorCleared returns if the "color" field was cleared in this mutation.
func (*SeverityMutation) EdgeCleared ¶ added in v0.1.1
func (m *SeverityMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*SeverityMutation) Field ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) FieldCleared ¶ added in v0.1.1
func (m *SeverityMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*SeverityMutation) Fields ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) ID ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) Label ¶ added in v0.1.1
func (m *SeverityMutation) Label() (r string, exists bool)
Label returns the value of the "label" field in the mutation.
func (*SeverityMutation) OldColor ¶ added in v0.1.1
func (m *SeverityMutation) OldColor(ctx context.Context) (v string, err error)
OldColor returns the old "color" field's value of the Severity entity. If the Severity 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 (*SeverityMutation) OldField ¶ added in v0.1.1
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*SeverityMutation) OldLabel ¶ added in v0.1.1
func (m *SeverityMutation) OldLabel(ctx context.Context) (v string, err error)
OldLabel returns the old "label" field's value of the Severity entity. If the Severity 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 (*SeverityMutation) Op ¶ added in v0.1.1
func (m *SeverityMutation) Op() Op
Op returns the operation name.
func (*SeverityMutation) RemoveVulnerabilityIDs ¶ added in v0.1.1
func (m *SeverityMutation) RemoveVulnerabilityIDs(ids ...string)
RemoveVulnerabilityIDs removes the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*SeverityMutation) RemovedEdges ¶ added in v0.1.1
func (m *SeverityMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*SeverityMutation) RemovedIDs ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) RemovedVulnerabilitiesIDs ¶ added in v0.1.1
func (m *SeverityMutation) RemovedVulnerabilitiesIDs() (ids []string)
RemovedVulnerabilities returns the removed IDs of the "vulnerabilities" edge to the Vulnerability entity.
func (*SeverityMutation) ResetColor ¶ added in v0.1.1
func (m *SeverityMutation) ResetColor()
ResetColor resets all changes to the "color" field.
func (*SeverityMutation) ResetEdge ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) ResetField ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) ResetLabel ¶ added in v0.1.1
func (m *SeverityMutation) ResetLabel()
ResetLabel resets all changes to the "label" field.
func (*SeverityMutation) ResetVulnerabilities ¶ added in v0.1.1
func (m *SeverityMutation) ResetVulnerabilities()
ResetVulnerabilities resets all changes to the "vulnerabilities" edge.
func (*SeverityMutation) SetColor ¶ added in v0.1.1
func (m *SeverityMutation) SetColor(s string)
SetColor sets the "color" field.
func (*SeverityMutation) SetField ¶ added in v0.1.1
func (m *SeverityMutation) 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 (*SeverityMutation) SetLabel ¶ added in v0.1.1
func (m *SeverityMutation) SetLabel(s string)
SetLabel sets the "label" field.
func (SeverityMutation) Tx ¶ added in v0.1.1
func (m SeverityMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*SeverityMutation) Type ¶ added in v0.1.1
func (m *SeverityMutation) Type() string
Type returns the node type of this mutation (Severity).
func (*SeverityMutation) VulnerabilitiesCleared ¶ added in v0.1.1
func (m *SeverityMutation) VulnerabilitiesCleared() bool
VulnerabilitiesCleared reports if the "vulnerabilities" edge to the Vulnerability entity was cleared.
func (*SeverityMutation) VulnerabilitiesIDs ¶ added in v0.1.1
func (m *SeverityMutation) VulnerabilitiesIDs() (ids []string)
VulnerabilitiesIDs returns the "vulnerabilities" edge IDs in the mutation.
func (*SeverityMutation) Where ¶ added in v0.1.1
func (m *SeverityMutation) Where(ps ...predicate.Severity)
Where appends a list predicates to the SeverityMutation builder.
type SeverityQuery ¶ added in v0.1.1
type SeverityQuery struct {
// contains filtered or unexported fields
}
SeverityQuery is the builder for querying Severity entities.
func (*SeverityQuery) All ¶ added in v0.1.1
func (sq *SeverityQuery) All(ctx context.Context) ([]*Severity, error)
All executes the query and returns a list of Severities.
func (*SeverityQuery) AllX ¶ added in v0.1.1
func (sq *SeverityQuery) AllX(ctx context.Context) []*Severity
AllX is like All, but panics if an error occurs.
func (*SeverityQuery) Clone ¶ added in v0.1.1
func (sq *SeverityQuery) Clone() *SeverityQuery
Clone returns a duplicate of the SeverityQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*SeverityQuery) Count ¶ added in v0.1.1
func (sq *SeverityQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*SeverityQuery) CountX ¶ added in v0.1.1
func (sq *SeverityQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*SeverityQuery) Exist ¶ added in v0.1.1
func (sq *SeverityQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*SeverityQuery) ExistX ¶ added in v0.1.1
func (sq *SeverityQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*SeverityQuery) First ¶ added in v0.1.1
func (sq *SeverityQuery) First(ctx context.Context) (*Severity, error)
First returns the first Severity entity from the query. Returns a *NotFoundError when no Severity was found.
func (*SeverityQuery) FirstID ¶ added in v0.1.1
func (sq *SeverityQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first Severity ID from the query. Returns a *NotFoundError when no Severity ID was found.
func (*SeverityQuery) FirstIDX ¶ added in v0.1.1
func (sq *SeverityQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*SeverityQuery) FirstX ¶ added in v0.1.1
func (sq *SeverityQuery) FirstX(ctx context.Context) *Severity
FirstX is like First, but panics if an error occurs.
func (*SeverityQuery) GroupBy ¶ added in v0.1.1
func (sq *SeverityQuery) GroupBy(field string, fields ...string) *SeverityGroupBy
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 { Label string `json:"label,omitempty"` Count int `json:"count,omitempty"` } client.Severity.Query(). GroupBy(severity.FieldLabel). Aggregate(ent.Count()). Scan(ctx, &v)
func (*SeverityQuery) IDs ¶ added in v0.1.1
func (sq *SeverityQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of Severity IDs.
func (*SeverityQuery) IDsX ¶ added in v0.1.1
func (sq *SeverityQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*SeverityQuery) Limit ¶ added in v0.1.1
func (sq *SeverityQuery) Limit(limit int) *SeverityQuery
Limit adds a limit step to the query.
func (*SeverityQuery) Offset ¶ added in v0.1.1
func (sq *SeverityQuery) Offset(offset int) *SeverityQuery
Offset adds an offset step to the query.
func (*SeverityQuery) Only ¶ added in v0.1.1
func (sq *SeverityQuery) Only(ctx context.Context) (*Severity, error)
Only returns a single Severity entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one Severity entity is not found. Returns a *NotFoundError when no Severity entities are found.
func (*SeverityQuery) OnlyID ¶ added in v0.1.1
func (sq *SeverityQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only Severity ID in the query. Returns a *NotSingularError when exactly one Severity ID is not found. Returns a *NotFoundError when no entities are found.
func (*SeverityQuery) OnlyIDX ¶ added in v0.1.1
func (sq *SeverityQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*SeverityQuery) OnlyX ¶ added in v0.1.1
func (sq *SeverityQuery) OnlyX(ctx context.Context) *Severity
OnlyX is like Only, but panics if an error occurs.
func (*SeverityQuery) Order ¶ added in v0.1.1
func (sq *SeverityQuery) Order(o ...OrderFunc) *SeverityQuery
Order adds an order step to the query.
func (*SeverityQuery) QueryVulnerabilities ¶ added in v0.1.1
func (sq *SeverityQuery) QueryVulnerabilities() *VulnerabilityQuery
QueryVulnerabilities chains the current query on the "vulnerabilities" edge.
func (*SeverityQuery) Select ¶ added in v0.1.1
func (sq *SeverityQuery) Select(fields ...string) *SeveritySelect
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 { Label string `json:"label,omitempty"` } client.Severity.Query(). Select(severity.FieldLabel). Scan(ctx, &v)
func (*SeverityQuery) Unique ¶ added in v0.1.1
func (sq *SeverityQuery) Unique(unique bool) *SeverityQuery
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 (*SeverityQuery) Where ¶ added in v0.1.1
func (sq *SeverityQuery) Where(ps ...predicate.Severity) *SeverityQuery
Where adds a new predicate for the SeverityQuery builder.
func (*SeverityQuery) WithVulnerabilities ¶ added in v0.1.1
func (sq *SeverityQuery) WithVulnerabilities(opts ...func(*VulnerabilityQuery)) *SeverityQuery
WithVulnerabilities tells the query-builder to eager-load the nodes that are connected to the "vulnerabilities" edge. The optional arguments are used to configure the query builder of the edge.
type SeveritySelect ¶ added in v0.1.1
type SeveritySelect struct { *SeverityQuery // contains filtered or unexported fields }
SeveritySelect is the builder for selecting fields of Severity entities.
func (*SeveritySelect) Bool ¶ added in v0.1.1
func (ss *SeveritySelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) BoolX ¶ added in v0.1.1
func (ss *SeveritySelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*SeveritySelect) Bools ¶ added in v0.1.1
func (ss *SeveritySelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) BoolsX ¶ added in v0.1.1
func (ss *SeveritySelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*SeveritySelect) Float64 ¶ added in v0.1.1
func (ss *SeveritySelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) Float64X ¶ added in v0.1.1
func (ss *SeveritySelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*SeveritySelect) Float64s ¶ added in v0.1.1
func (ss *SeveritySelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) Float64sX ¶ added in v0.1.1
func (ss *SeveritySelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*SeveritySelect) Int ¶ added in v0.1.1
func (ss *SeveritySelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) IntX ¶ added in v0.1.1
func (ss *SeveritySelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*SeveritySelect) Ints ¶ added in v0.1.1
func (ss *SeveritySelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) IntsX ¶ added in v0.1.1
func (ss *SeveritySelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*SeveritySelect) Scan ¶ added in v0.1.1
func (ss *SeveritySelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*SeveritySelect) ScanX ¶ added in v0.1.1
func (ss *SeveritySelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*SeveritySelect) String ¶ added in v0.1.1
func (ss *SeveritySelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*SeveritySelect) StringX ¶ added in v0.1.1
func (ss *SeveritySelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type SeverityUpdate ¶ added in v0.1.1
type SeverityUpdate struct {
// contains filtered or unexported fields
}
SeverityUpdate is the builder for updating Severity entities.
func (*SeverityUpdate) AddVulnerabilities ¶ added in v0.1.1
func (su *SeverityUpdate) AddVulnerabilities(v ...*Vulnerability) *SeverityUpdate
AddVulnerabilities adds the "vulnerabilities" edges to the Vulnerability entity.
func (*SeverityUpdate) AddVulnerabilityIDs ¶ added in v0.1.1
func (su *SeverityUpdate) AddVulnerabilityIDs(ids ...string) *SeverityUpdate
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*SeverityUpdate) ClearColor ¶ added in v0.1.1
func (su *SeverityUpdate) ClearColor() *SeverityUpdate
ClearColor clears the value of the "color" field.
func (*SeverityUpdate) ClearVulnerabilities ¶ added in v0.1.1
func (su *SeverityUpdate) ClearVulnerabilities() *SeverityUpdate
ClearVulnerabilities clears all "vulnerabilities" edges to the Vulnerability entity.
func (*SeverityUpdate) Exec ¶ added in v0.1.1
func (su *SeverityUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*SeverityUpdate) ExecX ¶ added in v0.1.1
func (su *SeverityUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SeverityUpdate) Mutation ¶ added in v0.1.1
func (su *SeverityUpdate) Mutation() *SeverityMutation
Mutation returns the SeverityMutation object of the builder.
func (*SeverityUpdate) RemoveVulnerabilities ¶ added in v0.1.1
func (su *SeverityUpdate) RemoveVulnerabilities(v ...*Vulnerability) *SeverityUpdate
RemoveVulnerabilities removes "vulnerabilities" edges to Vulnerability entities.
func (*SeverityUpdate) RemoveVulnerabilityIDs ¶ added in v0.1.1
func (su *SeverityUpdate) RemoveVulnerabilityIDs(ids ...string) *SeverityUpdate
RemoveVulnerabilityIDs removes the "vulnerabilities" edge to Vulnerability entities by IDs.
func (*SeverityUpdate) Save ¶ added in v0.1.1
func (su *SeverityUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*SeverityUpdate) SaveX ¶ added in v0.1.1
func (su *SeverityUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*SeverityUpdate) SetColor ¶ added in v0.1.1
func (su *SeverityUpdate) SetColor(s string) *SeverityUpdate
SetColor sets the "color" field.
func (*SeverityUpdate) SetLabel ¶ added in v0.1.1
func (su *SeverityUpdate) SetLabel(s string) *SeverityUpdate
SetLabel sets the "label" field.
func (*SeverityUpdate) SetNillableColor ¶ added in v0.1.1
func (su *SeverityUpdate) SetNillableColor(s *string) *SeverityUpdate
SetNillableColor sets the "color" field if the given value is not nil.
func (*SeverityUpdate) Where ¶ added in v0.1.1
func (su *SeverityUpdate) Where(ps ...predicate.Severity) *SeverityUpdate
Where appends a list predicates to the SeverityUpdate builder.
type SeverityUpdateOne ¶ added in v0.1.1
type SeverityUpdateOne struct {
// contains filtered or unexported fields
}
SeverityUpdateOne is the builder for updating a single Severity entity.
func (*SeverityUpdateOne) AddVulnerabilities ¶ added in v0.1.1
func (suo *SeverityUpdateOne) AddVulnerabilities(v ...*Vulnerability) *SeverityUpdateOne
AddVulnerabilities adds the "vulnerabilities" edges to the Vulnerability entity.
func (*SeverityUpdateOne) AddVulnerabilityIDs ¶ added in v0.1.1
func (suo *SeverityUpdateOne) AddVulnerabilityIDs(ids ...string) *SeverityUpdateOne
AddVulnerabilityIDs adds the "vulnerabilities" edge to the Vulnerability entity by IDs.
func (*SeverityUpdateOne) ClearColor ¶ added in v0.1.1
func (suo *SeverityUpdateOne) ClearColor() *SeverityUpdateOne
ClearColor clears the value of the "color" field.
func (*SeverityUpdateOne) ClearVulnerabilities ¶ added in v0.1.1
func (suo *SeverityUpdateOne) ClearVulnerabilities() *SeverityUpdateOne
ClearVulnerabilities clears all "vulnerabilities" edges to the Vulnerability entity.
func (*SeverityUpdateOne) Exec ¶ added in v0.1.1
func (suo *SeverityUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*SeverityUpdateOne) ExecX ¶ added in v0.1.1
func (suo *SeverityUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SeverityUpdateOne) Mutation ¶ added in v0.1.1
func (suo *SeverityUpdateOne) Mutation() *SeverityMutation
Mutation returns the SeverityMutation object of the builder.
func (*SeverityUpdateOne) RemoveVulnerabilities ¶ added in v0.1.1
func (suo *SeverityUpdateOne) RemoveVulnerabilities(v ...*Vulnerability) *SeverityUpdateOne
RemoveVulnerabilities removes "vulnerabilities" edges to Vulnerability entities.
func (*SeverityUpdateOne) RemoveVulnerabilityIDs ¶ added in v0.1.1
func (suo *SeverityUpdateOne) RemoveVulnerabilityIDs(ids ...string) *SeverityUpdateOne
RemoveVulnerabilityIDs removes the "vulnerabilities" edge to Vulnerability entities by IDs.
func (*SeverityUpdateOne) Save ¶ added in v0.1.1
func (suo *SeverityUpdateOne) Save(ctx context.Context) (*Severity, error)
Save executes the query and returns the updated Severity entity.
func (*SeverityUpdateOne) SaveX ¶ added in v0.1.1
func (suo *SeverityUpdateOne) SaveX(ctx context.Context) *Severity
SaveX is like Save, but panics if an error occurs.
func (*SeverityUpdateOne) Select ¶ added in v0.1.1
func (suo *SeverityUpdateOne) Select(field string, fields ...string) *SeverityUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*SeverityUpdateOne) SetColor ¶ added in v0.1.1
func (suo *SeverityUpdateOne) SetColor(s string) *SeverityUpdateOne
SetColor sets the "color" field.
func (*SeverityUpdateOne) SetLabel ¶ added in v0.1.1
func (suo *SeverityUpdateOne) SetLabel(s string) *SeverityUpdateOne
SetLabel sets the "label" field.
func (*SeverityUpdateOne) SetNillableColor ¶ added in v0.1.1
func (suo *SeverityUpdateOne) SetNillableColor(s *string) *SeverityUpdateOne
SetNillableColor sets the "color" field if the given value is not nil.
type SeverityUpsert ¶ added in v0.1.1
SeverityUpsert is the "OnConflict" setter.
func (*SeverityUpsert) ClearColor ¶ added in v0.1.1
func (u *SeverityUpsert) ClearColor() *SeverityUpsert
ClearColor clears the value of the "color" field.
func (*SeverityUpsert) SetColor ¶ added in v0.1.1
func (u *SeverityUpsert) SetColor(v string) *SeverityUpsert
SetColor sets the "color" field.
func (*SeverityUpsert) SetLabel ¶ added in v0.1.1
func (u *SeverityUpsert) SetLabel(v string) *SeverityUpsert
SetLabel sets the "label" field.
func (*SeverityUpsert) UpdateColor ¶ added in v0.1.1
func (u *SeverityUpsert) UpdateColor() *SeverityUpsert
UpdateColor sets the "color" field to the value that was provided on create.
func (*SeverityUpsert) UpdateLabel ¶ added in v0.1.1
func (u *SeverityUpsert) UpdateLabel() *SeverityUpsert
UpdateLabel sets the "label" field to the value that was provided on create.
type SeverityUpsertBulk ¶ added in v0.1.1
type SeverityUpsertBulk struct {
// contains filtered or unexported fields
}
SeverityUpsertBulk is the builder for "upsert"-ing a bulk of Severity nodes.
func (*SeverityUpsertBulk) ClearColor ¶ added in v0.1.1
func (u *SeverityUpsertBulk) ClearColor() *SeverityUpsertBulk
ClearColor clears the value of the "color" field.
func (*SeverityUpsertBulk) DoNothing ¶ added in v0.1.1
func (u *SeverityUpsertBulk) DoNothing() *SeverityUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*SeverityUpsertBulk) Exec ¶ added in v0.1.1
func (u *SeverityUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*SeverityUpsertBulk) ExecX ¶ added in v0.1.1
func (u *SeverityUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SeverityUpsertBulk) Ignore ¶ added in v0.1.1
func (u *SeverityUpsertBulk) Ignore() *SeverityUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Severity.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*SeverityUpsertBulk) SetColor ¶ added in v0.1.1
func (u *SeverityUpsertBulk) SetColor(v string) *SeverityUpsertBulk
SetColor sets the "color" field.
func (*SeverityUpsertBulk) SetLabel ¶ added in v0.1.1
func (u *SeverityUpsertBulk) SetLabel(v string) *SeverityUpsertBulk
SetLabel sets the "label" field.
func (*SeverityUpsertBulk) Update ¶ added in v0.1.1
func (u *SeverityUpsertBulk) Update(set func(*SeverityUpsert)) *SeverityUpsertBulk
Update allows overriding fields `UPDATE` values. See the SeverityCreateBulk.OnConflict documentation for more info.
func (*SeverityUpsertBulk) UpdateColor ¶ added in v0.1.1
func (u *SeverityUpsertBulk) UpdateColor() *SeverityUpsertBulk
UpdateColor sets the "color" field to the value that was provided on create.
func (*SeverityUpsertBulk) UpdateLabel ¶ added in v0.1.1
func (u *SeverityUpsertBulk) UpdateLabel() *SeverityUpsertBulk
UpdateLabel sets the "label" field to the value that was provided on create.
func (*SeverityUpsertBulk) UpdateNewValues ¶ added in v0.1.1
func (u *SeverityUpsertBulk) UpdateNewValues() *SeverityUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Severity.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
type SeverityUpsertOne ¶ added in v0.1.1
type SeverityUpsertOne struct {
// contains filtered or unexported fields
}
SeverityUpsertOne is the builder for "upsert"-ing
one Severity node.
func (*SeverityUpsertOne) ClearColor ¶ added in v0.1.1
func (u *SeverityUpsertOne) ClearColor() *SeverityUpsertOne
ClearColor clears the value of the "color" field.
func (*SeverityUpsertOne) DoNothing ¶ added in v0.1.1
func (u *SeverityUpsertOne) DoNothing() *SeverityUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*SeverityUpsertOne) Exec ¶ added in v0.1.1
func (u *SeverityUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*SeverityUpsertOne) ExecX ¶ added in v0.1.1
func (u *SeverityUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*SeverityUpsertOne) ID ¶ added in v0.1.1
func (u *SeverityUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*SeverityUpsertOne) IDX ¶ added in v0.1.1
func (u *SeverityUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*SeverityUpsertOne) Ignore ¶ added in v0.1.1
func (u *SeverityUpsertOne) Ignore() *SeverityUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Severity.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*SeverityUpsertOne) SetColor ¶ added in v0.1.1
func (u *SeverityUpsertOne) SetColor(v string) *SeverityUpsertOne
SetColor sets the "color" field.
func (*SeverityUpsertOne) SetLabel ¶ added in v0.1.1
func (u *SeverityUpsertOne) SetLabel(v string) *SeverityUpsertOne
SetLabel sets the "label" field.
func (*SeverityUpsertOne) Update ¶ added in v0.1.1
func (u *SeverityUpsertOne) Update(set func(*SeverityUpsert)) *SeverityUpsertOne
Update allows overriding fields `UPDATE` values. See the SeverityCreate.OnConflict documentation for more info.
func (*SeverityUpsertOne) UpdateColor ¶ added in v0.1.1
func (u *SeverityUpsertOne) UpdateColor() *SeverityUpsertOne
UpdateColor sets the "color" field to the value that was provided on create.
func (*SeverityUpsertOne) UpdateLabel ¶ added in v0.1.1
func (u *SeverityUpsertOne) UpdateLabel() *SeverityUpsertOne
UpdateLabel sets the "label" field to the value that was provided on create.
func (*SeverityUpsertOne) UpdateNewValues ¶ added in v0.1.1
func (u *SeverityUpsertOne) UpdateNewValues() *SeverityUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Severity.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
type Tx ¶
type Tx struct { // AuthStateCache is the client for interacting with the AuthStateCache builders. AuthStateCache *AuthStateCacheClient // PackageRecord is the client for interacting with the PackageRecord builders. PackageRecord *PackageRecordClient // Repository is the client for interacting with the Repository builders. Repository *RepositoryClient // Scan is the client for interacting with the Scan builders. Scan *ScanClient // Session is the client for interacting with the Session builders. Session *SessionClient // Severity is the client for interacting with the Severity builders. Severity *SeverityClient // User is the client for interacting with the User builders. User *UserClient // VulnStatus is the client for interacting with the VulnStatus builders. VulnStatus *VulnStatusClient // VulnStatusIndex is the client for interacting with the VulnStatusIndex builders. VulnStatusIndex *VulnStatusIndexClient // Vulnerability is the client for interacting with the Vulnerability builders. Vulnerability *VulnerabilityClient // contains filtered or unexported fields }
Tx is a transactional client that is created by calling Client.Tx().
func TxFromContext ¶
TxFromContext returns a Tx stored inside a context, or nil if there isn't one.
func (*Tx) OnRollback ¶
func (tx *Tx) OnRollback(f RollbackHook)
OnRollback adds a hook to call on rollback.
type User ¶
type User struct { // ID of the ent. ID int `json:"id,omitempty"` // GithubID holds the value of the "github_id" field. GithubID int64 `json:"github_id,omitempty"` // Login holds the value of the "login" field. Login string `json:"login,omitempty"` // Name holds the value of the "name" field. Name string `json:"name,omitempty"` // AvatarURL holds the value of the "avatar_url" field. AvatarURL string `json:"avatar_url,omitempty"` // URL holds the value of the "url" field. URL string `json:"url,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the UserQuery when eager-loading is set. Edges UserEdges `json:"edges"` // contains filtered or unexported fields }
User is the model entity for the User schema.
func (*User) QueryEditedStatus ¶
func (u *User) QueryEditedStatus() *VulnStatusQuery
QueryEditedStatus queries the "edited_status" edge of the User entity.
func (*User) Unwrap ¶
Unwrap unwraps the User entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.
func (*User) Update ¶
func (u *User) Update() *UserUpdateOne
Update returns a builder for updating this User. Note that you need to call User.Unwrap() before calling this method if this User was returned from a transaction, and the transaction was committed or rolled back.
type UserClient ¶
type UserClient struct {
// contains filtered or unexported fields
}
UserClient is a client for the User schema.
func NewUserClient ¶
func NewUserClient(c config) *UserClient
NewUserClient returns a client for the User from the given config.
func (*UserClient) Create ¶
func (c *UserClient) Create() *UserCreate
Create returns a create builder for User.
func (*UserClient) CreateBulk ¶
func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk
CreateBulk returns a builder for creating a bulk of User entities.
func (*UserClient) Delete ¶
func (c *UserClient) Delete() *UserDelete
Delete returns a delete builder for User.
func (*UserClient) DeleteOne ¶
func (c *UserClient) DeleteOne(u *User) *UserDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*UserClient) DeleteOneID ¶
func (c *UserClient) DeleteOneID(id int) *UserDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*UserClient) GetX ¶
func (c *UserClient) GetX(ctx context.Context, id int) *User
GetX is like Get, but panics if an error occurs.
func (*UserClient) Query ¶
func (c *UserClient) Query() *UserQuery
Query returns a query builder for User.
func (*UserClient) QueryEditedStatus ¶
func (c *UserClient) QueryEditedStatus(u *User) *VulnStatusQuery
QueryEditedStatus queries the edited_status edge of a User.
func (*UserClient) Update ¶
func (c *UserClient) Update() *UserUpdate
Update returns an update builder for User.
func (*UserClient) UpdateOne ¶
func (c *UserClient) UpdateOne(u *User) *UserUpdateOne
UpdateOne returns an update builder for the given entity.
func (*UserClient) UpdateOneID ¶
func (c *UserClient) UpdateOneID(id int) *UserUpdateOne
UpdateOneID returns an update builder for the given id.
func (*UserClient) Use ¶
func (c *UserClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `user.Hooks(f(g(h())))`.
type UserCreate ¶
type UserCreate struct {
// contains filtered or unexported fields
}
UserCreate is the builder for creating a User entity.
func (*UserCreate) AddEditedStatuIDs ¶
func (uc *UserCreate) AddEditedStatuIDs(ids ...int) *UserCreate
AddEditedStatuIDs adds the "edited_status" edge to the VulnStatus entity by IDs.
func (*UserCreate) AddEditedStatus ¶
func (uc *UserCreate) AddEditedStatus(v ...*VulnStatus) *UserCreate
AddEditedStatus adds the "edited_status" edges to the VulnStatus entity.
func (*UserCreate) Exec ¶
func (uc *UserCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*UserCreate) ExecX ¶
func (uc *UserCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserCreate) Mutation ¶
func (uc *UserCreate) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserCreate) OnConflict ¶
func (uc *UserCreate) OnConflict(opts ...sql.ConflictOption) *UserUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.User.Create(). SetGithubID(v). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.UserUpsert) { SetGithubID(v+v). }). Exec(ctx)
func (*UserCreate) OnConflictColumns ¶
func (uc *UserCreate) OnConflictColumns(columns ...string) *UserUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*UserCreate) Save ¶
func (uc *UserCreate) Save(ctx context.Context) (*User, error)
Save creates the User in the database.
func (*UserCreate) SaveX ¶
func (uc *UserCreate) SaveX(ctx context.Context) *User
SaveX calls Save and panics if Save returns an error.
func (*UserCreate) SetAvatarURL ¶
func (uc *UserCreate) SetAvatarURL(s string) *UserCreate
SetAvatarURL sets the "avatar_url" field.
func (*UserCreate) SetGithubID ¶
func (uc *UserCreate) SetGithubID(i int64) *UserCreate
SetGithubID sets the "github_id" field.
func (*UserCreate) SetLogin ¶
func (uc *UserCreate) SetLogin(s string) *UserCreate
SetLogin sets the "login" field.
func (*UserCreate) SetName ¶
func (uc *UserCreate) SetName(s string) *UserCreate
SetName sets the "name" field.
func (*UserCreate) SetURL ¶
func (uc *UserCreate) SetURL(s string) *UserCreate
SetURL sets the "url" field.
type UserCreateBulk ¶
type UserCreateBulk struct {
// contains filtered or unexported fields
}
UserCreateBulk is the builder for creating many User entities in bulk.
func (*UserCreateBulk) Exec ¶
func (ucb *UserCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*UserCreateBulk) ExecX ¶
func (ucb *UserCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserCreateBulk) OnConflict ¶
func (ucb *UserCreateBulk) OnConflict(opts ...sql.ConflictOption) *UserUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.User.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). // Override some of the fields with custom // update values. Update(func(u *ent.UserUpsert) { SetGithubID(v+v). }). Exec(ctx)
func (*UserCreateBulk) OnConflictColumns ¶
func (ucb *UserCreateBulk) OnConflictColumns(columns ...string) *UserUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
type UserDelete ¶
type UserDelete struct {
// contains filtered or unexported fields
}
UserDelete is the builder for deleting a User entity.
func (*UserDelete) Exec ¶
func (ud *UserDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*UserDelete) ExecX ¶
func (ud *UserDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*UserDelete) Where ¶
func (ud *UserDelete) Where(ps ...predicate.User) *UserDelete
Where appends a list predicates to the UserDelete builder.
type UserDeleteOne ¶
type UserDeleteOne struct {
// contains filtered or unexported fields
}
UserDeleteOne is the builder for deleting a single User entity.
func (*UserDeleteOne) Exec ¶
func (udo *UserDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*UserDeleteOne) ExecX ¶
func (udo *UserDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type UserEdges ¶
type UserEdges struct { // EditedStatus holds the value of the edited_status edge. EditedStatus []*VulnStatus `json:"edited_status,omitempty"` // contains filtered or unexported fields }
UserEdges holds the relations/edges for other nodes in the graph.
func (UserEdges) EditedStatusOrErr ¶
func (e UserEdges) EditedStatusOrErr() ([]*VulnStatus, error)
EditedStatusOrErr returns the EditedStatus value or an error if the edge was not loaded in eager-loading.
type UserGroupBy ¶
type UserGroupBy struct {
// contains filtered or unexported fields
}
UserGroupBy is the group-by builder for User entities.
func (*UserGroupBy) Aggregate ¶
func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*UserGroupBy) Bool ¶
func (ugb *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) BoolX ¶
func (ugb *UserGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*UserGroupBy) Bools ¶
func (ugb *UserGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) BoolsX ¶
func (ugb *UserGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*UserGroupBy) Float64 ¶
func (ugb *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) Float64X ¶
func (ugb *UserGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*UserGroupBy) Float64s ¶
func (ugb *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) Float64sX ¶
func (ugb *UserGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*UserGroupBy) Int ¶
func (ugb *UserGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) IntX ¶
func (ugb *UserGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*UserGroupBy) Ints ¶
func (ugb *UserGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) IntsX ¶
func (ugb *UserGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*UserGroupBy) Scan ¶
func (ugb *UserGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*UserGroupBy) ScanX ¶
func (ugb *UserGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*UserGroupBy) String ¶
func (ugb *UserGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*UserGroupBy) StringX ¶
func (ugb *UserGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type UserMutation ¶
type UserMutation struct {
// contains filtered or unexported fields
}
UserMutation represents an operation that mutates the User nodes in the graph.
func (*UserMutation) AddEditedStatuIDs ¶
func (m *UserMutation) AddEditedStatuIDs(ids ...int)
AddEditedStatuIDs adds the "edited_status" edge to the VulnStatus entity by ids.
func (*UserMutation) AddField ¶
func (m *UserMutation) AddField(name string, value ent.Value) error
AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UserMutation) AddGithubID ¶
func (m *UserMutation) AddGithubID(i int64)
AddGithubID adds i to the "github_id" field.
func (*UserMutation) AddedEdges ¶
func (m *UserMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*UserMutation) AddedField ¶
func (m *UserMutation) AddedField(name string) (ent.Value, bool)
AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UserMutation) AddedFields ¶
func (m *UserMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*UserMutation) AddedGithubID ¶
func (m *UserMutation) AddedGithubID() (r int64, exists bool)
AddedGithubID returns the value that was added to the "github_id" field in this mutation.
func (*UserMutation) AddedIDs ¶
func (m *UserMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*UserMutation) AvatarURL ¶
func (m *UserMutation) AvatarURL() (r string, exists bool)
AvatarURL returns the value of the "avatar_url" field in the mutation.
func (*UserMutation) ClearEdge ¶
func (m *UserMutation) ClearEdge(name string) error
ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.
func (*UserMutation) ClearEditedStatus ¶
func (m *UserMutation) ClearEditedStatus()
ClearEditedStatus clears the "edited_status" edge to the VulnStatus entity.
func (*UserMutation) ClearField ¶
func (m *UserMutation) ClearField(name string) error
ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ClearedEdges ¶
func (m *UserMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*UserMutation) ClearedFields ¶
func (m *UserMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (UserMutation) Client ¶
func (m UserMutation) Client() *Client
Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.
func (*UserMutation) EdgeCleared ¶
func (m *UserMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*UserMutation) EditedStatusCleared ¶
func (m *UserMutation) EditedStatusCleared() bool
EditedStatusCleared reports if the "edited_status" edge to the VulnStatus entity was cleared.
func (*UserMutation) EditedStatusIDs ¶
func (m *UserMutation) EditedStatusIDs() (ids []int)
EditedStatusIDs returns the "edited_status" edge IDs in the mutation.
func (*UserMutation) Field ¶
func (m *UserMutation) Field(name string) (ent.Value, bool)
Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.
func (*UserMutation) FieldCleared ¶
func (m *UserMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*UserMutation) Fields ¶
func (m *UserMutation) Fields() []string
Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().
func (*UserMutation) GithubID ¶
func (m *UserMutation) GithubID() (r int64, exists bool)
GithubID returns the value of the "github_id" field in the mutation.
func (*UserMutation) ID ¶
func (m *UserMutation) 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 (*UserMutation) Login ¶
func (m *UserMutation) Login() (r string, exists bool)
Login returns the value of the "login" field in the mutation.
func (*UserMutation) Name ¶
func (m *UserMutation) Name() (r string, exists bool)
Name returns the value of the "name" field in the mutation.
func (*UserMutation) OldAvatarURL ¶
func (m *UserMutation) OldAvatarURL(ctx context.Context) (v string, err error)
OldAvatarURL returns the old "avatar_url" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldField ¶
OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.
func (*UserMutation) OldGithubID ¶
func (m *UserMutation) OldGithubID(ctx context.Context) (v int64, err error)
OldGithubID returns the old "github_id" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldLogin ¶
func (m *UserMutation) OldLogin(ctx context.Context) (v string, err error)
OldLogin returns the old "login" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldName ¶
func (m *UserMutation) OldName(ctx context.Context) (v string, err error)
OldName returns the old "name" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) OldURL ¶
func (m *UserMutation) OldURL(ctx context.Context) (v string, err error)
OldURL returns the old "url" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.
func (*UserMutation) RemoveEditedStatuIDs ¶
func (m *UserMutation) RemoveEditedStatuIDs(ids ...int)
RemoveEditedStatuIDs removes the "edited_status" edge to the VulnStatus entity by IDs.
func (*UserMutation) RemovedEdges ¶
func (m *UserMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*UserMutation) RemovedEditedStatusIDs ¶
func (m *UserMutation) RemovedEditedStatusIDs() (ids []int)
RemovedEditedStatus returns the removed IDs of the "edited_status" edge to the VulnStatus entity.
func (*UserMutation) RemovedIDs ¶
func (m *UserMutation) RemovedIDs(name string) []ent.Value
RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.
func (*UserMutation) ResetAvatarURL ¶
func (m *UserMutation) ResetAvatarURL()
ResetAvatarURL resets all changes to the "avatar_url" field.
func (*UserMutation) ResetEdge ¶
func (m *UserMutation) ResetEdge(name string) error
ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.
func (*UserMutation) ResetEditedStatus ¶
func (m *UserMutation) ResetEditedStatus()
ResetEditedStatus resets all changes to the "edited_status" edge.
func (*UserMutation) ResetField ¶
func (m *UserMutation) ResetField(name string) error
ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.
func (*UserMutation) ResetGithubID ¶
func (m *UserMutation) ResetGithubID()
ResetGithubID resets all changes to the "github_id" field.
func (*UserMutation) ResetLogin ¶
func (m *UserMutation) ResetLogin()
ResetLogin resets all changes to the "login" field.
func (*UserMutation) ResetName ¶
func (m *UserMutation) ResetName()
ResetName resets all changes to the "name" field.
func (*UserMutation) ResetURL ¶
func (m *UserMutation) ResetURL()
ResetURL resets all changes to the "url" field.
func (*UserMutation) SetAvatarURL ¶
func (m *UserMutation) SetAvatarURL(s string)
SetAvatarURL sets the "avatar_url" field.
func (*UserMutation) SetField ¶
func (m *UserMutation) SetField(name string, value ent.Value) error
SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.
func (*UserMutation) SetGithubID ¶
func (m *UserMutation) SetGithubID(i int64)
SetGithubID sets the "github_id" field.
func (*UserMutation) SetLogin ¶
func (m *UserMutation) SetLogin(s string)
SetLogin sets the "login" field.
func (*UserMutation) SetName ¶
func (m *UserMutation) SetName(s string)
SetName sets the "name" field.
func (UserMutation) Tx ¶
func (m UserMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*UserMutation) Type ¶
func (m *UserMutation) Type() string
Type returns the node type of this mutation (User).
func (*UserMutation) URL ¶
func (m *UserMutation) URL() (r string, exists bool)
URL returns the value of the "url" field in the mutation.
func (*UserMutation) Where ¶
func (m *UserMutation) Where(ps ...predicate.User)
Where appends a list predicates to the UserMutation builder.
type UserQuery ¶
type UserQuery struct {
// contains filtered or unexported fields
}
UserQuery is the builder for querying User entities.
func (*UserQuery) Clone ¶
Clone returns a duplicate of the UserQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*UserQuery) First ¶
First returns the first User entity from the query. Returns a *NotFoundError when no User was found.
func (*UserQuery) FirstID ¶
FirstID returns the first User ID from the query. Returns a *NotFoundError when no User ID was found.
func (*UserQuery) GroupBy ¶
func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy
GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.
Example:
var v []struct { GithubID int64 `json:"github_id,omitempty"` Count int `json:"count,omitempty"` } client.User.Query(). GroupBy(user.FieldGithubID). Aggregate(ent.Count()). Scan(ctx, &v)
func (*UserQuery) Only ¶
Only returns a single User entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one User entity is not found. Returns a *NotFoundError when no User entities are found.
func (*UserQuery) OnlyID ¶
OnlyID is like Only, but returns the only User ID in the query. Returns a *NotSingularError when exactly one User ID is not found. Returns a *NotFoundError when no entities are found.
func (*UserQuery) QueryEditedStatus ¶
func (uq *UserQuery) QueryEditedStatus() *VulnStatusQuery
QueryEditedStatus chains the current query on the "edited_status" edge.
func (*UserQuery) Select ¶
func (uq *UserQuery) Select(fields ...string) *UserSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
Example:
var v []struct { GithubID int64 `json:"github_id,omitempty"` } client.User.Query(). Select(user.FieldGithubID). Scan(ctx, &v)
func (*UserQuery) Unique ¶
Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.
func (*UserQuery) WithEditedStatus ¶
func (uq *UserQuery) WithEditedStatus(opts ...func(*VulnStatusQuery)) *UserQuery
WithEditedStatus tells the query-builder to eager-load the nodes that are connected to the "edited_status" edge. The optional arguments are used to configure the query builder of the edge.
type UserSelect ¶
type UserSelect struct { *UserQuery // contains filtered or unexported fields }
UserSelect is the builder for selecting fields of User entities.
func (*UserSelect) Bool ¶
func (us *UserSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*UserSelect) BoolX ¶
func (us *UserSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*UserSelect) Bools ¶
func (us *UserSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*UserSelect) BoolsX ¶
func (us *UserSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*UserSelect) Float64 ¶
func (us *UserSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*UserSelect) Float64X ¶
func (us *UserSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*UserSelect) Float64s ¶
func (us *UserSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*UserSelect) Float64sX ¶
func (us *UserSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*UserSelect) Int ¶
func (us *UserSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*UserSelect) IntX ¶
func (us *UserSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*UserSelect) Ints ¶
func (us *UserSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*UserSelect) IntsX ¶
func (us *UserSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*UserSelect) Scan ¶
func (us *UserSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*UserSelect) ScanX ¶
func (us *UserSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*UserSelect) String ¶
func (us *UserSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*UserSelect) StringX ¶
func (us *UserSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type UserUpdate ¶
type UserUpdate struct {
// contains filtered or unexported fields
}
UserUpdate is the builder for updating User entities.
func (*UserUpdate) AddEditedStatuIDs ¶
func (uu *UserUpdate) AddEditedStatuIDs(ids ...int) *UserUpdate
AddEditedStatuIDs adds the "edited_status" edge to the VulnStatus entity by IDs.
func (*UserUpdate) AddEditedStatus ¶
func (uu *UserUpdate) AddEditedStatus(v ...*VulnStatus) *UserUpdate
AddEditedStatus adds the "edited_status" edges to the VulnStatus entity.
func (*UserUpdate) ClearEditedStatus ¶
func (uu *UserUpdate) ClearEditedStatus() *UserUpdate
ClearEditedStatus clears all "edited_status" edges to the VulnStatus entity.
func (*UserUpdate) Exec ¶
func (uu *UserUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpdate) ExecX ¶
func (uu *UserUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpdate) Mutation ¶
func (uu *UserUpdate) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserUpdate) RemoveEditedStatuIDs ¶
func (uu *UserUpdate) RemoveEditedStatuIDs(ids ...int) *UserUpdate
RemoveEditedStatuIDs removes the "edited_status" edge to VulnStatus entities by IDs.
func (*UserUpdate) RemoveEditedStatus ¶
func (uu *UserUpdate) RemoveEditedStatus(v ...*VulnStatus) *UserUpdate
RemoveEditedStatus removes "edited_status" edges to VulnStatus entities.
func (*UserUpdate) Save ¶
func (uu *UserUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*UserUpdate) SaveX ¶
func (uu *UserUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*UserUpdate) SetAvatarURL ¶
func (uu *UserUpdate) SetAvatarURL(s string) *UserUpdate
SetAvatarURL sets the "avatar_url" field.
func (*UserUpdate) SetLogin ¶
func (uu *UserUpdate) SetLogin(s string) *UserUpdate
SetLogin sets the "login" field.
func (*UserUpdate) SetName ¶
func (uu *UserUpdate) SetName(s string) *UserUpdate
SetName sets the "name" field.
func (*UserUpdate) SetURL ¶
func (uu *UserUpdate) SetURL(s string) *UserUpdate
SetURL sets the "url" field.
func (*UserUpdate) Where ¶
func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate
Where appends a list predicates to the UserUpdate builder.
type UserUpdateOne ¶
type UserUpdateOne struct {
// contains filtered or unexported fields
}
UserUpdateOne is the builder for updating a single User entity.
func (*UserUpdateOne) AddEditedStatuIDs ¶
func (uuo *UserUpdateOne) AddEditedStatuIDs(ids ...int) *UserUpdateOne
AddEditedStatuIDs adds the "edited_status" edge to the VulnStatus entity by IDs.
func (*UserUpdateOne) AddEditedStatus ¶
func (uuo *UserUpdateOne) AddEditedStatus(v ...*VulnStatus) *UserUpdateOne
AddEditedStatus adds the "edited_status" edges to the VulnStatus entity.
func (*UserUpdateOne) ClearEditedStatus ¶
func (uuo *UserUpdateOne) ClearEditedStatus() *UserUpdateOne
ClearEditedStatus clears all "edited_status" edges to the VulnStatus entity.
func (*UserUpdateOne) Exec ¶
func (uuo *UserUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*UserUpdateOne) ExecX ¶
func (uuo *UserUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpdateOne) Mutation ¶
func (uuo *UserUpdateOne) Mutation() *UserMutation
Mutation returns the UserMutation object of the builder.
func (*UserUpdateOne) RemoveEditedStatuIDs ¶
func (uuo *UserUpdateOne) RemoveEditedStatuIDs(ids ...int) *UserUpdateOne
RemoveEditedStatuIDs removes the "edited_status" edge to VulnStatus entities by IDs.
func (*UserUpdateOne) RemoveEditedStatus ¶
func (uuo *UserUpdateOne) RemoveEditedStatus(v ...*VulnStatus) *UserUpdateOne
RemoveEditedStatus removes "edited_status" edges to VulnStatus entities.
func (*UserUpdateOne) Save ¶
func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)
Save executes the query and returns the updated User entity.
func (*UserUpdateOne) SaveX ¶
func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User
SaveX is like Save, but panics if an error occurs.
func (*UserUpdateOne) Select ¶
func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*UserUpdateOne) SetAvatarURL ¶
func (uuo *UserUpdateOne) SetAvatarURL(s string) *UserUpdateOne
SetAvatarURL sets the "avatar_url" field.
func (*UserUpdateOne) SetLogin ¶
func (uuo *UserUpdateOne) SetLogin(s string) *UserUpdateOne
SetLogin sets the "login" field.
func (*UserUpdateOne) SetName ¶
func (uuo *UserUpdateOne) SetName(s string) *UserUpdateOne
SetName sets the "name" field.
func (*UserUpdateOne) SetURL ¶
func (uuo *UserUpdateOne) SetURL(s string) *UserUpdateOne
SetURL sets the "url" field.
type UserUpsert ¶
UserUpsert is the "OnConflict" setter.
func (*UserUpsert) SetAvatarURL ¶
func (u *UserUpsert) SetAvatarURL(v string) *UserUpsert
SetAvatarURL sets the "avatar_url" field.
func (*UserUpsert) SetGithubID ¶
func (u *UserUpsert) SetGithubID(v int64) *UserUpsert
SetGithubID sets the "github_id" field.
func (*UserUpsert) SetLogin ¶
func (u *UserUpsert) SetLogin(v string) *UserUpsert
SetLogin sets the "login" field.
func (*UserUpsert) SetName ¶
func (u *UserUpsert) SetName(v string) *UserUpsert
SetName sets the "name" field.
func (*UserUpsert) SetURL ¶
func (u *UserUpsert) SetURL(v string) *UserUpsert
SetURL sets the "url" field.
func (*UserUpsert) UpdateAvatarURL ¶
func (u *UserUpsert) UpdateAvatarURL() *UserUpsert
UpdateAvatarURL sets the "avatar_url" field to the value that was provided on create.
func (*UserUpsert) UpdateGithubID ¶
func (u *UserUpsert) UpdateGithubID() *UserUpsert
UpdateGithubID sets the "github_id" field to the value that was provided on create.
func (*UserUpsert) UpdateLogin ¶
func (u *UserUpsert) UpdateLogin() *UserUpsert
UpdateLogin sets the "login" field to the value that was provided on create.
func (*UserUpsert) UpdateName ¶
func (u *UserUpsert) UpdateName() *UserUpsert
UpdateName sets the "name" field to the value that was provided on create.
func (*UserUpsert) UpdateURL ¶
func (u *UserUpsert) UpdateURL() *UserUpsert
UpdateURL sets the "url" field to the value that was provided on create.
type UserUpsertBulk ¶
type UserUpsertBulk struct {
// contains filtered or unexported fields
}
UserUpsertBulk is the builder for "upsert"-ing a bulk of User nodes.
func (*UserUpsertBulk) DoNothing ¶
func (u *UserUpsertBulk) DoNothing() *UserUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*UserUpsertBulk) Exec ¶
func (u *UserUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpsertBulk) ExecX ¶
func (u *UserUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpsertBulk) Ignore ¶
func (u *UserUpsertBulk) Ignore() *UserUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*UserUpsertBulk) SetAvatarURL ¶
func (u *UserUpsertBulk) SetAvatarURL(v string) *UserUpsertBulk
SetAvatarURL sets the "avatar_url" field.
func (*UserUpsertBulk) SetGithubID ¶
func (u *UserUpsertBulk) SetGithubID(v int64) *UserUpsertBulk
SetGithubID sets the "github_id" field.
func (*UserUpsertBulk) SetLogin ¶
func (u *UserUpsertBulk) SetLogin(v string) *UserUpsertBulk
SetLogin sets the "login" field.
func (*UserUpsertBulk) SetName ¶
func (u *UserUpsertBulk) SetName(v string) *UserUpsertBulk
SetName sets the "name" field.
func (*UserUpsertBulk) SetURL ¶
func (u *UserUpsertBulk) SetURL(v string) *UserUpsertBulk
SetURL sets the "url" field.
func (*UserUpsertBulk) Update ¶
func (u *UserUpsertBulk) Update(set func(*UserUpsert)) *UserUpsertBulk
Update allows overriding fields `UPDATE` values. See the UserCreateBulk.OnConflict documentation for more info.
func (*UserUpsertBulk) UpdateAvatarURL ¶
func (u *UserUpsertBulk) UpdateAvatarURL() *UserUpsertBulk
UpdateAvatarURL sets the "avatar_url" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateGithubID ¶
func (u *UserUpsertBulk) UpdateGithubID() *UserUpsertBulk
UpdateGithubID sets the "github_id" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateLogin ¶
func (u *UserUpsertBulk) UpdateLogin() *UserUpsertBulk
UpdateLogin sets the "login" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateName ¶
func (u *UserUpsertBulk) UpdateName() *UserUpsertBulk
UpdateName sets the "name" field to the value that was provided on create.
func (*UserUpsertBulk) UpdateNewValues ¶
func (u *UserUpsertBulk) UpdateNewValues() *UserUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*UserUpsertBulk) UpdateURL ¶
func (u *UserUpsertBulk) UpdateURL() *UserUpsertBulk
UpdateURL sets the "url" field to the value that was provided on create.
type UserUpsertOne ¶
type UserUpsertOne struct {
// contains filtered or unexported fields
}
UserUpsertOne is the builder for "upsert"-ing
one User node.
func (*UserUpsertOne) DoNothing ¶
func (u *UserUpsertOne) DoNothing() *UserUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*UserUpsertOne) Exec ¶
func (u *UserUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*UserUpsertOne) ExecX ¶
func (u *UserUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*UserUpsertOne) ID ¶
func (u *UserUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*UserUpsertOne) IDX ¶
func (u *UserUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*UserUpsertOne) Ignore ¶
func (u *UserUpsertOne) Ignore() *UserUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*UserUpsertOne) SetAvatarURL ¶
func (u *UserUpsertOne) SetAvatarURL(v string) *UserUpsertOne
SetAvatarURL sets the "avatar_url" field.
func (*UserUpsertOne) SetGithubID ¶
func (u *UserUpsertOne) SetGithubID(v int64) *UserUpsertOne
SetGithubID sets the "github_id" field.
func (*UserUpsertOne) SetLogin ¶
func (u *UserUpsertOne) SetLogin(v string) *UserUpsertOne
SetLogin sets the "login" field.
func (*UserUpsertOne) SetName ¶
func (u *UserUpsertOne) SetName(v string) *UserUpsertOne
SetName sets the "name" field.
func (*UserUpsertOne) SetURL ¶
func (u *UserUpsertOne) SetURL(v string) *UserUpsertOne
SetURL sets the "url" field.
func (*UserUpsertOne) Update ¶
func (u *UserUpsertOne) Update(set func(*UserUpsert)) *UserUpsertOne
Update allows overriding fields `UPDATE` values. See the UserCreate.OnConflict documentation for more info.
func (*UserUpsertOne) UpdateAvatarURL ¶
func (u *UserUpsertOne) UpdateAvatarURL() *UserUpsertOne
UpdateAvatarURL sets the "avatar_url" field to the value that was provided on create.
func (*UserUpsertOne) UpdateGithubID ¶
func (u *UserUpsertOne) UpdateGithubID() *UserUpsertOne
UpdateGithubID sets the "github_id" field to the value that was provided on create.
func (*UserUpsertOne) UpdateLogin ¶
func (u *UserUpsertOne) UpdateLogin() *UserUpsertOne
UpdateLogin sets the "login" field to the value that was provided on create.
func (*UserUpsertOne) UpdateName ¶
func (u *UserUpsertOne) UpdateName() *UserUpsertOne
UpdateName sets the "name" field to the value that was provided on create.
func (*UserUpsertOne) UpdateNewValues ¶
func (u *UserUpsertOne) UpdateNewValues() *UserUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.User.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*UserUpsertOne) UpdateURL ¶
func (u *UserUpsertOne) UpdateURL() *UserUpsertOne
UpdateURL sets the "url" field to the value that was provided on create.
type ValidationError ¶
type ValidationError struct { Name string // Field or edge name. // contains filtered or unexported fields }
ValidationError returns when validating a field 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.
type VulnStatus ¶
type VulnStatus struct { // ID of the ent. ID int `json:"id,omitempty"` // Status holds the value of the "status" field. Status types.VulnStatusType `json:"status,omitempty"` // Source holds the value of the "source" field. Source string `json:"source,omitempty"` // PkgName holds the value of the "pkg_name" field. PkgName string `json:"pkg_name,omitempty"` // PkgType holds the value of the "pkg_type" field. PkgType string `json:"pkg_type,omitempty"` // VulnID holds the value of the "vuln_id" field. VulnID string `json:"vuln_id,omitempty"` // ExpiresAt holds the value of the "expires_at" field. ExpiresAt int64 `json:"expires_at,omitempty"` // CreatedAt holds the value of the "created_at" field. CreatedAt int64 `json:"created_at,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 VulnStatusQuery when eager-loading is set. Edges VulnStatusEdges `json:"edges"` // contains filtered or unexported fields }
VulnStatus is the model entity for the VulnStatus schema.
func (*VulnStatus) QueryAuthor ¶
func (vs *VulnStatus) QueryAuthor() *UserQuery
QueryAuthor queries the "author" edge of the VulnStatus entity.
func (*VulnStatus) String ¶
func (vs *VulnStatus) String() string
String implements the fmt.Stringer.
func (*VulnStatus) Unwrap ¶
func (vs *VulnStatus) Unwrap() *VulnStatus
Unwrap unwraps the VulnStatus 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 (*VulnStatus) Update ¶
func (vs *VulnStatus) Update() *VulnStatusUpdateOne
Update returns a builder for updating this VulnStatus. Note that you need to call VulnStatus.Unwrap() before calling this method if this VulnStatus was returned from a transaction, and the transaction was committed or rolled back.
type VulnStatusClient ¶
type VulnStatusClient struct {
// contains filtered or unexported fields
}
VulnStatusClient is a client for the VulnStatus schema.
func NewVulnStatusClient ¶
func NewVulnStatusClient(c config) *VulnStatusClient
NewVulnStatusClient returns a client for the VulnStatus from the given config.
func (*VulnStatusClient) Create ¶
func (c *VulnStatusClient) Create() *VulnStatusCreate
Create returns a create builder for VulnStatus.
func (*VulnStatusClient) CreateBulk ¶
func (c *VulnStatusClient) CreateBulk(builders ...*VulnStatusCreate) *VulnStatusCreateBulk
CreateBulk returns a builder for creating a bulk of VulnStatus entities.
func (*VulnStatusClient) Delete ¶
func (c *VulnStatusClient) Delete() *VulnStatusDelete
Delete returns a delete builder for VulnStatus.
func (*VulnStatusClient) DeleteOne ¶
func (c *VulnStatusClient) DeleteOne(vs *VulnStatus) *VulnStatusDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*VulnStatusClient) DeleteOneID ¶
func (c *VulnStatusClient) DeleteOneID(id int) *VulnStatusDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*VulnStatusClient) Get ¶
func (c *VulnStatusClient) Get(ctx context.Context, id int) (*VulnStatus, error)
Get returns a VulnStatus entity by its id.
func (*VulnStatusClient) GetX ¶
func (c *VulnStatusClient) GetX(ctx context.Context, id int) *VulnStatus
GetX is like Get, but panics if an error occurs.
func (*VulnStatusClient) Hooks ¶
func (c *VulnStatusClient) Hooks() []Hook
Hooks returns the client hooks.
func (*VulnStatusClient) Query ¶
func (c *VulnStatusClient) Query() *VulnStatusQuery
Query returns a query builder for VulnStatus.
func (*VulnStatusClient) QueryAuthor ¶
func (c *VulnStatusClient) QueryAuthor(vs *VulnStatus) *UserQuery
QueryAuthor queries the author edge of a VulnStatus.
func (*VulnStatusClient) Update ¶
func (c *VulnStatusClient) Update() *VulnStatusUpdate
Update returns an update builder for VulnStatus.
func (*VulnStatusClient) UpdateOne ¶
func (c *VulnStatusClient) UpdateOne(vs *VulnStatus) *VulnStatusUpdateOne
UpdateOne returns an update builder for the given entity.
func (*VulnStatusClient) UpdateOneID ¶
func (c *VulnStatusClient) UpdateOneID(id int) *VulnStatusUpdateOne
UpdateOneID returns an update builder for the given id.
func (*VulnStatusClient) Use ¶
func (c *VulnStatusClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `vulnstatus.Hooks(f(g(h())))`.
type VulnStatusCreate ¶
type VulnStatusCreate struct {
// contains filtered or unexported fields
}
VulnStatusCreate is the builder for creating a VulnStatus entity.
func (*VulnStatusCreate) Exec ¶
func (vsc *VulnStatusCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusCreate) ExecX ¶
func (vsc *VulnStatusCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusCreate) Mutation ¶
func (vsc *VulnStatusCreate) Mutation() *VulnStatusMutation
Mutation returns the VulnStatusMutation object of the builder.
func (*VulnStatusCreate) OnConflict ¶
func (vsc *VulnStatusCreate) OnConflict(opts ...sql.ConflictOption) *VulnStatusUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.VulnStatus.Create(). SetStatus(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.VulnStatusUpsert) { SetStatus(v+v). }). Exec(ctx)
func (*VulnStatusCreate) OnConflictColumns ¶
func (vsc *VulnStatusCreate) OnConflictColumns(columns ...string) *VulnStatusUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.VulnStatus.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*VulnStatusCreate) Save ¶
func (vsc *VulnStatusCreate) Save(ctx context.Context) (*VulnStatus, error)
Save creates the VulnStatus in the database.
func (*VulnStatusCreate) SaveX ¶
func (vsc *VulnStatusCreate) SaveX(ctx context.Context) *VulnStatus
SaveX calls Save and panics if Save returns an error.
func (*VulnStatusCreate) SetAuthor ¶
func (vsc *VulnStatusCreate) SetAuthor(u *User) *VulnStatusCreate
SetAuthor sets the "author" edge to the User entity.
func (*VulnStatusCreate) SetAuthorID ¶
func (vsc *VulnStatusCreate) SetAuthorID(id int) *VulnStatusCreate
SetAuthorID sets the "author" edge to the User entity by ID.
func (*VulnStatusCreate) SetComment ¶
func (vsc *VulnStatusCreate) SetComment(s string) *VulnStatusCreate
SetComment sets the "comment" field.
func (*VulnStatusCreate) SetCreatedAt ¶
func (vsc *VulnStatusCreate) SetCreatedAt(i int64) *VulnStatusCreate
SetCreatedAt sets the "created_at" field.
func (*VulnStatusCreate) SetExpiresAt ¶
func (vsc *VulnStatusCreate) SetExpiresAt(i int64) *VulnStatusCreate
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusCreate) SetNillableAuthorID ¶
func (vsc *VulnStatusCreate) SetNillableAuthorID(id *int) *VulnStatusCreate
SetNillableAuthorID sets the "author" edge to the User entity by ID if the given value is not nil.
func (*VulnStatusCreate) SetPkgName ¶
func (vsc *VulnStatusCreate) SetPkgName(s string) *VulnStatusCreate
SetPkgName sets the "pkg_name" field.
func (*VulnStatusCreate) SetPkgType ¶
func (vsc *VulnStatusCreate) SetPkgType(s string) *VulnStatusCreate
SetPkgType sets the "pkg_type" field.
func (*VulnStatusCreate) SetSource ¶
func (vsc *VulnStatusCreate) SetSource(s string) *VulnStatusCreate
SetSource sets the "source" field.
func (*VulnStatusCreate) SetStatus ¶
func (vsc *VulnStatusCreate) SetStatus(tst types.VulnStatusType) *VulnStatusCreate
SetStatus sets the "status" field.
func (*VulnStatusCreate) SetVulnID ¶
func (vsc *VulnStatusCreate) SetVulnID(s string) *VulnStatusCreate
SetVulnID sets the "vuln_id" field.
type VulnStatusCreateBulk ¶
type VulnStatusCreateBulk struct {
// contains filtered or unexported fields
}
VulnStatusCreateBulk is the builder for creating many VulnStatus entities in bulk.
func (*VulnStatusCreateBulk) Exec ¶
func (vscb *VulnStatusCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusCreateBulk) ExecX ¶
func (vscb *VulnStatusCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusCreateBulk) OnConflict ¶
func (vscb *VulnStatusCreateBulk) OnConflict(opts ...sql.ConflictOption) *VulnStatusUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.VulnStatus.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.VulnStatusUpsert) { SetStatus(v+v). }). Exec(ctx)
func (*VulnStatusCreateBulk) OnConflictColumns ¶
func (vscb *VulnStatusCreateBulk) OnConflictColumns(columns ...string) *VulnStatusUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.VulnStatus.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*VulnStatusCreateBulk) Save ¶
func (vscb *VulnStatusCreateBulk) Save(ctx context.Context) ([]*VulnStatus, error)
Save creates the VulnStatus entities in the database.
func (*VulnStatusCreateBulk) SaveX ¶
func (vscb *VulnStatusCreateBulk) SaveX(ctx context.Context) []*VulnStatus
SaveX is like Save, but panics if an error occurs.
type VulnStatusDelete ¶
type VulnStatusDelete struct {
// contains filtered or unexported fields
}
VulnStatusDelete is the builder for deleting a VulnStatus entity.
func (*VulnStatusDelete) Exec ¶
func (vsd *VulnStatusDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*VulnStatusDelete) ExecX ¶
func (vsd *VulnStatusDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusDelete) Where ¶
func (vsd *VulnStatusDelete) Where(ps ...predicate.VulnStatus) *VulnStatusDelete
Where appends a list predicates to the VulnStatusDelete builder.
type VulnStatusDeleteOne ¶
type VulnStatusDeleteOne struct {
// contains filtered or unexported fields
}
VulnStatusDeleteOne is the builder for deleting a single VulnStatus entity.
func (*VulnStatusDeleteOne) Exec ¶
func (vsdo *VulnStatusDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*VulnStatusDeleteOne) ExecX ¶
func (vsdo *VulnStatusDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type VulnStatusEdges ¶
type VulnStatusEdges struct { // Author holds the value of the author edge. Author *User `json:"author,omitempty"` // contains filtered or unexported fields }
VulnStatusEdges holds the relations/edges for other nodes in the graph.
func (VulnStatusEdges) AuthorOrErr ¶
func (e VulnStatusEdges) AuthorOrErr() (*User, error)
AuthorOrErr returns the Author value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
type VulnStatusGroupBy ¶
type VulnStatusGroupBy struct {
// contains filtered or unexported fields
}
VulnStatusGroupBy is the group-by builder for VulnStatus entities.
func (*VulnStatusGroupBy) Aggregate ¶
func (vsgb *VulnStatusGroupBy) Aggregate(fns ...AggregateFunc) *VulnStatusGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*VulnStatusGroupBy) Bool ¶
func (vsgb *VulnStatusGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) BoolX ¶
func (vsgb *VulnStatusGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*VulnStatusGroupBy) Bools ¶
func (vsgb *VulnStatusGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) BoolsX ¶
func (vsgb *VulnStatusGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*VulnStatusGroupBy) Float64 ¶
func (vsgb *VulnStatusGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) Float64X ¶
func (vsgb *VulnStatusGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*VulnStatusGroupBy) Float64s ¶
func (vsgb *VulnStatusGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) Float64sX ¶
func (vsgb *VulnStatusGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*VulnStatusGroupBy) Int ¶
func (vsgb *VulnStatusGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) IntX ¶
func (vsgb *VulnStatusGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*VulnStatusGroupBy) Ints ¶
func (vsgb *VulnStatusGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) IntsX ¶
func (vsgb *VulnStatusGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*VulnStatusGroupBy) Scan ¶
func (vsgb *VulnStatusGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*VulnStatusGroupBy) ScanX ¶
func (vsgb *VulnStatusGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*VulnStatusGroupBy) String ¶
func (vsgb *VulnStatusGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusGroupBy) StringX ¶
func (vsgb *VulnStatusGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type VulnStatusIndex ¶
type VulnStatusIndex struct { // ID of the ent. ID string `json:"id,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the VulnStatusIndexQuery when eager-loading is set. Edges VulnStatusIndexEdges `json:"edges"` // contains filtered or unexported fields }
VulnStatusIndex is the model entity for the VulnStatusIndex schema.
func (*VulnStatusIndex) QueryLatest ¶ added in v0.0.6
func (vsi *VulnStatusIndex) QueryLatest() *VulnStatusQuery
QueryLatest queries the "latest" edge of the VulnStatusIndex entity.
func (*VulnStatusIndex) QueryStatus ¶
func (vsi *VulnStatusIndex) QueryStatus() *VulnStatusQuery
QueryStatus queries the "status" edge of the VulnStatusIndex entity.
func (*VulnStatusIndex) String ¶
func (vsi *VulnStatusIndex) String() string
String implements the fmt.Stringer.
func (*VulnStatusIndex) Unwrap ¶
func (vsi *VulnStatusIndex) Unwrap() *VulnStatusIndex
Unwrap unwraps the VulnStatusIndex 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 (*VulnStatusIndex) Update ¶
func (vsi *VulnStatusIndex) Update() *VulnStatusIndexUpdateOne
Update returns a builder for updating this VulnStatusIndex. Note that you need to call VulnStatusIndex.Unwrap() before calling this method if this VulnStatusIndex was returned from a transaction, and the transaction was committed or rolled back.
type VulnStatusIndexClient ¶
type VulnStatusIndexClient struct {
// contains filtered or unexported fields
}
VulnStatusIndexClient is a client for the VulnStatusIndex schema.
func NewVulnStatusIndexClient ¶
func NewVulnStatusIndexClient(c config) *VulnStatusIndexClient
NewVulnStatusIndexClient returns a client for the VulnStatusIndex from the given config.
func (*VulnStatusIndexClient) Create ¶
func (c *VulnStatusIndexClient) Create() *VulnStatusIndexCreate
Create returns a create builder for VulnStatusIndex.
func (*VulnStatusIndexClient) CreateBulk ¶
func (c *VulnStatusIndexClient) CreateBulk(builders ...*VulnStatusIndexCreate) *VulnStatusIndexCreateBulk
CreateBulk returns a builder for creating a bulk of VulnStatusIndex entities.
func (*VulnStatusIndexClient) Delete ¶
func (c *VulnStatusIndexClient) Delete() *VulnStatusIndexDelete
Delete returns a delete builder for VulnStatusIndex.
func (*VulnStatusIndexClient) DeleteOne ¶
func (c *VulnStatusIndexClient) DeleteOne(vsi *VulnStatusIndex) *VulnStatusIndexDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*VulnStatusIndexClient) DeleteOneID ¶
func (c *VulnStatusIndexClient) DeleteOneID(id string) *VulnStatusIndexDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*VulnStatusIndexClient) Get ¶
func (c *VulnStatusIndexClient) Get(ctx context.Context, id string) (*VulnStatusIndex, error)
Get returns a VulnStatusIndex entity by its id.
func (*VulnStatusIndexClient) GetX ¶
func (c *VulnStatusIndexClient) GetX(ctx context.Context, id string) *VulnStatusIndex
GetX is like Get, but panics if an error occurs.
func (*VulnStatusIndexClient) Hooks ¶
func (c *VulnStatusIndexClient) Hooks() []Hook
Hooks returns the client hooks.
func (*VulnStatusIndexClient) Query ¶
func (c *VulnStatusIndexClient) Query() *VulnStatusIndexQuery
Query returns a query builder for VulnStatusIndex.
func (*VulnStatusIndexClient) QueryLatest ¶ added in v0.0.6
func (c *VulnStatusIndexClient) QueryLatest(vsi *VulnStatusIndex) *VulnStatusQuery
QueryLatest queries the latest edge of a VulnStatusIndex.
func (*VulnStatusIndexClient) QueryStatus ¶
func (c *VulnStatusIndexClient) QueryStatus(vsi *VulnStatusIndex) *VulnStatusQuery
QueryStatus queries the status edge of a VulnStatusIndex.
func (*VulnStatusIndexClient) Update ¶
func (c *VulnStatusIndexClient) Update() *VulnStatusIndexUpdate
Update returns an update builder for VulnStatusIndex.
func (*VulnStatusIndexClient) UpdateOne ¶
func (c *VulnStatusIndexClient) UpdateOne(vsi *VulnStatusIndex) *VulnStatusIndexUpdateOne
UpdateOne returns an update builder for the given entity.
func (*VulnStatusIndexClient) UpdateOneID ¶
func (c *VulnStatusIndexClient) UpdateOneID(id string) *VulnStatusIndexUpdateOne
UpdateOneID returns an update builder for the given id.
func (*VulnStatusIndexClient) Use ¶
func (c *VulnStatusIndexClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `vulnstatusindex.Hooks(f(g(h())))`.
type VulnStatusIndexCreate ¶
type VulnStatusIndexCreate struct {
// contains filtered or unexported fields
}
VulnStatusIndexCreate is the builder for creating a VulnStatusIndex entity.
func (*VulnStatusIndexCreate) AddStatuIDs ¶
func (vsic *VulnStatusIndexCreate) AddStatuIDs(ids ...int) *VulnStatusIndexCreate
AddStatuIDs adds the "status" edge to the VulnStatus entity by IDs.
func (*VulnStatusIndexCreate) AddStatus ¶
func (vsic *VulnStatusIndexCreate) AddStatus(v ...*VulnStatus) *VulnStatusIndexCreate
AddStatus adds the "status" edges to the VulnStatus entity.
func (*VulnStatusIndexCreate) Exec ¶
func (vsic *VulnStatusIndexCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusIndexCreate) ExecX ¶
func (vsic *VulnStatusIndexCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexCreate) Mutation ¶
func (vsic *VulnStatusIndexCreate) Mutation() *VulnStatusIndexMutation
Mutation returns the VulnStatusIndexMutation object of the builder.
func (*VulnStatusIndexCreate) OnConflict ¶
func (vsic *VulnStatusIndexCreate) OnConflict(opts ...sql.ConflictOption) *VulnStatusIndexUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.VulnStatusIndex.Create(). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). Exec(ctx)
func (*VulnStatusIndexCreate) OnConflictColumns ¶
func (vsic *VulnStatusIndexCreate) OnConflictColumns(columns ...string) *VulnStatusIndexUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.VulnStatusIndex.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*VulnStatusIndexCreate) Save ¶
func (vsic *VulnStatusIndexCreate) Save(ctx context.Context) (*VulnStatusIndex, error)
Save creates the VulnStatusIndex in the database.
func (*VulnStatusIndexCreate) SaveX ¶
func (vsic *VulnStatusIndexCreate) SaveX(ctx context.Context) *VulnStatusIndex
SaveX calls Save and panics if Save returns an error.
func (*VulnStatusIndexCreate) SetID ¶
func (vsic *VulnStatusIndexCreate) SetID(s string) *VulnStatusIndexCreate
SetID sets the "id" field.
func (*VulnStatusIndexCreate) SetLatest ¶ added in v0.0.6
func (vsic *VulnStatusIndexCreate) SetLatest(v *VulnStatus) *VulnStatusIndexCreate
SetLatest sets the "latest" edge to the VulnStatus entity.
func (*VulnStatusIndexCreate) SetLatestID ¶ added in v0.0.6
func (vsic *VulnStatusIndexCreate) SetLatestID(id int) *VulnStatusIndexCreate
SetLatestID sets the "latest" edge to the VulnStatus entity by ID.
func (*VulnStatusIndexCreate) SetNillableLatestID ¶ added in v0.0.6
func (vsic *VulnStatusIndexCreate) SetNillableLatestID(id *int) *VulnStatusIndexCreate
SetNillableLatestID sets the "latest" edge to the VulnStatus entity by ID if the given value is not nil.
type VulnStatusIndexCreateBulk ¶
type VulnStatusIndexCreateBulk struct {
// contains filtered or unexported fields
}
VulnStatusIndexCreateBulk is the builder for creating many VulnStatusIndex entities in bulk.
func (*VulnStatusIndexCreateBulk) Exec ¶
func (vsicb *VulnStatusIndexCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusIndexCreateBulk) ExecX ¶
func (vsicb *VulnStatusIndexCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexCreateBulk) OnConflict ¶
func (vsicb *VulnStatusIndexCreateBulk) OnConflict(opts ...sql.ConflictOption) *VulnStatusIndexUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.VulnStatusIndex.CreateBulk(builders...). OnConflict( // Update the row with the new values // the was proposed for insertion. sql.ResolveWithNewValues(), ). Exec(ctx)
func (*VulnStatusIndexCreateBulk) OnConflictColumns ¶
func (vsicb *VulnStatusIndexCreateBulk) OnConflictColumns(columns ...string) *VulnStatusIndexUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.VulnStatusIndex.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*VulnStatusIndexCreateBulk) Save ¶
func (vsicb *VulnStatusIndexCreateBulk) Save(ctx context.Context) ([]*VulnStatusIndex, error)
Save creates the VulnStatusIndex entities in the database.
func (*VulnStatusIndexCreateBulk) SaveX ¶
func (vsicb *VulnStatusIndexCreateBulk) SaveX(ctx context.Context) []*VulnStatusIndex
SaveX is like Save, but panics if an error occurs.
type VulnStatusIndexDelete ¶
type VulnStatusIndexDelete struct {
// contains filtered or unexported fields
}
VulnStatusIndexDelete is the builder for deleting a VulnStatusIndex entity.
func (*VulnStatusIndexDelete) Exec ¶
func (vsid *VulnStatusIndexDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*VulnStatusIndexDelete) ExecX ¶
func (vsid *VulnStatusIndexDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexDelete) Where ¶
func (vsid *VulnStatusIndexDelete) Where(ps ...predicate.VulnStatusIndex) *VulnStatusIndexDelete
Where appends a list predicates to the VulnStatusIndexDelete builder.
type VulnStatusIndexDeleteOne ¶
type VulnStatusIndexDeleteOne struct {
// contains filtered or unexported fields
}
VulnStatusIndexDeleteOne is the builder for deleting a single VulnStatusIndex entity.
func (*VulnStatusIndexDeleteOne) Exec ¶
func (vsido *VulnStatusIndexDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*VulnStatusIndexDeleteOne) ExecX ¶
func (vsido *VulnStatusIndexDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type VulnStatusIndexEdges ¶
type VulnStatusIndexEdges struct { // Latest holds the value of the latest edge. Latest *VulnStatus `json:"latest,omitempty"` // Status holds the value of the status edge. Status []*VulnStatus `json:"status,omitempty"` // contains filtered or unexported fields }
VulnStatusIndexEdges holds the relations/edges for other nodes in the graph.
func (VulnStatusIndexEdges) LatestOrErr ¶ added in v0.0.6
func (e VulnStatusIndexEdges) LatestOrErr() (*VulnStatus, error)
LatestOrErr returns the Latest value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (VulnStatusIndexEdges) StatusOrErr ¶
func (e VulnStatusIndexEdges) StatusOrErr() ([]*VulnStatus, error)
StatusOrErr returns the Status value or an error if the edge was not loaded in eager-loading.
type VulnStatusIndexGroupBy ¶
type VulnStatusIndexGroupBy struct {
// contains filtered or unexported fields
}
VulnStatusIndexGroupBy is the group-by builder for VulnStatusIndex entities.
func (*VulnStatusIndexGroupBy) Aggregate ¶
func (vsigb *VulnStatusIndexGroupBy) Aggregate(fns ...AggregateFunc) *VulnStatusIndexGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*VulnStatusIndexGroupBy) Bool ¶
func (vsigb *VulnStatusIndexGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) BoolX ¶
func (vsigb *VulnStatusIndexGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) Bools ¶
func (vsigb *VulnStatusIndexGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) BoolsX ¶
func (vsigb *VulnStatusIndexGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) Float64 ¶
func (vsigb *VulnStatusIndexGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) Float64X ¶
func (vsigb *VulnStatusIndexGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) Float64s ¶
func (vsigb *VulnStatusIndexGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) Float64sX ¶
func (vsigb *VulnStatusIndexGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) Int ¶
func (vsigb *VulnStatusIndexGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) IntX ¶
func (vsigb *VulnStatusIndexGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) Ints ¶
func (vsigb *VulnStatusIndexGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) IntsX ¶
func (vsigb *VulnStatusIndexGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) Scan ¶
func (vsigb *VulnStatusIndexGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*VulnStatusIndexGroupBy) ScanX ¶
func (vsigb *VulnStatusIndexGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*VulnStatusIndexGroupBy) String ¶
func (vsigb *VulnStatusIndexGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnStatusIndexGroupBy) StringX ¶
func (vsigb *VulnStatusIndexGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type VulnStatusIndexMutation ¶
type VulnStatusIndexMutation struct {
// contains filtered or unexported fields
}
VulnStatusIndexMutation represents an operation that mutates the VulnStatusIndex nodes in the graph.
func (*VulnStatusIndexMutation) AddField ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) AddStatuIDs ¶
func (m *VulnStatusIndexMutation) AddStatuIDs(ids ...int)
AddStatuIDs adds the "status" edge to the VulnStatus entity by ids.
func (*VulnStatusIndexMutation) AddedEdges ¶
func (m *VulnStatusIndexMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*VulnStatusIndexMutation) AddedField ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) AddedFields ¶
func (m *VulnStatusIndexMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*VulnStatusIndexMutation) AddedIDs ¶
func (m *VulnStatusIndexMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*VulnStatusIndexMutation) ClearEdge ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) ClearField ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) ClearLatest ¶ added in v0.0.6
func (m *VulnStatusIndexMutation) ClearLatest()
ClearLatest clears the "latest" edge to the VulnStatus entity.
func (*VulnStatusIndexMutation) ClearStatus ¶
func (m *VulnStatusIndexMutation) ClearStatus()
ClearStatus clears the "status" edge to the VulnStatus entity.
func (*VulnStatusIndexMutation) ClearedEdges ¶
func (m *VulnStatusIndexMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*VulnStatusIndexMutation) ClearedFields ¶
func (m *VulnStatusIndexMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (VulnStatusIndexMutation) Client ¶
func (m VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) EdgeCleared ¶
func (m *VulnStatusIndexMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*VulnStatusIndexMutation) Field ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) FieldCleared ¶
func (m *VulnStatusIndexMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*VulnStatusIndexMutation) Fields ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) ID ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) LatestCleared ¶ added in v0.0.6
func (m *VulnStatusIndexMutation) LatestCleared() bool
LatestCleared reports if the "latest" edge to the VulnStatus entity was cleared.
func (*VulnStatusIndexMutation) LatestID ¶ added in v0.0.6
func (m *VulnStatusIndexMutation) LatestID() (id int, exists bool)
LatestID returns the "latest" edge ID in the mutation.
func (*VulnStatusIndexMutation) LatestIDs ¶ added in v0.0.6
func (m *VulnStatusIndexMutation) LatestIDs() (ids []int)
LatestIDs returns the "latest" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use LatestID instead. It exists only for internal usage by the builders.
func (*VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) Op ¶
func (m *VulnStatusIndexMutation) Op() Op
Op returns the operation name.
func (*VulnStatusIndexMutation) RemoveStatuIDs ¶
func (m *VulnStatusIndexMutation) RemoveStatuIDs(ids ...int)
RemoveStatuIDs removes the "status" edge to the VulnStatus entity by IDs.
func (*VulnStatusIndexMutation) RemovedEdges ¶
func (m *VulnStatusIndexMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*VulnStatusIndexMutation) RemovedIDs ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) RemovedStatusIDs ¶
func (m *VulnStatusIndexMutation) RemovedStatusIDs() (ids []int)
RemovedStatus returns the removed IDs of the "status" edge to the VulnStatus entity.
func (*VulnStatusIndexMutation) ResetEdge ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) ResetField ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) ResetLatest ¶ added in v0.0.6
func (m *VulnStatusIndexMutation) ResetLatest()
ResetLatest resets all changes to the "latest" edge.
func (*VulnStatusIndexMutation) ResetStatus ¶
func (m *VulnStatusIndexMutation) ResetStatus()
ResetStatus resets all changes to the "status" edge.
func (*VulnStatusIndexMutation) SetField ¶
func (m *VulnStatusIndexMutation) 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 (*VulnStatusIndexMutation) SetID ¶
func (m *VulnStatusIndexMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of VulnStatusIndex entities.
func (*VulnStatusIndexMutation) SetLatestID ¶ added in v0.0.6
func (m *VulnStatusIndexMutation) SetLatestID(id int)
SetLatestID sets the "latest" edge to the VulnStatus entity by id.
func (*VulnStatusIndexMutation) StatusCleared ¶
func (m *VulnStatusIndexMutation) StatusCleared() bool
StatusCleared reports if the "status" edge to the VulnStatus entity was cleared.
func (*VulnStatusIndexMutation) StatusIDs ¶
func (m *VulnStatusIndexMutation) StatusIDs() (ids []int)
StatusIDs returns the "status" edge IDs in the mutation.
func (VulnStatusIndexMutation) Tx ¶
func (m VulnStatusIndexMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*VulnStatusIndexMutation) Type ¶
func (m *VulnStatusIndexMutation) Type() string
Type returns the node type of this mutation (VulnStatusIndex).
func (*VulnStatusIndexMutation) Where ¶
func (m *VulnStatusIndexMutation) Where(ps ...predicate.VulnStatusIndex)
Where appends a list predicates to the VulnStatusIndexMutation builder.
type VulnStatusIndexQuery ¶
type VulnStatusIndexQuery struct {
// contains filtered or unexported fields
}
VulnStatusIndexQuery is the builder for querying VulnStatusIndex entities.
func (*VulnStatusIndexQuery) All ¶
func (vsiq *VulnStatusIndexQuery) All(ctx context.Context) ([]*VulnStatusIndex, error)
All executes the query and returns a list of VulnStatusIndexes.
func (*VulnStatusIndexQuery) AllX ¶
func (vsiq *VulnStatusIndexQuery) AllX(ctx context.Context) []*VulnStatusIndex
AllX is like All, but panics if an error occurs.
func (*VulnStatusIndexQuery) Clone ¶
func (vsiq *VulnStatusIndexQuery) Clone() *VulnStatusIndexQuery
Clone returns a duplicate of the VulnStatusIndexQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*VulnStatusIndexQuery) Count ¶
func (vsiq *VulnStatusIndexQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*VulnStatusIndexQuery) CountX ¶
func (vsiq *VulnStatusIndexQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*VulnStatusIndexQuery) Exist ¶
func (vsiq *VulnStatusIndexQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*VulnStatusIndexQuery) ExistX ¶
func (vsiq *VulnStatusIndexQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*VulnStatusIndexQuery) First ¶
func (vsiq *VulnStatusIndexQuery) First(ctx context.Context) (*VulnStatusIndex, error)
First returns the first VulnStatusIndex entity from the query. Returns a *NotFoundError when no VulnStatusIndex was found.
func (*VulnStatusIndexQuery) FirstID ¶
func (vsiq *VulnStatusIndexQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first VulnStatusIndex ID from the query. Returns a *NotFoundError when no VulnStatusIndex ID was found.
func (*VulnStatusIndexQuery) FirstIDX ¶
func (vsiq *VulnStatusIndexQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*VulnStatusIndexQuery) FirstX ¶
func (vsiq *VulnStatusIndexQuery) FirstX(ctx context.Context) *VulnStatusIndex
FirstX is like First, but panics if an error occurs.
func (*VulnStatusIndexQuery) GroupBy ¶
func (vsiq *VulnStatusIndexQuery) GroupBy(field string, fields ...string) *VulnStatusIndexGroupBy
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 (*VulnStatusIndexQuery) IDs ¶
func (vsiq *VulnStatusIndexQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of VulnStatusIndex IDs.
func (*VulnStatusIndexQuery) IDsX ¶
func (vsiq *VulnStatusIndexQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*VulnStatusIndexQuery) Limit ¶
func (vsiq *VulnStatusIndexQuery) Limit(limit int) *VulnStatusIndexQuery
Limit adds a limit step to the query.
func (*VulnStatusIndexQuery) Offset ¶
func (vsiq *VulnStatusIndexQuery) Offset(offset int) *VulnStatusIndexQuery
Offset adds an offset step to the query.
func (*VulnStatusIndexQuery) Only ¶
func (vsiq *VulnStatusIndexQuery) Only(ctx context.Context) (*VulnStatusIndex, error)
Only returns a single VulnStatusIndex entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one VulnStatusIndex entity is not found. Returns a *NotFoundError when no VulnStatusIndex entities are found.
func (*VulnStatusIndexQuery) OnlyID ¶
func (vsiq *VulnStatusIndexQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID is like Only, but returns the only VulnStatusIndex ID in the query. Returns a *NotSingularError when exactly one VulnStatusIndex ID is not found. Returns a *NotFoundError when no entities are found.
func (*VulnStatusIndexQuery) OnlyIDX ¶
func (vsiq *VulnStatusIndexQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*VulnStatusIndexQuery) OnlyX ¶
func (vsiq *VulnStatusIndexQuery) OnlyX(ctx context.Context) *VulnStatusIndex
OnlyX is like Only, but panics if an error occurs.
func (*VulnStatusIndexQuery) Order ¶
func (vsiq *VulnStatusIndexQuery) Order(o ...OrderFunc) *VulnStatusIndexQuery
Order adds an order step to the query.
func (*VulnStatusIndexQuery) QueryLatest ¶ added in v0.0.6
func (vsiq *VulnStatusIndexQuery) QueryLatest() *VulnStatusQuery
QueryLatest chains the current query on the "latest" edge.
func (*VulnStatusIndexQuery) QueryStatus ¶
func (vsiq *VulnStatusIndexQuery) QueryStatus() *VulnStatusQuery
QueryStatus chains the current query on the "status" edge.
func (*VulnStatusIndexQuery) Select ¶
func (vsiq *VulnStatusIndexQuery) Select(fields ...string) *VulnStatusIndexSelect
Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.
func (*VulnStatusIndexQuery) Unique ¶
func (vsiq *VulnStatusIndexQuery) Unique(unique bool) *VulnStatusIndexQuery
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 (*VulnStatusIndexQuery) Where ¶
func (vsiq *VulnStatusIndexQuery) Where(ps ...predicate.VulnStatusIndex) *VulnStatusIndexQuery
Where adds a new predicate for the VulnStatusIndexQuery builder.
func (*VulnStatusIndexQuery) WithLatest ¶ added in v0.0.6
func (vsiq *VulnStatusIndexQuery) WithLatest(opts ...func(*VulnStatusQuery)) *VulnStatusIndexQuery
WithLatest tells the query-builder to eager-load the nodes that are connected to the "latest" edge. The optional arguments are used to configure the query builder of the edge.
func (*VulnStatusIndexQuery) WithStatus ¶
func (vsiq *VulnStatusIndexQuery) WithStatus(opts ...func(*VulnStatusQuery)) *VulnStatusIndexQuery
WithStatus tells the query-builder to eager-load the nodes that are connected to the "status" edge. The optional arguments are used to configure the query builder of the edge.
type VulnStatusIndexSelect ¶
type VulnStatusIndexSelect struct { *VulnStatusIndexQuery // contains filtered or unexported fields }
VulnStatusIndexSelect is the builder for selecting fields of VulnStatusIndex entities.
func (*VulnStatusIndexSelect) Bool ¶
func (vsis *VulnStatusIndexSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) BoolX ¶
func (vsis *VulnStatusIndexSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*VulnStatusIndexSelect) Bools ¶
func (vsis *VulnStatusIndexSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) BoolsX ¶
func (vsis *VulnStatusIndexSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*VulnStatusIndexSelect) Float64 ¶
func (vsis *VulnStatusIndexSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) Float64X ¶
func (vsis *VulnStatusIndexSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*VulnStatusIndexSelect) Float64s ¶
func (vsis *VulnStatusIndexSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) Float64sX ¶
func (vsis *VulnStatusIndexSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*VulnStatusIndexSelect) Int ¶
func (vsis *VulnStatusIndexSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) IntX ¶
func (vsis *VulnStatusIndexSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*VulnStatusIndexSelect) Ints ¶
func (vsis *VulnStatusIndexSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) IntsX ¶
func (vsis *VulnStatusIndexSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*VulnStatusIndexSelect) Scan ¶
func (vsis *VulnStatusIndexSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*VulnStatusIndexSelect) ScanX ¶
func (vsis *VulnStatusIndexSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*VulnStatusIndexSelect) String ¶
func (vsis *VulnStatusIndexSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*VulnStatusIndexSelect) StringX ¶
func (vsis *VulnStatusIndexSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type VulnStatusIndexUpdate ¶
type VulnStatusIndexUpdate struct {
// contains filtered or unexported fields
}
VulnStatusIndexUpdate is the builder for updating VulnStatusIndex entities.
func (*VulnStatusIndexUpdate) AddStatuIDs ¶
func (vsiu *VulnStatusIndexUpdate) AddStatuIDs(ids ...int) *VulnStatusIndexUpdate
AddStatuIDs adds the "status" edge to the VulnStatus entity by IDs.
func (*VulnStatusIndexUpdate) AddStatus ¶
func (vsiu *VulnStatusIndexUpdate) AddStatus(v ...*VulnStatus) *VulnStatusIndexUpdate
AddStatus adds the "status" edges to the VulnStatus entity.
func (*VulnStatusIndexUpdate) ClearLatest ¶ added in v0.0.6
func (vsiu *VulnStatusIndexUpdate) ClearLatest() *VulnStatusIndexUpdate
ClearLatest clears the "latest" edge to the VulnStatus entity.
func (*VulnStatusIndexUpdate) ClearStatus ¶
func (vsiu *VulnStatusIndexUpdate) ClearStatus() *VulnStatusIndexUpdate
ClearStatus clears all "status" edges to the VulnStatus entity.
func (*VulnStatusIndexUpdate) Exec ¶
func (vsiu *VulnStatusIndexUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusIndexUpdate) ExecX ¶
func (vsiu *VulnStatusIndexUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexUpdate) Mutation ¶
func (vsiu *VulnStatusIndexUpdate) Mutation() *VulnStatusIndexMutation
Mutation returns the VulnStatusIndexMutation object of the builder.
func (*VulnStatusIndexUpdate) RemoveStatuIDs ¶
func (vsiu *VulnStatusIndexUpdate) RemoveStatuIDs(ids ...int) *VulnStatusIndexUpdate
RemoveStatuIDs removes the "status" edge to VulnStatus entities by IDs.
func (*VulnStatusIndexUpdate) RemoveStatus ¶
func (vsiu *VulnStatusIndexUpdate) RemoveStatus(v ...*VulnStatus) *VulnStatusIndexUpdate
RemoveStatus removes "status" edges to VulnStatus entities.
func (*VulnStatusIndexUpdate) Save ¶
func (vsiu *VulnStatusIndexUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*VulnStatusIndexUpdate) SaveX ¶
func (vsiu *VulnStatusIndexUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*VulnStatusIndexUpdate) SetLatest ¶ added in v0.0.6
func (vsiu *VulnStatusIndexUpdate) SetLatest(v *VulnStatus) *VulnStatusIndexUpdate
SetLatest sets the "latest" edge to the VulnStatus entity.
func (*VulnStatusIndexUpdate) SetLatestID ¶ added in v0.0.6
func (vsiu *VulnStatusIndexUpdate) SetLatestID(id int) *VulnStatusIndexUpdate
SetLatestID sets the "latest" edge to the VulnStatus entity by ID.
func (*VulnStatusIndexUpdate) SetNillableLatestID ¶ added in v0.0.6
func (vsiu *VulnStatusIndexUpdate) SetNillableLatestID(id *int) *VulnStatusIndexUpdate
SetNillableLatestID sets the "latest" edge to the VulnStatus entity by ID if the given value is not nil.
func (*VulnStatusIndexUpdate) Where ¶
func (vsiu *VulnStatusIndexUpdate) Where(ps ...predicate.VulnStatusIndex) *VulnStatusIndexUpdate
Where appends a list predicates to the VulnStatusIndexUpdate builder.
type VulnStatusIndexUpdateOne ¶
type VulnStatusIndexUpdateOne struct {
// contains filtered or unexported fields
}
VulnStatusIndexUpdateOne is the builder for updating a single VulnStatusIndex entity.
func (*VulnStatusIndexUpdateOne) AddStatuIDs ¶
func (vsiuo *VulnStatusIndexUpdateOne) AddStatuIDs(ids ...int) *VulnStatusIndexUpdateOne
AddStatuIDs adds the "status" edge to the VulnStatus entity by IDs.
func (*VulnStatusIndexUpdateOne) AddStatus ¶
func (vsiuo *VulnStatusIndexUpdateOne) AddStatus(v ...*VulnStatus) *VulnStatusIndexUpdateOne
AddStatus adds the "status" edges to the VulnStatus entity.
func (*VulnStatusIndexUpdateOne) ClearLatest ¶ added in v0.0.6
func (vsiuo *VulnStatusIndexUpdateOne) ClearLatest() *VulnStatusIndexUpdateOne
ClearLatest clears the "latest" edge to the VulnStatus entity.
func (*VulnStatusIndexUpdateOne) ClearStatus ¶
func (vsiuo *VulnStatusIndexUpdateOne) ClearStatus() *VulnStatusIndexUpdateOne
ClearStatus clears all "status" edges to the VulnStatus entity.
func (*VulnStatusIndexUpdateOne) Exec ¶
func (vsiuo *VulnStatusIndexUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*VulnStatusIndexUpdateOne) ExecX ¶
func (vsiuo *VulnStatusIndexUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexUpdateOne) Mutation ¶
func (vsiuo *VulnStatusIndexUpdateOne) Mutation() *VulnStatusIndexMutation
Mutation returns the VulnStatusIndexMutation object of the builder.
func (*VulnStatusIndexUpdateOne) RemoveStatuIDs ¶
func (vsiuo *VulnStatusIndexUpdateOne) RemoveStatuIDs(ids ...int) *VulnStatusIndexUpdateOne
RemoveStatuIDs removes the "status" edge to VulnStatus entities by IDs.
func (*VulnStatusIndexUpdateOne) RemoveStatus ¶
func (vsiuo *VulnStatusIndexUpdateOne) RemoveStatus(v ...*VulnStatus) *VulnStatusIndexUpdateOne
RemoveStatus removes "status" edges to VulnStatus entities.
func (*VulnStatusIndexUpdateOne) Save ¶
func (vsiuo *VulnStatusIndexUpdateOne) Save(ctx context.Context) (*VulnStatusIndex, error)
Save executes the query and returns the updated VulnStatusIndex entity.
func (*VulnStatusIndexUpdateOne) SaveX ¶
func (vsiuo *VulnStatusIndexUpdateOne) SaveX(ctx context.Context) *VulnStatusIndex
SaveX is like Save, but panics if an error occurs.
func (*VulnStatusIndexUpdateOne) Select ¶
func (vsiuo *VulnStatusIndexUpdateOne) Select(field string, fields ...string) *VulnStatusIndexUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*VulnStatusIndexUpdateOne) SetLatest ¶ added in v0.0.6
func (vsiuo *VulnStatusIndexUpdateOne) SetLatest(v *VulnStatus) *VulnStatusIndexUpdateOne
SetLatest sets the "latest" edge to the VulnStatus entity.
func (*VulnStatusIndexUpdateOne) SetLatestID ¶ added in v0.0.6
func (vsiuo *VulnStatusIndexUpdateOne) SetLatestID(id int) *VulnStatusIndexUpdateOne
SetLatestID sets the "latest" edge to the VulnStatus entity by ID.
func (*VulnStatusIndexUpdateOne) SetNillableLatestID ¶ added in v0.0.6
func (vsiuo *VulnStatusIndexUpdateOne) SetNillableLatestID(id *int) *VulnStatusIndexUpdateOne
SetNillableLatestID sets the "latest" edge to the VulnStatus entity by ID if the given value is not nil.
type VulnStatusIndexUpsert ¶
VulnStatusIndexUpsert is the "OnConflict" setter.
type VulnStatusIndexUpsertBulk ¶
type VulnStatusIndexUpsertBulk struct {
// contains filtered or unexported fields
}
VulnStatusIndexUpsertBulk is the builder for "upsert"-ing a bulk of VulnStatusIndex nodes.
func (*VulnStatusIndexUpsertBulk) DoNothing ¶
func (u *VulnStatusIndexUpsertBulk) DoNothing() *VulnStatusIndexUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*VulnStatusIndexUpsertBulk) Exec ¶
func (u *VulnStatusIndexUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusIndexUpsertBulk) ExecX ¶
func (u *VulnStatusIndexUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexUpsertBulk) Ignore ¶
func (u *VulnStatusIndexUpsertBulk) Ignore() *VulnStatusIndexUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.VulnStatusIndex.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*VulnStatusIndexUpsertBulk) Update ¶
func (u *VulnStatusIndexUpsertBulk) Update(set func(*VulnStatusIndexUpsert)) *VulnStatusIndexUpsertBulk
Update allows overriding fields `UPDATE` values. See the VulnStatusIndexCreateBulk.OnConflict documentation for more info.
func (*VulnStatusIndexUpsertBulk) UpdateNewValues ¶
func (u *VulnStatusIndexUpsertBulk) UpdateNewValues() *VulnStatusIndexUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.VulnStatusIndex.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
type VulnStatusIndexUpsertOne ¶
type VulnStatusIndexUpsertOne struct {
// contains filtered or unexported fields
}
VulnStatusIndexUpsertOne is the builder for "upsert"-ing
one VulnStatusIndex node.
func (*VulnStatusIndexUpsertOne) DoNothing ¶
func (u *VulnStatusIndexUpsertOne) DoNothing() *VulnStatusIndexUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*VulnStatusIndexUpsertOne) Exec ¶
func (u *VulnStatusIndexUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusIndexUpsertOne) ExecX ¶
func (u *VulnStatusIndexUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusIndexUpsertOne) ID ¶
func (u *VulnStatusIndexUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*VulnStatusIndexUpsertOne) IDX ¶
func (u *VulnStatusIndexUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*VulnStatusIndexUpsertOne) Ignore ¶
func (u *VulnStatusIndexUpsertOne) Ignore() *VulnStatusIndexUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.VulnStatusIndex.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*VulnStatusIndexUpsertOne) Update ¶
func (u *VulnStatusIndexUpsertOne) Update(set func(*VulnStatusIndexUpsert)) *VulnStatusIndexUpsertOne
Update allows overriding fields `UPDATE` values. See the VulnStatusIndexCreate.OnConflict documentation for more info.
func (*VulnStatusIndexUpsertOne) UpdateNewValues ¶
func (u *VulnStatusIndexUpsertOne) UpdateNewValues() *VulnStatusIndexUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.VulnStatusIndex.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
type VulnStatusIndexes ¶
type VulnStatusIndexes []*VulnStatusIndex
VulnStatusIndexes is a parsable slice of VulnStatusIndex.
type VulnStatusMutation ¶
type VulnStatusMutation struct {
// contains filtered or unexported fields
}
VulnStatusMutation represents an operation that mutates the VulnStatus nodes in the graph.
func (*VulnStatusMutation) AddCreatedAt ¶
func (m *VulnStatusMutation) AddCreatedAt(i int64)
AddCreatedAt adds i to the "created_at" field.
func (*VulnStatusMutation) AddExpiresAt ¶
func (m *VulnStatusMutation) AddExpiresAt(i int64)
AddExpiresAt adds i to the "expires_at" field.
func (*VulnStatusMutation) AddField ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) AddedCreatedAt ¶
func (m *VulnStatusMutation) AddedCreatedAt() (r int64, exists bool)
AddedCreatedAt returns the value that was added to the "created_at" field in this mutation.
func (*VulnStatusMutation) AddedEdges ¶
func (m *VulnStatusMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*VulnStatusMutation) AddedExpiresAt ¶
func (m *VulnStatusMutation) AddedExpiresAt() (r int64, exists bool)
AddedExpiresAt returns the value that was added to the "expires_at" field in this mutation.
func (*VulnStatusMutation) AddedField ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) AddedFields ¶
func (m *VulnStatusMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*VulnStatusMutation) AddedIDs ¶
func (m *VulnStatusMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*VulnStatusMutation) AuthorCleared ¶
func (m *VulnStatusMutation) AuthorCleared() bool
AuthorCleared reports if the "author" edge to the User entity was cleared.
func (*VulnStatusMutation) AuthorID ¶
func (m *VulnStatusMutation) AuthorID() (id int, exists bool)
AuthorID returns the "author" edge ID in the mutation.
func (*VulnStatusMutation) AuthorIDs ¶
func (m *VulnStatusMutation) AuthorIDs() (ids []int)
AuthorIDs returns the "author" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AuthorID instead. It exists only for internal usage by the builders.
func (*VulnStatusMutation) ClearAuthor ¶
func (m *VulnStatusMutation) ClearAuthor()
ClearAuthor clears the "author" edge to the User entity.
func (*VulnStatusMutation) ClearEdge ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) ClearField ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) ClearedEdges ¶
func (m *VulnStatusMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*VulnStatusMutation) ClearedFields ¶
func (m *VulnStatusMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (VulnStatusMutation) Client ¶
func (m VulnStatusMutation) 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 (*VulnStatusMutation) Comment ¶
func (m *VulnStatusMutation) Comment() (r string, exists bool)
Comment returns the value of the "comment" field in the mutation.
func (*VulnStatusMutation) CreatedAt ¶
func (m *VulnStatusMutation) CreatedAt() (r int64, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*VulnStatusMutation) EdgeCleared ¶
func (m *VulnStatusMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*VulnStatusMutation) ExpiresAt ¶
func (m *VulnStatusMutation) ExpiresAt() (r int64, exists bool)
ExpiresAt returns the value of the "expires_at" field in the mutation.
func (*VulnStatusMutation) Field ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) FieldCleared ¶
func (m *VulnStatusMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*VulnStatusMutation) Fields ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) ID ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) OldComment ¶
func (m *VulnStatusMutation) OldComment(ctx context.Context) (v string, err error)
OldComment returns the old "comment" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) OldCreatedAt ¶
func (m *VulnStatusMutation) OldCreatedAt(ctx context.Context) (v int64, err error)
OldCreatedAt returns the old "created_at" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) OldExpiresAt ¶
func (m *VulnStatusMutation) OldExpiresAt(ctx context.Context) (v int64, err error)
OldExpiresAt returns the old "expires_at" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) 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 (*VulnStatusMutation) OldPkgName ¶
func (m *VulnStatusMutation) OldPkgName(ctx context.Context) (v string, err error)
OldPkgName returns the old "pkg_name" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) OldPkgType ¶
func (m *VulnStatusMutation) OldPkgType(ctx context.Context) (v string, err error)
OldPkgType returns the old "pkg_type" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) OldSource ¶
func (m *VulnStatusMutation) OldSource(ctx context.Context) (v string, err error)
OldSource returns the old "source" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) OldStatus ¶
func (m *VulnStatusMutation) OldStatus(ctx context.Context) (v types.VulnStatusType, err error)
OldStatus returns the old "status" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) OldVulnID ¶
func (m *VulnStatusMutation) OldVulnID(ctx context.Context) (v string, err error)
OldVulnID returns the old "vuln_id" field's value of the VulnStatus entity. If the VulnStatus 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 (*VulnStatusMutation) PkgName ¶
func (m *VulnStatusMutation) PkgName() (r string, exists bool)
PkgName returns the value of the "pkg_name" field in the mutation.
func (*VulnStatusMutation) PkgType ¶
func (m *VulnStatusMutation) PkgType() (r string, exists bool)
PkgType returns the value of the "pkg_type" field in the mutation.
func (*VulnStatusMutation) RemovedEdges ¶
func (m *VulnStatusMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*VulnStatusMutation) RemovedIDs ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) ResetAuthor ¶
func (m *VulnStatusMutation) ResetAuthor()
ResetAuthor resets all changes to the "author" edge.
func (*VulnStatusMutation) ResetComment ¶
func (m *VulnStatusMutation) ResetComment()
ResetComment resets all changes to the "comment" field.
func (*VulnStatusMutation) ResetCreatedAt ¶
func (m *VulnStatusMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*VulnStatusMutation) ResetEdge ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) ResetExpiresAt ¶
func (m *VulnStatusMutation) ResetExpiresAt()
ResetExpiresAt resets all changes to the "expires_at" field.
func (*VulnStatusMutation) ResetField ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) ResetPkgName ¶
func (m *VulnStatusMutation) ResetPkgName()
ResetPkgName resets all changes to the "pkg_name" field.
func (*VulnStatusMutation) ResetPkgType ¶
func (m *VulnStatusMutation) ResetPkgType()
ResetPkgType resets all changes to the "pkg_type" field.
func (*VulnStatusMutation) ResetSource ¶
func (m *VulnStatusMutation) ResetSource()
ResetSource resets all changes to the "source" field.
func (*VulnStatusMutation) ResetStatus ¶
func (m *VulnStatusMutation) ResetStatus()
ResetStatus resets all changes to the "status" field.
func (*VulnStatusMutation) ResetVulnID ¶
func (m *VulnStatusMutation) ResetVulnID()
ResetVulnID resets all changes to the "vuln_id" field.
func (*VulnStatusMutation) SetAuthorID ¶
func (m *VulnStatusMutation) SetAuthorID(id int)
SetAuthorID sets the "author" edge to the User entity by id.
func (*VulnStatusMutation) SetComment ¶
func (m *VulnStatusMutation) SetComment(s string)
SetComment sets the "comment" field.
func (*VulnStatusMutation) SetCreatedAt ¶
func (m *VulnStatusMutation) SetCreatedAt(i int64)
SetCreatedAt sets the "created_at" field.
func (*VulnStatusMutation) SetExpiresAt ¶
func (m *VulnStatusMutation) SetExpiresAt(i int64)
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusMutation) SetField ¶
func (m *VulnStatusMutation) 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 (*VulnStatusMutation) SetPkgName ¶
func (m *VulnStatusMutation) SetPkgName(s string)
SetPkgName sets the "pkg_name" field.
func (*VulnStatusMutation) SetPkgType ¶
func (m *VulnStatusMutation) SetPkgType(s string)
SetPkgType sets the "pkg_type" field.
func (*VulnStatusMutation) SetSource ¶
func (m *VulnStatusMutation) SetSource(s string)
SetSource sets the "source" field.
func (*VulnStatusMutation) SetStatus ¶
func (m *VulnStatusMutation) SetStatus(tst types.VulnStatusType)
SetStatus sets the "status" field.
func (*VulnStatusMutation) SetVulnID ¶
func (m *VulnStatusMutation) SetVulnID(s string)
SetVulnID sets the "vuln_id" field.
func (*VulnStatusMutation) Source ¶
func (m *VulnStatusMutation) Source() (r string, exists bool)
Source returns the value of the "source" field in the mutation.
func (*VulnStatusMutation) Status ¶
func (m *VulnStatusMutation) Status() (r types.VulnStatusType, exists bool)
Status returns the value of the "status" field in the mutation.
func (VulnStatusMutation) Tx ¶
func (m VulnStatusMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*VulnStatusMutation) Type ¶
func (m *VulnStatusMutation) Type() string
Type returns the node type of this mutation (VulnStatus).
func (*VulnStatusMutation) VulnID ¶
func (m *VulnStatusMutation) VulnID() (r string, exists bool)
VulnID returns the value of the "vuln_id" field in the mutation.
func (*VulnStatusMutation) Where ¶
func (m *VulnStatusMutation) Where(ps ...predicate.VulnStatus)
Where appends a list predicates to the VulnStatusMutation builder.
type VulnStatusQuery ¶
type VulnStatusQuery struct {
// contains filtered or unexported fields
}
VulnStatusQuery is the builder for querying VulnStatus entities.
func (*VulnStatusQuery) All ¶
func (vsq *VulnStatusQuery) All(ctx context.Context) ([]*VulnStatus, error)
All executes the query and returns a list of VulnStatusSlice.
func (*VulnStatusQuery) AllX ¶
func (vsq *VulnStatusQuery) AllX(ctx context.Context) []*VulnStatus
AllX is like All, but panics if an error occurs.
func (*VulnStatusQuery) Clone ¶
func (vsq *VulnStatusQuery) Clone() *VulnStatusQuery
Clone returns a duplicate of the VulnStatusQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*VulnStatusQuery) Count ¶
func (vsq *VulnStatusQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*VulnStatusQuery) CountX ¶
func (vsq *VulnStatusQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*VulnStatusQuery) Exist ¶
func (vsq *VulnStatusQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*VulnStatusQuery) ExistX ¶
func (vsq *VulnStatusQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*VulnStatusQuery) First ¶
func (vsq *VulnStatusQuery) First(ctx context.Context) (*VulnStatus, error)
First returns the first VulnStatus entity from the query. Returns a *NotFoundError when no VulnStatus was found.
func (*VulnStatusQuery) FirstID ¶
func (vsq *VulnStatusQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first VulnStatus ID from the query. Returns a *NotFoundError when no VulnStatus ID was found.
func (*VulnStatusQuery) FirstIDX ¶
func (vsq *VulnStatusQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*VulnStatusQuery) FirstX ¶
func (vsq *VulnStatusQuery) FirstX(ctx context.Context) *VulnStatus
FirstX is like First, but panics if an error occurs.
func (*VulnStatusQuery) GroupBy ¶
func (vsq *VulnStatusQuery) GroupBy(field string, fields ...string) *VulnStatusGroupBy
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 { Status types.VulnStatusType `json:"status,omitempty"` Count int `json:"count,omitempty"` } client.VulnStatus.Query(). GroupBy(vulnstatus.FieldStatus). Aggregate(ent.Count()). Scan(ctx, &v)
func (*VulnStatusQuery) IDs ¶
func (vsq *VulnStatusQuery) IDs(ctx context.Context) ([]int, error)
IDs executes the query and returns a list of VulnStatus IDs.
func (*VulnStatusQuery) IDsX ¶
func (vsq *VulnStatusQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*VulnStatusQuery) Limit ¶
func (vsq *VulnStatusQuery) Limit(limit int) *VulnStatusQuery
Limit adds a limit step to the query.
func (*VulnStatusQuery) Offset ¶
func (vsq *VulnStatusQuery) Offset(offset int) *VulnStatusQuery
Offset adds an offset step to the query.
func (*VulnStatusQuery) Only ¶
func (vsq *VulnStatusQuery) Only(ctx context.Context) (*VulnStatus, error)
Only returns a single VulnStatus entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one VulnStatus entity is not found. Returns a *NotFoundError when no VulnStatus entities are found.
func (*VulnStatusQuery) OnlyID ¶
func (vsq *VulnStatusQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only VulnStatus ID in the query. Returns a *NotSingularError when exactly one VulnStatus ID is not found. Returns a *NotFoundError when no entities are found.
func (*VulnStatusQuery) OnlyIDX ¶
func (vsq *VulnStatusQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*VulnStatusQuery) OnlyX ¶
func (vsq *VulnStatusQuery) OnlyX(ctx context.Context) *VulnStatus
OnlyX is like Only, but panics if an error occurs.
func (*VulnStatusQuery) Order ¶
func (vsq *VulnStatusQuery) Order(o ...OrderFunc) *VulnStatusQuery
Order adds an order step to the query.
func (*VulnStatusQuery) QueryAuthor ¶
func (vsq *VulnStatusQuery) QueryAuthor() *UserQuery
QueryAuthor chains the current query on the "author" edge.
func (*VulnStatusQuery) Select ¶
func (vsq *VulnStatusQuery) Select(fields ...string) *VulnStatusSelect
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 { Status types.VulnStatusType `json:"status,omitempty"` } client.VulnStatus.Query(). Select(vulnstatus.FieldStatus). Scan(ctx, &v)
func (*VulnStatusQuery) Unique ¶
func (vsq *VulnStatusQuery) Unique(unique bool) *VulnStatusQuery
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 (*VulnStatusQuery) Where ¶
func (vsq *VulnStatusQuery) Where(ps ...predicate.VulnStatus) *VulnStatusQuery
Where adds a new predicate for the VulnStatusQuery builder.
func (*VulnStatusQuery) WithAuthor ¶
func (vsq *VulnStatusQuery) WithAuthor(opts ...func(*UserQuery)) *VulnStatusQuery
WithAuthor tells the query-builder to eager-load the nodes that are connected to the "author" edge. The optional arguments are used to configure the query builder of the edge.
type VulnStatusSelect ¶
type VulnStatusSelect struct { *VulnStatusQuery // contains filtered or unexported fields }
VulnStatusSelect is the builder for selecting fields of VulnStatus entities.
func (*VulnStatusSelect) Bool ¶
func (vss *VulnStatusSelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) BoolX ¶
func (vss *VulnStatusSelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*VulnStatusSelect) Bools ¶
func (vss *VulnStatusSelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) BoolsX ¶
func (vss *VulnStatusSelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*VulnStatusSelect) Float64 ¶
func (vss *VulnStatusSelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) Float64X ¶
func (vss *VulnStatusSelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*VulnStatusSelect) Float64s ¶
func (vss *VulnStatusSelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) Float64sX ¶
func (vss *VulnStatusSelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*VulnStatusSelect) Int ¶
func (vss *VulnStatusSelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) IntX ¶
func (vss *VulnStatusSelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*VulnStatusSelect) Ints ¶
func (vss *VulnStatusSelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) IntsX ¶
func (vss *VulnStatusSelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*VulnStatusSelect) Scan ¶
func (vss *VulnStatusSelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*VulnStatusSelect) ScanX ¶
func (vss *VulnStatusSelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*VulnStatusSelect) String ¶
func (vss *VulnStatusSelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*VulnStatusSelect) StringX ¶
func (vss *VulnStatusSelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type VulnStatusSlice ¶
type VulnStatusSlice []*VulnStatus
VulnStatusSlice is a parsable slice of VulnStatus.
type VulnStatusUpdate ¶
type VulnStatusUpdate struct {
// contains filtered or unexported fields
}
VulnStatusUpdate is the builder for updating VulnStatus entities.
func (*VulnStatusUpdate) AddCreatedAt ¶
func (vsu *VulnStatusUpdate) AddCreatedAt(i int64) *VulnStatusUpdate
AddCreatedAt adds i to the "created_at" field.
func (*VulnStatusUpdate) AddExpiresAt ¶
func (vsu *VulnStatusUpdate) AddExpiresAt(i int64) *VulnStatusUpdate
AddExpiresAt adds i to the "expires_at" field.
func (*VulnStatusUpdate) ClearAuthor ¶
func (vsu *VulnStatusUpdate) ClearAuthor() *VulnStatusUpdate
ClearAuthor clears the "author" edge to the User entity.
func (*VulnStatusUpdate) Exec ¶
func (vsu *VulnStatusUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusUpdate) ExecX ¶
func (vsu *VulnStatusUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusUpdate) Mutation ¶
func (vsu *VulnStatusUpdate) Mutation() *VulnStatusMutation
Mutation returns the VulnStatusMutation object of the builder.
func (*VulnStatusUpdate) Save ¶
func (vsu *VulnStatusUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*VulnStatusUpdate) SaveX ¶
func (vsu *VulnStatusUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*VulnStatusUpdate) SetAuthor ¶
func (vsu *VulnStatusUpdate) SetAuthor(u *User) *VulnStatusUpdate
SetAuthor sets the "author" edge to the User entity.
func (*VulnStatusUpdate) SetAuthorID ¶
func (vsu *VulnStatusUpdate) SetAuthorID(id int) *VulnStatusUpdate
SetAuthorID sets the "author" edge to the User entity by ID.
func (*VulnStatusUpdate) SetComment ¶
func (vsu *VulnStatusUpdate) SetComment(s string) *VulnStatusUpdate
SetComment sets the "comment" field.
func (*VulnStatusUpdate) SetCreatedAt ¶
func (vsu *VulnStatusUpdate) SetCreatedAt(i int64) *VulnStatusUpdate
SetCreatedAt sets the "created_at" field.
func (*VulnStatusUpdate) SetExpiresAt ¶
func (vsu *VulnStatusUpdate) SetExpiresAt(i int64) *VulnStatusUpdate
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusUpdate) SetNillableAuthorID ¶
func (vsu *VulnStatusUpdate) SetNillableAuthorID(id *int) *VulnStatusUpdate
SetNillableAuthorID sets the "author" edge to the User entity by ID if the given value is not nil.
func (*VulnStatusUpdate) SetPkgName ¶
func (vsu *VulnStatusUpdate) SetPkgName(s string) *VulnStatusUpdate
SetPkgName sets the "pkg_name" field.
func (*VulnStatusUpdate) SetPkgType ¶
func (vsu *VulnStatusUpdate) SetPkgType(s string) *VulnStatusUpdate
SetPkgType sets the "pkg_type" field.
func (*VulnStatusUpdate) SetSource ¶
func (vsu *VulnStatusUpdate) SetSource(s string) *VulnStatusUpdate
SetSource sets the "source" field.
func (*VulnStatusUpdate) SetStatus ¶
func (vsu *VulnStatusUpdate) SetStatus(tst types.VulnStatusType) *VulnStatusUpdate
SetStatus sets the "status" field.
func (*VulnStatusUpdate) SetVulnID ¶
func (vsu *VulnStatusUpdate) SetVulnID(s string) *VulnStatusUpdate
SetVulnID sets the "vuln_id" field.
func (*VulnStatusUpdate) Where ¶
func (vsu *VulnStatusUpdate) Where(ps ...predicate.VulnStatus) *VulnStatusUpdate
Where appends a list predicates to the VulnStatusUpdate builder.
type VulnStatusUpdateOne ¶
type VulnStatusUpdateOne struct {
// contains filtered or unexported fields
}
VulnStatusUpdateOne is the builder for updating a single VulnStatus entity.
func (*VulnStatusUpdateOne) AddCreatedAt ¶
func (vsuo *VulnStatusUpdateOne) AddCreatedAt(i int64) *VulnStatusUpdateOne
AddCreatedAt adds i to the "created_at" field.
func (*VulnStatusUpdateOne) AddExpiresAt ¶
func (vsuo *VulnStatusUpdateOne) AddExpiresAt(i int64) *VulnStatusUpdateOne
AddExpiresAt adds i to the "expires_at" field.
func (*VulnStatusUpdateOne) ClearAuthor ¶
func (vsuo *VulnStatusUpdateOne) ClearAuthor() *VulnStatusUpdateOne
ClearAuthor clears the "author" edge to the User entity.
func (*VulnStatusUpdateOne) Exec ¶
func (vsuo *VulnStatusUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*VulnStatusUpdateOne) ExecX ¶
func (vsuo *VulnStatusUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusUpdateOne) Mutation ¶
func (vsuo *VulnStatusUpdateOne) Mutation() *VulnStatusMutation
Mutation returns the VulnStatusMutation object of the builder.
func (*VulnStatusUpdateOne) Save ¶
func (vsuo *VulnStatusUpdateOne) Save(ctx context.Context) (*VulnStatus, error)
Save executes the query and returns the updated VulnStatus entity.
func (*VulnStatusUpdateOne) SaveX ¶
func (vsuo *VulnStatusUpdateOne) SaveX(ctx context.Context) *VulnStatus
SaveX is like Save, but panics if an error occurs.
func (*VulnStatusUpdateOne) Select ¶
func (vsuo *VulnStatusUpdateOne) Select(field string, fields ...string) *VulnStatusUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*VulnStatusUpdateOne) SetAuthor ¶
func (vsuo *VulnStatusUpdateOne) SetAuthor(u *User) *VulnStatusUpdateOne
SetAuthor sets the "author" edge to the User entity.
func (*VulnStatusUpdateOne) SetAuthorID ¶
func (vsuo *VulnStatusUpdateOne) SetAuthorID(id int) *VulnStatusUpdateOne
SetAuthorID sets the "author" edge to the User entity by ID.
func (*VulnStatusUpdateOne) SetComment ¶
func (vsuo *VulnStatusUpdateOne) SetComment(s string) *VulnStatusUpdateOne
SetComment sets the "comment" field.
func (*VulnStatusUpdateOne) SetCreatedAt ¶
func (vsuo *VulnStatusUpdateOne) SetCreatedAt(i int64) *VulnStatusUpdateOne
SetCreatedAt sets the "created_at" field.
func (*VulnStatusUpdateOne) SetExpiresAt ¶
func (vsuo *VulnStatusUpdateOne) SetExpiresAt(i int64) *VulnStatusUpdateOne
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusUpdateOne) SetNillableAuthorID ¶
func (vsuo *VulnStatusUpdateOne) SetNillableAuthorID(id *int) *VulnStatusUpdateOne
SetNillableAuthorID sets the "author" edge to the User entity by ID if the given value is not nil.
func (*VulnStatusUpdateOne) SetPkgName ¶
func (vsuo *VulnStatusUpdateOne) SetPkgName(s string) *VulnStatusUpdateOne
SetPkgName sets the "pkg_name" field.
func (*VulnStatusUpdateOne) SetPkgType ¶
func (vsuo *VulnStatusUpdateOne) SetPkgType(s string) *VulnStatusUpdateOne
SetPkgType sets the "pkg_type" field.
func (*VulnStatusUpdateOne) SetSource ¶
func (vsuo *VulnStatusUpdateOne) SetSource(s string) *VulnStatusUpdateOne
SetSource sets the "source" field.
func (*VulnStatusUpdateOne) SetStatus ¶
func (vsuo *VulnStatusUpdateOne) SetStatus(tst types.VulnStatusType) *VulnStatusUpdateOne
SetStatus sets the "status" field.
func (*VulnStatusUpdateOne) SetVulnID ¶
func (vsuo *VulnStatusUpdateOne) SetVulnID(s string) *VulnStatusUpdateOne
SetVulnID sets the "vuln_id" field.
type VulnStatusUpsert ¶
VulnStatusUpsert is the "OnConflict" setter.
func (*VulnStatusUpsert) SetComment ¶
func (u *VulnStatusUpsert) SetComment(v string) *VulnStatusUpsert
SetComment sets the "comment" field.
func (*VulnStatusUpsert) SetCreatedAt ¶
func (u *VulnStatusUpsert) SetCreatedAt(v int64) *VulnStatusUpsert
SetCreatedAt sets the "created_at" field.
func (*VulnStatusUpsert) SetExpiresAt ¶
func (u *VulnStatusUpsert) SetExpiresAt(v int64) *VulnStatusUpsert
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusUpsert) SetPkgName ¶
func (u *VulnStatusUpsert) SetPkgName(v string) *VulnStatusUpsert
SetPkgName sets the "pkg_name" field.
func (*VulnStatusUpsert) SetPkgType ¶
func (u *VulnStatusUpsert) SetPkgType(v string) *VulnStatusUpsert
SetPkgType sets the "pkg_type" field.
func (*VulnStatusUpsert) SetSource ¶
func (u *VulnStatusUpsert) SetSource(v string) *VulnStatusUpsert
SetSource sets the "source" field.
func (*VulnStatusUpsert) SetStatus ¶
func (u *VulnStatusUpsert) SetStatus(v types.VulnStatusType) *VulnStatusUpsert
SetStatus sets the "status" field.
func (*VulnStatusUpsert) SetVulnID ¶
func (u *VulnStatusUpsert) SetVulnID(v string) *VulnStatusUpsert
SetVulnID sets the "vuln_id" field.
func (*VulnStatusUpsert) UpdateComment ¶
func (u *VulnStatusUpsert) UpdateComment() *VulnStatusUpsert
UpdateComment sets the "comment" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdateCreatedAt ¶
func (u *VulnStatusUpsert) UpdateCreatedAt() *VulnStatusUpsert
UpdateCreatedAt sets the "created_at" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdateExpiresAt ¶
func (u *VulnStatusUpsert) UpdateExpiresAt() *VulnStatusUpsert
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdatePkgName ¶
func (u *VulnStatusUpsert) UpdatePkgName() *VulnStatusUpsert
UpdatePkgName sets the "pkg_name" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdatePkgType ¶
func (u *VulnStatusUpsert) UpdatePkgType() *VulnStatusUpsert
UpdatePkgType sets the "pkg_type" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdateSource ¶
func (u *VulnStatusUpsert) UpdateSource() *VulnStatusUpsert
UpdateSource sets the "source" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdateStatus ¶
func (u *VulnStatusUpsert) UpdateStatus() *VulnStatusUpsert
UpdateStatus sets the "status" field to the value that was provided on create.
func (*VulnStatusUpsert) UpdateVulnID ¶
func (u *VulnStatusUpsert) UpdateVulnID() *VulnStatusUpsert
UpdateVulnID sets the "vuln_id" field to the value that was provided on create.
type VulnStatusUpsertBulk ¶
type VulnStatusUpsertBulk struct {
// contains filtered or unexported fields
}
VulnStatusUpsertBulk is the builder for "upsert"-ing a bulk of VulnStatus nodes.
func (*VulnStatusUpsertBulk) DoNothing ¶
func (u *VulnStatusUpsertBulk) DoNothing() *VulnStatusUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*VulnStatusUpsertBulk) Exec ¶
func (u *VulnStatusUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusUpsertBulk) ExecX ¶
func (u *VulnStatusUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusUpsertBulk) Ignore ¶
func (u *VulnStatusUpsertBulk) Ignore() *VulnStatusUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.VulnStatus.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*VulnStatusUpsertBulk) SetComment ¶
func (u *VulnStatusUpsertBulk) SetComment(v string) *VulnStatusUpsertBulk
SetComment sets the "comment" field.
func (*VulnStatusUpsertBulk) SetCreatedAt ¶
func (u *VulnStatusUpsertBulk) SetCreatedAt(v int64) *VulnStatusUpsertBulk
SetCreatedAt sets the "created_at" field.
func (*VulnStatusUpsertBulk) SetExpiresAt ¶
func (u *VulnStatusUpsertBulk) SetExpiresAt(v int64) *VulnStatusUpsertBulk
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusUpsertBulk) SetPkgName ¶
func (u *VulnStatusUpsertBulk) SetPkgName(v string) *VulnStatusUpsertBulk
SetPkgName sets the "pkg_name" field.
func (*VulnStatusUpsertBulk) SetPkgType ¶
func (u *VulnStatusUpsertBulk) SetPkgType(v string) *VulnStatusUpsertBulk
SetPkgType sets the "pkg_type" field.
func (*VulnStatusUpsertBulk) SetSource ¶
func (u *VulnStatusUpsertBulk) SetSource(v string) *VulnStatusUpsertBulk
SetSource sets the "source" field.
func (*VulnStatusUpsertBulk) SetStatus ¶
func (u *VulnStatusUpsertBulk) SetStatus(v types.VulnStatusType) *VulnStatusUpsertBulk
SetStatus sets the "status" field.
func (*VulnStatusUpsertBulk) SetVulnID ¶
func (u *VulnStatusUpsertBulk) SetVulnID(v string) *VulnStatusUpsertBulk
SetVulnID sets the "vuln_id" field.
func (*VulnStatusUpsertBulk) Update ¶
func (u *VulnStatusUpsertBulk) Update(set func(*VulnStatusUpsert)) *VulnStatusUpsertBulk
Update allows overriding fields `UPDATE` values. See the VulnStatusCreateBulk.OnConflict documentation for more info.
func (*VulnStatusUpsertBulk) UpdateComment ¶
func (u *VulnStatusUpsertBulk) UpdateComment() *VulnStatusUpsertBulk
UpdateComment sets the "comment" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdateCreatedAt ¶
func (u *VulnStatusUpsertBulk) UpdateCreatedAt() *VulnStatusUpsertBulk
UpdateCreatedAt sets the "created_at" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdateExpiresAt ¶
func (u *VulnStatusUpsertBulk) UpdateExpiresAt() *VulnStatusUpsertBulk
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdateNewValues ¶
func (u *VulnStatusUpsertBulk) UpdateNewValues() *VulnStatusUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.VulnStatus.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*VulnStatusUpsertBulk) UpdatePkgName ¶
func (u *VulnStatusUpsertBulk) UpdatePkgName() *VulnStatusUpsertBulk
UpdatePkgName sets the "pkg_name" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdatePkgType ¶
func (u *VulnStatusUpsertBulk) UpdatePkgType() *VulnStatusUpsertBulk
UpdatePkgType sets the "pkg_type" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdateSource ¶
func (u *VulnStatusUpsertBulk) UpdateSource() *VulnStatusUpsertBulk
UpdateSource sets the "source" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdateStatus ¶
func (u *VulnStatusUpsertBulk) UpdateStatus() *VulnStatusUpsertBulk
UpdateStatus sets the "status" field to the value that was provided on create.
func (*VulnStatusUpsertBulk) UpdateVulnID ¶
func (u *VulnStatusUpsertBulk) UpdateVulnID() *VulnStatusUpsertBulk
UpdateVulnID sets the "vuln_id" field to the value that was provided on create.
type VulnStatusUpsertOne ¶
type VulnStatusUpsertOne struct {
// contains filtered or unexported fields
}
VulnStatusUpsertOne is the builder for "upsert"-ing
one VulnStatus node.
func (*VulnStatusUpsertOne) DoNothing ¶
func (u *VulnStatusUpsertOne) DoNothing() *VulnStatusUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*VulnStatusUpsertOne) Exec ¶
func (u *VulnStatusUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnStatusUpsertOne) ExecX ¶
func (u *VulnStatusUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnStatusUpsertOne) ID ¶
func (u *VulnStatusUpsertOne) ID(ctx context.Context) (id int, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*VulnStatusUpsertOne) IDX ¶
func (u *VulnStatusUpsertOne) IDX(ctx context.Context) int
IDX is like ID, but panics if an error occurs.
func (*VulnStatusUpsertOne) Ignore ¶
func (u *VulnStatusUpsertOne) Ignore() *VulnStatusUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.VulnStatus.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*VulnStatusUpsertOne) SetComment ¶
func (u *VulnStatusUpsertOne) SetComment(v string) *VulnStatusUpsertOne
SetComment sets the "comment" field.
func (*VulnStatusUpsertOne) SetCreatedAt ¶
func (u *VulnStatusUpsertOne) SetCreatedAt(v int64) *VulnStatusUpsertOne
SetCreatedAt sets the "created_at" field.
func (*VulnStatusUpsertOne) SetExpiresAt ¶
func (u *VulnStatusUpsertOne) SetExpiresAt(v int64) *VulnStatusUpsertOne
SetExpiresAt sets the "expires_at" field.
func (*VulnStatusUpsertOne) SetPkgName ¶
func (u *VulnStatusUpsertOne) SetPkgName(v string) *VulnStatusUpsertOne
SetPkgName sets the "pkg_name" field.
func (*VulnStatusUpsertOne) SetPkgType ¶
func (u *VulnStatusUpsertOne) SetPkgType(v string) *VulnStatusUpsertOne
SetPkgType sets the "pkg_type" field.
func (*VulnStatusUpsertOne) SetSource ¶
func (u *VulnStatusUpsertOne) SetSource(v string) *VulnStatusUpsertOne
SetSource sets the "source" field.
func (*VulnStatusUpsertOne) SetStatus ¶
func (u *VulnStatusUpsertOne) SetStatus(v types.VulnStatusType) *VulnStatusUpsertOne
SetStatus sets the "status" field.
func (*VulnStatusUpsertOne) SetVulnID ¶
func (u *VulnStatusUpsertOne) SetVulnID(v string) *VulnStatusUpsertOne
SetVulnID sets the "vuln_id" field.
func (*VulnStatusUpsertOne) Update ¶
func (u *VulnStatusUpsertOne) Update(set func(*VulnStatusUpsert)) *VulnStatusUpsertOne
Update allows overriding fields `UPDATE` values. See the VulnStatusCreate.OnConflict documentation for more info.
func (*VulnStatusUpsertOne) UpdateComment ¶
func (u *VulnStatusUpsertOne) UpdateComment() *VulnStatusUpsertOne
UpdateComment sets the "comment" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdateCreatedAt ¶
func (u *VulnStatusUpsertOne) UpdateCreatedAt() *VulnStatusUpsertOne
UpdateCreatedAt sets the "created_at" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdateExpiresAt ¶
func (u *VulnStatusUpsertOne) UpdateExpiresAt() *VulnStatusUpsertOne
UpdateExpiresAt sets the "expires_at" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdateNewValues ¶
func (u *VulnStatusUpsertOne) UpdateNewValues() *VulnStatusUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.VulnStatus.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*VulnStatusUpsertOne) UpdatePkgName ¶
func (u *VulnStatusUpsertOne) UpdatePkgName() *VulnStatusUpsertOne
UpdatePkgName sets the "pkg_name" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdatePkgType ¶
func (u *VulnStatusUpsertOne) UpdatePkgType() *VulnStatusUpsertOne
UpdatePkgType sets the "pkg_type" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdateSource ¶
func (u *VulnStatusUpsertOne) UpdateSource() *VulnStatusUpsertOne
UpdateSource sets the "source" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdateStatus ¶
func (u *VulnStatusUpsertOne) UpdateStatus() *VulnStatusUpsertOne
UpdateStatus sets the "status" field to the value that was provided on create.
func (*VulnStatusUpsertOne) UpdateVulnID ¶
func (u *VulnStatusUpsertOne) UpdateVulnID() *VulnStatusUpsertOne
UpdateVulnID sets the "vuln_id" field to the value that was provided on create.
type Vulnerabilities ¶
type Vulnerabilities []*Vulnerability
Vulnerabilities is a parsable slice of Vulnerability.
type Vulnerability ¶
type Vulnerability struct { // ID of the ent. ID string `json:"id,omitempty"` // FirstSeenAt holds the value of the "first_seen_at" field. FirstSeenAt int64 `json:"first_seen_at,omitempty"` // LastModifiedAt holds the value of the "last_modified_at" field. LastModifiedAt int64 `json:"last_modified_at,omitempty"` // Title holds the value of the "title" field. Title string `json:"title,omitempty"` // Description holds the value of the "description" field. Description string `json:"description,omitempty"` // CweID holds the value of the "cwe_id" field. CweID []string `json:"cwe_id,omitempty"` // Severity holds the value of the "severity" field. Severity string `json:"severity,omitempty"` // Cvss holds the value of the "cvss" field. Cvss []string `json:"cvss,omitempty"` // References holds the value of the "references" field. References []string `json:"references,omitempty"` // Edges holds the relations/edges for other nodes in the graph. // The values are being populated by the VulnerabilityQuery when eager-loading is set. Edges VulnerabilityEdges `json:"edges"` // contains filtered or unexported fields }
Vulnerability is the model entity for the Vulnerability schema.
func (*Vulnerability) QueryCustomSeverity ¶ added in v0.1.1
func (v *Vulnerability) QueryCustomSeverity() *SeverityQuery
QueryCustomSeverity queries the "custom_severity" edge of the Vulnerability entity.
func (*Vulnerability) QueryPackages ¶
func (v *Vulnerability) QueryPackages() *PackageRecordQuery
QueryPackages queries the "packages" edge of the Vulnerability entity.
func (*Vulnerability) String ¶
func (v *Vulnerability) String() string
String implements the fmt.Stringer.
func (*Vulnerability) Unwrap ¶
func (v *Vulnerability) Unwrap() *Vulnerability
Unwrap unwraps the Vulnerability 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 (*Vulnerability) Update ¶
func (v *Vulnerability) Update() *VulnerabilityUpdateOne
Update returns a builder for updating this Vulnerability. Note that you need to call Vulnerability.Unwrap() before calling this method if this Vulnerability was returned from a transaction, and the transaction was committed or rolled back.
type VulnerabilityClient ¶
type VulnerabilityClient struct {
// contains filtered or unexported fields
}
VulnerabilityClient is a client for the Vulnerability schema.
func NewVulnerabilityClient ¶
func NewVulnerabilityClient(c config) *VulnerabilityClient
NewVulnerabilityClient returns a client for the Vulnerability from the given config.
func (*VulnerabilityClient) Create ¶
func (c *VulnerabilityClient) Create() *VulnerabilityCreate
Create returns a create builder for Vulnerability.
func (*VulnerabilityClient) CreateBulk ¶
func (c *VulnerabilityClient) CreateBulk(builders ...*VulnerabilityCreate) *VulnerabilityCreateBulk
CreateBulk returns a builder for creating a bulk of Vulnerability entities.
func (*VulnerabilityClient) Delete ¶
func (c *VulnerabilityClient) Delete() *VulnerabilityDelete
Delete returns a delete builder for Vulnerability.
func (*VulnerabilityClient) DeleteOne ¶
func (c *VulnerabilityClient) DeleteOne(v *Vulnerability) *VulnerabilityDeleteOne
DeleteOne returns a delete builder for the given entity.
func (*VulnerabilityClient) DeleteOneID ¶
func (c *VulnerabilityClient) DeleteOneID(id string) *VulnerabilityDeleteOne
DeleteOneID returns a delete builder for the given id.
func (*VulnerabilityClient) Get ¶
func (c *VulnerabilityClient) Get(ctx context.Context, id string) (*Vulnerability, error)
Get returns a Vulnerability entity by its id.
func (*VulnerabilityClient) GetX ¶
func (c *VulnerabilityClient) GetX(ctx context.Context, id string) *Vulnerability
GetX is like Get, but panics if an error occurs.
func (*VulnerabilityClient) Hooks ¶
func (c *VulnerabilityClient) Hooks() []Hook
Hooks returns the client hooks.
func (*VulnerabilityClient) Query ¶
func (c *VulnerabilityClient) Query() *VulnerabilityQuery
Query returns a query builder for Vulnerability.
func (*VulnerabilityClient) QueryCustomSeverity ¶ added in v0.1.1
func (c *VulnerabilityClient) QueryCustomSeverity(v *Vulnerability) *SeverityQuery
QueryCustomSeverity queries the custom_severity edge of a Vulnerability.
func (*VulnerabilityClient) QueryPackages ¶
func (c *VulnerabilityClient) QueryPackages(v *Vulnerability) *PackageRecordQuery
QueryPackages queries the packages edge of a Vulnerability.
func (*VulnerabilityClient) Update ¶
func (c *VulnerabilityClient) Update() *VulnerabilityUpdate
Update returns an update builder for Vulnerability.
func (*VulnerabilityClient) UpdateOne ¶
func (c *VulnerabilityClient) UpdateOne(v *Vulnerability) *VulnerabilityUpdateOne
UpdateOne returns an update builder for the given entity.
func (*VulnerabilityClient) UpdateOneID ¶
func (c *VulnerabilityClient) UpdateOneID(id string) *VulnerabilityUpdateOne
UpdateOneID returns an update builder for the given id.
func (*VulnerabilityClient) Use ¶
func (c *VulnerabilityClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `vulnerability.Hooks(f(g(h())))`.
type VulnerabilityCreate ¶
type VulnerabilityCreate struct {
// contains filtered or unexported fields
}
VulnerabilityCreate is the builder for creating a Vulnerability entity.
func (*VulnerabilityCreate) AddPackageIDs ¶
func (vc *VulnerabilityCreate) AddPackageIDs(ids ...int) *VulnerabilityCreate
AddPackageIDs adds the "packages" edge to the PackageRecord entity by IDs.
func (*VulnerabilityCreate) AddPackages ¶
func (vc *VulnerabilityCreate) AddPackages(p ...*PackageRecord) *VulnerabilityCreate
AddPackages adds the "packages" edges to the PackageRecord entity.
func (*VulnerabilityCreate) Exec ¶
func (vc *VulnerabilityCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnerabilityCreate) ExecX ¶
func (vc *VulnerabilityCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityCreate) Mutation ¶
func (vc *VulnerabilityCreate) Mutation() *VulnerabilityMutation
Mutation returns the VulnerabilityMutation object of the builder.
func (*VulnerabilityCreate) OnConflict ¶
func (vc *VulnerabilityCreate) OnConflict(opts ...sql.ConflictOption) *VulnerabilityUpsertOne
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Vulnerability.Create(). SetFirstSeenAt(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.VulnerabilityUpsert) { SetFirstSeenAt(v+v). }). Exec(ctx)
func (*VulnerabilityCreate) OnConflictColumns ¶
func (vc *VulnerabilityCreate) OnConflictColumns(columns ...string) *VulnerabilityUpsertOne
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Vulnerability.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*VulnerabilityCreate) Save ¶
func (vc *VulnerabilityCreate) Save(ctx context.Context) (*Vulnerability, error)
Save creates the Vulnerability in the database.
func (*VulnerabilityCreate) SaveX ¶
func (vc *VulnerabilityCreate) SaveX(ctx context.Context) *Vulnerability
SaveX calls Save and panics if Save returns an error.
func (*VulnerabilityCreate) SetCustomSeverity ¶ added in v0.1.1
func (vc *VulnerabilityCreate) SetCustomSeverity(s *Severity) *VulnerabilityCreate
SetCustomSeverity sets the "custom_severity" edge to the Severity entity.
func (*VulnerabilityCreate) SetCustomSeverityID ¶ added in v0.1.1
func (vc *VulnerabilityCreate) SetCustomSeverityID(id int) *VulnerabilityCreate
SetCustomSeverityID sets the "custom_severity" edge to the Severity entity by ID.
func (*VulnerabilityCreate) SetCvss ¶
func (vc *VulnerabilityCreate) SetCvss(s []string) *VulnerabilityCreate
SetCvss sets the "cvss" field.
func (*VulnerabilityCreate) SetCweID ¶
func (vc *VulnerabilityCreate) SetCweID(s []string) *VulnerabilityCreate
SetCweID sets the "cwe_id" field.
func (*VulnerabilityCreate) SetDescription ¶
func (vc *VulnerabilityCreate) SetDescription(s string) *VulnerabilityCreate
SetDescription sets the "description" field.
func (*VulnerabilityCreate) SetFirstSeenAt ¶
func (vc *VulnerabilityCreate) SetFirstSeenAt(i int64) *VulnerabilityCreate
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityCreate) SetID ¶
func (vc *VulnerabilityCreate) SetID(s string) *VulnerabilityCreate
SetID sets the "id" field.
func (*VulnerabilityCreate) SetLastModifiedAt ¶
func (vc *VulnerabilityCreate) SetLastModifiedAt(i int64) *VulnerabilityCreate
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityCreate) SetNillableCustomSeverityID ¶ added in v0.1.1
func (vc *VulnerabilityCreate) SetNillableCustomSeverityID(id *int) *VulnerabilityCreate
SetNillableCustomSeverityID sets the "custom_severity" edge to the Severity entity by ID if the given value is not nil.
func (*VulnerabilityCreate) SetNillableDescription ¶
func (vc *VulnerabilityCreate) SetNillableDescription(s *string) *VulnerabilityCreate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*VulnerabilityCreate) SetNillableSeverity ¶
func (vc *VulnerabilityCreate) SetNillableSeverity(s *string) *VulnerabilityCreate
SetNillableSeverity sets the "severity" field if the given value is not nil.
func (*VulnerabilityCreate) SetNillableTitle ¶
func (vc *VulnerabilityCreate) SetNillableTitle(s *string) *VulnerabilityCreate
SetNillableTitle sets the "title" field if the given value is not nil.
func (*VulnerabilityCreate) SetReferences ¶
func (vc *VulnerabilityCreate) SetReferences(s []string) *VulnerabilityCreate
SetReferences sets the "references" field.
func (*VulnerabilityCreate) SetSeverity ¶
func (vc *VulnerabilityCreate) SetSeverity(s string) *VulnerabilityCreate
SetSeverity sets the "severity" field.
func (*VulnerabilityCreate) SetTitle ¶
func (vc *VulnerabilityCreate) SetTitle(s string) *VulnerabilityCreate
SetTitle sets the "title" field.
type VulnerabilityCreateBulk ¶
type VulnerabilityCreateBulk struct {
// contains filtered or unexported fields
}
VulnerabilityCreateBulk is the builder for creating many Vulnerability entities in bulk.
func (*VulnerabilityCreateBulk) Exec ¶
func (vcb *VulnerabilityCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnerabilityCreateBulk) ExecX ¶
func (vcb *VulnerabilityCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityCreateBulk) OnConflict ¶
func (vcb *VulnerabilityCreateBulk) OnConflict(opts ...sql.ConflictOption) *VulnerabilityUpsertBulk
OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:
client.Vulnerability.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.VulnerabilityUpsert) { SetFirstSeenAt(v+v). }). Exec(ctx)
func (*VulnerabilityCreateBulk) OnConflictColumns ¶
func (vcb *VulnerabilityCreateBulk) OnConflictColumns(columns ...string) *VulnerabilityUpsertBulk
OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:
client.Vulnerability.Create(). OnConflict(sql.ConflictColumns(columns...)). Exec(ctx)
func (*VulnerabilityCreateBulk) Save ¶
func (vcb *VulnerabilityCreateBulk) Save(ctx context.Context) ([]*Vulnerability, error)
Save creates the Vulnerability entities in the database.
func (*VulnerabilityCreateBulk) SaveX ¶
func (vcb *VulnerabilityCreateBulk) SaveX(ctx context.Context) []*Vulnerability
SaveX is like Save, but panics if an error occurs.
type VulnerabilityDelete ¶
type VulnerabilityDelete struct {
// contains filtered or unexported fields
}
VulnerabilityDelete is the builder for deleting a Vulnerability entity.
func (*VulnerabilityDelete) Exec ¶
func (vd *VulnerabilityDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*VulnerabilityDelete) ExecX ¶
func (vd *VulnerabilityDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityDelete) Where ¶
func (vd *VulnerabilityDelete) Where(ps ...predicate.Vulnerability) *VulnerabilityDelete
Where appends a list predicates to the VulnerabilityDelete builder.
type VulnerabilityDeleteOne ¶
type VulnerabilityDeleteOne struct {
// contains filtered or unexported fields
}
VulnerabilityDeleteOne is the builder for deleting a single Vulnerability entity.
func (*VulnerabilityDeleteOne) Exec ¶
func (vdo *VulnerabilityDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*VulnerabilityDeleteOne) ExecX ¶
func (vdo *VulnerabilityDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
type VulnerabilityEdges ¶
type VulnerabilityEdges struct { // Packages holds the value of the packages edge. Packages []*PackageRecord `json:"packages,omitempty"` // CustomSeverity holds the value of the custom_severity edge. CustomSeverity *Severity `json:"custom_severity,omitempty"` // contains filtered or unexported fields }
VulnerabilityEdges holds the relations/edges for other nodes in the graph.
func (VulnerabilityEdges) CustomSeverityOrErr ¶ added in v0.1.1
func (e VulnerabilityEdges) CustomSeverityOrErr() (*Severity, error)
CustomSeverityOrErr returns the CustomSeverity value or an error if the edge was not loaded in eager-loading, or loaded but was not found.
func (VulnerabilityEdges) PackagesOrErr ¶
func (e VulnerabilityEdges) PackagesOrErr() ([]*PackageRecord, error)
PackagesOrErr returns the Packages value or an error if the edge was not loaded in eager-loading.
type VulnerabilityGroupBy ¶
type VulnerabilityGroupBy struct {
// contains filtered or unexported fields
}
VulnerabilityGroupBy is the group-by builder for Vulnerability entities.
func (*VulnerabilityGroupBy) Aggregate ¶
func (vgb *VulnerabilityGroupBy) Aggregate(fns ...AggregateFunc) *VulnerabilityGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*VulnerabilityGroupBy) Bool ¶
func (vgb *VulnerabilityGroupBy) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) BoolX ¶
func (vgb *VulnerabilityGroupBy) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*VulnerabilityGroupBy) Bools ¶
func (vgb *VulnerabilityGroupBy) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) BoolsX ¶
func (vgb *VulnerabilityGroupBy) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*VulnerabilityGroupBy) Float64 ¶
func (vgb *VulnerabilityGroupBy) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) Float64X ¶
func (vgb *VulnerabilityGroupBy) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*VulnerabilityGroupBy) Float64s ¶
func (vgb *VulnerabilityGroupBy) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) Float64sX ¶
func (vgb *VulnerabilityGroupBy) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*VulnerabilityGroupBy) Int ¶
func (vgb *VulnerabilityGroupBy) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) IntX ¶
func (vgb *VulnerabilityGroupBy) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*VulnerabilityGroupBy) Ints ¶
func (vgb *VulnerabilityGroupBy) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from group-by. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) IntsX ¶
func (vgb *VulnerabilityGroupBy) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*VulnerabilityGroupBy) Scan ¶
func (vgb *VulnerabilityGroupBy) Scan(ctx context.Context, v interface{}) error
Scan applies the group-by query and scans the result into the given value.
func (*VulnerabilityGroupBy) ScanX ¶
func (vgb *VulnerabilityGroupBy) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*VulnerabilityGroupBy) String ¶
func (vgb *VulnerabilityGroupBy) String(ctx context.Context) (_ string, err error)
String returns a single string from a group-by query. It is only allowed when executing a group-by query with one field.
func (*VulnerabilityGroupBy) StringX ¶
func (vgb *VulnerabilityGroupBy) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type VulnerabilityMutation ¶
type VulnerabilityMutation struct {
// contains filtered or unexported fields
}
VulnerabilityMutation represents an operation that mutates the Vulnerability nodes in the graph.
func (*VulnerabilityMutation) AddField ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) AddFirstSeenAt ¶
func (m *VulnerabilityMutation) AddFirstSeenAt(i int64)
AddFirstSeenAt adds i to the "first_seen_at" field.
func (*VulnerabilityMutation) AddLastModifiedAt ¶
func (m *VulnerabilityMutation) AddLastModifiedAt(i int64)
AddLastModifiedAt adds i to the "last_modified_at" field.
func (*VulnerabilityMutation) AddPackageIDs ¶
func (m *VulnerabilityMutation) AddPackageIDs(ids ...int)
AddPackageIDs adds the "packages" edge to the PackageRecord entity by ids.
func (*VulnerabilityMutation) AddedEdges ¶
func (m *VulnerabilityMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*VulnerabilityMutation) AddedField ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) AddedFields ¶
func (m *VulnerabilityMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*VulnerabilityMutation) AddedFirstSeenAt ¶
func (m *VulnerabilityMutation) AddedFirstSeenAt() (r int64, exists bool)
AddedFirstSeenAt returns the value that was added to the "first_seen_at" field in this mutation.
func (*VulnerabilityMutation) AddedIDs ¶
func (m *VulnerabilityMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*VulnerabilityMutation) AddedLastModifiedAt ¶
func (m *VulnerabilityMutation) AddedLastModifiedAt() (r int64, exists bool)
AddedLastModifiedAt returns the value that was added to the "last_modified_at" field in this mutation.
func (*VulnerabilityMutation) ClearCustomSeverity ¶ added in v0.1.1
func (m *VulnerabilityMutation) ClearCustomSeverity()
ClearCustomSeverity clears the "custom_severity" edge to the Severity entity.
func (*VulnerabilityMutation) ClearCvss ¶
func (m *VulnerabilityMutation) ClearCvss()
ClearCvss clears the value of the "cvss" field.
func (*VulnerabilityMutation) ClearCweID ¶
func (m *VulnerabilityMutation) ClearCweID()
ClearCweID clears the value of the "cwe_id" field.
func (*VulnerabilityMutation) ClearDescription ¶
func (m *VulnerabilityMutation) ClearDescription()
ClearDescription clears the value of the "description" field.
func (*VulnerabilityMutation) ClearEdge ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) ClearField ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) ClearPackages ¶
func (m *VulnerabilityMutation) ClearPackages()
ClearPackages clears the "packages" edge to the PackageRecord entity.
func (*VulnerabilityMutation) ClearReferences ¶
func (m *VulnerabilityMutation) ClearReferences()
ClearReferences clears the value of the "references" field.
func (*VulnerabilityMutation) ClearSeverity ¶
func (m *VulnerabilityMutation) ClearSeverity()
ClearSeverity clears the value of the "severity" field.
func (*VulnerabilityMutation) ClearTitle ¶
func (m *VulnerabilityMutation) ClearTitle()
ClearTitle clears the value of the "title" field.
func (*VulnerabilityMutation) ClearedEdges ¶
func (m *VulnerabilityMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*VulnerabilityMutation) ClearedFields ¶
func (m *VulnerabilityMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (VulnerabilityMutation) Client ¶
func (m VulnerabilityMutation) 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 (*VulnerabilityMutation) CustomSeverityCleared ¶ added in v0.1.1
func (m *VulnerabilityMutation) CustomSeverityCleared() bool
CustomSeverityCleared reports if the "custom_severity" edge to the Severity entity was cleared.
func (*VulnerabilityMutation) CustomSeverityID ¶ added in v0.1.1
func (m *VulnerabilityMutation) CustomSeverityID() (id int, exists bool)
CustomSeverityID returns the "custom_severity" edge ID in the mutation.
func (*VulnerabilityMutation) CustomSeverityIDs ¶ added in v0.1.1
func (m *VulnerabilityMutation) CustomSeverityIDs() (ids []int)
CustomSeverityIDs returns the "custom_severity" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use CustomSeverityID instead. It exists only for internal usage by the builders.
func (*VulnerabilityMutation) Cvss ¶
func (m *VulnerabilityMutation) Cvss() (r []string, exists bool)
Cvss returns the value of the "cvss" field in the mutation.
func (*VulnerabilityMutation) CvssCleared ¶
func (m *VulnerabilityMutation) CvssCleared() bool
CvssCleared returns if the "cvss" field was cleared in this mutation.
func (*VulnerabilityMutation) CweID ¶
func (m *VulnerabilityMutation) CweID() (r []string, exists bool)
CweID returns the value of the "cwe_id" field in the mutation.
func (*VulnerabilityMutation) CweIDCleared ¶
func (m *VulnerabilityMutation) CweIDCleared() bool
CweIDCleared returns if the "cwe_id" field was cleared in this mutation.
func (*VulnerabilityMutation) Description ¶
func (m *VulnerabilityMutation) Description() (r string, exists bool)
Description returns the value of the "description" field in the mutation.
func (*VulnerabilityMutation) DescriptionCleared ¶
func (m *VulnerabilityMutation) DescriptionCleared() bool
DescriptionCleared returns if the "description" field was cleared in this mutation.
func (*VulnerabilityMutation) EdgeCleared ¶
func (m *VulnerabilityMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*VulnerabilityMutation) Field ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) FieldCleared ¶
func (m *VulnerabilityMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*VulnerabilityMutation) Fields ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) FirstSeenAt ¶
func (m *VulnerabilityMutation) FirstSeenAt() (r int64, exists bool)
FirstSeenAt returns the value of the "first_seen_at" field in the mutation.
func (*VulnerabilityMutation) ID ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) LastModifiedAt ¶
func (m *VulnerabilityMutation) LastModifiedAt() (r int64, exists bool)
LastModifiedAt returns the value of the "last_modified_at" field in the mutation.
func (*VulnerabilityMutation) OldCvss ¶
func (m *VulnerabilityMutation) OldCvss(ctx context.Context) (v []string, err error)
OldCvss returns the old "cvss" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) OldCweID ¶
func (m *VulnerabilityMutation) OldCweID(ctx context.Context) (v []string, err error)
OldCweID returns the old "cwe_id" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) OldDescription ¶
func (m *VulnerabilityMutation) OldDescription(ctx context.Context) (v string, err error)
OldDescription returns the old "description" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) 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 (*VulnerabilityMutation) OldFirstSeenAt ¶
func (m *VulnerabilityMutation) OldFirstSeenAt(ctx context.Context) (v int64, err error)
OldFirstSeenAt returns the old "first_seen_at" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) OldLastModifiedAt ¶
func (m *VulnerabilityMutation) OldLastModifiedAt(ctx context.Context) (v int64, err error)
OldLastModifiedAt returns the old "last_modified_at" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) OldReferences ¶
func (m *VulnerabilityMutation) OldReferences(ctx context.Context) (v []string, err error)
OldReferences returns the old "references" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) OldSeverity ¶
func (m *VulnerabilityMutation) OldSeverity(ctx context.Context) (v string, err error)
OldSeverity returns the old "severity" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) OldTitle ¶
func (m *VulnerabilityMutation) OldTitle(ctx context.Context) (v string, err error)
OldTitle returns the old "title" field's value of the Vulnerability entity. If the Vulnerability 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 (*VulnerabilityMutation) Op ¶
func (m *VulnerabilityMutation) Op() Op
Op returns the operation name.
func (*VulnerabilityMutation) PackagesCleared ¶
func (m *VulnerabilityMutation) PackagesCleared() bool
PackagesCleared reports if the "packages" edge to the PackageRecord entity was cleared.
func (*VulnerabilityMutation) PackagesIDs ¶
func (m *VulnerabilityMutation) PackagesIDs() (ids []int)
PackagesIDs returns the "packages" edge IDs in the mutation.
func (*VulnerabilityMutation) References ¶
func (m *VulnerabilityMutation) References() (r []string, exists bool)
References returns the value of the "references" field in the mutation.
func (*VulnerabilityMutation) ReferencesCleared ¶
func (m *VulnerabilityMutation) ReferencesCleared() bool
ReferencesCleared returns if the "references" field was cleared in this mutation.
func (*VulnerabilityMutation) RemovePackageIDs ¶
func (m *VulnerabilityMutation) RemovePackageIDs(ids ...int)
RemovePackageIDs removes the "packages" edge to the PackageRecord entity by IDs.
func (*VulnerabilityMutation) RemovedEdges ¶
func (m *VulnerabilityMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*VulnerabilityMutation) RemovedIDs ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) RemovedPackagesIDs ¶
func (m *VulnerabilityMutation) RemovedPackagesIDs() (ids []int)
RemovedPackages returns the removed IDs of the "packages" edge to the PackageRecord entity.
func (*VulnerabilityMutation) ResetCustomSeverity ¶ added in v0.1.1
func (m *VulnerabilityMutation) ResetCustomSeverity()
ResetCustomSeverity resets all changes to the "custom_severity" edge.
func (*VulnerabilityMutation) ResetCvss ¶
func (m *VulnerabilityMutation) ResetCvss()
ResetCvss resets all changes to the "cvss" field.
func (*VulnerabilityMutation) ResetCweID ¶
func (m *VulnerabilityMutation) ResetCweID()
ResetCweID resets all changes to the "cwe_id" field.
func (*VulnerabilityMutation) ResetDescription ¶
func (m *VulnerabilityMutation) ResetDescription()
ResetDescription resets all changes to the "description" field.
func (*VulnerabilityMutation) ResetEdge ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) ResetField ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) ResetFirstSeenAt ¶
func (m *VulnerabilityMutation) ResetFirstSeenAt()
ResetFirstSeenAt resets all changes to the "first_seen_at" field.
func (*VulnerabilityMutation) ResetLastModifiedAt ¶
func (m *VulnerabilityMutation) ResetLastModifiedAt()
ResetLastModifiedAt resets all changes to the "last_modified_at" field.
func (*VulnerabilityMutation) ResetPackages ¶
func (m *VulnerabilityMutation) ResetPackages()
ResetPackages resets all changes to the "packages" edge.
func (*VulnerabilityMutation) ResetReferences ¶
func (m *VulnerabilityMutation) ResetReferences()
ResetReferences resets all changes to the "references" field.
func (*VulnerabilityMutation) ResetSeverity ¶
func (m *VulnerabilityMutation) ResetSeverity()
ResetSeverity resets all changes to the "severity" field.
func (*VulnerabilityMutation) ResetTitle ¶
func (m *VulnerabilityMutation) ResetTitle()
ResetTitle resets all changes to the "title" field.
func (*VulnerabilityMutation) SetCustomSeverityID ¶ added in v0.1.1
func (m *VulnerabilityMutation) SetCustomSeverityID(id int)
SetCustomSeverityID sets the "custom_severity" edge to the Severity entity by id.
func (*VulnerabilityMutation) SetCvss ¶
func (m *VulnerabilityMutation) SetCvss(s []string)
SetCvss sets the "cvss" field.
func (*VulnerabilityMutation) SetCweID ¶
func (m *VulnerabilityMutation) SetCweID(s []string)
SetCweID sets the "cwe_id" field.
func (*VulnerabilityMutation) SetDescription ¶
func (m *VulnerabilityMutation) SetDescription(s string)
SetDescription sets the "description" field.
func (*VulnerabilityMutation) SetField ¶
func (m *VulnerabilityMutation) 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 (*VulnerabilityMutation) SetFirstSeenAt ¶
func (m *VulnerabilityMutation) SetFirstSeenAt(i int64)
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityMutation) SetID ¶
func (m *VulnerabilityMutation) SetID(id string)
SetID sets the value of the id field. Note that this operation is only accepted on creation of Vulnerability entities.
func (*VulnerabilityMutation) SetLastModifiedAt ¶
func (m *VulnerabilityMutation) SetLastModifiedAt(i int64)
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityMutation) SetReferences ¶
func (m *VulnerabilityMutation) SetReferences(s []string)
SetReferences sets the "references" field.
func (*VulnerabilityMutation) SetSeverity ¶
func (m *VulnerabilityMutation) SetSeverity(s string)
SetSeverity sets the "severity" field.
func (*VulnerabilityMutation) SetTitle ¶
func (m *VulnerabilityMutation) SetTitle(s string)
SetTitle sets the "title" field.
func (*VulnerabilityMutation) Severity ¶
func (m *VulnerabilityMutation) Severity() (r string, exists bool)
Severity returns the value of the "severity" field in the mutation.
func (*VulnerabilityMutation) SeverityCleared ¶
func (m *VulnerabilityMutation) SeverityCleared() bool
SeverityCleared returns if the "severity" field was cleared in this mutation.
func (*VulnerabilityMutation) Title ¶
func (m *VulnerabilityMutation) Title() (r string, exists bool)
Title returns the value of the "title" field in the mutation.
func (*VulnerabilityMutation) TitleCleared ¶
func (m *VulnerabilityMutation) TitleCleared() bool
TitleCleared returns if the "title" field was cleared in this mutation.
func (VulnerabilityMutation) Tx ¶
func (m VulnerabilityMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*VulnerabilityMutation) Type ¶
func (m *VulnerabilityMutation) Type() string
Type returns the node type of this mutation (Vulnerability).
func (*VulnerabilityMutation) Where ¶
func (m *VulnerabilityMutation) Where(ps ...predicate.Vulnerability)
Where appends a list predicates to the VulnerabilityMutation builder.
type VulnerabilityQuery ¶
type VulnerabilityQuery struct {
// contains filtered or unexported fields
}
VulnerabilityQuery is the builder for querying Vulnerability entities.
func (*VulnerabilityQuery) All ¶
func (vq *VulnerabilityQuery) All(ctx context.Context) ([]*Vulnerability, error)
All executes the query and returns a list of Vulnerabilities.
func (*VulnerabilityQuery) AllX ¶
func (vq *VulnerabilityQuery) AllX(ctx context.Context) []*Vulnerability
AllX is like All, but panics if an error occurs.
func (*VulnerabilityQuery) Clone ¶
func (vq *VulnerabilityQuery) Clone() *VulnerabilityQuery
Clone returns a duplicate of the VulnerabilityQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*VulnerabilityQuery) Count ¶
func (vq *VulnerabilityQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*VulnerabilityQuery) CountX ¶
func (vq *VulnerabilityQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*VulnerabilityQuery) Exist ¶
func (vq *VulnerabilityQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*VulnerabilityQuery) ExistX ¶
func (vq *VulnerabilityQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*VulnerabilityQuery) First ¶
func (vq *VulnerabilityQuery) First(ctx context.Context) (*Vulnerability, error)
First returns the first Vulnerability entity from the query. Returns a *NotFoundError when no Vulnerability was found.
func (*VulnerabilityQuery) FirstID ¶
func (vq *VulnerabilityQuery) FirstID(ctx context.Context) (id string, err error)
FirstID returns the first Vulnerability ID from the query. Returns a *NotFoundError when no Vulnerability ID was found.
func (*VulnerabilityQuery) FirstIDX ¶
func (vq *VulnerabilityQuery) FirstIDX(ctx context.Context) string
FirstIDX is like FirstID, but panics if an error occurs.
func (*VulnerabilityQuery) FirstX ¶
func (vq *VulnerabilityQuery) FirstX(ctx context.Context) *Vulnerability
FirstX is like First, but panics if an error occurs.
func (*VulnerabilityQuery) GroupBy ¶
func (vq *VulnerabilityQuery) GroupBy(field string, fields ...string) *VulnerabilityGroupBy
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 { FirstSeenAt int64 `json:"first_seen_at,omitempty"` Count int `json:"count,omitempty"` } client.Vulnerability.Query(). GroupBy(vulnerability.FieldFirstSeenAt). Aggregate(ent.Count()). Scan(ctx, &v)
func (*VulnerabilityQuery) IDs ¶
func (vq *VulnerabilityQuery) IDs(ctx context.Context) ([]string, error)
IDs executes the query and returns a list of Vulnerability IDs.
func (*VulnerabilityQuery) IDsX ¶
func (vq *VulnerabilityQuery) IDsX(ctx context.Context) []string
IDsX is like IDs, but panics if an error occurs.
func (*VulnerabilityQuery) Limit ¶
func (vq *VulnerabilityQuery) Limit(limit int) *VulnerabilityQuery
Limit adds a limit step to the query.
func (*VulnerabilityQuery) Offset ¶
func (vq *VulnerabilityQuery) Offset(offset int) *VulnerabilityQuery
Offset adds an offset step to the query.
func (*VulnerabilityQuery) Only ¶
func (vq *VulnerabilityQuery) Only(ctx context.Context) (*Vulnerability, error)
Only returns a single Vulnerability entity found by the query, ensuring it only returns one. Returns a *NotSingularError when exactly one Vulnerability entity is not found. Returns a *NotFoundError when no Vulnerability entities are found.
func (*VulnerabilityQuery) OnlyID ¶
func (vq *VulnerabilityQuery) OnlyID(ctx context.Context) (id string, err error)
OnlyID is like Only, but returns the only Vulnerability ID in the query. Returns a *NotSingularError when exactly one Vulnerability ID is not found. Returns a *NotFoundError when no entities are found.
func (*VulnerabilityQuery) OnlyIDX ¶
func (vq *VulnerabilityQuery) OnlyIDX(ctx context.Context) string
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*VulnerabilityQuery) OnlyX ¶
func (vq *VulnerabilityQuery) OnlyX(ctx context.Context) *Vulnerability
OnlyX is like Only, but panics if an error occurs.
func (*VulnerabilityQuery) Order ¶
func (vq *VulnerabilityQuery) Order(o ...OrderFunc) *VulnerabilityQuery
Order adds an order step to the query.
func (*VulnerabilityQuery) QueryCustomSeverity ¶ added in v0.1.1
func (vq *VulnerabilityQuery) QueryCustomSeverity() *SeverityQuery
QueryCustomSeverity chains the current query on the "custom_severity" edge.
func (*VulnerabilityQuery) QueryPackages ¶
func (vq *VulnerabilityQuery) QueryPackages() *PackageRecordQuery
QueryPackages chains the current query on the "packages" edge.
func (*VulnerabilityQuery) Select ¶
func (vq *VulnerabilityQuery) Select(fields ...string) *VulnerabilitySelect
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 { FirstSeenAt int64 `json:"first_seen_at,omitempty"` } client.Vulnerability.Query(). Select(vulnerability.FieldFirstSeenAt). Scan(ctx, &v)
func (*VulnerabilityQuery) Unique ¶
func (vq *VulnerabilityQuery) Unique(unique bool) *VulnerabilityQuery
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 (*VulnerabilityQuery) Where ¶
func (vq *VulnerabilityQuery) Where(ps ...predicate.Vulnerability) *VulnerabilityQuery
Where adds a new predicate for the VulnerabilityQuery builder.
func (*VulnerabilityQuery) WithCustomSeverity ¶ added in v0.1.1
func (vq *VulnerabilityQuery) WithCustomSeverity(opts ...func(*SeverityQuery)) *VulnerabilityQuery
WithCustomSeverity tells the query-builder to eager-load the nodes that are connected to the "custom_severity" edge. The optional arguments are used to configure the query builder of the edge.
func (*VulnerabilityQuery) WithPackages ¶
func (vq *VulnerabilityQuery) WithPackages(opts ...func(*PackageRecordQuery)) *VulnerabilityQuery
WithPackages tells the query-builder to eager-load the nodes that are connected to the "packages" edge. The optional arguments are used to configure the query builder of the edge.
type VulnerabilitySelect ¶
type VulnerabilitySelect struct { *VulnerabilityQuery // contains filtered or unexported fields }
VulnerabilitySelect is the builder for selecting fields of Vulnerability entities.
func (*VulnerabilitySelect) Bool ¶
func (vs *VulnerabilitySelect) Bool(ctx context.Context) (_ bool, err error)
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) BoolX ¶
func (vs *VulnerabilitySelect) BoolX(ctx context.Context) bool
BoolX is like Bool, but panics if an error occurs.
func (*VulnerabilitySelect) Bools ¶
func (vs *VulnerabilitySelect) Bools(ctx context.Context) ([]bool, error)
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) BoolsX ¶
func (vs *VulnerabilitySelect) BoolsX(ctx context.Context) []bool
BoolsX is like Bools, but panics if an error occurs.
func (*VulnerabilitySelect) Float64 ¶
func (vs *VulnerabilitySelect) Float64(ctx context.Context) (_ float64, err error)
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) Float64X ¶
func (vs *VulnerabilitySelect) Float64X(ctx context.Context) float64
Float64X is like Float64, but panics if an error occurs.
func (*VulnerabilitySelect) Float64s ¶
func (vs *VulnerabilitySelect) Float64s(ctx context.Context) ([]float64, error)
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) Float64sX ¶
func (vs *VulnerabilitySelect) Float64sX(ctx context.Context) []float64
Float64sX is like Float64s, but panics if an error occurs.
func (*VulnerabilitySelect) Int ¶
func (vs *VulnerabilitySelect) Int(ctx context.Context) (_ int, err error)
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) IntX ¶
func (vs *VulnerabilitySelect) IntX(ctx context.Context) int
IntX is like Int, but panics if an error occurs.
func (*VulnerabilitySelect) Ints ¶
func (vs *VulnerabilitySelect) Ints(ctx context.Context) ([]int, error)
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) IntsX ¶
func (vs *VulnerabilitySelect) IntsX(ctx context.Context) []int
IntsX is like Ints, but panics if an error occurs.
func (*VulnerabilitySelect) Scan ¶
func (vs *VulnerabilitySelect) Scan(ctx context.Context, v interface{}) error
Scan applies the selector query and scans the result into the given value.
func (*VulnerabilitySelect) ScanX ¶
func (vs *VulnerabilitySelect) ScanX(ctx context.Context, v interface{})
ScanX is like Scan, but panics if an error occurs.
func (*VulnerabilitySelect) String ¶
func (vs *VulnerabilitySelect) String(ctx context.Context) (_ string, err error)
String returns a single string from a selector. It is only allowed when selecting one field.
func (*VulnerabilitySelect) StringX ¶
func (vs *VulnerabilitySelect) StringX(ctx context.Context) string
StringX is like String, but panics if an error occurs.
type VulnerabilityUpdate ¶
type VulnerabilityUpdate struct {
// contains filtered or unexported fields
}
VulnerabilityUpdate is the builder for updating Vulnerability entities.
func (*VulnerabilityUpdate) AddFirstSeenAt ¶
func (vu *VulnerabilityUpdate) AddFirstSeenAt(i int64) *VulnerabilityUpdate
AddFirstSeenAt adds i to the "first_seen_at" field.
func (*VulnerabilityUpdate) AddLastModifiedAt ¶
func (vu *VulnerabilityUpdate) AddLastModifiedAt(i int64) *VulnerabilityUpdate
AddLastModifiedAt adds i to the "last_modified_at" field.
func (*VulnerabilityUpdate) AddPackageIDs ¶
func (vu *VulnerabilityUpdate) AddPackageIDs(ids ...int) *VulnerabilityUpdate
AddPackageIDs adds the "packages" edge to the PackageRecord entity by IDs.
func (*VulnerabilityUpdate) AddPackages ¶
func (vu *VulnerabilityUpdate) AddPackages(p ...*PackageRecord) *VulnerabilityUpdate
AddPackages adds the "packages" edges to the PackageRecord entity.
func (*VulnerabilityUpdate) ClearCustomSeverity ¶ added in v0.1.1
func (vu *VulnerabilityUpdate) ClearCustomSeverity() *VulnerabilityUpdate
ClearCustomSeverity clears the "custom_severity" edge to the Severity entity.
func (*VulnerabilityUpdate) ClearCvss ¶
func (vu *VulnerabilityUpdate) ClearCvss() *VulnerabilityUpdate
ClearCvss clears the value of the "cvss" field.
func (*VulnerabilityUpdate) ClearCweID ¶
func (vu *VulnerabilityUpdate) ClearCweID() *VulnerabilityUpdate
ClearCweID clears the value of the "cwe_id" field.
func (*VulnerabilityUpdate) ClearDescription ¶
func (vu *VulnerabilityUpdate) ClearDescription() *VulnerabilityUpdate
ClearDescription clears the value of the "description" field.
func (*VulnerabilityUpdate) ClearPackages ¶
func (vu *VulnerabilityUpdate) ClearPackages() *VulnerabilityUpdate
ClearPackages clears all "packages" edges to the PackageRecord entity.
func (*VulnerabilityUpdate) ClearReferences ¶
func (vu *VulnerabilityUpdate) ClearReferences() *VulnerabilityUpdate
ClearReferences clears the value of the "references" field.
func (*VulnerabilityUpdate) ClearSeverity ¶
func (vu *VulnerabilityUpdate) ClearSeverity() *VulnerabilityUpdate
ClearSeverity clears the value of the "severity" field.
func (*VulnerabilityUpdate) ClearTitle ¶
func (vu *VulnerabilityUpdate) ClearTitle() *VulnerabilityUpdate
ClearTitle clears the value of the "title" field.
func (*VulnerabilityUpdate) Exec ¶
func (vu *VulnerabilityUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnerabilityUpdate) ExecX ¶
func (vu *VulnerabilityUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityUpdate) Mutation ¶
func (vu *VulnerabilityUpdate) Mutation() *VulnerabilityMutation
Mutation returns the VulnerabilityMutation object of the builder.
func (*VulnerabilityUpdate) RemovePackageIDs ¶
func (vu *VulnerabilityUpdate) RemovePackageIDs(ids ...int) *VulnerabilityUpdate
RemovePackageIDs removes the "packages" edge to PackageRecord entities by IDs.
func (*VulnerabilityUpdate) RemovePackages ¶
func (vu *VulnerabilityUpdate) RemovePackages(p ...*PackageRecord) *VulnerabilityUpdate
RemovePackages removes "packages" edges to PackageRecord entities.
func (*VulnerabilityUpdate) Save ¶
func (vu *VulnerabilityUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*VulnerabilityUpdate) SaveX ¶
func (vu *VulnerabilityUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*VulnerabilityUpdate) SetCustomSeverity ¶ added in v0.1.1
func (vu *VulnerabilityUpdate) SetCustomSeverity(s *Severity) *VulnerabilityUpdate
SetCustomSeverity sets the "custom_severity" edge to the Severity entity.
func (*VulnerabilityUpdate) SetCustomSeverityID ¶ added in v0.1.1
func (vu *VulnerabilityUpdate) SetCustomSeverityID(id int) *VulnerabilityUpdate
SetCustomSeverityID sets the "custom_severity" edge to the Severity entity by ID.
func (*VulnerabilityUpdate) SetCvss ¶
func (vu *VulnerabilityUpdate) SetCvss(s []string) *VulnerabilityUpdate
SetCvss sets the "cvss" field.
func (*VulnerabilityUpdate) SetCweID ¶
func (vu *VulnerabilityUpdate) SetCweID(s []string) *VulnerabilityUpdate
SetCweID sets the "cwe_id" field.
func (*VulnerabilityUpdate) SetDescription ¶
func (vu *VulnerabilityUpdate) SetDescription(s string) *VulnerabilityUpdate
SetDescription sets the "description" field.
func (*VulnerabilityUpdate) SetFirstSeenAt ¶
func (vu *VulnerabilityUpdate) SetFirstSeenAt(i int64) *VulnerabilityUpdate
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityUpdate) SetLastModifiedAt ¶
func (vu *VulnerabilityUpdate) SetLastModifiedAt(i int64) *VulnerabilityUpdate
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityUpdate) SetNillableCustomSeverityID ¶ added in v0.1.1
func (vu *VulnerabilityUpdate) SetNillableCustomSeverityID(id *int) *VulnerabilityUpdate
SetNillableCustomSeverityID sets the "custom_severity" edge to the Severity entity by ID if the given value is not nil.
func (*VulnerabilityUpdate) SetNillableDescription ¶
func (vu *VulnerabilityUpdate) SetNillableDescription(s *string) *VulnerabilityUpdate
SetNillableDescription sets the "description" field if the given value is not nil.
func (*VulnerabilityUpdate) SetNillableSeverity ¶
func (vu *VulnerabilityUpdate) SetNillableSeverity(s *string) *VulnerabilityUpdate
SetNillableSeverity sets the "severity" field if the given value is not nil.
func (*VulnerabilityUpdate) SetNillableTitle ¶
func (vu *VulnerabilityUpdate) SetNillableTitle(s *string) *VulnerabilityUpdate
SetNillableTitle sets the "title" field if the given value is not nil.
func (*VulnerabilityUpdate) SetReferences ¶
func (vu *VulnerabilityUpdate) SetReferences(s []string) *VulnerabilityUpdate
SetReferences sets the "references" field.
func (*VulnerabilityUpdate) SetSeverity ¶
func (vu *VulnerabilityUpdate) SetSeverity(s string) *VulnerabilityUpdate
SetSeverity sets the "severity" field.
func (*VulnerabilityUpdate) SetTitle ¶
func (vu *VulnerabilityUpdate) SetTitle(s string) *VulnerabilityUpdate
SetTitle sets the "title" field.
func (*VulnerabilityUpdate) Where ¶
func (vu *VulnerabilityUpdate) Where(ps ...predicate.Vulnerability) *VulnerabilityUpdate
Where appends a list predicates to the VulnerabilityUpdate builder.
type VulnerabilityUpdateOne ¶
type VulnerabilityUpdateOne struct {
// contains filtered or unexported fields
}
VulnerabilityUpdateOne is the builder for updating a single Vulnerability entity.
func (*VulnerabilityUpdateOne) AddFirstSeenAt ¶
func (vuo *VulnerabilityUpdateOne) AddFirstSeenAt(i int64) *VulnerabilityUpdateOne
AddFirstSeenAt adds i to the "first_seen_at" field.
func (*VulnerabilityUpdateOne) AddLastModifiedAt ¶
func (vuo *VulnerabilityUpdateOne) AddLastModifiedAt(i int64) *VulnerabilityUpdateOne
AddLastModifiedAt adds i to the "last_modified_at" field.
func (*VulnerabilityUpdateOne) AddPackageIDs ¶
func (vuo *VulnerabilityUpdateOne) AddPackageIDs(ids ...int) *VulnerabilityUpdateOne
AddPackageIDs adds the "packages" edge to the PackageRecord entity by IDs.
func (*VulnerabilityUpdateOne) AddPackages ¶
func (vuo *VulnerabilityUpdateOne) AddPackages(p ...*PackageRecord) *VulnerabilityUpdateOne
AddPackages adds the "packages" edges to the PackageRecord entity.
func (*VulnerabilityUpdateOne) ClearCustomSeverity ¶ added in v0.1.1
func (vuo *VulnerabilityUpdateOne) ClearCustomSeverity() *VulnerabilityUpdateOne
ClearCustomSeverity clears the "custom_severity" edge to the Severity entity.
func (*VulnerabilityUpdateOne) ClearCvss ¶
func (vuo *VulnerabilityUpdateOne) ClearCvss() *VulnerabilityUpdateOne
ClearCvss clears the value of the "cvss" field.
func (*VulnerabilityUpdateOne) ClearCweID ¶
func (vuo *VulnerabilityUpdateOne) ClearCweID() *VulnerabilityUpdateOne
ClearCweID clears the value of the "cwe_id" field.
func (*VulnerabilityUpdateOne) ClearDescription ¶
func (vuo *VulnerabilityUpdateOne) ClearDescription() *VulnerabilityUpdateOne
ClearDescription clears the value of the "description" field.
func (*VulnerabilityUpdateOne) ClearPackages ¶
func (vuo *VulnerabilityUpdateOne) ClearPackages() *VulnerabilityUpdateOne
ClearPackages clears all "packages" edges to the PackageRecord entity.
func (*VulnerabilityUpdateOne) ClearReferences ¶
func (vuo *VulnerabilityUpdateOne) ClearReferences() *VulnerabilityUpdateOne
ClearReferences clears the value of the "references" field.
func (*VulnerabilityUpdateOne) ClearSeverity ¶
func (vuo *VulnerabilityUpdateOne) ClearSeverity() *VulnerabilityUpdateOne
ClearSeverity clears the value of the "severity" field.
func (*VulnerabilityUpdateOne) ClearTitle ¶
func (vuo *VulnerabilityUpdateOne) ClearTitle() *VulnerabilityUpdateOne
ClearTitle clears the value of the "title" field.
func (*VulnerabilityUpdateOne) Exec ¶
func (vuo *VulnerabilityUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*VulnerabilityUpdateOne) ExecX ¶
func (vuo *VulnerabilityUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityUpdateOne) Mutation ¶
func (vuo *VulnerabilityUpdateOne) Mutation() *VulnerabilityMutation
Mutation returns the VulnerabilityMutation object of the builder.
func (*VulnerabilityUpdateOne) RemovePackageIDs ¶
func (vuo *VulnerabilityUpdateOne) RemovePackageIDs(ids ...int) *VulnerabilityUpdateOne
RemovePackageIDs removes the "packages" edge to PackageRecord entities by IDs.
func (*VulnerabilityUpdateOne) RemovePackages ¶
func (vuo *VulnerabilityUpdateOne) RemovePackages(p ...*PackageRecord) *VulnerabilityUpdateOne
RemovePackages removes "packages" edges to PackageRecord entities.
func (*VulnerabilityUpdateOne) Save ¶
func (vuo *VulnerabilityUpdateOne) Save(ctx context.Context) (*Vulnerability, error)
Save executes the query and returns the updated Vulnerability entity.
func (*VulnerabilityUpdateOne) SaveX ¶
func (vuo *VulnerabilityUpdateOne) SaveX(ctx context.Context) *Vulnerability
SaveX is like Save, but panics if an error occurs.
func (*VulnerabilityUpdateOne) Select ¶
func (vuo *VulnerabilityUpdateOne) Select(field string, fields ...string) *VulnerabilityUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*VulnerabilityUpdateOne) SetCustomSeverity ¶ added in v0.1.1
func (vuo *VulnerabilityUpdateOne) SetCustomSeverity(s *Severity) *VulnerabilityUpdateOne
SetCustomSeverity sets the "custom_severity" edge to the Severity entity.
func (*VulnerabilityUpdateOne) SetCustomSeverityID ¶ added in v0.1.1
func (vuo *VulnerabilityUpdateOne) SetCustomSeverityID(id int) *VulnerabilityUpdateOne
SetCustomSeverityID sets the "custom_severity" edge to the Severity entity by ID.
func (*VulnerabilityUpdateOne) SetCvss ¶
func (vuo *VulnerabilityUpdateOne) SetCvss(s []string) *VulnerabilityUpdateOne
SetCvss sets the "cvss" field.
func (*VulnerabilityUpdateOne) SetCweID ¶
func (vuo *VulnerabilityUpdateOne) SetCweID(s []string) *VulnerabilityUpdateOne
SetCweID sets the "cwe_id" field.
func (*VulnerabilityUpdateOne) SetDescription ¶
func (vuo *VulnerabilityUpdateOne) SetDescription(s string) *VulnerabilityUpdateOne
SetDescription sets the "description" field.
func (*VulnerabilityUpdateOne) SetFirstSeenAt ¶
func (vuo *VulnerabilityUpdateOne) SetFirstSeenAt(i int64) *VulnerabilityUpdateOne
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityUpdateOne) SetLastModifiedAt ¶
func (vuo *VulnerabilityUpdateOne) SetLastModifiedAt(i int64) *VulnerabilityUpdateOne
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityUpdateOne) SetNillableCustomSeverityID ¶ added in v0.1.1
func (vuo *VulnerabilityUpdateOne) SetNillableCustomSeverityID(id *int) *VulnerabilityUpdateOne
SetNillableCustomSeverityID sets the "custom_severity" edge to the Severity entity by ID if the given value is not nil.
func (*VulnerabilityUpdateOne) SetNillableDescription ¶
func (vuo *VulnerabilityUpdateOne) SetNillableDescription(s *string) *VulnerabilityUpdateOne
SetNillableDescription sets the "description" field if the given value is not nil.
func (*VulnerabilityUpdateOne) SetNillableSeverity ¶
func (vuo *VulnerabilityUpdateOne) SetNillableSeverity(s *string) *VulnerabilityUpdateOne
SetNillableSeverity sets the "severity" field if the given value is not nil.
func (*VulnerabilityUpdateOne) SetNillableTitle ¶
func (vuo *VulnerabilityUpdateOne) SetNillableTitle(s *string) *VulnerabilityUpdateOne
SetNillableTitle sets the "title" field if the given value is not nil.
func (*VulnerabilityUpdateOne) SetReferences ¶
func (vuo *VulnerabilityUpdateOne) SetReferences(s []string) *VulnerabilityUpdateOne
SetReferences sets the "references" field.
func (*VulnerabilityUpdateOne) SetSeverity ¶
func (vuo *VulnerabilityUpdateOne) SetSeverity(s string) *VulnerabilityUpdateOne
SetSeverity sets the "severity" field.
func (*VulnerabilityUpdateOne) SetTitle ¶
func (vuo *VulnerabilityUpdateOne) SetTitle(s string) *VulnerabilityUpdateOne
SetTitle sets the "title" field.
type VulnerabilityUpsert ¶
VulnerabilityUpsert is the "OnConflict" setter.
func (*VulnerabilityUpsert) ClearCvss ¶
func (u *VulnerabilityUpsert) ClearCvss() *VulnerabilityUpsert
ClearCvss clears the value of the "cvss" field.
func (*VulnerabilityUpsert) ClearCweID ¶
func (u *VulnerabilityUpsert) ClearCweID() *VulnerabilityUpsert
ClearCweID clears the value of the "cwe_id" field.
func (*VulnerabilityUpsert) ClearDescription ¶
func (u *VulnerabilityUpsert) ClearDescription() *VulnerabilityUpsert
ClearDescription clears the value of the "description" field.
func (*VulnerabilityUpsert) ClearReferences ¶
func (u *VulnerabilityUpsert) ClearReferences() *VulnerabilityUpsert
ClearReferences clears the value of the "references" field.
func (*VulnerabilityUpsert) ClearSeverity ¶
func (u *VulnerabilityUpsert) ClearSeverity() *VulnerabilityUpsert
ClearSeverity clears the value of the "severity" field.
func (*VulnerabilityUpsert) ClearTitle ¶
func (u *VulnerabilityUpsert) ClearTitle() *VulnerabilityUpsert
ClearTitle clears the value of the "title" field.
func (*VulnerabilityUpsert) SetCvss ¶
func (u *VulnerabilityUpsert) SetCvss(v []string) *VulnerabilityUpsert
SetCvss sets the "cvss" field.
func (*VulnerabilityUpsert) SetCweID ¶
func (u *VulnerabilityUpsert) SetCweID(v []string) *VulnerabilityUpsert
SetCweID sets the "cwe_id" field.
func (*VulnerabilityUpsert) SetDescription ¶
func (u *VulnerabilityUpsert) SetDescription(v string) *VulnerabilityUpsert
SetDescription sets the "description" field.
func (*VulnerabilityUpsert) SetFirstSeenAt ¶
func (u *VulnerabilityUpsert) SetFirstSeenAt(v int64) *VulnerabilityUpsert
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityUpsert) SetLastModifiedAt ¶
func (u *VulnerabilityUpsert) SetLastModifiedAt(v int64) *VulnerabilityUpsert
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityUpsert) SetReferences ¶
func (u *VulnerabilityUpsert) SetReferences(v []string) *VulnerabilityUpsert
SetReferences sets the "references" field.
func (*VulnerabilityUpsert) SetSeverity ¶
func (u *VulnerabilityUpsert) SetSeverity(v string) *VulnerabilityUpsert
SetSeverity sets the "severity" field.
func (*VulnerabilityUpsert) SetTitle ¶
func (u *VulnerabilityUpsert) SetTitle(v string) *VulnerabilityUpsert
SetTitle sets the "title" field.
func (*VulnerabilityUpsert) UpdateCvss ¶
func (u *VulnerabilityUpsert) UpdateCvss() *VulnerabilityUpsert
UpdateCvss sets the "cvss" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateCweID ¶
func (u *VulnerabilityUpsert) UpdateCweID() *VulnerabilityUpsert
UpdateCweID sets the "cwe_id" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateDescription ¶
func (u *VulnerabilityUpsert) UpdateDescription() *VulnerabilityUpsert
UpdateDescription sets the "description" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateFirstSeenAt ¶
func (u *VulnerabilityUpsert) UpdateFirstSeenAt() *VulnerabilityUpsert
UpdateFirstSeenAt sets the "first_seen_at" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateLastModifiedAt ¶
func (u *VulnerabilityUpsert) UpdateLastModifiedAt() *VulnerabilityUpsert
UpdateLastModifiedAt sets the "last_modified_at" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateReferences ¶
func (u *VulnerabilityUpsert) UpdateReferences() *VulnerabilityUpsert
UpdateReferences sets the "references" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateSeverity ¶
func (u *VulnerabilityUpsert) UpdateSeverity() *VulnerabilityUpsert
UpdateSeverity sets the "severity" field to the value that was provided on create.
func (*VulnerabilityUpsert) UpdateTitle ¶
func (u *VulnerabilityUpsert) UpdateTitle() *VulnerabilityUpsert
UpdateTitle sets the "title" field to the value that was provided on create.
type VulnerabilityUpsertBulk ¶
type VulnerabilityUpsertBulk struct {
// contains filtered or unexported fields
}
VulnerabilityUpsertBulk is the builder for "upsert"-ing a bulk of Vulnerability nodes.
func (*VulnerabilityUpsertBulk) ClearCvss ¶
func (u *VulnerabilityUpsertBulk) ClearCvss() *VulnerabilityUpsertBulk
ClearCvss clears the value of the "cvss" field.
func (*VulnerabilityUpsertBulk) ClearCweID ¶
func (u *VulnerabilityUpsertBulk) ClearCweID() *VulnerabilityUpsertBulk
ClearCweID clears the value of the "cwe_id" field.
func (*VulnerabilityUpsertBulk) ClearDescription ¶
func (u *VulnerabilityUpsertBulk) ClearDescription() *VulnerabilityUpsertBulk
ClearDescription clears the value of the "description" field.
func (*VulnerabilityUpsertBulk) ClearReferences ¶
func (u *VulnerabilityUpsertBulk) ClearReferences() *VulnerabilityUpsertBulk
ClearReferences clears the value of the "references" field.
func (*VulnerabilityUpsertBulk) ClearSeverity ¶
func (u *VulnerabilityUpsertBulk) ClearSeverity() *VulnerabilityUpsertBulk
ClearSeverity clears the value of the "severity" field.
func (*VulnerabilityUpsertBulk) ClearTitle ¶
func (u *VulnerabilityUpsertBulk) ClearTitle() *VulnerabilityUpsertBulk
ClearTitle clears the value of the "title" field.
func (*VulnerabilityUpsertBulk) DoNothing ¶
func (u *VulnerabilityUpsertBulk) DoNothing() *VulnerabilityUpsertBulk
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*VulnerabilityUpsertBulk) Exec ¶
func (u *VulnerabilityUpsertBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnerabilityUpsertBulk) ExecX ¶
func (u *VulnerabilityUpsertBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityUpsertBulk) Ignore ¶
func (u *VulnerabilityUpsertBulk) Ignore() *VulnerabilityUpsertBulk
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Vulnerability.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*VulnerabilityUpsertBulk) SetCvss ¶
func (u *VulnerabilityUpsertBulk) SetCvss(v []string) *VulnerabilityUpsertBulk
SetCvss sets the "cvss" field.
func (*VulnerabilityUpsertBulk) SetCweID ¶
func (u *VulnerabilityUpsertBulk) SetCweID(v []string) *VulnerabilityUpsertBulk
SetCweID sets the "cwe_id" field.
func (*VulnerabilityUpsertBulk) SetDescription ¶
func (u *VulnerabilityUpsertBulk) SetDescription(v string) *VulnerabilityUpsertBulk
SetDescription sets the "description" field.
func (*VulnerabilityUpsertBulk) SetFirstSeenAt ¶
func (u *VulnerabilityUpsertBulk) SetFirstSeenAt(v int64) *VulnerabilityUpsertBulk
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityUpsertBulk) SetLastModifiedAt ¶
func (u *VulnerabilityUpsertBulk) SetLastModifiedAt(v int64) *VulnerabilityUpsertBulk
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityUpsertBulk) SetReferences ¶
func (u *VulnerabilityUpsertBulk) SetReferences(v []string) *VulnerabilityUpsertBulk
SetReferences sets the "references" field.
func (*VulnerabilityUpsertBulk) SetSeverity ¶
func (u *VulnerabilityUpsertBulk) SetSeverity(v string) *VulnerabilityUpsertBulk
SetSeverity sets the "severity" field.
func (*VulnerabilityUpsertBulk) SetTitle ¶
func (u *VulnerabilityUpsertBulk) SetTitle(v string) *VulnerabilityUpsertBulk
SetTitle sets the "title" field.
func (*VulnerabilityUpsertBulk) Update ¶
func (u *VulnerabilityUpsertBulk) Update(set func(*VulnerabilityUpsert)) *VulnerabilityUpsertBulk
Update allows overriding fields `UPDATE` values. See the VulnerabilityCreateBulk.OnConflict documentation for more info.
func (*VulnerabilityUpsertBulk) UpdateCvss ¶
func (u *VulnerabilityUpsertBulk) UpdateCvss() *VulnerabilityUpsertBulk
UpdateCvss sets the "cvss" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateCweID ¶
func (u *VulnerabilityUpsertBulk) UpdateCweID() *VulnerabilityUpsertBulk
UpdateCweID sets the "cwe_id" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateDescription ¶
func (u *VulnerabilityUpsertBulk) UpdateDescription() *VulnerabilityUpsertBulk
UpdateDescription sets the "description" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateFirstSeenAt ¶
func (u *VulnerabilityUpsertBulk) UpdateFirstSeenAt() *VulnerabilityUpsertBulk
UpdateFirstSeenAt sets the "first_seen_at" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateLastModifiedAt ¶
func (u *VulnerabilityUpsertBulk) UpdateLastModifiedAt() *VulnerabilityUpsertBulk
UpdateLastModifiedAt sets the "last_modified_at" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateNewValues ¶
func (u *VulnerabilityUpsertBulk) UpdateNewValues() *VulnerabilityUpsertBulk
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Vulnerability.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*VulnerabilityUpsertBulk) UpdateReferences ¶
func (u *VulnerabilityUpsertBulk) UpdateReferences() *VulnerabilityUpsertBulk
UpdateReferences sets the "references" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateSeverity ¶
func (u *VulnerabilityUpsertBulk) UpdateSeverity() *VulnerabilityUpsertBulk
UpdateSeverity sets the "severity" field to the value that was provided on create.
func (*VulnerabilityUpsertBulk) UpdateTitle ¶
func (u *VulnerabilityUpsertBulk) UpdateTitle() *VulnerabilityUpsertBulk
UpdateTitle sets the "title" field to the value that was provided on create.
type VulnerabilityUpsertOne ¶
type VulnerabilityUpsertOne struct {
// contains filtered or unexported fields
}
VulnerabilityUpsertOne is the builder for "upsert"-ing
one Vulnerability node.
func (*VulnerabilityUpsertOne) ClearCvss ¶
func (u *VulnerabilityUpsertOne) ClearCvss() *VulnerabilityUpsertOne
ClearCvss clears the value of the "cvss" field.
func (*VulnerabilityUpsertOne) ClearCweID ¶
func (u *VulnerabilityUpsertOne) ClearCweID() *VulnerabilityUpsertOne
ClearCweID clears the value of the "cwe_id" field.
func (*VulnerabilityUpsertOne) ClearDescription ¶
func (u *VulnerabilityUpsertOne) ClearDescription() *VulnerabilityUpsertOne
ClearDescription clears the value of the "description" field.
func (*VulnerabilityUpsertOne) ClearReferences ¶
func (u *VulnerabilityUpsertOne) ClearReferences() *VulnerabilityUpsertOne
ClearReferences clears the value of the "references" field.
func (*VulnerabilityUpsertOne) ClearSeverity ¶
func (u *VulnerabilityUpsertOne) ClearSeverity() *VulnerabilityUpsertOne
ClearSeverity clears the value of the "severity" field.
func (*VulnerabilityUpsertOne) ClearTitle ¶
func (u *VulnerabilityUpsertOne) ClearTitle() *VulnerabilityUpsertOne
ClearTitle clears the value of the "title" field.
func (*VulnerabilityUpsertOne) DoNothing ¶
func (u *VulnerabilityUpsertOne) DoNothing() *VulnerabilityUpsertOne
DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.
func (*VulnerabilityUpsertOne) Exec ¶
func (u *VulnerabilityUpsertOne) Exec(ctx context.Context) error
Exec executes the query.
func (*VulnerabilityUpsertOne) ExecX ¶
func (u *VulnerabilityUpsertOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*VulnerabilityUpsertOne) ID ¶
func (u *VulnerabilityUpsertOne) ID(ctx context.Context) (id string, err error)
Exec executes the UPSERT query and returns the inserted/updated ID.
func (*VulnerabilityUpsertOne) IDX ¶
func (u *VulnerabilityUpsertOne) IDX(ctx context.Context) string
IDX is like ID, but panics if an error occurs.
func (*VulnerabilityUpsertOne) Ignore ¶
func (u *VulnerabilityUpsertOne) Ignore() *VulnerabilityUpsertOne
Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:
client.Vulnerability.Create(). OnConflict(sql.ResolveWithIgnore()). Exec(ctx)
func (*VulnerabilityUpsertOne) SetCvss ¶
func (u *VulnerabilityUpsertOne) SetCvss(v []string) *VulnerabilityUpsertOne
SetCvss sets the "cvss" field.
func (*VulnerabilityUpsertOne) SetCweID ¶
func (u *VulnerabilityUpsertOne) SetCweID(v []string) *VulnerabilityUpsertOne
SetCweID sets the "cwe_id" field.
func (*VulnerabilityUpsertOne) SetDescription ¶
func (u *VulnerabilityUpsertOne) SetDescription(v string) *VulnerabilityUpsertOne
SetDescription sets the "description" field.
func (*VulnerabilityUpsertOne) SetFirstSeenAt ¶
func (u *VulnerabilityUpsertOne) SetFirstSeenAt(v int64) *VulnerabilityUpsertOne
SetFirstSeenAt sets the "first_seen_at" field.
func (*VulnerabilityUpsertOne) SetLastModifiedAt ¶
func (u *VulnerabilityUpsertOne) SetLastModifiedAt(v int64) *VulnerabilityUpsertOne
SetLastModifiedAt sets the "last_modified_at" field.
func (*VulnerabilityUpsertOne) SetReferences ¶
func (u *VulnerabilityUpsertOne) SetReferences(v []string) *VulnerabilityUpsertOne
SetReferences sets the "references" field.
func (*VulnerabilityUpsertOne) SetSeverity ¶
func (u *VulnerabilityUpsertOne) SetSeverity(v string) *VulnerabilityUpsertOne
SetSeverity sets the "severity" field.
func (*VulnerabilityUpsertOne) SetTitle ¶
func (u *VulnerabilityUpsertOne) SetTitle(v string) *VulnerabilityUpsertOne
SetTitle sets the "title" field.
func (*VulnerabilityUpsertOne) Update ¶
func (u *VulnerabilityUpsertOne) Update(set func(*VulnerabilityUpsert)) *VulnerabilityUpsertOne
Update allows overriding fields `UPDATE` values. See the VulnerabilityCreate.OnConflict documentation for more info.
func (*VulnerabilityUpsertOne) UpdateCvss ¶
func (u *VulnerabilityUpsertOne) UpdateCvss() *VulnerabilityUpsertOne
UpdateCvss sets the "cvss" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateCweID ¶
func (u *VulnerabilityUpsertOne) UpdateCweID() *VulnerabilityUpsertOne
UpdateCweID sets the "cwe_id" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateDescription ¶
func (u *VulnerabilityUpsertOne) UpdateDescription() *VulnerabilityUpsertOne
UpdateDescription sets the "description" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateFirstSeenAt ¶
func (u *VulnerabilityUpsertOne) UpdateFirstSeenAt() *VulnerabilityUpsertOne
UpdateFirstSeenAt sets the "first_seen_at" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateLastModifiedAt ¶
func (u *VulnerabilityUpsertOne) UpdateLastModifiedAt() *VulnerabilityUpsertOne
UpdateLastModifiedAt sets the "last_modified_at" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateNewValues ¶
func (u *VulnerabilityUpsertOne) UpdateNewValues() *VulnerabilityUpsertOne
UpdateNewValues updates the fields using the new values that were set on create. Using this option is equivalent to using:
client.Vulnerability.Create(). OnConflict(sql.ResolveWithNewValues()). Exec(ctx)
func (*VulnerabilityUpsertOne) UpdateReferences ¶
func (u *VulnerabilityUpsertOne) UpdateReferences() *VulnerabilityUpsertOne
UpdateReferences sets the "references" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateSeverity ¶
func (u *VulnerabilityUpsertOne) UpdateSeverity() *VulnerabilityUpsertOne
UpdateSeverity sets the "severity" field to the value that was provided on create.
func (*VulnerabilityUpsertOne) UpdateTitle ¶
func (u *VulnerabilityUpsertOne) UpdateTitle() *VulnerabilityUpsertOne
UpdateTitle sets the "title" field to the value that was provided on create.
Source Files ¶
- authstatecache.go
- authstatecache_create.go
- authstatecache_delete.go
- authstatecache_query.go
- authstatecache_update.go
- client.go
- config.go
- context.go
- ent.go
- generate.go
- mutation.go
- packagerecord.go
- packagerecord_create.go
- packagerecord_delete.go
- packagerecord_query.go
- packagerecord_update.go
- repository.go
- repository_create.go
- repository_delete.go
- repository_query.go
- repository_update.go
- runtime.go
- scan.go
- scan_create.go
- scan_delete.go
- scan_query.go
- scan_update.go
- session.go
- session_create.go
- session_delete.go
- session_query.go
- session_update.go
- severity.go
- severity_create.go
- severity_delete.go
- severity_query.go
- severity_update.go
- tx.go
- user.go
- user_create.go
- user_delete.go
- user_query.go
- user_update.go
- vulnerability.go
- vulnerability_create.go
- vulnerability_delete.go
- vulnerability_query.go
- vulnerability_update.go
- vulnstatus.go
- vulnstatus_create.go
- vulnstatus_delete.go
- vulnstatus_query.go
- vulnstatus_update.go
- vulnstatusindex.go
- vulnstatusindex_create.go
- vulnstatusindex_delete.go
- vulnstatusindex_query.go
- vulnstatusindex_update.go