ScholarMatic | 24/7 Homework Help

ScholarMatic Will Help You Write Your Essays and Term Papers

Answered » You can buy a ready-made answer or pick a professional tutor to order an original one.

I need the following java program created

by | Nov 30, 2023 | questions

See attached file.

Document Preview:

Part 1.  Design and implement a class Menu which uses doubly linked lists as main data structures. A menu consists of main menu items, organized as a doubly linked list, each main menu item having associated a submenu, organized as a doubly linked list of submenu items (see the example of a Menu object in the attached file).
The class Menu should define a default constructor which builds an empty menu and the following methods: – addMainMenuItem, two overloaded methods for adding a main menu item having an empty submenu. One of the overloaded methods takes only one parameter, the name of the new main menu item. It adds the new main menu item to the end of the list. The other overloaded method takes three parameters: the name of the new main menu item, the name of an existing main menu item and a parameter which specifies whether the new main menu item will be added before or after the existing main menu item. – deleteMainMenuItem, deletes the main menu item specified by name; – addSubMenuItem, adds a submenu item specified by name to a main menu item specified by name; – toString, traverses the linked lists data structures and generates the string representation of a menu object, organized on lines. Each line should include the main menu item followed by its submenu items. The items should be separated by a semicolon character. The toString method will be invoked from other programs (such as the driver of Part 2) to display the menu.
Note. If necessary, additionally (housekeeping) methods may be defined for the class Menu. You are required to compile (without errors) the class Menu.java.
 
Part 2 Write a driver program MenuTest.java to test the Menu class.  In the driver program, do the following tasks: 
a) Read menu items from the input file Menu.txt and build a menu object which includes the specified items. Each file line contains a main menu item followed by its submenu items, all items being separated by the semicolon character. After reading the file and…

Attachments:


ScholarMatic: Explanation & Answer

Your ready answer from a verified tutor is just a click away for as little as $14.99


  

Click Order Now to get 100% Original Answer Customized to your instructions!

HOME TO CERTIFIED WRITERS

Why Place An Order With Us?

  • Certified Editors
  • 24/7 Customer Support
  • Profesional Research
  • Easy to Use System Interface
  • Student Friendly Pricing

Have a similar question?

PLAGIRAISM FREE PAPERS

All papers we provide are well-researched, properly formatted and cited.

TOP QUALITY

All papers we provide are well-researched, properly formatted and cited.

HIGHLY SECURED

All papers we provide are well-researched, properly formatted and cited.

ScholarMatic: Get Started

Assignment Writing Service

Feel safe and secure when placing an order on our portal!
Fruitful cooperation begins with solid guarantees, and we are professional enough to promise perfect results. Let’s get it started!