SENG6110 Object Oriented Programming Assignment Help and

Assignment Detail:- SENG6110 Object Oriented Programming - The University of Newcastle IntroductionThe objective of this assignment is to extend the implementation of Assignment- SpecificationsCreate a database which will hold up to 2 region objects- Each region object may have up to 3 dwarf planets in it - see the sample data in the file "input_data-csv"- To implement this you should use arrays, one array of up to 2 region objects each with its own array of up to 3 dwarf planets as an attribute- Question 1- Add a region-The user will specify a- the region name, b- the width in AU and c- the population of objects with diameters greater than 100km- There should be an error message if the region name already exists in the array, or if there are already 2 region objects in the array- Question 2- Add a dwarf planet object to one of the region objects-The user will specify the region name -the object to which this dwarf planet is being added-, dwarf planet name, diameter -km-, mass -x1021kg- and number of moons- There should be an error message if the dwarf planet already exists, or if the region does not exist, or the region already has 3 dwarf planet objects- Question 3- Delete a region-The user will specify the region name- There should be an error message if the region does not exist- This will also cause any dwarf planet objects in that region to be deleted- Question 4- Delete a dwarf planet-The user will specify the region and dwarf planet name- There should be an error message if either do not exist- If there exists a region containing that dwarf planet, the region should be updated- Question 5- List all objects-The output should list all regions and dwarf planets with all attributes included- If there are no objects, the output should be: "No objects exist"- Otherwise, one line should be output for each object with one of these formats:REGION name width largeObjectsDWARF PLANET regionName dwarfPlanetName diameter mass moons Question 6- List the dwarf planets that belong in a region-The user will specify the region name- If the region contains no dwarf planet objects, the output should be: "No dwarf planets contained in this region-" Otherwise, one line should be output for each dwarf planet, with this format:DWARF PLANET regionName dwarfPlanetName diameter mass moons Question 7- List the dwarf planets with a mass greater than 4 x 1021kg-The output should be in the format:DWARF PLANET regionName dwarfPlanetName mass Question 8- List the dwarf planet with the smallest diameter in each region-There should be an error message if there are no dwarf planets in the database- The output should be in the format:DWARF PLANET regionName dwarfPlanetName diameter Question 9- Import region and dwarf planet information from a file-The user will specify the name of the file to be read from- The program should expect a file consisting of zero or more lines- Each line should have one of these formats:REGION name width largeObjectsDWARF PLANET regionName dwarfPlanetName diameter mass moons The imported data should replace any pre-existing objects- A REGION line in the input file should cause addition of the described region object- Similarly, a DWARF PLANET line should cause addition of the described dwarf planet- An error message should be output if the file is unable to be opened, or if a problem occurred during reading the file- This includes cases such as finding a line with an invalid format and being unable to add a region or dwarf planet due to one of the issues listed under functionalities 1 and 2 -in both cases, the program should continue to process the rest of the file-- An example of a file which could be used -after the heading lines are removed- is included as input_data-csv- Question 10- Write region and dwarf planet information to file-The user will specify the name of the file to create- The created file should have the same format as that used for importing- An error message should be output if the file is unable to be created, or if a problem occurred during writing- Program Requirements In this assignment you should use arrays to store the region and dwarf planet objects- Use two constants specifying array sizes- The program should consist of three classes -and ONLY three classes-- Use the supplied "files to start with", do not change their names or add any additional files- All instance variables of your classes should be private -this is imposed so that you apply the principles of encapsulation-- Your classes will need methods to provide the required functionalities- The only class which should have a main-- method is Interface-java- Attachment:- Programming Assignment-rar




Most Recent Questions

Captcha

Helping Students for Excellence in Academics, GET Help with Assignment? Order Now