AsyncEnumerable.TakeLast<TSource> 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
返回包含最后 count 一个元素的新 source序列。
public:
generic <typename TSource>
[System::Runtime::CompilerServices::Extension]
static System::Collections::Generic::IAsyncEnumerable<TSource> ^ TakeLast(System::Collections::Generic::IAsyncEnumerable<TSource> ^ source, int count);
public static System.Collections.Generic.IAsyncEnumerable<TSource> TakeLast<TSource>(this System.Collections.Generic.IAsyncEnumerable<TSource> source, int count);
static member TakeLast : System.Collections.Generic.IAsyncEnumerable<'Source> * int -> System.Collections.Generic.IAsyncEnumerable<'Source>
<Extension()>
Public Function TakeLast(Of TSource) (source As IAsyncEnumerable(Of TSource), count As Integer) As IAsyncEnumerable(Of TSource)
类型参数
- TSource
中 source元素的类型。
参数
- source
- IAsyncEnumerable<TSource>
要从中返回元素的序列。
- count
- Int32
要从序列末尾获取的元素数。
返回
IAsyncEnumerable<TSource>
包含上 count 一个元素 source的新序列。