Question

In: Computer Science

1. A doctor’s office has at least 2 patients but can have up to 30 patients....

1. A doctor’s office has at least 2 patients but can have up to 30 patients. All patients have names, number of doctor’s visits, and total copayments for the year so far. After each visit, you need to be able to update each patient’s number of doctor’s visits and total copayments for the year.

a. Create the UML for the class diagram for patients.

b. Create the Java implementation for patients.

Solutions

Expert Solution

Patients.uml

patients.java

/**
* This is the implementation of patients entity
*
* @author xyz
*
*/
public class Patient {
   private String name;
   private int numberOfVisits;
   private double totalCoPayment;

   public Patient() {
       super();
   }

   /**
   * Increment patient's visit count on each visit by one
   */
   public void incrementVisitCount() {
       this.numberOfVisits++;
   }

   /**
   * Update total co-payment amount paid by patient
   *
   * @param amount
   */
   public void updateTotalCopayment(double amount) {
       this.totalCoPayment += amount;
   }

   public String getName() {
       return name;
   }

   public void setName(String name) {
       this.name = name;
   }

   public int getNumberOfVisits() {
       return numberOfVisits;
   }

   public void setNumberOfVisits(int numberOfVisits) {
       this.numberOfVisits = numberOfVisits;
   }

   public double getTotalCoPayment() {
       return totalCoPayment;
   }

   public void setTotalCoPayment(double totalCoPayment) {
       this.totalCoPayment = totalCoPayment;
   }
}

Please let me know if you have any question on this?


Related Solutions

At a doctor’s office, patients are called in from the waiting room according to a Poisson...
At a doctor’s office, patients are called in from the waiting room according to a Poisson distribution with an average of 2 patients every 15 minutes. a) On average, how many patients are called in to see the doctor between 3:15pm- 4:15pm? b) On average, how long does it take for a patient to finish their appointment with the doctor (seeing the doctor, not including the waiting time)? c) You are at the doctor’s office and there are 3 patients...
Q5. The laser at the doctor’s office is graduated in 1/20th of an inch intervals. It...
Q5. The laser at the doctor’s office is graduated in 1/20th of an inch intervals. It measures your height. A tape measure instead is graduated in 1/8th of an inch intervals. Which one is more accurate? Which one is more precise? Illustrate your rationale with a few examples of hypothetically measured heights using the two instruments. [20]
a)A sample of 30 patients in a doctor's office showed that they had to wait an...
a)A sample of 30 patients in a doctor's office showed that they had to wait an average of 35 minutes before they could see the doctor. The sample standard deviation is 9 minutes. Assume the population of waiting times is normally distributed.At 90% confidence, compute the margin of error. b)Consider the population of electric usage per month for houses. The standard deviation of this population is 119 kilowatt-hours. What is the smallest sample size to provide a 90% confidence interval...
1. General Survey & Vital Signs You went to the living room of the doctor’s office....
1. General Survey & Vital Signs You went to the living room of the doctor’s office. Your patient is sitting down, you call her name. So far, you two have made it to the intake room. You are going to perform the intake on a 7 month old infant. He is still in his mother’s lap. What are the general survey information may you collect from the patient encounter so far, before speaking to the patient’s mother? 2. Lubin Janot,...
CRITICALTHINKING: Chris has come to the doctor’s office in a somewhat agitated state. Several months ago,...
CRITICALTHINKING: Chris has come to the doctor’s office in a somewhat agitated state. Several months ago, his wife noticed a small, dark spot in the skin on his lower back. His wife is worried that the spot may indicate skin cancer. Initially, Chris chose to ignore it. But recently his wife has noticed the spot has grown. In addition, when she inspected it and squeezed it, a thick, white material was released from the spot. Now Chris is worried. The...
1.You went to the living room of the doctor’s office. Your patient is sitting down, you...
1.You went to the living room of the doctor’s office. Your patient is sitting down, you call her name. So far, you two have made it to the intake room. Contrast the most commonly used way of measuring body temperature versus the most accurate. 2. Lubin Janot, a 75 year-old male, had shingles since last year. However, he has been going to the doctor for the same pain that developed on his rib cage on the right. Any little touch...
Suppose we have 30-day follow-up data on 350 ischemic stroke patients and want to investigate whether...
Suppose we have 30-day follow-up data on 350 ischemic stroke patients and want to investigate whether the risk of recurrent stroke and/or death (RD) depends on the type of stroke. You classify patients according to initial stroke type-having a cerebral embolism (CE = 1) or not (CE = 0). Analysis of Maximum Likelihood Estimates                                                         Standard         Wald Parameter             DF      Estimate      Error          Chi-Square      Pr>ChiSq Intercept               1        -2.8034         0.5149          29.639          <0.0001 CE                          1        1.8651          0.6479          8.2874          0.0040 Odds Ratio Estimates...
The customer has asked to have a customer representative office set up in the same building...
The customer has asked to have a customer representative office set up in the same building as the project office. As a project manager, you put the customer’s office at the opposite end of the building from where you are, and on a different floor. The customer states that he wants his office next to yours. Should this be permitted, and, if so, under what conditions?
1. A doctor’s office wants to predict Body fat based on tight fat content, mid-arm circumference,...
1. A doctor’s office wants to predict Body fat based on tight fat content, mid-arm circumference, and triceps fat electric conductivity. A research was conducted and the following information was obtained. Fat Triceps Midarm Thigh 11.9 19.5 29.1 43.1 22.8 24.7 28.2 49.8 18.7 30.7 37 51.9 20.1 29.8 31.1 54.3 12.9 19.1 30.9 42.2 21.7 25.6 23.7 53.9 27.1 31.4 27.6 58.5 25.4 27.9 30.6 52.1 21.3 22.1 23.2 49.9 19.3 25.5 24.8 53.5 25.4 31.1 30 56.6 27.2...
Case #1 A 24-year old female automotive technician presents herself at the doctor’s office. She complains...
Case #1 A 24-year old female automotive technician presents herself at the doctor’s office. She complains of fever and of pain in her left hand. On physical examination, the patient had a deep wound on her left palm that was oozing pus. She had purplish, red streaks running up her left arm. She had enlarged lymph nodes at the elbow and under her arm. The patient’s skin was warm and dry. In her history, the patient had punctured her left...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT