WaitTrigger¶
-
virtual PSignal ILatch::WaitTrigger(double timeout) = 0¶
Waits until the latch is triggered, or the timeout interval is exceeded.
- Parameters
timeout – Interval in seconds to wait for trigger. Negative value means infinite.
- Returns
PSignal – Data source signal.
- Throws
CInvalidArgumentException
– Invalid timeout specified (NaN).CInvalidOperationException
– Latch state not “Waiting” or “Triggered”.COutOfResourcesException
– No resources available to wait for trigger.CTimeoutException
– Timeout interval exceeded while waiting for trigger.CCommunicationErrorException
– Protocol error.CConnectionLostException
– Connection to controller lost.CRebootedException
– Controller has been rebooted since this object reference was retrieved, invalidating this reference.CObjectDestroyedException
– Object is destroyed.
- Remarks
Returns at entry of ELatchState::Triggered. Additionally, if configured with ELatchTriggerMode::OneShot, this function also returns if the latch is already triggered. Execution requires one subscription resource.