cutie_smily
asked on
cana class extend a class which is jar and added to a classpath
I have to extend a class which is in different package or which is in server.jar. Is that possible?
I am using eclipse, it does say its not finding parent class.
I am using eclipse, it does say its not finding parent class.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Base class Animal
sub class cow
Animal a=new cow();
a.speak(); //it says Animal does not have speak method.
Doesn't it get from subclass ?
sub class cow
Animal a=new cow();
a.speak(); //it says Animal does not have speak method.
Doesn't it get from subclass ?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
>>Doesn't it get from subclass ?
If the method exist only in the subclass, there is no way the Animal class can point to that method which it not aware of, try object's comment.
If the method exist only in the subclass, there is no way the Animal class can point to that method which it not aware of, try object's comment.
ASKER