Home | All Classes | Main Classes | Annotated | Grouped Classes | Functions |

# The dumpcpp Tool

The `dumpcpp` tool generates a C++ namespace for a type library.

To generate a C++ namespace for a type library, call `dumpcpp` with the following command line parameters:

Option | Result
--- | ---
input | Generate documentation for input. input can specify a type library file or a type library ID, or a CLSID or ProgID for an object
-o file | Writes the class declaration to file.h and meta object infomation to file.cpp
-n namespace | Generate a C++ namespace namespace
-nometaobject | Do not generate a .cpp file with the meta object information. The meta object is then generated in runtime.
-v | Print version information
-h | Print help

`dumpcpp` can be integrated into the `qmake` build system. In your .pro file, add dumpcpp to the `CONFIG` and list the type libraries you want to use in the TYPELIBS variable:

        TEMPLATE = app
        TARGET   = qutlook
        CONFIG  += qaxcontainer

        !exists("c:\program files\Microsoft Office\Office10\msoutl.olb") {
            message("Microsoft Outlook type library not found at standard location!")
            REQUIRES += Outlook
        } else {
            TYPELIBS = "c:\program files\Microsoft Office\Office10\msoutl.olb"

To build the tool you must first build the QAxContainer library. Then run your make tool in `tools/dumpcpp`.