7
Session Unified Modeling Language Checklist Introduction to UML Case Study: Order Processing System

Introduction to UML

Embed Size (px)

Citation preview

Page 1: Introduction to UML

1

Session

Unified Modeling Language

Checklist

Introduction to UML

Case Study: Order Processing System

Page 2: Introduction to UML

2

Introduction

UML is a modeling tool with graphical notations. It is mainly used by Business Analysts and

Software Engineers. Business Analysts use them for modeling a business flow or to define a

process. Software Engineers use UML for Object Oriented Analysis Design. UML helps software

engineers to communicate their design over the team

UML is maintained by Object Mentor Groups (OMG) a non-profit organization which is

responsible for designing the specification for UML.

How I am going to approach UML?

There are presently 13 official diagram types described by UML 2.0. These official diagrams are

classified as Structural Diagram and Behavioral Diagram. Figure 1 shows UML classification

1. Structural Diagram – These diagrams deal with technical aspects of the system. How the

functional blocks are modeled in a system.

2. Behavioral Diagram – These diagrams deal with the functional flow or process of a

system.

What to do with all these diagrams?

When the project complexity increases we need some of these diagrams as a

communication medium across all the stake holders in the project. Stakeholders with

different backgrounds will be part of the project. UML diagrams help each stakeholder

to understand the system.

With different diagrams it is easy to pinpoint the logical mistakes. It will help us to invest

our efforts where it is required.

Page 3: Introduction to UML

3

Figure 1: UML Classification Diagram

Page 4: Introduction to UML

4

Case Study

I am firm believer in “Learning by doing”. I am going to use this case study in further articles to

learn “How to construct” UML diagrams. The case study presented here is a scaled down

version of Order processing system. As every project starts with gathering requirements, let us

go through the requirements and understand the problem before us.

The Problem Statement

A computer store wants to acquire an automated tool for placing orders. An order may be

placed by a single registered customer. Customers can edit or remove the order before they

pay. An order is considered valid if there is at least one item and ordered items are in stock. The

system should keep track of the inventory. Customers can make their order confirmation by

paying the net amount. They can pay by cash or by using credit card. An invoice is given after

servicing the order.

Some additional requirements when customer uses credit card.

1. The credit card must be under the name of the customer

2. The validity of the credit card must exceed at least two weeks the current date of the

order servicing

3. The credit level must exceed the amount due of the order

Note:

You will see the problem statement changing from session to session. I have to do this because

you will have an opportunity to use as much concepts available in each session.

FAQ’s ?...

Let’s get an overall picture of How’s? & Why’s? before proceeding to the details of modeling. I

have listed some questions that I had in mind before starting to learn UML. Feel free to skip

them if you are familiar with the background of UML.

Page 5: Introduction to UML

5

1. Who uses UML?

UML is used by Business Analyst, Programmers and Project Managers. It is not confined

to Software Industry alone, although software industry is the key player in using UML.

Business Analyst use UML to gather requirements from their clients and understand the

business process. They use UML as a communicating medium to help programmers

understand what is required out of the system.

Programmers use UML to design the system. They use UML to assign responsibilities to

engineers. Engineers use these modular level diagrams to construct the system.

Project Management use UML to improve the performances of a business process,

monitor the development life cycle.

2. Will I be using all the diagrams?

No, it depends on what role you play in your project. For instance, if you are a developer

you will use Class diagram, Object diagram and sequence diagram to construct a

particular module of a system.

3. I have seen projects which don’t give much concern about UML? Is it so? Why?

Yes, that is true. It depends upon the project methodology you are using.

One such example is Extreme programming model where the model is mainly focused

on coding. It strips out unimportant aspects like documentation/modeling. Clients

communicate and work with programmers to deliver the product.

But in case of other models like Waterfall, Agile and Iterative process UML is an integral

part of the process. Some business processes even have a separate team for modeling

diagrams.

4. Will this set of articles deal with Model Driven Architecture?

No, Model Driven Architecture is still in its development stage and is not widely used. In

addition to it, MDA is a whole topic which I could not address them in these set of

articles.

Page 6: Introduction to UML

6

5. Where does UML fit in a project life cycle?

UML is de-facto in forward engineering; people use to design before they begin to code.

In reverse engineering it is used for understanding the code. Some Integrated

Development Environments (IDE’s) have the capability to generate source code from

UML diagrams.

6. Where are the references for these articles?

There is no specific book or online course as reference for my articles. Web is my

resource; it has wealth of information for you to refer.

7. How can I draw these UML diagrams? What is the development environment required

for using UML?

Just like other programming languages, UML too has its share of modeling tools in the

market. Wikipedia list all the modeling tools here.

8. How to choose my modeling tools?

It is a trick question to answer but I will try to be honest. Choosing a modeling tool

depends upon your requirement and why you need it.

If you are a student who needs to learn using UML then my best bet is to try open

source projects.

If you are a team leader who is a position to select the tool which is required for your

team then I would suggest looking through the usability, whether team collaboration

feature is supported and technical support from the vendor is good before choosing

one.

There is a stack overflow discussion going on here which will help to keep your first foot.

Page 7: Introduction to UML

7

Review

UML is a modeling language maintained by Object Mentor Group

UML diagrams are used by various stake holders in a project

There are 13 official diagrams supported by UML 2.0

The case study to be used in these article is Order processing system