Turn: Open source projects where c/+ + programmers must be proficient

Source: Internet
Author: User

As an experienced C + + programmer, must have written various functions of the code, such as encapsulating the database access classes, encapsulating the network communication classes, encapsulating the log operation of the class, encapsulating the file access classes, packaging the UI interface Library and so on, but also in the actual project, but back to think carefully, In fact, these previously written code, can only be used in a specific project or a specific environment, for themselves, in different projects, only need to copy code, change is also possible, because their own code is familiar with writing. The problem is, you encapsulate these libraries, in the use of others, when others are very convenient to use, cross-platform is not also very common, performance is not enough good, is not support multi-threading, the function is not strong enough, can be applied to a variety of different needs. If you've done all of this, it's a testament to the fact that you've spent a lot of time on this library, and it's been continuously improved and optimized.

In the daily development, as a programmer, a lot of things have no need to re-development, can be used directly, after all, 21st century has been over n years. There's no need to reinvent the wheel (there's no denying that the process of inventing wheels can learn a lot, and that's how I came along).

The following combination of their own years of development experience, think where to write where, I hope that the new people have some help.

First, the network

The network library must master aces and Libevent, one is a heavyweight network library, and the other is a lightweight network library. Think about it, now that app doesn't use the Internet. Do not understand the network, you will be unable to move AH. Familiar with the two open Source Library premise is that you must understand the principle of socket, to recommend the good Book is "UNIX Network Programming", read this book can be, and other what "Windows network Programming" These do not have to look, because network programming, you learned the Berkeley socket, You can do network programming on any platform, do not need to learn what the network programming under Windows, because the network under Windows is also from the Berkeley socket, if you learn "Windows network Programming", then you Linux,unix the day under the network programming, You'll have to study a bit. There is no need for that.

Second, the database

Database well, open source MySQL and open source PostgreSQL as long as understand one of them, business database in mastering an Oracle can, file database Master SQLite. But please note, do not be confused by the database name above, the nature of the database is SQL statement, must understand the basic principles of the database, proficient in the use of SQL language, understand the optimization of the database, stored procedures. The principle of the database to understand, take what database come easy to master, will not care whether it is MySQL or Oracle.

Third, the log operation

Log operations recommended that you are familiar with Log4cpp this log library, support multi-threading, log redirection to the network, etc. have, anyway you can think of the function of the log, there are.

Log, one is convenient to find the problem, easy to record the operation of some cases. This is a must.

Http://www.ibm.com/developerworks/cn/linux/l-log4cpp/index.html is a description of the use of the library

Iv. Management Background

As we all know, writing programs is for others to use, not their own use, so in the program's ease of use, more to the other side to provide some direct view of the management interface, appears to be divided into important. For the program to provide a Web management interface, convenient for users to log on to view the program's various information, it is necessary.

I have here a handy web-managed HTTP implementation that can be easily integrated into the application. In IE, enter the listening port, you can view the status of the program. The code has not been carefully collated. A brother in need can give me a message and send it to everyone.

V. Read the configuration file

All programs must have a configuration file that facilitates configuration of projects and provides flexibility for the program. So write a program that must have a wrapper class to read the configuration file.

Six, Memory pool

All processes need to allocate memory, and allocating and managing memory is a challenging task for C + +.

We recommend Nedmalloc this open source memory pool library. Nedmalloc is a cross-platform, high-performance multi-threaded memory allocation library that is used by many libraries.

Vii. Cache Library

As we all know, the most used cache library is memcache. This is especially useful when doing database development.

Eight, the script

Script is a very interesting thing, a lot of features, in fact, we just write a script can be done, the code is small, development speed.

The scripts that have to be mastered are more commonly used to count Perl, very old languages, but the features are too powerful. I can assure you that. Net,java can do a good job, and it's sure to get Perl to do it. C capable, Perl is not necessarily capable. Perl as Linux, Unix's system-integrated scripting language, must learn.

The Lua language, the language, is used more in the gaming industry. Do not recommend learning.

Python script, very powerful, recommended to learn.

These are some of the more common features that all programs will use.

In different application areas, need to master different open source libraries, such as game development, may need to master the open source UI library Cegui, open source 3D engine ogre and so on.

There may be distributed File system libraries for distributed development.

Goto: Open source projects that C/C + + programmers must be proficient in

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.