In this final project, you will be pulling together all of the concepts from this course to create a model of a health-care facility. In particular, you will need to use your knowledge of:
You will need to create a few classes of your own, but you may also use any of the classes in the Java Standard Library and the LabTests.jar to support your program.
Create a model of a health-care facility. Your program will accept lists of patients and their illnesses, provide them with treatment if possible, and output reports of the work that was done.
Your program should have a main loop to handle each "day" of work at your facility. Each iteration of the loop will read in a group of patients that arrive on that day and assign them beds, nurses, and doctors as they become available. Your main loop should continue to run until instructed to stop by the user, or until an upper limit of "days of work" is reached (at least three days).
The specifics of the implementation and exact output are up to you, but your program must satisfy the following minimum requirements:
Your facility has a limited (fixed) number of beds. Each bed:
Before treatment, a patient must be:
To complete their treatment, the patient must be cared for by their doctor for a minimum of 2 "days" (2 iterations of the main program loop, including the day they arrive). Once they have been treated, they are dischared from the facility and their bed may be used by other patients.
Accepting and treating patients generates income for the facility. Specifically:
After your program has stopped accepting patients, it must report:
Your solution should show your mastery of lists (used as stacks and queues), searching, and sorting.
bonus Add features beyond the minimum requirements and make the program your own and earn bonus points! What other interesting reports could you add? What should your program do if your facility runs out of beds?
Your completed project should include a single main method class and as many supporting classes as necessary, stored within a single package named like LastnameFirstname_project. Compress the package directory into a ZIP archive and upload it to the D2L assignment.
The marks for this project are heavily weighted towards good coding practice and style. Your code for handling input, processing data, and showing output must be clearly separated from one another. Pay attention to your code formatting, make sure you have documented all public members using JavaDoc, and make sure you are using data structures and methods.
NOTE: This assignment is to be done individually. You can help one another with problems and questions, but in the end everyone must do their own work.
| Criteria | Marks |
|---|---|
| Programs compile and run without error | 2 |
| Good coding style | 2 |
| Task requirements met or exceeded | 2 |
| Total | 6 |