OOD Assignment 2 (1)

docx

School

University of the Cumberlands *

*We aren’t endorsed by this school

Course

552

Subject

Computer Science

Date

Nov 24, 2024

Type

docx

Pages

3

Uploaded by MateGerbilMaster994

Report
CS552BH1 OOAD Homework Assignment #2 Fall 2023, Term 1 Rivier University CS552CH2: Object-Oriented Design Homework Assignment #2 Student’s Name : ______Karunakar Reddy Sanikommu_______ Please write clearly. Ambiguity will be penalized. Copying and pasting answers will also be penalized. You are expected to read and understand the material in the textbook and then answer the questions in your own words, based on your understanding . 1. Read Chapters 5, 6, 7 & 8 of the textbook. 2. Plot a Class Diagram for the Online Catering Service you designed in Homework #1. P a g e 1 | 3
CS552BH1 OOAD Homework Assignment #2 Fall 2023, Term 1 3. Describe each of the three parts of the UML Class representation using one of the Classes from your Class Diagram in question #2 as an example. The Unified Modeling Language (UML) offers a standardized means to visually represent systems, elucidating their components and interactions. For an Online Catering System, UML provides a comprehensive overview, encompassing various classes like User, Menu, Order, Payment, and Feedback. At the core of this system is the User class. Every user, upon joining the platform, is uniquely identified by their userID. Besides basic attributes like username, password, and email, the system necessitates functions or methods for user management. For instance, register() enables new users to create an account, while login() allows returning users to access their profiles. Users can also modify their details using the updateProfile() method. Another integral component is the Menu class, the heart of the catering service. Each item on the menu has distinct attributes like menuID, itemName, itemDescription, and itemPrice. To ensure the dynamism of the menu, methods such as addItem(), removeItem(), and updateItem() are indispensable. These functions ensure that the service providers can regularly update their offerings. Now, the actual service transaction materializes in the Order class. When a user places an order, it's uniquely identified with an orderID. The system also logs which user placed the order using the userID as a foreign key. Details like the date of order and totalAmount are also recorded. The functions here, like placeOrder(), cancelOrder(), and updateOrder(), facilitate the entire order processing flow. No transaction is complete without payment, leading us to the Payment class. Each payment gets an identity through paymentID, and its relationship with the order is established using the orderID as a foreign key. Whether a user opts for credit, debit, or an online wallet, the paymentMethod attribute captures this detail. Essential methods here include makePayment() and refundPayment(), streamlining financial transactions. 4. Plot an Object Diagram for one of the major classes in your Online Catering Service based on your Class diagram from question # 2 P a g e 2 | 3
CS552BH1 OOAD Homework Assignment #2 Fall 2023, Term 1 . P a g e 3 | 3
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help