aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Overriding and Exceptions Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Overriding and Exceptions" Watch "Overriding and Exceptions" New topic
Author

Overriding and Exceptions

Deepali Pate
Ranch Hand

Joined: Mar 20, 2002
Posts: 114
Someone clarify to me if this is right.
Overridden methods cannot add new checked exceptions.
But is it right that when it is overriding a abstract method it can add new checked exceptions.
Jamal Hasanov
Ranch Hand

Joined: Jan 08, 2002
Posts: 411
Hi, Deepali
Abstract method can be implemented, not overridden...
Jamal Hasanov
www.j-think.com
Deepali Pate
Ranch Hand

Joined: Mar 20, 2002
Posts: 114
Well ya thats right thnx for correcting my blunder.
Anthony Villanueva
Ranch Hand

Joined: Mar 22, 2002
Posts: 1055

Overridden methods cannot add new checked exceptions.

Yes.

But is it right that when it is overriding a abstract method it can add new checked exceptions.

No. See below:
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Overriding and Exceptions