Hi,
I'm trying to apply the concepts from the book in a real world
application which main domain is access control. But I got stuck on
early stages with a basic question: what about functions? The book
talks a lot about communicating objects throught asynchronous signals,
which trigger non-blocking procedures on the receiving objects. It
seems there isn't any single case through all the book case study
(order management) of an object needing to wait for another object
response before taking some execution path decision (if/then/else).
Instead, all the decisions showed there were based on query (select)
results.
Initialy I thought there is no need to an object to wait a response
from another, because the second object would send a signal to the
former when it had arrived at some state or condition that the former
needs to know, which seems to corroborate to the idea of no controller
objects too. But my system has a lot of decision points of the form:
In object A:
if some condition related to object B holds true, then do this; else
do that. ("do this" and " do that" do not modify B's state)
...and in object B:
if some condition related to object C holds true, then return true;
else return false.
...and in object C:
if some condition related to object D holds true, then return true;
else return false.
And so on.
This compounds a hierarquical decision tree, where the action taken by
an object depends on a query on another object, which depends on a
query on another object, and so on. The way I modeled above, object A
only needs to talk to C. It doesn't need to know anything about B or
D's existence nor implementation, and vice-versa. How can this be
re-frased using asynchronous signals and non-blocking,
non-value-returning procedures? I can only think about it in terms of
functions and hierarquical communication, which may resemble to
controller objects.
How should this be handled using the Executable UML modelling concepts
provided in the book?
I would appreciate any enlightenment or opinion. Thanks!
Regards,
Charles Abreu