InterviewSolution
| 1. |
What Is Moc(meta Object Compiler)? |
|
Answer» The Meta-Object Compiler, moc, is the program that handles QT's C++ extensions. The moc tool reads a C++ HEADER file. If it finds one or more class declarations that CONTAIN the Q_OBJECT macro, it produces a C++ source file CONTAINING the meta-object code for those classes. Among other things, meta-object code is required for the signals and slots mechanism, the run-time type information, and the DYNAMIC property system. The Meta-Object Compiler, moc, is the program that handles Qt's C++ extensions. The moc tool reads a C++ header file. If it finds one or more class declarations that contain the Q_OBJECT macro, it produces a C++ source file containing the meta-object code for those classes. Among other things, meta-object code is required for the signals and slots mechanism, the run-time type information, and the dynamic property system. |
|