C++/CLI Fundamentals |
|
To make it possible for people to write programmers that run on Microsoft Windows operating systems, Microsoft developed a library named Win32. This library is mainly a series of objects and their behaviors that define how to create programs that allow a person to interact with a personal computer (PC).
C++ is a computer language that was developed by Bjarne Stroustrup, from AT & T. Instead of completely reinventing the wheel, he based it on the C language. He added various features such object-oriented programming (classes) and inheritance, just to name a few. Based on the solidity of C++, the language laid a great foundation that many other programming languages imitated. From its original implementation, C++ lacked a few features that some other languages had. For example, C++ didn’t have a string data type. It had some limits on file streaming. It also had little or no support for web programming, native database development, XML, etc. Still, because C++ featured many strong qualities, various new languages were based on it, including Java, JavaScript, and lately C#. As you would guess, these new languages completed what C++ lacked. Alternative languages were also developed to perform tasks that were difficult in C++. These languages included Perl, Microsoft Visual Basic, PHP, VBScript, etc. C++ and many other languages have always benefited from additional libraries. These were used to provide support for areas that probably were not dealt with when the language first came up. In fact, these libraries are what usually makes a language appealing. Some of the libraries that assist C++ are STL and boost. Still, with the high demands of modern assignments, and considering that C++ has not been updated for a while, apparently some of its shortcomings have not evaded.
As the Microsoft Windows 3.X and then 5.5 operating systems were becoming popular, many programmers were interested in creating graphical programs. They had to use Win32, which made it possible only to use C to create programs. With this approach, everything was done manually, including the design and code writing, which was an increasing demanding task, wasting a good deal of time. Remember that Win32 was written in C and had no native support for C++. Therefore, Microsoft created a library, named Microsoft Foundation Classes Library, and abbreviated MFC. This library was originally an “adaptation” or customization of Win32, adding object-orientation (classes and inheritance) to it. Because Win32 was written in C, it also carried C’s limitations, such as a rough or little support for file streaming, web programming, XML, little support for object serialization, etc. The MFC library was a great addition and overcame many C’s limitations.
The MFC is a library and can be used to manually develop programs. To make the use of MFC friendlier, Microsoft developed Microsoft Visual C++. This is a graphical programming environment that allows designing Windows objects and writing code to implement their behavior. As its name indicates, this environment takes C++ as its base language. Fortunately, using MFC, it goes over some of the limitations of C++ and takes advantage of MFC’s classes.
To use the Win32 library, a programmer had to know either C or C++. To use the MFC, you had to know C++ and have the patience of using it with its pointers and memory management. To alleviate these and other types of challenges to create or develop graphical windows, Microsoft created Microsoft Visual Basic as a relatively easy-to-use language. This programming environment appeared to be friendlier than Visual C++. While Microsoft Visual C++ perfectly “understands” Win32, one of the shortcomings of Visual Basic is that it cannot directly interpret Win32 code. To use Win32, you had to “import” or “load” the necessary function from Win32 into Microsoft Visual Basic. |
|
||
Home | Copyright © 2006-2016, FunctionX, Inc. | Next |
|