Skip to content

Instantly share code, notes, and snippets.

@carchrae
Created September 25, 2013 22:01
Show Gist options
  • Select an option

  • Save carchrae/6706664 to your computer and use it in GitHub Desktop.

Select an option

Save carchrae/6706664 to your computer and use it in GitHub Desktop.
Handler<Throwable> onError = new Handler<Throwable>(Throwable.class) {
@Override
public Throwable handle(Throwable value) {
value.printStackTrace();
return value;
}
};
Handler2<Throwable,String> onError2 = new Handler2<Throwable,String>(Throwable.class,String.class) {
@Override
public String handle(Throwable value) {
value.printStackTrace();
return String.valueOf(value);
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment