Question: java Write a class named Patient that has member variables for first name, middle name, last name, phone number, and the name and phone number
java
Write a class named Patient that has member variables for first name, middle name, last
name, phone number, and the name and phone number of an emergency contact.
The Patient class should have a constructor that accepts an argument for each member
variable. The Patient class should also have accessor and mutator methods for each member
variable.
Write a class named Procedure that represents a medical procedure performed on a patient.
The Procedure class has member variables for Patient, the name of procedure, date of
procedure, name of physician, and charge for procedure.
The Procedure class should have a constructor that accepts each state variable, and accessor
mutator methods for each state variable.
To test these classes, write a program that creates an instance of a Patient initialized with
data provided by the user and one or more Procedure classes representing procedures
performed on the patient. At the end of the data entry, use the classes you have created to
create a summary that displays the patient information, information about each procedure,
and the total charges for the patient. Display all costs with two digits after the decimal point.
The class diagrams for these two classes are:
Patient
firstName: String
middleName: String
lastName: String
phoneNumber: String
emergencyContact: String
String getFirstName
String getMiddleName
String getLastName
String getPhoneNumber
String getEmergencyContact
void setFirstNameString
void setMiddleNameString
void setLastNameString
void setPhoneNumberString
void setEmergencyContactString
Procedure
patientName: Patient
procedureName: String
procedureDate: Date
physicianName: String
procedureCost: double
Patient getPatient;
String getProcedureName;
Date getProcedureDate
String getPhysicianName;
double getProcedureCost;
void setPatientPatient
void setProcedureNameString
void setProcedureDateDate
void setPhysicianNameString
void setProcedureCostdouble
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
