如果有的话,您何时会期望标记为过时的类从 .NET 框架中删除?

发布于 2024-08-08 21:21:03 字数 496 浏览 2 评论 0原文

当我们接近 .NET 框架的第四个主要版本时,我们可能会看到标记为过时(以表明它们已被弃用)的类和方法的数量增加。我发现此页面列出了所有过时成员类型,现在变得相当大。

所以,我想知道是否:

  1. 是否有任何标记为过时的成员或类型实际上已从框架的任何版本中删除?是否有来自 .NET 1 的元素根本不在更高版本中?

  2. 对于何时删除元素,Microsoft 是否遵循任何正式准则?这是在 X 次发布之后吗?经过时间?或者是否已弃用的元素可能会永久保留?

As we approach the 4th major release of the .NET framework we are likely to see an increase in the number of classes and methods marked as obsolete (to indicate they are deprecated). I found this page listing all the obsolete members and types, which is growing quite large now.

So, I was wondering whether:

  1. Have any members or types marked as obsolete have been actually removed from any version of the framework? Are there elements from, say, .NET 1 that are not in later versions at all?

  2. Are there any formal guidelines Microsoft follow as to when elements will be removed? Is this after X number of releases? Elapsed time? Or is it likely deprecated elements will remain in perpetuity?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

反目相谮 2024-08-15 21:21:03

从框架中删除过时的类的问题在于,它会成为针对框架构建的应用程序的重大更改,而应用 ObsoleteAttribute 则不然。

因此,我预计在不久的将来(如果有的话)不会看到任何标记为过时的类被删除。

The problem with removing an obsolete class from the Framework is that it becomes a breaking change to applications built against the Framework, whereas applying ObsoleteAttribute is not.

Consequently, I don't expect to see any of those classes marked obsolete removed any time in the near future, if ever.

水溶 2024-08-15 21:21:03

最合理的方法是永远将它们留在那里,以保持向后兼容性。

The most reasonable way would be to leave them there forever in order to keep backward compatibility.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文