What restrictions are placed on method overloading and
method overriding?
Answer Posted / muthusenthil
Restriction imposed on Method Overloading are
a) should done with in a same class.
b) it should have same name of overloading method.
c) its arguments or parameter should be different
irrespective of return type.
Restriction imposed on Method Overriding are
a) should done with its derived class
b) should have same name of parent method and arguments
too.
| Is This Answer Correct ? | 34 Yes | 7 No |
Post New Answer View All Answers
Can a static class implement an interface?
How to create a fecelet view?
Convert Binary tree to linked list.
What is the difference between actual and formal parameters?
What is a heavyweight component?
What is the current version of java?
What about interrupt() method of thread class ?
what is singleton class in java?
Which methods cannot be overridden in java?
Can we define a package statement after the import statement in java?
What are the two ways to create a thread?
Describe string intern() methodology
What is a website container?
Does constructor creates the object ?
What are the types of exceptions?