-
Notifications
You must be signed in to change notification settings - Fork 168
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Seq.peekThrowable(Consumer<Throwable>) #91
Comments
@lukaseder, do you have any thoughts on this? I believe, |
I haven't thought all situations through yet. I'm afraid that it might not be a very good idea to implement such a method in a |
An implementation suggestion was made by @tlinkowski in #299 |
Implemented through #315 |
There is currently no fluent way of handling exceptions in a
Stream
. WhileStream
extendsAutoCloseable
and provides anonClose(Runnable)
hook for actions that are to be taken before the actual closing, there is no such thing for exceptions.We should add an
peekThrowable(Consumer<Throwable>)
hook that allowsConsumers
to be added to consume all sorts of exceptions that may occur.The actual API is not yet fully defined and may differ, e.g. by taking inspiration from the
Try
monadThe text was updated successfully, but these errors were encountered: