C# 클래스 Catel.Threading.AsyncLock

파일 보기 프로젝트 열기: Catel/Catel 1 사용 예제들

공개 메소드들

메소드 설명
AsyncLock ( ) : System

Creates a new async-compatible mutual exclusion lock.

AsyncLock ( IAsyncWaitQueue queue ) : System

Creates a new async-compatible mutual exclusion lock using the specified wait queue.

Lock ( ) : IDisposable

Synchronously acquires the lock. Returns a disposable that releases the lock when disposed. This method may block the calling thread.

Lock ( CancellationToken cancellationToken ) : IDisposable

Synchronously acquires the lock. Returns a disposable that releases the lock when disposed. This method may block the calling thread.

LockAsync ( ) : AwaitableDisposable

Asynchronously acquires the lock. Returns a disposable that releases the lock when disposed.

LockAsync ( CancellationToken cancellationToken ) : AwaitableDisposable

Asynchronously acquires the lock. Returns a disposable that releases the lock when disposed.

비공개 메소드들

메소드 설명
ReleaseLock ( ) : void

Releases the lock.

메소드 상세

AsyncLock() 공개 메소드

Creates a new async-compatible mutual exclusion lock.
public AsyncLock ( ) : System
리턴 System

AsyncLock() 공개 메소드

Creates a new async-compatible mutual exclusion lock using the specified wait queue.
public AsyncLock ( IAsyncWaitQueue queue ) : System
queue IAsyncWaitQueue The wait queue used to manage waiters.
리턴 System

Lock() 공개 메소드

Synchronously acquires the lock. Returns a disposable that releases the lock when disposed. This method may block the calling thread.
public Lock ( ) : IDisposable
리턴 IDisposable

Lock() 공개 메소드

Synchronously acquires the lock. Returns a disposable that releases the lock when disposed. This method may block the calling thread.
public Lock ( CancellationToken cancellationToken ) : IDisposable
cancellationToken System.Threading.CancellationToken The cancellation token used to cancel the lock. If this is already set, then this method will attempt to take the lock immediately (succeeding if the lock is currently available).
리턴 IDisposable

LockAsync() 공개 메소드

Asynchronously acquires the lock. Returns a disposable that releases the lock when disposed.
public LockAsync ( ) : AwaitableDisposable
리턴 AwaitableDisposable

LockAsync() 공개 메소드

Asynchronously acquires the lock. Returns a disposable that releases the lock when disposed.
public LockAsync ( CancellationToken cancellationToken ) : AwaitableDisposable
cancellationToken System.Threading.CancellationToken The cancellation token used to cancel the lock. If this is already set, then this method will attempt to take the lock immediately (succeeding if the lock is currently available).
리턴 AwaitableDisposable