?
_.-=
Hi!
Whats the difference between "implements" and "extends"?
Thanks to all.
-ReAdY-
Whats the difference between "implements" and "extends"?
Thanks to all.
-ReAdY-
_.-= said:Whats the difference between "implements" and "extends"?
_.-= said:Hi!
Whats the difference between "implements" and "extends"?
Thanks to all.
-ReAdY-
Whats the difference between "implements" and "extends"?
Daniel Sjöblom said:Well, you implement interfaces and you extend classes.
_.-= said:Since no one happened to answer my question, I thought I'd answer it myself
now that I've figured it out.
Joona said:"No one happened to answer your question"? Then what do you call the
four answers you got from various people?
Since no one happened to answer my question, I thought I'd answer it myself
now that I've figured it out.
Manish Jethani said:But Java is now old enough that people will not answer basic
questions like the difference between "implements" and "extends".
_.-= said:Since no one happened to answer my question, I thought I'd answer it myself
now that I've figured it out.
When you "extend" a class, any methods that you write with the same name
will override the parent class' method.
When you "implement" a class, the parent class had nothing more than the
method definition (i.e. there was no code in the method) so, in effect, all
you are doing is adding your own method code to what was just a method
declaration and therefore not overriding the parent methods.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.