Documentation
¶
Index ¶
- Constants
- Variables
- type ComponentRepository
- type FileRepository
- type FileRepositoryImpl
- type InMemoryComponentRepository
- type JSONComponentRepository
- type LicenseRepository
- type LicenseRepositoryJsonImpl
- type ResultRepository
- type ResultRepositoryInMemoryImpl
- type ResultRepositoryJsonImpl
- type ScanossSettingsJsonRepository
- func (r *ScanossSettingsJsonRepository) AddBomEntry(newEntry entities.ComponentFilter, filterAction string) error
- func (r *ScanossSettingsJsonRepository) AddStagedScanningSkipPattern(pattern string) error
- func (r *ScanossSettingsJsonRepository) ClearAllFilters() error
- func (r *ScanossSettingsJsonRepository) CommitStagedScanningSkipPatterns() error
- func (r *ScanossSettingsJsonRepository) DiscardStagedScanningSkipPatterns() error
- func (r *ScanossSettingsJsonRepository) GetDeclaredPurls() []string
- func (r *ScanossSettingsJsonRepository) GetDefaultSkipPatterns(sf *entities.SettingsFile) []string
- func (r *ScanossSettingsJsonRepository) GetEffectiveScanningSkipPatterns() []string
- func (r *ScanossSettingsJsonRepository) GetSettings() *entities.SettingsFile
- func (r *ScanossSettingsJsonRepository) HasStagedScanningSkipPatternChanges() bool
- func (r *ScanossSettingsJsonRepository) HasUnsavedChanges() (bool, error)
- func (r *ScanossSettingsJsonRepository) Init() error
- func (r *ScanossSettingsJsonRepository) MatchesEffectiveScanningSkipPattern(path string) bool
- func (r *ScanossSettingsJsonRepository) Read() (entities.SettingsFile, error)
- func (r *ScanossSettingsJsonRepository) RemoveBomEntry(entry entities.ComponentFilter) error
- func (r *ScanossSettingsJsonRepository) RemoveStagedScanningSkipPattern(path string, pattern string) error
- func (r *ScanossSettingsJsonRepository) Save() error
- type ScanossSettingsRepository
Constants ¶
View Source
const LICENSES_FILE_PATH = "backend/data/spdx-licenses.json"
Variables ¶
Functions ¶
This section is empty.
Types ¶
type ComponentRepository ¶
type FileRepository ¶
type FileRepository interface {
ReadLocalFile(filePath string) (entities.File, error)
ReadRemoteFileByMD5(path string, md5 string) (entities.File, error)
GetComponentByFilePath(filePath string) (entities.Component, error)
}
func NewFileRepositoryImpl ¶
func NewFileRepositoryImpl() FileRepository
type FileRepositoryImpl ¶
type FileRepositoryImpl struct{}
func (*FileRepositoryImpl) GetComponentByFilePath ¶
func (r *FileRepositoryImpl) GetComponentByFilePath(filePath string) (entities.Component, error)
func (*FileRepositoryImpl) ReadLocalFile ¶
func (r *FileRepositoryImpl) ReadLocalFile(path string) (entities.File, error)
func (*FileRepositoryImpl) ReadRemoteFileByMD5 ¶
type InMemoryComponentRepository ¶
type InMemoryComponentRepository struct {
}
func NewInMemoryComponentRepository ¶
func NewInMemoryComponentRepository() *InMemoryComponentRepository
func (*InMemoryComponentRepository) FindByFilePath ¶
func (r *InMemoryComponentRepository) FindByFilePath(path string) (entities.Component, error)
type JSONComponentRepository ¶
type JSONComponentRepository struct {
// contains filtered or unexported fields
}
func NewJSONComponentRepository ¶
func NewJSONComponentRepository(fr utils.FileReader, resultsRepository ResultRepository) *JSONComponentRepository
func (*JSONComponentRepository) FindByFilePath ¶
func (r *JSONComponentRepository) FindByFilePath(path string) (entities.Component, error)
type LicenseRepository ¶
func NewLicenseJsonRepository ¶
func NewLicenseJsonRepository(fr utils.FileReader) LicenseRepository
type LicenseRepositoryJsonImpl ¶
type LicenseRepositoryJsonImpl struct {
// contains filtered or unexported fields
}
type ResultRepository ¶
type ResultRepositoryInMemoryImpl ¶
type ResultRepositoryInMemoryImpl struct {
}
func NewResultRepositoryInMemoryImpl ¶
func NewResultRepositoryInMemoryImpl() *ResultRepositoryInMemoryImpl
func (*ResultRepositoryInMemoryImpl) GetResults ¶
func (r *ResultRepositoryInMemoryImpl) GetResults(filter entities.ResultFilter) ([]entities.Result, error)
type ResultRepositoryJsonImpl ¶
type ResultRepositoryJsonImpl struct {
// contains filtered or unexported fields
}
func NewResultRepositoryJsonImpl ¶
func NewResultRepositoryJsonImpl(fr utils.FileReader) (*ResultRepositoryJsonImpl, error)
func (*ResultRepositoryJsonImpl) GetResultByPath ¶ added in v0.6.1
func (r *ResultRepositoryJsonImpl) GetResultByPath(path string) *entities.Result
func (*ResultRepositoryJsonImpl) GetResults ¶
func (r *ResultRepositoryJsonImpl) GetResults(filter entities.ResultFilter) ([]entities.Result, error)
type ScanossSettingsJsonRepository ¶
type ScanossSettingsJsonRepository struct {
// contains filtered or unexported fields
}
func (*ScanossSettingsJsonRepository) AddBomEntry ¶
func (r *ScanossSettingsJsonRepository) AddBomEntry(newEntry entities.ComponentFilter, filterAction string) error
func (*ScanossSettingsJsonRepository) AddStagedScanningSkipPattern ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) AddStagedScanningSkipPattern(pattern string) error
func (*ScanossSettingsJsonRepository) ClearAllFilters ¶
func (r *ScanossSettingsJsonRepository) ClearAllFilters() error
func (*ScanossSettingsJsonRepository) CommitStagedScanningSkipPatterns ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) CommitStagedScanningSkipPatterns() error
func (*ScanossSettingsJsonRepository) DiscardStagedScanningSkipPatterns ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) DiscardStagedScanningSkipPatterns() error
func (*ScanossSettingsJsonRepository) GetDeclaredPurls ¶
func (r *ScanossSettingsJsonRepository) GetDeclaredPurls() []string
func (*ScanossSettingsJsonRepository) GetDefaultSkipPatterns ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) GetDefaultSkipPatterns(sf *entities.SettingsFile) []string
func (*ScanossSettingsJsonRepository) GetEffectiveScanningSkipPatterns ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) GetEffectiveScanningSkipPatterns() []string
func (*ScanossSettingsJsonRepository) GetSettings ¶
func (r *ScanossSettingsJsonRepository) GetSettings() *entities.SettingsFile
func (*ScanossSettingsJsonRepository) HasStagedScanningSkipPatternChanges ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) HasStagedScanningSkipPatternChanges() bool
func (*ScanossSettingsJsonRepository) HasUnsavedChanges ¶
func (r *ScanossSettingsJsonRepository) HasUnsavedChanges() (bool, error)
func (*ScanossSettingsJsonRepository) Init ¶
func (r *ScanossSettingsJsonRepository) Init() error
func (*ScanossSettingsJsonRepository) MatchesEffectiveScanningSkipPattern ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) MatchesEffectiveScanningSkipPattern(path string) bool
func (*ScanossSettingsJsonRepository) Read ¶
func (r *ScanossSettingsJsonRepository) Read() (entities.SettingsFile, error)
func (*ScanossSettingsJsonRepository) RemoveBomEntry ¶ added in v0.12.0
func (r *ScanossSettingsJsonRepository) RemoveBomEntry(entry entities.ComponentFilter) error
func (*ScanossSettingsJsonRepository) RemoveStagedScanningSkipPattern ¶ added in v0.6.5
func (r *ScanossSettingsJsonRepository) RemoveStagedScanningSkipPattern(path string, pattern string) error
func (*ScanossSettingsJsonRepository) Save ¶
func (r *ScanossSettingsJsonRepository) Save() error
type ScanossSettingsRepository ¶
type ScanossSettingsRepository interface {
Init() error
Save() error
Read() (entities.SettingsFile, error)
HasUnsavedChanges() (bool, error)
AddBomEntry(newEntry entities.ComponentFilter, filterAction string) error
RemoveBomEntry(entry entities.ComponentFilter) error
ClearAllFilters() error
GetSettings() *entities.SettingsFile
GetDeclaredPurls() []string
AddStagedScanningSkipPattern(pattern string) error
RemoveStagedScanningSkipPattern(path string, pattern string) error
CommitStagedScanningSkipPatterns() error
DiscardStagedScanningSkipPatterns() error
GetEffectiveScanningSkipPatterns() []string
MatchesEffectiveScanningSkipPattern(path string) bool
HasStagedScanningSkipPatternChanges() bool
}
func NewScanossSettingsJsonRepository ¶
func NewScanossSettingsJsonRepository(fr utils.FileReader) ScanossSettingsRepository
Source Files
¶
- component_repository.go
- component_repository_in_memory_impl.go
- component_repository_json_impl.go
- file_repository.go
- file_repository_impl.go
- license_repository.go
- license_repository_json_impl.go
- result_repository.go
- result_repository_in_memory_impl.go
- result_repository_json_impl.go
- scanoss_settings_repository.go
- scanoss_settings_repository_json_impl.go
Click to show internal directories.
Click to hide internal directories.