< Summary

Information
Class: Spdx3.Model.ExpandedLicensing.Classes.OrLaterOperator
Assembly: Spdx3
File(s): /home/runner/work/Spdx3/Spdx3/Spdx3/Model/ExpandedLicensing/Classes/OrLaterOperator.cs
Line coverage
100%
Covered lines: 10
Uncovered lines: 0
Coverable lines: 10
Total lines: 35
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_SubjectLicense()100%11100%
.ctor()100%11100%
.ctor(...)100%11100%
Validate()100%11100%

File(s)

/home/runner/work/Spdx3/Spdx3/Spdx3/Model/ExpandedLicensing/Classes/OrLaterOperator.cs

#LineLine coverage
 1using System.Diagnostics.CodeAnalysis;
 2using System.Text.Json.Serialization;
 3using Spdx3.Model.Core.Classes;
 4using Spdx3.Serialization;
 5using Spdx3.Utility;
 6
 7namespace Spdx3.Model.ExpandedLicensing.Classes;
 8
 9/// <summary>
 10/// Portion of an AnyLicenseInfo representing this version, or any later version, of the indicated License.
 11/// See https://spdx.github.io/spdx-spec/v3.0.1/model/ExpandedLicensing/Classes/OrLaterOperator/
 12/// </summary>
 13public class OrLaterOperator : ExtendableLicense
 14{
 15    [JsonPropertyName("expandedlicensing_subjectLicense")]
 16    [JsonConverter(typeof(SpdxModelConverterFactory))]
 917    public required License SubjectLicense { get; set; }
 18
 119    protected internal OrLaterOperator()
 20    {
 121    }
 22
 23    [SetsRequiredMembers]
 224    public OrLaterOperator(Catalog catalog, CreationInfo creationInfo, License subjectLicense) : base(catalog,
 225        creationInfo)
 26    {
 227        SubjectLicense = subjectLicense;
 228    }
 29
 30    public override void Validate()
 31    {
 232        base.Validate();
 233        ValidateRequiredProperty(nameof(SubjectLicense));
 234    }
 35}