Documentation
¶
Index ¶
- Constants
- type Artifact
- type Commit
- type Contributor
- type ContributorInfo
- type Core
- func (cr *Core) GetAllCores() []Core
- func (cr *Core) HighestPossibleValue() float64
- func (cr *Core) Intake(value float64, weight float64)
- func (cr *Core) IntakeLimit(value, limit, weight float64)
- func (cr *Core) IntakeThreshold(value, threshold, weight float64)
- func (cr *Core) IsInconclusive() bool
- func (cr *Core) Normalized() Core
- func (cr *Core) Overtake(from Core, weight float64)
- func (cr *Core) Recommend() RecommendationDistribution
- func (cr *Core) Sum() float64
- func (cr *Core) ToString() string
- func (cr *Core) ToStringDeep() string
- type CoreName
- type DataModel
- type Dependency
- type Distribution
- type ExternalReference
- type HashAlgorithm
- type Issue
- type IssueContribution
- type IssueState
- type Library
- type Organization
- type Recommendation
- type RecommendationDistribution
- type Release
- type Repository
- type RepositoryData
- type VulnerabilityIndex
Constants ¶
View Source
const ( NC float64 = 0.875 NIA float64 = 0.625 W float64 = 0.375 DM float64 = 0.125 )
View Source
const ( SHA1 HashAlgorithm = "SHA-1" VCS ExternalReference = "vcs" )
View Source
const Separator string = " <---> "
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Artifact ¶
type Artifact struct {
Version string
Description string
ArtifactRepositories []string
Date time.Time
Vulnerabilities []string
Dependents []string
Dependencies []string
DeprecationWarning bool // TODO: Cant interpret false confidently
Contributors []string
Developers []string
Organization string
Licenses []string
MailingLists []string
}
type Commit ¶
type Commit struct {
Author string
Committer string
ChangedFiles []string
Message string
Timestamp time.Time
Additions int
Deletions int
Total int
}
func (Commit) GetTimestamp ¶
type Contributor ¶
type ContributorInfo ¶
type Core ¶
type Core struct {
Name CoreName
NoConcerns float64
NoImmediateAction float64
Watchlist float64
DecisionMaking float64
UnderlyingCores map[float64][]Core
}
func (*Core) GetAllCores ¶
func (*Core) HighestPossibleValue ¶
func (*Core) IntakeLimit ¶
func (*Core) IntakeThreshold ¶
func (*Core) IsInconclusive ¶
func (*Core) Normalized ¶
func (*Core) Recommend ¶
func (cr *Core) Recommend() RecommendationDistribution
func (*Core) ToStringDeep ¶
type CoreName ¶
type CoreName string
const ( CombCon CoreName = "Combination And Conclusion" Activity CoreName = "Activity" CoreTeam CoreName = "Core Team" Rivalry CoreName = "Rivalry" DeityGiven CoreName = "Deity-Given" Recentness CoreName = "Recentness" Backup CoreName = "Backup" Participation CoreName = "Participation" Prestige CoreName = "Prestige" Processing CoreName = "Processing" Effort CoreName = "Effort" Interconnectedness CoreName = "Interconnectedness" Network CoreName = "Network" Popularity CoreName = "Popularity" Vulnerabilities CoreName = "Vulnerabilities" Community CoreName = "Community" Support CoreName = "Support" Circumstances CoreName = "Circumstances" ProjectQuality CoreName = "ProjectQuality" Engagement CoreName = "Engagement" Licensing CoreName = "Licensing" Marking CoreName = "Marking" )
type DataModel ¶
type DataModel struct {
Repository *Repository
Distribution *Distribution
VulnerabilityIndex *VulnerabilityIndex
}
type Dependency ¶
type Dependency struct {
Name string
Version string
PackageURL string
Hashes map[HashAlgorithm]string
ExternalReferences map[ExternalReference]string
}
type Distribution ¶
type ExternalReference ¶
type ExternalReference string
type HashAlgorithm ¶
type HashAlgorithm string
type Issue ¶
type Issue struct {
Number int
Author string
AuthorAssociation string
State IssueState
Title string
Content string
ClosedBy string
Contributions []IssueContribution
Contributors []string
CreationTime time.Time
FirstResponse *time.Time
LastUpdate time.Time
ClosingTime time.Time
}
func (Issue) GetTimestamp ¶
type IssueContribution ¶
func (IssueContribution) GetTimestamp ¶
func (ic IssueContribution) GetTimestamp() time.Time
type Organization ¶
type Recommendation ¶
type Recommendation string
const ( NoConcerns Recommendation = "No Concerns" NoImmediateAction Recommendation = "No Immediate Action" Watchlist Recommendation = "Watchlist" DecisionMaking Recommendation = "Decision Making" Inconclusive Recommendation = "Inconclusive | No Recommendation Was Possible" )
func (Recommendation) ToAbbreviation ¶
func (r Recommendation) ToAbbreviation() string
type RecommendationDistribution ¶
type RecommendationDistribution map[Recommendation]float64
type Release ¶
func (Release) GetTimestamp ¶
type Repository ¶
type Repository struct {
Contributors []Contributor
Issues []Issue
Commits []Commit
Releases []Release
*RepositoryData
}
func (*Repository) TotalCommits ¶
func (r *Repository) TotalCommits() int
func (*Repository) TotalContributors ¶
func (r *Repository) TotalContributors() int
func (*Repository) TotalIssues ¶
func (r *Repository) TotalIssues() int
func (*Repository) TotalReleases ¶
func (r *Repository) TotalReleases() int
type RepositoryData ¶
type VulnerabilityIndex ¶
type VulnerabilityIndex struct {
TotalVulnerabilitiesCount int
}
Click to show internal directories.
Click to hide internal directories.