ExtensionMethodsCoGroupByTInput1, TInput2, TKey, TOutput, TTime Method Naiad Help

[This is preliminary documentation and is subject to change.]

Groups records from both input streams using the respective key selector, and applies the given reduction function.

Namespace: Microsoft.Research.Naiad.Frameworks.Lindi
Assembly: Microsoft.Research.Naiad.Lindi (in Microsoft.Research.Naiad.Lindi.dll) Version: 0.5.0.0 (0.5.0.0)
Syntax

C#
public static Stream<TOutput, TTime> CoGroupBy<TInput1, TInput2, TKey, TOutput, TTime>(
	this Stream<TInput1, TTime> stream1,
	Stream<TInput2, TTime> stream2,
	Func<TInput1, TKey> keySelector1,
	Func<TInput2, TKey> keySelector2,
	Func<TKey, IEnumerable<TInput1>, IEnumerable<TInput2>, IEnumerable<TOutput>> reducer
)
where TTime : Object, Time<TTime>

Parameters

stream1
Type: Microsoft.Research.NaiadStreamTInput1, TTime
The first input stream.
stream2
Type: Microsoft.Research.NaiadStreamTInput2, TTime
The second input stream.
keySelector1
Type: SystemFuncTInput1, TKey
The key selector applied to records in stream1.
keySelector2
Type: SystemFuncTInput2, TKey
The key selector applied to records in stream2.
reducer
Type: SystemFuncTKey, IEnumerableTInput1, IEnumerableTInput2, IEnumerableTOutput
Function that transforms a key and two sequences of records from each input stream to a sequence of output records.

Type Parameters

TInput1
The type of records in stream1.
TInput2
The type of records in stream2.
TKey
The key type.
TOutput
The result type.
TTime
The type of timestamp on each record.

Return Value

Type: StreamTOutput, TTime
The stream of output records for each group in either input stream.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type StreamTInput1, TTime. 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).
See Also

Reference