|
Chapter 3: The .NET Base Class Libraries.
|
XML Articles & Tutorials, Sample Code, Sample Chapters, Books :: A sample chapter from 'Professional Visual Basic 6 XML'. TX Text Control is a royalty-free ActiveX and C++ Class Library that offers an extensive http://www.developerfusion.co.uk/xml/HOME | In This Chapter
Libraries Shared Across Languages
When you write managed C++, you have access to all of the managed code libraries that come with the .NET Framework: the Base Class Libraries, ADO.NET, ASP.NET, and so on. These libraries are modern and powerful. They provide services, such as XML processing, that weren't even thought of when older libraries such as MFC and ATL were first written. Foundation ASP.NET for Flash:: File Format: PDF/Adobe Acrobatyou have stored in these libraries.” As I mentioned in Chapter 1, one major part of the .NET. Framework is the base class library. This is a HUGE library of http://www.friendsofed.com/samples/1590595173.pdfHOME | Programmingtutorials.com - Free Online Programming Tutorials:: NET framework base classes, Visual Studio .NET, and the .NET languages. NET framework class library, the CLR, and .NET framework application design. http://www.programmingtutorials.com/dotnet.aspxHOME |
In sharp contrast to the historical capabilities of C++ and Visual Basic, on the .NET Framework these two languages share the same class libraries. Every library class and method that's available from Visual Basic is available from managed C++ and from C#. Every library class and method that's available from C# is available from Visual Basic and Managed C++.
The advantages of a shared class library are many. They include System.IO.SerialPort sample in V C++ Express,.NET Base Class :: SerialPort sample in V C++ Express document under .NET Base Class Library classified msdner >> .NET Development >> .NET Base Class Library http://www.codeprof.com/dev-archive/183/12-39-1835851.shtmHOME | Sample : Chapter 9 of Database Programming with JDBC and Java :: The core of a solid persistence library contains no code specific to any data . The Transaction base class that makes these calls leaves the commit( http://www.javacoffeebreak.com/books/samples/jdbc/chapter9.htmlHOME |
Reduced learning time when moving from one .NET-supported language to another
A larger body of samples and documentation, because these do not need to be language specific
Better communication between programmers who work in different .NET-supported languages
The C++ Advantage - C++ can use the same class libraries as C# and VB.NET. Does it work the other way around? No. There are libraries of unmanaged code available from managed C++ that cannot be called from Visual Basic or C#ATL and MFC are just two examples. However, it's unlikely that a Visual Basic or C# programmer would want to use those libraries, because their functionality is provided elsewhere; the capability to call them from managed C++ helps simplify a port from unmanaged to managed C++.
Working in Multiple Languages - I have a small consulting firm, and often our clients specify the programming language we are to use for a project. When several projects are on the go at once, I might switch languages several times in the course of a single day, as I help my associates with problems or track down the last few bugs in systems that are almost finished.
Before I starting using the .NET Framework, about once a month I'd suffer a "brain freeze" and for a moment or two forget how to perform some really simple task, like determining whether a string contains a particular character, in the language of the moment. Usually at those times my fingers would start typing the method or operator in randomly chosen other languages or libraries: Perl, Visual Basic, MFC, STL, Javaanything except the one I wanted. Now, with a common set of libraries across languages, I don't have to "context switch" nearly as oftenand I avoid those "deer in the headlights" moments.
In the past, just because you knew how to perform a specific task, such as writing some text to a file in Visual C++, didn't mean you knew how to do that same task in Visual Basic. A great tutorial you found on database access in Visual Basic wasn't much help if you wanted to write your database application in Visual C++. Now, as long as you're working in managed C++, the walkthroughs, tutorials, and samples you find for any managed languageand you'll find plenty for Visual Basic and C#are equally applicable to Visual C++. You'll have to translate the actual language elements, of course, but an explanation of a particular class or a method of that class is valid no matter which .NET supported language you intend to use.
Pre-Article:Intel Puts Chipmaking Technique on the Fast Track Next-Article:Bits & Bytes for January 26, 2004 |