|
|
@@ -1,5 +1,4 @@
|
|
|
using System;
|
|
|
-using System.Collections;
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
namespace Masuit.Tools.Models
|
|
|
@@ -8,7 +7,7 @@ namespace Masuit.Tools.Models
|
|
|
/// 分页集合
|
|
|
/// </summary>
|
|
|
/// <typeparam name="T"></typeparam>
|
|
|
- public class PagedList<T> : IReadOnlyList<T>
|
|
|
+ public class PagedList<T>
|
|
|
{
|
|
|
/// <summary>
|
|
|
/// 数据集
|
|
|
@@ -65,19 +64,5 @@ namespace Masuit.Tools.Models
|
|
|
TotalPages = (int)Math.Ceiling(count * 1.0 / size);
|
|
|
Data = items;
|
|
|
}
|
|
|
-
|
|
|
- public IEnumerator<T> GetEnumerator()
|
|
|
- {
|
|
|
- return Data.GetEnumerator();
|
|
|
- }
|
|
|
-
|
|
|
- IEnumerator IEnumerable.GetEnumerator()
|
|
|
- {
|
|
|
- return GetEnumerator();
|
|
|
- }
|
|
|
-
|
|
|
- int IReadOnlyCollection<T>.Count => Data.Count;
|
|
|
-
|
|
|
- public T this[int index] => Data[index];
|
|
|
}
|
|
|
}
|