7 #include "fwData/mt/ObjectReadToWriteLock.hpp" 9 #include <boost/thread/locks.hpp> 54 m_upgradedLock = std::make_shared< ::fwCore::mt::UpgradeToWriteLock >(std::ref(m_lock));
61 m_upgradedLock.reset();
FWDATA_API void downgrade()
Downgrade exclusive lock to upgradable lock.
::boost::upgrade_lock< ReadWriteMutex > ReadToWriteLock
Defines an upgradable lock type for read/write mutex.
FWDATA_API void upgrade()
Upgrade lock to exclusive.
FWDATA_API void lock()
Adds upgradable lock on object mutex.
FWDATA_API void unlock()
Releases upgradable lock on object mutex.
FWDATA_API ~ObjectReadToWriteLock()
Destructor. Does nothing.
Contains the representation of the data objects used in the framework.
FWDATA_API ObjectReadToWriteLock(::fwData::Object::sptr obj, bool lock=true)
Constructor : owns an upgradable lock on object mutex. If adopt_lock==false : the mutex is not locked...