commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rahul Akolkar" <rahul.akol...@gmail.com>
Subject Re: [SCXML] Forward eventdata within transition
Date Fri, 01 Jun 2007 22:51:36 GMT
On 6/1/07, Ingmar Kliche <ingmar.kliche@googlemail.com> wrote:
> Rahul,
>
> within a transition (which is gets eventdata from outside) I'd like to
> forward some pieces of the eventdata structure using a <send> with namelist:
>
> <transition event="change">
>      <if cond = "_eventdata.eventSource == 'x'">
>           <send targettype="GUI" target="'y'" event="change" namelist="
> _eventdata.eventValue" />
>      </if>
> </transition>
> As it does obviously not work it seems to me that the _eventdata structure
> is not accessible within a <send> tags namelist. Is this intended? I think
> it would be helpful. As a work around I save the value temporarily to the
> data model using <assign name="temp" expr="_eventdata.eventValue"/> and use
> "temp" within the send tags namelist attribute. But it would be more
> convenient to access it directly. What do you think?
>
<snip/>

Namelist is treated as a space-separated list of variable names (as it
seems to imply). From your example, '_eventdata.eventValue' is an
expression. So, its the difference between a 'get' and an 'evaluate'
(which also explains why the 'temp' bit works).

I think either the attribute should be renamed (by the WG) or spec
should better clarify what each token is. Until then, I think we
should be treating those as variable names, as we do now.

-Rahul


> --Ingmar.
>
> PS: I'm using 0.7-SNAPSHOT.
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message