.NET 平台与 .NETStandard [英] .NETPlatform vs .NETStandard

查看:36
本文介绍了.NET 平台与 .NETStandard的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近我对 .NET 中有关平台的术语感到非常困惑 - 在我们拥有 PCL 之前我曾经理解它.

I'm really confused about the terminology around the platforms in .NET these days - I used to understand it up until we had the PCLs.

我找到了以下文件:

对于初学者来说,第一个文档将带有绰号netstandard"的概念平台称为.NET Platform Standard".后者称之为.NET Standard"(同时引入了一个新的.NET Standard Library").

For starters, the first document refers to the conceptual platform with the moniker "netstandard" as ".NET Platform Standard". The latter calls it ".NET Standard" (at the same time it introduces a new ".NET Standard Library").

我真的不明白为什么第一个文档的顶部有一个免责声明,第二个文档描述了后继概念:似乎至少在第一个文档中显示版本关系的表格是新的.

I don't really get why the first document has a disclaimer at the top that the second describes the successor concept: It seems that at least the table showing the version releationships is newer in the first document.

那么.NET 平台标准"和.NET 标准库"的概念有什么区别?第二个文档中描述所谓的新概念的表格只显示了基本上是旧表格的内容,没有为这个新的.NET 标准库"添加新行——好像概念毕竟是一样的.免责声明真的只是建议重命名吗?

So what is the difference between the concepts ".NET Platform Standard" and ".NET Standard Library"? The table in the second document describing the allegedly new concept just show what is basically the old table, without a new row for this new ".NET Standard Library" - as if the concepts were the same after all. Is the disclaimer really just suggesting a renaming?

NuGet 增加了更多神秘感:

NuGet adds more mystery:

Json.NET NuGet 包有一个名为.NETStandard"的目标(显然 NuGet 使用第三个绰号来表示其中之一),我认为这应该与netstandard"相同,对吧?哪个实际上是.NET 平台标准",对吗?

The Json.NET NuGet package has a target called ".NETStandard" (apparantly NuGet uses a third moniker for one of those things) and I presume this is supposed to be the same thing as "netstandard", right? Which is actually the ".NET Platform Standard", correct?

Microsoft.AspNet.Mvc 包的 RC 有一个名为.NETPlatform 5.4"的目标.那是什么?它的名称不同,并且版本太高,与 .NET Platform Standard 或 .NET Standard Library 没有任何关系,无论两者之间的关系如何.嗯.

The RC of the Microsoft.AspNet.Mvc package has a target called ".NETPlatform 5.4". So what's that? It's called differently and has a version that's way too high to have anything to do with the .NET Platform Standard or the .NET Standard Library, whatever the relationship between the two might be. Hmmm.

有人知道这一切意味着什么吗?

Does anybody know what all of this really means?

我设法弄明白了一点:正如 Lex Li 所说,Microsoft.AspNet.Mvc 的 rc 版本已不复存在.它使用简短的绰号dotnet5.4",它确实在第一个文档中被引用为已弃用并被称为.NET 平台".该包的当前最新版本可能是名为Microsoft.AspNetCore.Mvc"的包,它仅指未失效的目标名称.

I managed to figure out a bit more: As Lex Li said, the rc version of Microsoft.AspNet.Mvc is defunct. It uses the short moniker "dotnet5.4", which is indeed referenced in the first document as deprecated and called ".NET Platform" in long. The current newest version of the package is presumably the one called "Microsoft.AspNetCore.Mvc", which refers only to non-defunct target names.

这样就解决了问题的 NuGet 部分,我目前的理论是.NET 标准库"只是以前称为.NET 平台标准"的重命名.这就留下了.NET 平台"这个词,我怀疑当版本计数没有对所有内容都重置为1"时,它是这些东西中任何一个的更古老的名称.

So that solves the NuGet part of the question and my theory at this point is that the ".NET Standard Library" is just a rename of what was previously called the ".NET Platform Standard". That leaves the term ".NET Platform", which I suspect is an even older name for either of these things back when the version count wasn't reset to "1" for everything.

也许了解这些事情的人可以确认或更正这一点.

Maybe someone with knowledge of these things can confirm or correct this.

推荐答案

你说得对,.NET Platform Standard 的概念已被 .NET Standard 取代(基本上重命名)..NET Standard 和 .NET Standard Library 本质上也是指同一个概念.

You're about right, the concept of .NET Platform Standard has been replaced (basically renamed) with .NET Standard. .NET Standard and .NET Standard Library are essentially referring to the same concept as well.

您在这里看到的 NuGet 绰号只是 .NET Standard 演变的遗迹.目前的绰号是:

The NuGet monikers you see here and there are just remains of the .NET Standard evolution. The current monikers are:

  • netstandard.x:指.NET Standard 的特定版本
  • netcoreapp1.x:指的是一个 .NET Core 应用程序.NET Core 的特定版本
  • netstandard.x: refers to a specific version to the .NET Standard
  • netcoreapp1.x: refers to a .NET Core application targeting on a specific version of .NET Core

查看新的 .NET Standard GitHub 存储库,尤其是 docs 以了解有关 .NET Standard 最新发展的更多信息.

Check out the new .NET Standard GitHub repository and especially the docs to find out more about the latest .NET Standard developments.

这篇关于.NET 平台与 .NETStandard的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆