Click or drag to resize
TimedLock Structure
This class is by Ian Griffiths, see: [FB]Comment below is by Ian as well. Class is left as-is with very minor changes in comments and code placement. Thanks to Eric Gunnerson for recommending this be a struct rather than a class - avoids a heap allocation. Thanks to Change Gillespie and Jocelyn Coulmance for pointing out the bugs that then crept in when I changed it to use struct... Thanks to John Sands for providing the necessary incentive to make me invent a way of using a struct in both release and debug builds without losing the debug leak tracking.

Namespace:  SD.LLBLGen.Pro.ORMSupportClasses
Assembly:  SD.LLBLGen.Pro.ORMSupportClasses (in SD.LLBLGen.Pro.ORMSupportClasses.dll) Version: (5.3.0)
public struct TimedLock : IDisposable

The TimedLock type exposes the following members.

Public methodDispose
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Public methodEquals
Indicates whether this instance and a specified object are equal.
(Inherited from ValueType.)
Public methodGetHashCode
Returns the hash code for this instance.
(Inherited from ValueType.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodStatic memberLock(Object)
Locks the specified o.
Public methodStatic memberLock(Object, TimeSpan)
Locks the specified o.
Public methodToString
Returns the fully qualified type name of this instance.
(Inherited from ValueType.)
See Also