<?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 How to remove a variable? in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30996#M15996</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The API (ActivitiExecution class) doesn't have any method specifically for removing a variable from the execution.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I am guessing setting a variable to NULL would remove it. Am I right? If so, it would be helpful to note it in the JavaDocs (on setVariable method)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Hamed&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 03 Oct 2010 08:05:15 GMT</pubDate>
    <dc:creator>iravanchi</dc:creator>
    <dc:date>2010-10-03T08:05:15Z</dc:date>
    <item>
      <title>How to remove a variable?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30996#M15996</link>
      <description>Hi,The API (ActivitiExecution class) doesn't have any method specifically for removing a variable from the execution.I am guessing setting a variable to NULL would remove it. Am I right? If so, it would be helpful to note it in the JavaDocs (on setVariable method)-Hamed</description>
      <pubDate>Sun, 03 Oct 2010 08:05:15 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30996#M15996</guid>
      <dc:creator>iravanchi</dc:creator>
      <dc:date>2010-10-03T08:05:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove a variable?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30997#M15997</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Well, apparently I was wrong. At least about non-nullable types.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;When setting the variable value to null, Activiti will look at the variable type handler associated to the current value.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;So, for example, if the variable is an integer, it tries to set the value of an integer to null, which throws an exception.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It depends on what is Activiti's definition for null values, but if null value means removal from the variable map, it shouldn't get to that point. (It shouldn't call VariableInstanceEntity.setValue or even VariableMap.put at all, rather remove it from the map.)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here's the stack trace that I got, in case it can be of any help:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Caused by: java.lang.NullPointerException&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.engine.impl.variable.IntegerType.setValue(IntegerType.java:34)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.engine.impl.runtime.VariableInstanceEntity.setValue(VariableInstanceEntity.java:158)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.engine.impl.runtime.VariableMap.put(VariableMap.java:114)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.engine.impl.runtime.VariableMap.put(VariableMap.java:34)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.pvm.impl.runtime.ExecutionImpl.setVariableLocally(ExecutionImpl.java:593)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.pvm.impl.runtime.ExecutionImpl.setVariable(ExecutionImpl.java:580)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; at org.activiti.pvm.impl.runtime.ExecutionImpl.setVariable(ExecutionImpl.java:584)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I would create a JIRA issue, but I don't know your intended definition for null values as variable values.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Oct 2010 08:56:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30997#M15997</guid>
      <dc:creator>iravanchi</dc:creator>
      <dc:date>2010-10-03T08:56:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove a variable?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30998#M15998</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Afaik, this is not possible with the current API (since null is indeed treated separately).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I added a Jira for this feature request: &lt;/SPAN&gt;&lt;A href="http://jira.codehaus.org/browse/ACT-208" rel="nofollow noopener noreferrer"&gt;http://jira.codehaus.org/browse/ACT-208&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 04 Oct 2010 09:14:04 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30998#M15998</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2010-10-04T09:14:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove a variable?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30999#M15999</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Afaik, this is not possible with the current API (since null is indeed treated separately).&lt;BR /&gt;&lt;BR /&gt;I added a Jira for this feature request: &lt;A href="http://jira.codehaus.org/browse/ACT-208" rel="nofollow noopener noreferrer"&gt;http://jira.codehaus.org/browse/ACT-208&lt;/A&gt;&lt;/BLOCKQUOTE&gt;&lt;SPAN&gt;It's resolved? Any example, please.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Mar 2011 06:30:59 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/30999#M15999</guid>
      <dc:creator>shar</dc:creator>
      <dc:date>2011-03-18T06:30:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove a variable?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/31000#M16000</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The DelegateExecution has a method to remove the variable.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Mar 2011 16:56:36 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-remove-a-variable/m-p/31000#M16000</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2011-03-21T16:56:36Z</dc:date>
    </item>
  </channel>
</rss>

