title: Checking attribute exists in JSP
body: <p>I have some classes which extends a superclass, and in the JSP I want to show some attributes of these classes. I only want to make one JSP, but I don't know in advance if the object has an attribute or not. So I need a JSTL expression or a tag which checks that the object I pass has this attribute (similar to in operator in javascript, but in the server).</p>
  
  <pre><code>&lt;c:if test="${an expression which checks if myAttribute exists in myObject}"&gt;
      &lt;!-- Display this only when myObject has the atttribute "myAttribute" --&gt;
      &lt;!-- Now I can access safely to "myAttribute" --&gt;
      ${myObject.myAttribute}
  &lt;/C:if&gt;
  </code></pre>
  
  <p>How can I get this?</p>
  
  <p>Thanks.</p>