Locks a resource defined by key. The resource name is application-defined.
Class: YetaWF.Core.IO.ILockProvider
Namespace: YetaWF.Core.IO
Assembly: YetaWF.Core
public Task<ILockObject> LockResourceAsync( string key );
key
The resource name.
Returns an lock object. This object must be disposed.
Once the returned object is disposed, the lock is released. It is better to explicitly unlock the resource using the ILockObject.UnlockAsync method due to its async nature. The object must be disposed properly in all cases, even if the ILockObject.UnlockAsync method is called to unlock.
See Also YetaWF.Core.IO.ILockProvider ClassYetaWF.Core Overview
Documentation Feedback
© 2024 - Softel vdm, Inc. - YetaWF.com