 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
| • |
In
the previous example, we did not use the value of the
|
|
|
throw
operand in the catch blocks so we did not need to
|
|
|
specify
an identifier in the catch block's argument list, just
|
|
|
the
type.
|
|
| • |
If
we want to catch any exception independent of the type,
|
|
we
can use the ellipses (...) as the type of a catch block.
|
|
| • |
If a
catch block using ellipses is specified, it must be the
|
|
|
last
catch block in the sequence and is guaranteed to catch
|
|
|
exceptions
of any type.
|
|
| • |
Of
course, if a catch block for a particular type precedes a
|
|
|
catch
block using the ellipses, then it will catch an
|
|
|
exception
of that particular type before the catch block
|
|
|
with
the ellipses.
|
|