Decision Structures in Java
     You are the owner of a companythat sells designer desks. Your program will create a user friendlyinterface (company name, labeled prompts, neat output) thatcalculates the cost of constructing desks for customers. After thecustomer enters the appropriate prompted values, the program willcalculate the cost of the desk based on the specifications outlinedbelow. The program should allow the user to order a second desk ifdesired.
- Define a java instance class as described below. Save the classdefinition in a file with an appropriate filename.
ClassName:Â Â Â Â Â Â Â Â Â Desk
Instance Variables: length – float(representing inches)
(Fields)                    width – float (representing inches)
                                type – char (valid values P, O, or M for Pine, Oak, orMahogany)
                                drawers – integer (representing the number of desk drawers)
StaticVariable:       count– tracks the number of desks created
Instance Methods: Aconstructor that accepts no arguments and setsdefault values as follows: the length to 6, width to 12, Oak type,and 1 drawer
                                A constructor that accepts 4 arguments, and setsthe fields appropriately.
                                 getArea() A method to calculate and return the area of thedesk.
                                 getType() A method to return desk type.
                                 getDrawers() A method to return the number of drawers.
                                 toString()Displays the object’s attributes
                               Â
- Create a program class, TestDesk, thatcontains a main() to test and use the above class. This processshould contain methods as follows:
main(): This method should:
- Call createDesk() to get the inputs and create a Deskobject.
- Call calculatePrice() to determine the cost of constructing adesk.
- Display the price of the desk along with the attributevalues.
- Ask the user if they want another desk.
- If the answer is No, display the total price of the desk
- If the answer is Yes, implement steps 1 and 2 again (without aloop), then display:
- the number of desks created (through a variable)
- total cost of the desk(s), and
- average desk cost.
- The program should then end.
Classmethods:Â Â Â Â Â Â createDesk() A function to prompt the user for inputs and accept thefour (4) input values needed to create an instance of a Desk. Itinstantiates a Desk object and returns the object to the callingmethod.
                              CalculatePrice()This function has a Desk object as its formal argument and returnsthe price of the desk to be determined as follows:
- The basic cost of a frame is $12.50 for P(ine), $26 for O(ak),and $37.75 for M(ahogany).
- Any desk with an area greater than 75 square inches isconsidered large. Add $18.25 to the cost for a large desk.
- The basic desk comes with one (1) drawer. There is an extracharge of $9.50 for each additional drawer. Desk’s are charged fora maximum of six (6) drawers. Any desk with more than 6 drawers ischarged for 6 drawers.
Additional Notes:
- Be sure to efficiently implement all 3 decision structuresdiscussed in class
- Implement sound program design so as to avoid duplicatedcode
- An invalid wood type entry should default to Oak
- Your program should accommodate upper and lower case userinputs
- Dollar values should be displayed to 2 decimal places andlabeled