Why do you get an "already been caught" exception when you place MyChildException before MyParentException? The exercise doesn't explain why you get this.
try {
throw new MyChildException();
} catch (MyParentException e) {
System.err.println("Caught MyParentException");
} catch (MyChildException e) { // Compile error expected
System.err.println("Caught MyChildtException");
}
TDR
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [email protected]
For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en
-~----------~----~----~----~------~----~------~--~---
- [java programming] LAB-1007 CatchingExceptionHierarc... Tanya Dina Ruttenberg
