problema using a class hierarchy of your own


Problem:

(a) Using a class hierarchy of your own choosing, with at least TWO subclass levels, show

(i) the use of abstract and concrete forms of Java class and method in your hierarchy.

(ii) the role and purpose of constructors in each level of your hierarchy.

(iii) the meaning of 'polymorphism'.

In your answer, it should be clearly and fully explained how the proposed class structure is reflected in Java language and constructs.

(b) (i) Consider a class ‘Employee'. Given the knowledge we have of some of the different categories of employees like permanent salaried employees, commission employees, etc, write the sample code in Java to represent the class ‘Employee' such that it forms part of a hierarchy with subclasses.

Note: The class Employee should have different other classes inheriting from it at more than one level.

(ii) Use this same example to explain how we can simulate the concept of multiple inheritance in Java by using interfaces. Here we should make the ‘Employee' our interface.

Request for Solution File

Ask an Expert for Answer!!
C/C++ Programming: problema using a class hierarchy of your own
Reference No:- TGS0360671

Expected delivery within 24 Hours