Giter Club home page Giter Club logo
Elphord Kudzai photo

elphord Goto Github PK

followers: 0.0 following: 0.0 repos: 6.0 gists: 0.0

Name: Elphord Kudzai

Type: User

Bio: πŸ‘‹ Hi, I’m @Elphord Kudzai Machida πŸ‘€ I’m interested in network engineering 🌱 I’m currently learning ... πŸ’žοΈ I’m looking to collaborate on ... πŸ“« elphord.m

Location: 06 Woodcote Close Marlborough , Harare , Zimbabwe

Online bookstore Exam

You are tasked with developing an online bookstore application in java. The application should allow users to browse and purchase books from various categories .you need to design and implement the system using OOP principles.

  1. Packages: Package Classes Accounts -User.java -Administrator.java -Customer.java

Inventory -Bookstore.java -Book.java -Category.java -All category classes(Fiction, Non-fiction, Mystery) Executable -Cart.java -Main.java

  1. User Class + (Customer and Administrator classes) β€’ User auto-generated ID, firstname ,lastname ,address, phone β€’ Implement two child classes namely (customer and administrator classes) with appropriate distinct fields ,e.g, administrators must have login privileges (username, role, password) and customers may further have credit points at every purchase and will determine discounts in future purchases. β€’ Customer profile should also have a collection of books bought β€’

  2. Book Class β€’ Create a Book class that represents a book with attributes such as auto -generated ID,title, author ,price, and isbn(International Standard Book Number) β€’ Implement proper encapsulation for these attributes.

  3. Category Class β€’ Create a Category class that represents a category of books (e.g, Fiction,Non-fiction,Mystery). β€’ Use inheritance to ensure that each category inherits common attributes from a parent class ,such as name and description.

5.Bookstore Class: β€’ Create a Bookstore class that manages the collection of books available for purchase. β€’ The bookstore must have an ID and a location. β€’ Implement a method to add to the books to the store’s inventory, taking into consideration quantities of books stored β€’ Implement a method to search for books by title or author within a specific category. β€’ Allow store administrators to manage the inventory ,adding and removing books.

  1. Shopping Cart: β€’ Design a shopping cart that allows customers to add and remove books. β€’ The cart must have an auto-generated ID, Customer ID, store ID and seller ID β€’ It must have a list of books selected and their quantities ,also, ensure that the shopping cart can calculate the total cost of the items added. β€’ The cart must invoke methods in the bookstore class toc check whether required quantities to be purchased are available and reduce the stock when purchases are made.

  2. Exception Handling , Abstraction and Polymorphism β€’ Implement exception handling for scenarios like adding duplicate books to the shopping cart or searching for a book that doesn’t exist. β€’ Utilize abstraction to hide the internal implementation details of the Book class while providing a public interface to access its attributes. β€’ Implement polymorphism by creating different subclasses of Category (e.g., FictionCategory , NonFictionCategory) that override methods like getDescription.

Guidelines:

β€’ Start by creating a class diagram that outlines the relationships between classes and their attributes /methods. β€’ Use appropriate exception classes for exception handling(e.g., DuplicateBookException, BookNotFoundException) β€’ Test your application thoroughly with a menu driven method by:  Create bookstore.  Create category.  Create books.  Manage Inventory  Customer Shopping

You may add other menus you dim necessary to demonstrate your creativity.

Elphord Kudzai's Projects

elphord icon elphord

Config files for my GitHub profile.

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.