18 #include <condition_variable> 21 #include <type_traits> 41 void Stop(
bool rethrowSendThreadExceptions =
true)
override;
58 std::mutex m_WaitMutex;
59 std::condition_variable m_WaitCondition;
60 std::thread m_SendThread;
61 std::atomic<bool> m_IsRunning;
62 std::atomic<bool> m_KeepRunning;
67 std::exception_ptr m_SendThreadException;
68 std::mutex m_PacketSentWaitMutex;
69 std::condition_variable m_PacketSentWaitCondition;
void Start(IProfilingConnection &profilingConnection) override
Start the thread.
bool WaitForPacketSent(uint32_t timeout)
void Stop(bool rethrowSendThreadExceptions=true) override
Stop the thread.
void SetReadyToRead() override
Set a "ready to read" flag in the buffer to notify the reading thread to start reading it...
SendThread(ProfilingStateMachine &profilingStateMachine, IBufferManager &buffer, ISendCounterPacket &sendCounterPacket, int timeout=1000)