Documentation ¶
Index ¶
- type Accessory
- type AdditionLink
- type Artifact
- type CVEAllowlist
- type ExecHistory
- type GCHistory
- type GCSchedule
- type ImmutableRule
- type Label
- type Option
- type OverviewOptions
- type Project
- type Quota
- type Reference
- type RepoRecord
- type ResourceList
- type RetentionExec
- type RetentionPolicy
- type RetentionTask
- type Robot
- type ScannerMetadata
- type ScannerRegistration
- type Schedule
- type ScheduleParam
- type Tag
- type User
- type WebhookJob
- type WebhookPolicy
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdditionLink ¶
type AdditionLink struct {
*artifact.AdditionLink
}
AdditionLink is a link via that the addition can be fetched
func NewAdditionLink ¶
func NewAdditionLink(a *artifact.AdditionLink) *AdditionLink
NewAdditionLink ...
func (*AdditionLink) ToSwagger ¶
func (a *AdditionLink) ToSwagger() models.AdditionLink
ToSwagger converts the addition link to the swagger model
type Artifact ¶
type Artifact struct { artifact.Artifact // TODO: rename to VulOverview ScanOverview map[string]interface{} `json:"scan_overview"` SBOMOverView map[string]interface{} `json:"sbom_overview"` }
Artifact model
type CVEAllowlist ¶
type CVEAllowlist struct {
*models.CVEAllowlist
}
CVEAllowlist model
func NewCVEAllowlist ¶
func NewCVEAllowlist(l *models.CVEAllowlist) *CVEAllowlist
NewCVEAllowlist ...
func (*CVEAllowlist) ToSwagger ¶
func (l *CVEAllowlist) ToSwagger() *svrmodels.CVEAllowlist
ToSwagger converts the model to swagger model
type ExecHistory ¶
type ExecHistory struct { Schedule *ScheduleParam `json:"schedule"` ID int64 `json:"id"` Name string `json:"job_name"` Kind string `json:"job_kind"` Parameters string `json:"job_parameters"` Status string `json:"job_status"` UUID string `json:"-"` Deleted bool `json:"deleted"` CreationTime time.Time `json:"creation_time"` UpdateTime time.Time `json:"update_time"` }
ExecHistory execution history
func (*ExecHistory) ToSwagger ¶
func (h *ExecHistory) ToSwagger() *models.ExecHistory
ToSwagger converts the history to the swagger model
type GCHistory ¶
type GCHistory struct { Schedule *ScheduleParam `json:"schedule"` ID int64 `json:"id"` Name string `json:"job_name"` Kind string `json:"job_kind"` Parameters string `json:"job_parameters"` Status string `json:"job_status"` UUID string `json:"-"` Deleted bool `json:"deleted"` CreationTime time.Time `json:"creation_time"` UpdateTime time.Time `json:"update_time"` }
GCHistory gc execution history
type GCSchedule ¶
GCSchedule ...
func (*GCSchedule) ToSwagger ¶
func (s *GCSchedule) ToSwagger() *models.GCHistory
ToSwagger converts the schedule to the swagger model
type ImmutableRule ¶
ImmutableRule ...
func NewImmutableRule ¶
func NewImmutableRule(meta *pkg_model.Metadata) *ImmutableRule
NewImmutableRule ...
func (*ImmutableRule) ToScopeSelectors ¶
func (ir *ImmutableRule) ToScopeSelectors() map[string][]models.ImmutableSelector
ToScopeSelectors ...
func (*ImmutableRule) ToSwagger ¶
func (ir *ImmutableRule) ToSwagger() *models.ImmutableRule
ToSwagger ...
func (*ImmutableRule) ToTagSelectors ¶
func (ir *ImmutableRule) ToTagSelectors() []*models.ImmutableSelector
ToTagSelectors ...
type OverviewOptions ¶
OverviewOptions define the option to query overview info
func NewOverviewOptions ¶
func NewOverviewOptions(options ...Option) *OverviewOptions
NewOverviewOptions create a new OverviewOptions
type RepoRecord ¶
type RepoRecord struct {
*model.RepoRecord
}
RepoRecord model
func (*RepoRecord) ToSwagger ¶
func (r *RepoRecord) ToSwagger() *models.Repository
ToSwagger converts the repository into the swagger model
type ResourceList ¶
type ResourceList struct {
types.ResourceList
}
ResourceList model
func NewResourceList ¶
func NewResourceList(rl types.ResourceList) *ResourceList
NewResourceList new resource list instance
func (*ResourceList) ToSwagger ¶
func (rl *ResourceList) ToSwagger() models.ResourceList
ToSwagger converts the resource list to the swagger model
type RetentionExec ¶
RetentionExec ...
func NewRetentionExec ¶
func NewRetentionExec(exec *retention.Execution) *RetentionExec
NewRetentionExec ...
func (*RetentionExec) ToSwagger ¶
func (e *RetentionExec) ToSwagger() *models.RetentionExecution
ToSwagger ...
type RetentionPolicy ¶
RetentionPolicy ...
func NewRetentionPolicy ¶
func NewRetentionPolicy(policy *policy.Metadata) *RetentionPolicy
NewRetentionPolicy ...
func NewRetentionPolicyFromSwagger ¶
func NewRetentionPolicyFromSwagger(policy *models.RetentionPolicy) *RetentionPolicy
NewRetentionPolicyFromSwagger ...
func (*RetentionPolicy) ToSwagger ¶
func (s *RetentionPolicy) ToSwagger() *models.RetentionPolicy
ToSwagger ...
type RetentionTask ¶
RetentionTask ...
func NewRetentionTask ¶
func NewRetentionTask(task *retention.Task) *RetentionTask
NewRetentionTask ...
func (*RetentionTask) ToSwagger ¶
func (e *RetentionTask) ToSwagger() *models.RetentionExecutionTask
ToSwagger ...
type ScannerMetadata ¶
type ScannerMetadata struct {
*v1.ScannerAdapterMetadata
}
ScannerMetadata ...
func NewScannerMetadata ¶
func NewScannerMetadata(md *v1.ScannerAdapterMetadata) *ScannerMetadata
NewScannerMetadata ...
func (*ScannerMetadata) ToSwagger ¶
func (s *ScannerMetadata) ToSwagger(_ context.Context) *models.ScannerAdapterMetadata
ToSwagger ...
type ScannerRegistration ¶
type ScannerRegistration struct {
*scanner.Registration
}
ScannerRegistration ...
func NewScannerRegistration ¶
func NewScannerRegistration(scanner *scanner.Registration) *ScannerRegistration
NewScannerRegistration ...
func (*ScannerRegistration) ToSwagger ¶
func (s *ScannerRegistration) ToSwagger(_ context.Context) *models.ScannerRegistration
ToSwagger ...
type ScheduleParam ¶
type ScheduleParam struct { // Daily, Weekly, Custom, Manual, None Type string `json:"type"` // The cron string of scheduled job Cron string `json:"cron"` }
ScheduleParam defines the parameter of schedule trigger
type User ¶
User ...
func (*User) ToSearchRespItem ¶
func (u *User) ToSearchRespItem() *svrmodels.UserSearchRespItem
ToSearchRespItem ...
func (*User) ToUserProfile ¶
func (u *User) ToUserProfile() *svrmodels.UserProfile
ToUserProfile ...
type WebhookJob ¶
WebhookJob ...
type WebhookPolicy ¶
WebhookPolicy ...
func (*WebhookPolicy) ToSwagger ¶
func (n *WebhookPolicy) ToSwagger() *models.WebhookPolicy
ToSwagger ...
func (*WebhookPolicy) ToTargets ¶
func (n *WebhookPolicy) ToTargets() []*models.WebhookTargetObject
ToTargets ...