Dr. Javier Gonzalez-Sanchez
[email protected]
www.javiergs.info
o
ffi
ce: 14 -227
CSC 307
Introduction to Software Engineering
Lecture 05. Software Design
Slide 2
Slide 2 text
Homework
1. Due today: Paint-App
Slide 3
Slide 3 text
Homework
2. Due today: Game-of-Life
Slide 4
Slide 4 text
Previously
Slide 5
Slide 5 text
Tools
We need a Tool
Slide 6
Slide 6 text
Task Board
6
Slide 7
Slide 7 text
Software Design
Slide 8
Slide 8 text
Activities
8
Slide 9
Slide 9 text
Software Design
De
f
inition
To cre
a
te
a
speci
f
ic
a
tion
of
a
softw
a
re (solution)
Gr
a
phic
a
l
Abstr
a
ct
Description
(blueprint)
9
model
Slide 10
Slide 10 text
Whiteboard
10
Slide 11
Slide 11 text
Design
11
VS
Slide 12
Slide 12 text
Error Smells
Slide 13
Slide 13 text
Structural models
Structur
a
l models of softw
a
re displ
a
y the org
a
niz
a
tion of
a
system in terms of
a
) the p
a
rts (items, elements, components) th
a
t m
a
ke up th
a
t system
a
nd
b) their rel
a
tionships.
13
Slide 14
Slide 14 text
UML Diagrams
14
Slide 15
Slide 15 text
Class diagram
Cl
a
ss di
a
gr
a
ms show the cl
a
sses in
a
system
• modi
f
iers
• Attributes
• methods
And the rel
a
tionships between these cl
a
sses:
• Associ
a
tion / Dependency
• Aggreg
a
tion / Composition
• Gener
a
liz
a
tion / Speci
a
liz
a
tion / Re
a
liz
a
tion
15
Slide 16
Slide 16 text
Relationships
16
Association Directed
Association
Reflexive
Association
Multiplicity
Aggregation Composition Generalization Realization
Slide 17
Slide 17 text
Let’s Work
17
Slide 18
Slide 18 text
Examples
Slide 19
Slide 19 text
Thoughts?
19
Slide 20
Slide 20 text
Thoughts?
20
Slide 21
Slide 21 text
Thoughts?
21
Slide 22
Slide 22 text
CSC3100/Cloud-Services
22
Slide 23
Slide 23 text
Your Code
23
Slide 24
Slide 24 text
Questions
24
Slide 25
Slide 25 text
Lab 05. UML Class Diagrams
Slide 26
Slide 26 text
Lab
26
Draft the Class Diagram for
___________________.
Slide 27
Slide 27 text
Problem
public class B implements E {
public B() {
C c1 = new C();
}
public void method() {
B b = new B();
b.sleep();
}
}
public class Y {
A [] a = new A[5];
}
public class A extends B {
C c1, c2;
public A() {
c1 = new C();
}
public void method() {
D d = new D();
d.working();
}
}
public class X {
public void m() {
B var = new A();
double x – Math.sqrt(5);
}
}
Slide 28
Slide 28 text
Homework
1. Due today: Paint-App
Slide 29
Slide 29 text
Homework
2. Due today: Game-of-Life
Slide 30
Slide 30 text
CSC 307 Introduction to Software Engineering
Javier Gonzalez-Sanchez, Ph.D.
[email protected]
Summer 2024
Copyright. These slides can only be used as study material for the class CSC307 at Cal Poly.
They cannot be distributed or used for another purpose.