Software Engineering
The Design Workflow

Agenda


Modeling and Simulation Model

 

Ways of using UML

  1. UML class diagrams as sketch - result of requirement analysis
  2. UML class diagrams as blueprint - result of a design process based on class sketches
  3. UML as programming language - UML diagrams are compiled directly to executable code

Design (Webster)

Object-oriented design is part of OO methodology and it forces programmers to think in terms of objects, rather than procedures, when they plan their code. An object contains encapsulated data and procedures grouped together to represent an application entity. The “object interface”, how the object can be interacted, is also defined (interaction diagrams) along with class relationships (class diagrams) in the design object model.

Implementers translate the design object model developed during the object-oriented design into a particular object-oriented language (programming). An object-oriented program is described by the interaction of design objects. Implementers use a programming paradigm that uses design objects and their interactions to write computer programs based on object-oriented techniques, including instantiation, encapsulation, modularity, polymorphism, and inheritance.


Design Artifacts - Metamodel


Artifact trace relationship

 


Should you Maintain Two Model?

Strategy   Consequences
1. Take the analysis model and refine it into a design model   You have a single design model, but you have lost the analysis model
2. Take the analysis model, refine it into a design model and use a modeling tool to recover an "analysis model"   You have a single design model, but the analysis view recovers by the modeling tool might not be satisfactory
3. Freeze the analysis model at some point in the Elaboration phase - refine a copy of the analysis model into a design model   You have two models, but they are out of step
4. Maintain two separate models - an analysis model and a design model   You have two models - they are in step, but there is a maintenance burden

It is wise to remember that many systems long outlive their project life span. Keep an analysis model for large, complex, or strategic system. They are invaluable for:


Design Workflow Detail


Architectural Design


Design a Class

 


What are design classes?

Design classes come from the problem domain and the solution domain.


Anatomy of a Design Class


Well Formed Design Classes


High Cohesion

Each class should capture a single, well-defined abstraction, using the minimal set of features.
  1. Cohesive classes are easy to understand, reuse, and maintain
  2. A cohesive class has a small set of responsibilities that are intimately related.

How to fix it?

 

Selling system:


Low Coupling

A class should be associated with the minimum number of other classes to allow it to fulfill its responsibilities.

A Paradigm for Verifying Analysis Objects and Classes


Commonality and Variability Analysis


Encapsulate, encapsulate,  encapsulate ...


Interfaces and Specialization


Inheritance vs. Aggregation

  1. Inheritance is the strongest form of coupling between classes.
  2. Encapsulation is weak within a class hierarchy. Changes to the base class ripple down to changes in subclasses.
    Changes to the base class have a large impact on other class in the system - "fragile case class"
  3. It is an inflexible relationship - fixed at runtime.



Multiple Inheritance


Nested classes


A nested (in Java inner) class is a class defined inside another class.


Design a Subsystem


What is an interface?


Subsystems and Components

  1. Component-based development is about constructing software from plug-in parts.
  2. Interfaces are key to component-based development (CBD).
  3. If you want to create flexible component-based SW for which you can plug-in new implementation at will, you must design with interfaces.
  4. UML definition: "A component represents a modular part of a system that encapsulates its contents and whose manifestation is replaceable with its environment."

 

 


Architecture and Layering Pattern


FICUS Design (Sparx Enterprise Architect Professional)

Description File Source
Silenus and Ficus Use Case Image FICUS.eap
 
Tracker Use Case Image
Ficus Components Image
Ficus Upload Sequence Diagram Image
Ficus Download Sequence Diagram

Image

Ficus Deployment Diagram Image
Ficus Class Diagram Image