Skip to content

,System.Linq.Expressions.Expression{System.Func{--0,--0,--0}})} ,--1,System.Linq.Expressions.Expression{System.Func{--1,--0,--1}})}

Qbservable.Scan(IQbservable, Expression>) method

Defined in

Type: Qbservable Namespace: System.Reactive.Linq Assembly: System.Reactive.dll

Applies to

netstandard2.0

Overloads

  • 1. public static IQbservable<TSource> Scan<TSource>(this IQbservable<TSource> source, Expression<Func<TSource, TSource, TSource>> accumulator)
  • 2. public static IQbservable<TAccumulate> Scan<TSource, TAccumulate>(this IQbservable<TSource> source, TAccumulate seed, Expression<Func<TAccumulate, TSource, TAccumulate>> accumulator)

1. Overload

public static IQbservable<TSource> Scan<TSource>(this IQbservable<TSource> source, Expression<Func<TSource, TSource, TSource>> accumulator)

Summary: Applies an accumulator function over an observable sequence and returns each intermediate result. For aggregation behavior with no intermediate results, see Aggregate.

Type parameters

NameDescription
TSourceThe type of the elements in the source sequence and the result of the aggregation.

Parameters

NameTypeDescription
source[IQbservable](#An observable sequence to accumulate over.
accumulatorExpression>An accumulator function to be invoked on each element.

Returns: IQbservable -- An observable sequence containing the accumulated values.

Exceptions

TypeCondition
System.ArgumentNullExceptionsource or accumulator is null.

2. Overload

public static IQbservable<TAccumulate> Scan<TSource, TAccumulate>(this IQbservable<TSource> source, TAccumulate seed, Expression<Func<TAccumulate, TSource, TAccumulate>> accumulator)

Summary: Applies an accumulator function over an observable sequence and returns each intermediate result. The specified seed value is used as the initial accumulator value. For aggregation behavior with no intermediate results, see Aggregate.

Type parameters

NameDescription
TSourceThe type of the elements in the source sequence.
TAccumulateThe type of the result of the aggregation.

Parameters

NameTypeDescription
source[IQbservable](#An observable sequence to accumulate over.
seedTAccumulateThe initial accumulator value.
accumulatorExpression>An accumulator function to be invoked on each element.

Returns: IQbservable -- An observable sequence containing the accumulated values.

Exceptions

TypeCondition
System.ArgumentNullExceptionsource or accumulator is null.