#pragma once namespace Utils::Thread { bool setName(HANDLE t, const std::string& name); bool setName(DWORD id, const std::string& name); bool setName(std::thread& t, const std::string& name); bool setName(const std::string& name); template std::thread createNamedThread(const std::string& name, Args&&... args) { auto t = std::thread(std::forward(args)...); setName(t, name); return t; } std::vector getThreadIds(); void forEachThread(const std::function& callback); void suspendOtherThreads(); void resumeOtherThreads(); }