Skip to content
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

Improve BlockingIterable javadoc #2010

Merged
merged 1 commit into from Dec 14, 2021

Commits on Dec 10, 2021

  1. Improve BlockingIterable javadoc

    Motivation:
    
    `BlockingIterable` and `BlockingIterator` methods can throw
    `InterruptedException` using the sneaky-throw mechanism. The reason for
    it is that implementations rely on `BlockingQueue` which may be
    interrupted. However, as `BlockingIterator` extends `Iterator` from the
    JDK, its' method signatures don't list any checked exception. Therefore
    it would be inconsistent to have some methods declare checked
    exceptions, while the overridden ones not.
    
    Modification:
    
    Add javadoc notes to all methods that can throw `InterruptedException`
    to `BlockingIterable` and `BlockingIterator`.
    
    Result:
    
    The runtime behavior is better described via javadoc.
    Dariusz Jędrzejczyk committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    40d3d89 View commit details
    Browse the repository at this point in the history