Peter said:
http://en.wikipedia.org/wiki/Windows_Communication_Foundation
.NET Framework 3.0 (formerly called WinFX) - the new .NET Windows API
to succeed Win32 with the release of Windows Vista.
The above quote is from the link above it. It seems to be saying that
the .NET Framework 3.0 will replace and supercede Win32. Does this
mean that the underlying Win32 functions have been rewritten for .NET
or is this new framework simply a wrapper around the pre-existing
Win32 API?
Marketing messaging to the contrary, the fact is that .NET 3.0 (aka WinFX)
is, like all the rest of the .NET platform, a wrapper over Win32. It's an
application framework that puts an easier to use, managed veneer over the
native Win32 APIs. It does not make use of any interfaces into the core OS
that aren't available to every Win32 program.
WPF (aka Avalon) applications are managed, but their user interface is
rendered by a new Win32 service process that's largely native code via
Direct-3D. While Direct-3D has a managed interface, internally it's all
native code.
WCF (aka Indigo) applications are managed, but WCF is nothing more than a
large, complex, sophisticated library that makes use of the existing
System.Net facilities, which in turn make use of the OS/Kernel-supplied
networking facilities (e.g. sockets, IO completion ports, etc).
WWF (workflow) is completely new and completely managed - this is one area
where WinFX isn't just a wrapper over Win32 - there's actually some entirely
new functionality here.
As for Vista, nearly 100% of the new features in Vista are native code.
There are extensive additions to the kernel, to User32 (and by extension,
the Win32 API). The new "Aero" UI is 100% native code, implemented by 100's
of new Win32 controls and styles.
One place where .NET 3.0 might be considered a "replacement" for Win32 is in
the focus of development tools - considerably more resources are involved in
driving developers towards writing managed code than are supporting
development of native code. The message is clear: for new projects, use
managed code. At some point, unmanaged code will "go away", but that point
is many years down the road still.
There's still a fundamental schism between Win32 and .NET: Win32 is the API
of an Operating System, while .NET is an application framework that's
largely OS agnostic (and could be implemented for nearly any modern
operating system).
HTH
-cd