analysis

package
v1.4.2 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

nolint

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IAnalysisRepository

type IAnalysisRepository interface {
	Create(analysis *horusec.Analysis, tx SQL.InterfaceWrite) error
	GetByID(analysisID uuid.UUID) (*horusec.Analysis, error)
	GetDetailsPaginated(companyID, repositoryID uuid.UUID, page, size int, initialDate,
		finalDate time.Time) (vulnDetails []dashboard.VulnDetails, err error)
	GetDetailsCount(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (count int, err error)
	GetDeveloperCount(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (count int, err error)
	GetRepositoryCount(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (count int, err error)
	GetVulnBySeverity(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (vulnBySeverity []dashboard.VulnBySeverity, err error)
	GetVulnByDeveloper(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (vulnByDeveloper []dashboard.VulnByDeveloper, err error)
	GetVulnByLanguage(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (vulnByLanguage []dashboard.VulnByLanguage, err error)
	GetVulnByRepository(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (vulnByRepository []dashboard.VulnByRepository, err error)
	GetVulnByTime(companyID, repositoryID uuid.UUID, initialDate,
		finalDate time.Time) (vulnByTime []dashboard.VulnByTime, err error)
}

func NewAnalysisRepository

func NewAnalysisRepository(databaseRead SQL.InterfaceRead, databaseWrite SQL.InterfaceWrite) IAnalysisRepository

type Mock

type Mock struct {
	mock.Mock
}

func (*Mock) Create

func (m *Mock) Create(analysis *horusec.Analysis, tx SQL.InterfaceWrite) error

func (*Mock) GetByID

func (m *Mock) GetByID(analysisID uuid.UUID) (*horusec.Analysis, error)

func (*Mock) GetDetailsCount

func (m *Mock) GetDetailsCount(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (count int, err error)

func (*Mock) GetDetailsPaginated

func (m *Mock) GetDetailsPaginated(companyID, repositoryID uuid.UUID, page, size int, initialDate,
	finalDate time.Time) (vulnDetails []dashboard.VulnDetails, err error)

func (*Mock) GetDeveloperCount

func (m *Mock) GetDeveloperCount(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (count int, err error)

func (*Mock) GetRepositoryCount

func (m *Mock) GetRepositoryCount(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (count int, err error)

func (*Mock) GetVulnByDeveloper

func (m *Mock) GetVulnByDeveloper(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByDeveloper []dashboard.VulnByDeveloper, err error)

func (*Mock) GetVulnByLanguage

func (m *Mock) GetVulnByLanguage(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByLanguage []dashboard.VulnByLanguage, err error)

func (*Mock) GetVulnByRepository

func (m *Mock) GetVulnByRepository(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByRepository []dashboard.VulnByRepository, err error)

func (*Mock) GetVulnBySeverity

func (m *Mock) GetVulnBySeverity(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnBySeverity []dashboard.VulnBySeverity, err error)

func (*Mock) GetVulnByTime

func (m *Mock) GetVulnByTime(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByTime []dashboard.VulnByTime, err error)

type Repository

type Repository struct {
	// contains filtered or unexported fields
}

func (*Repository) Create

func (ar *Repository) Create(analysis *horusec.Analysis, tx SQL.InterfaceWrite) error

func (*Repository) GetByID

func (ar *Repository) GetByID(analysisID uuid.UUID) (*horusec.Analysis, error)

func (*Repository) GetDetailsCount

func (ar *Repository) GetDetailsCount(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (count int, err error)

func (*Repository) GetDetailsPaginated

func (ar *Repository) GetDetailsPaginated(companyID, repositoryID uuid.UUID, page, size int, initialDate,
	finalDate time.Time) (vulnDetails []dashboard.VulnDetails, err error)

func (*Repository) GetDeveloperCount

func (ar *Repository) GetDeveloperCount(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (count int, err error)

func (*Repository) GetRepositoryCount

func (ar *Repository) GetRepositoryCount(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (count int, err error)

func (*Repository) GetVulnByDeveloper

func (ar *Repository) GetVulnByDeveloper(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByDeveloper []dashboard.VulnByDeveloper, err error)

func (*Repository) GetVulnByLanguage

func (ar *Repository) GetVulnByLanguage(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByLanguage []dashboard.VulnByLanguage, err error)

func (*Repository) GetVulnByRepository

func (ar *Repository) GetVulnByRepository(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByRepository []dashboard.VulnByRepository, err error)

func (*Repository) GetVulnBySeverity

func (ar *Repository) GetVulnBySeverity(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnBySeverity []dashboard.VulnBySeverity, err error)

func (*Repository) GetVulnByTime

func (ar *Repository) GetVulnByTime(companyID, repositoryID uuid.UUID, initialDate,
	finalDate time.Time) (vulnByTime []dashboard.VulnByTime, err error)

Jump to

Keyboard shortcuts

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