Reactive Extensions meant specifically for implementations of IObservable<bool>
This documentation uses marble diagrams to explain the transformations of IObservable<bool>
. More on marble diagrams can be found in the documentation of ReactiveX.
This library has extension methods for logical operators:
This library also has extension methods for scheduling:
Returns an observable that stays true for a time span once the source observable turns back to false.
Returns an observable that emits true once the source observable emits true for a minimum time span.
Returns an observable that stays true for a maximum of time span. If the source observable emits false before the time has passed, the resulting observable also emits false.
Besides transformations, this library has extension methods that help with common cases of subscribing to implementations of IObservable<bool>
: SubscribeTrueFalse
, SubscribeFalse
and SubscribeTrue
.
boolObservable.SubscribeTrueFalse(
() => {
// Logic for when observable emits true.
},
() => {
// Logic for when observable emits false.
}
)