Question: Object Oriented Programming- 14011102-4 Lab #7 Complete the following tasks in Java within the lab time using NetBeans Task 1: Create class Employee with the

 Object Oriented Programming- 14011102-4 Lab #7 Complete the following tasks in

Object Oriented Programming- 14011102-4 Lab #7 Complete the following tasks in Java within the lab time using NetBeans Task 1: Create class Employee with the Employee ID and name as private data members. You must add any needed methods and constructors Task 2: Create class Department with the Department ID, name as data members.in addition to a list of the Employee's who work at the Department as a ArrayList from class Employee. Again all these data members must be declared private and you should add any needed methods or constructors. Task 3: Create class Company with a main method in it. In the main method create an ArrayList of Employees. Fill it with at least 5 Employee objects. Then print the Department information (Name, id and the list of employees) sorted by their ids. Hint: In order to sort the s of employee use Collections.sort( ListName)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

To complete the tasks youll need to create three Java classes Employee Department and Company Heres how you can structure these classes Task 1 Create ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!