#include <WaitSet.hpp>
Inheritance diagram for WaitSet< DELEGATE >:A WaitSet object allows an application to wait until one or more of the attached Condition objects has a trigger_value of TRUE or else until the timeout expires. A WaitSet is not necessarily associated with a single DomainParticipant and could be used to wait on Condition objects associated with different DomainParticipant objects.
Definition at line 38 of file WaitSet.hpp.
| typedef dds::core::Reference< DELEGATE > BASE_T |
Definition at line 43 of file WaitSet.hpp.
| typedef std::vector<dds::core::cond::Condition> ConditionSeq |
Definition at line 40 of file WaitSet.hpp.
| typedef ::dds::core::smart_ptr_traits< DELEGATE >::ref_type DELEGATE_REF_T |
Reimplemented from Reference< DELEGATE >.
Definition at line 43 of file WaitSet.hpp.
| typedef DELEGATE DELEGATE_T |
Reimplemented from Reference< DELEGATE >.
Definition at line 43 of file WaitSet.hpp.
| typedef ::dds::core::smart_ptr_traits< DELEGATE >::weak_ref_type DELEGATE_WEAK_REF_T |
Reimplemented from Reference< DELEGATE >.
Definition at line 43 of file WaitSet.hpp.
| WaitSet | ( | DELEGATE_T * | p | ) | [inline, explicit] |
Definition at line 43 of file WaitSet.hpp.
| WaitSet | ( | const DELEGATE_REF_T & | ref | ) | [inline, explicit] |
Definition at line 43 of file WaitSet.hpp.
| WaitSet | ( | const H__ & | h | ) | [inline] |
Definition at line 43 of file WaitSet.hpp.
| WaitSet | ( | ) | [inline] |
Definition at line 43 of file WaitSet.hpp.
| ~WaitSet | ( | ) | [inline] |
Definition at line 48 of file WaitSet.hpp.
| void attach_condition | ( | const dds::core::cond::Condition & | cond | ) | [inline] |
Attaches a Condition to the WaitSet. It is possible to attach a Condition on a WaitSet that is currently being waited upon (via the wait operation). In this case, if the Condition has a trigger_value of TRUE, then attaching the condition will unblock the WaitSet. Adding a Condition that is already attached to the WaitSet has no effect.
| cond | the condition to be attached to this waitset. |
Definition at line 228 of file WaitSet.hpp.
| void close | ( | ) | [inline] |
Definition at line 50 of file WaitSet.hpp.
| ConditionSeq& conditions | ( | ConditionSeq & | conds | ) | const [inline] |
This operation retrieves the list of attached conditions.
Definition at line 258 of file WaitSet.hpp.
| const ConditionSeq conditions | ( | ) | [inline] |
This operation retrieves the list of attached conditions.
Definition at line 249 of file WaitSet.hpp.
| bool detach_condition | ( | const dds::core::cond::Condition & | cond | ) | [inline] |
Detaches a Condition from the WaitSet. If the Condition was not attached to the WaitSet, the operation will return false.
| cond | the condition to detach from this WaitSet |
Definition at line 240 of file WaitSet.hpp.
| void dispatch | ( | ) | [inline] |
Waits for at least one of the attached conditions to trigger and then dispatches the events.
Definition at line 190 of file WaitSet.hpp.
| void dispatch | ( | const dds::core::Duration & | timeout | ) | [inline] |
Waits for at least one of the attached conditions to trigger and then dispatches the events, or, times out and unblocks.
Definition at line 199 of file WaitSet.hpp.
| static WaitSet newWaitSet | ( | ) | [static] |
| WaitSet& operator+= | ( | const dds::core::cond::Condition & | cond | ) | [inline] |
A synonym for attach_condition.
Definition at line 207 of file WaitSet.hpp.
| WaitSet& operator-= | ( | const dds::core::cond::Condition & | cond | ) | [inline] |
A synonym for detach_condition.
Definition at line 214 of file WaitSet.hpp.
| WaitSet& operator= | ( | const T__ & | rhs | ) | [inline] |
Definition at line 43 of file WaitSet.hpp.
| const ConditionSeq wait | ( | ) | [inline] |
This operation allows an application thread to wait for the occurrence of certain conditions. If none of the conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
The wait operation takes a timeout argument that specifies the maximum duration for the wait. It this duration is exceeded and none of the attached Condition objects is true, wait will continue and the returned ConditionSeq will be empty.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will raise immediately an exception PreconditionNotMet.
The result of the wait operation is the list of all the attached conditions that have a trigger_value of TRUE (i.e., the conditions that unblocked the wait).
| timeout | the maximum amount of time for which the wait should block while waiting for a condition to be triggered. |
PreconditionNotMetException when multiple thread try to invoke the method concurrently.
Definition at line 115 of file WaitSet.hpp.
| const ConditionSeq wait | ( | const dds::core::Duration & | timeout | ) | [inline] |
This operation allows an application thread to wait for the occurrence of certain conditions. If none of the conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
The wait operation takes a timeout argument that specifies the maximum duration for the wait. It this duration is exceeded and none of the attached Condition objects is true, wait will continue and the returned ConditionSeq will be empty.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will raise immediately an exception PreconditionNotMet.
The result of the wait operation is the list of all the attached conditions that have a trigger_value of TRUE (i.e., the conditions that unblocked the wait).
| timeout | the maximum amount of time for which the wait should block while waiting for a condition to be triggered. |
PreconditionNotMetException when multiple thread try to invoke the method concurrently.
Definition at line 83 of file WaitSet.hpp.
| ConditionSeq& wait | ( | ConditionSeq & | triggered, | |
| const dds::core::Duration & | timeout | |||
| ) | [inline] |
This operation allows an application thread to wait for the occurrence of certain conditions. If none of the conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
The wait operation takes a timeout argument that specifies the maximum duration for the wait. It this duration is exceeded and none of the attached Condition objects is true, wait will continue and the returned ConditionSeq will be empty.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will raise immediately an exception PreconditionNotMet.
The result of the wait operation is the list of all the attached conditions that have a trigger_value of TRUE (i.e., the conditions that unblocked the wait).
| timeout | the maximum amount of time for which the wait should block while waiting for a condition to be triggered. |
PreconditionNotMetException when multiple thread try to invoke the method concurrently.
Definition at line 147 of file WaitSet.hpp.
| ConditionSeq& wait | ( | ConditionSeq & | triggered | ) | [inline] |
This operation allows an application thread to wait for the occurrence of certain conditions. If none of the conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
The wait operation takes a timeout argument that specifies the maximum duration for the wait. It this duration is exceeded and none of the attached Condition objects is true, wait will continue and the returned ConditionSeq will be empty.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will raise immediately an exception PreconditionNotMet.
The result of the wait operation is the list of all the attached conditions that have a trigger_value of TRUE (i.e., the conditions that unblocked the wait).
| timeout | the maximum amount of time for which the wait should block while waiting for a condition to be triggered. |
PreconditionNotMetException when multiple thread try to invoke the method concurrently.
Definition at line 180 of file WaitSet.hpp.
1.7.1