747
1 Replies
Ruby
other
java
java
• The Hospital has several employees and each one of them has an ID (int), name (string), address (string), mobile phone number (string), email (string) and salary (double) with suitable data types. • The employees are divided into: - Administration staff: who have in addition to the previous information their position (string). - Doctor: who have also a rank (string) and specialty (string). • The Hospital also has a set of patients. Each patient is identified by his ID (int), name (string), address (string), mobile phone number (string), email (string), type (A or B) (char) and a set of hospital services (vector or arraylist). • The Hospital has a set of services to be provided to the patients. Each service is identified by ID (int), name (string) and price (double). The patient who is from type A will have a discount 25% of the service price. Assume that all doctors could provide all possible services. • Every patient could be treated by one doctor and every doctor could treat zero or more patients • Each patient receives one or more services from the doctor who treats him. The project requirements: • You will need to create all the needed Java classes with all the required information. • You have to apply all the OOP (Object Oriented Programming) concepts that we have covered in this module (i.e. inheritance, polymorphism, interface, UML, exception handling and collections) • Include a Microsoft Word document FILE (name it as readme.doc) that includes several screenshots of your Netbeans IDE application GUI interface as well as the output screenshot results. The document should also include a UML class diagram of all the classes, associations and multiplicity (cardinality) among these classes. Provide all assumptions that you have made during design and implementation. • Include the whole Netbeans Java project FOLDER with all source codes. Write as much comments as possible to document your source codes. At the end, you will need to create a testing class (e.g. Hospital.java) with a static main() method with the following requirements: • It must have initial fixed collections of working staff (at least 3 administration staffs and 2 doctors) • The project will start by reading a name. If the name is in the administration staff collection, the program will continue. If it is not, the program will ask for a name again. • The program will print a selection screen were the administrative staff can choose the operation he/she wants to perform. The selection screen will be repeated after each selection until the staff type the number 9 to exit the program: 1. Add a doctor (by providing all her/his information) 2. Add a service (by providing all its information) 3. Add a patient (by providing all her/his information) including all received services IDs (entered by point 2 above) 4. Print all doctors information 5. Print all patients information 6. Display specific doctor data (by reading doctor ID by the user) 7. Display specific patient data (by reading patient ID by the user) 8. Print a specific patient’s bill (by reading the patient ID by the user and then calculating the total price for all services provided for this patient (could be more than one service for each patient) 9. Exit the program • You need to create, use and print a custom exception called DuplicatePateientIdException that should be thrown when the admin tries to add a new patient using existing patient ID. The message of the exception should be read as “Invalid patient ID. This patient ID is already used”
Please move your assignment task to the Jobs section. Thanks.