星期二, 4月 13, 2010

.Net framework 4 來了

很難得會寫這個,這是今天剛好看到的What's New in the .NET Framework 4,所以就順便記了一下,這次微軟也加了不少東西到 .Net 4 裡。

下面就簡單的條列,詳細的內容還是要看原文章比較清楚。

以前用 1.1/2.0/3.0/3.5 編譯的程式,現在 .Net 4.0 不接受了,除非你有在 configuration file 裡指定 supportedRuntime 或者用 .net 4 重新編譯才行。

In-process side-by-side,可以在同一個 process 載入多個版本的 .Net CLR,這還蠻神奇的。

Diagnostics、效能、GC、DLR 跟 generic 的加強

Embed Interop,這個看起來是可以把原本 Interop assembly 的 type 資訊嵌到你專案裡,這樣 deploy 的時候就不需要拿那個 Interop Assembly 一起 deploy>

新的型別:BigInteger、Complex 跟 Tuple

File System 直接提供 enumerator ,不用自己刻了。

支援 Memory-mapped file 跟 64 bit

類別庫裡也多了不少更方便的類別或者是為原有的 method 提供了更方便的 overload...還有 MEF、Parallel Computing、Networking、Web(ASP.Net)、WCF、WWF、ADO.Net ...等等。

ASP.Net 的部份可以看這裡:ASP.NET 4 and Visual Studio 2010 Web Development Overview

沒有留言: