title: UIMA RUTA - How to simulate a IF-ELSE-Condition?
body: <p>I am currently trying to solve the following use-case in RUTA:</p>
  
  <pre><code>If a Fragment contains one or more words from a WordlistA, then CREATE(Process, "finished" = "true")
  If the Fragment contains none of the words from the WordlistA, then CREATE(Process, "finished" = "false")
  </code></pre>
  
  <p>So the created annotation Process@finished should be either true or false but never 'true' and 'false' at the same time.</p>
  
  <p>I tried this one:</p>
  
  <pre><code>DECLARE Process (STRING finsihed);
  WORDLIST WordlistA = 'mywordlist.txt';
  Document{-&gt; MARKFAST(ProcessTerm, WordlistA)};
  Fragment {} -&gt; {ProcessTerm {-&gt; CREATE(Process, "finished" = "true")};};
  Fragment {-CONTAINS(ProcessTerm) -&gt; CREATE(Process, "finished" = "false")};
  </code></pre>
  
  <p>As far as I can see, the second rule matches always!? But why? As a result the ProcessTerm@finished annotation contains 'true' and 'false' if the first rule matches, too.</p>
  
  <p>What is the best way to achive the use-case using RUTA? In my opinion, I need something like an IF-ELSE-Statement.</p>
  
  <p>As the use case changed a little bit in the last two hours into</p>
  
  <pre><code>If a **Document** contains one or more words from a WordlistA, then CREATE(Process, "finished" = "true")
  If the **Document** contains none of the words from the WordlistA, then CREATE(Process, "finished" = "false")
  </code></pre>
  
  <p>I am now using Peters proposal in the following way:</p>
  
  <pre><code>Document-&gt;{
    Document{CONTAINS(ProcessTerm)-&gt; CREATE(Process, "finished" = "true")};
    Document{-PARTOF(Process) -&gt; CREATE(Process, "finished" = "false")};
  };
  </code></pre>