Qbservable.Zip<TFirst, TSecond, TResult> Method (IQbservable<TFirst>, IEnumerable<TSecond>, Expression<Func<TFirst, TSecond, TResult>>)

Merges a queryable observable sequence and an enumerable sequence into one queryable observable sequence by using the selector function.

Namespace:  System.Reactive.Linq
Assembly:  System.Reactive.Providers (in System.Reactive.Providers.dll)

public static IQbservable<TResult> Zip<TFirst, TSecond, TResult>(
	this IQbservable<TFirst> first,
	IEnumerable<TSecond> second,
	Expression<Func<TFirst, TSecond, TResult>> resultSelector

Type Parameters


The first type.


The second type.


The type of result.


Type: System.Reactive.Linq.IQbservable<TFirst>
The first observable source.
Type: System.Collections.Generic.IEnumerable<TSecond>
The second enumerable source.
Type: System.Linq.Expressions.Expression<Func<TFirst, TSecond, TResult>>
The function to invoke for each consecutive pair of elements from the first and second source.

Return Value

Type: System.Reactive.Linq.IQbservable<TResult>
A queryable observable sequence containing the result of pairwise combining the elements of the first and second source using the specified result selector function.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IQbservable<TFirst>. When you use instance method syntax to call this method, omit the first parameter. For more information, see https://msdn.microsoft.com/en-us/library/bb384936(v=vs.103).aspx or https://msdn.microsoft.com/en-us/library/bb383977(v=vs.103).aspx.