| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687 |
- <?xml version="1.0" encoding="utf-8"?>
- <Type Name="TaskExtensions" FullName="System.Threading.Tasks.TaskExtensions">
- <TypeSignature Language="C#" Value="public static class TaskExtensions" />
- <TypeSignature Language="ILAsm" Value=".class public auto ansi abstract sealed beforefieldinit TaskExtensions extends System.Object" />
- <AssemblyInfo>
- <AssemblyName>System.Core</AssemblyName>
- <AssemblyVersion>4.0.0.0</AssemblyVersion>
- </AssemblyInfo>
- <Base>
- <BaseTypeName>System.Object</BaseTypeName>
- </Base>
- <Interfaces />
- <Docs>
- <remarks>To be added.</remarks>
- <summary>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>Provides a set of static (Shared in Visual Basic) methods for working with specific kinds of <see cref="T:System.Threading.Tasks.Task" /> instances.</para>
- </summary>
- </Docs>
- <Members>
- <Member MemberName="Unwrap">
- <MemberSignature Language="C#" Value="public static System.Threading.Tasks.Task Unwrap (this System.Threading.Tasks.Task<System.Threading.Tasks.Task> task);" />
- <MemberSignature Language="ILAsm" Value=".method public static hidebysig class System.Threading.Tasks.Task Unwrap(class System.Threading.Tasks.Task`1<class System.Threading.Tasks.Task> task) cil managed" />
- <MemberType>Method</MemberType>
- <AssemblyInfo>
- <AssemblyVersion>4.0.0.0</AssemblyVersion>
- </AssemblyInfo>
- <ReturnValue>
- <ReturnType>System.Threading.Tasks.Task</ReturnType>
- </ReturnValue>
- <Parameters>
- <Parameter Name="task" Type="System.Threading.Tasks.Task<System.Threading.Tasks.Task>" RefType="this" />
- </Parameters>
- <Docs>
- <remarks>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>It is often useful to be able to return a Task from a <see cref="T:System.Threading.Tasks.Task`1" />, where the inner Task represents work done as part of the outer <see cref="T:System.Threading.Tasks.Task`1" />. However, doing so results in a Task<Task> (C#) or Task (Of Task) (Visual Basic), which, if not dealt with carefully, could produce unexpected behavior. Unwrap solves this problem by creating a proxy Task that represents the entire asynchronous operation of such a task.</para>
- </remarks>
- <summary>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>Creates a proxy <see cref="T:System.Threading.Tasks.Task" /> that represents the asynchronous operation of a <see cref="M:System.Threading.Tasks.TaskScheduler.TryExecuteTaskInline(System.Threading.Tasks.Task,System.Boolean)" />.</para>
- </summary>
- <returns>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>A Task that represents the asynchronous operation of the provided System.Threading.Tasks.Task(Of Task).</para>
- </returns>
- <param name="task">
- <attribution license="cc4" from="Microsoft" modified="false" />The Task<Task> (C#) or Task (Of Task) (Visual Basic) to unwrap.</param>
- </Docs>
- </Member>
- <Member MemberName="Unwrap<TResult>">
- <MemberSignature Language="C#" Value="public static System.Threading.Tasks.Task<TResult> Unwrap<TResult> (this System.Threading.Tasks.Task<System.Threading.Tasks.Task<TResult>> task);" />
- <MemberSignature Language="ILAsm" Value=".method public static hidebysig class System.Threading.Tasks.Task`1<!!TResult> Unwrap<TResult>(class System.Threading.Tasks.Task`1<class System.Threading.Tasks.Task`1<!!TResult>> task) cil managed" />
- <MemberType>Method</MemberType>
- <AssemblyInfo>
- <AssemblyVersion>4.0.0.0</AssemblyVersion>
- </AssemblyInfo>
- <ReturnValue>
- <ReturnType>System.Threading.Tasks.Task<TResult></ReturnType>
- </ReturnValue>
- <TypeParameters>
- <TypeParameter Name="TResult" />
- </TypeParameters>
- <Parameters>
- <Parameter Name="task" Type="System.Threading.Tasks.Task<System.Threading.Tasks.Task<TResult>>" RefType="this" />
- </Parameters>
- <Docs>
- <remarks>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>It is often useful to be able to return a <see cref="T:System.Threading.Tasks.Task" /> from a <see cref="T:System.Threading.Tasks.Task" />, where the inner <see cref="T:System.Threading.Tasks.Task" /> represents work done as part of the outer <see cref="T:System.Threading.Tasks.Task" />. However, doing so results in a Task<Task<T>> (C#) or Task (Of Task(Of T)) (Visual Basic), which, if not dealt with carefully, could produce unexpected behavior. Unwrap solves this problem by creating a proxy <see cref="T:System.Threading.Tasks.Task`1" /> that represents the entire asynchronous operation of such a Task<Task<T>> (C#) or Task (Of Task(Of T)) (Visual Basic).</para>
- </remarks>
- <summary>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>Creates a proxy <see cref="T:System.Threading.Tasks.Task" /> that represents the asynchronous operation of a Task<Task<T>> (C#) or Task (Of Task(Of T)) (Visual Basic).</para>
- </summary>
- <returns>
- <attribution license="cc4" from="Microsoft" modified="false" />
- <para>A <see cref="T:System.Threading.Tasks.Task" /> that represents the asynchronous operation of the provided Task<Task<T>> (C#) or Task (Of Task(Of T)) (Visual Basic).</para>
- </returns>
- <param name="task">
- <attribution license="cc4" from="Microsoft" modified="false" />The Task<Task<T>> (C#) or Task (Of Task(Of T)) (Visual Basic) to unwrap.</param>
- <typeparam name="TResult">
- <attribution license="cc4" from="Microsoft" modified="false" />The type of the task's result.</typeparam>
- </Docs>
- </Member>
- </Members>
- </Type>
|