Index
Steps
House Sketch
Roof Components
Door Components
Object Diagram
Template
First Try
Conclusion
Steps
House Sketch
We're going to model (code) a very simple house.
The components are shown in this sketch.
Roof Components
We have a variety of different roof types we can use.
GableRoof
FlatRoof
CurvedRoof
GreenRoof
ComboRoof
DomeRoof
We generally call any of these type
"Roof"
Door Components
We have a variety of different roof types we can use.
FrenchDoor
PatioDoor
WoodEntryDoor
FiberglassEntryDoor
SteelEntryDoor
We generally call any of these type
"Door"
Object Diagram
Time to take a cut at an object diagram.
We try to have the object diagram model (mimic) the real world or domain.
So we browse over our sketches again.
Template
Here is an object diagram template.
The three ivars shown are just for the template.
We may have anywhere between zero to many ivars (our idea).
House ---- ivar1 -------- ivar1Type ---- ivar2 -------- ivar2Type ---- ivar3 -------- ivar3Type etc
📋
First Try
Come up with your first try of an object diagram
House ---- ivar1 -------- ivar1Type ---- ivar2 -------- ivar2Type ---- ivar3 -------- ivar3Type etc
📋
Conclusion
What things did we learn about coming up with object ideas?
Coding Fundamentals
Chapter 201 - Ideas-Mode (Code Evaporation)
Example 4 -- House
Search Site
Home
Back To Top