Skip to content

Instantly share code, notes, and snippets.

@jwkidd3
Created January 18, 2017 21:31
Show Gist options
  • Save jwkidd3/75bf0196c83f90fede3cbfae605d7af3 to your computer and use it in GitHub Desktop.
Save jwkidd3/75bf0196c83f90fede3cbfae605d7af3 to your computer and use it in GitHub Desktop.
Integer[] is = {1,2,3};
Observable<Integer> values = Observable.from(is);
Subscription subscription = values.subscribe(
v -> System.out.println("Received: " + v),
e -> System.out.println("Error: " + e),
() -> System.out.println("Completed")
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment