-
#include "tensorstore/util/future.h"
-
template <typename Callback>
FutureCallbackRegistration
tensorstore::Promise<T>::ExecuteWhenNotNeeded(
Callback&& callback) const; Registers a callback to be invoked when
result_needed()
becomesfalse
.If
result_needed()
isfalse
upon invocation, the callback is executed immediately.Note
Typically, the specified
callback
function cancels pending work when invoked.