Action Engine
Loading...
Searching...
No Matches
concurrency.h File Reference

Detailed Description

Concurrency utilities for ActionEngine.

This file provides a set of concurrency utilities for use in ActionEngine. It includes classes and functions for managing fibers, channels, and synchronization primitives.

This file provides a set of concurrency utilities for use in ActionEngine. That includes classes and functions for managing fibers, channels, and basic synchronization primitives: mutexes and condition variables.

This implementation is based on Boost::fiber, but it is designed to mimic closely the thread::Fiber and thread::Channel interfaces used internally at Google. A fully compatible implementation is neither a guarantee nor a goal, but the API is designed to be similar enough to be used interchangeably in most cases. The Mutex and CondVar classes provide the same basic functionality as their counterparts in Abseil.

#include <absl/base/attributes.h>
#include <absl/base/nullability.h>
#include <absl/base/thread_annotations.h>
#include <absl/time/time.h>
#include "thread/concurrency.h"

Go to the source code of this file.

Functions

void act::SleepFor (absl::Duration duration)
 Sleeps for the given duration, allowing other fibers to proceed on the rest of the thread's quantum, and other threads to run.
 

Function Documentation

◆ SleepFor()

void act::SleepFor ( absl::Duration duration)
inline

Sleeps for the given duration, allowing other fibers to proceed on the rest of the thread's quantum, and other threads to run.

Parameters
durationThe duration to sleep for.