From f9d3e991a608316794a0bacdc9c46eeb0fa01afb Mon Sep 17 00:00:00 2001 From: "David M. Gross" Date: Mon, 12 Oct 2015 11:06:05 -0700 Subject: [PATCH] enhance Observable.fromCallable javadoc --- src/main/java/rx/Observable.java | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/main/java/rx/Observable.java b/src/main/java/rx/Observable.java index a0d93ccacf..0a2ebab8ce 100644 --- a/src/main/java/rx/Observable.java +++ b/src/main/java/rx/Observable.java @@ -1251,22 +1251,26 @@ public final static Observable from(T[] array) { } /** - * Returns an Observable that invokes passed function and emits its result for each new Observer that subscribes. + * Returns an Observable that, when an observer subscribes to it, invokes a function you specify and then + * emits the value returned from that function. *

- * Allows you to defer execution of passed function until Observer subscribes to the Observable. - * It makes passed function "lazy". - * Result of the function invocation will be emitted by the Observable. + * + *

+ * This allows you to defer the execution of the function you specify untl an observer subscribes to the + * Observable. That is to say, it makes the function "lazy." *

*
Scheduler:
*
{@code fromCallable} does not operate by default on a particular {@link Scheduler}.
*
* * @param func - * function which execution should be deferred, it will be invoked when Observer will subscribe to the Observable + * a function, the execution of which should be deferred; {@code fromCallable} will invoke this + * function only when an observer subscribes to the Observable that {@code fromCallable} returns * @param * the type of the item emitted by the Observable * @return an Observable whose {@link Observer}s' subscriptions trigger an invocation of the given function * @see #defer(Func0) + * @since (if this graduates from Experimental/Beta to supported, replace this parenthetical with the release number) */ @Experimental public static Observable fromCallable(Callable func) {