Skip to content

Commit 802bfa2

Browse files
committed
chore: Do not name the value parameter for @Json... annotations
Generally omit this first paramater name for shortness and consistency. Signed-off-by: Sebastian Schuberth <[email protected]>
1 parent c51acbd commit 802bfa2

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

model/src/main/kotlin/DependencyGraph.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,7 @@ class DependencyReference(
315315
* package managers / languages only support dynamic linking or at least default to it, also use that as the
316316
* default value here to not blow up ORT result files.
317317
*/
318-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = PackageLinkageValueFilter::class)
318+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = PackageLinkageValueFilter::class)
319319
val linkage: PackageLinkage = PackageLinkage.DYNAMIC,
320320

321321
/**
@@ -360,7 +360,7 @@ data class DependencyGraphNode(
360360
* package managers / languages only support dynamic linking or at least default to it, also use that as the
361361
* default value here to not blow up ORT result files.
362362
*/
363-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = PackageLinkageValueFilter::class)
363+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = PackageLinkageValueFilter::class)
364364
val linkage: PackageLinkage = PackageLinkage.DYNAMIC,
365365

366366
/**

model/src/main/kotlin/PackageReference.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ data class PackageReference(
4545
* package managers / languages only support dynamic linking or at least default to it, also use that as the
4646
* default value here to not blow up ORT result files.
4747
*/
48-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = PackageLinkageValueFilter::class)
48+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = PackageLinkageValueFilter::class)
4949
override val linkage: PackageLinkage = PackageLinkage.DYNAMIC,
5050

5151
/**

model/src/main/kotlin/config/RepositoryConfiguration.kt

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,50 +36,50 @@ data class RepositoryConfiguration(
3636
/**
3737
* The configuration for the analyzer. Values in this configuration take precedence over global configuration.
3838
*/
39-
@JsonInclude(value = JsonInclude.Include.NON_NULL)
39+
@JsonInclude(JsonInclude.Include.NON_NULL)
4040
val analyzer: RepositoryAnalyzerConfiguration? = null,
4141

4242
/**
4343
* Defines which parts of the repository will be excluded. Note that excluded parts will still be analyzed and
4444
* scanned, but related errors will be marked as resolved in the reporter output.
4545
*/
46-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = ExcludesFilter::class)
46+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = ExcludesFilter::class)
4747
val excludes: Excludes = Excludes(),
4848

4949
/**
5050
* Defines which parts of the repository will be included.
5151
*/
52-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = IncludesFilter::class)
52+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = IncludesFilter::class)
5353
val includes: Includes = Includes.EMPTY,
5454

5555
/**
5656
* Defines resolutions for issues with this repository.
5757
*/
58-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = ResolutionsFilter::class)
58+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = ResolutionsFilter::class)
5959
val resolutions: Resolutions = Resolutions(),
6060

6161
/**
6262
* Defines curations for packages used as dependencies by projects in this repository, or curations for license
6363
* findings in the source code of a project in this repository.
6464
*/
65-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = CurationsFilter::class)
65+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = CurationsFilter::class)
6666
val curations: Curations = Curations(),
6767

6868
/**
6969
* Defines configurations for packages used as dependencies by projects in this repository.
7070
*/
71-
@JsonInclude(value = JsonInclude.Include.NON_EMPTY)
71+
@JsonInclude(JsonInclude.Include.NON_EMPTY)
7272
val packageConfigurations: List<PackageConfiguration> = emptyList(),
7373

7474
/**
7575
* Defines license choices within this repository.
7676
*/
77-
@JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = LicenseChoicesFilter::class)
77+
@JsonInclude(JsonInclude.Include.CUSTOM, valueFilter = LicenseChoicesFilter::class)
7878
val licenseChoices: LicenseChoices = LicenseChoices(),
7979

8080
/**
8181
* Defines snippet choices for projects in this repository.
8282
*/
83-
@JsonInclude(value = JsonInclude.Include.NON_EMPTY)
83+
@JsonInclude(JsonInclude.Include.NON_EMPTY)
8484
val snippetChoices: List<SnippetChoices> = emptyList()
8585
)

model/src/main/kotlin/vulnerabilities/VulnerabilityReference.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ import java.net.URI
3232
* with a list of references; each reference points to the source of the information and has some detailed information
3333
* provided by this source.
3434
*/
35-
@JsonIgnoreProperties(value = ["severity_rating"])
35+
@JsonIgnoreProperties("severity_rating")
3636
data class VulnerabilityReference(
3737
/**
3838
* The URI pointing to details of the belonging vulnerability.

0 commit comments

Comments
 (0)