Chapter 1: Understanding the .NET Framework Architecture


New technologies force change, nowhere more so than in computers and software. Occasionally, a new technology is so innovative that it forces us to challenge our most fundamental assumptions. In the computing industry, the latest such technology is the Internet. It has forced us to rethink how software should be created, deployed, and used.

However, that process takes time. Usually, when a powerful new technology comes along, it is first simply strapped onto existing platforms. So it has been for the Internet. Before the advent of Microsoft .NET, developers used older platforms with new Internet capabilities “strapped on.” The resulting systems worked, but they were expensive and difficult to produce, hard to use, and difficult to maintain.

Realizing this several years ago, Microsoft decided it was time to design a new platform from the ground up specifically for the post-Internet world. The result is called .NET. It represents a turning point in the world of Windows software for Microsoft platforms. Microsoft has staked its future on .NET and has publicly stated that henceforth almost all its research and development will be done on this platform. It is expected that, eventually, almost all Microsoft products will be ported to the .NET platform.

Microsoft is now at version 3.0 of the Microsoft .NET Framework, and the development environment associated with this version is called Visual Studio 2005. The version of Visual Basic in this version is thus called Visual Basic 2005, and this book is about using Visual Basic 2005 with the .NET Framework 3.0.

What Is the .NET Framework?

The .NET Framework includes an execution platform in the form of a virtual machine. It also includes several programming languages that can produce programs for this virtual machine, and extensive class libraries, to provide rich built-in functionality for those languages.

This chapter looks at the .NET Framework from the viewpoint of a Visual Basic developer. Unless you are quite familiar with the framework already, you should consider this introduction an essential first step in assimilating the information about Visual Basic 2005 that is presented in the rest of this book.

Versions of the .NET Framework

The first released product based on the .NET Framework was Visual Studio .NET 2002, which was publicly launched in February 2002, and included version 1.0 of the .NET Framework. Visual Studio .NET 2003 was introduced a year later and included version 1.1 of the .NET Framework.

In late 2005, version 2.0 of the .NET Framework was introduced, and along with it a new version of Visual Studio was released. That version is named Visual Studio 2005. (Note that the “.NET” part of the name was dropped for this version.)

In early 2007, Microsoft’s new version of Windows, called Vista, was released to the public. At the same time, a new version of the .NET Framework was introduced, called .NET Framework 3.0. This version of the .NET Framework is built into Windows Vista, and is available to be installed on Windows XP and Windows Server 2003.

Earlier versions of the .NET Framework also worked on several versions of Windows before XP, but the .NET Framework 3.0 does not. It is only compatible with Windows XP, Windows 2003 Server, and Windows Vista.

No new version of Visual Studio was released with the .NET Framework 3.0. Visual Studio 2005 is compatible with this version of the framework.

This book assumes that you are using Visual Studio 2005 and .NET Framework 3.0. Some of the examples will work transparently with other versions of the .NET Framework and Visual Studio, but you should not count on this. Many examples in this edition emphasize features of .NET Framework 2.0 over 1.0/1.1, and of course many new examples require .NET Framework 3.0.

What’s New in .NET Framework 3.0?

Most of the classes in .NET Framework 2.0 are unchanged in 3.0. The differences for .NET Framework 3.0 are new libraries that offer completely new functionality. The new capabilities in .NET Framework 3.0 are almost entirely contained in three new technologies:

Windows Presentation Foundation (WPF) - A completely new UI technology, based on the DirectX engine, which allows creation of vector-based user interfaces instead of the traditional Windows bitmapped UI. WPF is the platform for the next generation of interactive user interfaces, with built-in capabilities for scaling, animation, media, styling, and three-dimensional visualization.

Windows Communication Foundation (WCF) - A unified framework for machine-to-machine and process-to-process communication. WCF brings together the capabilities of various messaging and communications technologies, including Web Services, enterprise services, remoting, and Microsoft Message Queue, into one integrated programming model. WCF is designed to be the principal Microsoft platform for systems with Service-Oriented Architecture (SOA).

Windows Workflow (WF) - An engine for creation of workflow applications. WF serves as the kernel of workflow, handling threading, persistence, and other plumbing tasks. WF brings a consistent, component-oriented philosophy to workflow, and is expected to be the core of a range of workflow solutions from Microsoft and various third parties.

Platform for a Post-Internet World

The .NET Framework began as a rich and complex platform, and as indicated earlier, it continues to include new and innovative capabilities. These new technologies fit well with the original philosophy of .NET, which is to serve as a platform for all kinds of software in an Internet-enabled world.

The vision of Microsoft .NET is globally distributed systems, using XML as the universal glue to enable functions running on different computers across an organization or across the world to come together in a single application. In this vision, systems from servers to wireless palmtops, with everything in between, will share the same general platform, with versions of .NET available for all of them, and with each of them able to integrate transparently with the others.

This does not leave out classic applications as you have always known them, though. The .NET Framework also makes traditional business applications much easier to develop and deploy. Some of the technologies of the .NET Framework, such as Windows Forms, demonstrate that Microsoft has not forgotten the traditional business developer. In fact, such developers will find it possible to Internet-enable their applications more easily than with any previous platform.

From the perspective of a Visual Basic developer, the .NET Framework enables Visual Basic to be used for anything from a simple utility program to a worldwide distributed n-tier system, and to create software on anything from huge servers to portable devices.

Overcoming the Limitations of COM

The pre-.NET technologies used for development on Microsoft platforms encompassed the COM (Component Object Model) standard for creation of components. COM had several major drawbacks. It wasn’t designed for an Internet-enabled world or for highly distributed systems. In addition, deployment of COM-based applications was quite expensive.

Pre-.NET versions of Visual Basic also had significant limitations, and many of them resulted from the limitations of COM, upon which VB6 was based. For example, VB6’s lack of full object orientation was due in part to the fact that COM itself was not object oriented. This meant that producing frameworks for complex systems in versions of Visual Basic through VB6 was not very practical.

Add to this a limited threading model and limited options for exposing Internet user interfaces, and Visual Basic needed a complete overhaul. That was done as part of the creation of the .NET Framework.




Professional VB 2005 with. NET 3. 0
Professional VB 2005 with .NET 3.0 (Programmer to Programmer)
ISBN: 0470124709
EAN: 2147483647
Year: 2004
Pages: 267

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net