Class Count
Represents an operator that returns the count of the number of elements in an observable sequence.
The Count
operator collects all the values from the source sequence and emits a single value representing the total number of items. The single result value is emitted only when the source sequence terminates successfully.
public class Count : Combinator<int>
- Inheritance
-
Count
- Inherited Members
Methods
Process<TSource>(IObservable<TSource>)
Returns the count of the number of elements in an observable sequence.
public override IObservable<int> Process<TSource>(IObservable<TSource> source)
Parameters
source
IObservable<TSource>An observable sequence that contains elements to be counted.
Returns
- IObservable<int>
An observable sequence containing a single integer representing the total number of elements in the
source
sequence.
Type Parameters
TSource
The type of the elements in the
source
sequence.