Applications can send two classes of ToolTalk messages: notices
and requests. A notice is informational, a way for an application
to announce an event. Applications that receive a notice absorb
the message without returning results to the sender. A request is
a call for an action, with the results of the action recorded in
the message, and the message returned to the sender as a reply.
Sending Notices |
 |
When you send an informational message, the notice takes a
one-way trip, as shown in Figure 7-1.
The sending process creates a message, fills in attribute
values, and sends it. The ToolTalk service matches message and pattern
attribute values, then gives a copy of the message to one handler
and to all matching observers. File-scoped messages are automatically
transferred across session boundaries to processes that have declared
interest in the file.
Sending Requests |
 |
When you send a message that is a request, the request takes
a round-trip from sender to handler and back; copies of the message
take a one-way trip to interested observers. Figure 7-2
illustrates the request routing procedure.
The ToolTalk service delivers a request to only one handler.
The handler adds results to the message and sends it back. Other
processes can observe a request before or after it is handled, or
at both times; observers absorb a request without sending it back.
Changes in State of Sent Message |
 |
To allow you to track the progress of a request you sent,
you will receive a message every time the request changes state.
You will receive these state- change messages even if no patterns
have been registered, or no message callbacks have been specified.