SlideShare a Scribd company logo
1 of 2
Download to read offline
In JAVA,
Summary The gist of this assignment document's contents are as follows: - Program
Description: Reading shape specifications from files and printing them out - Hints, edge-cases,
and design considerations You have 10 files as input and you must use all of them You should
have files outputted You should have at least 3 classes by the end of the program - Deliverables
& Reminders Use a project named Assignment6 and create a different java file for each class.
Files must be named according to the shape. For example, a file containing the Triangle class
should be named "Triangle.java". Submit a .zip file that is your compressed project folder. -
Rubric Visible on Canvas Assignment Page - Sample Program Output - Changelog/Clarifications
Program Description For this assignment, you will write a program to print three shapes of
different sizes. Your program will read input from a text file and write the output to another file.
The input files should be saved in a subfolder called InputFiles while the output files should be
written to a subfolder called OutputFiles. Both InputFiles and OutputFiles subfolders should be
under the project's main folder This assignment is divided up into five main parts we want you to
be able to handle, objects, recursion, JUnit testing, file I/O, and exception handling. The sections
are in the order l'd recommend you implement them in, however do what will make the most
sense to you.
This assignment is divided up into five main parts we want you to be able to handle, objects,
recursion, JUnit testing, file I/O, and exception handling. The sections are in the order I'd
recommend you implement them in, however do what will make the most sense to you. Objects
Create four classes; Triangle, Rectangle and Rhombus and a File Handler class A Triangle will
be supplied one integer which will dictate how far "down" you want to go. For example, if you're
given the integer 5 , you'll get the output:
and if you get 4 as input, you'll output: A way the Triangle class can look is as follows, however
you are in no way obligated to follow this. The other classes will also look like this one. public
class Triangle { private int length; public Triangle(int length); } public String printShape();
The Rectangle class will represent rectangles with two numbers representing the width and the
height. and a rectangle given 3 and 2 will look like:
The Rhombus class will represent a rhombus with a single number indicating the height. See
figure for explanation. and if it's 7 it should look like: note that an even number will not work
for this shape, so such if a rhombus if an even number is supplied to its constructor an
"IllegalArgumentException" should be thrown. The asterisks should also be padded like the
examples.
Each class should implement a recursive getShape() method (similar to the getArea() method in
the lecture slides). The method will return a String containing the shape in a form similar to the
figures in this assignment. JUnit Testing After the classes and methods are made, you should
make sure they will have the correct expected output. Make sure you test for edge cases, namely
massive numbers, small numbers, and anything that might break your program. Make sure you
also test every class, and each method that's being tested must be called at least 3 times per test,
with different parameters each time. Note that no files should be read/written to when testing
your functions. File 1/0 Your program should take in input from the files on Canvas, which will
have the in extensions. Furthermore, your program should also output to files with the same
name of the input file, but with the .out extension, provided the input file is in the correct format.
We recommend that you make one method that will parse the file and handle its inputs and takes
in a "File" as a parameter, and another that will read the file.
Sample Input/Output: Input: A file containing the name of a shape and its dimensions, for
example: rhombus 5 rectangle 45 triangle 3 This input called for a rhombus of height 5 , a
rectangle of width 4 and 5 , and a triangle that goes "down" 3 . Output: A file that contains the
specified shapes in the input file. Going off the previous example

More Related Content

Similar to In JAVA, Summary The gist of this assignment documents contents a.pdf

pythontraining-201jn026043638.pptx
pythontraining-201jn026043638.pptxpythontraining-201jn026043638.pptx
pythontraining-201jn026043638.pptxRohitKumar639388
 
Presentation 1st
Presentation 1stPresentation 1st
Presentation 1stConnex
 
Bt0065, c programming and data structures
Bt0065, c programming and data structuresBt0065, c programming and data structures
Bt0065, c programming and data structuressmumbahelp
 
CSC388 Online Programming Languages Homework 3 (due b.docx
CSC388 Online Programming Languages  Homework 3 (due b.docxCSC388 Online Programming Languages  Homework 3 (due b.docx
CSC388 Online Programming Languages Homework 3 (due b.docxannettsparrow
 
The Lab assignment will be graded out of 100 points.  There are .docx
The Lab assignment will be graded out of 100 points.  There are .docxThe Lab assignment will be graded out of 100 points.  There are .docx
The Lab assignment will be graded out of 100 points.  There are .docxjmindy
 
C++ - UNIT_-_V.pptx which contains details about File Concepts
C++  - UNIT_-_V.pptx which contains details about File ConceptsC++  - UNIT_-_V.pptx which contains details about File Concepts
C++ - UNIT_-_V.pptx which contains details about File ConceptsANUSUYA S
 
Looping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptxLooping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptxadihartanto7
 
1126640 question
1126640 question 1126640 question
1126640 question lpss0513
 
VB_ERROR CONTROL_FILE HANDLING.ppt
VB_ERROR CONTROL_FILE HANDLING.pptVB_ERROR CONTROL_FILE HANDLING.ppt
VB_ERROR CONTROL_FILE HANDLING.pptBhuvanaR13
 
Reaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdfReaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdffashionbigchennai
 
Problem solving (C++ Programming)
Problem solving (C++ Programming)Problem solving (C++ Programming)
Problem solving (C++ Programming)Umair Younas
 
CS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docx
CS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docxCS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docx
CS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docxannettsparrow
 
Your 1ab8 c file is doe by Friday 1159pm to be submitted.pdf
Your 1ab8 c file is doe by Friday 1159pm to be submitted.pdfYour 1ab8 c file is doe by Friday 1159pm to be submitted.pdf
Your 1ab8 c file is doe by Friday 1159pm to be submitted.pdfabhijitmaskey
 
1 Project 2 Introduction - the SeaPort Project seri.docx
1  Project 2 Introduction - the SeaPort Project seri.docx1  Project 2 Introduction - the SeaPort Project seri.docx
1 Project 2 Introduction - the SeaPort Project seri.docxhoney725342
 
BASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdf
BASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdfBASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdf
BASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdfashaks17
 
Programming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) EnvironmentProgramming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) EnvironmentMahmoud Samir Fayed
 

Similar to In JAVA, Summary The gist of this assignment documents contents a.pdf (20)

pythontraining-201jn026043638.pptx
pythontraining-201jn026043638.pptxpythontraining-201jn026043638.pptx
pythontraining-201jn026043638.pptx
 
Presentation 1st
Presentation 1stPresentation 1st
Presentation 1st
 
Bt0065, c programming and data structures
Bt0065, c programming and data structuresBt0065, c programming and data structures
Bt0065, c programming and data structures
 
CSC388 Online Programming Languages Homework 3 (due b.docx
CSC388 Online Programming Languages  Homework 3 (due b.docxCSC388 Online Programming Languages  Homework 3 (due b.docx
CSC388 Online Programming Languages Homework 3 (due b.docx
 
The Lab assignment will be graded out of 100 points.  There are .docx
The Lab assignment will be graded out of 100 points.  There are .docxThe Lab assignment will be graded out of 100 points.  There are .docx
The Lab assignment will be graded out of 100 points.  There are .docx
 
C++ - UNIT_-_V.pptx which contains details about File Concepts
C++  - UNIT_-_V.pptx which contains details about File ConceptsC++  - UNIT_-_V.pptx which contains details about File Concepts
C++ - UNIT_-_V.pptx which contains details about File Concepts
 
Looping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptxLooping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptx
 
1126640 question
1126640 question 1126640 question
1126640 question
 
VB_ERROR CONTROL_FILE HANDLING.ppt
VB_ERROR CONTROL_FILE HANDLING.pptVB_ERROR CONTROL_FILE HANDLING.ppt
VB_ERROR CONTROL_FILE HANDLING.ppt
 
Savitch ch 06
Savitch ch 06Savitch ch 06
Savitch ch 06
 
Reaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdfReaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdf
 
Problem solving (C++ Programming)
Problem solving (C++ Programming)Problem solving (C++ Programming)
Problem solving (C++ Programming)
 
CS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docx
CS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docxCS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docx
CS 111 - Homework 5 p. 1CS 111 - Homework 5Deadline1.docx
 
Your 1ab8 c file is doe by Friday 1159pm to be submitted.pdf
Your 1ab8 c file is doe by Friday 1159pm to be submitted.pdfYour 1ab8 c file is doe by Friday 1159pm to be submitted.pdf
Your 1ab8 c file is doe by Friday 1159pm to be submitted.pdf
 
1 Project 2 Introduction - the SeaPort Project seri.docx
1  Project 2 Introduction - the SeaPort Project seri.docx1  Project 2 Introduction - the SeaPort Project seri.docx
1 Project 2 Introduction - the SeaPort Project seri.docx
 
BASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdf
BASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdfBASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdf
BASIC_INTRODUCTION_TO_PYTHON_PROGRAMMING.pdf
 
Programming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) EnvironmentProgramming Without Coding Technology (PWCT) Environment
Programming Without Coding Technology (PWCT) Environment
 
pyton Notes1
pyton Notes1pyton Notes1
pyton Notes1
 
F# Console class
F# Console classF# Console class
F# Console class
 
C programming
C programmingC programming
C programming
 

More from siva009113

In Chapter 2, a discussion of how social media influences the politi.pdf
In Chapter 2, a discussion of how social media influences the politi.pdfIn Chapter 2, a discussion of how social media influences the politi.pdf
In Chapter 2, a discussion of how social media influences the politi.pdfsiva009113
 
In March 2019, Zambia, a small open economy, lifted its export ban o.pdf
In March 2019, Zambia, a small open economy, lifted its export ban o.pdfIn March 2019, Zambia, a small open economy, lifted its export ban o.pdf
In March 2019, Zambia, a small open economy, lifted its export ban o.pdfsiva009113
 
in JavsScript we have folders and files. Which folder would these tw.pdf
in JavsScript we have folders and files. Which folder would these tw.pdfin JavsScript we have folders and files. Which folder would these tw.pdf
in JavsScript we have folders and files. Which folder would these tw.pdfsiva009113
 
IN JAVA PLEASEmake sure of the variables are correct and the s.pdf
IN JAVA PLEASEmake sure of the variables are correct and the s.pdfIN JAVA PLEASEmake sure of the variables are correct and the s.pdf
IN JAVA PLEASEmake sure of the variables are correct and the s.pdfsiva009113
 
IN C CODEGiven an IntNode struct and the operating functions for a.pdf
IN C CODEGiven an IntNode struct and the operating functions for a.pdfIN C CODEGiven an IntNode struct and the operating functions for a.pdf
IN C CODEGiven an IntNode struct and the operating functions for a.pdfsiva009113
 
In an agricultural experiment there are 25 varieties of maize, label.pdf
In an agricultural experiment there are 25 varieties of maize, label.pdfIn an agricultural experiment there are 25 varieties of maize, label.pdf
In an agricultural experiment there are 25 varieties of maize, label.pdfsiva009113
 

More from siva009113 (6)

In Chapter 2, a discussion of how social media influences the politi.pdf
In Chapter 2, a discussion of how social media influences the politi.pdfIn Chapter 2, a discussion of how social media influences the politi.pdf
In Chapter 2, a discussion of how social media influences the politi.pdf
 
In March 2019, Zambia, a small open economy, lifted its export ban o.pdf
In March 2019, Zambia, a small open economy, lifted its export ban o.pdfIn March 2019, Zambia, a small open economy, lifted its export ban o.pdf
In March 2019, Zambia, a small open economy, lifted its export ban o.pdf
 
in JavsScript we have folders and files. Which folder would these tw.pdf
in JavsScript we have folders and files. Which folder would these tw.pdfin JavsScript we have folders and files. Which folder would these tw.pdf
in JavsScript we have folders and files. Which folder would these tw.pdf
 
IN JAVA PLEASEmake sure of the variables are correct and the s.pdf
IN JAVA PLEASEmake sure of the variables are correct and the s.pdfIN JAVA PLEASEmake sure of the variables are correct and the s.pdf
IN JAVA PLEASEmake sure of the variables are correct and the s.pdf
 
IN C CODEGiven an IntNode struct and the operating functions for a.pdf
IN C CODEGiven an IntNode struct and the operating functions for a.pdfIN C CODEGiven an IntNode struct and the operating functions for a.pdf
IN C CODEGiven an IntNode struct and the operating functions for a.pdf
 
In an agricultural experiment there are 25 varieties of maize, label.pdf
In an agricultural experiment there are 25 varieties of maize, label.pdfIn an agricultural experiment there are 25 varieties of maize, label.pdf
In an agricultural experiment there are 25 varieties of maize, label.pdf
 

Recently uploaded

Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...christianmathematics
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxDenish Jangid
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...pradhanghanshyam7136
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxheathfieldcps1
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfagholdier
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17Celine George
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701bronxfugly43
 
Third Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptxThird Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptxAmita Gupta
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseAnaAcapella
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxAmanpreet Kaur
 
Dyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptxDyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptxcallscotland1987
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.christianmathematics
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and ModificationsMJDuyan
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSCeline George
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfSherif Taha
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin ClassesCeline George
 

Recently uploaded (20)

Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
Asian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptxAsian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptx
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
Third Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptxThird Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptx
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
 
Dyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptxDyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptx
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POS
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdf
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 

In JAVA, Summary The gist of this assignment documents contents a.pdf

  • 1. In JAVA, Summary The gist of this assignment document's contents are as follows: - Program Description: Reading shape specifications from files and printing them out - Hints, edge-cases, and design considerations You have 10 files as input and you must use all of them You should have files outputted You should have at least 3 classes by the end of the program - Deliverables & Reminders Use a project named Assignment6 and create a different java file for each class. Files must be named according to the shape. For example, a file containing the Triangle class should be named "Triangle.java". Submit a .zip file that is your compressed project folder. - Rubric Visible on Canvas Assignment Page - Sample Program Output - Changelog/Clarifications Program Description For this assignment, you will write a program to print three shapes of different sizes. Your program will read input from a text file and write the output to another file. The input files should be saved in a subfolder called InputFiles while the output files should be written to a subfolder called OutputFiles. Both InputFiles and OutputFiles subfolders should be under the project's main folder This assignment is divided up into five main parts we want you to be able to handle, objects, recursion, JUnit testing, file I/O, and exception handling. The sections are in the order l'd recommend you implement them in, however do what will make the most sense to you. This assignment is divided up into five main parts we want you to be able to handle, objects, recursion, JUnit testing, file I/O, and exception handling. The sections are in the order I'd recommend you implement them in, however do what will make the most sense to you. Objects Create four classes; Triangle, Rectangle and Rhombus and a File Handler class A Triangle will be supplied one integer which will dictate how far "down" you want to go. For example, if you're given the integer 5 , you'll get the output: and if you get 4 as input, you'll output: A way the Triangle class can look is as follows, however you are in no way obligated to follow this. The other classes will also look like this one. public class Triangle { private int length; public Triangle(int length); } public String printShape(); The Rectangle class will represent rectangles with two numbers representing the width and the height. and a rectangle given 3 and 2 will look like: The Rhombus class will represent a rhombus with a single number indicating the height. See figure for explanation. and if it's 7 it should look like: note that an even number will not work for this shape, so such if a rhombus if an even number is supplied to its constructor an
  • 2. "IllegalArgumentException" should be thrown. The asterisks should also be padded like the examples. Each class should implement a recursive getShape() method (similar to the getArea() method in the lecture slides). The method will return a String containing the shape in a form similar to the figures in this assignment. JUnit Testing After the classes and methods are made, you should make sure they will have the correct expected output. Make sure you test for edge cases, namely massive numbers, small numbers, and anything that might break your program. Make sure you also test every class, and each method that's being tested must be called at least 3 times per test, with different parameters each time. Note that no files should be read/written to when testing your functions. File 1/0 Your program should take in input from the files on Canvas, which will have the in extensions. Furthermore, your program should also output to files with the same name of the input file, but with the .out extension, provided the input file is in the correct format. We recommend that you make one method that will parse the file and handle its inputs and takes in a "File" as a parameter, and another that will read the file. Sample Input/Output: Input: A file containing the name of a shape and its dimensions, for example: rhombus 5 rectangle 45 triangle 3 This input called for a rhombus of height 5 , a rectangle of width 4 and 5 , and a triangle that goes "down" 3 . Output: A file that contains the specified shapes in the input file. Going off the previous example