Hello,

a few hours ago I got asked on IRC how one could pass non-string variables like 
in

  participant :ref => 'alpha', :something => "${v:my_array}"

I replied "you should copy the variable into a workitem field".

  http://ruote-irclogs.s3.amazonaws.com/log_2011-02-07.html

In order to make things simpler, I added a twist to the so called "dollar 
notation".

If, when all the substitutions are done, the resulting text look like

  "$f:xyz" or "$v:xyz"

and there is no { or }, the literal value in the field 'xyz' or the variable 
will be returned, not necessarily a string.

  
https://github.com/jmettraux/ruote/commit/43529d57a318a4d17a6bdde1bcb01327f853962d

(the tests the commit add may help understand this trick)

So it allows :

  participant :ref => 'alpha', :something => "$v:my_array"

I'll probably explore the benefits introduced by this technique, it can 
probably help with many expressions.

BTW, I just introduced the beginning of a :filter attribute implementation

  
https://github.com/jmettraux/ruote/commit/4e502306c50cd9bcfccaa858f8e62d3d776bd8a2

you can wrap a participant expression or any expression in an in/out filter.


If you have any question/suggestion/critic, feel free to fire, best regards,

-- 
John Mettraux - http://jmettraux.wordpress.com

-- 
you received this message because you are subscribed to the "ruote users" group.
to post : send email to [email protected]
to unsubscribe : send email to [email protected]
more options : http://groups.google.com/group/openwferu-users?hl=en

Reply via email to