Compartir a través de


AsyncReaderWriterResourceLock<TMoniker, TResource>.PrepareResourceForExclusiveAccessAsync Method

Microsoft internal only. Prepares a resource for access by one thread.

Namespace:  Microsoft.VisualStudio.Threading
Assembly:  Microsoft.VisualStudio.Threading (in Microsoft.VisualStudio.Threading.dll)

Syntax

'Declaration
Protected MustOverride Function PrepareResourceForExclusiveAccessAsync ( _
    resource As TResource, _
    lockFlags As AsyncReaderWriterResourceLock(Of T).LockFlags, _
    cancellationToken As CancellationToken _
) As Task
protected abstract Task PrepareResourceForExclusiveAccessAsync(
    TResource resource,
    AsyncReaderWriterResourceLock<T>.LockFlags lockFlags,
    CancellationToken cancellationToken
)
protected:
virtual Task^ PrepareResourceForExclusiveAccessAsync(
    TResource resource, 
    AsyncReaderWriterResourceLock<T>::LockFlags lockFlags, 
    CancellationToken cancellationToken
) abstract
abstract PrepareResourceForExclusiveAccessAsync : 
        resource:'TResource * 
        lockFlags:AsyncReaderWriterResourceLock<T>.LockFlags * 
        cancellationToken:CancellationToken -> Task
protected abstract function PrepareResourceForExclusiveAccessAsync(
    resource : TResource, 
    lockFlags : AsyncReaderWriterResourceLock<TMoniker, TResource>.LockFlags, 
    cancellationToken : CancellationToken
) : Task

Parameters

Return Value

Type: System.Threading.Tasks.Task
A Task whose completion signals the resource has been prepared.

.NET Framework Security

See Also

Reference

AsyncReaderWriterResourceLock<TMoniker, TResource> Class

Microsoft.VisualStudio.Threading Namespace