Skip to content

Instantly share code, notes, and snippets.

@mayuroks
Created August 15, 2018 14:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mayuroks/e5d9dc18770ee896fff79f9e528480a4 to your computer and use it in GitHub Desktop.
Save mayuroks/e5d9dc18770ee896fff79f9e528480a4 to your computer and use it in GitHub Desktop.
public class SchedulerProvider {
// UI thread
public static Scheduler ui() {
return AndroidSchedulers.mainThread();
}
// IO thread
public static Scheduler io() {
return Schedulers.io();
}
// Computation thread
public static Scheduler computation() {
return Schedulers.computation();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment