This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
The overriding method must NOT throw checked exceptions that are new
or broader than those declared by the overridden method. For example, a
method that declares a FileNotFoundException cannot be overridden by a
method that declares a SQLException, Exception, or any other non-runtime
exception unless it's a subclass of FileNotFoundException
I have the following code which compiles fine, going against the quote above, however, if access modifiers are changed to public then it does not compile fine as stated in the quote above.
My question is that if I have private access modifiers, is the eat() method still being overridden? and if so, why don't I get an error.