codeclarity

package
v0.0.14-alpha Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2025 License: AGPL-3.0 Imports: 3 Imported by: 25

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Analysis

type Analysis struct {
	bun.BaseModel  `bun:"table:analysis,alias:analysis"`
	Id             uuid.UUID  `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
	AnalyzerId     uuid.UUID  `bun:"analyzerId"`
	OrganizationId uuid.UUID  `bun:"organizationId"`
	ProjectId      *uuid.UUID `bun:"projectId"` // Pointer allows null values
	Config         map[string]any
	Stage          int
	Steps          [][]Step
	Status         AnalysisStatus
	Commit         string `bun:"commit_hash"`
	Branch         string
}

type AnalysisStatus

type AnalysisStatus string
const (
	SUCCESS     AnalysisStatus = "success"
	UPDATING_DB AnalysisStatus = "updating_db"
	ONGOING     AnalysisStatus = "ongoing"
	FAILURE     AnalysisStatus = "failure"
	COMPLETED   AnalysisStatus = "completed"
	STARTED     AnalysisStatus = "started"
)

type Analyzer

type Analyzer struct {
	bun.BaseModel  `bun:"table:analyzer,alias:analyzer"`
	Id             uuid.UUID `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
	Name           string
	Description    string
	CreatedOn      string `bun:"created_on"`
	Steps          [][]Step
	OrganizationId string `bun:"organizationId"`
	CreatedById    string `bun:"createdById"`
}

type File

type File struct {
	bun.BaseModel `bun:"table:file,alias:file"`
	Id            uuid.UUID `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
	Added_on      time.Time
	Type          string
	Name          string
	ProjectId     uuid.UUID `bun:"projectId"`
	Project       Project   `bun:"rel:belongs-to,join:'projectId'=id"`
	AddedById     uuid.UUID `bun:"addedById"`
	AddedBy       User      `bun:"rel:belongs-to,join:'addedById'=id"`
}

type Integration

type Integration struct {
	bun.BaseModel   `bun:"table:integration,alias:integration"`
	Id              uuid.UUID `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
	IntegrationType string    `bun:"integration_type"`
	AccessToken     string    `bun:"access_token"`
	TokenType       string    `bun:"token_type"`
	Invalid         bool      `bun:"invalid"`
	AddedOn         string    `bun:"added_on"`
	AddedBy         string    `bun:"ownerId"`
	ServiceDomain   string    `bun:"service_domain"`
}

type Project

type Project struct {
	bun.BaseModel  `bun:"table:project,alias:project"`
	Id             uuid.UUID `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
	Name           string
	Description    string
	Integration_id string `bun:"integrationId"`
	Type           string
	Url            string
}

type Result

type Result struct {
	bun.BaseModel `bun:"table:result,alias:r"`
	Id            uuid.UUID   `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
	Result        interface{} `bun:"result"`
	AnalysisId    uuid.UUID   `bun:"analysisId"`
	Plugin        string      `bun:"plugin"`
	CreatedOn     time.Time   `bun:"created_on,default:current_timestamp"`
}

type Step

type Step struct {
	Name       string
	Version    string
	Config     map[string]any
	Status     AnalysisStatus
	Result     map[string]any
	Started_on string
	Ended_on   string
}

type User

type User struct {
	bun.BaseModel `bun:"table:user,alias:user"`
	Id            uuid.UUID `bun:",pk,autoincrement,type:uuid,default:uuid_generate_v4()"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL