private WriteLock(ReaderWriterLockObject lockObject) { m_lockObject = lockObject; m_lockObject.Lock.EnterWriteLock(); m_lockObject.IsLocked = true; m_lockObject.ManagedThreadId = Thread.CurrentThread.ManagedThreadId; m_lockObject.ThreadName = Thread.CurrentThread.Name; }
public static WriteLock CreateLock(ReaderWriterLockObject lockObject) { return(new WriteLock(lockObject)); }
public static UpgradeableReadLock CreateLock(ReaderWriterLockObject lockObject) { return(new UpgradeableReadLock(lockObject)); }