Class EnumerableExtensions
Inheritance
Namespace: Syncfusion.Data.Extensions
Assembly: Syncfusion.Data.Portable.dll
Syntax
public static class EnumerableExtensions : Object
Methods
Average(IEnumerable<Int16>)
Gets the average of all System.Double values from the specified source
.
Declaration
public static double Average(this IEnumerable<short> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Int16> | source | The specified source for which the average to be calculated |
Returns
Type | Description |
---|---|
System.Double | The average of all System.Double values from the specified |
Average(IEnumerable<Nullable<Int16>>)
Gets the average of all System.Double? values from the specified source
.
Declaration
public static Nullable<double> Average(this IEnumerable<Nullable<short>> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Nullable<System.Int16>> | source | The specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Double> | The average of all System.Double? values from the specified |
Average<TSource>(IEnumerable<TSource>, Func<TSource, Int16>)
Gets the average of all System.Double values from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static double Average<TSource>(this IEnumerable<TSource> source, Func<TSource, short> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source for which the average to be calculated |
System.Func<TSource, System.Int16> | selector | The function that retrieves all System.Double values from the specified |
Returns
Type | Description |
---|---|
System.Double | The average of all System.Double values from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Average<TSource>(IEnumerable<TSource>, Func<TSource, Nullable<Int16>>)
Gets the average of all System.Double? values from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static Nullable<double> Average<TSource>(this IEnumerable<TSource> source, Func<TSource, Nullable<short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source for which the average to be calculated. |
System.Func<TSource, System.Nullable<System.Int16>> | selector | The function that retrieves all System.Double? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Double> | The average of all System.Double? values from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Average<TSource>(IQueryable<TSource>, Expression<Func<TSource, Int16>>)
Gets the average of all System.Double values from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static double Average<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source for which the average to be calculated |
System.Linq.Expressions.Expression<System.Func<TSource, System.Int16>> | selector | The function that retrieves all System.Double values from the specified |
Returns
Type | Description |
---|---|
System.Double | The average of all System.Double values from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
Average<TSource>(IQueryable<TSource>, Expression<Func<TSource, Nullable<Int16>>>)
Gets the average of all System.Double? values from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static Nullable<double> Average<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, Nullable<short>>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source for which the average to be calculated. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Nullable<System.Int16>>> | selector | The function that retrieves all System.Double? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Double> | The average of all System.Double? values from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
GetElementType(IEnumerable)
Gets the Element type of the specified source.
Declaration
public static Type GetElementType(this IEnumerable source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source |
Returns
Type | Description |
---|---|
System.Type | The Element type of the specified source. |
GetGenericSourceType(IEnumerable)
Gets the generic source type of the specified source.
Declaration
public static Type GetGenericSourceType(IEnumerable source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source |
Returns
Type | Description |
---|---|
System.Type | The generic source type of the specified source. |
GetItemPropertyInfo(IEnumerable)
Gets the Item property informaation of the specified list
.
Declaration
public static PropertyInfo GetItemPropertyInfo(this IEnumerable list)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | list |
Returns
Type | Description |
---|---|
System.Reflection.PropertyInfo | The Item property informaation of the specified |
GetItemType(IEnumerable, Boolean)
Gets the item type of the source.
Declaration
public static Type GetItemType(this IEnumerable source, bool useRepresentativeItem)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source | |
System.Boolean | useRepresentativeItem |
Returns
Type | Description |
---|---|
System.Type | The item type of the source. |
GetParallelQuery(IEnumerable, Type)
Gets the parallel sequence of the specified source
.
Declaration
public static ParallelQuery GetParallelQuery(this IEnumerable source, Type sourceType = null)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source | |
System.Type | sourceType |
Returns
Type | Description |
---|---|
System.Linq.ParallelQuery | the parallel sequence of the specified |
GetParallelQueryFor<T>(IEnumerable)
Gets the parallel query of the specified source
.
Declaration
public static ParallelQuery<T> GetParallelQueryFor<T>(IEnumerable source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source |
Returns
Type | Description |
---|---|
System.Linq.ParallelQuery<T> | The parallel query of the specified |
Type Parameters
Name |
---|
T |
IndexOf<T>(IEnumerable<T>, T)
Gets the index of the specified value
in the source
.
Declaration
public static int IndexOf<T>(this IEnumerable<T> source, T value)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<T> | source | |
T | value |
Returns
Type | Description |
---|---|
System.Int32 | the index of the specified |
Type Parameters
Name |
---|
T |
InvokeParallelExecution<T>(IEnumerable, Predicate<Object>)
Creates a System.Linq.ParallelQuery for the specified source
.
Declaration
public static ParallelQuery InvokeParallelExecution<T>(IEnumerable source, Predicate<object> func)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source | The specified Source. |
System.Predicate<System.Object> | func | The func that ensures the criteria to create a System.Linq.ParallelQuery. |
Returns
Type | Description |
---|---|
System.Linq.ParallelQuery | The System.Linq.ParallelQuery for the specified |
Type Parameters
Name |
---|
T |
Max(IEnumerable<Int16>)
Gets the maximum value of System.Int16 from the specified System.Collections.IEnumerable source
.
Declaration
public static short Max(this IEnumerable<short> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Int16> | source | The specified source from which the maximum value to be found. |
Returns
Type | Description |
---|---|
System.Int16 | The maximum value of System.Int16 from the specified System.Collections.IEnumerable |
Max(IEnumerable<Nullable<Int16>>)
Gets the maximum value of System.Int16? from the specified source
.
Declaration
public static Nullable<short> Max(this IEnumerable<Nullable<short>> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Nullable<System.Int16>> | source | The specified source from which the maximum value to be found. |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The maximum value of System.Int16? from the specified |
Max<TSource>(IEnumerable<TSource>, Func<TSource, Int16>)
Gets the maximum value of System.Int16 from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static short Max<TSource>(this IEnumerable<TSource> source, Func<TSource, short> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source from which the maximum value to be found. |
System.Func<TSource, System.Int16> | selector | The function that retrieves all System.Int16 values from the specified |
Returns
Type | Description |
---|---|
System.Int16 | The maximum value of System.Int16 from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Max<TSource>(IEnumerable<TSource>, Func<TSource, Nullable<Int16>>)
Gets the maximum value of System.Int16? from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static Nullable<short> Max<TSource>(this IEnumerable<TSource> source, Func<TSource, Nullable<short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source from which the maximum value to be found. |
System.Func<TSource, System.Nullable<System.Int16>> | selector | The function that retrieves all System.Int16? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The maximum value of System.Int16? from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Max<TSource>(IQueryable<TSource>, Expression<Func<TSource, Int16>>)
Gets the maximum value of System.Int16 from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static short Max<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source from which the maximum value to be found. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Int16>> | selector | The function that retrieves all System.Int16 values from the specified |
Returns
Type | Description |
---|---|
System.Int16 | The maximum value of System.Int16 from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
Max<TSource>(IQueryable<TSource>, Expression<Func<TSource, Nullable<Int16>>>)
Gets the maximum value of System.Int16? from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static Nullable<short> Max<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, Nullable<short>>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source from which the maximum value to be found. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Nullable<System.Int16>>> | selector | The function that retrieves all System.Int16? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The maximum value of System.Int16? from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
Min(IEnumerable<Int16>)
Gets the minimum of System.Int16 value from the specified System.Collections.IEnumerable source
.
Declaration
public static short Min(this IEnumerable<short> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Int16> | source | The specified source from which the minimum value to be found. |
Returns
Type | Description |
---|---|
System.Int16 | The minimum of System.Int16 value from the specified System.Collections.IEnumerable |
Min(IEnumerable<Nullable<Int16>>)
Gets the minimum value of System.Int16? from the specified source
.
Declaration
public static Nullable<short> Min(this IEnumerable<Nullable<short>> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Nullable<System.Int16>> | source | The specified source from which the minimum value to be found. |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The minimum value of System.Int16? from the specified |
Min<TSource>(IEnumerable<TSource>, Func<TSource, Int16>)
Gets the minimum value of System.Int16 from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static short Min<TSource>(this IEnumerable<TSource> source, Func<TSource, short> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source from which the minimum value to be found. |
System.Func<TSource, System.Int16> | selector | The function that retrieves all System.Int16 values from the specified |
Returns
Type | Description |
---|---|
System.Int16 | The minimum value of System.Int16 from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Min<TSource>(IEnumerable<TSource>, Func<TSource, Nullable<Int16>>)
Gets the minimum value of System.Int16? from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static Nullable<short> Min<TSource>(this IEnumerable<TSource> source, Func<TSource, Nullable<short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source from which the minimum value to be found. |
System.Func<TSource, System.Nullable<System.Int16>> | selector | The function that retrieves all System.Int16? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The minimum of value System.Int16? from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Min<TSource>(IQueryable<TSource>, Expression<Func<TSource, Int16>>)
Gets the minimum value of System.Int16 from the specified System.Linq.IQueryable source using selector
.
Declaration
public static short Min<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source from which the minimum value to be found. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Int16>> | selector | The function that retrieves all System.Int16 values from the specified |
Returns
Type | Description |
---|---|
System.Int16 | The minimum value of System.Int16 from the specified System.Linq.IQueryable source using |
Type Parameters
Name |
---|
TSource |
Min<TSource>(IQueryable<TSource>, Expression<Func<TSource, Nullable<Int16>>>)
Gets the minimum value of System.Int16? from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static Nullable<short> Min<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, Nullable<short>>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source from which the minimum value to be found. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Nullable<System.Int16>>> | selector | The function that retrieves all System.Int16? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The minimum value of System.Int16? from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
OrderBy<T>(IEnumerable<T>, String, Func<String, Object, Object>)
Sorts the elements of a sequence in ascending order.
Declaration
public static IEnumerable<T> OrderBy<T>(this IEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in ascending order according to a key. |
Type Parameters
Name |
---|
T |
OrderBy<T>(IEnumerable<T>, String, Func<String, Object, Object>, IComparer<Object>)
Sorts the elements of a sequence in ascending order by using specified comparer.
Declaration
public static IEnumerable<T> OrderBy<T>(this IEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc, IComparer<object> comparer)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
System.Collections.Generic.IComparer<System.Object> | comparer | The comparer. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in ascending order according to a key. |
Type Parameters
Name |
---|
T |
OrderByDescending<T>(IEnumerable<T>, String, Func<String, Object, Object>)
Sorts the elements of a sequence in descending order.
Declaration
public static IEnumerable<T> OrderByDescending<T>(this IEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in descending order according to a key. |
Type Parameters
Name |
---|
T |
OrderByDescending<T>(IEnumerable<T>, String, Func<String, Object, Object>, IComparer<Object>)
Sorts the elements of a sequence in descending order by using specified comparer.
Declaration
public static IEnumerable<T> OrderByDescending<T>(this IEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc, IComparer<object> comparer)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
System.Collections.Generic.IComparer<System.Object> | comparer | The comparer. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in descending order according to a key. |
Type Parameters
Name |
---|
T |
Sum(IEnumerable<Int16>)
Gets the sum of all System.Int16 values from the specified source
.
Declaration
public static short Sum(this IEnumerable<short> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Int16> | source | The specified source for which the sum to be calculated. |
Returns
Type | Description |
---|---|
System.Int16 | The sum of all System.Int16 values from the specified |
Sum(IEnumerable<Nullable<Int16>>)
Gets the sum of all System.Int16? values from the specified source
Declaration
public static Nullable<short> Sum(this IEnumerable<Nullable<short>> source)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Nullable<System.Int16>> | source | The specified source for which the sum to be calculated. |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | the sum of all System.Int16? values from the specified |
Sum<TSource>(IEnumerable<TSource>, Func<TSource, Int16>)
Gets the sum of all System.Int16 values from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static short Sum<TSource>(this IEnumerable<TSource> source, Func<TSource, short> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source for which the sum to be calculated. |
System.Func<TSource, System.Int16> | selector | The function that retrieves System.Int16 values from the specified |
Returns
Type | Description |
---|---|
System.Int16 | The sum of all System.Int16 values from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Sum<TSource>(IEnumerable<TSource>, Func<TSource, Nullable<Int16>>)
Gets the sum of all System.Int16? values from the specified System.Collections.IEnumerable source
using selector
.
Declaration
public static Nullable<short> Sum<TSource>(this IEnumerable<TSource> source, Func<TSource, Nullable<short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TSource> | source | The specified source for which the sum to be calculated. |
System.Func<TSource, System.Nullable<System.Int16>> | selector | The function that retrieves System.Int16? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The sum of all System.Int16? values from the specified System.Collections.IEnumerable |
Type Parameters
Name |
---|
TSource |
Sum<TSource>(IQueryable<TSource>, Expression<Func<TSource, Int16>>)
Gets the sum of all System.Int16 values from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static short Sum<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, short>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source for which the sum to be calculated. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Int16>> | selector | The function that retrieves System.Int16 values from the specified |
Returns
Type | Description |
---|---|
System.Int16 | The sum of all System.Int16 values from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
Sum<TSource>(IQueryable<TSource>, Expression<Func<TSource, Nullable<Int16>>>)
Gets the sum of all System.Int16? values from the specified System.Linq.IQueryable source
using selector
.
Declaration
public static Nullable<short> Sum<TSource>(this IQueryable<TSource> source, Expression<Func<TSource, Nullable<short>>> selector)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IQueryable<TSource> | source | The specified source for which the sum to be calculated. |
System.Linq.Expressions.Expression<System.Func<TSource, System.Nullable<System.Int16>>> | selector | The function that retrieves System.Int16? values from the specified |
Returns
Type | Description |
---|---|
System.Nullable<System.Int16> | The sum of all System.Int16? values from the specified System.Linq.IQueryable |
Type Parameters
Name |
---|
TSource |
ThenBy<T>(IOrderedEnumerable<T>, String, Func<String, Object, Object>)
Performs a subsequent ordering of the elements in a sequence in ascending order.
Declaration
public static IEnumerable<T> ThenBy<T>(this IOrderedEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IOrderedEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in ascending order according to a key. |
Type Parameters
Name |
---|
T |
ThenBy<T>(IOrderedEnumerable<T>, String, Func<String, Object, Object>, IComparer<Object>)
Performs a subsequent ordering of the elements in a sequence in ascending order by using specified comparer.
Declaration
public static IEnumerable<T> ThenBy<T>(this IOrderedEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc, IComparer<object> comparer)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IOrderedEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
System.Collections.Generic.IComparer<System.Object> | comparer | The comparer. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in ascending order according to a key. |
Type Parameters
Name |
---|
T |
ThenByDescending<T>(IOrderedEnumerable<T>, String, Func<String, Object, Object>)
Performs a subsequent ordering of the elements in a sequence in descending order.
Declaration
public static IEnumerable<T> ThenByDescending<T>(this IOrderedEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IOrderedEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in descending order according to a key. |
Type Parameters
Name |
---|
T |
ThenByDescending<T>(IOrderedEnumerable<T>, String, Func<String, Object, Object>, IComparer<Object>)
Performs a subsequent ordering of the elements in a sequence in descending by using specified comparer.
Declaration
public static IEnumerable<T> ThenByDescending<T>(this IOrderedEnumerable<T> entities, string propertyName, Func<string, object, object> getFunc, IComparer<object> comparer)
Parameters
Type | Name | Description |
---|---|---|
System.Linq.IOrderedEnumerable<T> | entities | The source. |
System.String | propertyName | The property name. |
System.Func<System.String, System.Object, System.Object> | getFunc | The get func. |
System.Collections.Generic.IComparer<System.Object> | comparer | The comparer. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T> | An System.Linq.IOrderedEnumerable<> whose elements are sorted in descending order according to a key. |
Type Parameters
Name |
---|
T |