thread_pool:C++11线程池

时间:2021-06-14 02:09:48
【文件属性】:
文件名称:thread_pool:C++11线程池
文件大小:8KB
文件格式:ZIP
更新时间:2021-06-14 02:09:48
C++ 线程池 C++11线程池 ####用法: std::mutex mtx; try{ tp::thread_pool tp; std::vector> v; std::vector> v1; for (int i = 0; i != 10; ++i){ auto ans = tp.submit([](int answer) { return answer; }, i); v.push_back(std::move(ans)); } for (int i = 0; i != 5; ++i){ auto ans = tp.submit([&mtx](const std::string& str1, const std::string& str2){ std::lock_guard<std::m
【文件预览】:
thread_pool-master
----thread_pool.sln(985B)
----.gitignore(3KB)
----thread_pool()
--------thread_guard.h(630B)
--------test.cpp(1KB)
--------thread_pool.h(2KB)
--------thread_pool.vcxproj(4KB)
--------thread_pool.vcxproj.filters(1KB)
----README.md(834B)
----.gitattributes(2KB)

网友评论