Hi John et al.,

I went through earlier thread as well.
Is it possible to refer a subprocess with just 'internal' Ruby
definition instead of a URL (either local storage or remote) ?

An intuitive analogous example to cite would be 'rake' tasks. In
'rake' DSL, the task dependencies are mapped such that they are
resolved 'internally'. An example of such process reference is at the
end of the post.

Of course, the suggestion is pretty superficial and without any
knowledge of internals of OpenWFE.

Thanks for your time and efforts.

./harshal

For example -

-----8<-----

p1.rb :

OpenWFE.process_definition :name => 'p1' do
  sequence do
    participant "a"
    participant "b"
    participant "c"
  end
end

p2.rb :

OpenWFE.process_definition :name => 'p2' do
  sequence do
    subprocess :ref => OpenWFE::Processes.get_process('p1') # Or
something similar
    participant "d"
  end
end
----->8-----


On Apr 9, 6:20 pm, John Mettraux <[email protected]> wrote:
> On Thu, Apr 9, 2009 at 3:05 PM, Makarand <[email protected]> wrote:
>
> > In this case, can we somehow reuse P1 in P2 and P3 ?
>
> Hi Makarand,
>
> thanks for having read my answer 
> athttp://groups.google.com/group/openwferu-users/browse_frm/thread/932a...
>
> p1.rb :
>
> OpenWFE.process_definition :name => 'p1' do
>   sequence do
>     participant "a"
>     participant "b"
>     participant "c"
>   end
> end
>
> p2.rb :
>
> OpenWFE.process_definition :name => 'p2' do
>   sequence do
>     subprocess :ref => 'p1.rb'
>     participant "d"
>   end
> end
>
> There is also :
>
> OpenWFE.process_definition :name => 'p1' do
>   sequence do
>     ('a'..'c').to_a.each { |ref| participant ref }
>   end
> end
>
>  http://openwferu.rubyforge.org/expressions.html#exp_subprocess
>
> 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