MySQL  8.0.19
Source Code Documentation
Continuation Class Reference

#include <pipeline_interfaces.h>

Public Member Functions

 Continuation ()
 
 ~Continuation ()
 
int wait ()
 Wait until release. More...
 
void signal (int error=0, bool tran_discarded=false)
 Signal the continuation that execution can continue. More...
 
void reset_error_code ()
 Reset the error code after a reported error. More...
 
void set_transation_discarded (bool discarded)
 Sets the value of the flag for discarded transactions. More...
 
bool is_transaction_discarded ()
 Says if a transaction was discarded or not. More...
 

Private Attributes

mysql_mutex_t lock
 
mysql_cond_t cond
 
bool ready
 
int error_code
 
bool transaction_discarded
 

Detailed Description

Class used to wait on the execution of some action. The class can also be used to report whenever a transaction is discarded as a result of execution.

Constructor & Destructor Documentation

◆ Continuation()

Continuation::Continuation ( )
inline

◆ ~Continuation()

Continuation::~Continuation ( )
inline

Member Function Documentation

◆ is_transaction_discarded()

bool Continuation::is_transaction_discarded ( )
inline

Says if a transaction was discarded or not.

Returns
the transaction discarded flag
Return values
0not discarded
!=0discarded

◆ reset_error_code()

void Continuation::reset_error_code ( )
inline

Reset the error code after a reported error.

◆ set_transation_discarded()

void Continuation::set_transation_discarded ( bool  discarded)
inline

Sets the value of the flag for discarded transactions.

Parameters
[in]discardedis the transaction discarded.

◆ signal()

void Continuation::signal ( int  error = 0,
bool  tran_discarded = false 
)
inline

Signal the continuation that execution can continue.

Parameters
[in]errorthe error code if any
[in]tran_discardedif the transaction to whom the event belongs was discarded

◆ wait()

int Continuation::wait ( )
inline

Wait until release.

Note
The continuation will not wait if an error as occurred in the past until reset_error_code() is invoked.
Returns
the end status
Return values
0OK
!=0Error returned on the execution

Member Data Documentation

◆ cond

mysql_cond_t Continuation::cond
private

◆ error_code

int Continuation::error_code
private

◆ lock

mysql_mutex_t Continuation::lock
private

◆ ready

bool Continuation::ready
private

◆ transaction_discarded

bool Continuation::transaction_discarded
private

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