public void Lock()
 {
     if (_currentObject != null && LockingMemberInfo.GetValue(_currentObject) == null)
     {
         object user = GetCurrentUser();
         LockingMemberInfo.SetValue(_currentObject, user);
         _session.Save(_currentObject);
     }
 }
 public void UnLock(bool force)
 {
     if (force)
     {
         UnLockCore();
     }
     else if (_currentObject != null && LockingMemberInfo.GetValue(_currentObject) == GetCurrentUser())
     {
         UnLockCore();
     }
 }
 void UnLockCore()
 {
     _session.Reload(_currentObject);
     LockingMemberInfo.SetValue(_currentObject, null);
     _session.Save(_currentObject);
 }