|
SObjectizer
5.5
|
A synchronous interaction between agents is a very useful mechanism for some situations. But usage of long method call chaings for that interaction is sometimes complex and confusing. For example:
Such long method call chains are there because there was a necessity to support of compilers without proper implementation of C++11 variadic templates. But such compilers are not supported now. It means that synchronous interactions can be simplified.
Two new helper functions have been introduced in v.5.5.9:
The usage of request_future() and request_value() can be shown in comparison with old approach:
New functions also support signals as requests:
The first argument for request_future() and request_value() can be either a so_5::rt::mbox_t, a reference to so_5::rt::agent_t or a reference to ad-hoc agent proxy. For example:
1.8.14