Vending Machine UML diagrams & Questions

Unified Modelling Language Practicals. This Subject is called as UML in Mumbai University MCA Colleges. Below is the case study of it for the construction of different UML diagrams

In This Section we are going to solve some questions of UML which were asked in University Exams.

UML Question in Exams:-

Q. Consider a vending machine. Consider the processes:

  1. Buy a beverage:The vending machine delivers a beverage after a customer selects and pays for it.
  2.  Perform Scheduled Maintenance: The repair technician performs the periodic service on the vending machine necessary to keep it in good working condition.
  3. Make repairs: The repair technician performs the unexpected service on the vending machine necessary to repair a problem in its operation.
  4. Load Items: A stock clerk adds items into the vending machine to add its stock of beverages.
Create a Use Case Diagram for this Vending Machine

Use Case Diagram :-

Use Case Diagram Vending Machine


2)

The vending machine delivers a beverage after a customer selects and pays for it. The machine starts in the waiting state in which it displays the message “Enter coins”. When the customer inserts coins into the machine, the machine enters into “Ready” state. When the customer pushes the ok button, the machine goes in “Dispense” state. In this state, the machine dispenses the corresponding item. The machine goes in “Out of Stock” state if item is not loaded. Draw the state transition diagram for above description

State Transition Diagram for Vending Machine:-

State Transition Diagram for Vending Machine

1)

The vending machine delivers a beverage after a customer selects and pays for it. The machine starts in the waiting state in which it displays the message “Enter coins”. When the customer inserts coins into the machine, the machine displays total value of money entered. The customer pushes a button. The machine dispenses a corresponding item and make change, if the cost of the item is less than the money inserted. If the cost of the item is greater than money inserted, the machine shows the message as “Insufficient money”. Draw the sequence diagram for above description.

Sequence Diagram for Vending Machine:-

Sequence Diagram for Vending Machine




Keep on Following this Site for More Notes, Programs and notes for Students.
Just search the site for More of Programs and Notes for MCA

No comments:

Post a Comment

Post a Comment