Logtalk 2.30.1 files.

git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@1903 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
pmoura
2007-06-12 10:39:47 +00:00
parent 84f478c301
commit 6b4bde14e1
475 changed files with 6213 additions and 6424 deletions

View File

@@ -32,7 +32,7 @@ In this example, we will illustrate the use of:
by defining a simple profiler that prints the starting and ending time for processing a message sent to an object.
</p>
<h2>Messages as events<a id="events"></a></h2>
<h2 id="events">Messages as events</h2>
<p>
In a pure object-oriented system, all computations start by sending messages to objects. We can thus define an <em>event</em> as the sending of a message to an object. An event can then be specified by the tuple <code>(Object, Message, Sender)</code>. This definition can be refined by interpreting the sending of a message and the return of the control to the object that has sent the message as two distinct events. We call these events respectively <code>before</code> and <code>after</code>. Therefore, we end up by representing an event by the tuple <code>(Event, Object, Message, Sender)</code>. For instance, if we send the message:
@@ -53,7 +53,7 @@ Note that the second event is only generated if the message succeeds. If the mes
Events are automatically generated by the message sending mechanisms for each public message sent using the <a title="Consult reference manual" href="../refman/control/to_object2.html"><code>::/2</code></a> operator.
</p>
<h2>Profilers as monitors<a id="monitors"></a></h2>
<h2 id="monitors">Profilers as monitors</h2>
<p>
A monitor is an object that reacts whenever a spied event occurs. The monitor actions are defined by two event handlers: <a title="Consult reference manual" href="../refman/methods/before3.html"><code>before/3</code></a> for <code>before</code> events and <a title="Consult reference manual" href="../refman/methods/after3.html"><code>after/3</code></a> for <code>after</code> events. These predicates are automatically called by the message sending mechanisms when an event registered for the monitor occurs. These event handlers are declared as public predicates in the <code>monitoring</code> built-in protocol.
@@ -120,7 +120,7 @@ yes</pre>
This call will abolish all events defined over the object <code>foo</code> assigned to the <code>stop_watch</code> monitor.
</p>
<h2>Summary<a id="summary"></a></h2>
<h2 id="summary">Summary</h2>
<ul>
<li>An event is defined as the sending of a (public) message to an object.</li>