Showing posts with label extend keyword. Show all posts
Showing posts with label extend keyword. Show all posts

Tuesday, 21 January 2014

INHERITANCE BASICS

Basics of Inheritance in java

How to use extends keyword to inherit the super class

Inheritance is one of the key feature of Object Oriented Programming.There are three types of inheritance in java,they are Single Inheritance,Multilevel Inheritance and Hierarchical Inheritance.Inheritance provided mechanism that allowed a class to inherit property of another class.When a class extends another class it inherits all non-private members including fields and methods.For class inheritance, Java uses the keyword extends.