You are on page 1of 7

Made by:Sushil Kumar Mishra (ECE-I) Roll no.

05311502809

Overview
A sequence diagram shows, as parallel vertical lines (lifelines), different processes or objects that live simultaneously, and, as horizontal arrows, the messages exchanged between them, in the order in which they occur. This allows the specification of simple runtime scenarios in a graphical manner. For instance, the UML 1.x diagram on the right describes the sequences of messages of a (simple) restaurant system. This diagram represents a Patron ordering food and wine, drinking wine then eating the food, and finally paying for the food. The dotted lines extending downwards indicate the timeline. Time flows from top to bottom. The arrows represent messages (stimuli) from an actor or object to other objects. For example, the Patron sends message 'pay' to the Cashier. Half arrows indicate asynchronous method calls.

Example:

Sequence Diagram - Login

: User

: SignIn.aspx

: EditAccount.aspx

1: user provides requested information 2: new : User

3: verifyLogin(userName:String,password:String)

4: Verify

5: [IsVerify]

Sequence diagram shows that user successfully login for editing his/her account

Sequence Diagram Making a Reservation

: User

: FindHotel.aspx

: Hotel Chain

: HotelResult.aspx

: RoomPref erences.aspx

:Conf irmReserv ation.aspx

1: prov ide requested inf ormation 2: f indHotel(city :String, state:String) 3: new

: Hotel

4: f indHotel(city :String, state:String)

5: v erif y 6: [IsVerif y ]

7: selectHotel() 8: room pref erences

9: select room pref erences 10: new : Room

11: getRoomAv l()

12: v erif y 13: reserv e 14: [IsVerif y ] new : Reserv ation

15: makeReserv ation(r:Reserv ation)

16: Verif y

17: [IsVerif y ] conf irmation

This sequence diagram shows successf ull reserv ation and user already logged in. Operation Signature: getRoomAv l(hotelID : String, bedTy pe : String, smoking : String, checkIn : Date, checkOut : Date) : Room

Sequence Diagram Canceling a Reservation


: User : CancelReservation.aspx : ConfirmCancelReservation.aspx

1: provides requested information 2: new : Reservation

3: getReservation(reservationNumber:Integer)

4: cancel()

5: cancelReservation(reservationNumber:Integer)

6: verify

7: [IsVerify]

Sequence Diagram Requesting an Account

: Agent

: RequestAccount.aspx

: Mail

1: provide requested information 2: new : TravelAgent

3: requestAccount() 4: verify 5: [verify] sendMail(e_address:String)

The sequence diagram shows that the travel agent successfully applies to an account. Operation Signature: requestAccount(userName : String, email : String, password : String, companyName : String, status : String, phone : String, address : String, city : String, state : String, zip : String) : Boolean

Sequence Diagram Generating a Report

: Agent

: Report.aspx

: TravelAgent

1: provides requested information 2: generateReport(startingDate:Date, endingDate:Date)

3: Report

You might also like