Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Design (Fruit Mini Market System); the system sells the fruits and stores some details about Fruits like Fruit name, original or not, date, product price,

Design (Fruit Mini Market System); the system sells the fruits and stores some details about Fruits like Fruit name, original or not, date, product price, and company name.

And allows customers to buys the fruits and vegetables. Also; the market has customers and employees (which all is person).

- Each person has a name and address.

- Each employee has a salary which is private, and section name that works on it (fruit, vegetable, or cashier).

- Each employee has a supervisor and may be one of them has a supervision on himself.

- When the person (either employee or customer) starts to deals with the system; he/she has to add himself to the system with his own username and password.

(hint: the system must have constructor to add the person with his user name and password and is he employee or customer). - Write a print() method in the main class that takes the person and decide is he employee or customer and print his type).

1. Draw the UML diagram for the classes and its relationships,

2. Implement the classes. (hint: dont forget to write setter and getter methods for each data field).

3. Write a test program that creates a Person, Employee, Customer, and Fruit classes, and invokes their print() methods.

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

Object Databases The Essentials

Authors: Mary E. S. Loomis

1st Edition

020156341X, 978-0201563412

More Books

Students also viewed these Databases questions