Skip to content

Instantly share code, notes, and snippets.

@kaushikgopal
Created July 11, 2015 22:28
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 kaushikgopal/76628d4a10eb82f55aad to your computer and use it in GitHub Desktop.
Save kaushikgopal/76628d4a10eb82f55aad to your computer and use it in GitHub Desktop.
warm observable snippet for a blog post
Observable
.interval(1, TimeUnit.SECONDS)
.map(new Func1<Long, Integer>() {
@Override
public Integer call(Long aLong) {
return aLong.intValue();
}
})
.take(20)
.share();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment