SE Session1

You might also like

Download as ppsx, pdf, or txt
Download as ppsx, pdf, or txt
You are on page 1of 42

oftware Engineering Essentials

Objectives
In this session, you will learn to:

Understand the case study: StarLine Airways


Identify the current system of StarLine Airways
Identify the envisioned system of StarLine Airways
Analyze the system of StarLine Airways
Create the Use Case diagram
Create the Class diagram

NIIT Ltd.

Page 1 of 42

oftware Engineering Essentials

Case Study: StarLine


Airways

Page 2 of 42

oftware Engineering Essentials


Case Study: StarLine Airways
Started its operations in January 2008 with a single aircraft
operating between New York and Chicago.
Earned the prestigious Service Excellence award for customer
satisfaction.
Earned a profit of $1 million in the first year of its operation.
Substantially increased customer base over the past five
years.
At present, has two Boeing and two Airbus aircrafts.

NIIT Ltd.

Page 3 of 42

oftware Engineering Essentials


Flight Sectors of StarLine Airways
It offers ten flights that operate in the following ten sectors:
New York Chicago

Chicago New York

New York New


Orleans

New Orleans New


York

New York Miami

Miami New York

New York
Pittsburgh

Pittsburgh New York

New York Memphis

Memphis New York

Each flight operates two times a week.


NIIT Ltd.

Page 4 of 42

oftware Engineering Essentials


Flight Details
The details about the flight are listed in the following table.
Flight #

NIIT Ltd.

Sector

Days

Aircraft
Type

Local
Local
Departur Arrival
e Time
Time

Fares ($)
Business Economy
Class
Class

HA101

NY-CH

Wed, Sat

Airbus

08:55

12:00

330

250

HA222

NY-NO

Mon, Thu

Airbus

11:30

18:17

380

330

HA141

NY-MI

Tue, Fri

Boeing

06:30

11:45

310

260

HA901

NY-PI

Mon, Thu

Airbus

08:55

10:40

150

120

HA875

NY-ME

Tue-Sun

Boeing

06:30

10:10

330

240

HA102

CH-NY

Wed, Sat

Airbus

06:25

12:31

330

250

HA223

NO-NY

Mon, Thu

Airbus

06:20

12:31

380

330

HA142

ME-NY

Tue, Fri

Boeing

12:20

05:50

310

260

HA902

PI-NY

Mon, Thu

Airbus

07:00

08:30

150

100

HA876

ME-NY

Tue, Fri

Boeing

06:20

12:10

330

240

Page 5 of 42

oftware Engineering Essentials


Seating Layout for Aircrafts
The seating layout for Airbus is summarized in the following
Seating Layout for Airbus
table.
Class
Business
class

Seat
Arrangement
AB
EF GH

Economy AB
CDEF
class
GH
Total Number of Seats

No. of
Rows
10
35

Total Seats
6 seats * 10 rows =
60 seats
8 seats * 35 rows =
280 seats
340 seats

The seating layout for Boeing is summarized in the following


Seating Layout for Boeing
table.
Seat
Arrangement
Business
ABC DE FG
class
HJK
Economy
ABC DEFG
class
HJK
Total Number of Seats
Class

NIIT Ltd.

No. of
Rows
4
30

Total Seats
10 seats * 4 rows
= 40 seats
10 seats * 30 rows
= 300 seats
340 seats
Page 6 of 42

oftware Engineering Essentials

The Current System

Page 7 of 42

oftware Engineering Essentials


The Current System of StarLine Airways
StarLine Airways has a number of reservation offices in each
city where the flights operate.
Each reservation office has a number of reservation counters
to handle reservations and cancellations.
Each counter has a counter assistant who is responsible for
making reservations or cancellations.
Reservations for a flight commence 30 days before the date
of the flight.

NIIT Ltd.

Page 8 of 42

oftware Engineering Essentials


Ticket Reservation
On receiving a request for reservation from a customer, the
counter assistant:

Accepts the date, departure city, and destination city from the
person and checks for the availability of a seat on the requested
date.
Maintains details about the availability of seats and the seat in the
Reservation file.
Confirms the details with the prospective passenger and accepts the
remaining details.
Updates the seat availability status in the Reservation file and adds
the passenger
details to the Manifest file. The passenger is assigned a unique
Passenger Name Request (PNR) number.
Prints the ticket and gives it to the
passenger.
Collects the fare amount from the passenger.
Updates the Daily Collection file.
NIIT Ltd.

Page 9 of 42

oftware Engineering Essentials


Ticket Reservation (Contd.)
StarLine Airways also provides overbooked or wait-listed
tickets.
Overbooking is allowed for 10 seats per flight.
For example, if the capacity of an aircraft is 340 seats,
bookings are made for 350 seats, that is, 340 seats plus 10
overbooked tickets.
An overbooked or wait-listed passenger is accommodated on
the flight depending on the availability of a seat when the
passenger checks in.
A passenger who cannot be accommodated on the flight is
given full refund.

NIIT Ltd.

Page 10 of 42

oftware Engineering Essentials


Cancel Reservation
On receiving a cancellation request from a passenger, the
counter assistant:

Retrieves the details from the Manifest file using the PNR number.
Verifies the details of the ticket and computes the refund amount.
Updates the seat availability status in the Reservations file and marks the
corresponding details of the Manifest file.
Makes the refund and prints the refund receipt.
Files the receipt along with the signature of the passenger.
Updates the Daily Collection file.

NIIT Ltd.

Page 11 of 42

oftware Engineering Essentials


Cancel Reservation (Contd.)
The confirmed tickets are subject to cancellation rules, as
shown in the following table.

NIIT Ltd.

Cancellation Time
More than one day before scheduled
departure of the flight

Cancellation Charges
NIL

Less than one day before scheduled


departure of the flight

10 percent of the ticket


amount

Page 12 of 42

oftware Engineering Essentials


Passenger List and Daily Collection Summary
Report

At the end of each day, the employees of the Operations


department:

Print the list of passengers (confirmed and wait-listed)


on the flights departing before 9:00 A.M. the next day.

Employees of the Operations


department

Print the daily collection summary report.

NIIT Ltd.

Page 13 of 42

oftware Engineering Essentials

The Envisioned System

Page 14 of 42

oftware Engineering Essentials


The Envisioned System
The new system must provide the following functionalities:

Allow the counter


assistants to make
reservations for
customers.

Allow the counter


assistants to cancel the
reservations.

Allow the employees of


StarLine Airways to print
the confirmed passenger
list, waiting list, and daily
collections report.

Allow users to book


tickets online by using a
Web-based interface.

Allow users to make


online inquiries about the
availability of tickets.

Allow users to check the


status of their
reservations online.

Allow users to cancel


their reservations online.

NIIT Ltd.

Allow an administrator to
enter flight, aircraft,
class, and sector details.

Page 15 of 42

oftware Engineering Essentials


UML Diagrams for the Envisioned System
In order to develop the software system for StarLine Airways,
you need to analyze the existing system and create a design
for the envisioned system by using UML.
To achieve the preceding task, you need to create the
following UML diagrams:

Activity
diagram
(for any use
case)

State
diagram
(for any
object)

Communica
Sequence
tion
diagram
diagram
(for any use
(for any use
case)
case)

Class
diagram

Use case
diagram
NIIT Ltd.

Page 16 of 42

oftware Engineering Essentials

System Analysis

Page 17 of 42

oftware Engineering Essentials


Discussion
Discuss and identify the users that will interact with the
system of StarLine Airways.
Also discuss the system functionality needed for each user.

NIIT Ltd.

Page 18 of 42

oftware Engineering Essentials


System Analysis
After the analysis of the current system and the envisioned
system, the following users have been identified:

Counter assistants

Employees of the Operations department

Customers

Administrators

NIIT Ltd.

Page 19 of 42

oftware Engineering Essentials


Functions for Counter Assistant
Functionalities to be implemented for the counter assistant:

Book tickets

Print tickets

Cancel tickets

NIIT Ltd.

Page 20 of 42

oftware Engineering Essentials


Functions for Operations Executive
Functionalities to be implemented for the Operations executive:

Create the confirmed passengers report.

Create the wait-listed passengers report.

Create the daily collection report.

NIIT Ltd.

Page 21 of 42

oftware Engineering Essentials


Functions of Web-based Interface and
Administrators

Functionalities to be implemented on the Web-based interface for


the customers:
Book a ticket online.

Cancel an existing reservation.

Check for the availability of seats.

Check the status of reservation.

NIIT Ltd.

Page 22 of 42

oftware Engineering Essentials

Creating the Use Case


Diagram

Page 23 of 42

oftware Engineering Essentials


Creating the Use Case Diagram
A use case is used to:
Represent a list of steps or interactions between a user and a
system to fulfill a requirement.
Describe the interactions between the use cases and actors of the
proposed software system.

To create the use case diagram for the proposed system, first
you need to identify the actors and the use cases.
The following actors will interact with the StarLine Airways
system:

NIIT Ltd.

Customer

Counter assistant

Operations executive

Administrator

Page 24 of 42

oftware Engineering Essentials


Discussion
Discuss and identify the use cases for each actor of the
system.

NIIT Ltd.

Customer

Counter assistant

Operations executive

Administrator

Page 25 of 42

oftware Engineering Essentials


Identifying the Use Cases
The following use cases may exist in the StarLine Airways
system:

NIIT Ltd.

Check
Availability

Reserve
Tickets

Print Tickets

Process
Payment

Cancel Tickets

Update
Reservation
Status

Validate
Passenger
Details

Check
Reservation
Status

Refund
Payment

Generate
Confirmed
Passengers
Report

Generate Waitlisted
Passengers
Report

Generate Daily
Collection
Report

Update Flight
Details

Update Aircraft
Details

Page 26 of 42

oftware Engineering Essentials


Discussion
Discuss and identify the relationships that can exist in the use
case diagram of StarLine Airways.
Break into groups and create the use case diagrams.

NIIT Ltd.

Page 27 of 42

oftware Engineering Essentials


Use Case Diagram of the StarLine Airways System
The following figure shows a possible use case diagram of the
StarLine Airways system.
System

Print
Tickets

Check
Availability
Customer

<<include>>
<<include>>
Reserve
Tickets

<<include>>
Cancel
Tickets

Counter Assistant

Check
Reservation
Status

Update
Reservation
Status

<<include>>

<<include>>

Validate
Passenger
Details

Refund
Payment

Generate Daily
Collection Report

Operations Executive

Process
Payment

Generate Confirmed
Passengers Report

Update Flight
Details

Update
Aircraft Details

Administrator

Generate Wait-listed
Passengers Report

NIIT Ltd.

Page 28 of 42

oftware Engineering Essentials

Creating the Class


Diagram

Page 29 of 42

oftware Engineering Essentials


Creating the Class Diagram
A class diagram is used:
For visualizing and describing the aspects of a system based on
the object-oriented approach.
To describe the attributes, methods, and any constraints for the
various classes that can be created for the required system.

To create the class diagram for the proposed system, you


need to identify the classes, their attributes and methods,
and the relationships between the classes.

NIIT Ltd.

Page 30 of 42

oftware Engineering Essentials


Discussion
Discuss and identify the classes that can exist in the class
diagram of StarLine Airways.
List down the attributes and operations in each class.
Consider the visibility of each attribute.

NIIT Ltd.

Page 31 of 42

oftware Engineering Essentials


Identifying the Classes
The following classes can be created in the StarLine Airways
system:

NIIT Ltd.

Page 32 of 42

oftware Engineering Essentials


Properties of Classes
The following table lists the classes and their attributes along
with their visibilities.
Class
Passenger

Ticket

NIIT Ltd.

Attributes
PassengerName

Visibility
Private

Age

Private

Address

Private

Contact_no

Private

Seat_preference

Private

Meal_preference

Private

Gender

Private

SSR

Private

PNR_no

Private

Ticket_no

Private

Date_of_issue

Private

Status

Private

Class

Private
Page 33 of 42

oftware Engineering Essentials


Properties of Classes (Contd.)
Class
Flight
Reservation

Flight

NIIT Ltd.

Attributes
Flight_no

Visibility
Private

Date_of_flight

Private

BusinessClass_availableseats

Private

EconomyClass_availableseats

Private

Flight_no

Private

From_city

Private

To_city

Private

Departure_time

Private

Arrival_time

Private

Days_of_flight

Private

Businessclass_fare

Private

Economyclass_fare

Private

Page 34 of 42

oftware Engineering Essentials


Properties of Classes (Contd.)
Class
Aircraft

NIIT Ltd.

Attributes
Aircraft_name

Visibility
Private

Totalseats_businessclass

Private

Totalseats_economyclass

Private

Page 35 of 42

oftware Engineering Essentials


Class Operations
The following table lists the operations that are performed by
theClass
classes. Operations
Description
Visibility
Passenger

getPassengerDetails
()
setPassengerDetails
()
validateDetails()

Ticket

bookTicket()

printTicket()
cancelTicket()
printCancellationRe
ceipt()
processPayment()

NIIT Ltd.

Retrieves the passenger


details from the
database.
Updates the passenger
details after input from
the system user.
Validates whether the
passenger details exist
in the database or not.
Reserves a seat for a
passenger on a flight
and books a ticket for
the same.
Prints a reserved ticket.
Cancels a reserved
ticket.
Prints a receipt for the
refund money in case of
ticket cancellation.
Calculates the payment
to be made by a
customer for a ticket
booking and updates
the details in the

Public
Public
Public
Public

Private
Public
Private
Private

Page 36 of 42

oftware Engineering Essentials


Class Operations (Contd.)
Class
Ticket

Operations
processRefund()
checkReservationSt
atus()
updateReservationS
tatus()

Flight
Reservati
on

updateSeatAvailabi
lity()

checkSeatAvailabil
ity()

NIIT Ltd.

Description
Computes the amount to be
refunded to the customer in
case of ticket cancellation.
Allows the customer to check
whether his/her reservation
status is confirmed or waiting
through the online portal.
Updates the status of a ticket
from confirmed to cancelled,
waiting to confirmed, or
waiting to cancelled.
Updates the number of seats
available in a particular class
of a flight, based on the
reservation or cancellation of
tickets.
Checks if seats are available
in a particular class of a
particular flight.

Visibility
Private
Public

Public

Public

Public

Page 37 of 42

oftware Engineering Essentials


Class Operations (Contd.)
Class
Flight

Operations
getFlightDetails()
setFlightDetails()
matchSector()

Aircraft

NIIT Ltd.

getAircraftDetails
()
setAircraftDetails
()

Description
Retrieves the details of a
flight from the database.
Updates the flight details
based on inputs from a
system user.
Gets a flight that matches a
particular sector.
Retrieves the details of an
aircraft from the database.
Updates the aircraft details
after input from system user.

Visibility
Public
Public
Public
Public
Public

Page 38 of 42

oftware Engineering Essentials


Discussion
Discuss and identify the relationships that exist among
classes.

NIIT Ltd.

Page 39 of 42

oftware Engineering Essentials


Class Relationships
Association relationships can exist in the following classes of
the system:

NIIT Ltd.

Page 40 of 42

oftware Engineering Essentials


Class Diagram of StarLine Airways
The following figure shows a possible class diagram for
Ticket
StarLine
Airways.
Passenger
-PassengerName: string
-Age: int
-Address: string
-Contact_no: long
-Seat_preference: string
-Meal_preference: string
-Gender: char
-SSR: string

-PNR_no: long
-Ticket_no: int
-Date_of_issue: date
-Status: string
-Class: string

+getPassengerDetails()
+setPassengerDetails()
+validateDetails()

+bookTicket()
-printTicket()
+cancelTicket()
+printCancellationReceipt()
-processPayment()
-processRefund()
+checkReservationStatus()
+updateReservationStatus()

Flight Reservation

-Flight_no: string
-Date_of_flight: date
-Businessclass_availableseats: int
-Economyclass_availableseats: int
+updateSeatAvailability()
+checkSeatAvailability()
1

Flight

Aircraft
-Aircraft_name: string
-Totalseats_businessclass: int
-Totalseats_economyclass: int
+getAircraftDetails()
+setAircraftDetails()

-Flight_no: int
-From_city: string
-To_city: string
-Departure_time: time
-Arrival_time: time
-Days_of_flight: string
-Businessclass_fare: float
-Economyclass_fare: float
+getFlightDetails()
+setFlightDetails()
+matchSector()

NIIT Ltd.

Page 41 of 42

oftware Engineering Essentials


Summary
In this session, you learned that:
A use case is used to represent a list of steps or interactions
between a user and a system to fulfill a requirement.
You can create a use case diagram to describe the interactions
between the use cases and actors of the proposed software
system.
To create the use case diagram for the proposed system, first you
need to identify the actors and the use cases.
A class diagram is used for visualizing and describing the aspects
of a system based on the object-oriented approach. It can then be
used to construct the executable code of the software application.
You can use a class diagram to describe the attributes, methods,
and any constraints for the various classes that can be created for
the required system.
To create the class diagram for the proposed system, you need to
identify the classes, their attributes and methods, and the
relationships between the classes.
NIIT Ltd.

Page 42 of 42

You might also like