title: struts2: enum in IF
body: <p>How does the following Java condition translate into <code>s:if test="..."</code> in <em>struts2</em>?</p>
  
  <pre><code>if(company.getAffiliateId().asInt() != com.foo.bar.Affiliates.XYZ.asInt()){
   // do something
  }
  </code></pre>
  
  <p><em>company.getAffiliateId()</em> returns <code>BigDecimal</code></p>
  
  <p><em>com.foo.bar.Affiliates</em> is an <code>enum</code></p>
  
  <p>This doesn't work:</p>
  
  <pre><code>&lt;s:if test="%{company.affiliateId.asInt() != com.foo.bar.Affiliates.XYZ.asInt() }"&gt;
     alert("do something");
  &lt;/s:if&gt;
  </code></pre>