In a class hierarchy, when the subclass method has the same name and signature as its superclass method, the method in the subclass is said to override the method in the superclass. This phenomenon is known as method overriding.
An example of method overriding is given below:
void show() { }
}
class Subclass extends Superclass {
void show() { }
}
Here, show() is the overridden method.
- Download practice question and study guide for master-ciw-enterprise-developer for exam.
- Click here to download scbcd test study guide and practice question.
- Click here to get free scdjws SCDJWS exam practice questions.
- Download practice question and study guide for scja for exam.
- Download free practice test for SUN SCJP exam.
- Get certified in first attempt download scjp-5-0 - SCJP 5/6 simulation.
- Download free practice test for SUN SCMAD exam.
- Pass SUN scwcd - SCWCD
- Get certified in first attempt download CX310-019 - SCJA simulation.
- Pass SUN CX310-036 - SCJP 1.4 Upgrade
- Get certified in first attempt download CX310-055 - Java 5.0 simulation.
- Click here to get free CX310-065 SCJP 6.0 exam practice questions.
- Click here to get free CX310-110 SCMAD Mobile Application Developer exam practice questions.
If you like this article, please leave a comment or subscribe this blog via RSS or via e-mail, Bookmark and share through your network. Click the AddThis button below. Thanks.