Sunshine latest
Self-hosted game stream host for Moonlight.
thread_safe.h File Reference

Declarations for thread-safe data structures. More...

#include <array>
#include <atomic>
#include <condition_variable>
#include <functional>
#include <map>
#include <mutex>
#include <vector>
#include "utility.h"
Include dependency graph for thread_safe.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  safe::alarm_raw_t< T >
 
class  safe::event_t< T >
 
class  safe::mail_raw_t
 
class  safe::post_t< T >
 
struct  safe::shared_t< T >::ptr_t
 
class  safe::queue_t< T >
 
class  safe::shared_t< T >
 

Typedefs

template<class T >
using safe::alarm_t = std::shared_ptr<alarm_raw_t<T>>
 
using safe::mail_t = std::shared_ptr<mail_raw_t>
 
using safe::signal_t = event_t<bool>
 

Functions

void safe::cleanup (mail_raw_t *)
 
template<class T >
auto safe::lock (const std::weak_ptr< void > &wp)
 
template<class T >
alarm_t< T > safe::make_alarm ()
 
template<class T , class F_Construct , class F_Destruct >
auto safe::make_shared (F_Construct &&fc, F_Destruct &&fd)
 

Detailed Description

Declarations for thread-safe data structures.