A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Joined: Feb 18, 2004
Mar 22, 2004 08:35:00
I am just a bigginer,so maybe my question is a little stupid.
Dose overload only happen in one class,or just like override,one child class can overload it's parent class's method?
Joined: Mar 16, 2004
Mar 22, 2004 09:03:00
You overload a method for the same type of object. If B extends A, then B is a type of A. So you can overload a method in B that exists in A, assuming the method is not private.
I agree. Here's the link:
subject: About overload
static variables and methods..
Why Dynamic Method dispatch is called dynamic polymorphism?
Method Overloading & Method Overriding
Ovveriding Static Method.
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015