PartitionExtensionPartitionT, TResult(IEnumerableIGroupingBoolean, T, FuncIEnumerableT, IEnumerableT, TResult) Method
Partitions a grouping by Boolean keys into a projection of true
elements and false elements, respectively.
Namespace: MoreLinq.ExtensionsAssembly: MoreLinq (in MoreLinq.dll) Version: 4.4.0+6d97c3b1d482f98300f4446df14742b0e3fafbec
public static TResult Partition<T, TResult>(
this IEnumerable<IGrouping<bool, T>> source,
Func<IEnumerable<T>, IEnumerable<T>, TResult> resultSelector
)
<ExtensionAttribute>
Public Shared Function Partition(Of T, TResult) (
source As IEnumerable(Of IGrouping(Of Boolean, T)),
resultSelector As Func(Of IEnumerable(Of T), IEnumerable(Of T), TResult)
) As TResult
public:
[ExtensionAttribute]
generic<typename T, typename TResult>
static TResult Partition(
IEnumerable<IGrouping<bool, T>^>^ source,
Func<IEnumerable<T>^, IEnumerable<T>^, TResult>^ resultSelector
)
[<ExtensionAttribute>]
static member Partition :
source : IEnumerable<IGrouping<bool, 'T>> *
resultSelector : Func<IEnumerable<'T>, IEnumerable<'T>, 'TResult> -> 'TResult
- source IEnumerableIGroupingBoolean, T
- The source sequence.
- resultSelector FuncIEnumerableT, IEnumerableT, TResult
-
Function that projects the result from sequences of true elements
and false elements, respectively, passed as arguments.
- T
- Type of elements in source groupings.
- TResult
- Type of the result.
TResult
The return value from
resultSelector.
In Visual Basic and C#, you can call this method as an instance method on any object of type
IEnumerableIGroupingBoolean,
T. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).