singleFromFunction

fun <T> singleFromFunction(func: () -> T): Single<T>

Returns a Single that emits the value returned by the func shared function.

Please refer to the corresponding RxJava document.