using System.Collections.Generic; namespace MemoryPools.Collections.Specialized { public static partial class AsSingleQueryList { public static IPoolingEnumerable AsSingleEnumerableList(this IEnumerable src) { var list = Pool>.Get().Init(); foreach (var item in src) { list.Add(item); } return Pool>.Get().Init(list); } public static IPoolingEnumerable AsSingleEnumerableSharedList(this IEnumerable src) where T : class { var list = Pool>.Get().Init(); foreach (var item in src) { list.Add(item); } return Pool>.Get().Init(list); } public static IPoolingEnumerable AsSingleEnumerableList(this IPoolingEnumerable src) { var list = Pool>.Get().Init(); foreach (var item in src) { list.Add(item); } return Pool>.Get().Init(list); } public static IPoolingEnumerable AsSingleEnumerableSharedList(this IPoolingEnumerable src) where T : class { var list = Pool>.Get().Init(); foreach (var item in src) { list.Add(item); } return Pool>.Get().Init(list); } } }