Create a Small Library Inventory Program that Checks In and Out Book

Hello, I need help creating a project with the following features in C++: -The Book class counts the number of times a book has been checked out. -The Library class contains a collection of Book instances. -New books are added to the collection of the Library class through the calls to addbookintoCollection( ). -The books are allowed to be checked out by calls to bookCheckout( ) in the library class. -Subclass via inheritances std::logic_error to create bookNotAvailable errors when users attempt to create errors. -Only want to provide the public API. Here is the outline to follow: class Library {  public:  library();  void addbookintoCollection( string author, string title );  void bookCheckout( string author, string title ) throw (bookNotAvailable);  void bookCheckin( string author, string title ) throw (bookNotAvailable);  friend operator<< ( ostream& out, const Library & l );  private:  Book myBooks[ 20 ];  int numberOfbooksSeenthusfar;} class Book{  public:  Book();   Book( string author, string title );  string getAuthor() const;   string getTitle() const;   int getNumberCheckedOut() const;   void increaseNumberCheckedOut( int amount=1 );   friend operator<< ( ostream& out, const Book & b );  private:  string theAuthor;   string theTitle;  int theNumberCheckedOut;} Here is the driver code: Library lib;lib.addBookToCollection( “F. Scott Fitzgerald”, “The Great Gatsby” );lib.addBookToCollection( “J. D. Salinger”, “The Catcher in the Rye” ); cout << lib << endl; try {   lib.bookCheckout( “J. D. Salinger”, “The Catcher in the Rye” );  lib.bookCheckin( “J. D. Salinger”, “The Catcher in the Rye” );   lib.bookCheckout( “F. Scott Fitzgerald”, “The Great Gatsby” );} catch(bookNotAvailable notava ) {   cout << “You have entered the incorrect:”;  cout << notava.goof() << endl;} Thanks for the help

Looking for this or a Similar Assignment? Click below to Place your Order

Open chat