代写C++基础作业,根据UML图完成相应的Class.RequirementConsider the class hierarchy shown in this figure:Create the super abstract class “Employee” that has the following instance variables, constructor, and methods( you may need to add more methods):a) nameb) date_of_birthc) starting_dated) ssne) phone_numberf) Constructorg) set/get methodsh) toString methodCreate the sub class “Hourly_Based_Employee” that is derived from the super class“Employee” and has the following instance variables, constructor, and methods:a) nameb) date_of_birthc) starting_dated) ssne) phone_numberf) per_Hourg) hoursh) Constructori) set/get methodsj) compute_Salary that is based on the hours* per_hourk) toString methodCreate the sub class “Salary_Based_Employee” that is derived from the super class“Employee” and has the following instance variables, constructor, and methods:a) nameb) date_of_birthc) starting_dated) ssne) phone_numberf) salaryg) Constructorh) set/get methodsi) compute_salary 代写CSCI111 Employee调试C/C++程序、C/C++实验代写that is based on his salaryj) toString methodk)Create the sub class “Manager_Employee” that is derived from the class“Salary_Based_Employee” and has the following instance variables, constructor, and methods:a) nameb) date_of_birthc) starting_dated) ssne) phone_numberf) salaryg) bonush) Constructori) set/get methodsj) compute_salary that is based on his salary and bonusk) toString methodCreate the “Testing” class that has the main method and does the following:a) Are you able to create an object of Employee class?b) Use the constructor to create object of Hourly_Based_Employee class.c) Use the constructor to create object of Salary_Based_Employee class.d) Use the constructor to create object of Manager_Employee class.e) Define three elements array of “Employee”.f) Let each element in the array refer to objects created in b, c, and dg) Call compute_salary and toString using objects created in b, c, and dh) Call compute_salary and toString using array elements defined in f. You need to design the abstract class in a way that allow you to call this method.i) What is the difference between results obtained from g and h.转自:http://www.3daixie.com/contents/11/3444.html
网友评论