- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Callback for use with
withIteratorWill be invoked with a Iterator<T>. The iterator will be closed when this callback returns.
iterator- iterator to be used only within scope of this callback
- The return value of the callback
X- optional exception thrown by the callback