title: How to write correct expression to result to Boolean? (Cannot cast from boolean to Boolean)
body: <p>I am experiencing difficulties with an expression that should result in showing or hiding a band in an iReport.</p>
  
  <p>These are variables that I have:</p>
  
  <pre><code>Integer mainGroupInt = Integer.valueOf(5);
  Integer subGroupInt = Integer.valueOf(5);
  Boolean showDetailGroup = Boolean.valueOf(false);
  </code></pre>
  
  <p>The result must be a <code>Boolean</code>, so I tried the following:</p>
  
  <pre><code>mainGroupInt.intValue() != 0 &amp;&amp; subGroupInt.intValue() != 0)) || (mainGroupInt.intValue() != 0 &amp;&amp; showDetailGroup)
  </code></pre>
  
  <p>This is thus not working, I get the following error:</p>
  
  <blockquote>
    <p>The expression of type boolean is boxed into Boolean</p>
  </blockquote>
  
  <p>I'm overthinking this one but I cannot solve it.</p>
  
  <p>Thanks for your help.</p>