
OutputActionsAttribute |
ptolemy.domains.fsm.kernel.OutputActionsAttribute |
An action that sends outputs to one or more ports.
This action is contained by a transition,
and is evaluated whenever that transition becomes enabled. The evaluation
is done in the fire() method of the FSMActor that contains the
transition (hereafter called "the FSM actor").
Note that the fire() method may be invoked more than once in an
iteration, particularly in domains where there is iteration to a fixed point,
such as CT. To specify an action that is executed only when the
transition is taken (in the postfire() method), use the class
CommitActionsAttribute.
<p>
The value of this attribute is a semicolon separated list of commands,
where each command gives a destination port to send data to and a value
to send. The actions are given by calling setExpression() with
a string of the form:
<pre>
<i>command</i>; <i>command</i>; ...
</pre>
where each <i>command</i> has the form:
<pre>
<i>destination</i> = <i>expression</i>
</pre>
where <i>destination</i> is either
<pre>
<i>portName</i>
</pre>
or
<pre>
<i>portName</i>(<i>channelNumber</i>)
</pre>
where <i>portName</i> is the name of a port of the FSM actor.
If no <i>channelNumber</i> is given, then the value
is broadcast to all channels of the port.
<p>
The <i>expression</i> is a string giving an expression in the usual
Ptolemy II expression language. The expression may include references
to variables and parameters contained by the FSM actor.
Author(s): Xiaojun Liu, Edward A. Lee, Haiyang Zheng
Version:$Id: OutputActionsAttribute.doc.html,v 1.1 2006/02/22 18:41:22 mangal Exp $
Pt.Proposed Rating:Red (hyzheng)
Pt.Accepted Rating:Red (hyzheng)