File tree Expand file tree Collapse file tree 5 files changed +8
-9
lines changed Expand file tree Collapse file tree 5 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -166,7 +166,7 @@ internal class ScanController(
166166 /* *
167167 * Return all [KnownProvenance]s contained in [nestedProvenances].
168168 */
169- fun getAllProvenances (): Set <KnownProvenance > =
169+ fun getAllProvenances (): Set <RemoteProvenance > =
170170 nestedProvenances.values.flatMapTo(mutableSetOf ()) { it.allProvenances }
171171
172172 /* *
Original file line number Diff line number Diff line change @@ -570,12 +570,12 @@ class Scanner(
570570 }
571571
572572 private fun scanPath (
573- provenance : KnownProvenance ,
573+ provenance : RemoteProvenance ,
574574 scanners : List <PathScannerWrapper >,
575575 context : ScanContext
576576 ): Map <PathScannerWrapper , ScanResult > {
577577 val downloadDir = try {
578- provenanceDownloader.download(provenance as RemoteProvenance )
578+ provenanceDownloader.download(provenance)
579579 } catch (e: DownloadException ) {
580580 val issue = createAndLogIssue(
581581 " Downloader" , " Could not download provenance $provenance : ${e.collectMessages()} "
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ data class NestedProvenance(
3333 /* *
3434 * The root provenance that contains the [nested provenances][subRepositories].
3535 */
36- val root : KnownProvenance ,
36+ val root : RemoteProvenance ,
3737
3838 /* *
3939 * If [root] is a [RepositoryProvenance] this map contains all paths which contain nested repositories associated
@@ -46,7 +46,7 @@ data class NestedProvenance(
4646 * The set of all contained [KnownProvenance]s.
4747 */
4848 @JsonIgnore
49- val allProvenances: Set <KnownProvenance > =
49+ val allProvenances: Set <RemoteProvenance > =
5050 buildSet {
5151 add(root)
5252 addAll(subRepositories.values)
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ data class NestedProvenanceScanResult(
3939 /* *
4040 * A map of [KnownProvenance]s from [nestedProvenance] associated with lists of [ScanResult]s.
4141 */
42- val scanResults : Map <KnownProvenance , List <ScanResult >>
42+ val scanResults : Map <RemoteProvenance , List <ScanResult >>
4343) {
4444 /* *
4545 * Return true if [scanResults] contains at least one scan result for each of the [KnownProvenance]s contained in
@@ -108,7 +108,7 @@ data class NestedProvenanceScanResult(
108108 }
109109 }
110110
111- fun KnownProvenance .withVcsPath () =
111+ fun RemoteProvenance .withVcsPath () =
112112 when (this ) {
113113 is RepositoryProvenance -> {
114114 val pathWithinProvenance = pathsWithinProvenances.getValue(this )
Original file line number Diff line number Diff line change @@ -29,7 +29,6 @@ import org.ossreviewtoolkit.downloader.DownloadException
2929import org.ossreviewtoolkit.downloader.Downloader
3030import org.ossreviewtoolkit.downloader.WorkingTreeCache
3131import org.ossreviewtoolkit.model.ArtifactProvenance
32- import org.ossreviewtoolkit.model.KnownProvenance
3332import org.ossreviewtoolkit.model.Package
3433import org.ossreviewtoolkit.model.RemoteProvenance
3534import org.ossreviewtoolkit.model.RepositoryProvenance
@@ -62,7 +61,7 @@ fun interface ProvenanceDownloader {
6261 // Use the provenanceDownloader to download each provenance from nestedProvenance separately, because they are
6362 // likely already cached if a path scanner wrapper is used.
6463
65- val root = download(nestedProvenance.root as RemoteProvenance )
64+ val root = download(nestedProvenance.root)
6665
6766 nestedProvenance.subRepositories.forEach { (path, provenance) ->
6867 val tempDir = download(provenance)
You can’t perform that action at this time.
0 commit comments