code: public static <R> Func0<Observable<R>> toAsync(final Func0<? extends R> func, final Scheduler scheduler) {
          return new Func0<Observable<R>>() {
              @Override
              public Observable<R> call() {
                  return startCallable(func, scheduler);
              }
          };
      }
docs: Convert a synchronous function call into an asynchronous function call through an Observable.
  <p>
  <img width="640" src="https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/toAsync.s.png" alt="">
  
  @param <R> the result type
  @param func the function to convert
  @param scheduler the Scheduler used to call the {@code func}
  @return a function that returns an Observable that executes the {@code func} and emits its returned value
  @see <a href="https://github.com/ReactiveX/RxJava/wiki/Async-Operators#wiki-toasync-or-asyncaction-or-asyncfunc">RxJava Wiki: toAsync()</a>
  @see <a href="http://msdn.microsoft.com/en-us/library/hh211792.aspx">MSDN: Observable.ToAsync</a>