ooad – iii software design nupul kukreja 10 th october, 2014

21
OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Upload: branden-bryant

Post on 04-Jan-2016

224 views

Category:

Documents


7 download

TRANSCRIPT

Page 1: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

OOAD – IIISoftware Design

Nupul Kukreja10th October, 2014

Page 2: OOAD – III Software Design Nupul Kukreja 10 th October, 2014
Page 3: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Agenda• Technical Architecture (TA)

– What?– Good TA– Winbook TA– Why/When?

• Detailed Design– What/How?– Sequence Diagrams (SD)

• What/Why?• How?

• Hands on In class– Robustness Diagram– High level SD– Low level SD

• Conclusion

Page 4: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

TECHNICAL ARCHITECTUREDiving Deeper

Page 5: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

•Main program and sub-routines

•Object-oriented

Language Influenced

•Virtual Machine

•Client-Server

Layered

•Batch-sequential

•Pipe-and-filter

Dataflow Styles

•Blackboard

•Rule-based

Shared Memory

•Publish/Subscribe

•Event-based

Implicit Invocation

•Interpreter

•Mobile code

Interpreter

•Representational State Transfer (e.g. WWW)

REST

•(e.g. Gnutella, Skype, Napster etc.,)

Peer-to-Peer

Page 6: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Twin Peaks: Requirements and Architecture

Requirements Architecture

General

Detailed

Level of

Detail

Implementation Dependence

Independent Dependent

Page 7: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Good Technical Architecture• Built to satisfy business and level of service

requirements of the system• Describes:– Deployment model (topology, servers etc.,)– Package/component model (separation of concerns)– Data Model (ER diagram etc.,)

• Addresses –ilities effectively (i.e., scalability, security, availability etc.,)

• Testable• Shows external systems to be interfaced with• Increase confidence of “being right”

Page 8: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Client: HTML/JS

Presentation Layer: Tomcat/Restlet

Data Access Layer: Spring/JDBC Database

Page 9: OOAD – III Software Design Nupul Kukreja 10 th October, 2014
Page 10: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Technical Architecture – When & Why?• Done much before robustness analysis– In parallel to/before requirements negotiation– Refined as more learned about system

• You must know the high-level “how” to derive the low/design-level “how”– Allocating methods to classes– Which classes/services to involve?– Which methods to call and in what order?– To think about the code before coding it

Page 11: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

SEQUENCE DIAGRAMMINGDiving into design

Page 12: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Detailed OOD• Domain modeling, use-case and robustness

analysis discovering “classes”• Detailed design “allocating” behavior i.e.,

allocating methods to classes• Works within the technical architecture defined• Reifies our initial guess of how classes really

interact with each other• Sequence diagrams are “one” way to drive

detailed design– Use case Robustness Sequence Diagram

Page 13: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Sequence Diagram Notation

Page 14: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

“Why” Sequence Diagramming• Allocate behavior to classes– Controllers operations on classes or separate

controller objects• Show detailed interaction among classes over

lifetime of use-case– “how” do objects communicate to realize use case

• Finalize distribution of operations among classes– Who’s doing what and to whom?

Page 15: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

“How” to do it?• Start from where you left off with Robustness

Analysis (RA)– One sequence diagram per use case

1. Copy the correct, detailed & explicit use case text to SD

2. Copy entity objects from RA diagram to SD3. Copy boundary objects and actors from RA

diagram to SD4. Assign operations to classes (actual thinking

work)

Page 16: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

HANDS ON EXERCISE

Page 17: OOAD – III Software Design Nupul Kukreja 10 th October, 2014
Page 18: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

A user enters the their email id and password on the login page. The system checks if the user is registered by validating their account against the set of registered users. If the user is registered he is taken to the page showing the list of projects

Alternative course:-Invalid login/ password: The system displays invalid username/ password

Page 19: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Blank 1

Page 20: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Blank 2

Page 21: OOAD – III Software Design Nupul Kukreja 10 th October, 2014

Reiteration of Steps1. Create an initial high level OO sequence diagram only

involving boundary/entity objects from RA diagram2. Add implementation level details/classes to sequence

diagram– Allocate/call appropriate framework methods

3. Review SD to validate correctness4. Update static class diagram with implementation

classes and identified methods5. Repeat for each use case6. Move to coding after thorough reviewing7. Update SD as you identify gaps in design rarely done

documentation obsolete Architectural degradation