Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The cancellation_token_source class represents the ability to cancel an operation.
class cancellation_token_source;
Members
Public Constructors
| Name | Description | 
|---|---|
| cancellation_token_source::cancellation_token_source Constructor | Overloaded. Constructs a cancellation_token_source object. | 
| cancellation_token_source::~cancellation_token_source Destructor | Destructs the cancellation_token_source object. | 
Public Methods
| Name | Description | 
|---|---|
| Cancels the token source and all the tokens associated with it. | |
| Overloaded. Creates a cancellation_token_source which will be canceled when an input token is canceled. | |
| Returns a cancellation_token associated with this source. | 
Public Operators
| Name | Description | 
|---|---|
| Determines whether two cancellation_token_source objects represent two different token sources. | |
| Overloaded. Replaces the contents of one cancellation_token_source object with another. | |
| Determines whether two cancellation_token_source objects represent the same token source. | 
Remarks
cancellation_token_source can be used to request cancellation of a cancelable operation.
Use the cancel method to set all cancellation_token objects that are associated with this cancellation_token_source as canceled.
cancellation_token_source behaves like a smart pointer and is safe to pass around by value.
Inheritance Hierarchy
cancellation_token_source
Requirements
Header: ppl.h
Namespace: concurrency