This repository has been archived by the owner on Jul 30, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #698 from NuGet/dev
Merge branch 'dev' into master
- Loading branch information
Showing
48 changed files
with
736 additions
and
377 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// 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 Newtonsoft.Json; | ||
|
||
namespace NuGet.Protocol.Catalog | ||
{ | ||
/// <summary> | ||
/// Source: https://docs.microsoft.com/en-us/nuget/api/registration-base-url-resource#alternate-package | ||
/// </summary> | ||
public class AlternatePackage | ||
{ | ||
[JsonProperty("@id")] | ||
public string Url { get; set; } | ||
|
||
[JsonProperty("@type")] | ||
public string Type { get; set; } | ||
|
||
[JsonProperty("id")] | ||
public string Id { get; set; } | ||
|
||
[JsonProperty("range")] | ||
public string Range { get; set; } | ||
} | ||
} |
23 changes: 23 additions & 0 deletions
23
src/NuGet.Protocol.Catalog/Models/BasePackageDependencyGroup.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// 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.Collections.Generic; | ||
using Newtonsoft.Json; | ||
|
||
namespace NuGet.Protocol.Catalog | ||
{ | ||
public abstract class BasePackageDependencyGroup<TDependency> where TDependency : PackageDependency | ||
{ | ||
[JsonProperty("@id")] | ||
public string Url { get; set; } | ||
|
||
[JsonProperty("@type")] | ||
public string Type { get; set; } | ||
|
||
[JsonProperty("dependencies")] | ||
public List<TDependency> Dependencies { get; set; } | ||
|
||
[JsonProperty("targetFramework")] | ||
public string TargetFramework { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,9 @@ | ||
// 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.Collections.Generic; | ||
using Newtonsoft.Json; | ||
|
||
namespace NuGet.Protocol.Catalog | ||
{ | ||
public class PackageDependencyGroup | ||
public class PackageDependencyGroup : BasePackageDependencyGroup<PackageDependency> | ||
{ | ||
[JsonProperty("targetFramework")] | ||
public string TargetFramework { get; set; } | ||
|
||
[JsonProperty("dependencies")] | ||
public List<PackageDependency> Dependencies { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// 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.Collections.Generic; | ||
using Newtonsoft.Json; | ||
|
||
namespace NuGet.Protocol.Catalog | ||
{ | ||
/// <summary> | ||
/// Source: https://docs.microsoft.com/en-us/nuget/api/registration-base-url-resource#package-deprecation | ||
/// </summary> | ||
public class PackageDeprecation | ||
{ | ||
[JsonProperty("@id")] | ||
public string Url { get; set; } | ||
|
||
[JsonProperty("@type")] | ||
public string Type { get; set; } | ||
|
||
[JsonProperty("alternatePackage")] | ||
public AlternatePackage AlternatePackage { get; set; } | ||
|
||
[JsonProperty("message")] | ||
public string Message { get; set; } | ||
|
||
[JsonProperty("reasons")] | ||
public List<string> Reasons { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// 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; | ||
|
||
namespace NuGet.Protocol.Registration | ||
{ | ||
public interface ICommitted | ||
{ | ||
string CommitId { get; set; } | ||
DateTimeOffset CommitTimestamp { get; set; } | ||
} | ||
} |
Oops, something went wrong.