Question
Put your name in PHP comments The application should contain nine files: 1. The payable.class.php file contains the interface, which is implemented by Employee and
Put your name in PHP comments The application should contain nine files:
1. The payable.class.php file contains the interface, which is implemented by Employee and Invoice classes.
2. The invoice.class.php file contains the Invoice class, which implements the Payable interface. The class also contains a static attribute and method that keep track of number of Invoice objects created in the system.
3. The employee.class.php file contains an abstract, base class named Employee. One of the attributes of the class is an object of Person. This demonstrates one of the three relationship types among classes: composition. This class also contains a static attribute and method that keep track of a number of Employee objects created in the system.
4. The person.class.php file contains the Person class.
5. The manager.class.php file contains the Manager class. This class inherits from the Employee class.
6. The executive_manager.class.php file contains the ExecutiveManager class, which inherits from the Manager class.
7. The sales_person.class.php file contains the SalesPerson class, which also inherits from the Employee class.
8. The secretary.class.php contains the class named Secretary, which inherits from the Employee class.
9. The test_payable.php contains a client program. The program tests all classes in the Payable class hierarchy. Make sure polymorphism is demonstrated in this file. The Web page displays string representation of each object type in the class hierarchy and the number of Invoice and Employee objects
(interface) Payable Invoice part_name: string - price: float - quantity: integer - invoice_count: integer + getPaymentAmount: float + toString: string Person (abstract) Employee - first_name:string - last_name: string - gender:string - ssn: string + __construct + getPartName: string + getQuantity: integer - getPrice: float + getPaymentAmount: float + getinvoiceCount: integer +toString: string - person: Person emp_id:integer -year_of_services: integer - emp_count: integer +__construct + getFirstName: string + getLastName: string + getGender, string + getSSN: string + toString: string +_construct + getPerson: Person +getEmplo: integer getYears: integer +getEmpCount: integer + toString: string Manager Salesperson Secretary - wage: float - hours: integer - department: string salary, float - sales: float commission_rate: float +_construct - getWage: float + getHours: integer + getPaymentAmount: float + toString: string + _construct + getDepartment: string + getSalary: string + getPayment Amount: float + toString: string + construct getSales: float +getCommission Rate: float + getPaymentAmount: float toString: string Executive Manager bonus + -construct + getBonus: float + getPayment Amount: float +toString: string (interface) Payable Invoice part_name: string - price: float - quantity: integer - invoice_count: integer + getPaymentAmount: float + toString: string Person (abstract) Employee - first_name:string - last_name: string - gender:string - ssn: string + __construct + getPartName: string + getQuantity: integer - getPrice: float + getPaymentAmount: float + getinvoiceCount: integer +toString: string - person: Person emp_id:integer -year_of_services: integer - emp_count: integer +__construct + getFirstName: string + getLastName: string + getGender, string + getSSN: string + toString: string +_construct + getPerson: Person +getEmplo: integer getYears: integer +getEmpCount: integer + toString: string Manager Salesperson Secretary - wage: float - hours: integer - department: string salary, float - sales: float commission_rate: float +_construct - getWage: float + getHours: integer + getPaymentAmount: float + toString: string + _construct + getDepartment: string + getSalary: string + getPayment Amount: float + toString: string + construct getSales: float +getCommission Rate: float + getPaymentAmount: float toString: string Executive Manager bonus + -construct + getBonus: float + getPayment Amount: float +toString: stringStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started