AsyncReaderWriterResourceLock<TMoniker, TResource>.ResourceReleaser.GetResourceAsync Method
Microsoft internal only. Gets the lock-protected resource.
Namespace: Microsoft.VisualStudio.Threading
Assembly: Microsoft.VisualStudio.Threading (in Microsoft.VisualStudio.Threading.dll)
Syntax
'Declaration
Public Function GetResourceAsync ( _
resourceMoniker As TMoniker, _
cancellationToken As CancellationToken _
) As Task(Of TResource)
public Task<TResource> GetResourceAsync(
TMoniker resourceMoniker,
CancellationToken cancellationToken
)
public:
Task<TResource>^ GetResourceAsync(
TMoniker resourceMoniker,
CancellationToken cancellationToken
)
member GetResourceAsync :
resourceMoniker:'TMoniker *
cancellationToken:CancellationToken -> Task<'TResource>
public function GetResourceAsync(
resourceMoniker : TMoniker,
cancellationToken : CancellationToken
) : Task<TResource>
Parameters
resourceMoniker
Type: TMonikerThe identifier for the protected resource.
cancellationToken
Type: System.Threading.CancellationTokenA token whose cancellation signals lost interest in the protected resource.
Return Value
Type: System.Threading.Tasks.Task<TResource>
A Task<TResult> whose result is the resource.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
AsyncReaderWriterResourceLock<TMoniker, TResource>.ResourceReleaser Structure