[otj-users] Develop Teams independent of base classes

Stephan Herrmann stephan at cs.tu-berlin.de
Thu Jan 17 21:15:12 CET 2008


Hi,

> I just started to work with ObjectTeams, so please pardon my beginner
> questions :-)
No problem!
 
> Is it possible to develop teams independent of the base classes they
> will use? It seems, by binding roles to their possible base classes via
> "playedBy" the base class must be known to the team developer. Is that
> right?

At the moment when you declared bindings (playedBy, callout, callin)
you must indeed know what you are binding to.

You may, however, implement teams and roles completely _omitting_
any bindings, and later extend the (perhaps abstract) team using 
team inheritance in order to add those bindings.
This is what we call a "connector" team. This should actually be
documented in our patterns section at
	http://trac.objectteams.org/ot/wiki/OtPatterns
I will add a description sometime soon. Until then you may refer
to the OTSample-FlightBonus example that ships with the OTDT.
(Install into your workspace via "Help -> Welcome -> Samples ...")

In this example the team Bonus is defined independent of any base classes.
The sub team FlightBonus adds (almost) no implementation but is used to
bind inherited roles and their methods to corresponding elements in the 
base application.

As a special goody select FlightBonus in the package explorer and invoke
from the context menu "Open Binding Editor ...".
This dialog is designed specifically for point-and-click style definition
of said "connectors" ;-)

Does this answer your question?
Stephan



More information about the otj-users mailing list