Apache Mesos
Namespaces | Macros | Functions | Variables
libev.hpp File Reference
#include <ev.h>
#include <mutex>
#include <queue>
#include <process/future.hpp>
#include <process/owned.hpp>
#include <stout/lambda.hpp>
#include <stout/synchronized.hpp>

Go to the source code of this file.

Namespaces

 process
 

Macros

#define __in_event_loop__
 

Functions

template<typename T >
void process::_run_in_event_loop (const lambda::function< Future< T >()> &f, const Owned< Promise< T >> &promise)
 
template<typename T >
Future< T > process::run_in_event_loop (const lambda::function< Future< T >()> &f)
 

Variables

struct ev_loop * process::loop
 
ev_async process::async_watcher
 
std::queue< ev_io * > * process::watchers
 
std::mutex * process::watchers_mutex
 
std::queue< lambda::function
< void()> > * 
process::functions
 
thread_local bool * process::_in_event_loop_
 

Macro Definition Documentation

#define __in_event_loop__
Value:
*(_in_event_loop_ == nullptr ? \
_in_event_loop_ = new bool(false) : _in_event_loop_)
thread_local bool * _in_event_loop_
Definition: libevent.hpp:28