Class ScannerConfiguration
-
- All Implemented Interfaces:
public final class ScannerConfigurationThe configuration model of the scanner.
-
-
Field Summary
Fields Modifier and Type Field Description private final BooleanskipConcludedprivate final FileArchiverConfigurationarchiveprivate final BooleancreateMissingArchivesprivate final Map<String, String>detectedLicenseMappingprivate final FileListStorageConfigurationfileListStorageprivate final Map<String, PluginConfiguration>configprivate final Map<String, ScanStorageConfiguration>storagesprivate final List<String>storageReadersprivate final List<String>storageWritersprivate final List<String>ignorePatternsprivate final ProvenanceStorageConfigurationprovenanceStorage
-
Constructor Summary
Constructors Constructor Description ScannerConfiguration(Boolean skipConcluded, FileArchiverConfiguration archive, Boolean createMissingArchives, Map<String, String> detectedLicenseMapping, FileListStorageConfiguration fileListStorage, Map<String, PluginConfiguration> config, Map<String, ScanStorageConfiguration> storages, List<String> storageReaders, List<String> storageWriters, List<String> ignorePatterns, ProvenanceStorageConfiguration provenanceStorage)
-
Method Summary
Modifier and Type Method Description final BooleangetSkipConcluded()A flag to indicate whether packages that have a concluded license and authors set (to derive copyrights from) should be skipped in the scan in favor of only using the declared information. final FileArchiverConfigurationgetArchive()Configuration of a FileArchiver that archives certain scanned files in an external FileStorage. final BooleangetCreateMissingArchives()Create archives for packages that have a stored scan result but no license archive yet. final Map<String, String>getDetectedLicenseMapping()Mappings from licenses returned by the scanner to valid SPDX licenses. final FileListStorageConfigurationgetFileListStorage()The storage to store the file lists by provenance. final Map<String, PluginConfiguration>getConfig()Scanner specific configuration options. final Map<String, ScanStorageConfiguration>getStorages()A map with the configurations of the scan result storages available. final List<String>getStorageReaders()A list with the IDs of scan storages that are queried for existing scan results. final List<String>getStorageWriters()A list with the IDs of scan storages that are called to persist scan results. final List<String>getIgnorePatterns()A list of glob expressions that match file paths which are to be excluded from scan results. final ProvenanceStorageConfigurationgetProvenanceStorage()Configuration of the storage for provenance information. -
-
Constructor Detail
-
ScannerConfiguration
ScannerConfiguration(Boolean skipConcluded, FileArchiverConfiguration archive, Boolean createMissingArchives, Map<String, String> detectedLicenseMapping, FileListStorageConfiguration fileListStorage, Map<String, PluginConfiguration> config, Map<String, ScanStorageConfiguration> storages, List<String> storageReaders, List<String> storageWriters, List<String> ignorePatterns, ProvenanceStorageConfiguration provenanceStorage)
-
-
Method Detail
-
getSkipConcluded
final Boolean getSkipConcluded()
A flag to indicate whether packages that have a concluded license and authors set (to derive copyrights from) should be skipped in the scan in favor of only using the declared information.
-
getArchive
final FileArchiverConfiguration getArchive()
Configuration of a FileArchiver that archives certain scanned files in an external FileStorage.
-
getCreateMissingArchives
final Boolean getCreateMissingArchives()
Create archives for packages that have a stored scan result but no license archive yet.
-
getDetectedLicenseMapping
final Map<String, String> getDetectedLicenseMapping()
Mappings from licenses returned by the scanner to valid SPDX licenses. Note that these mappings are only applied in new scans, stored scan results are not affected.
-
getFileListStorage
final FileListStorageConfiguration getFileListStorage()
The storage to store the file lists by provenance.
-
getConfig
final Map<String, PluginConfiguration> getConfig()
Scanner specific configuration options. The key needs to match the name of the scanner class, e.g. "ScanCode" for the ScanCode wrapper. See the documentation of the scanner for available options.
-
getStorages
final Map<String, ScanStorageConfiguration> getStorages()
A map with the configurations of the scan result storages available. Based on this information the actual storages are created. Storages can be configured as readers or writers of scan results. Having this map makes it possible for storage instances to act in both roles without having to duplicate configuration.
-
getStorageReaders
final List<String> getStorageReaders()
A list with the IDs of scan storages that are queried for existing scan results. The strings in this list must match keys in the storages map.
-
getStorageWriters
final List<String> getStorageWriters()
A list with the IDs of scan storages that are called to persist scan results. The strings in this list must match keys in the storages map.
-
getIgnorePatterns
final List<String> getIgnorePatterns()
A list of glob expressions that match file paths which are to be excluded from scan results.
-
getProvenanceStorage
final ProvenanceStorageConfiguration getProvenanceStorage()
Configuration of the storage for provenance information.
-
-
-
-