Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
QtOhos::QOhosMtBlockingCallsGateway< SlaveContext > Class Template Reference

#include <qohosmtblockingcallsgateway_p.h>

Inheritance diagram for QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >:
Collaboration diagram for QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >:

Public Types

enum class  MasterThreadTaskResult { CancelledByDeadlock , TimeoutedBeforeStart , TimeoutedAfterStart , Finished }

Public Member Functions

void invokeInMasterThread (std::function< void()> &&task)
void invokeInSlaveThread (std::function< void(SlaveContext &)> &&task)
void runInSlaveThreadAndWaitForContinue (QOhosConsumer< SlaveContext &, std::function< void()> > &&task)
Q_REQUIRED_RESULT MasterThreadTaskResult tryInvokeInMasterThreadAndTryWaitForContinue (QOhosConsumer< std::function< void()> > &&task, std::chrono::nanoseconds timeout)

Static Public Member Functions

static std::shared_ptr< QOhosMtBlockingCallsGateway< SlaveContext > > makeInstance (QOhosConsumer< std::function< void()> > masterThreadTasksExecutor, QOhosConsumer< std::function< void(SlaveContext &)> > slaveThreadTasksExecutor)

Detailed Description

template<typename SlaveContext>
class QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >

Definition at line 34 of file qohosmtblockingcallsgateway_p.h.

Member Enumeration Documentation

◆ MasterThreadTaskResult

template<typename SlaveContext>
enum class QtOhos::QOhosMtBlockingCallsGateway::MasterThreadTaskResult
strong
Enumerator
CancelledByDeadlock 
TimeoutedBeforeStart 
TimeoutedAfterStart 
Finished 

Definition at line 37 of file qohosmtblockingcallsgateway_p.h.

Member Function Documentation

◆ invokeInMasterThread()

template<typename SlaveContext>
void QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >::invokeInMasterThread ( std::function< void()> && task)

Definition at line 97 of file qohosmtblockingcallsgateway_p.h.

◆ invokeInSlaveThread()

template<typename SlaveContext>
void QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >::invokeInSlaveThread ( std::function< void(SlaveContext &)> && task)

Definition at line 103 of file qohosmtblockingcallsgateway_p.h.

◆ makeInstance()

template<typename SlaveContext>
std::shared_ptr< QOhosMtBlockingCallsGateway< SlaveContext > > QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >::makeInstance ( QOhosConsumer< std::function< void()> > masterThreadTasksExecutor,
QOhosConsumer< std::function< void(SlaveContext &)> > slaveThreadTasksExecutor )
static

Definition at line 78 of file qohosmtblockingcallsgateway_p.h.

◆ runInSlaveThreadAndWaitForContinue()

template<typename SlaveContext>
void QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >::runInSlaveThreadAndWaitForContinue ( QOhosConsumer< SlaveContext &, std::function< void()> > && task)

Definition at line 109 of file qohosmtblockingcallsgateway_p.h.

◆ tryInvokeInMasterThreadAndTryWaitForContinue()

template<typename SlaveContext>
QOhosMtBlockingCallsGateway< SlaveContext >::MasterThreadTaskResult QtOhos::QOhosMtBlockingCallsGateway< SlaveContext >::tryInvokeInMasterThreadAndTryWaitForContinue ( QOhosConsumer< std::function< void()> > && task,
std::chrono::nanoseconds timeout )

Definition at line 143 of file qohosmtblockingcallsgateway_p.h.


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