folly::cancellation_token_merge

Merge the given tokens into a single CancellationToken.

Synopsis

Declared in <folly/CancellationToken.h>

template<typename... Ts>
CancellationToken
cancellation_token_merge(Ts&&... tokens);

NOTE

This function is defined as an Algorithm Function Object (AFO).

Return Value

A token that is cancelled when any of tokens is cancelled.

Parameters

NameDescription
tokensThe cancellation tokens to merge.