简体   繁体   中英

What do you call a single header whose purpose is to include other header files?

I've seen this done before in various C++ libraries - namely Qt (QtCore, QtGui, etc.) and Irrlicht (irrlicht.h):

// file - mylibrary.h

#include "someclass1.h"
#include "someclass2.h"
#include "someclass3.h"
// and so on...

Obviously this exists for convenience - a programmer wishing to use the library only has to include one header instead of lots of different ones. My question is, is there a special name for this type of header file? Even if there's not an "official" name, what you you refer to it as? A "convenience header" or "module header" or something?


Names given so far ( with sources ):

User contributions ( no sources ):

That's a nice question :)

I've found some sources that call it master header file , eg:

When it is used to host headers for the header precompiler, it could be called precompiler global header :

However I don't think that there's a single widespread way to call it.

我不知道有没有正式的名字,但我唯一听说过的就是“伞”。

convenience header

I have seen them referred to as convenience header files. Here is one example from boost that I pull up with a quick google search.


meta-header

Never actually heard/seen someone call it a meta-header but the idea fits and is much easier to say than umbrella or convenience . I even found a reference to that name with a google search.

how about

header header?

:)

我喜欢“元标题”(这是我第二次发明的:-)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM