Show / Hide Table of Contents

Struct AsyncLock.Holder

Represents acquired asynchronous lock.

Implements
IDisposable
Inherited Members
ValueType.Equals(object)
ValueType.GetHashCode()
ValueType.ToString()
object.Equals(object, object)
object.GetType()
object.ReferenceEquals(object, object)
Namespace: DotNext.Threading
Assembly: DotNext.Threading.dll
Syntax
public struct AsyncLock.Holder : IDisposable
Remarks

The lock can be released by calling Dispose().

Properties

| Edit this page View Source

IsEmpty

Gets a value indicating that this object doesn't hold the lock.

Declaration
public readonly bool IsEmpty { get; }
Property Value
Type Description
bool

Methods

| Edit this page View Source

Dispose()

Releases the acquired lock.

Declaration
public void Dispose()
Remarks

This object is not reusable after calling of this method.

Operators

| Edit this page View Source

implicit operator bool(in Holder)

Indicates that the object holds successfully acquired lock.

Declaration
public static implicit operator bool(in AsyncLock.Holder holder)
Parameters
Type Name Description
AsyncLock.Holder holder

The lock holder.

Returns
Type Description
bool

true, if the object holds successfully acquired lock; otherwise, false.

Implements

IDisposable

Extension Methods

BasicExtensions.IsBetween<T, TLowerBound, TUpperBound>(T, TLowerBound, TUpperBound)
BasicExtensions.IsOneOf<T>(T, ReadOnlySpan<T>)
Collection.ToAsyncEnumerator<TEnumerator, T>(TEnumerator, CancellationToken)
Collection.ToClassicEnumerator<TEnumerator, T>(TEnumerator)
Enumerator.Skip<TEnumerator, T>(ref TEnumerator, int)
ExpressionBuilder.Const<T>(T)
  • Edit this page
  • View Source
☀
☾
In this article
Back to top
Supported by the .NET Foundation
☀
☾