简体   繁体   English

了解 .NET 框架的未来

[英]Understanding the future of the .NET framework

I currently use Qt for my desktop app (simple apps) development.我目前使用 Qt 进行桌面应用程序(简单应用程序)开发。 The one thing I don't like about Qt is the fact that I have a feeling that the free license will eventually disappear and I would rather move to a different framework.我不喜欢 Qt 的一件事是我觉得免费许可证最终会消失,我宁愿转向不同的框架。 On the other side I have been hearing about .NET going open source and cross platform.另一方面,我听说 .NET 会开源和跨平台。

Can someone clarify what exactly does this means because I have read that only the server side will be open sourced and cross platform but I'm not sure if this will only affect Linux servers.有人可以澄清这到底意味着什么,因为我已经读到只有服务器端是开源和跨平台的,但我不确定这是否只会影响 Linux 服务器。

  1. Does this mean that we will be able to create cross platform application in Visual Studio?这是否意味着我们将能够在 Visual Studio 中创建跨平台应用程序?

  2. Does this means that Visual Studio will run on Linux and Mac?这是否意味着 Visual Studio 将在 Linux 和 Mac 上运行?

Thanks a lot非常感谢

In December I got an email from BizSpark about this very same announcement. 12 月,我收到了一封来自 BizSpark 的电子邮件,内容与此相同。

http://weblogs.asp.net/scottgu/announcing-open-source-of-net-core-framework-net-core-distribution-for-linux-osx-and-free-visual-studio-community-edition http://weblogs.asp.net/scottgu/annoucing-open-source-of-net-core-framework-net-core-distribution-for-linux-osx-and-free-visual-studio-community-edition

Basically, the idea is to open-source the ASP.NET runtimes to allow developers to build ASP.NET websites for all platforms.基本上,这个想法是开源ASP.NET运行时,允许开发人员为所有平台构建ASP.NET网站。

That said, there's no telling where Microsoft will take it.也就是说,没有人知道微软将把它带到哪里。 My personal opinion is that they will use this opportunity to port the ENTIRE .NET framework to Linux/OS X, but this is complete conjecture.我个人的意见是他们会利用这个机会将整个.NET框架移植到 Linux/OS X,但这完全是猜测。

Today I'm excited to announce that we are going even further, and will be open sourcing the .NET Core Runtime.今天,我很高兴地宣布,我们将走得更远,并将开源 .NET Core 运行时。 This will include everything needed to execute .NET code – including the CLR, Just-In-Time Compiler (JIT), Garbage Collector (GC), and core .NET base class libraries.这将包括执行 .NET 代码所需的一切——包括 CLR、即时编译器 (JIT)、垃圾收集器 (GC) 和核心 .NET 基类库。

And more importantly:更重要的是:

Today's open source announcement means that developers will have a fully supported, fully open source, fully cross platform .NET stack for creating server and cloud applications – including everything from the C#/VB compilers , to the CLR runtime , to the core .NET base class libraries , to the higher-level .NET Web, Data and API frameworks.今天的开源公告意味着开发人员将拥有一个完全支持、完全开源、完全跨平台的 .NET 堆栈,用于创建服务器和云应用程序——包括从C#/VB 编译器CLR 运行时,再到核心.NET 基础的所有内容类库,到更高级别的.NET Web、数据和 API框架。

You should visit the GitHub page for .NET and see what it has to offer, as this will likely be the first part of .NET to be cross-platformed: https://github.com/dotnet/您应该访问.NET的 GitHub 页面,看看它提供了什么,因为这可能是.NET跨平台的第一部分: https : //github.com/dotnet/

So, to answer your questions:所以,回答你的问题:

  1. To an extent .某种程度上 The entire .NET framework is NOT expected to be ported (largely System.Windows , and the other GUI libraries).整个.NET框架预计不会被移植(主要System.Windows ,另一GUI库)。 You will likely NOT be able to develop WPF or Windows Forms apps for Linux/OS X, but WILL be able to develop ASP.NET WebForms and MVC products for them.你可能能够开发WPFWindows Forms用于Linux / OS X的应用程序,但可以开发ASP.NET WebForms and MVC的产品他们。

  2. Not likely .不太可能 Visual Studio is expected to remain a Windows-only application. Visual Studio 预计仍将是一个仅限 Windows 的应用程序。

Edit: Yes, you could continue to use MONO or WINE for GUI based applications, and yes, large parts of the MONO and WINE implementations could be based around the new open-sourcing of the .NET framework, but if you are expecting Visual Studio to allow you to compile Linux/Unix/OS X native applications, you will likely not find that in the new announcements.编辑:是的,您可以继续将MONOWINE用于基于GUI的应用程序,是的,大部分MONOWINE实现都可以基于.NET框架的新开源,但如果您期待Visual Studio允许您编译 Linux/Unix/OS X 本机应用程序,您可能不会在新公告中找到。

The .net framework is cross platform (similar to java's JVM, it's all managed code), allowing you to develop apps that will run on linux/mac/ios/android, but I don't know if you'll ever be able to run visual studio on anything other than windows (could install windows on your mac machine and switch to it). .net框架是跨平台的(类似于java的JVM,都是托管代码),允许你开发可以在linux/mac/ios/android上运行的应用程序,但我不知道你是否能够在 windows 以外的任何东西上运行visual studio(可以在你的mac机器上安装windows并切换到它)。

There are cross platform IDEs for .net though, like Mono. .net 有跨平台的 IDE,比如 Mono。 If you search for them you'll find a few options.如果您搜索它们,您会发现一些选项。

This was just posted today 5/1 (VisualStudioMagazine) and I thought I would add this when I remembered your post:这是今天 5/1 (VisualStudioMagazine) 刚刚发布的,当我想起你的帖子时,我想我会添加这个:

"You probably never thought you would see the day when Visual Studio would run natively on a Mac. Well the newest member to the Visual Studio family, Visual Studio Code, does just that. Visual Studio Code is a lightweight code editor that has versions that will run on Windows, Mac, and Linux. But don't let the fact that it is lightweight fool you. It is packed with a ton of features like full Intellisense, color coding, and more. Even better, it's free." “您可能从未想过自己会看到 Visual Studio 在 Mac 上本地运行的那一天。好吧,Visual Studio 系列的最新成员 Visual Studio Code 就是这样做的。Visual Studio Code 是一个轻量级代码编辑器,其版本可以”

Does this means that we will be able to create cross platform application in Visual Studio?这是否意味着我们将能够在 Visual Studio 中创建跨平台应用程序?

Yes.是的。 There are a variety of third party user interface frameworks that can be used to develop open source applications.有多种第三方用户界面框架可用于开发开源应用程序。 None of them are officially supported by Microsoft as far as I know, aside from Silverlight which is deprecated.据我所知,除了不推荐使用的 Silverlight 之外,它们都没有得到微软的正式支持。

WinForms does work under Mono and can be used to deliver applications which work in Linux and Mac but last I tried, it was a bit buggy. WinForms确实在 Mono 下工作,可用于交付在 Linux 和 Mac 上工作的应用程序,但上次我尝试过,它有点问题。 It's probably better now but if you use it you will want to test early and test often on multiple platforms.现在可能会更好,但如果您使用它,您将希望尽早测试并经常在多个平台上进行测试。 The desktop experience also feels rather foreign, especially on Mac.桌面体验也感觉很陌生,尤其是在 Mac 上。 Also, you only have designer support in Visual Studio on Windows.此外,您仅在 Windows 上的 Visual Studio 中获得设计器支持。 But it does work.但它确实有效。

There is also GTK# which is free (in both senses).还有免费的GTK# (在两种意义上)。 This provides a significantly more native feel to apps, not 100% perfect but pretty good.这为应用程序提供了明显更原生的感觉,不是 100% 完美,但相当不错。 There is designer support in MonoDevelop for it and there are external tools which you can use to design user interfaces that you can then load in your application. MonoDevelop 中为它提供了设计器支持,并且有一些外部工具可用于设计用户界面,然后您可以将其加载到您的应用程序中。

Xwt is free, and looks promising and is actively developed. Xwt是免费的,看起来很有前途,并且正在积极开发中。 I haven't looked at it in a while.我有一段时间没看它了。 This one is apparently used by Xamarin Studio and MonoDevelop, so it is probably fairly robust. Xamarin Studio 和 MonoDevelop 显然使用了这个,因此它可能相当健壮。

Eto.Forms is another free one that looks promising, and includes support for mobile development. Eto.Forms是另一种看起来很有前途的免费软件,它包括对移动开发的支持。 I haven't looked at it much at all and it doesn't look like it's been actively developed lately.我根本没有看过它,而且看起来它最近没有被积极开发。

Does this means that Visual Studio will run on Linux and Mac?这是否意味着 Visual Studio 将在 Linux 和 Mac 上运行?

No. This seems extremely unlikely.不,这似乎极不可能。 Wine seems to have made some progress on some older versions of Visual Studio but you will not likely be able to use any recent version of Visual Studio. Wine 似乎在某些较旧版本的 Visual Studio 上取得了一些进展,但您可能无法使用任何最新版本的 Visual Studio。

With Mono you can create cross-platform applications, and even GUI with WinForms or Gtk# , you can develop them and compile in Visual Studio under .net (we know that mono is just a reimplementation of .net) but in Linux you will have to run them under mono.使用Mono,您可以创建跨平台应用程序,甚至可以使用WinFormsGtk#创建 GUI,您可以开发它们并在 .net 下的Visual Studio 中编译(我们知道 Mono 只是 .net 的重新实现),但在Linux 中,您将拥有在单声道下运行它们。 I think Mono has a good future now that Microsoft has made their new compiler open-source so it will simplify development of mono-project.我认为 Mono 有一个很好的未来,因为微软已经将他们的新编译器开源,因此它将简化 mono 项目的开发。

I don't think that visual studio will be available in Linux or Mac because it would be a huge work to port them on those platforms.我认为 Visual Studio 不会在LinuxMac上可用,因为将它们移植到这些平台上将是一项巨大的工作。 If you just want an IDE for developing on another platform you can use MonoDevelop but it is not so rich as visual studio如果你只是想要一个在另一个平台上开发的IDE ,你可以使用MonoDevelop,但它不像 Visual Studio 那样丰富

Breaking news: This just in from Scott Hunter, Director of .NET Program Management:突发新闻:这是来自 .NET 程序管理总监 Scott Hunter:

All future investment in .NET will be in .NET Core.未来对 .NET 的所有投资都将用于 .NET Core。 This includes: Runtime, JIT, AOT, GC, BCL (Base Class Library), C#, VB.NET, F#, ASP.NET, Entity Framework, ML.NET, WinForms, WPF and Xamarin.这包括:运行时、JIT、AOT、GC、BCL(基类库)、C#、VB.NET、F#、ASP.NET、实体框架、ML.NET、WinForms、WPF 和 Xamarin。

https://devblogs.microsoft.com/dotnet/net-core-is-the-future-of-net/ https://devblogs.microsoft.com/dotnet/net-core-is-the-future-of-net/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM