Skip to main content
Jump to: navigation, search

Difference between revisions of "OTJ Primer"

(New page: The programming language OT/J introduces two '''new kinds of classes''' * Image:Team_obj.gif '''Teams''' * Image:Role_obj.png '''Roles''' However, it is much more interest...)
 
m (Role Containment)
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
 +
{{Tip|Is this the right level for me?|
 +
* If you're quite rushed maybe the [[Object_Teams_Quick-Start|Object Teams Quick-Start]] is better suited.
 +
* If, on the other hand, you look for literature on the background of the concepts of Object Teams, the list of scientific [http://www.objectteams.org/publications publications] has all you need. From these, the following is the most comprehensive recent coverage of Object Teams: [http://www.objectteams.org/publications/#JAO07 A Precise Model for Contextual Roles: The Programming Language ObjectTeams/Java] -- (Journal Applied Ontology 2007)
 +
 +
This page with its sub-pages tries to cover the middle ground, addressing readers who do want to learn the essential concepts of Object Teams without the burden of a detailed scientific discussion.
 +
 +
Throughout this text references into the [http://www.objectteams.org/def/1.3 OT/J Language Definition] are given like this (see {{otjld|0|}}), where the interested reader will find the detailed definitions.}}
 +
 
The programming language [[OTJ|OT/J]] introduces two '''new kinds of classes'''
 
The programming language [[OTJ|OT/J]] introduces two '''new kinds of classes'''
 
* [[Image:Team_obj.gif]] '''Teams'''
 
* [[Image:Team_obj.gif]] '''Teams'''
Line 26: Line 34:
 
* Roles preferably communicate with other roles.
 
* Roles preferably communicate with other roles.
 
* Roles can be confined to their enclosing team to protect them against external access
 
* Roles can be confined to their enclosing team to protect them against external access
* Data-flows between a team an its outside applies '''translation polymorphism''' to translate between roles and bases:
+
* Data-flows between a team and its outside apply '''translation polymorphism''' to translate between roles and bases:
 
** sending a role object to the outside applies '''lowering''' (role-to-base translation)
 
** sending a role object to the outside applies '''lowering''' (role-to-base translation)
 
** sending a base object into a team applies '''lifting''' (base-to-role translation)
 
** sending a base object into a team applies '''lifting''' (base-to-role translation)
Line 34: Line 42:
  
 
----
 
----
 +
 
===[[OTJ_Primer/Team_Inheritance|Team Inheritances]]===
 
===[[OTJ_Primer/Team_Inheritance|Team Inheritances]]===
  
Line 43: Line 52:
  
 
→ [[OTJ_Primer/Team_Inheritance|Details on Team Inheritances ...]]
 
→ [[OTJ_Primer/Team_Inheritance|Details on Team Inheritances ...]]
 +
 +
 +
[[Category:Object Teams]]

Latest revision as of 04:20, 3 June 2011

Idea.png
Is this the right level for me?

This page with its sub-pages tries to cover the middle ground, addressing readers who do want to learn the essential concepts of Object Teams without the burden of a detailed scientific discussion.

Throughout this text references into the OT/J Language Definition are given like this (see OTJLD §0), where the interested reader will find the detailed definitions.


The programming language OT/J introduces two new kinds of classes

  • Team obj.gif Teams
  • Role obj.png Roles

However, it is much more interesting to look at what happens between these things.
Here, OT/J introduces the following major relations:


Role Playing

RolePlaying.png

Role classes/objects are playedBy base classes/objects. The communication between the two part objects is defined using

  • callout method bindings for forwarding role-to-base
  • callin method bindings for intercepting method calls base-to-role

Details on Role Playing ...


Role Containment

RoleContainment.png

Role classes/objects are contained in a team instance.

  • Roles preferably communicate with other roles.
  • Roles can be confined to their enclosing team to protect them against external access
  • Data-flows between a team and its outside apply translation polymorphism to translate between roles and bases:
    • sending a role object to the outside applies lowering (role-to-base translation)
    • sending a base object into a team applies lifting (base-to-role translation)
  • Team activation controls the enablement of callin bindings

Details on Role Containment ...


Team Inheritances

TeamInheritance.png

  • A team class can be sub-classed including all its contained roles (similar to Java classes with inner classes)
  • A sub-team can override any of its inherited roles (different from Java inner classes).
  • An overriding role implicitly inherits from its overridden version.

Details on Team Inheritances ...

Back to the top