-
-
Notifications
You must be signed in to change notification settings - Fork 12
Implementation Role Feature 10
Max Leuthäuser edited this page Aug 7, 2015
·
3 revisions
The state of an object can be role-specific
The state of an object may vary depending on the role in which it is being addressed.
Roles are implemented with classes and their state is of course instance specific. By merging the roles instances with its player object with the play
-method (or the playing
-method) semantically they become one (compound object as I call it). At the end you have the state of the core object, the states of the role instances and the (merged) state of the resulting compound object.
None.