Using checked exceptions forces method callers to deal with errors, either by propagating them or by handling them. Throwing exceptions makes them
fully part of the API of the method.
But to keep the complexity for callers reasonable, methods should not throw more than one kind of checked exception.
Noncompliant code example
public void delete() throws IOException, SQLException { // Noncompliant
/* ... */
}
Compliant solution
public void delete() throws SomeApplicationLevelException {
/* ... */
}
Exceptions
Overriding methods are not checked by this rule and are allowed to throw several checked exceptions.