Skip to content

)}

Observable.Latest(IObservable) method

Defined in

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

Applies to

netstandard2.0

public static IEnumerable<TSource> Latest<TSource>(this IObservable<TSource> source)

Summary: Returns an enumerable sequence whose enumeration returns the latest observed element in the source observable sequence. Enumerators on the resulting sequence will never produce the same element repeatedly, and will block until the next element becomes available.

Type parameters

NameDescription
TSourceThe type of the elements in the source sequence.

Parameters

NameTypeDescription
sourceIObservableSource observable sequence.

Returns: IEnumerable -- The enumerable sequence that returns the last sampled element upon each iteration and subsequently blocks until the next element in the observable source sequence becomes available.