CTRE Phoenix Pro C++ 23.0.12
ctre::phoenix::threading::ManualEvent Class Reference

Manual Event object, useful for signaling other threads about an event. More...

#include <ctre/phoenix/threading/ManualEvent.hpp>

Public Member Functions

 ManualEvent (bool initialSignal=false)
 
bool WaitForSignal (int timeoutMs) const
 Wait for event to be signaled, or for timeout. More...
 
void Signal ()
 Signal the event. More...
 
void Clear ()
 Clear the event. More...
 
void Reset ()
 Reset the event signal without signaling other threads. More...
 

Detailed Description

Manual Event object, useful for signaling other threads about an event.

Constructor & Destructor Documentation

◆ ManualEvent()

ctre::phoenix::threading::ManualEvent::ManualEvent ( bool  initialSignal = false)
Parameters
initialSignalobject defaults to Signaled or Not Signaled (default is not signaled).

Member Function Documentation

◆ Clear()

void ctre::phoenix::threading::ManualEvent::Clear ( )

Clear the event.

Any threads waiting on WaitForSignal() will time out.

◆ Reset()

void ctre::phoenix::threading::ManualEvent::Reset ( )

Reset the event signal without signaling other threads.

◆ Signal()

void ctre::phoenix::threading::ManualEvent::Signal ( )

Signal the event.

Any threads waiting on WaitForSignal() will return true.

◆ WaitForSignal()

bool ctre::phoenix::threading::ManualEvent::WaitForSignal ( int  timeoutMs) const

Wait for event to be signaled, or for timeout.

Returns
true if event is signaled, false if timed out.

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