Slide 1

Slide 1 text

No content

Slide 2

Slide 2 text

No content

Slide 3

Slide 3 text

No content

Slide 4

Slide 4 text

Edges Spaces Relationships Lights/Shadows Gestalt

Slide 5

Slide 5 text

Modeling on the Right Side of the Brain An introduction to the five basic skills of Object Modeling ! Nicholas Henry #motrsb

Slide 6

Slide 6 text

Objects Collaborations Business Rules Services Attributes

Slide 7

Slide 7 text

Anatomy of Domain Model

Slide 8

Slide 8 text

Anatomy of Domain Model

Slide 9

Slide 9 text

Anatomy of Domain Model

Slide 10

Slide 10 text

Anatomy of Domain Model

Slide 11

Slide 11 text

Other Concerns

Slide 12

Slide 12 text

Heart of your Application

Slide 13

Slide 13 text

No content

Slide 14

Slide 14 text

User Stories Rails Application The Gap ?

Slide 15

Slide 15 text

Use Object Modeling to bridge the gap between User Stories and implementing Domain Models

Slide 16

Slide 16 text

No content

Slide 17

Slide 17 text

NO BIG UPFRONT DESIGN

Slide 18

Slide 18 text

Objects have responsibilities

Slide 19

Slide 19 text

Objects have responsibilities

Slide 20

Slide 20 text

Objects have responsibilities

Slide 21

Slide 21 text

Objects have responsibilities

Slide 22

Slide 22 text

Objects have responsibilities

Slide 23

Slide 23 text

Collaborations Business Rules Services Attributes Finding Objects

Slide 24

Slide 24 text

Collaborations Solution Challenge

Slide 25

Slide 25 text

Archetypes

Slide 26

Slide 26 text

Event Archetype

Slide 27

Slide 27 text

Event Archetype

Slide 28

Slide 28 text

Role Archetype

Slide 29

Slide 29 text

Party-Place-Thing Archetype

Slide 30

Slide 30 text

Description Archetype

Slide 31

Slide 31 text

makeMomentInterval addDetail calcTotal recalcTotal complete cancel mi_generateNext mi_assessWRTPrior mi_assessWRTNext mi_comparePlanVsActual listMIs assessAcrossMIs «moment-interval» MomentInterval number dateOrDateTimeOrInterval priority total status «moment-interval» NextMI «moment-interval» PriorMI calcTotal qty «mi-detail» MomentIntervalDetail 0..* 1 0..* 1 Interacts - With its pink mi-details - With its pink prior moment-intervals - With its pink next moment-intervals - With its corresponding yellow roles, green party/place/things, or blue descriptions plan 0..* actual 0..1 1 1..* makeMomentInterval interface «plug-in point» IMakeMomentInterval 1 assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» ThingRole assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» PlaceRole assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» PartyRole 0..* 1 0..* 1 0..* 0..* assessAcrossRoles getCustomElseDefaultValue listRoles listThings assessAcrossThings serialNumber name address customerValue «thing» Thing assessAcrossRoles getCustomElseDefaultValue listRoles listPlaces assessAcrossPlaces serialNumber name address customerValue «place» Place assessWithPlugInElseDefault accessAcrossPlaces findAvailable calcQtyAvailable calcTotalFor listPlaces listDescs accessAcrossDescs type description itemNumber defaultNumber «description» PlaceDescription 0..* 1 assess interface «plug-in point» IAssess assessWithPlugInElseDefault accessAcrossThings findAvailable calcQtyAvailable calcTotalFor listThings listDescs accessAcrossDescs type description itemNumber defaultNumber «description» ThingDescription 0..* 1 assess interface «plug-in point» IAssess assessWithPlugInElseDefault accessAcrossParties findAvailable calcQtyAvailable calcTotalFor listParties listDescs accessAcrossDescs type description itemNumber defaultNumber «description» PartyDescription 0..* 1 assess interface «plug-in point» IAssess assessAcrossRoles getCustomElseDefaultValue listRoles listParties assessAcrossThings serialNumber name address customerValue «party» Party Interacts with its yellow roles or its pink moment-intervals Interacts with its green parties or its pink moment-intervals Interacts with its pink moment-intervals 1 0..* 0..1 0..1 1 0..* 1 0..* 0..1 The domain-neutral component. If you do not need to track a specific green, then drop the been and the yellow; the blue is enough. If just one hello for a green, keep the portioning if useful, else drop the yellow. If you do not need to track a specific green, then drop the been and the yellow; the blue is enough. If just a category attribute, move the attribute to the green and drop the blue.

Slide 32

Slide 32 text

Archetypes

Slide 33

Slide 33 text

Archetypes

Slide 34

Slide 34 text

Archetypes

Slide 35

Slide 35 text

Archetypes

Slide 36

Slide 36 text

Archetypes

Slide 37

Slide 37 text

makeMomentInterval addDetail calcTotal recalcTotal complete cancel mi_generateNext mi_assessWRTPrior mi_assessWRTNext mi_comparePlanVsActual listMIs assessAcrossMIs «moment-interval» MomentInterval number dateOrDateTimeOrInterval priority total status «moment-interval» NextMI «moment-interval» PriorMI calcTotal qty «mi-detail» MomentIntervalDetail 0..* 1 0..* 1 Interacts - With its pink mi-details - With its pink prior moment-intervals - With its pink next moment-intervals - With its corresponding yellow roles, green party/place/things, or blue descriptions plan 0..* actual 0..1 1 1..* makeMomentInterval interface «plug-in point» IMakeMomentInterval 1 assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» ThingRole assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» PlaceRole assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» PartyRole 0..* 1 0..* 1 0..* 0..* assessAcrossRoles getCustomElseDefaultValue listRoles listThings assessAcrossThings serialNumber name address customerValue «thing» Thing assessAcrossRoles getCustomElseDefaultValue listRoles listPlaces assessAcrossPlaces serialNumber name address customerValue «place» Place assessWithPlugInElseDefault accessAcrossPlaces findAvailable calcQtyAvailable calcTotalFor listPlaces listDescs accessAcrossDescs type description itemNumber defaultNumber «description» PlaceDescription 0..* 1 assess interface «plug-in point» IAssess assessWithPlugInElseDefault accessAcrossThings findAvailable calcQtyAvailable calcTotalFor listThings listDescs accessAcrossDescs type description itemNumber defaultNumber «description» ThingDescription 0..* 1 assess interface «plug-in point» IAssess assessWithPlugInElseDefault accessAcrossParties findAvailable calcQtyAvailable calcTotalFor listParties listDescs accessAcrossDescs type description itemNumber defaultNumber «description» PartyDescription 0..* 1 assess interface «plug-in point» IAssess assessAcrossRoles getCustomElseDefaultValue listRoles listParties assessAcrossThings serialNumber name address customerValue «party» Party Interacts with its yellow roles or its pink moment-intervals Interacts with its green parties or its pink moment-intervals Interacts with its pink moment-intervals 1 0..* 0..1 0..1 1 0..* 1 0..* 0..1 The domain-neutral component. If you do not need to track a specific green, then drop the been and the yellow; the blue is enough. If just one hello for a green, keep the portioning if useful, else drop the yellow. If you do not need to track a specific green, then drop the been and the yellow; the blue is enough. If just a category attribute, move the attribute to the green and drop the blue.

Slide 38

Slide 38 text

makeMomentInterval addDetail calcTotal recalcTotal complete cancel mi_generateNext mi_assessWRTPrior mi_assessWRTNext mi_comparePlanVsActual listMIs assessAcrossMIs «moment-interval» MomentInterval number dateOrDateTimeOrInterval priority total status «moment-interval» NextMI «moment-interval» PriorMI calcTotal qty «mi-detail» MomentIntervalDetail 0..* 1 0..* 1 Interacts - With its pink mi-details - With its pink prior moment-intervals - With its pink next moment-intervals - With its corresponding yellow roles, green party/place/things, or blue descriptions plan 0..* actual 0..1 1 1..* makeMomentInterval interface «plug-in point» IMakeMomentInterval 1 assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» ThingRole assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» PlaceRole assessAcrossMIs listMIs listRoles accessAcrossRoles assignedNumber status «role» PartyRole 0..* 1 0..* 1 0..* 0..* assessAcrossRoles getCustomElseDefaultValue listRoles listThings assessAcrossThings serialNumber name address customerValue «thing» Thing assessAcrossRoles getCustomElseDefaultValue listRoles listPlaces assessAcrossPlaces serialNumber name address customerValue «place» Place assessWithPlugInElseDefault accessAcrossPlaces findAvailable calcQtyAvailable calcTotalFor listPlaces listDescs accessAcrossDescs type description itemNumber defaultNumber «description» PlaceDescription 0..* 1 assess interface «plug-in point» IAssess assessWithPlugInElseDefault accessAcrossThings findAvailable calcQtyAvailable calcTotalFor listThings listDescs accessAcrossDescs type description itemNumber defaultNumber «description» ThingDescription 0..* 1 assess interface «plug-in point» IAssess assessWithPlugInElseDefault accessAcrossParties findAvailable calcQtyAvailable calcTotalFor listParties listDescs accessAcrossDescs type description itemNumber defaultNumber «description» PartyDescription 0..* 1 assess interface «plug-in point» IAssess assessAcrossRoles getCustomElseDefaultValue listRoles listParties assessAcrossThings serialNumber name address customerValue «party» Party Interacts with its yellow roles or its pink moment-intervals Interacts with its green parties or its pink moment-intervals Interacts with its pink moment-intervals 1 0..* 0..1 0..1 1 0..* 1 0..* 0..1 If you do not need to track a specific green, then drop the been and the yellow; the blue is enough. If just one hello for a green, keep the portioning if useful, else drop the yellow. If you do not need to track a specific green, then drop the been and the yellow; the blue is enough. If just a category attribute, move the attribute to the green and drop the blue.

Slide 39

Slide 39 text

No content

Slide 40

Slide 40 text

Archetypes

Slide 41

Slide 41 text

Objects Identifying Collaborations Business Rules Services Attributes

Slide 42

Slide 42 text

VS Collaborations Associations

Slide 43

Slide 43 text

Objects have responsibilities

Slide 44

Slide 44 text

Collaborations Solution Challenge

Slide 45

Slide 45 text

Elementary Collaboration Pattern

Slide 46

Slide 46 text

Example

Slide 47

Slide 47 text

PPT vs Description Archetypes

Slide 48

Slide 48 text

PPT vs Description Archetypes

Slide 49

Slide 49 text

PPT vs Description Archetypes

Slide 50

Slide 50 text

PPT vs Description Archetypes

Slide 51

Slide 51 text

Composite Pattern

Slide 52

Slide 52 text

Follow-up Pattern

Slide 53

Slide 53 text

Example

Slide 54

Slide 54 text

Example

Slide 55

Slide 55 text

Example

Slide 56

Slide 56 text

Example

Slide 57

Slide 57 text

Event Aggregate Pattern

Slide 58

Slide 58 text

Objects Collaborations Defining Business Rules Services Attributes

Slide 59

Slide 59 text

Business Rules Solution Challenge

Slide 60

Slide 60 text

Collaborations require dialog

Slide 61

Slide 61 text

total_weight expedited «event» Shipment max_weight duration «description» ShippingMethod shipment.total_weight <= max_weight Collaborations require dialog

Slide 62

Slide 62 text

total_weight expedited «event» Shipment max_weight duration «description» ShippingMethod expedited? && shipping_method.duration <= 2.days Collaborations require dialog

Slide 63

Slide 63 text

Collaborations require dialog

Slide 64

Slide 64 text

Objects Collaborations Business Rules Assigning Services Attributes

Slide 65

Slide 65 text

Objects have responsibilities

Slide 66

Slide 66 text

No content

Slide 67

Slide 67 text

Collaborations Solution Challenge

Slide 68

Slide 68 text

Objects perform actions themselves

Slide 69

Slide 69 text

Objects Collaborations Business Rules Services Assigning Attributes

Slide 70

Slide 70 text

Objects have responsibilities

Slide 71

Slide 71 text

Attributes

Slide 72

Slide 72 text

Attributes

Slide 73

Slide 73 text

Attributes

Slide 74

Slide 74 text

User Stories Rails Application The Gap ?

Slide 75

Slide 75 text

User Stories Rails Application Object Modeling

Slide 76

Slide 76 text

Next Steps

Slide 77

Slide 77 text

Next Steps

Slide 78

Slide 78 text

Next Steps

Slide 79

Slide 79 text

Next Steps

Slide 80

Slide 80 text

Objects Collaborations Business Rules Services Attributes

Slide 81

Slide 81 text

nicholas@firsthand.ca @nicholasjhenry Nicholas Henry http://bit.ly/motrsb