Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please help with this program using Java. I am uncertain how to save the file with the animal information and then use it. Thank you.

Please help with this program using Java. I am uncertain how to save the file with the animal information and then use it. Thank you. image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
Concepts: Classes and objects, inheritance The purpose of this project is to give students exposure to object oriented design and programming using classes and polymorphism in a realistic application that involves arrays of objects and sorting arrays containing objects. You will write several classes for this program. Please submit all classes in one file. The name of the physical program file submitted commonLab. Assignment: A veterinarian services many pets and their owners. As new pets are added to the population of pets being serviced, their information is entered into a flat text file. Each month, the vet requests a listing of all pets sorted by their outstanding bill balance. You have to write a program to produce a report of animals and their owners sorted by their outstanding bill balances from the data in the flat text file. Below is a description of the information on the text file: . The first entry is the number of animals on the file (numeric) . The fields below repeat for each animal: o Owner name (String) o Birth year (numeric) o Bill balance (numeric) o Species (String) o Special feature (numeric or String) The animals serviced by the veterinarian are of two types: mammals and non-mammals. For a mammal the special feature field on the flat file is the number of legs of the animal (numeric). For a non-mammal the special feature field is the blood type, warm-blooded or cold-blooded (String). Program requirements and grading From the information provided, write a solution that includes the following: .A suitable inheritance hierarchy which represents the pets serviced by the veterinarian. It is up to you how to design the inheritance hierarchy. I suggest an Animal class and appropriate subclasses. For all classes include the following: . o Instance variables Constructors Accessor and mutator methods o o Suitable toString) methods Concepts: Classes and objects, inheritance The purpose of this project is to give students exposure to object oriented design and programming using classes and polymorphism in a realistic application that involves arrays of objects and sorting arrays containing objects. You will write several classes for this program. Please submit all classes in one file. The name of the physical program file submitted commonLab. Assignment: A veterinarian services many pets and their owners. As new pets are added to the population of pets being serviced, their information is entered into a flat text file. Each month, the vet requests a listing of all pets sorted by their outstanding bill balance. You have to write a program to produce a report of animals and their owners sorted by their outstanding bill balances from the data in the flat text file. Below is a description of the information on the text file: . The first entry is the number of animals on the file (numeric) . The fields below repeat for each animal: o Owner name (String) o Birth year (numeric) o Bill balance (numeric) o Species (String) o Special feature (numeric or String) The animals serviced by the veterinarian are of two types: mammals and non-mammals. For a mammal the special feature field on the flat file is the number of legs of the animal (numeric). For a non-mammal the special feature field is the blood type, warm-blooded or cold-blooded (String). Program requirements and grading From the information provided, write a solution that includes the following: .A suitable inheritance hierarchy which represents the pets serviced by the veterinarian. It is up to you how to design the inheritance hierarchy. I suggest an Animal class and appropriate subclasses. For all classes include the following: . o Instance variables Constructors Accessor and mutator methods o o Suitable toString) methods

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design Application Development And Administration

Authors: Michael V. Mannino

4th Edition

0615231047, 978-0615231044

More Books

Students also viewed these Databases questions

Question

LO3 Define the difference between job satisfaction and engagement.

Answered: 1 week ago

Question

What is the difference between Needs and GAP Analyses?

Answered: 1 week ago

Question

What are ERP suites? Are HCMSs part of ERPs?

Answered: 1 week ago