Home > The Program Execution Monitor > Implementation

The Program Execution Monitor implementation

To monitor execution of user supplied function cpp_main() the Program Execution Monitor relies on the Boost.Test's Execution Monitor. Also the Program Execution Monitor supplies the function main() to facilitate uniform error reporting. Following files constitute the Program Execution Monitor implementation:
為了監控用戶提供的 cpp_main() 函數的執行,Program Execution Monitor 依賴於 Boost.Test 的 Execution Monitor。 同樣,Program Execution Monitor 提供 main() 函數來簡化統一錯誤報告。 下面的文件組成了 Program Execution Monitor 的實現:


provides Execution Monitor implementation for all supported configurations.
提供 Execution Monitor 支持所有設置的實現。


supplies function main() for static library build
為靜態庫生成提供 main() 函數


combines all implementation files into single header to be use as inlined version of component


contains definitions for main() function for dynamic library build and pragmas for auto-linking feature support.
包含為動態庫生成定義的 main() 和用於自動鏈接 (auto-link) 特性的 pragma。

The Program Execution Monitor implementation wraps several system headers and is intended to be used as standalone library. While there exist an alternative variant to include the whole implementation directly into your program, for the long term usage the preferable solution is to build library once and reuse it.
Program Execution Monitor 的實現覆蓋了一些系統頭文件,並且傾向於作為單獨的庫使用。 作為替代可以將所有實現直接包含 (include the whole implementation directly) 進你的程序, 但如果長期使用,更好的解決方案是生成庫一次 (build library once) 並重用。