C + + Now, for a company that is developing a project, choosing a development language under Windows is no longer as easy as it used to be. C + + was once the best choice for commercial development, but now, developers have no time and no patience to repeat the endless cycle of coding-compiling-and-error-making, and they are tired of tinkering with the loopholes in the programs that were written years ago. While C + + programming under Windows is relatively easy, the fast pace of the Internet era has not allowed them to compete slowly with their development tools. They need an efficient, secure development tool.
Compared to C + +, Java has the advantage of short development cycles, code security (because of no pointers), and platform independence. However, for low-level development, Java is still not ideal. Despite this, many programmers have started to choose Java as a development tool, including, of course, many of the original Windows developers. Perhaps that's why Microsoft is rushing to release its beta preview of the. NET SDK (software Development Kit). The development tool has been downloaded for 86M, which shows us a new development concept in the future Windows environment. Included in the toolkit is a C # compiler, which is a new programming language, named "C of the tooth." I do not know this tooth, will be Java bite into what looks like. But for c++,c# seems to have the idea of extermination.
The tooth that grows on C + +
The Microsoft-made alternative C + + is a great boon for those engaged in the development of Windows C + +, because it eases the pain that C + + brings to programmers. Unlike C + + and, of course, Java, it makes it easy to access the services that Windows itself has, including network objects, UIS, and network traffic. Like Java, C # has greatly enhanced the stability of C # by avoiding general programming errors and automatic resource management.
If you are already familiar with C + +, it is much easier to learn C # than to learn java. C # is not managed by Microsoft, but is managed by ECMA (the European Computer Manufacturing Consortium), just like JavaScript. ECMA is an independent entity. And there is no hint in the beta preview, but there are reports that Microsoft will issue other operating system versions. NET and C # (beta releases can only be run on Windiws2000). If this is true, C # is likely to do well in the near future.
There are critics who warn that. NET and C # are just a new type of software that has been announced or sold but has not yet been formally produced. Even so, it does not prevent people from using C # enthusiasm. We worked with it for nearly one months and found that it was really much better than the compilers we used before. In fact, because the compiler is doing really well, there are already developers on the Internet and web forums for some C # code exchange (e.g., http://www.csharpindex.com).
An editor for C # is now appearing, and other business editors are testing their support for C #. A good code editor should make it easy to write a Web server. Now Microsoft is combining Vertigo Software, ready to launch a practical. NET e-commerce demonstration products.
What is the crux of C + +?
The founders of Java said that C + + 's laissez-faire policy of programming gave the C + + developers A great deal of freedom. Not only do they have easy access to system resources, they can also be modified even for the language itself. This may be a major feature, but it is also the major feature of the destruction of C + + itself. In C + + programming, code errors can lead to system vulnerabilities, resulting in illegal or malicious memory operations. Not only that, because it is difficult to eliminate the problem, so many programmers big headache.
The stability of the Java application is mainly because it abandons the functions of C + + such as manual memory location, pointer (direct pointing memory), instantaneous variable and overload administrator. In addition, its automatic memory management, ease of platform independence, and a large number of predefined Java objects make it easy for Java developers to define and use objects.
It should be said that the Java excellent design has made the development of enterprise software greatly changed, but because it deviated from the syntax of C + +, making it difficult to be accepted by C + + developers. This has hindered its development and popularization to a great extent.
In contrast to Java, C # extends C + + to Java-like direction, which includes automatic memory management, Object life management, interpretation execution, easy access to external objects, and simplification of object creation. C + + useful concepts are discarded by Java, such as overloading administrators and reference variables, while C # retains these concepts. The Java-Discarded pointer is also preserved in C #, but it is no longer as omnipotent as it used to be. It is used only in those code snippets that are marked as unsecured.
porting to C #
Transition from C + + to C #, just like from manual to automated mode? In C + +, the object must be allocated a clear free memory, and in C #, the allocation of memory is automatically completed. Memory consumed by C # objects will be freed when the object is no longer in use (i.e., garbage recycling technology, a technology widely praised in Java).
In C + +, in order to access some system services, you have to include many files in the header, and most of these files are not used in the object design. In C #, system services are transparently packaged in some and C # compatible objects. In C + +, it is very difficult to transform C + + objects into Windows COM (Component OBJEC model), while in C # objects are automatically converted to. NET patterns and can be accessed from various. NET languages.
. NET layer ensures that objects can be used in a variety of languages, so there is no need for data conversion or external object conversion.
Now, the biggest difficulty in using C # is to ask programmers to get used to shifting gears without a clutch. Also said, once adjusted, C # will be easier to control than C + +. Java needs its C + + developers to learn a new way of doing things. For C #, the developers of C + + gave up only the ugly objects and poor memory management that were written in the system development process. And they can still use pointers and reference variables, which gives C # developers a direct, simple way to access external modules, including 32-bit Windows dynamic-link libraries.
Converting a Windows C + + application into a Java application would be a painful thing to do, but if you convert it to C #,. NET multi-language crossover will make all of this easier, and the transformed application will be greatly enhanced in stability. Microsoft seems to have made a lot of effort to easily access existing programs, and the results are pretty good.
In addition to the very good performance of the module, it would be wise to choose C # to migrate existing C + + applications to. NET. Microsoft's. NET extends to Visual C + +, making it easy to integrate with C # code.
C # is the heir
C # arises because Microsoft needs a Java-like language on. NET, and Java itself is not up to it. C # is so much like C + + that it's hard to give people the thrill of experiencing new things. However, it can be believed that the vast majority of C + + developers will choose to use it because C # retains most of its favorite, powerful, and exciting features in C + +. Regardless of Microsoft's motives, it is a matter of public satisfaction that C # is managed directly by ECMA. This gives us the opportunity to obtain resources from non-Microsoft C # tools and compilers and other organizations.
Third-party C # development tools will not need to obtain language licenses from Microsoft, which will keep the prices of these tools at a lower level. Instead, Sun has left its Java standard trajectory so that it can only stand alone on the path of Java development.
Because. NET relies on C # and can only run on Windows, so Microsoft has actually lagged behind Sun in enterprise-level development. However, due to its. NET Framework is independent of a specific language, so Microsoft will be able to occupy a part of the market share of the competition. Even in a beta release, developers can use C + +, C #, Visual Basic, JavaScript, and Visual FoxPro to develop. NET applications. They can be translated into a code language called IL (Intermediate language), and share a framework that defines data-independent techniques. Because there are no VB, C #, and JavaScript objects, only. NET objects, developers can use several language codes for mixed programming.
For traditional programming, developers like to use the same language in project development because it makes it easier for different developers to connect to each other. Right now. NET will no longer have this limitation, developers can put C #, VB, C + + and JavaScript in the same code compiler, and the. NET layer can put these pieces together, and there will be more programming language will be able to. NET in use. Developers can use their most familiar and favorite programming language to develop. This means that you can use as little time as possible, lower training costs, and clear source code, all of which will make the developer's development process very enjoyable.
One of the first tasks that C # has done is to enable C + + developers to access it. NET Framework. It's not an easy thing, because. NET is intended to be the core of Windows enterprise application development. At the Professional Developers ' conference held at Florida State Orlando. NET debut, Microsoft has shown to the world. NET is not only independent of hardware, but also is very convenient to interact between multi-platform.
Microsoft for its. NET's porting program has remained silent, of course making it the first thing to run under windows, but we doubt whether Microsoft will migrate it to Solaris and Linux as soon as possible. Once. NET extends to other systems outside of Windows, C # will become a truly powerful competitor for Java. By then, C # will be the true heir of C + + in Windows Enterprise development.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.