This repository was archived by the owner on Mar 31, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathPackageCompatibility.cs
More file actions
71 lines (53 loc) · 2.5 KB
/
PackageCompatibility.cs
File metadata and controls
71 lines (53 loc) · 2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System.ComponentModel.DataAnnotations;
namespace NuGet.Insights.Worker.PackageCompatibilityToCsv
{
[CsvRecord]
public partial record PackageCompatibility : PackageRecord, IAggregatedCsvRecord<PackageCompatibility>
{
public PackageCompatibility()
{
}
public PackageCompatibility(Guid scanId, DateTimeOffset scanTimestamp, PackageDeleteCatalogLeaf leaf) : base(scanId, scanTimestamp, leaf)
{
ResultType = PackageCompatibilityResultType.Deleted;
}
public PackageCompatibility(Guid scanId, DateTimeOffset scanTimestamp, PackageDetailsCatalogLeaf leaf) : base(scanId, scanTimestamp, leaf)
{
ResultType = PackageCompatibilityResultType.Available;
}
[Required]
public PackageCompatibilityResultType ResultType { get; set; }
public bool? HasError { get; set; }
public bool? DoesNotRoundTrip { get; set; }
public bool? HasAny { get; set; }
public bool? HasUnsupported { get; set; }
public bool? HasAgnostic { get; set; }
[KustoType("dynamic")]
public string BrokenFrameworks { get; set; }
[KustoType("dynamic")]
public string NuspecReader { get; set; }
[KustoType("dynamic")]
public string NU1202 { get; set; }
[KustoType("dynamic")]
public string NuGetGallery { get; set; }
[KustoType("dynamic")]
public string NuGetGalleryEscaped { get; set; }
[KustoType("dynamic")]
public string NuGetGallerySupported { get; set; }
[KustoType("dynamic")]
public string NuGetGalleryBadges { get; set; }
public static string CsvCompactMessageSchemaName => "cc.pco";
public static IEqualityComparer<PackageCompatibility> KeyComparer { get; } = PackageRecordIdentityComparer<PackageCompatibility>.Instance;
public static IReadOnlyList<string> KeyFields { get; } = PackageRecordExtensions.IdentityKeyField;
public static List<PackageCompatibility> Prune(List<PackageCompatibility> records, bool isFinalPrune, IOptions<NuGetInsightsWorkerSettings> options, ILogger logger)
{
return PackageRecordExtensions.Prune(records, isFinalPrune);
}
public int CompareTo(PackageCompatibility other)
{
return base.CompareTo(other);
}
}
}