<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Answers to: TaskQuery isInvolved and canWorkOn</title><link>https://answers.axonivy.com/questions/1345/taskquery-isinvolved-and-canworkon</link><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;What does mean isInvolved for a SecurityMember in a TaskQuery? If I want to get all the tasks that I can start, is "canWorkOn" enough?&lt;/p&gt;
&lt;p&gt;Thanks a lot in advance!&lt;/p&gt;
&lt;p&gt;Example:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;ISecurityMember member = Ivy.wf().getSecurityContext().findUser(username);

TaskQuery taskUserQuery = TaskQuery.create();
taskUserQuery.where().isInvolved(member);
taskUserQuery.where().or().canWorkOn(member);
&lt;/code&gt;&lt;/pre&gt;</description><atom:link href="https://answers.axonivy.com/questions/1345/taskquery-isinvolved-and-canworkon" rel="self"></atom:link><language>en</language><lastBuildDate>Fri, 29 May 2015 15:50:06 -0400</lastBuildDate><item><title>Answer by Dominik Regli</title><link>https://answers.axonivy.com/questions/1345/taskquery-isinvolved-and-canworkon/1346</link><description>&lt;p&gt;I think &lt;code&gt;canWorkOn(member)&lt;/code&gt; is enough for this use-case. It returns all tasks, for which the user has permission, and are in state &lt;code&gt;SUSPENDED&lt;/code&gt;, &lt;code&gt;PARKED&lt;/code&gt;, &lt;code&gt;RESUMED&lt;/code&gt;, or &lt;code&gt;CREATED&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;isInvolved(member)&lt;/code&gt; will return the same tasks as canWorkOn(..) &lt;strong&gt;but also&lt;/strong&gt; tasks for which the user has permission, but are in a not resumable state (&lt;code&gt;READY_FOR_JOIN&lt;/code&gt;, &lt;code&gt;JOINING&lt;/code&gt;, &lt;code&gt;JOIN_FAILED&lt;/code&gt;, &lt;code&gt;DONE&lt;/code&gt; or &lt;code&gt;DESTROYED&lt;/code&gt;)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Dominik Regli</dc:creator><pubDate>Fri, 29 May 2015 15:50:06 -0400</pubDate><guid>https://answers.axonivy.com/questions/1345/taskquery-isinvolved-and-canworkon/1346</guid></item></channel></rss>