storage

package
v2.1.3 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MemoryStorage

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

MemoryStorage is scans' results representation

func NewMemoryStorage

func NewMemoryStorage() *MemoryStorage

NewMemoryStorage creates a new MemoryStorage empty and returns it

func (*MemoryStorage) GetFiles

GetFiles returns a collection of files saved on MemoryStorage

func (*MemoryStorage) GetScanSummary

func (m *MemoryStorage) GetScanSummary(_ context.Context, _ []string) ([]model.SeveritySummary, error)

GetScanSummary is not supported by MemoryStorage

func (*MemoryStorage) GetVulnerabilities

func (m *MemoryStorage) GetVulnerabilities(_ context.Context, _ string) ([]model.Vulnerability, error)

GetVulnerabilities returns a collection of vulnerabilities saved on MemoryStorage

func (*MemoryStorage) SaveFile

func (m *MemoryStorage) SaveFile(_ context.Context, metadata *model.FileMetadata) error

SaveFile adds a new file metadata to files collection

func (*MemoryStorage) SaveVulnerabilities

func (m *MemoryStorage) SaveVulnerabilities(_ context.Context, vulnerabilities []model.Vulnerability) error

SaveVulnerabilities adds a list of vulnerabilities to vulnerabilities collection

Jump to

Keyboard shortcuts

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