/**
 * CS149 - Programming Fundamentals
 * Department of Computer Science
 * James Madison University
 * @version Fall 2019
 */

Final PA - Dukes Little Library

Objectives

Honor Code

This assignment must be completed individually. Your submission must conform to the JMU Honor Code. You may discuss the project with other students at a high level, but direct help is limited to general discussion on Piazza, the lab assistants assigned to CS149, and the instructor. Copying work from another student or the Internet is an honor code violation and will be grounds for a reduced or failing grade in the course.

Background

Little Free Library Little Free Library books

This assignment is inspired by the Little Free Library organization which has managed to charter small "libraries" like the one shown above all across the world. Each "library" encourages patrons to take a book or leave a book to promote accessibility of books and reading in general. They are community spaces, many with benches or seats nearby and all are maintained by volunteers. There are eight in Harrisonburg. The one at Thomas Harrison Middle School was built by the JMU Art Department. The one shown above is the Elizabeth Street Little Free Library, and the data file you will be using in the assignment is based on the books available at this writing in the Elizabeth Street box.

Requirements

In this assignment, imagine that the Little Free Library organization has contracted with the JMU Computer Science department to track how much money they could earn if they were a commercial organization that charged late fees for overdue books. This information will then be used for local LFL librarians to apply for funding from other non-profit foundations or the government. Each book and patron will be modeled by classes with relevant data and methods as outlined in the UML diagram and descriptions shown below. The Library class will then have arrays of books and patrons along with methods that allow for books to be checked in, checked out, and found in addition to determining fines. Your program will be based on the following files:

You don't actually need the Driver to complete the assignment; it is simply provided to show how your classes might be used in a larger application. The following UML diagram illustrates the relationships between the classes.

Library UML

Book.java

Patron.java

Library.java

Hints and Tips

*Do not implement any public methods other than what you see in the UML diagram. For example, you should not have a Patron.getBalance()method, even for testing purposes. You may add helper methods, but they must be private.

Submission

Part A (40 pts): Due Friday, Nov 22 at 5:00 PM

Submit Book.java and BookTest.java, Patron.java and PatronTest.java via https://autolab.cs.jmu.edu

Part B (60 pts): Due Friday Dec 6 at 11:00 PM

Submit Book.java and BookTest.java, Patron.java and PatronTest.java, Library.java and LibraryTest.java via https://autolab.cs.jmu.edu.