Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please help me with the 1 st phase the use case and classs diagram what to include in the class diagram with right OOP relationship

please help me with the 1st phase the use case and classs diagram what to include in the class diagram with right OOP relationship and getter settersCoursework Description
Objectives
The aim of this coursework is to assess the knowledge and skills that you have acquired about object-oriented programming
during the module. You are asked to implement a program in which objects interact in order to fulfil a set of functional
requirements.
Analyse the problem statement
An important skill that you will start to develop in this module is analysing a problem statement in order to identify the details
needed to develop a solution.
In this assignment, the first task you should perform is a careful analysis of the problem statement in order to make sure you
have all the information to elaborate a solution. If you have any questions, please write your queries on the forum on BB.
Problem description and requirement statement
You are required to develop a program to manage an online shopping system.
You should implement a console system from where the manager can add new products, delete if needed, print and save them
as described in detail below.
You should implement a Graphical User Interface (GUI) from where a user can select different products, add them to the
shopping cart and visualise the final price, etc., as described below.
For the user interface, you are not allowed to use drag-and-drop tools (such as the Designer in NetBeans), and you cannot use
Java FX, but you can use some external API if you want to add graphs or some more professional components.
In this assignment, you will be required to address the following tasks:
Design and class implementation (Phase 1)
The design of your system should be consistent with the Object-oriented principles and easy to understand by an independent
programmer.
You are required to design your program using UML diagrams. In particular, you have to draw:
A UML use case diagram for the system (6 marks).
A UML class diagram (6 marks)
Read carefully the following requirements. It is important that you follow the specifications, and your design and
implementation must comply with these.
According to the Inheritance and encapsulation principles, you have to design and implement a super-class Product and the
subclasses Electronics and Clothing. Also, you will have to add at least one constructor for each class.
The class Product should be abstract and include appropriate get/set methods and hold information about the product ID
(mix of characters and numbers), product name, number of available items and the price (4 marks).(You can add any other
information that you consider appropriate).
In particular:
The Electronics subclass should hold specific information and methods. You should add the brand and the warranty
period as instance variables, constructors, and the relative get/set methods (3 marks).
The Clothing subclass should hold specific information and methods. You should add the size and colour as instance
variables (attribute), constructors and the relative get/set methods (3 marks).
You should implement a class User to represent the user account. The class should hold information about the
username and password, constructors, and the relative get/set methods (3 marks).
You should implement a class ShoppingCart to represent the user's cart. The class should contain a list of products
as instance variable, there should be methods to add, remove and calculate the total cost (3 marks).

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Relational Database Design With Microcomputer Applications

Authors: Glenn A. Jackson

1st Edition

0137718411, 978-0137718412

More Books

Students also viewed these Databases questions

Question

Consistently develop management talent.

Answered: 1 week ago

Question

Create a refreshed and common vision and values across Europe.

Answered: 1 week ago

Question

Provide the best employee relations environment.

Answered: 1 week ago