namespace WrtDeviceApis {
namespace Commons {
-
/**
* Manages listener events emitters.
* Template parameter should be class that derives from @see ListenerEvent.
}
/**
- * Emits event through those emitters that when passed to predicate result in
+ * Emits event through those emitters that when passed to predicate result
+ * in
* returning true by it.
* @param event Event to emit.
* @param pred Predicate - a callable object (function, functor) that takes
*/
template<typename Predicate>
void emitIf(const EventPtrType& event,
- Predicate pred)
+ Predicate pred)
{
DPL::Mutex::ScopedLock lock(&m_mtx);
for (Iterator it = m_emitters.begin(); it != m_emitters.end(); ++it) {
/**
* Lock this object.
- * This lock will be automatically released when out of scope (unless someone
+ * This lock will be automatically released when out of scope (unless
+ * someone
* copies it). Do not use in the same scope as other API of this class.
* @return Lock object.
* @remarks Provided to allow locking emitters in scope of some client
DPL::Mutex m_mtx; ///< Synchronizes operation on this object.
Map m_emitters; ///< Emitters container.
};
-
}
} // WrtDeviceApisCommon