public void Dispose() { if (_locker != null) { _locker.Unlock(_resource); _locker = null; } }
public ResourceLock(ResourceLocker <T> locker, T resource) { _locker = locker; _resource = resource; }