merged
merged
presentation
BITS Pilani Paramananda Barik
Pilani Campus CS&IS Department
BITS Pilani
Pilani Campus
SSZG514/SEZG512,
Object Oriented Analysis and Design
Lecture No.1
Review of Object-Oriented
Programming
Key OOP Concepts
– Object, Class
– Instantiation, Constructors
– Encapsulation
– Inheritance and Subclasses
– Abstraction
– Reuse
– Polymorphism, Dynamic Binding
Object-Oriented Design and Modeling
Object creation
Memory is allocated for the object’s fields as
defined in the class
Initialization is specified through a constructor
– a special method invoked when objects are
created
Inheritance:
– programming language feature that allows
for the implicit definition of
variables/methods for a class through an
existing class
Subclass relationship
– B is a subclass of A
– B inherits all definitions
(variables/methods) in A
“Many forms”
– allow several definitions under a single
method name
Example:
– “move” means something for a person object
but means something else for a car object
Dynamic binding:
– capability of an implementation to distinguish
between the different forms during run-time
SSZG514/SEZG512,
Object Oriented Analysis and Design
Lecture No.2
Difference Between
Procedural and OOP
▪ Both Procedural Programming and Object
Oriented Programming are high-level
languages in programming world and are
widely used in the development of
applications.
▪ On the basis of nature of developing the
code, both languages have different
approaches on basis of which both are
differentiate from each other.
SSZG514/SEZG512,
Object Oriented Analysis and Design
Lecture No.2
“
▪ Horizontal prototype
Broad view of entire system/sub-system
Focus is on user interaction more than low-level
system functionality (e.g. , databsae access)
Useful for:
■ Confirmation of UI requirements and system scope
■ Demonstration version of the system to obtain
buy-in from business/customers
■ Develop preliminary estimates of development
time, cost, effort
Dimensions of Prototyping
▪ Vertical prototype
More complete elaboration of a single sub-system
or function
Useful for:
■ Obtaining detailed requirements for a given function
■ Refining database design
■ Obtaining info on system interface needs
■ Clarifying complex requirements by drilling down to
actual system functionality
Types of prototyping
▪ Low-fidelity
Paper/pencil
■ Mimics the functionality, but does not look like it
Fidelity of Protype
▪ Medium to High-fidelity
GUI builder
“Click dummy” prototype – looks like the system, but
does not provide the functionality
Or provide functionality, but have it be general and not
linked to specific data
http://www.youtube.com/watch?v=VGjcFouSlpk
http://www.youtube.com/watch?v=5oLlmNbxap4&fea
ture=related
Throwaway Prototyping steps
▪ Typical activities
Develop project plan
Develop configuration management plan
Develop a test plan
Develop an installation plan
Spiral Model Strengths
▪ http://www.youtube.com/watch?v=kkkl3Lucx
TY&feature=related
Housekeeping
▪ Individual Assignment:
Post mortem + peer review
▪ Final presentations/demos
July 26/28 - 25 minutes per
■ ~8 minute presentation
■ ~10 minute demo
■ ~7 minutes questions
▪ Course evaluations this Thursday (4:05 pm)
The Rise and Fall of
Waterfall
▪ http://www.youtube.com/watch?v=X1c2--sP3
o0&NR=1&feature=fvwp
▪ Warning: bad language at 3:50! (hands over
ears if easily offended!)
AGILE SOFTWARE DEVELOPMENT
LIFE CYCLES
Agile SDLC’s
▪ http://en.wikipedia.org/wiki/Joint_application
_design
CASE Tools
▪ http://en.wikipedia.org/wiki/Computer-aided
_software_engineering
Construction Phase
SSZG514/SEZG512,
Object Oriented Analysis and Design
Lecture No.3
Unified Process (UP) Model
Inception
Elaboration(milestone)
Conception(release)
Transition(final production release)
It is use-case driven
It is architecture-centric
It is risk focused
It is iterative and incremental
The disciplines (Analysis, Design, Coding The disciplines are generally done
and Testing ) are done iteratively and sequentially (e.g. Coding only starts once
concurrently. Requirements have been completed and
signed-off)
SSZG514/SEZG512,
Object Oriented Analysis and Design
Lecture No.3 and 4
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
UP : Phases &
Disciplines
Phases of the Unified Process
154
BITS Pilani, Deemed to be
University under Section 3 of
What is “Agility”?
Yielding …
155
BITS Pilani, Deemed to be
University under Section 3 of
An Agile Process
157
BITS Pilani, Deemed to be
University under Section 3 of
Principles of Agility
• Build projects around motivated individuals. Give them the
environment and support they need, and trust them to get
the job done.
• The most efficient and effective method of conveying
information to and within a development team is
face-to-face conversation.
• Working software is the primary measure of progress.
• Agile processes promote sustainable development. The
sponsors, developers, and users should be able to maintain a
constant pace continuously.
158
BITS Pilani, Deemed to be
University under Section 3 of
The Manifesto for Agile
Software Development
“We are uncovering better ways of developing
software by doing it and helping others do it.
Through this work we have come to value”
159
BITS Pilani, Deemed to be
University under Section 3 of
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
eXtreme Programming
(XP)
eXtreme Programming (XP)
163
BITS Pilani, Deemed to be
University under Section 3 of
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
SCRU
M
SCRUM
4
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
SCRUM Process Flow
Agile
Modelling
Agile Modeling (AM)
3
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
Test Driven
Development
Test Driven Development
Write a test
Refactor code
Compile
(and test)
• Revisit, Optimize
• Refactoring in
– Programming
– Design
177
BITS Pilani, Deemed to be
University under Section 3 of
Continuous Integration (CI)
• 2 Ways of testing
– Big-bang fashion
– Continious Integration (CI)
178
BITS Pilani, Deemed to be
University under Section 3 of
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
Overview of
UML
What is UML?
Class Relationships in
UML
Inheritance: superclass &
subclass
Styles of Use
Cases
Styles of Use Cases
• Essential: Focus is on intend.
– Avoid making UI decisions
• Concrete: UI decisions are embedded
in the use case text.
– e.g. “Admin enters ID and password in the
dialog
box (see picture X)”
– Concrete style not suitable during early
requirements analysis work.
Styles of Use
Cases
Styles of Use Cases
• Essential: Focus is on intend.
– Avoid making UI decisions
• Concrete: UI decisions are embedded
in the use case text.
– e.g. “Admin enters ID and password in the
dialog
box (see picture X)”
– Concrete style not suitable during early
requirements analysis work.
Paramananda Barik
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
BITS
Pilani
Pilani|Dubai|Goa|Hyderabad
What is Domain
Model?
Domain
Model
• A Domain Model illustrates meaningful concepts in a
problem domain.
• It may show:
– concepts
– associations between concepts
– attributes of concepts
Multiplicity
Relationship
Association
Attributes
Significance of Domain
Model
Domain Model :
Partial?
Significance of
SSD
Significance of
SSD
• Interaction of the system with the outside
world
• It is used to depict how System responses to
external events
• It plays key role in GUI design of the system
What is Operation
Contracts
Why Operation
Contracts?
• Details missing from System Sequence
Diagram
• What an Analyst Reflect in Operation
Contract?
– show extensions
• use the <<extends>> relationship
What is Interaction
Diagram?
What is Interaction Diagram?
Types of Interactions
Diagram
Types of Interaction
Diagrams
What is Activity
Diagram?
What is Activity
Diagram
• They show the sequence of flow activities
involved in a process.
• Used to model dynamic aspects of a system
• Like Flowchart showing flow of control from
activity to activity
• Are used when you have multiple activities
going on at the same time.
• Initial state
• Final state
• Fork and join
– model concurrent f
lows
• Activities
Place Order
– Step in overall Process
• Transitions
– Triggered by end of previous activity and initiates next
activity
Fulfill Order
Place Order
Start State
[yes]
[yes] End State
Create
Account
BITS Pilani
Pilani | Dubai | Goa | Hyderabad
BITS Pilani
Pilani | Dubai | Goa | Hyderabad
Message:
getProductDesc
ProductCatalogue must be
visible to Register for
interaction to take place.
Attribute Visibility
Attribute Visibility
Object B will be visible to Object A
If
B is an attribute of A.
Parameter Visibility
Parameter Visibility
Object B will be visible to Object A
If
Object B is a parameter of a method in A
Local Visibility
Local Visibility
Object B may be said to be visible to Object A
If
Object B is a local object (non-parameter) in a method of Object A.
• Replace relationships by
indicating attribute types.
• In Figure you see that the
customer has a
shippingAddress attribute of
type Address – part of the
scaffolding code to maintain
the association between
customer objects and address
objects.
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
BITS Pilani
Pilani | Dubai | Goa | Hyderabad
An interface can be
defined as
collection of
operation signature
and/or attribute
definitions that
ideally defines a
cohesive set of
behaviors.
• Also: http://agilemodeling.com/style/packageDiagram.htm
• http://www.uml-diagrams.org/package-diagrams.htm
• In a layered architecture
model, classes within
each subsystem layer
provide services to the
layer above it.
• Also: http://agilemodeling.com/style/packageDiagram.htm
• http://www.uml-diagrams.org/package-diagrams.htm
Package can be used as a template for other Package template Service Provider and bound
packages. These are called package package Scheduler Service.
template and template package.
• Packageable element can be used as
a template parameter.
• A package template parameter may
refer to any element owned or used by
the package template, or templates
nested within it.
• A package may be bound to one or more
template packages.
• When several bindings are applied the
result of bindings is produced by taking
the intermediate results and merging
them into the combined result
using package merge.
• Also: http://agilemodeling.com/style/packageDiagram.htm
• http://www.uml-diagrams.org/package-diagrams.htm
• Also: http://agilemodeling.com/style/packageDiagram.htm
• http://www.uml-diagrams.org/package-diagrams.htm
• Also: http://agilemodeling.com/style/packageDiagram.htm
• http://www.uml-diagrams.org/package-diagrams.htm
BITS Pilani
Pilani|Dubai|Goa|Hyderabad
Paramananda Barik
BITS Pilani
Pilani|Dubai|Goa|Hyderabad
UI Layer :SaleJFrame
enterItem(id, quantity)
:ProcessSaleHandler
Choices for Controller
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
System Behavious Analysis
The assignment of
System Register
endSale() ...
enterItem()
makeNewSale()
makePayment()
endSale()
enterItem()
makeNewSale()
responsibility for systems
makeNewReturn()
enterReturnItem()
...
makePayment()
makeNewReturn()
operation may be
assigned to one or more
enterReturnItem()
...
system operations
discovered during system
allocation of system
operations during design, classes. See examples on
left.
behavior analysis using one facade controller
ProcessSale HandleReturns
System Handler Handler
allocation of system
operations during design,
using several use case
controllers
• Controller is basically a
delegation pattern. presses button
logic.
• Controller pattern common
1: enterItem(itemID, qty)
work request.
• Controller is a façade for
the domain layer from UI
layer.
1: makeLineItem(itemID, qty)
Domain Layer :Sale
<<interfacer>> calTax()
ITaxCalculator
Sale <<actor>>
Tax Calculator
ITaxCalculator c = … findTax()
c.calTax( )
TaxCalculator
Adapter
Using Indirection
lookup
Client EJB