Table of Contents

Class LockManager

Namespace: Casewhere.Common
Assembly: Casewhere.Common.dll

public class LockManager : ILockManager

Inheritance

objectLockManager

Implements

ILockManager

Inherited Members

object.ToString(), object.Equals(object), object.Equals(object, object), object.ReferenceEquals(object, object), object.GetHashCode(), object.GetType(), object.MemberwiseClone()

Extension Methods

ObjectExtension.ConvertToBsonValue(object), EnumExtensions.DeepClone<LockManager>(LockManager)

Constructors

LockManager()

public LockManager()

Methods

Acquire(string, double)

Try add key to dictionary (for lock), if add success, the key will also add to MemoryCache

public bool Acquire(string key, double expirationTimeoutInSecond)

Parameters

key string

expirationTimeoutInSecond double

Returns

bool

Release(string)

public void Release(string key)

Parameters

key string

Release(List<string>)

public void Release(List<string> keys)

Parameters

keys List<string>