The LibraryRunner class is a Java class that represents the main class of a library management...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
The LibraryRunner class is a Java class that represents the main class of a library management system. This class contains the main method, which is the entry point for the application. The main purpose of this class is to provide a text-based menu (this will be a command-line based interaction and not GUI) that allows students to interact with the library management system. This is a student facing system. The menu should include the following options: Register: This option registers a student in the library system. When this option is selected, the system will ask for the name of the student. Sort Books: This option allows the student to sort the books based on ISBN. Search Books: This option allows students to search for books in the library, given the ISBN. Borrow Book: This option allows students to borrow books from the library. When this option is selected the system will ask for the student's registration number and ISBN of the book. Return Book: This option allows students to return books to the library. When this option is selected the system should ask for the registration number of the student; once the registration number is entered it should display a list of all the books the student has borrowed. The system would then ask for the ISBN of the book to be returned. Once a book is returned, it should be removed from the borrowed books list and the quantity should be updated in the inventory. Show Inventory Stats: This option displays a chart (bar graph) that shows the number of available books in the library inventory for both fiction and non-fiction categories. You can use Java Swing or Java FX to create this screen. This option should create an InventoryChart object with a title and the stats to be displayed. Library.availableBooks() should give the needed stats and then invoke InventoryChart.displayGraph() to display the chart. InventoryChart This class is used to display the bar graph. Depending on the way you choose to create the GUI (Swing or FX), extend the appropriate classes. The attributes of this class are String title, int[] stats. Add getters and setters for both. The displayGraph method should make the GUI visible. It should be a single screen Ul with a bar chart and two bars of different colors. One bar should depict the number of available fiction books and the other bar should depict the number of available non-fiction books. LibraryManagementSystem The LibraryManagement System is an interface that represents the contract for a library management system. This interface defines four methods that a library management system should implement: The LibraryRunner class is a Java class that represents the main class of a library management system. This class contains the main method, which is the entry point for the application. The main purpose of this class is to provide a text-based menu (this will be a command-line based interaction and not GUI) that allows students to interact with the library management system. This is a student facing system. The menu should include the following options: Register: This option registers a student in the library system. When this option is selected, the system will ask for the name of the student. Sort Books: This option allows the student to sort the books based on ISBN. Search Books: This option allows students to search for books in the library, given the ISBN. Borrow Book: This option allows students to borrow books from the library. When this option is selected the system will ask for the student's registration number and ISBN of the book. Return Book: This option allows students to return books to the library. When this option is selected the system should ask for the registration number of the student; once the registration number is entered it should display a list of all the books the student has borrowed. The system would then ask for the ISBN of the book to be returned. Once a book is returned, it should be removed from the borrowed books list and the quantity should be updated in the inventory. Show Inventory Stats: This option displays a chart (bar graph) that shows the number of available books in the library inventory for both fiction and non-fiction categories. You can use Java Swing or Java FX to create this screen. This option should create an InventoryChart object with a title and the stats to be displayed. Library.availableBooks() should give the needed stats and then invoke InventoryChart.displayGraph() to display the chart. InventoryChart This class is used to display the bar graph. Depending on the way you choose to create the GUI (Swing or FX), extend the appropriate classes. The attributes of this class are String title, int[] stats. Add getters and setters for both. The displayGraph method should make the GUI visible. It should be a single screen Ul with a bar chart and two bars of different colors. One bar should depict the number of available fiction books and the other bar should depict the number of available non-fiction books. LibraryManagementSystem The LibraryManagement System is an interface that represents the contract for a library management system. This interface defines four methods that a library management system should implement:
Expert Answer:
Answer rating: 100% (QA)
Answer Here are is a possible implementation for the textbased menu with 6 options import javautilScanner public class LibraryRunner public static void mainString args Scanner scanner new ScannerSyste... View the full answer
Related Book For
Management Accounting Information for Decision-Making and Strategy Execution
ISBN: 978-0137024971
6th Edition
Authors: Anthony A. Atkinson, Robert S. Kaplan, Ella Mae Matsumura, S. Mark Young
Posted Date:
Students also viewed these programming questions
-
Describe issues of healthcare provision during economic downturns. Consider some of the ethical issues presented by government financing. Explain with at least three hundred words
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
Case Study: Quick Fix Dental Practice Technology requirements Application must be built using Visual Studio 2019 or Visual Studio 2017, professional or enterprise. The community edition is not...
-
The atomic mass of 14c is 14.003242 u. Show that the decay of 14C is energetically possible, and calculate the energy released in the decay.
-
Consider the conditions of Example 9.3, including the effect of adding insulation of thickness t and thermal conductivity k = 0.035 W/m. K to the duct. We wish to now include the effect of radiation...
-
If government regulations make a certain job less dangerous, then we'd expect that the supply of labor for that job would be?
-
Show that for a European call or put on a non-dividend-paying stock = N' (d1) SoT SN' (d) -Ke-T N(d2). 2T
-
Given the following information for Lightning Power Co., find the WACC. Assume the companys tax rate is 35 percent. Debt: 8,000 6.5 percent coupon bonds outstanding, $1,000 par value, 25 years to...
-
As a manager, Rick sometimes receives emails from the people who work under him that give responses that they think he'd like to hear rather than honest appraisals would be more helpful to him. This...
-
Telemark-Kjemi AS manufactures an industrial solvent in two departments mixing and cooking. This question focuses on the Cooking Department. During June 2022, 90 tonnes of solvent were completed and...
-
Find an equation of the plane through (-8, 2, -2) that is perpendicular to the planes 3x y+z = 4 and x+y- 4z = 6. O -13y + 4z+ 34 0 O 3x + 13y + 4z + 6 = 0 O 3x 13y + 4z + 58 = 0 O 3x y+z+ 28 = 0...
-
What is a hospitals responsibility to provide care to the indigent, and how does it differ depending on the type of care (emergency vs. nonemergency) and the type of hospital (e.g., public, private,...
-
What kinds of fraudulent or abusive behavior related to federal healthcare payment programs can occur in hospital operations?
-
Entity E entered into a contract in 2009 to supply video game consoles to customer G. The contract is for 50,000 game consoles at EUR 100 each. The contract contains specific instructions from...
-
On appeal, defendant raises several alleged trial errors. He presses more strongly, however, his contentions that the evidence was insufficient to support the guilty verdict on the Medicare fraud...
-
You want your program to execute statement 1 when A A is false, B B is false, and C C is true, and to execute statement 2 otherwise. You wrote \section*{if not ( A not ( A and B ) B ) and C C then}...
-
6. The purchase of a new house is the one form of a. household spending that is not counted as part of investment in the national income accounts. b. investment that is financed by private saving...
-
If you want to solve a minimization problem by applying the geometric method to the dual problem, how many variables and problem constraints must be in the original problem?
-
For each of the following products, suggest three measures of quality: a. Television set b. University course c. Meal in an exclusive restaurant d. Carryout meal from a restaurant e. Container of...
-
Organizations in the public and nonprofit sector, such as government agencies and charitable social service entities, have financial systems that budget expenses and monitor and control actual...
-
Why do organizations allocate revenues to responsibility centers?
-
The control volume shown in Figure \(P 2.15\) has steady, incompressible flow, and all properties are uniform at the inlet and outlet. For \(u_{1}=1.256 \mathrm{MJ} / \mathrm{kg}\) and...
-
(a) List the forces exerted on the spring-cart system of Figure 15.1 right after it is released, and draw a freebody diagram for each object in the system. (b) Which of these forces do work on the...
-
(a) In Figure 15.2e, the cart's displacement from the equilibrium position is maximum. Is the \(x\) component of the cart's acceleration at that instant positive, negative, or zero? (b) At which...
Study smarter with the SolutionInn App