Represents possible actions for modification of the state.
More...
#include <SharedState.hpp>
|
void | access (std::function< void(T &)> block) |
| Provides read and write access to state within the block. More...
|
|
template<typename R > |
R | extract (std::function< R(T &)> block) |
| Provides read and write access to state within the block and returns a value. More...
|
|
void | notifyOne (std::function< void(T &)> block) |
| Provides read and write access to state within the block and notifies one thread waiting for state changes. More...
|
|
template<typename R > |
R | notifyOne (std::function< R(T &)> block) |
| Provides read and write access to state within the block and notifies one thread waiting for state changes. More...
|
|
void | notifyAll (std::function< void(T &)> block) |
| Provides read and write access to state within the block and notifies all threads waiting for state changes. More...
|
|
template<typename R > |
R | notifyAll (std::function< R(T &)> block) |
| Provides read and write access to state within the block and notifies all threads waiting for state changes. More...
|
|
Action & | when (std::function< bool(T &)> pred) |
| Waits till state will satisfy predicate condition. More...
|
|
template<typename T>
class CppMate::SharedState< T >::Action
Represents possible actions for modification of the state.
◆ access()
Provides read and write access to state within the block.
- Parameters
-
◆ extract()
template<typename T >
template<typename R >
Provides read and write access to state within the block and returns a value.
- Parameters
-
- Returns
- return value of the block.
◆ notifyAll() [1/2]
template<typename T >
template<typename R >
Provides read and write access to state within the block and notifies all threads waiting for state changes.
- Parameters
-
- Returns
- return value of the block.
◆ notifyAll() [2/2]
Provides read and write access to state within the block and notifies all threads waiting for state changes.
- Parameters
-
◆ notifyOne() [1/2]
template<typename T >
template<typename R >
Provides read and write access to state within the block and notifies one thread waiting for state changes.
- Parameters
-
- Returns
- return value of the block.
◆ notifyOne() [2/2]
Provides read and write access to state within the block and notifies one thread waiting for state changes.
- Parameters
-
◆ when()
Waits till state will satisfy predicate condition.
- Parameters
-
pred | the predicate function. |
- Returns
- itself.
◆ SharedState
The documentation for this class was generated from the following file: