Hi Cyril,
This is an example of
polymorphism - method overriding. In
Java when a subclass over-rides a superclass' method, the restriction on the throws clause is: The child method (in the sub class) cannot throw any "extra" exception that is not a child of any of the exceptions thrown by the parent method.
Thus, the exceptions in the child method should :
1. Either be in the list of exceptions thrown by the parent method
2. Or be a sub class of any of the exceptions listed in the parent method
3. Java allows child methods to throw a subset of the exceptions thrown by the parent method.
Ciao,
GSS
SCJP, SCJD, SCWCD 1.3, SCWCD 1.4, SCBCD