TryLock¶
Tries to acquire lock for a shared key.
1 |
|
Parameters¶
string key
Shared lock key.
Returns¶
Token value in string if lock has acquired, otherwise null.
Remarks¶
This method immediately checks to shared key is locked and generates token if shared key is not locked. Does not perform any wait operation for availability, if you want to wait for short period, please use the Lock method instead.
Example¶
1 2 3 4 5 6 7 |
|