Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Creating Observable

Creating Observable
We can create our own Observable by creating a Function that takes an observer parameter. The function will be passed to create the Observable. When someone subscribes to the observable, the function is called and returns the values emitted from the function.

In the below sample we create a function listGenerator, which takes an observer as a parameter and emit list values one at a time using .next().


This post first appeared on C# Guide, please read the originial post: here

Share the post

Creating Observable

×

Subscribe to C# Guide

Get updates delivered right to your inbox!

Thank you for your subscription

×