Data, Context, Interation

- Lean Software Architecture for Agile Software Development (2010)

James Coplien

Trygve Reenskaug

- MVC (solved half the problem)

The Motivation

Complex business administration system

- hard to follow in the code what's going on

Code related to business processing rules was scattered across classes

Because "OO"

 

Spaghetti code

The Result

- of traditional "OO" for complex business processes

* Each domain class holds logic (business rules) from different contexts

* A single class holds just a snippet of the logic of a wider context

No container of broader contexts

Other Options

Service objects, Rails Concerns

- code still scattered, lacking a container

"In OO programming, it always happens somewhere else" !

Emergent?

A search for an alternative

AOP - the separation of cross-cutting concerns (?)

Googled

Googled..DCI

- snail oil check:

  • Proponents
  • Containment
  • Technical feasibility

What is DCI ?

It's about giving us a framework that reflects the use case

What is an object?           - identity

- can play different roles in different contexts

 

We need to draw out the interactions: roles

To reason about the behaviour of the system

(not a single object)

These interactions happen in an arena called the Context

The Context

A collection of related possible scenarios between an end user and the system

A Use Case: a sequence of tasks towards a business goal

Seamlessness between the business analysis world and the coding world

An architectural home for use cases

class Context

end

github.com/alanq/ruby-dci

The OO vision has not been realised

Alan Kay - object oriented programming was to align with the end user's mental model

"Class Oriented Programming"

- concentrates on the nouns, rather than giving us a way to model the dynamic behaviour, the end user's mental model of interactions

It would be nice if the technology in the machine were just an extension of the end user's mental model..

Title Text

- MVC does this on an object by object basis

Interface for end user to interact with system:

The job of the programmer

 - to unite mental models

We shouldn't have to do this!

The user shouldn't have to figure out how the manufacturer manufactured the product in order to use it.

Brenda Laurel

- virtual reality, video games, HCI

What happens in a program happens between the objects

It's not about the classes - they support the programmer rather than the end user

The objects come and go

 

But the network of communication between them stays the same

 

Objects may even be from different classes the next time the use case is run

A user's mental model applies a name to an object according to its use 

Objects are too small - we need something to model the system behaviour for a use case

James O. Coplien - Reflections on Reflection

slides.com/alanquigley/data-context-interation

Me

Software developer

Business analyst


FundCalcs.com founder

SimpleSchoolAdmin.com - almost founded!

Alan Quigley

Alan@FundCalcs.com

Data Context Interation

By Alan Quigley

Data Context Interation

  • 279