10
MTO Ordering System HENRY, HAYDEN, AND KELLIE

MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose Our project modeled an ordering system similar to Sheetz It allowed a user to order a variety

Embed Size (px)

Citation preview

Page 1: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

MTO Ordering SystemHENRY, HAYDEN, AND KELLIE

Page 2: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Purpose

Our project modeled an ordering system similar to Sheetz

It allowed a user to order a variety of food and drinks by clicking buttons on a screen

Page 3: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Key Components

GUI – Hayden State, factory, and façade patterns

Ordering – Kellie State, singleton, and observer patterns

Food Options – Henry Strategy, decorator, and template patterns

Page 4: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Development Process

First we decided on a general UML and then assigned parts to each person so that each person had three patterns

Each person came up with their own UMLs for their patterns

We coded our own parts and resolved conflicts as we put it together

Page 5: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Ordering

Singleton pattern for the order so you can not have more than one order at a time

Observer pattern for the receipt printer so the order can notify the printer when a receipt needs to be printed

State pattern for the order so different actions can happen when it is in different states

Page 6: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

State Pattern for Ordering Three States:

Idle State

In the idle state, you can just begin the order and this takes you to the ordering state

Ordering State

In the ordering state, you can add items.

You can also cancel the order which brings you back to idle and complete the order which brings you to the complete state

Complete Order State

In the complete order state you can pay for the order or cancel your order, both bring you back to the idle state

This pattern is completed in the code

Page 7: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Inventory

State pattern to keep track of availbility of product.

OutOfStockState would prevent the order from using the product if we ran out of that product.

Page 8: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

User Interface

Façade pattern used to simplify the ordering process for the user.

Factory pattern used to create the screens as we needed for the menu system.

Page 9: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Food Options

Strategy Pattern to control restrictions on the order

Template Pattern to build the food Order

Decorator Pattern to add toppings to the food order

Page 10: MTO Ordering System HENRY, HAYDEN, AND KELLIE. Purpose  Our project modeled an ordering system similar to Sheetz  It allowed a user to order a variety

Decorator Pattern for Food Orders

Adds Toppings/Condiments to the food order

Allows for toppings to be added to any food item , within that items restrictions, without having an individual class for

each possible combination

Allows for easy addition of more toppings,

or food options