INDIA : +91-995-314-1035                                              USA: +1-628-888-9041

                 Rights Reserved - VARCHAS IT SYSTEMS PVT.LTD 

                  Terms and Conditions

privacy policy right reserved research paper

Object Oriented Design and Development
Attached, you will find a fully written main() method that instantiates 3 objects of type Home. You are not to alter the code in this method. However, you may comment out lines as you work through the process. When complete, the program will successfully run providing the output listed below. Please make sure that you deliver the main method back to me intact.
To complete this assignment, you are to develop the Home class that is consumed by the code in the provided main() method. The Home class has the following characteristics:
 Private instance fields:
1. Address of type string
2. City of type string
3. State of type string
4. Zip of type string
5. Age of type integer
6. Number of Square Feet of type integer
7. Value of the home that is capable of holding decimal values
 Constructors:
1. A default No-Arg Constructor – this constructor sets all private instance fields to either empty string or 0.
2. A constructor that accepts as parameters Address, City, State, and Zip. The private instance fields will be set using these parameters. All other instance fields are set to zero (0).
3. A constructor that accepts as parameters Address, City, State, Zip, Age, Number of square feet, and value of the home. All of the private instance fields will be set using these parameters.
 Methods:
1. Public methods used to get and set each (ALL) of the private instance fields.
2. A public method, “outputInfo”, that returns a formatted string for each instantiated object as depicted below.
Output:
Address: 1200 Covington Ave
City: Piqua
State: Ohio
ZipCode 45356
Age of the home: 71 years
Number of Square Feet: 1657
Value of the home: $149900.00
Address: 250 Hillcrest Ct.
City: Sidney
State: Ohio
ZipCode 45365
Age of the home: 61 years
Number of Square Feet: 2176
Value of the home: $175900.00
Address: 1801 Cumberland Ave.
City: Sidney
State: Ohio
ZipCode 45356
Age of the home: 1 years
Number of Square Feet: 1340
Value of the home: $179900.00
Once you have completed the assignment, “zip” up your Home Class along with the class that contains the main() method provided. Both of these classes should be within the same Java package. Don't forget to put the following information in your submitted file as code comments: Your name Project Name Date Description of Program Developed and Compiled using // Doug Streitenberger // Chapter 6 Programming Assignment // Today’s Date // This program... // Developed and compiled using NetBeans Finally, click on the link to attach the completed .zip file. When you have finished attaching the file, don't forget to press the SUBMIT button.

 

java program to update

package oophome;
public class OOPHome {
public static void main(String[] args) {
// these are merely random homes that I found
// for sale on the internet as I was writing this code
// Information on these homes is not accurate
Home home1 = new Home();
home1.setAddress("1200 Covington Ave");
home1.setCity("Piqua");
home1.setState("Ohio");
home1.setZip("45356");
home1.setAge(71);
home1.setNumberSquareFeet(1657);
home1.setWorth(149900);
System.out.println(home1.outputInfo());
Home home2 = new Home("250 Hillcrest Ct.", "Sidney", "Ohio", "45365");
home2.setAge(61);
home2.setNumberSquareFeet(2176);
home2.setWorth(175900);
System.out.println(home2.outputInfo());
Home home3 = new Home("1801 Cumberland Ave.", "Sidney", "Ohio", "45356",
1, 1340, 179900);
System.out.println(home3.outputInfo());
}
}

Object Oriented Design and Development Java

$40.00Price