|
dxd - dynax driver framework 3.0.0d222
cross platform open source driver development framework
|
whether this pipe stands: an event to wait on and a promoted to follow - dx::pipe::status derives it from what the last operation answered More...
#include <dx_pipe.h>
Public Types | |
| typedef std::unique_lock< mutex_t > | lock_t |
| typedef std::mutex | mutex_t |
| typedef bool | value_t |
Public Member Functions | |
| void | commit (lock_t &&lock, const value_t &value) |
| the server's answer: the value stands, the transition ends and the listeners are told - outside the lock, so a listener may read the promoted back | |
| connection () | |
| < promoted value notifyng connection changes | |
| virtual event & | initialize (bool signalled=false) |
| virtual event & | initialize (const std::string &, bool signalled=false) |
| operator const value_t & () | |
| value_t | operator++ (int) noexcept |
| promoted & | operator+= (const value_t &value) noexcept |
| value_t | operator-- (int) noexcept |
| promoted & | operator-= (const value_t &value) noexcept |
| const value_t & | operator-> () |
| bool | operator== (const value_t &value) |
| event & | reset (uint64_t count=0) override |
| super & | signal (uint64_t count=1) override |
| uint64_t | signalled () const |
| super & | wait (bool reset=false) override |
| template<typename rep_t, typename period_t> | |
| bool | wait (const std::chrono::duration< rep_t, period_t > &timeout, bool reset=false) |
Public Attributes | |
| bool | initialized |
| listen< std::function< void(const value_t &)> > | listen |
| std::function< void(lock_t &&, const value_t &, const value_t &)> | server |
| \ indicate the value is in transition - does not have the new value yet | |
| bool | transient |
| \ indicate the value has been initialized | |
Static Public Attributes | |
| static constexpr auto | scope {user} |
Protected Attributes | |
| value_t | value |
whether this pipe stands: an event to wait on and a promoted to follow - dx::pipe::status derives it from what the last operation answered
|
inherited |
|
inherited |
|
inherited |
|
inline |
< promoted value notifyng connection changes
|
inlineinherited |
the server's answer: the value stands, the transition ends and the listeners are told - outside the lock, so a listener may read the promoted back
|
inlinevirtualinherited |
Reimplemented in dx::event< kernel >.
|
inlinevirtualinherited |
Reimplemented in dx::event< kernel >, and dx::shared::event.
|
inlineinherited |
|
inlinenoexceptinherited |
|
inlinenoexceptinherited |
|
inlinenoexceptinherited |
|
inlinenoexceptinherited |
|
inlineinherited |
|
inlineinherited |
Implements dx::abstract::event.
Implements dx::abstract::event.
|
inlineinherited |
wait with duration timeout returns true: signalled false: timed out
|
inherited |
|
inherited |
|
inherited |
\ indicate the value is in transition - does not have the new value yet
server: handle synchronous and asynchronous value updates and initialization lock: lock promoted value from access during update value: new value (if in transition) current: current value to allow discarding update and reverting to current value if update is not permitted
it needs to handle these case: not initialized and not in transition: initialze and commit the value not initialized and in transition: if dependent on external settings initialize a temporary and compare it with the new value and update the external setting if required make sure to commit the new value so listeners get notified either synchronously or asynchronously by external notification initialized and in transition: update external settings if any and make sure to commit the new value so listeners get notified either synchronously or asynchronousl by external notification
server will not be called with this state: initialized and not in transation
for synchronous operation: move lock to commit for asynchronous operation: store lock and at asynchronous response restore and move lock to commit
|
inherited |
\ indicate the value has been initialized
|
protectedinherited |
| (c) copyright 2009 dynamic acoustics e.U. | generated on |