What is the catch or declare rule?

What will be an ideal response?

The catch or declare rule states that checked exceptions that might be thrown when a
method is invoked must be accounted for in one of two ways:
1. The possible exception can be caught in a catch block within the method definition.
2. The possible exception can be declared at the start of the method definition by placing the
exception class name in the throws clause (and letting whoever uses the method worry about
how to handle the exception.

Computer Science & Information Technology

You might also like to view...

Each Outlook folder displays the items it contains in a layout called a(n) ____.

A. arrangement B. view C. list D. collection

Computer Science & Information Technology

Rebecca and Lucy are supervising the installation of new software on their company's computers.  To begin the software installation process, Lucy tells Rebecca to click on a compressed file with any of the following extensions EXCEPT _____.

A. .exe B. .xls C. .zip D. .msi

Computer Science & Information Technology