<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Is it possible to define a variable in a bpmn20.xml file? in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57734#M35162</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for explanation, you are completely right about injection.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For my purpose I could just use a groovy ScriptTask doing something like &lt;/SPAN&gt;&lt;CODE&gt;execution.setVariable("myVar", scriptVar)&lt;/CODE&gt;&lt;SPAN&gt; then fetching myVar in JavaDelegate's execute() via &lt;/SPAN&gt;&lt;CODE&gt;execution.getVariable()&lt;/CODE&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 25 Oct 2011 10:06:27 GMT</pubDate>
    <dc:creator>ilgrosso</dc:creator>
    <dc:date>2011-10-25T10:06:27Z</dc:date>
    <item>
      <title>Is it possible to define a variable in a bpmn20.xml file?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57732#M35160</link>
      <description>Hi,I need to parametrize a UserTask (i.e. a Java class implementing JavaDelegate): thus, I would be able to define a variable in the process definition XML file, so that I can then get it from Java code.Is that possible? Is there any workaround about this?Thanks for your support.</description>
      <pubDate>Mon, 10 Oct 2011 14:16:23 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57732#M35160</guid>
      <dc:creator>ilgrosso</dc:creator>
      <dc:date>2011-10-10T14:16:23Z</dc:date>
    </item>
    <item>
      <title>Re: Is it possible to define a variable in a bpmn20.xml file?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57733#M35161</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi,&lt;BR /&gt;I need to parametrize a UserTask (i.e. a Java class implementing JavaDelegate): thus, I would be able to define a variable in the process definition XML file, so that I can then get it from Java code.&lt;BR /&gt;&lt;BR /&gt;Is that possible? Is there any workaround about this?&lt;BR /&gt;&lt;BR /&gt;Thanks for your support.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm a bit confused, as you speek about a UserTask and refer to a JavaDelegate too. IMHO, a user task does not have a java delegate - only service tasks do. If you are speaking about service tasks, check out the manual about field injection. It allows you to inject static fields, as well as expressions into tasks. Keep in mind, that the injection into your java delegate object only occurs at its first creation. Subsequent calls to your java delegate will use the injected value. The corresponding chapter in the manual is &lt;/SPAN&gt;&lt;A href="http://www.activiti.org/userguide/index.html#serviceTaskFieldInjection" rel="nofollow noopener noreferrer"&gt;http://www.activiti.org/userguide/index.html#serviceTaskFieldInjection&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For user tasks, there is no such field injection possible I think.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Heiko&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Oct 2011 06:35:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57733#M35161</guid>
      <dc:creator>bardioc</dc:creator>
      <dc:date>2011-10-11T06:35:47Z</dc:date>
    </item>
    <item>
      <title>Re: Is it possible to define a variable in a bpmn20.xml file?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57734#M35162</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for explanation, you are completely right about injection.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For my purpose I could just use a groovy ScriptTask doing something like &lt;/SPAN&gt;&lt;CODE&gt;execution.setVariable("myVar", scriptVar)&lt;/CODE&gt;&lt;SPAN&gt; then fetching myVar in JavaDelegate's execute() via &lt;/SPAN&gt;&lt;CODE&gt;execution.getVariable()&lt;/CODE&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Oct 2011 10:06:27 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/is-it-possible-to-define-a-variable-in-a-bpmn20-xml-file/m-p/57734#M35162</guid>
      <dc:creator>ilgrosso</dc:creator>
      <dc:date>2011-10-25T10:06:27Z</dc:date>
    </item>
  </channel>
</rss>

