![]() |
dfx 0.1.0
Linux-based dynamic dataflow executor
|
Small helpers to set and query the current thread name. More...
Go to the source code of this file.
Functions | |
| void | dfx::Utils::Thread::setName (std::string_view name, std::error_code &ec) noexcept |
| Set the calling thread name. | |
| void | dfx::Utils::Thread::setName (std::string_view name) |
| Set the calling thread name. | |
| std::string | dfx::Utils::Thread::getName (std::error_code &ec) noexcept |
| Get the calling thread name. | |
| std::string | dfx::Utils::Thread::getName () |
| Get the calling thread name. | |
Small helpers to set and query the current thread name.
These helpers set or retrieve the calling thread name, typically for debugging, logging, and observability (e.g., easier identification in top/htop, debuggers, profilers, crash dumps).
Two APIs are provided for each operation:
std::error_code& for no-throw usage (errors are reported through ec).std::error_code that reports failures by throwing (typically std::system_error, depending on implementation).