Loading...
Searching...
No Matches
osmium::thread Namespace Reference

Threading-related low-level code. More...

## Classes

class | function_wrapper
class | Pool
class | Queue
class | thread_handler

## Functions

template<typename T >
void | check_for_exception (std::future< T > &future)
template<typename T >
void | wait_until_done (std::future< T > &future)
void | set_thread_name (const char *name) noexcept

## Detailed Description

Threading-related low-level code.

## Function Documentation

## check_for_exception()

template<typename T >

void osmium::thread::check_for_exception | ( | std::future< T > & | future | ) |

inline

Check if the future resulted in an exception. This will re-throw the exception stored in the future if there was one. Otherwise it will just return.

## set_thread_name()

void osmium::thread::set_thread_name | ( | const char * | name | ) |

inline noexcept

Set name of current thread for debugging. This currently only works on Linux and FreeBSD.

## wait_until_done()

template<typename T >

void osmium::thread::wait_until_done | ( | std::future< T > & | future | ) |

inline

Wait until the given future becomes ready. Will block if the future is not ready. Can be called more than once unlike future.get().