简体   繁体   中英

Understanding the future of the .NET framework

I currently use Qt for my desktop app (simple apps) development. 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. On the other side I have been hearing about .NET going open source and cross platform.

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.

  1. Does this mean that we will be able to create cross platform application in Visual Studio?

  2. Does this means that Visual Studio will run on Linux and Mac?

Thanks a lot

In December I got an email from BizSpark about this very same announcement.

http://weblogs.asp.net/scottgu/announcing-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.

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.

Today I'm excited to announce that we are going even further, and will be open sourcing the .NET Core Runtime. 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.

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.

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/

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). 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.

  2. Not likely . Visual Studio is expected to remain a Windows-only application.

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.

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).

There are cross platform IDEs for .net though, like 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:

"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."

Does this means that we will be able to create cross platform application in 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.

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. 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. Also, you only have designer support in Visual Studio on Windows. But it does work.

There is also GTK# which is free (in both senses). This provides a significantly more native feel to apps, not 100% perfect but pretty good. 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.

Xwt is free, and looks promising and is actively developed. 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.

Eto.Forms is another free one that looks promising, and includes support for mobile development. 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?

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.

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. 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.

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. If you just want an IDE for developing on another platform you can use MonoDevelop but it is not so rich as visual studio

Breaking news: This just in from Scott Hunter, Director of .NET Program Management:

All future investment in .NET will be in .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.

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

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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