List<T>.Slice(Int32, Int32) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
在源 List<T>中创建一系列元素的浅表副本。
public:
System::Collections::Generic::List<T> ^ Slice(int start, int length);
public System.Collections.Generic.List<T> Slice(int start, int length);
member this.Slice : int * int -> System.Collections.Generic.List<'T>
Public Function Slice (start As Integer, length As Integer) As List(Of T)
参数
- length
- Int32
范围的长度。
返回
源 List<T>中元素范围的浅表副本。
例外
start 并且 length 不表示中 List<T>有效元素的范围。