olp-cpp-sdk  1.21.0
Public Types | Public Member Functions | List of all members
olp::client::CancellationToken Class Reference

Cancels service requests. More...

#include <CancellationToken.h>

Public Types

using CancelFuncType = std::function< void()>
 An alias for the cancellation function.
 

Public Member Functions

 CancellationToken (CancelFuncType func)
 Creates the CancellationToken instance. More...
 
void Cancel () const
 Cancels the current operation and calls the func_ instance.
 

Detailed Description

Cancels service requests.

Constructor & Destructor Documentation

◆ CancellationToken()

olp::client::CancellationToken::CancellationToken ( CancelFuncType  func)
explicit

Creates the CancellationToken instance.

Parameters
funcThe operation that should be used to cancel the ongoing operation.

The documentation for this class was generated from the following file: