|
NexusForce 1.0.0
A rigorously engineered full-stack C++ backend library.
|
RAII事务作用域守卫 更多...
#include "NeForce/db/db_interface.hpp"类 | |
| class | neforce::scope_transaction< Connect > |
| RAII事务作用域守卫 更多... | |
函数 | |
| template<typename Connect> | |
| scope_transaction< Connect > | neforce::make_transaction (Connect &conn) |
| 事务守卫的便捷构造函数 | |
RAII事务作用域守卫
提供异常安全的事务管理,构造时自动开始事务,析构时根据提交状态决定提交或回滚。
使用示例:
在文件 scope_transaction.hpp 中定义.