A little bit confusion about enthuware.ocajp.i.v8.2.1478

All the posts and topics that contain only an error report will be moved here after the error is corrected. This is to ensure that when users view a question in ETS Viewer, the "Discuss" button will not indicate the presence of a discussion that adds no value to the question.

Moderators: Site Manager, fjwalraven

Post Reply
klhlubek
Posts: 7
Joined: Mon Oct 12, 2015 9:58 am
Contact:

A little bit confusion about enthuware.ocajp.i.v8.2.1478

Post by klhlubek »

It will compile if getId method in PremiumAccount is replaced with: public String getId(){ super.getId(); }
You cannot use super keyword to call a method defined in the super interface.
Yes, in this context it is right, but it would be surely better if you write, that abstract methods can not have a body, because this would be the general problem in this question. ( But this is only a tipp from myself )

admin
Site Admin
Posts: 10389
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: A little bit confusion about enthuware.ocajp.i.v8.2.1478

Post by admin »

Explanation has been updated to make it clearer.
thank you for your feedback!

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest