ahbadawy
Newbie level 3
Contents
AN INTRODUCTION TO THE UML 7
What is the UML? 7
A Common Language 7
Summary 9
THE UML WITHIN A DEVELOPMENT PROCESS 10
The UML as a Notation 10
The Waterfall Model 10
The Spiral Model 12
Iterative, Incremental Frameworks 13
Inception 13
Elaboration 14
Construction 14
Transition 15
How Many Iterations? How Long Should They Be? 15
Time Boxing 16
Typical Project Timings 16
The Rational Unified Process 17
Summary 18
OBJECT ORIENTATION 19
Structured Programming 19
The Object Orientated Approach 22
Encapsulation 23
Objects 23
Terminology 24
The Object Oriented Strategy 24
Summary 25
AN OVERVIEW OF THE UML 26
The Use Case Diagram 27
The Class Diagram 28
Collaboration Diagrams 29
Sequence Diagram 30
State Diagrams 31
Package Diagrams 32
Component Diagrams 33
Deployment Diagrams 34
Summary 34
THE INCEPTION PHASE 35
4 UML Applied - Object Oriented Analysis and Design using the UML
2001 Ariadne Training Limited www.ariadnetraining.co.uk
THE ELABORATION PHASE 37
Deliverables 37
Summary 38
USE CASE MODELLING 39
Actors 39
The Purpose of Use Cases 40
Use Case Granularity 41
Use Case Descriptions 43
Use Cases at the Elaboration Phase 43
Finding Use Cases 44
Joint Requirements Planning Workshops (JRP) 44
Brainstorming Advice 45
Summary 45
CONCEPTUAL MODELLING 46
Finding Concepts 47
Extracting Concepts From Requirements 47
The Conceptual Model in the UML 48
Finding Attributes 49
Guidelines for Finding Attributes 50
Associations 50
Possible Cardinalities 51
Building the Complete Model 51
Summary 53
RANKING USE CASES 54
Summary 55
THE CONSTRUCTION PHASE 56
Construction 56
Summary 57
THE CONSTRUCTION PHASE : ANALYSIS 58
Back to the Use Cases 58
1. Pre-Conditions 59
2. Post Conditions 59
3. Main Flow 59
Alternate Flows 60
Exception Flows 60
The Complete Use Case 61
The UML Sequence Diagram 61
Summary 63
5 UML Applied - Object Oriented Analysis and Design using the UML
2001 Ariadne Training Limited www.ariadnetraining.co.uk
THE CONSTRUCTION PHASE : DESIGN 64
Design - Introduction 64
Collaboration of Objects in Real Life 65
Collaboration Diagrams 66
Collaboration Syntax : The Basics 66
Collaboration Diagrams : Looping 68
Collaboration Diagrams : Creating new objects 68
Message Numbering 68
Collaboration Diagrams : Worked Example 69
Some Guidelines For Collaboration Diagrams 72
Chapter Summary 73
DESIGN CLASS DIAGRAMS 74
Crediting and Debiting Accounts 74
Step 1 : Add Operations 75
Step 2 : Add Navigability 75
Step 3 : Enhance Attributes 75
Step 4 : Determine Visibility 76
Aggregation 76
Composition 77
Finding Aggregation and Composition 77
Summary 77
RESPONSIBILITY ASSIGNMENT PATTERNS 78
The GRASP Patterns 78
What is a pattern? 78
Grasp 1 : Expert 78
Grasp 2 : Creator 80
Grasp 3 : High Cohesion 81
Grasp 4 : Low Coupling 83
Grasp 5 : Controller 86
Summary 87
INHERITANCE 88
Inheritance – the basics 88
Inheritance is White Box Reuse 90
The 100% Rule 91
Substitutability 91
The Is-A-Kind-Of Rule 92
Example - Reusing queues through inheritance 92
Problems With Inheritance 94
Visibility of Attributes 95
Polymorphism 96
Abstract Classes 97
The Power of Polymorphism 98
Summary 99
6 UML Applied - Object Oriented Analysis and Design using the UML
SYSTEM ARCHITECTURE - LARGE AND COMPLEX SYSTEMS 100
The UML Package Diagram 100
Elements Inside a Package 101
Why Packaging? 101
Some Packaging Heuristics 102
Expert 102
High Cohesion 102
Loose Coupling 102
Handling Cross Package Communication 102
The Facade Pattern 104
Architecture-Centric Development 105
Example 105
Handling Large Use Cases 106
The Construction Phase 107
Summary 107
MODELLING STATES 108
Example Statechart 108
State Diagram Syntax 109
Substates 110
Entry/Exit Events 111
Send Events 111
Guards 111
History States 112
Other Uses for State Diagrams 112
Summary 113
TRANSITION TO CODE 114
Synchronising Artifacts 114
Mapping Designs to Code 115
Defining the Methods 117
Step 1 118
Step 2 118
Step 3 119
Step 4 119
Mapping Packages into Code 119
In Java 119
In C++ 120
The UML Component Model 120
Ada Components 121
Summary 121
AN INTRODUCTION TO THE UML 7
What is the UML? 7
A Common Language 7
Summary 9
THE UML WITHIN A DEVELOPMENT PROCESS 10
The UML as a Notation 10
The Waterfall Model 10
The Spiral Model 12
Iterative, Incremental Frameworks 13
Inception 13
Elaboration 14
Construction 14
Transition 15
How Many Iterations? How Long Should They Be? 15
Time Boxing 16
Typical Project Timings 16
The Rational Unified Process 17
Summary 18
OBJECT ORIENTATION 19
Structured Programming 19
The Object Orientated Approach 22
Encapsulation 23
Objects 23
Terminology 24
The Object Oriented Strategy 24
Summary 25
AN OVERVIEW OF THE UML 26
The Use Case Diagram 27
The Class Diagram 28
Collaboration Diagrams 29
Sequence Diagram 30
State Diagrams 31
Package Diagrams 32
Component Diagrams 33
Deployment Diagrams 34
Summary 34
THE INCEPTION PHASE 35
4 UML Applied - Object Oriented Analysis and Design using the UML
2001 Ariadne Training Limited www.ariadnetraining.co.uk
THE ELABORATION PHASE 37
Deliverables 37
Summary 38
USE CASE MODELLING 39
Actors 39
The Purpose of Use Cases 40
Use Case Granularity 41
Use Case Descriptions 43
Use Cases at the Elaboration Phase 43
Finding Use Cases 44
Joint Requirements Planning Workshops (JRP) 44
Brainstorming Advice 45
Summary 45
CONCEPTUAL MODELLING 46
Finding Concepts 47
Extracting Concepts From Requirements 47
The Conceptual Model in the UML 48
Finding Attributes 49
Guidelines for Finding Attributes 50
Associations 50
Possible Cardinalities 51
Building the Complete Model 51
Summary 53
RANKING USE CASES 54
Summary 55
THE CONSTRUCTION PHASE 56
Construction 56
Summary 57
THE CONSTRUCTION PHASE : ANALYSIS 58
Back to the Use Cases 58
1. Pre-Conditions 59
2. Post Conditions 59
3. Main Flow 59
Alternate Flows 60
Exception Flows 60
The Complete Use Case 61
The UML Sequence Diagram 61
Summary 63
5 UML Applied - Object Oriented Analysis and Design using the UML
2001 Ariadne Training Limited www.ariadnetraining.co.uk
THE CONSTRUCTION PHASE : DESIGN 64
Design - Introduction 64
Collaboration of Objects in Real Life 65
Collaboration Diagrams 66
Collaboration Syntax : The Basics 66
Collaboration Diagrams : Looping 68
Collaboration Diagrams : Creating new objects 68
Message Numbering 68
Collaboration Diagrams : Worked Example 69
Some Guidelines For Collaboration Diagrams 72
Chapter Summary 73
DESIGN CLASS DIAGRAMS 74
Crediting and Debiting Accounts 74
Step 1 : Add Operations 75
Step 2 : Add Navigability 75
Step 3 : Enhance Attributes 75
Step 4 : Determine Visibility 76
Aggregation 76
Composition 77
Finding Aggregation and Composition 77
Summary 77
RESPONSIBILITY ASSIGNMENT PATTERNS 78
The GRASP Patterns 78
What is a pattern? 78
Grasp 1 : Expert 78
Grasp 2 : Creator 80
Grasp 3 : High Cohesion 81
Grasp 4 : Low Coupling 83
Grasp 5 : Controller 86
Summary 87
INHERITANCE 88
Inheritance – the basics 88
Inheritance is White Box Reuse 90
The 100% Rule 91
Substitutability 91
The Is-A-Kind-Of Rule 92
Example - Reusing queues through inheritance 92
Problems With Inheritance 94
Visibility of Attributes 95
Polymorphism 96
Abstract Classes 97
The Power of Polymorphism 98
Summary 99
6 UML Applied - Object Oriented Analysis and Design using the UML
SYSTEM ARCHITECTURE - LARGE AND COMPLEX SYSTEMS 100
The UML Package Diagram 100
Elements Inside a Package 101
Why Packaging? 101
Some Packaging Heuristics 102
Expert 102
High Cohesion 102
Loose Coupling 102
Handling Cross Package Communication 102
The Facade Pattern 104
Architecture-Centric Development 105
Example 105
Handling Large Use Cases 106
The Construction Phase 107
Summary 107
MODELLING STATES 108
Example Statechart 108
State Diagram Syntax 109
Substates 110
Entry/Exit Events 111
Send Events 111
Guards 111
History States 112
Other Uses for State Diagrams 112
Summary 113
TRANSITION TO CODE 114
Synchronising Artifacts 114
Mapping Designs to Code 115
Defining the Methods 117
Step 1 118
Step 2 118
Step 3 119
Step 4 119
Mapping Packages into Code 119
In Java 119
In C++ 120
The UML Component Model 120
Ada Components 121
Summary 121