need help writing and fomatting pseudocode rom java code using conditional statements if, then else else if etc

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

need help writing and fomatting pseudocode rom java code using conditional statements if, then else else if etc  

/**
 * 
 */
 
/**
 * @author bernadettecam_snhu
 *
 */
public class Pet {
    // Attributes
    /* Instance variables are private. This means that only the object of the class can access 
* the values of the private data. */
    private String petType;
private String petName;
    private int petAge;
private int dogSpaces;
private int catSpaces;
private int daysStay;
private double amountDue;
 
    /**
* @param args
*/
    /* Constructor declaration of class with parameters. 
* Constructors are public and contain the same name as the class. */
    public Pet(String petType, String petName, int dogSpaces, int catSpaces, int petAge, int daysStay, double amountDue) {
        this.petType = petType;
        this.petName = petName;
        this.petAge = petAge;
        this.dogSpaces = dogSpaces;
        this.catSpaces = catSpaces;
        this.daysStay = daysStay;
        this.amountDue = amountDue;
    }
 
    // Accessor methods
    /* Getters; because our instance variables are private, any variable
* or object that attempts to access these values can only do so through public methods. */
    /**
    * @return the petype. The type of pet (e.g., dog, cat).
    */
    public String getPetType() {
return petType;
}
 
/**
 * @return the petName. The name of the pet.
 */
public String getPetName() {
return petName;
}
 
/**
 * @return the petAge. The age of the pet.
 */
public int getPetAge() {
return petAge;
}
 
/**
 * @return the dogSpaces. The number of available dog spaces.
 */
public int getDogSpaces() {
return dogSpaces;
}
 
 
/**
 * @return the catSpaces. The number of available cat spaces.
 */
public int getCatSpaces() {
return catSpaces;
}
 
/**
 * @return the daysStay The number of days the pet is staying.
 */
public int getDaysStay() {
return daysStay;
}
 
/**
 * @return the amountDue. The amount due for pet stay.
 */
public double getAmountDue() {
return amountDue;
}
 
 
    // Mutator methods
    /* Setters with parameters. The job of a setter is to set
* or change the value of the instance variables. */
    /**
 * @param petType 
 *the petType to set
 */
    public void setPetType(String petType) {
this.petType = petType;
}
 
/**
 * @param petName 
 *the petName to set
 */
public void setPetName(String petName) {
this.petName = petName;
}
 
/**
 * @param petAge 
 *the petAge to set
 */
public void setPetAge(int petAge) {
this.petAge = petAge;
}
 
/**
 * @param dogSpaces 
 *the dogSpaces to set
 */
 
public void setDogSpaces(int dogSpaces) {
this.dogSpaces = dogSpaces;
}
 
/**
 * @param catSpaces 
 *the catSpaces to set
 */
 
public void setCatSpaces(int catSpaces) {
this.catSpaces = catSpaces;
}
 
/**
 * @param daysStay 
 *the daysStay to set
 */
 
public void setDaysStay(int daysStay) {
this.daysStay = daysStay;
}
 
/**
 * @param amountDue 
 *the amountDue to set
 */
 
public void setAmountDue(double amountDue) {
this.amountDue = amountDue;
}
}

 

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 6 steps with 7 images

Blurred answer
Knowledge Booster
Structure chart
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education