Giter VIP home page Giter VIP logo

bookstore-system-using-oop's Introduction

Bookstore-system-using-OOP

Book store maintains an inventory of books. The store tracks the title and author of each book, plus the book's media. The media is one of hardcover(cloth or leather), paperback, and audio books.


The inventory records whether each hardcover book has either a cloth or a leather cover and how many discs are in each audiobook. Each electronic book has a download URL link that the store wants to use to let a customer browse the book. The store keeps its inventory in a formatted file. Each non-empty line represents a book that the store has in stock.


Each book entry appears as a single line in the file. For example, here are example file entries for different versions and editions of the book "Ulysses" by James Joyce:

Ulysses_James Joyce_895
Ulysses_James Joyce_3195_leather
Ulysses_James Joyce_2395_cloth
Ulysses_James Joyce_0_http://www.amazon.com
Ulysses_James Joyce_1995_3


As you can see, the fields are underscore-separated strings. The fields are the title, author, cost in cents, and an optional field providing details on the book's media format. If there is no media format, the entry is a paperback. Leather and cloth are kinds of hardcover books. The first entry in the example is a paperback, and the last two entries are an electronic book and an 3 disc audiobook respectively.


This short example interaction shows the program printing its inventory list and offering search options. More detailed sample run is provided in sample_output.txt
$ java Store bookList0.txt
The inventory of Barney's Books 'N' Bytes:

  1. "Ulysses".
    James Joyce.
    Paperback.
  2. "Ulysses".
    James Joyce.
    Hardcover leather.
  3. "Ulysses".
    James Joyce.
    Hardcover cloth.
  4. "Ulysses".
    James Joyce.
    Electronic from http://www.amazon.com
  5. "Designing Object-Oriented Software".
    Rebecca Wirfs-Brock, Brian Wilkerson, Lauren Wiener
    Electronic from http://booksRnotDead.com
  6. "Sometimes a Great Notion".
    Ken Kesey.
    Audio: 3 discs.

Enter one of these codes (t, a, m)=(title, author, media) and a portion of the desired text. Or enter a blank line to quit. (Note: media format is paper, hard, audio, or electronic). How would you like to search? :

bookstore-system-using-oop's People

Contributors

patelherat avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.